@cimulate/copilot-widget 0.21.0 → 0.23.0

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.
@@ -1,43 +1,43 @@
1
- (function(Oe,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Oe=typeof globalThis!="undefined"?globalThis:Oe||self,Fe(Oe["cimulate-copilot-widget"]={}))})(this,function(Oe){"use strict";var QF=Object.defineProperty,XF=Object.defineProperties;var JF=Object.getOwnPropertyDescriptors;var Qc=Object.getOwnPropertySymbols;var lx=Object.prototype.hasOwnProperty,cx=Object.prototype.propertyIsEnumerable;var No=(Oe,Fe)=>(Fe=Symbol[Oe])?Fe:Symbol.for("Symbol."+Oe),ZF=Oe=>{throw TypeError(Oe)},Xc=Math.pow,Pm=(Oe,Fe,Ge)=>Fe in Oe?QF(Oe,Fe,{enumerable:!0,configurable:!0,writable:!0,value:Ge}):Oe[Fe]=Ge,U=(Oe,Fe)=>{for(var Ge in Fe||(Fe={}))lx.call(Fe,Ge)&&Pm(Oe,Ge,Fe[Ge]);if(Qc)for(var Ge of Qc(Fe))cx.call(Fe,Ge)&&Pm(Oe,Ge,Fe[Ge]);return Oe},ye=(Oe,Fe)=>XF(Oe,JF(Fe));var Xt=(Oe,Fe)=>{var Ge={};for(var ot in Oe)lx.call(Oe,ot)&&Fe.indexOf(ot)<0&&(Ge[ot]=Oe[ot]);if(Oe!=null&&Qc)for(var ot of Qc(Oe))Fe.indexOf(ot)<0&&cx.call(Oe,ot)&&(Ge[ot]=Oe[ot]);return Ge};var ke=(Oe,Fe,Ge)=>Pm(Oe,typeof Fe!="symbol"?Fe+"":Fe,Ge);var it=(Oe,Fe,Ge)=>new Promise((ot,At)=>{var pt=Nt=>{try{jt(Ge.next(Nt))}catch(En){At(En)}},Pe=Nt=>{try{jt(Ge.throw(Nt))}catch(En){At(En)}},jt=Nt=>Nt.done?ot(Nt.value):Promise.resolve(Nt.value).then(pt,Pe);jt((Ge=Ge.apply(Oe,Fe)).next())}),Ur=function(Oe,Fe){this[0]=Oe,this[1]=Fe},Jc=(Oe,Fe,Ge)=>{var ot=(Pe,jt,Nt,En)=>{try{var ms=Ge[Pe](jt),Oo=(jt=ms.value)instanceof Ur,Zc=ms.done;Promise.resolve(Oo?jt[0]:jt).then(nr=>Oo?ot(Pe==="return"?Pe:"next",jt[1]?{done:nr.done,value:nr.value}:nr,Nt,En):Nt({value:nr,done:Zc})).catch(nr=>ot("throw",nr,Nt,En))}catch(nr){En(nr)}},At=Pe=>pt[Pe]=jt=>new Promise((Nt,En)=>ot(Pe,jt,Nt,En)),pt={};return Ge=Ge.apply(Oe,Fe),pt[No("asyncIterator")]=()=>pt,At("next"),At("throw"),At("return"),pt},Rm=Oe=>{var Fe=Oe[No("asyncIterator")],Ge=!1,ot,At={};return Fe==null?(Fe=Oe[No("iterator")](),ot=pt=>At[pt]=Pe=>Fe[pt](Pe)):(Fe=Fe.call(Oe),ot=pt=>At[pt]=Pe=>{if(Ge){if(Ge=!1,pt==="throw")throw Pe;return Pe}return Ge=!0,{done:!1,value:new Ur(new Promise(jt=>{var Nt=Fe[pt](Pe);Nt instanceof Object||ZF("Object expected"),jt(Nt)}),1)}}),At[No("iterator")]=()=>At,ot("next"),"throw"in Fe?ot("throw"):At.throw=pt=>{throw pt},"return"in Fe&&ot("return"),At},fx=(Oe,Fe,Ge)=>(Fe=Oe[No("asyncIterator")])?Fe.call(Oe):(Oe=Oe[No("iterator")](),Fe={},Ge=(ot,At)=>(At=Oe[ot])&&(Fe[ot]=pt=>new Promise((Pe,jt,Nt)=>(pt=At.call(Oe,pt),Nt=pt.done,Promise.resolve(pt.value).then(En=>Pe({value:En,done:Nt}),jt)))),Ge("next"),Ge("return"),Fe);var Fe=document.createElement("style");Fe.textContent=`.cim-widget-button{padding:.5rem;background-color:var(--cim-widget-primary-color, #3182ce);border-radius:4px;border-color:var(--cim-widget-primary-color, #3182ce);border-style:solid;color:#fff;font-family:var(--cim-widget-font-family, inherit);cursor:pointer;&:disabled,&[disabled]{cursor:not-allowed;opacity:.6}}.cim-widget-icon-button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;background-color:transparent;border:1px solid transparent;border-radius:4px;padding:6px;cursor:pointer;color:#333;font-size:18px;&:hover{background-color:#f0f0f0}&:disabled,&[disabled]{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-search-bar{display:flex;align-items:center;justify-content:space-between;padding:1px;border:1px solid var(--cim-widget-border-color);border-radius:4px;font-family:var(--cim-widget-font-family)}.cim-widget-search-input{width:100%;height:100%;margin-left:2px;background-color:transparent;border:none;outline:none}.cim-widget-connection-status-icon{display:inline-block;min-width:8px;width:.6rem;height:.5rem;border-radius:50%;margin:.35rem;vertical-align:middle;&.connected{background-color:#00d60080}&.disconnected{background-color:#c9c7c7}}.cim-widget-overflow-menu{position:relative;height:auto;width:auto}.cim-widget-overflow-menu-list{width:130px;background:#fff;padding:.25rem 0;border-radius:.5rem;border:1px solid var(--cim-widget-border-color)}.cim-widget-overflow-menu-button-trigger,.cim-widget-overflow-menu-button{display:inline-flex;align-items:center;width:100%;background-color:#fff;border:1px solid transparent;border-radius:4px;padding:6px;cursor:pointer;color:#333;&:hover{background-color:#f0f0f0}}.cim-widget-overflow-menu-button{gap:.5rem;padding:.5rem .75rem;svg{font-size:.75rem}}.cim-widget-close-button{display:flex;align-items:center;justify-content:center;padding:.5rem;border-radius:4px;border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-product-tile{display:inline-flex;flex-direction:column;background-color:var(--cim-widget-background-color, #ffffff);border-radius:4px;box-shadow:0 1px 3px #0000001a}.cim-widget-product-tile.embedded,.cim-widget-product-tile.standalone{min-width:15dvw;max-width:30dvw}.cim-widget-product-tile-image{object-fit:contain;width:100%;height:auto;max-height:25dvh;border-top-left-radius:4px;border-top-right-radius:4px}.cim-widget-product-tile-details{height:100%;display:flex;flex-direction:column;justify-content:space-between;padding:.5rem}.cim-widget-product-tile-brand{color:var(--cim-widget-primary-color)}.cim-widget-product-tile-pdp,.cim-widget-product-tile-name,.cim-widget-product-tile-price,.cim-widget-product-tile-pid{display:inline-block;line-height:1.25rem;font-size:.875rem}.cim-widget-product-tile-name{font-weight:700}.cim-widget-product-tile-pdp{color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 85%,black);text-decoration:none;word-wrap:break-word;&:hover{text-decoration:underline}}.cim-widget-product-tile-pdp-arrow{display:inline-block;transform:rotate(-45deg)}.cim-widget-product-tile-footer{display:flex;justify-content:space-between;align-items:center;padding-top:.5rem;gap:.5rem}.cim-widget-product-tile-price{font-weight:700}@media (max-width: 576px){.cim-widget-product-tile.embedded,.cim-widget-product-tile.standalone{min-width:30dvw;max-width:45dvw}.cim-widget-product-tile-pdp,.cim-widget-product-tile-name{display:-webkit-box;line-clamp:3;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}}.cim-widget-display-products{flex-direction:column;overflow-x:hidden}.cim-widget-product-list{flex:1;display:inline-flex;gap:.5rem;padding:.5rem .5rem .5rem 0;overflow-x:auto}.cim-widget-error-message-text{display:inline-flex;align-items:center;gap:.5rem;color:#e53e3e;&.embedded svg{min-width:1.25rem;height:1.25rem}}.cim-widget-suggestion-container.embedded{display:inline-flex;flex-wrap:wrap;gap:.5rem}.cim-widget-suggestion-button.embedded{height:auto;padding:.2rem .5rem;border:1px solid var(--cim-widget-primary-color);border-radius:4px;background-color:transparent;font-size:.875rem;font-weight:600;font-family:inherit;color:var(--cim-widget-primary-color);white-space:normal;word-break:break-word;text-align:left;cursor:pointer}.cim-widget-suggestion-button.embedded:hover{background-color:#fff;color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-container.standalone{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:.5rem;padding:.5rem 0}@media (max-width: 768px){.cim-widget-suggestion-container.standalone{grid-template-columns:repeat(1,1fr)}}.cim-widget-suggestion-button.standalone{display:inline-flex;align-items:center;padding:.5rem 1rem;border:1px solid var(--cim-widget-primary-color);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent);font-weight:700;color:var(--cim-widget-primary-color);text-align:left;white-space:normal;word-break:break-word}.cim-widget-suggestion-button.standalone:hover{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 15%,transparent);color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-button:disabled{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a;cursor:not-allowed}.cim-widget-suggestion-button:disabled:hover{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a}.cim-widget-blinking-cursor{display:inline-flex;margin-left:2px;line-height:0;animation:cursor-blink 1.5s steps(2) infinite}@keyframes cursor-blink{0%{opacity:0}}.cim-widget-ul{list-style-type:disc;padding-left:1.5rem}.cim-widget-ol{list-style-type:decimal;padding-left:1.5rem}.cim-widget-table{width:100%;margin-top:1rem;margin-bottom:1rem;border-radius:.5rem;border:1px solid #8a8a8a;border-collapse:collapse}.cim-widget-thead{background-color:#f0f0f0;border-bottom-width:2px;border-color:#8a8a8a}.cim-widget-tr{border-bottom-width:1px;border-color:#8a8a8a}.cim-widget-th{padding:.5rem 1rem;text-align:left;font-weight:700;border-bottom-width:1px;border-color:#8a8a8a}.cim-widget-td{padding:.5rem 1rem;border-bottom-width:1px;border-color:#8a8a8a}.cim-widget-message-container pre{margin:0}.cim-widget-progress-message.embedded,.cim-widget-progress-message.standalone{display:flex;align-items:center}.cim-widget-progress-text.embedded{font-size:.85rem;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 80%,white);line-height:1rem;line-clamp:3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cim-widget-progress-text.standalone{font-size:inherit;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 85%,white)}.cim-widget-thought-container{padding-left:.5rem;margin:.5rem;border-left:2px solid var(--cim-widget-primary-color)}p.cim-widget-progress-thought{margin-bottom:1rem;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 70%,white);line-height:1;font-size:.875rem}.cim-widget-thought-context-button{display:inline-flex;align-items:center;justify-content:space-between;padding:.25rem;min-width:84px;background-color:transparent;border-color:transparent;color:var(--cim-widget-primary-color);font-weight:700;cursor:pointer;&:hover{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent);color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}}.cim-widget-message-icon.progress-icon.embedded{color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 50%,white)}.cim-widget-refined-event{display:flex;flex-direction:column}.cim-widget-refined-event-query{display:inline-flex;align-items:center;color:var(--cim-widget-secondary-color)}.cim-widget-message-icon.refined-event-icon{font-size:1.5rem;&.embedded,&.standalone{color:var(--cim-widget-primary-color)}}.cim-widget-facet-pill{display:inline-flex;align-items:center;margin-left:4px;padding:.25rem .5rem;color:var(--cim-widget-primary-color);border-radius:9999px;font-size:.75rem;font-weight:700;&.embedded{background-color:#ffffff90}&.standalone{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent)}}.cim-widget-facet-filters{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:.25rem}.cim-widget-facets{display:flex;flex-direction:column;padding:.25rem}.cim-widget-facets .cim-widget-facet-category{margin-bottom:0;font-size:.875rem;font-weight:700;word-wrap:break-word}.cim-widget-facets .cim-widget-facet-values{margin-top:0;font-size:.675rem}.cim-widget-user-message{display:flex;align-items:center}.cim-widget-user-message.embedded{display:inline-flex;align-self:flex-end;border-radius:8px;padding:.5rem 1rem;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:30%}.cim-widget-user-message.standalone{margin:.5rem 0}.cim-widget-user-message-text{font-weight:700;margin-bottom:.5rem}.cim-widget-message-icon.user-message-icon{margin-right:.5rem}.cim-widget-message-icon.user-message-icon.embedded{color:var(--cim-widget-primary-color)}.cim-widget-user-search{display:flex}.cim-widget-user-search.embedded{display:inline-flex;align-self:flex-end;border-radius:8px;padding:.5rem 1rem;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:30%;gap:4px}.cim-widget-user-search.standalone{flex-direction:column;padding-top:.5rem;padding-bottom:.5rem}.cim-widget-user-search-query{display:inline-flex}.cim-widget-message-icon.user-search-icon.embedded,.cim-widget-message-icon.user-search-icon.standalone{font-size:1.5rem;color:var(--cim-widget-primary-color)}.message{border-radius:.5rem}.widget-message{display:flex;align-self:flex-start}.user-message{display:flex;align-self:flex-end;padding:1rem}.cim-widget-reset-message{font-size:.75rem;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 75%,white)}.cim-widget-start-search-message{font-size:.875rem;font-weight:700;color:var(--cim-widget-font-color)}.cim-widget-message-group,.cim-widget-message{display:flex;flex-direction:column}.cim-widget-message-group{gap:.5rem;padding:1rem;margin-bottom:1rem;border-radius:8px;&.standalone{padding:0 1rem}.cim-widget-message-group-child{max-width:100%;margin-bottom:.25rem}}.cim-widget-message-group.embedded{max-width:80%;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent)}.cim-widget-message{margin-bottom:1rem}.cim-widget-message.standalone{border-radius:0;background-color:transparent;padding:0 1rem}.cim-widget-message.embedded{margin-bottom:1rem}.cim-widget-embedded-chat{position:relative;width:100%;height:100%;margin:0 auto;border-radius:8px;border:1px solid var(--cim-widget-border-color)}.cim-widget-embedded-chat>.cim-widget-message-container{padding-top:2rem;padding-left:1rem;padding-right:1rem}.cim-widget-embedded-chat-menu{position:absolute;top:.25rem;right:.25rem}.cim-widget-overflow-menu-button-trigger.chat{border:1px solid var(--cim-widget-border-color)}.cim-widget-dialog{position:fixed;width:35dvw;height:55dvh;padding:1rem;border-radius:.5rem;border:1px solid var(--cim-widget-border-color);font-size:.875rem;&.bottom-left{bottom:.5rem;left:.5rem}&.bottom-right{bottom:.5rem;right:.5rem}}.cim-widget-dialog-content{display:flex;flex-direction:column;height:100%}.cim-widget-dialog-header{display:inline-flex;align-items:center;width:100%;margin-bottom:.5rem;gap:8px}.cim-widget-dialog-controls{position:absolute;top:4px;right:4px;display:inline-flex;align-items:center}.cim-widget-dialog-logo{object-fit:contain;max-width:50%;max-height:3rem}.cim-widget-dialog-title{margin-top:0;margin-bottom:0}@media (576px <= width <= 768px){.cim-widget-dialog{width:50%;border-radius:0}}@media (max-width: 576px){.cim-widget-dialog{height:100%;width:100%;border-radius:0;&.bottom-left{bottom:0;left:0}&.bottom-right{bottom:0;right:0}}}.cim-widget-modal-container{display:flex;align-items:center;justify-content:center;position:fixed;top:0;left:0;height:100dvh;width:100dvw}.cim-widget-modal-backdrop{position:absolute;top:0;left:0;height:100%;width:100%;background:#00000080}.cim-widget-modal{position:fixed;width:70dvw;height:80dvh;padding:1rem;border-radius:.5rem;border:1px solid var(--cim-widget-border-color);overflow-y:hidden;&.fullscreen{height:100%;width:100%;border-radius:0}}.cim-widget-modal-content{display:flex;flex-direction:column;height:100%}.cim-widget-modal-header{display:inline-flex;align-items:center;width:100%;margin-bottom:1rem;gap:8px}.cim-widget-modal-controls{position:absolute;top:4px;right:4px;display:inline-flex;align-items:center}.cim-widget-modal-logo{object-fit:contain;max-width:50%;max-height:3rem}.cim-widget-modal-title{margin-top:0;margin-bottom:0}@media (max-width: 576px){.cim-widget-modal{height:100%;width:100%;border-radius:0}}.cim-widget-container{box-sizing:border-box;display:flex;flex-direction:column;background-color:var(--cim-widget-background-color);font-family:var(--cim-widget-font-family, inherit);color:var(--cim-widget-font-color, inherit)}.cim-widget-message-container p{margin:.25rem 0;padding:0;+p{margin-top:.5rem}}.cim-widget-message-container span{line-height:1}.cim-widget-header{font-weight:700;color:inherit}.cim-widget-header.h1{margin-top:2rem;margin-bottom:2rem;font-size:2rem}.cim-widget-header.h2{margin-top:1.5rem;margin-bottom:1.5rem;font-size:1.5rem}.cim-widget-header.h3{margin-top:1rem;margin-bottom:1rem;font-size:1.2rem}.cim-widget-link{color:var(--cim-widget-primary-color);text-decoration:underline;cursor:pointer}.cim-widget-link:hover{color:var(--cim-widget-secondary-color);text-decoration:none}.cim-widget-text{line-height:1.5;color:inherit;margin-bottom:.25rem}.cim-widget-text.italic{font-style:italic}.cim-widget-text.bold{font-weight:700}.cim-widget-message-container{flex:1;overflow-y:auto;padding:1rem 0}.cim-widget-message-icon{display:inline-flex;align-items:center;margin-right:.25rem}.cim-widget-message-icon.embedded{font-size:1rem;color:var(--cim-widget-secondary-color)}.cim-widget-message-icon.standalone{font-size:1.5rem;color:var(--cim-widget-primary-color)}
2
- /*$vite$:1*/`,document.head.appendChild(Fe);function Ge(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ot={exports:{}},At={},pt={exports:{}},Pe={};var jt;function Nt(){if(jt)return Pe;jt=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),u=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),E=Symbol.iterator;function b(R){return R===null||typeof R!="object"?null:(R=E&&R[E]||R["@@iterator"],typeof R=="function"?R:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,S={};function C(R,Q,N){this.props=R,this.context=Q,this.refs=S,this.updater=N||T}C.prototype.isReactComponent={},C.prototype.setState=function(R,Q){if(typeof R!="object"&&typeof R!="function"&&R!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,R,Q,"setState")},C.prototype.forceUpdate=function(R){this.updater.enqueueForceUpdate(this,R,"forceUpdate")};function k(){}k.prototype=C.prototype;function M(R,Q,N){this.props=R,this.context=Q,this.refs=S,this.updater=N||T}var D=M.prototype=new k;D.constructor=M,_(D,C.prototype),D.isPureReactComponent=!0;var G=Array.isArray,q=Object.prototype.hasOwnProperty,B={current:null},te={key:!0,ref:!0,__self:!0,__source:!0};function Te(R,Q,N){var _e,Me={},Ie=null,Ye=null;if(Q!=null)for(_e in Q.ref!==void 0&&(Ye=Q.ref),Q.key!==void 0&&(Ie=""+Q.key),Q)q.call(Q,_e)&&!te.hasOwnProperty(_e)&&(Me[_e]=Q[_e]);var Ve=arguments.length-2;if(Ve===1)Me.children=N;else if(1<Ve){for(var Je=Array(Ve),xt=0;xt<Ve;xt++)Je[xt]=arguments[xt+2];Me.children=Je}if(R&&R.defaultProps)for(_e in Ve=R.defaultProps,Ve)Me[_e]===void 0&&(Me[_e]=Ve[_e]);return{$$typeof:e,type:R,key:Ie,ref:Ye,props:Me,_owner:B.current}}function Se(R,Q){return{$$typeof:e,type:R.type,key:Q,ref:R.ref,props:R.props,_owner:R._owner}}function H(R){return typeof R=="object"&&R!==null&&R.$$typeof===e}function fe(R){var Q={"=":"=0",":":"=2"};return"$"+R.replace(/[=:]/g,function(N){return Q[N]})}var de=/\/+/g;function ue(R,Q){return typeof R=="object"&&R!==null&&R.key!=null?fe(""+R.key):Q.toString(36)}function ie(R,Q,N,_e,Me){var Ie=typeof R;(Ie==="undefined"||Ie==="boolean")&&(R=null);var Ye=!1;if(R===null)Ye=!0;else switch(Ie){case"string":case"number":Ye=!0;break;case"object":switch(R.$$typeof){case e:case t:Ye=!0}}if(Ye)return Ye=R,Me=Me(Ye),R=_e===""?"."+ue(Ye,0):_e,G(Me)?(N="",R!=null&&(N=R.replace(de,"$&/")+"/"),ie(Me,Q,N,"",function(xt){return xt})):Me!=null&&(H(Me)&&(Me=Se(Me,N+(!Me.key||Ye&&Ye.key===Me.key?"":(""+Me.key).replace(de,"$&/")+"/")+R)),Q.push(Me)),1;if(Ye=0,_e=_e===""?".":_e+":",G(R))for(var Ve=0;Ve<R.length;Ve++){Ie=R[Ve];var Je=_e+ue(Ie,Ve);Ye+=ie(Ie,Q,N,Je,Me)}else if(Je=b(R),typeof Je=="function")for(R=Je.call(R),Ve=0;!(Ie=R.next()).done;)Ie=Ie.value,Je=_e+ue(Ie,Ve++),Ye+=ie(Ie,Q,N,Je,Me);else if(Ie==="object")throw Q=String(R),Error("Objects are not valid as a React child (found: "+(Q==="[object Object]"?"object with keys {"+Object.keys(R).join(", ")+"}":Q)+"). If you meant to render a collection of children, use an array instead.");return Ye}function ge(R,Q,N){if(R==null)return R;var _e=[],Me=0;return ie(R,_e,"","",function(Ie){return Q.call(N,Ie,Me++)}),_e}function we(R){if(R._status===-1){var Q=R._result;Q=Q(),Q.then(function(N){(R._status===0||R._status===-1)&&(R._status=1,R._result=N)},function(N){(R._status===0||R._status===-1)&&(R._status=2,R._result=N)}),R._status===-1&&(R._status=0,R._result=Q)}if(R._status===1)return R._result.default;throw R._result}var ae={current:null},V={transition:null},ee={ReactCurrentDispatcher:ae,ReactCurrentBatchConfig:V,ReactCurrentOwner:B};function w(){throw Error("act(...) is not supported in production builds of React.")}return Pe.Children={map:ge,forEach:function(R,Q,N){ge(R,function(){Q.apply(this,arguments)},N)},count:function(R){var Q=0;return ge(R,function(){Q++}),Q},toArray:function(R){return ge(R,function(Q){return Q})||[]},only:function(R){if(!H(R))throw Error("React.Children.only expected to receive a single React element child.");return R}},Pe.Component=C,Pe.Fragment=n,Pe.Profiler=o,Pe.PureComponent=M,Pe.StrictMode=r,Pe.Suspense=f,Pe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ee,Pe.act=w,Pe.cloneElement=function(R,Q,N){if(R==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+R+".");var _e=_({},R.props),Me=R.key,Ie=R.ref,Ye=R._owner;if(Q!=null){if(Q.ref!==void 0&&(Ie=Q.ref,Ye=B.current),Q.key!==void 0&&(Me=""+Q.key),R.type&&R.type.defaultProps)var Ve=R.type.defaultProps;for(Je in Q)q.call(Q,Je)&&!te.hasOwnProperty(Je)&&(_e[Je]=Q[Je]===void 0&&Ve!==void 0?Ve[Je]:Q[Je])}var Je=arguments.length-2;if(Je===1)_e.children=N;else if(1<Je){Ve=Array(Je);for(var xt=0;xt<Je;xt++)Ve[xt]=arguments[xt+2];_e.children=Ve}return{$$typeof:e,type:R.type,key:Me,ref:Ie,props:_e,_owner:Ye}},Pe.createContext=function(R){return R={$$typeof:a,_currentValue:R,_currentValue2:R,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},R.Provider={$$typeof:u,_context:R},R.Consumer=R},Pe.createElement=Te,Pe.createFactory=function(R){var Q=Te.bind(null,R);return Q.type=R,Q},Pe.createRef=function(){return{current:null}},Pe.forwardRef=function(R){return{$$typeof:c,render:R}},Pe.isValidElement=H,Pe.lazy=function(R){return{$$typeof:m,_payload:{_status:-1,_result:R},_init:we}},Pe.memo=function(R,Q){return{$$typeof:h,type:R,compare:Q===void 0?null:Q}},Pe.startTransition=function(R){var Q=V.transition;V.transition={};try{R()}finally{V.transition=Q}},Pe.unstable_act=w,Pe.useCallback=function(R,Q){return ae.current.useCallback(R,Q)},Pe.useContext=function(R){return ae.current.useContext(R)},Pe.useDebugValue=function(){},Pe.useDeferredValue=function(R){return ae.current.useDeferredValue(R)},Pe.useEffect=function(R,Q){return ae.current.useEffect(R,Q)},Pe.useId=function(){return ae.current.useId()},Pe.useImperativeHandle=function(R,Q,N){return ae.current.useImperativeHandle(R,Q,N)},Pe.useInsertionEffect=function(R,Q){return ae.current.useInsertionEffect(R,Q)},Pe.useLayoutEffect=function(R,Q){return ae.current.useLayoutEffect(R,Q)},Pe.useMemo=function(R,Q){return ae.current.useMemo(R,Q)},Pe.useReducer=function(R,Q,N){return ae.current.useReducer(R,Q,N)},Pe.useRef=function(R){return ae.current.useRef(R)},Pe.useState=function(R){return ae.current.useState(R)},Pe.useSyncExternalStore=function(R,Q,N){return ae.current.useSyncExternalStore(R,Q,N)},Pe.useTransition=function(){return ae.current.useTransition()},Pe.version="18.3.1",Pe}var En;function ms(){return En||(En=1,pt.exports=Nt()),pt.exports}var Oo;function Zc(){if(Oo)return At;Oo=1;var e=ms(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,u={key:!0,ref:!0,__self:!0,__source:!0};function a(c,f,h){var m,E={},b=null,T=null;h!==void 0&&(b=""+h),f.key!==void 0&&(b=""+f.key),f.ref!==void 0&&(T=f.ref);for(m in f)r.call(f,m)&&!u.hasOwnProperty(m)&&(E[m]=f[m]);if(c&&c.defaultProps)for(m in f=c.defaultProps,f)E[m]===void 0&&(E[m]=f[m]);return{$$typeof:t,type:c,key:b,ref:T,props:E,_owner:o.current}}return At.Fragment=n,At.jsx=a,At.jsxs=a,At}var nr;function px(){return nr||(nr=1,ot.exports=Zc()),ot.exports}var I=px();const br=Object.create(null);br.open="0",br.close="1",br.ping="2",br.pong="3",br.message="4",br.upgrade="5",br.noop="6";const ca=Object.create(null);Object.keys(br).forEach(e=>{ca[br[e]]=e});const ef={type:"error",data:"parser error"},Lm=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",Dm=typeof ArrayBuffer=="function",Fm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,tf=({type:e,data:t},n,r)=>Lm&&t instanceof Blob?n?r(t):Mm(t,r):Dm&&(t instanceof ArrayBuffer||Fm(t))?n?r(t):Mm(new Blob([t]),r):r(br[e]+(t||"")),Mm=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function Bm(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let nf;function mx(e,t){if(Lm&&e.data instanceof Blob)return e.data.arrayBuffer().then(Bm).then(t);if(Dm&&(e.data instanceof ArrayBuffer||Fm(e.data)))return t(Bm(e.data));tf(e,!1,n=>{nf||(nf=new TextEncoder),t(nf.encode(n))})}const Um="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Io=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<Um.length;e++)Io[Um.charCodeAt(e)]=e;const gx=e=>{let t=e.length*.75,n=e.length,r,o=0,u,a,c,f;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const h=new ArrayBuffer(t),m=new Uint8Array(h);for(r=0;r<n;r+=4)u=Io[e.charCodeAt(r)],a=Io[e.charCodeAt(r+1)],c=Io[e.charCodeAt(r+2)],f=Io[e.charCodeAt(r+3)],m[o++]=u<<2|a>>4,m[o++]=(a&15)<<4|c>>2,m[o++]=(c&3)<<6|f&63;return h},Ex=typeof ArrayBuffer=="function",rf=(e,t)=>{if(typeof e!="string")return{type:"message",data:Hm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:yx(e.substring(1),t)}:ca[n]?e.length>1?{type:ca[n],data:e.substring(1)}:{type:ca[n]}:ef},yx=(e,t)=>{if(Ex){const n=gx(e);return Hm(n,t)}else return{base64:!0,data:e}},Hm=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},zm="",Tx=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((u,a)=>{tf(u,!1,c=>{r[a]=c,++o===n&&t(r.join(zm))})})},bx=(e,t)=>{const n=e.split(zm),r=[];for(let o=0;o<n.length;o++){const u=rf(n[o],t);if(r.push(u),u.type==="error")break}return r};function _x(){return new TransformStream({transform(e,t){mx(e,n=>{const r=n.length;let o;if(r<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,r);else if(r<65536){o=new Uint8Array(3);const u=new DataView(o.buffer);u.setUint8(0,126),u.setUint16(1,r)}else{o=new Uint8Array(9);const u=new DataView(o.buffer);u.setUint8(0,127),u.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let sf;function fa(e){return e.reduce((t,n)=>t+n.length,0)}function da(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let o=0;o<t;o++)n[o]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function xx(e,t){sf||(sf=new TextDecoder);const n=[];let r=0,o=-1,u=!1;return new TransformStream({transform(a,c){for(n.push(a);;){if(r===0){if(fa(n)<1)break;const f=da(n,1);u=(f[0]&128)===128,o=f[0]&127,o<126?r=3:o===126?r=1:r=2}else if(r===1){if(fa(n)<2)break;const f=da(n,2);o=new DataView(f.buffer,f.byteOffset,f.length).getUint16(0),r=3}else if(r===2){if(fa(n)<8)break;const f=da(n,8),h=new DataView(f.buffer,f.byteOffset,f.length),m=h.getUint32(0);if(m>Math.pow(2,21)-1){c.enqueue(ef);break}o=m*Math.pow(2,32)+h.getUint32(4),r=3}else{if(fa(n)<o)break;const f=da(n,o);c.enqueue(rf(u?f:sf.decode(f),t)),r=0}if(o===0||o>e){c.enqueue(ef);break}}}})}const jm=4;function Ft(e){if(e)return Sx(e)}function Sx(e){for(var t in Ft.prototype)e[t]=Ft.prototype[t];return e}Ft.prototype.on=Ft.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},Ft.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},Ft.prototype.off=Ft.prototype.removeListener=Ft.prototype.removeAllListeners=Ft.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,o=0;o<n.length;o++)if(r=n[o],r===t||r.fn===t){n.splice(o,1);break}return n.length===0&&delete this._callbacks["$"+e],this},Ft.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,o=n.length;r<o;++r)n[r].apply(this,t)}return this},Ft.prototype.emitReserved=Ft.prototype.emit,Ft.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},Ft.prototype.hasListeners=function(e){return!!this.listeners(e).length};const ha=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),$n=typeof self!="undefined"?self:typeof window!="undefined"?window:Function("return this")(),wx="arraybuffer";function eM(){}function $m(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const Cx=$n.setTimeout,Ax=$n.clearTimeout;function pa(e,t){t.useNativeTimers?(e.setTimeoutFn=Cx.bind($n),e.clearTimeoutFn=Ax.bind($n)):(e.setTimeoutFn=$n.setTimeout.bind($n),e.clearTimeoutFn=$n.clearTimeout.bind($n))}const vx=1.33;function kx(e){return typeof e=="string"?Nx(e):Math.ceil((e.byteLength||e.size)*vx)}function Nx(e){let t=0,n=0;for(let r=0,o=e.length;r<o;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function Vm(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Ox(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function Ix(e){let t={},n=e.split("&");for(let r=0,o=n.length;r<o;r++){let u=n[r].split("=");t[decodeURIComponent(u[0])]=decodeURIComponent(u[1])}return t}class Px extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class of extends Ft{constructor(t){super(),this.writable=!1,pa(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new Px(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=rf(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=Ox(t);return n.length?"?"+n:""}}class Rx extends of{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};bx(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,Tx(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=Vm()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let qm=!1;try{qm=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const Lx=qm;function Dx(){}class Fx extends Rx{constructor(t){if(super(t),typeof location!="undefined"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location!="undefined"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(o,u)=>{this.onError("xhr post error",o,u)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class _r extends Ft{constructor(t,n,r){super(),this.createRequest=t,pa(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=$m(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let o in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(o)&&r.setRequestHeader(o,this._opts.extraHeaders[o])}}catch(o){}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(o){}try{r.setRequestHeader("Accept","*/*")}catch(o){}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var o;r.readyState===3&&((o=this._opts.cookieJar)===null||o===void 0||o.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(o){this.setTimeoutFn(()=>{this._onError(o)},0);return}typeof document!="undefined"&&(this._index=_r.requestsCount++,_r.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr=="undefined"||this._xhr===null)){if(this._xhr.onreadystatechange=Dx,t)try{this._xhr.abort()}catch(n){}typeof document!="undefined"&&delete _r.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}if(_r.requestsCount=0,_r.requests={},typeof document!="undefined"){if(typeof attachEvent=="function")attachEvent("onunload",Ym);else if(typeof addEventListener=="function"){const e="onpagehide"in $n?"pagehide":"unload";addEventListener(e,Ym,!1)}}function Ym(){for(let e in _r.requests)_r.requests.hasOwnProperty(e)&&_r.requests[e].abort()}const Mx=function(){const e=Wm({xdomain:!1});return e&&e.responseType!==null}();class Bx extends Fx{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=Mx&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new _r(Wm,this.uri(),t)}}function Wm(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||Lx))return new XMLHttpRequest}catch(n){}if(!t)try{return new $n[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const Gm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class Ux extends of{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=Gm?{}:$m(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],o=n===t.length-1;tf(r,this.supportsBinary,u=>{try{this.doWrite(r,u)}catch(a){}o&&ha(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws!="undefined"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=Vm()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const uf=$n.WebSocket||$n.MozWebSocket;class Hx extends Ux{createSocket(t,n,r){return Gm?new uf(t,n,r):n?new uf(t,n):new uf(t)}doWrite(t,n){this.ws.send(n)}}class zx extends of{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=xx(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=_x();o.readable.pipeTo(t.writable),this._writer=o.writable.getWriter();const u=()=>{r.read().then(({done:c,value:f})=>{c||(this.onPacket(f),u())}).catch(c=>{})};u();const a={type:"open"};this.query.sid&&(a.data=`{"sid":"${this.query.sid}"}`),this._writer.write(a).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],o=n===t.length-1;this._writer.write(r).then(()=>{o&&ha(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const jx={websocket:Hx,webtransport:zx,polling:Bx},$x=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Vx=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function af(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let o=$x.exec(e||""),u={},a=14;for(;a--;)u[Vx[a]]=o[a]||"";return n!=-1&&r!=-1&&(u.source=t,u.host=u.host.substring(1,u.host.length-1).replace(/;/g,":"),u.authority=u.authority.replace("[","").replace("]","").replace(/;/g,":"),u.ipv6uri=!0),u.pathNames=qx(u,u.path),u.queryKey=Yx(u,u.query),u}function qx(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function Yx(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,u){o&&(n[o]=u)}),n}const lf=typeof addEventListener=="function"&&typeof removeEventListener=="function",ma=[];lf&&addEventListener("offline",()=>{ma.forEach(e=>e())},!1);class ui extends Ft{constructor(t,n){if(super(),this.binaryType=wx,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=af(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=af(n.host).host);pa(this,n),this.secure=n.secure!=null?n.secure:typeof location!="undefined"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location!="undefined"?location.hostname:"localhost"),this.port=n.port||(typeof location!="undefined"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const o=r.prototype.name;this.transports.push(o),this._transportsByName[o]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=Ix(this.opts.query)),lf&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},ma.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=jm,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&ui.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",ui.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const o=this.writeBuffer[r].data;if(o&&(n+=kx(o)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,ha(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const u={type:t,data:n,options:r};this.emitReserved("packetCreate",u),this.writeBuffer.push(u),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(ui.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),lf&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=ma.indexOf(this._offlineEventListener);r!==-1&&ma.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}ui.protocol=jm;class Wx extends ui{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;ui.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",E=>{if(!r)if(E.type==="pong"&&E.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;ui.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(m(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const b=new Error("probe error");b.transport=n.name,this.emitReserved("upgradeError",b)}}))};function u(){r||(r=!0,m(),n.close(),n=null)}const a=E=>{const b=new Error("probe error: "+E);b.transport=n.name,u(),this.emitReserved("upgradeError",b)};function c(){a("transport closed")}function f(){a("socket closed")}function h(E){n&&E.name!==n.name&&u()}const m=()=>{n.removeListener("open",o),n.removeListener("error",a),n.removeListener("close",c),this.off("close",f),this.off("upgrading",h)};n.once("open",o),n.once("error",a),n.once("close",c),this.once("close",f),this.once("upgrading",h),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let Gx=class extends Wx{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(o=>jx[o]).filter(o=>!!o)),super(t,r)}};function Kx(e,t="",n){let r=e;n=n||typeof location!="undefined"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n!="undefined"?e=n.protocol+"//"+e:e="https://"+e),r=af(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const u=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+u+":"+r.port+t,r.href=r.protocol+"://"+u+(n&&n.port===r.port?"":":"+r.port),r}const Qx=typeof ArrayBuffer=="function",Xx=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,Km=Object.prototype.toString,Jx=typeof Blob=="function"||typeof Blob!="undefined"&&Km.call(Blob)==="[object BlobConstructor]",Zx=typeof File=="function"||typeof File!="undefined"&&Km.call(File)==="[object FileConstructor]";function cf(e){return Qx&&(e instanceof ArrayBuffer||Xx(e))||Jx&&e instanceof Blob||Zx&&e instanceof File}function ga(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ga(e[n]))return!0;return!1}if(cf(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ga(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ga(e[n]))return!0;return!1}function eS(e){const t=[],n=e.data,r=e;return r.data=ff(n,t),r.attachments=t.length,{packet:r,buffers:t}}function ff(e,t){if(!e)return e;if(cf(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=ff(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=ff(e[r],t));return n}return e}function tS(e,t){return e.data=df(e.data,t),delete e.attachments,e}function df(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=df(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=df(e[n],t));return e}const nS=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],rS=5;var Qe;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(Qe||(Qe={}));class iS{constructor(t){this.replacer=t}encode(t){return(t.type===Qe.EVENT||t.type===Qe.ACK)&&ga(t)?this.encodeAsBinary({type:t.type===Qe.EVENT?Qe.BINARY_EVENT:Qe.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Qe.BINARY_EVENT||t.type===Qe.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=eS(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}function Qm(e){return Object.prototype.toString.call(e)==="[object Object]"}class hf extends Ft{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===Qe.BINARY_EVENT;r||n.type===Qe.BINARY_ACK?(n.type=r?Qe.EVENT:Qe.ACK,this.reconstructor=new sS(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(cf(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(Qe[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Qe.BINARY_EVENT||r.type===Qe.BINARY_ACK){const u=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const a=t.substring(u,n);if(a!=Number(a)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(a)}if(t.charAt(n+1)==="/"){const u=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(u,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const u=n+1;for(;++n;){const a=t.charAt(n);if(a==null||Number(a)!=a){--n;break}if(n===t.length)break}r.id=Number(t.substring(u,n+1))}if(t.charAt(++n)){const u=this.tryParse(t.substr(n));if(hf.isPayloadValid(r.type,u))r.data=u;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch(n){return!1}}static isPayloadValid(t,n){switch(t){case Qe.CONNECT:return Qm(n);case Qe.DISCONNECT:return n===void 0;case Qe.CONNECT_ERROR:return typeof n=="string"||Qm(n);case Qe.EVENT:case Qe.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&nS.indexOf(n[0])===-1);case Qe.ACK:case Qe.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class sS{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=tS(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const oS=Object.freeze(Object.defineProperty({__proto__:null,Decoder:hf,Encoder:iS,get PacketType(){return Qe},protocol:rS},Symbol.toStringTag,{value:"Module"}));function rr(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const uS=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class Xm extends Ft{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[rr(t,"open",this.onopen.bind(this)),rr(t,"packet",this.onpacket.bind(this)),rr(t,"error",this.onerror.bind(this)),rr(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,o,u;if(uS.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const a={type:Qe.EVENT,data:n};if(a.options={},a.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const m=this.ids++,E=n.pop();this._registerAckCallback(m,E),a.id=m}const c=(o=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||o===void 0?void 0:o.writable,f=this.connected&&!(!((u=this.io.engine)===null||u===void 0)&&u._hasPingExpired());return this.flags.volatile&&!c||(f?(this.notifyOutgoingListeners(a),this.packet(a)):this.sendBuffer.push(a)),this.flags={},this}_registerAckCallback(t,n){var r;const o=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(o===void 0){this.acks[t]=n;return}const u=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let c=0;c<this.sendBuffer.length;c++)this.sendBuffer[c].id===t&&this.sendBuffer.splice(c,1);n.call(this,new Error("operation has timed out"))},o),a=(...c)=>{this.io.clearTimeoutFn(u),n.apply(this,c)};a.withError=!0,this.acks[t]=a}emitWithAck(t,...n){return new Promise((r,o)=>{const u=(a,c)=>a?o(a):r(c);u.withError=!0,n.push(u),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((o,...u)=>r!==this._queue[0]?void 0:(o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...u)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:Qe.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case Qe.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case Qe.EVENT:case Qe.BINARY_EVENT:this.onevent(t);break;case Qe.ACK:case Qe.BINARY_ACK:this.onack(t);break;case Qe.DISCONNECT:this.ondisconnect();break;case Qe.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...o){r||(r=!0,n.packet({type:Qe.ACK,id:t,data:o}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:Qe.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function gs(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}gs.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=(Math.floor(t*10)&1)==0?e-n:e+n}return Math.min(e,this.max)|0},gs.prototype.reset=function(){this.attempts=0},gs.prototype.setMin=function(e){this.ms=e},gs.prototype.setMax=function(e){this.max=e},gs.prototype.setJitter=function(e){this.jitter=e};class pf extends Ft{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,pa(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new gs({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||oS;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new Gx(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=rr(n,"open",function(){r.onopen(),t&&t()}),u=c=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",c),t?t(c):this.maybeReconnectOnOpen()},a=rr(n,"error",u);if(this._timeout!==!1){const c=this._timeout,f=this.setTimeoutFn(()=>{o(),u(new Error("timeout")),n.close()},c);this.opts.autoUnref&&f.unref(),this.subs.push(()=>{this.clearTimeoutFn(f)})}return this.subs.push(o),this.subs.push(a),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(rr(t,"ping",this.onping.bind(this)),rr(t,"data",this.ondata.bind(this)),rr(t,"error",this.onerror.bind(this)),rr(t,"close",this.onclose.bind(this)),rr(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){ha(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new Xm(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const Po={};function Ea(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=Kx(e,t.path||"/socket.io"),r=n.source,o=n.id,u=n.path,a=Po[o]&&u in Po[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||a;let f;return c?f=new pf(r,t):(Po[o]||(Po[o]=new pf(r,t)),f=Po[o]),n.query&&!t.query&&(t.query=n.queryKey),f.socket(n.path,t)}Object.assign(Ea,{Manager:pf,Socket:Xm,io:Ea,connect:Ea});var aS=function(e){return function(t){return!!t&&typeof t=="object"}(e)&&!function(t){var n=Object.prototype.toString.call(t);return n==="[object RegExp]"||n==="[object Date]"||function(r){return r.$$typeof===lS}(t)}(e)},lS=typeof Symbol=="function"&&Symbol.for?Symbol.for("react.element"):60103;function Ro(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Es((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function cS(e,t,n){return e.concat(t).map(function(r){return Ro(r,n)})}function Jm(e){return Object.keys(e).concat(function(t){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter(function(n){return Object.propertyIsEnumerable.call(t,n)}):[]}(e))}function Zm(e,t){try{return t in e}catch(n){return!1}}function fS(e,t,n){var r={};return n.isMergeableObject(e)&&Jm(e).forEach(function(o){r[o]=Ro(e[o],n)}),Jm(t).forEach(function(o){(function(u,a){return Zm(u,a)&&!(Object.hasOwnProperty.call(u,a)&&Object.propertyIsEnumerable.call(u,a))})(e,o)||(Zm(e,o)&&n.isMergeableObject(t[o])?r[o]=function(u,a){if(!a.customMerge)return Es;var c=a.customMerge(u);return typeof c=="function"?c:Es}(o,n)(e[o],t[o],n):r[o]=Ro(t[o],n))}),r}function Es(e,t,n){(n=n||{}).arrayMerge=n.arrayMerge||cS,n.isMergeableObject=n.isMergeableObject||aS,n.cloneUnlessOtherwiseSpecified=Ro;var r=Array.isArray(t);return r===Array.isArray(e)?r?n.arrayMerge(e,t,n):fS(e,t,n):Ro(t,n)}Es.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(n,r){return Es(n,r,t)},{})};var dS=Es;class hS{constructor(t){Object.assign(this,t)}}function dn(e){if(e)return function(t){for(var n in dn.prototype)t[n]=dn.prototype[n];return t}(e)}dn.prototype.on=dn.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},dn.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},dn.prototype.off=dn.prototype.removeListener=dn.prototype.removeAllListeners=dn.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return r.length===0&&delete this._callbacks["$"+e],this},dn.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t)}return this},dn.prototype.emitReserved=dn.prototype.emit,dn.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},dn.prototype.hasListeners=function(e){return!!this.listeners(e).length};const pS=typeof ArrayBuffer=="function",e0=Object.prototype.toString,mS=typeof Blob=="function"||typeof Blob!="undefined"&&e0.call(Blob)==="[object BlobConstructor]",gS=typeof File=="function"||typeof File!="undefined"&&e0.call(File)==="[object FileConstructor]";function mf(e){return pS&&(e instanceof ArrayBuffer||(t=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(t):t.buffer instanceof ArrayBuffer)(e))||mS&&e instanceof Blob||gS&&e instanceof File}function ya(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ya(e[n]))return!0;return!1}if(mf(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ya(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ya(e[n]))return!0;return!1}function ES(e){const t=[],n=e.data,r=e;return r.data=gf(n,t),r.attachments=t.length,{packet:r,buffers:t}}function gf(e,t){if(!e)return e;if(mf(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=gf(e[r],t);return n}if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=gf(e[r],t));return n}return e}function yS(e,t){return e.data=Ef(e.data,t),delete e.attachments,e}function Ef(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=Ef(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Ef(e[n],t));return e}const TS=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var _t;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(_t||(_t={}));class bS{constructor(t){this.replacer=t}encode(t){return t.type!==_t.EVENT&&t.type!==_t.ACK||!ya(t)?[this.encodeAsString(t)]:this.encodeAsBinary({type:t.type===_t.EVENT?_t.BINARY_EVENT:_t.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id})}encodeAsString(t){let n=""+t.type;return t.type!==_t.BINARY_EVENT&&t.type!==_t.BINARY_ACK||(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=ES(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}function t0(e){return Object.prototype.toString.call(e)==="[object Object]"}class yf extends dn{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===_t.BINARY_EVENT;r||n.type===_t.BINARY_ACK?(n.type=r?_t.EVENT:_t.ACK,this.reconstructor=new _S(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else{if(!mf(t)&&!t.base64)throw new Error("Unknown type: "+t);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n))}}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(_t[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===_t.BINARY_EVENT||r.type===_t.BINARY_ACK){const u=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const a=t.substring(u,n);if(a!=Number(a)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(a)}if(t.charAt(n+1)==="/"){const u=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(u,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const u=n+1;for(;++n;){const a=t.charAt(n);if(a==null||Number(a)!=a){--n;break}if(n===t.length)break}r.id=Number(t.substring(u,n+1))}if(t.charAt(++n)){const u=this.tryParse(t.substr(n));if(!yf.isPayloadValid(r.type,u))throw new Error("invalid payload");r.data=u}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch(n){return!1}}static isPayloadValid(t,n){switch(t){case _t.CONNECT:return t0(n);case _t.DISCONNECT:return n===void 0;case _t.CONNECT_ERROR:return typeof n=="string"||t0(n);case _t.EVENT:case _t.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&TS.indexOf(n[0])===-1);case _t.ACK:case _t.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class _S{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=yS(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const n0=["searchParams.facetFilters","hits","products"],r0=(e,t,n)=>function r(o,u=[]){const a=Object.entries(o).map(([c,f])=>{const h=[...u,t(c)];return[e(c),f instanceof Object&&!(n!=null&&n.includes(h.join(".")))?r(f,h):f]});return Array.isArray(o)?a.map(c=>c[1]):Object.fromEntries(a)},i0=e=>e.replace(/_([a-z])/g,(t,n)=>n.toUpperCase()),xS=r0(e=>e.replace(/([A-Z])/g,"_$1").toLowerCase(),e=>e,n0),SS=r0(i0,i0,n0),wS={Encoder:class extends bS{encode(e){var t,n;return super.encode(ye(U({},e),{data:((t=e.data)==null?void 0:t.length)==2?[e.data[0],xS(e.data[1])]:((n=e.data)==null?void 0:n.length)==1?[e.data[0]]:typeof e.data=="object"&&e.data!=null?e.data:void 0}))}},Decoder:class extends yf{constructor(){super((e,t)=>e==""&&Array.isArray(t)?t.map(n=>n instanceof Object?SS(n):n):t)}}},CS={path:"/api/v1/socket.io",autoConnect:!1,transports:["polling","websocket"],upgrade:!0,timeout:1e4};class AS{constructor({apiKey:t,apiToken:n,baseUrl:r,namespace:o="/copilot",socketOptions:u={}}){if(this.sessionIdKey="x-cimulate-copilot-session-id",this.reconnectAttempts=0,this.maxReconnectAttempts=5,this.maxReconnectDelay=3e4,this.handleConnectAck=h=>{console.log("[Copilot SDK] Connect Ack:",h),this.socket.auth={[this.sessionIdKey]:h.sessionId}},this.handleDisconnect=h=>{console.warn(`[Copilot SDK] Disconnected: ${h}`),h!=="io client disconnect"&&(console.log(`[Copilot SDK] Disconnected due to ${h}. Attempting reconnect...`),this.retryConnect())},this.handleConnectError=h=>{console.error(`[Copilot SDK] Connect error: ${h.message}`);const m=h.message.match(/['"]error['"]:\s*['"](\w+)['"]/),E=m==null?void 0:m[1];E&&["InvalidApiKey","InvalidToken","BadRequest"].includes(E)?this.disconnect():this.socket.connected||this.socket.active||(console.log("[Copilot SDK] Retrying connect attempt..."),this.retryConnect())},this.offInternalHandlers=()=>{this.socket.off("connect_ack",this.handleConnectAck),this.socket.off("disconnect",this.handleDisconnect),this.off("connect_error",this.handleConnectError)},t&&n||!t&&!n)throw new Error("Provide exactly one authentication method: either 'apiKey' or 'apiToken', but not both.");const a=`${r}${o}`,c={};t?c["x-cimulate-api-key"]=t:n&&(c.Authorization=`Bearer ${n}`);const f=[CS,u,{parser:wS,withCredentials:!0,transportOptions:{polling:{extraHeaders:c}}}];this.socket=Ea(a,dS.all(f))}connect(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0,this.reconnectAttempts=0),this.offInternalHandlers(),this.on("connect_ack",this.handleConnectAck),this.socket.on("disconnect",this.handleDisconnect),this.on("connect_error",this.handleConnectError),this.socket.auth&&this.sessionIdKey in this.socket.auth&&(this.socket.auth={}),this.socket.connect()}retryConnect(){if(!(this.socket.connected||this.socket.active||this.reconnectAttempts>=this.maxReconnectAttempts))if(this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0),this.reconnectAttempts<this.maxReconnectAttempts){const t=Math.min(1e3*Xc(2,this.reconnectAttempts),this.maxReconnectDelay);console.info(`[Copilot SDK] Retry #${this.reconnectAttempts+1} in ${t}ms...`),this.reconnectTimeout=setTimeout(()=>{this.socket.connected||this.socket.active||(this.reconnectAttempts++,this.reconnect())},t)}else console.error("[Copilot SDK] Max reconnect attempts reached.")}reconnect(){this.socket.connected||this.socket.active||this.reconnectAttempts>=this.maxReconnectAttempts||(this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0,this.reconnectAttempts=0),this.socket.connect())}browse(t,n){return it(this,null,function*(){return this.asyncResponse("copilot_browse",t,n)})}search(t,n){return it(this,null,function*(){return this.asyncResponse("copilot_search",t,n)})}facetedNavigation(t,n){return it(this,null,function*(){return this.asyncResponse("faceted_navigation",t,n)})}cancelRequest(t,n){return this.asyncResponse("cancel",t,n)}conversationReset(t,n){return this.asyncResponse("conversation_reset",t,n)}productView(t,n){return it(this,null,function*(){return this.asyncResponse("product_view",t,n)})}requestSessionInformation(t){return it(this,null,function*(){return new Promise(n=>{this.socket.emit("session_info",r=>{t&&t(r),n(r)})})})}getConversationEvents(t,n){return it(this,null,function*(){return new Promise(r=>{this.socket.emit("conversation_events",t,o=>{n&&n(o),r(o)})})})}on(t,n){return this.socket.on(t,n),n}once(t,n){this.socket.once(t,n)}off(t,n){this.socket.off(t,n)}disconnect(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0),this.offInternalHandlers(),this.socket.disconnect()}onDisconnect(t){this.socket.on("disconnect",t)}asyncResponse(t,n,r){return it(this,null,function*(){if(r)return void this.socket.emit(t,n,r);let o="";const u=function(a){return Jc(this,null,function*(){const c=[];let f=!1,h=null;const m=yield new Ur(a({emit:E=>{c.push(E),h&&(h(),h=null)},cancel:()=>{f=!0}}));try{for(;!f;)c.length>0?yield c.shift():yield new Ur(new Promise(E=>{h=E}));for(;c.length>0;)yield c.shift()}finally{yield new Ur(m==null?void 0:m())}})}(({emit:a,cancel:c})=>{const f=(h,m)=>{["done","error"].includes(m.name)&&c(),m.eventSourceId==o&&a(m)};return this.socket.onAny(f),()=>it(this,null,function*(){this.socket.offAny(f)})});return{result:yield new Promise((a,c)=>this.socket.emit(t,n,f=>{f.name==="error"?c(new hS(f)):(o=f==null?void 0:f.id,a(f))})),events:u}})}}var W=ms();const Bi=Ge(W);function s0(e,t){return function(){return e.apply(t,arguments)}}const{toString:vS}=Object.prototype,{getPrototypeOf:Tf}=Object,{iterator:Ta,toStringTag:o0}=Symbol,ba=(e=>t=>{const n=vS.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),ir=e=>(e=e.toLowerCase(),t=>ba(t)===e),_a=e=>t=>typeof t===e,{isArray:ys}=Array,Ts=_a("undefined");function Lo(e){return e!==null&&!Ts(e)&&e.constructor!==null&&!Ts(e.constructor)&&yn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const u0=ir("ArrayBuffer");function kS(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&u0(e.buffer),t}const NS=_a("string"),yn=_a("function"),a0=_a("number"),Do=e=>e!==null&&typeof e=="object",OS=e=>e===!0||e===!1,xa=e=>{if(ba(e)!=="object")return!1;const t=Tf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(o0 in e)&&!(Ta in e)},IS=e=>{if(!Do(e)||Lo(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},PS=ir("Date"),RS=ir("File"),LS=ir("Blob"),DS=ir("FileList"),FS=e=>Do(e)&&yn(e.pipe),MS=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||yn(e.append)&&((t=ba(e))==="formdata"||t==="object"&&yn(e.toString)&&e.toString()==="[object FormData]"))},BS=ir("URLSearchParams"),[US,HS,zS,jS]=["ReadableStream","Request","Response","Headers"].map(ir),$S=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Fo(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),ys(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(Lo(e))return;const u=n?Object.getOwnPropertyNames(e):Object.keys(e),a=u.length;let c;for(r=0;r<a;r++)c=u[r],t.call(null,e[c],c,e)}}function l0(e,t){if(Lo(e))return null;t=t.toLowerCase();const n=Object.keys(e);let r=n.length,o;for(;r-- >0;)if(o=n[r],t===o.toLowerCase())return o;return null}const Ui=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,c0=e=>!Ts(e)&&e!==Ui;function bf(){const{caseless:e,skipUndefined:t}=c0(this)&&this||{},n={},r=(o,u)=>{const a=e&&l0(n,u)||u;xa(n[a])&&xa(o)?n[a]=bf(n[a],o):xa(o)?n[a]=bf({},o):ys(o)?n[a]=o.slice():(!t||!Ts(o))&&(n[a]=o)};for(let o=0,u=arguments.length;o<u;o++)arguments[o]&&Fo(arguments[o],r);return n}const VS=(e,t,n,{allOwnKeys:r}={})=>(Fo(t,(o,u)=>{n&&yn(o)?e[u]=s0(o,n):e[u]=o},{allOwnKeys:r}),e),qS=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),YS=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},WS=(e,t,n,r)=>{let o,u,a;const c={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),u=o.length;u-- >0;)a=o[u],(!r||r(a,e,t))&&!c[a]&&(t[a]=e[a],c[a]=!0);e=n!==!1&&Tf(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},GS=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},KS=e=>{if(!e)return null;if(ys(e))return e;let t=e.length;if(!a0(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},QS=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&Tf(Uint8Array)),XS=(e,t)=>{const r=(e&&e[Ta]).call(e);let o;for(;(o=r.next())&&!o.done;){const u=o.value;t.call(e,u[0],u[1])}},JS=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},ZS=ir("HTMLFormElement"),ew=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),f0=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),tw=ir("RegExp"),d0=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Fo(n,(o,u)=>{let a;(a=t(o,u,e))!==!1&&(r[u]=a||o)}),Object.defineProperties(e,r)},nw=e=>{d0(e,(t,n)=>{if(yn(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(yn(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},rw=(e,t)=>{const n={},r=o=>{o.forEach(u=>{n[u]=!0})};return ys(e)?r(e):r(String(e).split(t)),n},iw=()=>{},sw=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function ow(e){return!!(e&&yn(e.append)&&e[o0]==="FormData"&&e[Ta])}const uw=e=>{const t=new Array(10),n=(r,o)=>{if(Do(r)){if(t.indexOf(r)>=0)return;if(Lo(r))return r;if(!("toJSON"in r)){t[o]=r;const u=ys(r)?[]:{};return Fo(r,(a,c)=>{const f=n(a,o+1);!Ts(f)&&(u[c]=f)}),t[o]=void 0,u}}return r};return n(e,0)},aw=ir("AsyncFunction"),lw=e=>e&&(Do(e)||yn(e))&&yn(e.then)&&yn(e.catch),h0=((e,t)=>e?setImmediate:t?((n,r)=>(Ui.addEventListener("message",({source:o,data:u})=>{o===Ui&&u===n&&r.length&&r.shift()()},!1),o=>{r.push(o),Ui.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",yn(Ui.postMessage)),cw=typeof queueMicrotask!="undefined"?queueMicrotask.bind(Ui):typeof process!="undefined"&&process.nextTick||h0,K={isArray:ys,isArrayBuffer:u0,isBuffer:Lo,isFormData:MS,isArrayBufferView:kS,isString:NS,isNumber:a0,isBoolean:OS,isObject:Do,isPlainObject:xa,isEmptyObject:IS,isReadableStream:US,isRequest:HS,isResponse:zS,isHeaders:jS,isUndefined:Ts,isDate:PS,isFile:RS,isBlob:LS,isRegExp:tw,isFunction:yn,isStream:FS,isURLSearchParams:BS,isTypedArray:QS,isFileList:DS,forEach:Fo,merge:bf,extend:VS,trim:$S,stripBOM:qS,inherits:YS,toFlatObject:WS,kindOf:ba,kindOfTest:ir,endsWith:GS,toArray:KS,forEachEntry:XS,matchAll:JS,isHTMLForm:ZS,hasOwnProperty:f0,hasOwnProp:f0,reduceDescriptors:d0,freezeMethods:nw,toObjectSet:rw,toCamelCase:ew,noop:iw,toFiniteNumber:sw,findKey:l0,global:Ui,isContextDefined:c0,isSpecCompliantForm:ow,toJSONObject:uw,isAsyncFn:aw,isThenable:lw,setImmediate:h0,asap:cw,isIterable:e=>e!=null&&yn(e[Ta])};function ze(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o,this.status=o.status?o.status:null)}K.inherits(ze,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:K.toJSONObject(this.config),code:this.code,status:this.status}}});const p0=ze.prototype,m0={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{m0[e]={value:e}}),Object.defineProperties(ze,m0),Object.defineProperty(p0,"isAxiosError",{value:!0}),ze.from=(e,t,n,r,o,u)=>{const a=Object.create(p0);K.toFlatObject(e,a,function(m){return m!==Error.prototype},h=>h!=="isAxiosError");const c=e&&e.message?e.message:"Error",f=t==null&&e?e.code:t;return ze.call(a,c,f,n,r,o),e&&a.cause==null&&Object.defineProperty(a,"cause",{value:e,configurable:!0}),a.name=e&&e.name||"Error",u&&Object.assign(a,u),a};const fw=null;function _f(e){return K.isPlainObject(e)||K.isArray(e)}function g0(e){return K.endsWith(e,"[]")?e.slice(0,-2):e}function E0(e,t,n){return e?e.concat(t).map(function(o,u){return o=g0(o),!n&&u?"["+o+"]":o}).join(n?".":""):t}function dw(e){return K.isArray(e)&&!e.some(_f)}const hw=K.toFlatObject(K,{},null,function(t){return/^is[A-Z]/.test(t)});function Sa(e,t,n){if(!K.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=K.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,C){return!K.isUndefined(C[S])});const r=n.metaTokens,o=n.visitor||m,u=n.dots,a=n.indexes,f=(n.Blob||typeof Blob!="undefined"&&Blob)&&K.isSpecCompliantForm(t);if(!K.isFunction(o))throw new TypeError("visitor must be a function");function h(_){if(_===null)return"";if(K.isDate(_))return _.toISOString();if(K.isBoolean(_))return _.toString();if(!f&&K.isBlob(_))throw new ze("Blob is not supported. Use a Buffer instead.");return K.isArrayBuffer(_)||K.isTypedArray(_)?f&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function m(_,S,C){let k=_;if(_&&!C&&typeof _=="object"){if(K.endsWith(S,"{}"))S=r?S:S.slice(0,-2),_=JSON.stringify(_);else if(K.isArray(_)&&dw(_)||(K.isFileList(_)||K.endsWith(S,"[]"))&&(k=K.toArray(_)))return S=g0(S),k.forEach(function(D,G){!(K.isUndefined(D)||D===null)&&t.append(a===!0?E0([S],G,u):a===null?S:S+"[]",h(D))}),!1}return _f(_)?!0:(t.append(E0(C,S,u),h(_)),!1)}const E=[],b=Object.assign(hw,{defaultVisitor:m,convertValue:h,isVisitable:_f});function T(_,S){if(!K.isUndefined(_)){if(E.indexOf(_)!==-1)throw Error("Circular reference detected in "+S.join("."));E.push(_),K.forEach(_,function(k,M){(!(K.isUndefined(k)||k===null)&&o.call(t,k,K.isString(M)?M.trim():M,S,b))===!0&&T(k,S?S.concat(M):[M])}),E.pop()}}if(!K.isObject(e))throw new TypeError("data must be an object");return T(e),t}function y0(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function xf(e,t){this._pairs=[],e&&Sa(e,this,t)}const T0=xf.prototype;T0.append=function(t,n){this._pairs.push([t,n])},T0.toString=function(t){const n=t?function(r){return t.call(this,r,y0)}:y0;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function pw(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function b0(e,t,n){if(!t)return e;const r=n&&n.encode||pw;K.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let u;if(o?u=o(t,n):u=K.isURLSearchParams(t)?t.toString():new xf(t,n).toString(r),u){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class _0{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){K.forEach(this.handlers,function(r){r!==null&&t(r)})}}const x0={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},mw={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:xf,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},Sf=typeof window!="undefined"&&typeof document!="undefined",wf=typeof navigator=="object"&&navigator||void 0,gw=Sf&&(!wf||["ReactNative","NativeScript","NS"].indexOf(wf.product)<0),Ew=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",yw=Sf&&window.location.href||"http://localhost",nn=U(U({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Sf,hasStandardBrowserEnv:gw,hasStandardBrowserWebWorkerEnv:Ew,navigator:wf,origin:yw},Symbol.toStringTag,{value:"Module"}))),mw);function Tw(e,t){return Sa(e,new nn.classes.URLSearchParams,U({visitor:function(n,r,o,u){return nn.isNode&&K.isBuffer(n)?(this.append(r,n.toString("base64")),!1):u.defaultVisitor.apply(this,arguments)}},t))}function bw(e){return K.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function _w(e){const t={},n=Object.keys(e);let r;const o=n.length;let u;for(r=0;r<o;r++)u=n[r],t[u]=e[u];return t}function S0(e){function t(n,r,o,u){let a=n[u++];if(a==="__proto__")return!0;const c=Number.isFinite(+a),f=u>=n.length;return a=!a&&K.isArray(o)?o.length:a,f?(K.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!c):((!o[a]||!K.isObject(o[a]))&&(o[a]=[]),t(n,r,o[a],u)&&K.isArray(o[a])&&(o[a]=_w(o[a])),!c)}if(K.isFormData(e)&&K.isFunction(e.entries)){const n={};return K.forEachEntry(e,(r,o)=>{t(bw(r),o,n,0)}),n}return null}function xw(e,t,n){if(K.isString(e))try{return(t||JSON.parse)(e),K.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Mo={transitional:x0,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,u=K.isObject(t);if(u&&K.isHTMLForm(t)&&(t=new FormData(t)),K.isFormData(t))return o?JSON.stringify(S0(t)):t;if(K.isArrayBuffer(t)||K.isBuffer(t)||K.isStream(t)||K.isFile(t)||K.isBlob(t)||K.isReadableStream(t))return t;if(K.isArrayBufferView(t))return t.buffer;if(K.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(u){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Tw(t,this.formSerializer).toString();if((c=K.isFileList(t))||r.indexOf("multipart/form-data")>-1){const f=this.env&&this.env.FormData;return Sa(c?{"files[]":t}:t,f&&new f,this.formSerializer)}}return u||o?(n.setContentType("application/json",!1),xw(t)):t}],transformResponse:[function(t){const n=this.transitional||Mo.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(K.isResponse(t)||K.isReadableStream(t))return t;if(t&&K.isString(t)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(t,this.parseReviver)}catch(c){if(a)throw c.name==="SyntaxError"?ze.from(c,ze.ERR_BAD_RESPONSE,this,null,this.response):c}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:nn.classes.FormData,Blob:nn.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};K.forEach(["delete","get","head","post","put","patch"],e=>{Mo.headers[e]={}});const Sw=K.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),ww=e=>{const t={};let n,r,o;return e&&e.split(`
3
- `).forEach(function(a){o=a.indexOf(":"),n=a.substring(0,o).trim().toLowerCase(),r=a.substring(o+1).trim(),!(!n||t[n]&&Sw[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},w0=Symbol("internals");function Bo(e){return e&&String(e).trim().toLowerCase()}function wa(e){return e===!1||e==null?e:K.isArray(e)?e.map(wa):String(e)}function Cw(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const Aw=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Cf(e,t,n,r,o){if(K.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!K.isString(t)){if(K.isString(r))return t.indexOf(r)!==-1;if(K.isRegExp(r))return r.test(t)}}function vw(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function kw(e,t){const n=K.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(o,u,a){return this[r].call(this,t,o,u,a)},configurable:!0})})}let Tn=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function u(c,f,h){const m=Bo(f);if(!m)throw new Error("header name must be a non-empty string");const E=K.findKey(o,m);(!E||o[E]===void 0||h===!0||h===void 0&&o[E]!==!1)&&(o[E||f]=wa(c))}const a=(c,f)=>K.forEach(c,(h,m)=>u(h,m,f));if(K.isPlainObject(t)||t instanceof this.constructor)a(t,n);else if(K.isString(t)&&(t=t.trim())&&!Aw(t))a(ww(t),n);else if(K.isObject(t)&&K.isIterable(t)){let c={},f,h;for(const m of t){if(!K.isArray(m))throw TypeError("Object iterator must return a key-value pair");c[h=m[0]]=(f=c[h])?K.isArray(f)?[...f,m[1]]:[f,m[1]]:m[1]}a(c,n)}else t!=null&&u(n,t,r);return this}get(t,n){if(t=Bo(t),t){const r=K.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return Cw(o);if(K.isFunction(n))return n.call(this,o,r);if(K.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Bo(t),t){const r=K.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Cf(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function u(a){if(a=Bo(a),a){const c=K.findKey(r,a);c&&(!n||Cf(r,r[c],c,n))&&(delete r[c],o=!0)}}return K.isArray(t)?t.forEach(u):u(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const u=n[r];(!t||Cf(this,this[u],u,t,!0))&&(delete this[u],o=!0)}return o}normalize(t){const n=this,r={};return K.forEach(this,(o,u)=>{const a=K.findKey(r,u);if(a){n[a]=wa(o),delete n[u];return}const c=t?vw(u):String(u).trim();c!==u&&delete n[u],n[c]=wa(o),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return K.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&K.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
4
- `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(o=>r.set(o)),r}static accessor(t){const r=(this[w0]=this[w0]={accessors:{}}).accessors,o=this.prototype;function u(a){const c=Bo(a);r[c]||(kw(o,a),r[c]=!0)}return K.isArray(t)?t.forEach(u):u(t),this}};Tn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),K.reduceDescriptors(Tn.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),K.freezeMethods(Tn);function Af(e,t){const n=this||Mo,r=t||n,o=Tn.from(r.headers);let u=r.data;return K.forEach(e,function(c){u=c.call(n,u,o.normalize(),t?t.status:void 0)}),o.normalize(),u}function C0(e){return!!(e&&e.__CANCEL__)}function bs(e,t,n){ze.call(this,e==null?"canceled":e,ze.ERR_CANCELED,t,n),this.name="CanceledError"}K.inherits(bs,ze,{__CANCEL__:!0});function A0(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ze("Request failed with status code "+n.status,[ze.ERR_BAD_REQUEST,ze.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function Nw(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Ow(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,u=0,a;return t=t!==void 0?t:1e3,function(f){const h=Date.now(),m=r[u];a||(a=h),n[o]=f,r[o]=h;let E=u,b=0;for(;E!==o;)b+=n[E++],E=E%e;if(o=(o+1)%e,o===u&&(u=(u+1)%e),h-a<t)return;const T=m&&h-m;return T?Math.round(b*1e3/T):void 0}}function Iw(e,t){let n=0,r=1e3/t,o,u;const a=(h,m=Date.now())=>{n=m,o=null,u&&(clearTimeout(u),u=null),e(...h)};return[(...h)=>{const m=Date.now(),E=m-n;E>=r?a(h,m):(o=h,u||(u=setTimeout(()=>{u=null,a(o)},r-E)))},()=>o&&a(o)]}const Ca=(e,t,n=3)=>{let r=0;const o=Ow(50,250);return Iw(u=>{const a=u.loaded,c=u.lengthComputable?u.total:void 0,f=a-r,h=o(f),m=a<=c;r=a;const E={loaded:a,total:c,progress:c?a/c:void 0,bytes:f,rate:h||void 0,estimated:h&&c&&m?(c-a)/h:void 0,event:u,lengthComputable:c!=null,[t?"download":"upload"]:!0};e(E)},n)},v0=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},k0=e=>(...t)=>K.asap(()=>e(...t)),Pw=nn.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,nn.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(nn.origin),nn.navigator&&/(msie|trident)/i.test(nn.navigator.userAgent)):()=>!0,Rw=nn.hasStandardBrowserEnv?{write(e,t,n,r,o,u){const a=[e+"="+encodeURIComponent(t)];K.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),K.isString(r)&&a.push("path="+r),K.isString(o)&&a.push("domain="+o),u===!0&&a.push("secure"),document.cookie=a.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Lw(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Dw(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function N0(e,t,n){let r=!Lw(t);return e&&(r||n==!1)?Dw(e,t):t}const O0=e=>e instanceof Tn?U({},e):e;function Hi(e,t){t=t||{};const n={};function r(h,m,E,b){return K.isPlainObject(h)&&K.isPlainObject(m)?K.merge.call({caseless:b},h,m):K.isPlainObject(m)?K.merge({},m):K.isArray(m)?m.slice():m}function o(h,m,E,b){if(K.isUndefined(m)){if(!K.isUndefined(h))return r(void 0,h,E,b)}else return r(h,m,E,b)}function u(h,m){if(!K.isUndefined(m))return r(void 0,m)}function a(h,m){if(K.isUndefined(m)){if(!K.isUndefined(h))return r(void 0,h)}else return r(void 0,m)}function c(h,m,E){if(E in t)return r(h,m);if(E in e)return r(void 0,h)}const f={url:u,method:u,data:u,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:c,headers:(h,m,E)=>o(O0(h),O0(m),E,!0)};return K.forEach(Object.keys(U(U({},e),t)),function(m){const E=f[m]||o,b=E(e[m],t[m],m);K.isUndefined(b)&&E!==c||(n[m]=b)}),n}const I0=e=>{const t=Hi({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:u,headers:a,auth:c}=t;if(t.headers=a=Tn.from(a),t.url=b0(N0(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),c&&a.set("Authorization","Basic "+btoa((c.username||"")+":"+(c.password?unescape(encodeURIComponent(c.password)):""))),K.isFormData(n)){if(nn.hasStandardBrowserEnv||nn.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(K.isFunction(n.getHeaders)){const f=n.getHeaders(),h=["content-type","content-length"];Object.entries(f).forEach(([m,E])=>{h.includes(m.toLowerCase())&&a.set(m,E)})}}if(nn.hasStandardBrowserEnv&&(r&&K.isFunction(r)&&(r=r(t)),r||r!==!1&&Pw(t.url))){const f=o&&u&&Rw.read(u);f&&a.set(o,f)}return t},Fw=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=I0(e);let u=o.data;const a=Tn.from(o.headers).normalize();let{responseType:c,onUploadProgress:f,onDownloadProgress:h}=o,m,E,b,T,_;function S(){T&&T(),_&&_(),o.cancelToken&&o.cancelToken.unsubscribe(m),o.signal&&o.signal.removeEventListener("abort",m)}let C=new XMLHttpRequest;C.open(o.method.toUpperCase(),o.url,!0),C.timeout=o.timeout;function k(){if(!C)return;const D=Tn.from("getAllResponseHeaders"in C&&C.getAllResponseHeaders()),q={data:!c||c==="text"||c==="json"?C.responseText:C.response,status:C.status,statusText:C.statusText,headers:D,config:e,request:C};A0(function(te){n(te),S()},function(te){r(te),S()},q),C=null}"onloadend"in C?C.onloadend=k:C.onreadystatechange=function(){!C||C.readyState!==4||C.status===0&&!(C.responseURL&&C.responseURL.indexOf("file:")===0)||setTimeout(k)},C.onabort=function(){C&&(r(new ze("Request aborted",ze.ECONNABORTED,e,C)),C=null)},C.onerror=function(G){const q=G&&G.message?G.message:"Network Error",B=new ze(q,ze.ERR_NETWORK,e,C);B.event=G||null,r(B),C=null},C.ontimeout=function(){let G=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const q=o.transitional||x0;o.timeoutErrorMessage&&(G=o.timeoutErrorMessage),r(new ze(G,q.clarifyTimeoutError?ze.ETIMEDOUT:ze.ECONNABORTED,e,C)),C=null},u===void 0&&a.setContentType(null),"setRequestHeader"in C&&K.forEach(a.toJSON(),function(G,q){C.setRequestHeader(q,G)}),K.isUndefined(o.withCredentials)||(C.withCredentials=!!o.withCredentials),c&&c!=="json"&&(C.responseType=o.responseType),h&&([b,_]=Ca(h,!0),C.addEventListener("progress",b)),f&&C.upload&&([E,T]=Ca(f),C.upload.addEventListener("progress",E),C.upload.addEventListener("loadend",T)),(o.cancelToken||o.signal)&&(m=D=>{C&&(r(!D||D.type?new bs(null,e,C):D),C.abort(),C=null)},o.cancelToken&&o.cancelToken.subscribe(m),o.signal&&(o.signal.aborted?m():o.signal.addEventListener("abort",m)));const M=Nw(o.url);if(M&&nn.protocols.indexOf(M)===-1){r(new ze("Unsupported protocol "+M+":",ze.ERR_BAD_REQUEST,e));return}C.send(u||null)})},Mw=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,o;const u=function(h){if(!o){o=!0,c();const m=h instanceof Error?h:this.reason;r.abort(m instanceof ze?m:new bs(m instanceof Error?m.message:m))}};let a=t&&setTimeout(()=>{a=null,u(new ze(`timeout ${t} of ms exceeded`,ze.ETIMEDOUT))},t);const c=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(h=>{h.unsubscribe?h.unsubscribe(u):h.removeEventListener("abort",u)}),e=null)};e.forEach(h=>h.addEventListener("abort",u));const{signal:f}=r;return f.unsubscribe=()=>K.asap(c),f}},Bw=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,o;for(;r<n;)o=r+t,yield e.slice(r,o),r=o},Uw=function(e,t){return Jc(this,null,function*(){try{for(var n=fx(Hw(e)),r,o,u;r=!(o=yield new Ur(n.next())).done;r=!1){const a=o.value;yield*Rm(Bw(a,t))}}catch(o){u=[o]}finally{try{r&&(o=n.return)&&(yield new Ur(o.call(n)))}finally{if(u)throw u[0]}}})},Hw=function(e){return Jc(this,null,function*(){if(e[Symbol.asyncIterator]){yield*Rm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new Ur(t.read());if(n)break;yield r}}finally{yield new Ur(t.cancel())}})},P0=(e,t,n,r)=>{const o=Uw(e,t);let u=0,a,c=h=>{a||(a=!0,r&&r(h))};return new ReadableStream({pull(h){return it(this,null,function*(){try{const{done:m,value:E}=yield o.next();if(m){c(),h.close();return}let b=E.byteLength;if(n){let T=u+=b;n(T)}h.enqueue(new Uint8Array(E))}catch(m){throw c(m),m}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})},R0=64*1024,{isFunction:Aa}=K,zw=(({Request:e,Response:t})=>({Request:e,Response:t}))(K.global),{ReadableStream:L0,TextEncoder:D0}=K.global,F0=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},jw=e=>{e=K.merge.call({skipUndefined:!0},zw,e);const{fetch:t,Request:n,Response:r}=e,o=t?Aa(t):typeof fetch=="function",u=Aa(n),a=Aa(r);if(!o)return!1;const c=o&&Aa(L0),f=o&&(typeof D0=="function"?(_=>S=>_.encode(S))(new D0):_=>it(null,null,function*(){return new Uint8Array(yield new n(_).arrayBuffer())})),h=u&&c&&F0(()=>{let _=!1;const S=new n(nn.origin,{body:new L0,method:"POST",get duplex(){return _=!0,"half"}}).headers.has("Content-Type");return _&&!S}),m=a&&c&&F0(()=>K.isReadableStream(new r("").body)),E={stream:m&&(_=>_.body)};o&&["text","arrayBuffer","blob","formData","stream"].forEach(_=>{!E[_]&&(E[_]=(S,C)=>{let k=S&&S[_];if(k)return k.call(S);throw new ze(`Response type '${_}' is not supported`,ze.ERR_NOT_SUPPORT,C)})});const b=_=>it(null,null,function*(){if(_==null)return 0;if(K.isBlob(_))return _.size;if(K.isSpecCompliantForm(_))return(yield new n(nn.origin,{method:"POST",body:_}).arrayBuffer()).byteLength;if(K.isArrayBufferView(_)||K.isArrayBuffer(_))return _.byteLength;if(K.isURLSearchParams(_)&&(_=_+""),K.isString(_))return(yield f(_)).byteLength}),T=(_,S)=>it(null,null,function*(){const C=K.toFiniteNumber(_.getContentLength());return C==null?b(S):C});return _=>it(null,null,function*(){let{url:S,method:C,data:k,signal:M,cancelToken:D,timeout:G,onDownloadProgress:q,onUploadProgress:B,responseType:te,headers:Te,withCredentials:Se="same-origin",fetchOptions:H}=I0(_),fe=t||fetch;te=te?(te+"").toLowerCase():"text";let de=Mw([M,D&&D.toAbortSignal()],G),ue=null;const ie=de&&de.unsubscribe&&(()=>{de.unsubscribe()});let ge;try{if(B&&h&&C!=="get"&&C!=="head"&&(ge=yield T(Te,k))!==0){let R=new n(S,{method:"POST",body:k,duplex:"half"}),Q;if(K.isFormData(k)&&(Q=R.headers.get("content-type"))&&Te.setContentType(Q),R.body){const[N,_e]=v0(ge,Ca(k0(B)));k=P0(R.body,R0,N,_e)}}K.isString(Se)||(Se=Se?"include":"omit");const we=u&&"credentials"in n.prototype,ae=ye(U({},H),{signal:de,method:C.toUpperCase(),headers:Te.normalize().toJSON(),body:k,duplex:"half",credentials:we?Se:void 0});ue=u&&new n(S,ae);let V=yield u?fe(ue,H):fe(S,ae);const ee=m&&(te==="stream"||te==="response");if(m&&(q||ee&&ie)){const R={};["status","statusText","headers"].forEach(Me=>{R[Me]=V[Me]});const Q=K.toFiniteNumber(V.headers.get("content-length")),[N,_e]=q&&v0(Q,Ca(k0(q),!0))||[];V=new r(P0(V.body,R0,N,()=>{_e&&_e(),ie&&ie()}),R)}te=te||"text";let w=yield E[K.findKey(E,te)||"text"](V,_);return!ee&&ie&&ie(),yield new Promise((R,Q)=>{A0(R,Q,{data:w,headers:Tn.from(V.headers),status:V.status,statusText:V.statusText,config:_,request:ue})})}catch(we){throw ie&&ie(),we&&we.name==="TypeError"&&/Load failed|fetch/i.test(we.message)?Object.assign(new ze("Network Error",ze.ERR_NETWORK,_,ue),{cause:we.cause||we}):ze.from(we,we&&we.code,_,ue)}})},$w=new Map,M0=e=>{let t=e?e.env:{};const{fetch:n,Request:r,Response:o}=t,u=[r,o,n];let a=u.length,c=a,f,h,m=$w;for(;c--;)f=u[c],h=m.get(f),h===void 0&&m.set(f,h=c?new Map:jw(t)),m=h;return h};M0();const vf={http:fw,xhr:Fw,fetch:{get:M0}};K.forEach(vf,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(n){}Object.defineProperty(e,"adapterName",{value:t})}});const B0=e=>`- ${e}`,Vw=e=>K.isFunction(e)||e===null||e===!1,U0={getAdapter:(e,t)=>{e=K.isArray(e)?e:[e];const{length:n}=e;let r,o;const u={};for(let a=0;a<n;a++){r=e[a];let c;if(o=r,!Vw(r)&&(o=vf[(c=String(r)).toLowerCase()],o===void 0))throw new ze(`Unknown adapter '${c}'`);if(o&&(K.isFunction(o)||(o=o.get(t))))break;u[c||"#"+a]=o}if(!o){const a=Object.entries(u).map(([f,h])=>`adapter ${f} `+(h===!1?"is not supported by the environment":"is not available in the build"));let c=n?a.length>1?`since :
5
- `+a.map(B0).join(`
6
- `):" "+B0(a[0]):"as no adapter specified";throw new ze("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return o},adapters:vf};function kf(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new bs(null,e)}function H0(e){return kf(e),e.headers=Tn.from(e.headers),e.data=Af.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),U0.getAdapter(e.adapter||Mo.adapter,e)(e).then(function(r){return kf(e),r.data=Af.call(e,e.transformResponse,r),r.headers=Tn.from(r.headers),r},function(r){return C0(r)||(kf(e),r&&r.response&&(r.response.data=Af.call(e,e.transformResponse,r.response),r.response.headers=Tn.from(r.response.headers))),Promise.reject(r)})}const z0="1.12.2",va={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{va[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const j0={};va.transitional=function(t,n,r){function o(u,a){return"[Axios v"+z0+"] Transitional option '"+u+"'"+a+(r?". "+r:"")}return(u,a,c)=>{if(t===!1)throw new ze(o(a," has been removed"+(n?" in "+n:"")),ze.ERR_DEPRECATED);return n&&!j0[a]&&(j0[a]=!0,console.warn(o(a," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(u,a,c):!0}},va.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function qw(e,t,n){if(typeof e!="object")throw new ze("options must be an object",ze.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const u=r[o],a=t[u];if(a){const c=e[u],f=c===void 0||a(c,u,e);if(f!==!0)throw new ze("option "+u+" must be "+f,ze.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ze("Unknown option "+u,ze.ERR_BAD_OPTION)}}const ka={assertOptions:qw,validators:va},xr=ka.validators;let zi=class{constructor(t){this.defaults=t||{},this.interceptors={request:new _0,response:new _0}}request(t,n){return it(this,null,function*(){try{return yield this._request(t,n)}catch(r){if(r instanceof Error){let o={};Error.captureStackTrace?Error.captureStackTrace(o):o=new Error;const u=o.stack?o.stack.replace(/^.+\n/,""):"";try{r.stack?u&&!String(r.stack).endsWith(u.replace(/^.+\n.+\n/,""))&&(r.stack+=`
7
- `+u):r.stack=u}catch(a){}}throw r}})}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Hi(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:u}=n;r!==void 0&&ka.assertOptions(r,{silentJSONParsing:xr.transitional(xr.boolean),forcedJSONParsing:xr.transitional(xr.boolean),clarifyTimeoutError:xr.transitional(xr.boolean)},!1),o!=null&&(K.isFunction(o)?n.paramsSerializer={serialize:o}:ka.assertOptions(o,{encode:xr.function,serialize:xr.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),ka.assertOptions(n,{baseUrl:xr.spelling("baseURL"),withXsrfToken:xr.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=u&&K.merge(u.common,u[n.method]);u&&K.forEach(["delete","get","head","post","put","patch","common"],_=>{delete u[_]}),n.headers=Tn.concat(a,u);const c=[];let f=!0;this.interceptors.request.forEach(function(S){typeof S.runWhen=="function"&&S.runWhen(n)===!1||(f=f&&S.synchronous,c.unshift(S.fulfilled,S.rejected))});const h=[];this.interceptors.response.forEach(function(S){h.push(S.fulfilled,S.rejected)});let m,E=0,b;if(!f){const _=[H0.bind(this),void 0];for(_.unshift(...c),_.push(...h),b=_.length,m=Promise.resolve(n);E<b;)m=m.then(_[E++],_[E++]);return m}b=c.length;let T=n;for(;E<b;){const _=c[E++],S=c[E++];try{T=_(T)}catch(C){S.call(this,C);break}}try{m=H0.call(this,T)}catch(_){return Promise.reject(_)}for(E=0,b=h.length;E<b;)m=m.then(h[E++],h[E++]);return m}getUri(t){t=Hi(this.defaults,t);const n=N0(t.baseURL,t.url,t.allowAbsoluteUrls);return b0(n,t.params,t.paramsSerializer)}};K.forEach(["delete","get","head","options"],function(t){zi.prototype[t]=function(n,r){return this.request(Hi(r||{},{method:t,url:n,data:(r||{}).data}))}}),K.forEach(["post","put","patch"],function(t){function n(r){return function(u,a,c){return this.request(Hi(c||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:u,data:a}))}}zi.prototype[t]=n(),zi.prototype[t+"Form"]=n(!0)});let Yw=class dx{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(u){n=u});const r=this;this.promise.then(o=>{if(!r._listeners)return;let u=r._listeners.length;for(;u-- >0;)r._listeners[u](o);r._listeners=null}),this.promise.then=o=>{let u;const a=new Promise(c=>{r.subscribe(c),u=c}).then(o);return a.cancel=function(){r.unsubscribe(u)},a},t(function(u,a,c){r.reason||(r.reason=new bs(u,a,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new dx(function(o){t=o}),cancel:t}}};function Ww(e){return function(n){return e.apply(null,n)}}function Gw(e){return K.isObject(e)&&e.isAxiosError===!0}const Nf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Nf).forEach(([e,t])=>{Nf[t]=e});function $0(e){const t=new zi(e),n=s0(zi.prototype.request,t);return K.extend(n,zi.prototype,t,{allOwnKeys:!0}),K.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return $0(Hi(e,o))},n}const Ot=$0(Mo);Ot.Axios=zi,Ot.CanceledError=bs,Ot.CancelToken=Yw,Ot.isCancel=C0,Ot.VERSION=z0,Ot.toFormData=Sa,Ot.AxiosError=ze,Ot.Cancel=Ot.CanceledError,Ot.all=function(t){return Promise.all(t)},Ot.spread=Ww,Ot.isAxiosError=Gw,Ot.mergeConfig=Hi,Ot.AxiosHeaders=Tn,Ot.formToJSON=e=>S0(K.isHTMLForm(e)?new FormData(e):e),Ot.getAdapter=U0.getAdapter,Ot.HttpStatusCode=Nf,Ot.default=Ot;const{Axios:uM,AxiosError:aM,CanceledError:lM,isCancel:cM,CancelToken:fM,VERSION:dM,all:hM,Cancel:pM,isAxiosError:mM,spread:gM,toFormData:EM,AxiosHeaders:yM,HttpStatusCode:TM,formToJSON:bM,getAdapter:_M,mergeConfig:xM}=Ot;class V0{constructor(t,n,r=!1){ke(this,"CIMULATE_API_HEADER","x-cimulate-api-key");ke(this,"CIMULATE_SEARCH_API_PATH","api/v1");ke(this,"baseApiUrl");ke(this,"headers",{});ke(this,"fetchConfig",()=>it(this,null,function*(){try{const t=yield Ot.get(`${this.apiUrl}/configs/copilot`,{headers:this.headers}),{customer_config:n}=t.data,r=atob(n);return JSON.parse(r)}catch(t){throw console.error("Error fetching customer config:",t),t}}));if(t&&n||!t&&!n)throw new Error("Provide exactly one authentication method: either 'apiKey' or 'apiToken', but not both.");t?this.headers[this.CIMULATE_API_HEADER]=t:n&&(this.headers.Authorization=`Bearer ${n}`),this.baseApiUrl=r?"https://staging.search.cimulate.ai":"https://prod.search.cimulate.ai"}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}const Kw=W.createContext(void 0),Qw=({apiKey:e,apiToken:t,isDevelopment:n=!1,children:r})=>{const o=W.useMemo(()=>new V0(e,t,n),[e,t,n]);return I.jsx(Kw.Provider,{value:o,children:r})};var q0=Symbol.for("immer-nothing"),Y0=Symbol.for("immer-draftable"),rt=Symbol.for("immer-state");function Vn(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var _s=Object.getPrototypeOf;function xs(e){return!!e&&!!e[rt]}function Hr(e){var t;return e?W0(e)||Array.isArray(e)||!!e[Y0]||!!((t=e.constructor)!=null&&t[Y0])||Oa(e)||Ia(e):!1}var Xw=Object.prototype.constructor.toString();function W0(e){if(!e||typeof e!="object")return!1;const t=_s(e);if(t===null)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object?!0:typeof n=="function"&&Function.toString.call(n)===Xw}function Uo(e,t){Na(e)===0?Reflect.ownKeys(e).forEach(n=>{t(n,e[n],e)}):e.forEach((n,r)=>t(r,n,e))}function Na(e){const t=e[rt];return t?t.type_:Array.isArray(e)?1:Oa(e)?2:Ia(e)?3:0}function Of(e,t){return Na(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function G0(e,t,n){const r=Na(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function Jw(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Oa(e){return e instanceof Map}function Ia(e){return e instanceof Set}function $t(e){return e.copy_||e.base_}function If(e,t){if(Oa(e))return new Map(e);if(Ia(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=W0(e);if(t===!0||t==="class_only"&&!n){const r=Object.getOwnPropertyDescriptors(e);delete r[rt];let o=Reflect.ownKeys(r);for(let u=0;u<o.length;u++){const a=o[u],c=r[a];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(r[a]={configurable:!0,writable:!0,enumerable:c.enumerable,value:e[a]})}return Object.create(_s(e),r)}else{const r=_s(e);if(r!==null&&n)return U({},e);const o=Object.create(r);return Object.assign(o,e)}}function Pf(e,t=!1){return Pa(e)||xs(e)||!Hr(e)||(Na(e)>1&&(e.set=e.add=e.clear=e.delete=Zw),Object.freeze(e),t&&Object.entries(e).forEach(([n,r])=>Pf(r,!0))),e}function Zw(){Vn(2)}function Pa(e){return Object.isFrozen(e)}var Rf={};function ji(e){const t=Rf[e];return t||Vn(0,e),t}function eC(e,t){Rf[e]||(Rf[e]=t)}var Ho;function Ra(){return Ho}function tC(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function K0(e,t){t&&(ji("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Lf(e){Df(e),e.drafts_.forEach(nC),e.drafts_=null}function Df(e){e===Ho&&(Ho=e.parent_)}function Q0(e){return Ho=tC(Ho,e)}function nC(e){const t=e[rt];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function X0(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[rt].modified_&&(Lf(t),Vn(4)),Hr(e)&&(e=La(t,e),t.parent_||Da(t,e)),t.patches_&&ji("Patches").generateReplacementPatches_(n[rt].base_,e,t.patches_,t.inversePatches_)):e=La(t,n,[]),Lf(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==q0?e:void 0}function La(e,t,n){if(Pa(t))return t;const r=t[rt];if(!r)return Uo(t,(o,u)=>J0(e,r,t,o,u,n)),t;if(r.scope_!==e)return t;if(!r.modified_)return Da(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const o=r.copy_;let u=o,a=!1;r.type_===3&&(u=new Set(o),o.clear(),a=!0),Uo(u,(c,f)=>J0(e,r,o,c,f,n,a)),Da(e,o,!1),n&&e.patches_&&ji("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function J0(e,t,n,r,o,u,a){if(xs(o)){const c=u&&t&&t.type_!==3&&!Of(t.assigned_,r)?u.concat(r):void 0,f=La(e,o,c);if(G0(n,r,f),xs(f))e.canAutoFreeze_=!1;else return}else a&&n.add(o);if(Hr(o)&&!Pa(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;La(e,o),(!t||!t.scope_.parent_)&&typeof r!="symbol"&&Object.prototype.propertyIsEnumerable.call(n,r)&&Da(e,o)}}function Da(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Pf(t,n)}function rC(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:Ra(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=r,u=Ff;n&&(o=[r],u=zo);const{revoke:a,proxy:c}=Proxy.revocable(o,u);return r.draft_=c,r.revoke_=a,c}var Ff={get(e,t){if(t===rt)return e;const n=$t(e);if(!Of(n,t))return iC(e,n,t);const r=n[t];return e.finalized_||!Hr(r)?r:r===Mf(e.base_,t)?(Bf(e),e.copy_[t]=jo(r,e)):r},has(e,t){return t in $t(e)},ownKeys(e){return Reflect.ownKeys($t(e))},set(e,t,n){const r=Z0($t(e),t);if(r!=null&&r.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const o=Mf($t(e),t),u=o==null?void 0:o[rt];if(u&&u.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(Jw(n,o)&&(n!==void 0||Of(e.base_,t)))return!0;Bf(e),zr(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return Mf(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Bf(e),zr(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=$t(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){Vn(11)},getPrototypeOf(e){return _s(e.base_)},setPrototypeOf(){Vn(12)}},zo={};Uo(Ff,(e,t)=>{zo[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),zo.deleteProperty=function(e,t){return zo.set.call(this,e,t,void 0)},zo.set=function(e,t,n){return Ff.set.call(this,e[0],t,n,e[0])};function Mf(e,t){const n=e[rt];return(n?$t(n):e)[t]}function iC(e,t,n){var o;const r=Z0(t,n);return r?"value"in r?r.value:(o=r.get)==null?void 0:o.call(e.draft_):void 0}function Z0(e,t){if(!(t in e))return;let n=_s(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=_s(n)}}function zr(e){e.modified_||(e.modified_=!0,e.parent_&&zr(e.parent_))}function Bf(e){e.copy_||(e.copy_=If(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var sC=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const u=n;n=t;const a=this;return function(f=u,...h){return a.produce(f,m=>n.call(this,m,...h))}}typeof n!="function"&&Vn(6),r!==void 0&&typeof r!="function"&&Vn(7);let o;if(Hr(t)){const u=Q0(this),a=jo(t,void 0);let c=!0;try{o=n(a),c=!1}finally{c?Lf(u):Df(u)}return K0(u,r),X0(o,u)}else if(!t||typeof t!="object"){if(o=n(t),o===void 0&&(o=t),o===q0&&(o=void 0),this.autoFreeze_&&Pf(o,!0),r){const u=[],a=[];ji("Patches").generateReplacementPatches_(t,o,u,a),r(u,a)}return o}else Vn(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(a,...c)=>this.produceWithPatches(a,f=>t(f,...c));let r,o;return[this.produce(t,n,(a,c)=>{r=a,o=c}),r,o]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){Hr(e)||Vn(8),xs(e)&&(e=oC(e));const t=Q0(this),n=jo(e,void 0);return n[rt].isManual_=!0,Df(t),n}finishDraft(e,t){const n=e&&e[rt];(!n||!n.isManual_)&&Vn(9);const{scope_:r}=n;return K0(r,t),X0(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const o=t[n];if(o.path.length===0&&o.op==="replace"){e=o.value;break}}n>-1&&(t=t.slice(n+1));const r=ji("Patches").applyPatches_;return xs(e)?r(e,t):this.produce(e,o=>r(o,t))}};function jo(e,t){const n=Oa(e)?ji("MapSet").proxyMap_(e,t):Ia(e)?ji("MapSet").proxySet_(e,t):rC(e,t);return(t?t.scope_:Ra()).drafts_.push(n),n}function oC(e){return xs(e)||Vn(10,e),eg(e)}function eg(e){if(!Hr(e)||Pa(e))return e;const t=e[rt];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=If(e,t.scope_.immer_.useStrictShallowCopy_)}else n=If(e,!0);return Uo(n,(r,o)=>{G0(n,r,eg(o))}),t&&(t.finalized_=!1),n}function uC(){class e extends Map{constructor(f,h){super(),this[rt]={type_:2,parent_:h,scope_:h?h.scope_:Ra(),modified_:!1,finalized_:!1,copy_:void 0,assigned_:void 0,base_:f,draft_:this,isManual_:!1,revoked_:!1}}get size(){return $t(this[rt]).size}has(f){return $t(this[rt]).has(f)}set(f,h){const m=this[rt];return a(m),(!$t(m).has(f)||$t(m).get(f)!==h)&&(n(m),zr(m),m.assigned_.set(f,!0),m.copy_.set(f,h),m.assigned_.set(f,!0)),this}delete(f){if(!this.has(f))return!1;const h=this[rt];return a(h),n(h),zr(h),h.base_.has(f)?h.assigned_.set(f,!1):h.assigned_.delete(f),h.copy_.delete(f),!0}clear(){const f=this[rt];a(f),$t(f).size&&(n(f),zr(f),f.assigned_=new Map,Uo(f.base_,h=>{f.assigned_.set(h,!1)}),f.copy_.clear())}forEach(f,h){const m=this[rt];$t(m).forEach((E,b,T)=>{f.call(h,this.get(b),b,this)})}get(f){const h=this[rt];a(h);const m=$t(h).get(f);if(h.finalized_||!Hr(m)||m!==h.base_.get(f))return m;const E=jo(m,h);return n(h),h.copy_.set(f,E),E}keys(){return $t(this[rt]).keys()}values(){const f=this.keys();return{[Symbol.iterator]:()=>this.values(),next:()=>{const h=f.next();return h.done?h:{done:!1,value:this.get(h.value)}}}}entries(){const f=this.keys();return{[Symbol.iterator]:()=>this.entries(),next:()=>{const h=f.next();if(h.done)return h;const m=this.get(h.value);return{done:!1,value:[h.value,m]}}}}[Symbol.iterator](){return this.entries()}}function t(c,f){return new e(c,f)}function n(c){c.copy_||(c.assigned_=new Map,c.copy_=new Map(c.base_))}class r extends Set{constructor(f,h){super(),this[rt]={type_:3,parent_:h,scope_:h?h.scope_:Ra(),modified_:!1,finalized_:!1,copy_:void 0,base_:f,draft_:this,drafts_:new Map,revoked_:!1,isManual_:!1}}get size(){return $t(this[rt]).size}has(f){const h=this[rt];return a(h),h.copy_?!!(h.copy_.has(f)||h.drafts_.has(f)&&h.copy_.has(h.drafts_.get(f))):h.base_.has(f)}add(f){const h=this[rt];return a(h),this.has(f)||(u(h),zr(h),h.copy_.add(f)),this}delete(f){if(!this.has(f))return!1;const h=this[rt];return a(h),u(h),zr(h),h.copy_.delete(f)||(h.drafts_.has(f)?h.copy_.delete(h.drafts_.get(f)):!1)}clear(){const f=this[rt];a(f),$t(f).size&&(u(f),zr(f),f.copy_.clear())}values(){const f=this[rt];return a(f),u(f),f.copy_.values()}entries(){const f=this[rt];return a(f),u(f),f.copy_.entries()}keys(){return this.values()}[Symbol.iterator](){return this.values()}forEach(f,h){const m=this.values();let E=m.next();for(;!E.done;)f.call(h,E.value,E.value,this),E=m.next()}}function o(c,f){return new r(c,f)}function u(c){c.copy_||(c.copy_=new Set,c.base_.forEach(f=>{if(Hr(f)){const h=jo(f,c);c.drafts_.set(f,h),c.copy_.add(h)}else c.copy_.add(f)}))}function a(c){c.revoked_&&Vn(3,JSON.stringify($t(c)))}eC("MapSet",{proxyMap_:t,proxySet_:o})}var In=new sC,aC=In.produce;In.produceWithPatches.bind(In),In.setAutoFreeze.bind(In),In.setUseStrictShallowCopy.bind(In),In.applyPatches.bind(In),In.createDraft.bind(In),In.finishDraft.bind(In);function lC(e,t,n){var r=W.useMemo(function(){return aC(e)},[e]);return W.useReducer(r,t,n)}const tg={PAGE_CHANGED:"page-changed",PAGE_SIZE_CHANGED:"page-size-changed",FACET_FILTERS_CHANGED:"facet-filters-changed",RANGE_FILTERS_CHANGED:"range-filters-changed",CATALOG_SEGMENT_CHANGED:"catalog-segment-changed",PRICEBOOKS_CHANGED:"pricebooks-changed"},bn={RESET_STATE:"RESET_STATE",RESET_COPILOT:"RESET_COPILOT",ADD_MESSAGE:"ADD_MESSAGE",SET_COPILOT:"SET_COPILOT",SET_CONNECTED:"SET_CONNECTED",ADD_LOADING_MESSAGE:"ADD_LOADING_MESSAGE",REMOVE_LOADING_MESSAGE:"REMOVE_LOADING_MESSAGE"},Fa={copilot:null,connected:!1,messages:[],groupedMessages:[],loadingMessages:new Set},$o="cimulate",Uf=`${$o}:pdp-update`,Hf=`${$o}:browse-update`,zf=`${$o}:search-update`,jf=`${$o}:ui-state-update`,$f=`${$o}:session-state`,jr=U({CONTEXT_UPDATED:"browse-context-updated",CATEGORY_ID_CHANGED:"category-id-changed"},tg),cC={"browse-context":jr.CONTEXT_UPDATED,categoryId:jr.CATEGORY_ID_CHANGED,page:jr.PAGE_CHANGED,pageSize:jr.PAGE_SIZE_CHANGED,includeFacets:jr.FACET_FILTERS_CHANGED,facetFilters:jr.FACET_FILTERS_CHANGED,rangeFilters:jr.RANGE_FILTERS_CHANGED,catalogSegment:jr.CATALOG_SEGMENT_CHANGED,pricebooks:jr.PRICEBOOKS_CHANGED},$r=U({SEARCH_CONTEXT_UPDATED:"search-context-updated",QUERY_CHANGED:"query-changed"},tg),fC={"search-context":$r.SEARCH_CONTEXT_UPDATED,query:$r.QUERY_CHANGED,page:$r.PAGE_CHANGED,pageSize:$r.PAGE_SIZE_CHANGED,includeFacets:$r.FACET_FILTERS_CHANGED,facetFilters:$r.FACET_FILTERS_CHANGED,rangeFilters:$r.RANGE_FILTERS_CHANGED,catalogSegment:$r.CATALOG_SEGMENT_CHANGED,pricebooks:$r.PRICEBOOKS_CHANGED},Z="cim-widget",Ss=`--${Z}`,$i={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd"},dC=(e=$i)=>({[`${Ss}-primary-color`]:e.primaryColor||$i.primaryColor,[`${Ss}-secondary-color`]:e.secondaryColor||$i.secondaryColor,[`${Ss}-font-color`]:e.fontColor||$i.fontColor,[`${Ss}-font-family`]:e.fontFamily||$i.fontFamily,[`${Ss}-background-color`]:e.backgroundColor||$i.backgroundColor,[`${Ss}-border-color`]:e.borderColor||$i.borderColor}),ai={RESET_CONVERSATION:"reset-conversation",GET_SESSION_INFORMATION:"get-session-information",GET_CONVERSATION_MESSAGES:"get-conversation-messages",LOAD_CONVERSATION:"load-conversation"},ng=W.createContext(null),rg=W.createContext(null);class hC{constructor(t,n,r=!1){ke(this,"apiService");ke(this,"config",null);ke(this,"getConfig",()=>it(this,null,function*(){if(this.config)return this.config;try{const t=yield this.apiService.fetchConfig();return this.config=t,this.config}catch(t){throw console.error("Failed to fetch customer config:",t),t}}));ke(this,"getPid",t=>this.getProductFieldValue(t,"pidCol"));ke(this,"getName",t=>this.getProductFieldValue(t,"nameCol"));ke(this,"getDescription",t=>this.getProductFieldValue(t,"description"));ke(this,"getBrand",t=>this.getProductFieldValue(t,"productBrandCol"));ke(this,"getPrice",t=>this.getProductFieldValue(t,"priceCol"));ke(this,"getRelativePdp",t=>this.getProductFieldValue(t,"relativePdpCol"));ke(this,"getPdp",t=>this.getProductFieldValue(t,"pdpCol"));ke(this,"getImage",t=>this.getProductFieldValue(t,"imageCol"));ke(this,"getProductHiddenFields",()=>{const t=this.getProductField("productHiddenFields");return Array.isArray(t)?t:[]});ke(this,"getProductField",t=>this.config?this.config[t]:"");ke(this,"getProductFieldValue",(t,n)=>{const r=this.getProductField(n);return r&&t[r]||""});this.apiService=new V0(t,n,r)}getPriceDisplay(t){const n=this.getPrice(t);return n?typeof n=="string"?n.includes("$")?n:`$${n}`:typeof n=="number"?new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}).format(n):n:""}}const ws=(e,t,n,...r)=>{if(!e)return;const o=["background: linear-gradient(90deg,rgba(253, 99, 99, 1) 0%, rgba(245, 139, 35, 1) 65%)","font-weight: bold","color: transparent","background-clip: text","text-fill-color: transparent"].join(";");console[t]("%c[cimulate-widget]",o,n,...r)};class pC{constructor(t=!1){ke(this,"isDevelopment");ke(this,"_log",(t,n,...r)=>{ws(this.isDevelopment,t,n,...r)});this.isDevelopment=t}log(t,...n){this._log("log",t,...n)}warn(t,...n){this._log("warn",t,...n)}error(t,...n){this._log("error",t,...n)}info(t,...n){this._log("info",t,...n)}debug(t,...n){this._log("debug",t,...n)}}const ig=W.createContext(null),mC=({logoUrl:e,headerText:t="Your Search Assistant",globalClassName:n="",searchPlaceholder:r,searchButtonLabel:o,resetConversationMessage:u="What products would you like to explore today?",apiKey:a,apiToken:c,theme:f,isDevelopment:h,children:m})=>{const E=W.useMemo(()=>new hC(a,c,h),[a,c,h]),b=W.useMemo(()=>new pC(h),[h]);W.useEffect(()=>{E.config||E.getConfig()},[E]);const T=W.useMemo(()=>dC(f),[f]),_=W.useMemo(()=>({configModule:E,logoUrl:e,headerText:t,globalClassName:n,themeVariables:T,logger:b,searchPlaceholder:r,searchButtonLabel:o,resetConversationMessage:u}),[E,e,t,n,r,o,u,b,T]);return I.jsx(ig.Provider,{value:_,children:m})},sr=()=>{const e=W.useContext(ig);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e};class gC{constructor(){ke(this,"initialState",{connected:!1,mode:"embedded",status:{type:"dialog",isOpen:!1},dialog:{position:"bottom-left"},modal:{isFullscreen:!1}});ke(this,"connectedProxy");ke(this,"modeProxy");ke(this,"statusProxy");ke(this,"dialogProxy");ke(this,"modalProxy",{isFullscreen:!1});ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>{if(!(n in t))throw new Error(`Property ${n} does not exist on UIState`);return TC(n,r),Reflect.set(t,n,r)});this.connectedProxy=new Proxy({connected:this.initialState.connected},{get:this._fullGet,set:this._fullSet}),this.modeProxy=new Proxy({mode:this.initialState.mode},{get:this._fullGet,set:this._fullSet}),this.statusProxy=new Proxy({type:this.initialState.status.type,isOpen:this.initialState.status.isOpen},{get:this._fullGet,set:this._fullSet}),this.dialogProxy=new Proxy({position:this.initialState.dialog.position},{get:this._fullGet,set:this._fullSet}),this.modalProxy=new Proxy({isFullscreen:this.initialState.modal.isFullscreen},{get:this._fullGet,set:this._fullSet})}get connected(){return this.connectedProxy.connected}get mode(){return this.modeProxy.mode}get isOpen(){return!!this.statusProxy.isOpen}get type(){return this.statusProxy.type}get position(){return this.dialogProxy.position}get state(){return{connected:this.connected,mode:this.mode,status:{type:this.type,isOpen:this.isOpen},dialog:{position:this.position},modal:{isFullscreen:this.modalProxy.isFullscreen}}}}const It=new gC,Cs=()=>It.connected,EC=e=>{window.addEventListener(jf,e)},yC=e=>{window.removeEventListener(jf,e)},TC=(e,t)=>{const n=new CustomEvent(jf,{detail:{property:e,value:t}});window.dispatchEvent(n)},bC=e=>{It.connectedProxy.connected=e},Ma=e=>{if(typeof e!="boolean"){It.statusProxy.isOpen=!It.statusProxy.isOpen;return}It.statusProxy.isOpen=e},sg=e=>{It.modalProxy.isFullscreen=e},Vf=e=>{if(!["chat","dialog","modal"].includes(e))throw new Error(`Invalid type: ${e}. Must be 'chat', 'dialog', or 'modal'.`);It.statusProxy.type=e,e==="dialog"||e==="chat"?It.modeProxy.mode="embedded":It.modeProxy.mode="standalone"},og=e=>{const t=["top","top-left","top-right","bottom","bottom-left","bottom-right","left","right","center"];if(!t.includes(e))throw new Error(`Invalid position: ${e}. Must be one of ${t.join(", ")}.`);It.dialogProxy.position=e},_C=({onCopilotEvent:e,children:t,dispatch:n})=>{const{logger:r}=sr(),o=W.useCallback(b=>{n({type:bn.SET_COPILOT,payload:b})},[n]),u=W.useCallback(b=>{bC(b),n({type:bn.SET_CONNECTED,payload:b})},[n]),a=W.useCallback(()=>{n({type:bn.RESET_COPILOT,payload:{}})},[n]),c=W.useCallback(()=>{n({type:bn.RESET_STATE,payload:{}})},[n]),f=W.useCallback(b=>{r==null||r.log(`${b.name} event received`,b),n({type:bn.ADD_MESSAGE,payload:b}),e==null||e(b)},[e,r,n]),h=W.useCallback(b=>{n({type:bn.ADD_LOADING_MESSAGE,payload:b})},[n]),m=W.useCallback(b=>{n({type:bn.REMOVE_LOADING_MESSAGE,payload:b})},[n]),E=W.useMemo(()=>({setCopilot:o,setConnected:u,resetCopilot:a,resetCopilotState:c,addCopilotEvent:f,addLoadingMessage:h,removeLoadingMessage:m}),[o,u,a,c,f,h,m]);return I.jsx(rg.Provider,{value:E,children:t})};uC();const xC=(e,t)=>{const{type:n,payload:r}=t;if(n===bn.ADD_MESSAGE){const o=r;if(e.messages.push(o),o.eventSourceId){const u=e.groupedMessages.findIndex(a=>a.eventSourceId===o.eventSourceId);if(u!==-1){let a=e.groupedMessages[u].messages;a||(a=[]);const c=a.findIndex(f=>f.id===o.id);if(c!==-1){a[c]=o;return}a.push(o);return}else{e.groupedMessages.push({type:"group",eventSourceId:o.eventSourceId,messages:[o],createdAt:new Date(o.createdAt)});return}}e.groupedMessages.push({type:"individual",message:o,createdAt:new Date(o.createdAt)});return}switch(n){case bn.RESET_STATE:e.messages=Fa.messages,e.groupedMessages=Fa.groupedMessages,e.loadingMessages=Fa.loadingMessages;break;case bn.RESET_COPILOT:e.copilot=null;break;case bn.SET_COPILOT:e.copilot=r;break;case bn.SET_CONNECTED:e.connected=r;break;case bn.ADD_LOADING_MESSAGE:e.loadingMessages.add(r);break;case bn.REMOVE_LOADING_MESSAGE:e.loadingMessages.delete(r);break}},SC=({onCopilotEvent:e,children:t})=>{const[n,r]=lC(xC,Fa);return I.jsx(ng.Provider,{value:n,children:I.jsx(_C,{onCopilotEvent:e,dispatch:r,children:t})})};function wC(){var e=W.useRef(!0);return e.current?(e.current=!1,!0):e.current}var CC=function(e){W.useEffect(e,[])},AC=function(e,t){return e===t};function vC(e,t){t===void 0&&(t=AC);var n=W.useRef(),r=W.useRef(e),o=wC();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}class kC{constructor(){ke(this,"items",[]);ke(this,"add",t=>{this.items.push(t)});ke(this,"remove",()=>this.items.shift());ke(this,"first",()=>this.items.length>0?this.items[0]:null);ke(this,"processQueue",t=>{new Array(or.size).fill(1).forEach(()=>{const r=or.first();r&&(t(r),or.remove())})})}get size(){return this.items.length}}const or=new kC,ug=e=>{window.addEventListener(zf,e)},ag=e=>{window.removeEventListener(zf,e)},NC=(e,t,n)=>{const r=new CustomEvent(zf,{detail:{event:e,property:t,value:n}});window.dispatchEvent(r)},lg=e=>{window.addEventListener(Hf,e)},cg=e=>{window.removeEventListener(Hf,e)},OC=(e,t,n)=>{const r=new CustomEvent(Hf,{detail:{event:e,property:t,value:n}});window.dispatchEvent(r)},fg=e=>{window.addEventListener(Uf,e)},dg=e=>{window.removeEventListener(Uf,e)},hg=(e,t,n)=>{const r=new CustomEvent(Uf,{detail:{property:e,value:t,event:n}});window.dispatchEvent(r)},IC=e=>{window.addEventListener($f,e)},PC=e=>{window.removeEventListener($f,e)},Ba=(e,t,n)=>{const r=new CustomEvent($f,{detail:{property:e,value:t,event:n}});window.dispatchEvent(r)};class RC{constructor(){ke(this,"initialParams",{categoryId:"",page:null,pageSize:null,includeFacets:!0,facetFilters:{},rangeFilters:[],catalogSegment:null,pricebooks:null});ke(this,"categoryIdProxy");ke(this,"facetFiltersProxy");ke(this,"rangeFiltersProxy");ke(this,"catalogSegmentProxy");ke(this,"pricebooksProxy");ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>{const o=cC[n];return OC(o,n,r),Reflect.set(t,n,r)});ke(this,"updateFacetFiltersProxy",t=>new Proxy({facetFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updateRangeFiltersProxy",t=>new Proxy({rangeFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updatePricebooksProxy",t=>new Proxy({pricebooks:t},{get:this._fullGet,set:this._fullSet}));this.categoryIdProxy=new Proxy({categoryId:this.initialParams.categoryId},{get:this._fullGet,set:this._fullSet}),this.facetFiltersProxy=this.updateFacetFiltersProxy(this.initialParams.facetFilters||{}),this.rangeFiltersProxy=this.updateRangeFiltersProxy(this.initialParams.rangeFilters||[]),this.catalogSegmentProxy=new Proxy({catalogSegment:this.initialParams.catalogSegment},{get:this._fullGet,set:this._fullSet}),this.pricebooksProxy=this.updatePricebooksProxy(this.initialParams.pricebooks||null)}get categoryId(){return this.categoryIdProxy.categoryId||""}get facetFilters(){return this.facetFiltersProxy.facetFilters||{}}get rangeFilters(){return this.rangeFiltersProxy.rangeFilters||[]}get catalogSegment(){return this.catalogSegmentProxy.catalogSegment||null}get pricebooks(){return this.pricebooksProxy.pricebooks||null}get state(){return{categoryId:this.categoryId,facetFilters:this.facetFilters,rangeFilters:this.rangeFilters,catalogSegment:this.catalogSegment,pricebooks:this.pricebooks,page:this.initialParams.page,pageSize:this.initialParams.pageSize,includeFacets:this.initialParams.includeFacets}}}const mt=new RC,As={categoryId:mt.categoryId,facetFilters:mt.facetFilters,rangeFilters:mt.rangeFilters,catalogSegment:mt.catalogSegment,pricebooks:mt.pricebooks},pg=W.createContext(As),LC=({children:e})=>{const[t,n]=W.useState(As.categoryId),[r,o]=W.useState(As.facetFilters),[u,a]=W.useState(As.rangeFilters),[c,f]=W.useState(As.catalogSegment),[h,m]=W.useState(As.pricebooks);W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="categoryId"&&n(T.value),(T==null?void 0:T.property)==="facetFilters"&&o(T.value),(T==null?void 0:T.property)==="rangeFilters"&&a(T.value),(T==null?void 0:T.property)==="catalogSegment"&&f(T.value),(T==null?void 0:T.property)==="pricebooks"&&m(T.value)};return lg(b),()=>{cg(b)}},[]);const E=W.useMemo(()=>({categoryId:t,facetFilters:r,rangeFilters:u,catalogSegment:c,pricebooks:h}),[t,r,u,c,h]);return I.jsx(pg.Provider,{value:E,children:e})},DC=()=>{const e=W.useContext(pg);if(!e)throw new Error("useBrowse must be used within a BrowseProvider");return e},mg=(e,t)=>{const n=t.updateFacetFiltersProxy(e);t.facetFiltersProxy.facetFilters=n.facetFilters},gg=(e,t,n)=>{var a,c;const r=U({},((a=n.facetFiltersProxy)==null?void 0:a.facetFilters)||{});if(!!((c=r[e])!=null&&c.includes(t))){const f=r[e].filter(h=>h!==t);f.length>0?r[e]=f:delete r[e]}else r[e]=r[e]?[...r[e],t]:[t];const u=n.updateFacetFiltersProxy(r);n.facetFiltersProxy.facetFilters=u.facetFilters},Eg=(e,t)=>{const n=t.updateRangeFiltersProxy(e);t.rangeFiltersProxy.rangeFilters=n.rangeFilters},yg=({field:e,value:t},n)=>{const[r,o]=Array.isArray(t)?t:[];if(typeof r=="undefined"||typeof o=="undefined")throw new Error("Range values must be an array with two numbers for min and max");const u=[...n.rangeFiltersProxy.rangeFilters||[]],a=u.findIndex(f=>f.field===e);if(a!==-1){u[a]={field:e,min:r,max:o},n.rangeFiltersProxy.rangeFilters=u;return}u.push({field:e,min:r,max:o});const c=n.updateRangeFiltersProxy(u);n.rangeFiltersProxy.rangeFilters=c.rangeFilters},Tg=(e,t)=>{t.catalogSegmentProxy.catalogSegment=e},bg=(e,t)=>{const n=t.updatePricebooksProxy(e);t.pricebooksProxy.pricebooks=n.pricebooks},FC=Object.freeze(Object.defineProperty({__proto__:null,setSearchContext:e=>{if(!e||!e.query)throw new Error("Search context must include a query");"facetFilters"in e&&(gt.facetFiltersProxy.facetFilters=e.facetFilters||{}),"rangeFilters"in e&&(gt.rangeFiltersProxy.rangeFilters=e.rangeFilters||[]),"catalogSegment"in e&&(gt.catalogSegmentProxy.catalogSegment=e.catalogSegment||null),"pricebooks"in e&&(gt.pricebooksProxy.pricebooks=e.pricebooks||null),gt.queryProxy.query=e.query,Cs()||or.add({context:"search",payload:U({},gt.state)})},updateCatalogSegment:e=>{Tg(e,gt)},updateFacetFilter:(e,t)=>{gg(e,t,gt)},updateFacetFilters:e=>{mg(e,gt)},updatePricebooks:e=>{bg(e,gt)},updateRangeFilter:({field:e,value:t})=>{yg({field:e,value:t},gt)},updateRangeFilters:e=>{Eg(e,gt)},updateSearchQuery:e=>{gt.queryProxy.query=e,Cs()||or.add({context:"search",payload:U({},gt.state)})}},Symbol.toStringTag,{value:"Module"})),MC=Object.freeze(Object.defineProperty({__proto__:null,setBrowseContext:e=>{if(!e||!e.categoryId)throw new Error("Browse context must include a categoryId");"facetFilters"in e&&(mt.facetFiltersProxy.facetFilters=e.facetFilters||{}),"rangeFilters"in e&&(mt.rangeFiltersProxy.rangeFilters=e.rangeFilters||[]),"catalogSegment"in e&&(mt.catalogSegmentProxy.catalogSegment=e.catalogSegment||null),"pricebooks"in e&&(mt.pricebooksProxy.pricebooks=e.pricebooks||null),mt.categoryIdProxy.categoryId=e.categoryId,Cs()||or.add({context:"browse",payload:U({},mt.state)})},updateBrowseCategoryId:e=>{mt.categoryIdProxy.categoryId=e,Cs()||or.add({context:"browse",payload:U({},mt.state)})},updateCatalogSegment:e=>{Tg(e,mt)},updateFacetFilter:(e,t)=>{gg(e,t,mt)},updateFacetFilters:e=>{mg(e,mt)},updatePricebooks:e=>{bg(e,mt)},updateRangeFilter:({field:e,value:t})=>{yg({field:e,value:t},mt)},updateRangeFilters:e=>{Eg(e,mt)}},Symbol.toStringTag,{value:"Module"}));class BC{constructor(){ke(this,"initialParams",{productId:"",pdpLink:""});ke(this,"proxy");ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>(hg(n,r),Reflect.set(t,n,r)));ke(this,"updateProxy",t=>{t.productId&&(this.proxy=new Proxy({productId:t.productId,pdpLink:t.pdpLink||""},{get:this._fullGet,set:this._fullSet}))});this.proxy=new Proxy({productId:this.initialParams.productId,pdpLink:this.initialParams.pdpLink},{get:this._fullGet,set:this._fullSet})}get productId(){return this.proxy.productId}get pdpLink(){return this.proxy.pdpLink}get state(){return{productId:this.productId,pdpLink:this.pdpLink}}}const Vr=new BC,UC=e=>{if(!e||!e.productId)throw new Error("PDP context must include a productId");Vr.updateProxy(e),hg("pdp-context",e),Cs()||or.add({context:"pdp",payload:U({},Vr.state)})},HC=e=>{Vr.proxy.productId=e,Cs()||or.add({context:"pdp",payload:U({},Vr.state)})},zC=e=>{Vr.proxy.pdpLink=e},jC=Object.freeze(Object.defineProperty({__proto__:null,getConversationMessages:({payload:e,callback:t})=>{Ba("getConversationMessages",{payload:e,callback:t},ai.GET_CONVERSATION_MESSAGES)},getSessionInformation:e=>{Ba("getSessionInformation",{callback:e},ai.GET_SESSION_INFORMATION)},loadConversation:e=>{Ba("loadConversation",e,ai.LOAD_CONVERSATION)},resetConversation:()=>{Ba("resetConversation",!0,ai.RESET_CONVERSATION)}},Symbol.toStringTag,{value:"Module"}));class $C{constructor(){ke(this,"initialParams",{query:"",page:null,pageSize:null,includeFacets:!0,facetFilters:{},rangeFilters:[],catalogSegment:null,pricebooks:null});ke(this,"queryProxy");ke(this,"facetFiltersProxy");ke(this,"rangeFiltersProxy");ke(this,"catalogSegmentProxy");ke(this,"pricebooksProxy");ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>{const o=fC[n];return NC(o,n,r),Reflect.set(t,n,r)});ke(this,"updateFacetFiltersProxy",t=>new Proxy({facetFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updateRangeFiltersProxy",t=>new Proxy({rangeFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updatePricebooksProxy",t=>new Proxy({pricebooks:t},{get:this._fullGet,set:this._fullSet}));this.queryProxy=new Proxy({query:this.initialParams.query},{get:this._fullGet,set:this._fullSet}),this.facetFiltersProxy=this.updateFacetFiltersProxy(this.initialParams.facetFilters||{}),this.rangeFiltersProxy=this.updateRangeFiltersProxy(this.initialParams.rangeFilters||[]),this.catalogSegmentProxy=new Proxy({catalogSegment:this.initialParams.catalogSegment},{get:this._fullGet,set:this._fullSet}),this.pricebooksProxy=this.updatePricebooksProxy(this.initialParams.pricebooks||null)}get query(){return this.queryProxy.query||""}get facetFilters(){return this.facetFiltersProxy.facetFilters||{}}get rangeFilters(){return this.rangeFiltersProxy.rangeFilters||[]}get catalogSegment(){return this.catalogSegmentProxy.catalogSegment||null}get pricebooks(){return this.pricebooksProxy.pricebooks||null}get state(){return{query:this.query,facetFilters:this.facetFilters,rangeFilters:this.rangeFilters,catalogSegment:this.catalogSegment,pricebooks:this.pricebooks,page:this.initialParams.page,pageSize:this.initialParams.pageSize,includeFacets:this.initialParams.includeFacets}}}const gt=new $C,vs={searchQuery:gt.query,facetFilters:gt.facetFilters,rangeFilters:gt.rangeFilters,catalogSegment:gt.catalogSegment,pricebooks:gt.pricebooks},_g=W.createContext(vs),VC=({children:e})=>{const[t,n]=W.useState(vs.searchQuery),[r,o]=W.useState(vs.facetFilters),[u,a]=W.useState(vs.rangeFilters),[c,f]=W.useState(vs.catalogSegment),[h,m]=W.useState(vs.pricebooks);W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="query"&&n(T.value),(T==null?void 0:T.property)==="facetFilters"&&o(T.value),(T==null?void 0:T.property)==="rangeFilters"&&a(T.value),(T==null?void 0:T.property)==="catalogSegment"&&f(T.value),(T==null?void 0:T.property)==="pricebooks"&&m(T.value)};return ug(b),()=>{ag(b)}},[]);const E=W.useMemo(()=>({searchQuery:t,facetFilters:r,rangeFilters:u,catalogSegment:c,pricebooks:h}),[t,r,u,c,h]);return I.jsx(_g.Provider,{value:E,children:e})},qC=()=>{const e=W.useContext(_g);if(!e)throw new Error("useSearch must be used within a SearchProvider");return e},xg=()=>{const e=W.useContext(rg);if(!e)throw new Error("useCopilotDispatch must be used within a CopilotProvider");return e},Sg=()=>{const e=W.useContext(ng);if(!e)throw new Error("useCopilotState must be used within a CopilotProvider");return e},wg=W.createContext({copilot:null,messages:[],groupedMessages:[],isLoading:!1,isResponseLoading:()=>!1,handleSearch:()=>{},handleBrowse:()=>{},handlePdp:()=>{},handleSuggestion:()=>{},handleUserInput:()=>{},handleCancel:()=>{},resetConversation:()=>{},getSessionInformation:()=>{},getConversationMessages:()=>{}}),YC=({apiKey:e,apiToken:t,baseUrl:n,isDevelopment:r,onConnect:o,onRefinedSearch:u,onRefinedBrowse:a,children:c})=>{const{logger:f}=sr(),Je=qC(),{searchQuery:h}=Je,m=Xt(Je,["searchQuery"]),xt=DC(),{categoryId:E}=xt,b=Xt(xt,["categoryId"]),{setCopilot:T,setConnected:_,resetCopilot:S,resetCopilotState:C,addCopilotEvent:k,addLoadingMessage:M,removeLoadingMessage:D}=xg(),{connected:G,copilot:q,messages:B,groupedMessages:te,loadingMessages:Te}=Sg(),Se=W.useRef(!1),H=W.useRef(!1),fe=W.useMemo(()=>Te.size>0,[Te]),de=W.useCallback(be=>Te.has(be),[Te]),ue=W.useCallback(be=>{k(be),M(be.id)},[k,M]),ie=W.useCallback(({query:be,facetFilters:He,rangeFilters:tt,catalogSegment:Tt,pricebooks:St,userPrompt:un,isUserAction:Wt})=>{if(!q){f==null||f.error("Copilot is not initialized");return}if(!be)return;const Rt={searchParams:{query:be}};un&&(Rt.userPrompt=un),He&&Object.keys(He).length>0&&(Rt.searchParams.facetFilters=He),tt&&tt.length>0&&(Rt.searchParams.rangeFilters=tt),Tt&&(Rt.searchParams.catalogSegment=Tt),St&&(Rt.searchParams.pricebooks=St);const Mn=!Se.current;q.search(Rt,ft=>{const vt=U({},ft);Mn&&(vt.isInitial=!0,vt.isUserAction=!0),Wt&&(vt.isUserAction=Wt),Se.current=!0,ue(vt)})},[f,ue,q]),ge=W.useCallback(({categoryId:be,facetFilters:He,rangeFilters:tt,catalogSegment:Tt,pricebooks:St,userPrompt:un,isUserAction:Wt})=>{if(!q){f==null||f.error("Copilot is not initialized");return}if(!be)return;const Rt={browseParams:{categoryId:be}};un&&(Rt.userPrompt=un),He&&Object.keys(He).length>0&&(Rt.browseParams.facetFilters=He),tt&&tt.length>0&&(Rt.browseParams.rangeFilters=tt),Tt&&(Rt.browseParams.catalogSegment=Tt),St&&(Rt.browseParams.pricebooks=St);const Mn=!H.current;q.browse(Rt,ft=>{const vt=U({},ft);Mn&&(vt.isInitial=!0,vt.isUserAction=!0),Wt&&(vt.isUserAction=Wt),H.current=!0,ue(vt)})},[f,ue,q]),we=W.useCallback(({productId:be,pdpLink:He,userPrompt:tt,isUserAction:Tt})=>{if(!q){f==null||f.error("Copilot is not initialized");return}if(!be)return;const St={productId:be};tt&&(St.userPrompt=tt),He&&(St.pdpLink=He),q.productView(St,un=>{const Wt=U({},un);Tt&&(Wt.isUserAction=Tt),ue(Wt)})},[f,q,ue]),ae=W.useCallback(be=>{const He=ye(U({},be),{id:be.inquiryLinkId||be.id});k(He)},[k]),V=W.useCallback(be=>{k(be),u==null||u(be)},[k,u]),ee=W.useCallback(be=>{k(be),a==null||a(be)},[k,a]),w=W.useCallback(be=>{o==null||o(be),_(!0)},[o,_]);W.useEffect(()=>{!q||!G||or.size>0&&or.processQueue(be=>{if(be.context==="search"){const He=ye(U({},be.payload),{isUserAction:!0});ie(He)}if(be.context==="browse"){const He=ye(U({},be.payload),{isUserAction:!0});ge(He)}if(be.context==="pdp"){const He=ye(U({},be.payload),{isUserAction:!0});we(He)}})},[q,G,ie,ge,we]);const R=W.useCallback(be=>{q&&q.requestSessionInformation(He=>{f==null||f.log("Retrieved session information: ",He),be==null||be(He)})},[q,f]),Q=W.useCallback((be,He)=>{q&&be.conversationId&&q.getConversationEvents(be,tt=>{f==null||f.log("Retrieved conversation messages: ",tt),He(tt)})},[q,f]),N=W.useCallback(be=>{be.on("connect_ack",w),be.on("follow_up",k),be.on("inquiry",ae),be.on("partial_inquiry",ae),be.on("display_products",k),be.on("progress",k),be.on("refined_search",V),be.on("refined_browse",ee),be.on("done",He=>{D(He.eventSourceId)}),be.on("error",He=>{k(He),D(He.eventSourceId)}),be.onDisconnect(He=>{const tt=["io server disconnect","transport error","server shutting down"];if(f==null||f.log("Connection disconnected with reason: ",He),!tt.includes(He)){_(!1);return}f==null||f.log("De-registering event listeners");const Tt=new Date().toISOString();k({name:"error",message:"Connection was lost. Please try again.",createdAt:Tt,id:`error-${Tt}`,sessionId:"session"}),be.off()})},[f,_,D,ae,V,ee,k,w]);CC(()=>{let be;n?be=n:be=r?"https://staging.copilot.search.cimulate.ai":"https://prod.copilot.search.cimulate.ai";const He={baseUrl:be};e?He.apiKey=e:t&&(He.apiToken=t);const tt=new AS(He);return T(tt),N(tt),tt.connect(),tt.requestSessionInformation(Tt=>{f==null||f.log("Session Information: ",Tt)}),()=>{tt.disconnect(),tt.off(),S()}});const _e=W.useCallback(be=>{if(!q)return;const He={eventId:be,reason:"User cancelled the request"};q.cancelRequest(He,tt=>{k(tt),D(be)})},[k,D,q]),Me=W.useCallback(()=>{q&&q.conversationReset({},be=>{C(),k(be),q.requestSessionInformation(He=>{f==null||f.log("Session Information: ",He)})})},[q,f,k,C]),Ie=W.useCallback(be=>{!be||!h||ie(ye(U({query:h},m),{userPrompt:be}))},[h,m,ie]),Ye=W.useCallback((be,He)=>{var un,Rt;const Tt=be.params.userPrompt||"";if(!Tt)return;const St=B.find(ft=>ft.id===He);if(St){if(St.name==="copilot_search"){const Wt=((un=St.request)==null?void 0:un.searchParams)||{},{query:ft}=Wt,vt=Xt(Wt,["query"]);ft&&ie(ye(U(U({query:ft||h},m),vt),{userPrompt:Tt}));return}if(St.name==="copilot_browse"){const Mn=((Rt=St.request)==null?void 0:Rt.browseParams)||{},{categoryId:ft}=Mn,vt=Xt(Mn,["categoryId"]);if(ft){ge(ye(U(U({categoryId:ft||E},b),vt),{userPrompt:Tt}));return}}if(St.name==="product_view"){const ft=St.request;ft!=null&&ft.productId&&we(ye(U({},ft),{userPrompt:Tt}))}}},[h,m,E,b,B,ie,ge,we]),Ve=W.useMemo(()=>({copilot:q,messages:B,groupedMessages:te,isLoading:fe,isResponseLoading:de,handleSearch:ie,handleBrowse:ge,handlePdp:we,handleUserInput:Ie,handleSuggestion:Ye,handleCancel:_e,resetConversation:Me,getSessionInformation:R,getConversationMessages:Q}),[q,B,te,fe,de,ie,ge,we,Ie,Ye,_e,Me,R,Q]);return I.jsx(wg.Provider,{value:Ve,children:c})},li=()=>{const e=W.useContext(wg);if(!e)throw new Error("useCopilot must be used within a CopilotProvider");return e},WC=()=>{const{resetCopilotState:e,addCopilotEvent:t}=xg(),{copilot:n,handleSearch:r,handleBrowse:o,handlePdp:u,resetConversation:a,getSessionInformation:c,getConversationMessages:f}=li(),h=W.useCallback(({query:b,isUserAction:T})=>{if(!n||!b)return;const{facetFilters:_}=gt.facetFiltersProxy,{rangeFilters:S}=gt.rangeFiltersProxy,{catalogSegment:C}=gt.catalogSegmentProxy,{pricebooks:k}=gt.pricebooksProxy,M={query:b};_&&Object.keys(_).length>0&&(M.facetFilters=_),S&&S.length>0&&(M.rangeFilters=S),C&&(M.catalogSegment=C),k&&(M.pricebooks=k),r(ye(U({},M),{isUserAction:T}))},[n,r]),m=W.useCallback(({categoryId:b,isUserAction:T})=>{if(!n||!b)return;const{facetFilters:_}=mt.facetFiltersProxy,{rangeFilters:S}=mt.rangeFiltersProxy,{catalogSegment:C}=mt.catalogSegmentProxy,{pricebooks:k}=mt.pricebooksProxy,M={categoryId:b};_&&Object.keys(_).length>0&&(M.facetFilters=_),S&&S.length>0&&(M.rangeFilters=S),C&&(M.catalogSegment=C),k&&(M.pricebooks=k),o(ye(U({},M),{isUserAction:T}))},[n,o]),E=W.useCallback(({productId:b,isUserAction:T})=>{if(!n||!b)return;const _={productId:b,pdpLink:Vr.pdpLink,isUserAction:T};u(U({},_))},[n,u]);return W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="query"&&h({query:T.value,isUserAction:!0})};return ug(b),()=>{ag(b)}},[h]),W.useEffect(()=>{const b=({detail:T})=>{if((T==null?void 0:T.property)==="pdp-context"){const _=T.value;E({productId:_.productId,isUserAction:!0});return}(T==null?void 0:T.property)==="productId"&&E({productId:T.value,isUserAction:!0})};return fg(b),()=>{dg(b)}},[E]),W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="categoryId"&&m({categoryId:T.value,isUserAction:!0})};return lg(b),()=>{cg(b)}},[m]),W.useEffect(()=>{const b=({detail:T})=>{if((T==null?void 0:T.event)==ai.RESET_CONVERSATION&&a(),(T==null?void 0:T.event)==ai.GET_SESSION_INFORMATION){const _=T.value.callback;c(_)}if((T==null?void 0:T.event)==ai.GET_CONVERSATION_MESSAGES){const{payload:_,callback:S}=T.value;if(!_.conversationId||typeof S!="function")return;f(_,S)}if((T==null?void 0:T.event)==ai.LOAD_CONVERSATION){const _=T.value;if(!_.conversationId)return;f(_,C=>{e(),C.forEach(k=>{t(k)})})}};return IC(b),()=>{PC(b)}},[a,c,f,e,t]),null},GC=({apiKey:e,apiToken:t,baseUrl:n,isDevelopment:r,onConnect:o,onCopilotEvent:u,onRefinedSearch:a,onRefinedBrowse:c,children:f})=>I.jsx(SC,{onCopilotEvent:u,children:I.jsxs(YC,{apiKey:e,apiToken:t,baseUrl:n,isDevelopment:r,onConnect:o,onRefinedSearch:a,onRefinedBrowse:c,children:[I.jsx(WC,{}),f]})}),qf={productId:Vr.proxy.productId,pdpLink:Vr.proxy.pdpLink},KC=W.createContext(qf),QC=({children:e})=>{const[t,n]=W.useState(qf.productId),[r,o]=W.useState(qf.pdpLink);W.useEffect(()=>{const a=({detail:c})=>{if((c==null?void 0:c.property)==="pdp-context"){const f=c.value;n(f.productId),o(f.pdpLink);return}(c==null?void 0:c.property)==="productId"&&n(c.value),(c==null?void 0:c.property)==="pdpLink"&&o(c.value)};return fg(a),()=>{dg(a)}},[]);const u=W.useMemo(()=>({productId:t,pdpLink:r}),[t,r]);return I.jsx(KC.Provider,{value:u,children:e})},Cg=W.createContext({mode:It.modeProxy.mode,status:It.statusProxy,dialogPosition:It.dialogProxy.position,isModalFullscreen:It.modalProxy.isFullscreen,previousComponentType:It.statusProxy.type}),XC=({componentType:e,children:t})=>{const[n,r]=W.useState(It.modeProxy.mode),[o,u]=W.useState({type:e||It.statusProxy.type,isOpen:It.statusProxy.isOpen}),[a,c]=W.useState(It.dialogProxy.position),[f,h]=W.useState(It.modalProxy.isFullscreen),m=vC(o.type);W.useEffect(()=>{const b=T=>{const{property:_,value:S}=T.detail||{};if(!(!_||S===void 0)){if(_==="mode"){r(S);return}if(_==="isOpen"){u(C=>ye(U({},C),{isOpen:S}));return}if(_==="type"){u(C=>ye(U({},C),{type:S}));return}if(_==="position"){c(S);return}if(_==="isFullscreen"){h(S);return}}};return EC(b),()=>{yC(b)}},[]);const E=W.useMemo(()=>({mode:n,status:o,previousComponentType:m||"dialog",dialogPosition:a,isModalFullscreen:f}),[n,o,m,a,f]);return I.jsx(Cg.Provider,{value:E,children:t})},Ag=({apiKey:e,apiToken:t,baseUrl:n,logoUrl:r,headerText:o,theme:u,globalClassName:a,isDevelopment:c=!1,componentType:f,searchPlaceholder:h,searchButtonLabel:m,resetConversationMessage:E,onConnect:b,onCopilotEvent:T,onRefinedSearch:_,onRefinedBrowse:S,children:C})=>I.jsx(mC,{apiKey:e,logoUrl:r,headerText:o,theme:u,globalClassName:a,searchPlaceholder:h,searchButtonLabel:m,resetConversationMessage:E,isDevelopment:c,children:I.jsx(Qw,{apiKey:e,apiToken:t,isDevelopment:c,children:I.jsx(QC,{children:I.jsx(LC,{children:I.jsx(VC,{children:I.jsx(XC,{componentType:f,children:I.jsx(GC,{apiKey:e,apiToken:t,baseUrl:n,isDevelopment:c,onConnect:b,onCopilotEvent:T,onRefinedSearch:_,onRefinedBrowse:S,children:C})})})})})})}),Vo=()=>{const e=W.useContext(Cg);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};function vg(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=vg(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function oe(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=vg(e))&&(r&&(r+=" "),r+=t);return r}var kg={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Ng=Bi.createContext&&Bi.createContext(kg),JC=["attr","size","title"];function ZC(e,t){if(e==null)return{};var n=eA(e,t),r,o;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);for(o=0;o<u.length;o++)r=u[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function eA(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Ua(){return Ua=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ua.apply(this,arguments)}function Og(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Ha(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Og(Object(n),!0).forEach(function(r){tA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Og(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tA(e,t,n){return t=nA(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nA(e){var t=rA(e,"string");return typeof t=="symbol"?t:t+""}function rA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ig(e){return e&&e.map((t,n)=>Bi.createElement(t.tag,Ha({key:n},t.attr),Ig(t.child)))}function hn(e){return t=>Bi.createElement(iA,Ua({attr:Ha({},e.attr)},t),Ig(e.child))}function iA(e){var t=n=>{var{attr:r,size:o,title:u}=e,a=ZC(e,JC),c=o||n.size||"1em",f;return n.className&&(f=n.className),e.className&&(f=(f?f+" ":"")+e.className),Bi.createElement("svg",Ua({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,a,{className:f,style:Ha(Ha({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),u&&Bi.createElement("title",null,u),e.children)};return Ng!==void 0?Bi.createElement(Ng.Consumer,null,n=>t(n)):t(kg)}function Pg(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"},child:[]}]})(e)}function za(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"},child:[]}]})(e)}function sA(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"},child:[]}]})(e)}function Rg(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 9h12v2H6V9zm8 5H6v-2h8v2zm4-6H6V6h12v2z"},child:[]}]})(e)}function oA(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12 8-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"},child:[]}]})(e)}function uA(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"},child:[]}]})(e)}function aA(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M5 16h3v3h2v-5H5v2zm3-8H5v2h5V5H8v3zm6 11h2v-3h3v-2h-5v5zm2-11V5h-2v5h5V8h-3z"},child:[]}]})(e)}function lA(e){return hn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"},child:[]}]})(e)}const Yf=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>I.jsx("button",{className:oe(`${Z}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),ja=({className:e,icon:t,type:n="button",ariaLabel:r,disabled:o=!1,onClick:u})=>I.jsx("button",{className:oe(e,`${Z}-icon-button`),type:n,"aria-label":r,onClick:u,disabled:o,children:t}),cA=({className:e,searchButtonLabel:t,globalClassName:n,componentType:r,isLoading:o})=>t?I.jsx(Yf,{className:oe(n,r,e),type:"submit",disabled:o,children:t}):I.jsx(ja,{className:oe(n,r,e),type:"submit",disabled:o,ariaLabel:"Search Copilot",icon:I.jsx(za,{})}),Wf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{connected:o}=Sg(),{globalClassName:u,searchPlaceholder:a,searchButtonLabel:c}=sr(),f=W.useRef(null),h=b=>{var _;b.preventDefault();const T=(((_=f.current)==null?void 0:_.value)||"").trim();T&&(r(T),f.current.value="")},m=!!o||!1,E=m?"connected":"disconnected";return I.jsxs("form",{className:oe(u,e,n,`${Z}-search-bar`),name:`${Z}-search-form`,onSubmit:h,children:[I.jsx("span",{role:"status",className:oe(`${Z}-connection-status-icon`,E)}),I.jsx("input",{className:oe(u,e,n,`${Z}-search-input`),type:"text",ref:f,placeholder:a,name:`${Z}-user-input`}),I.jsx(cA,{searchButtonLabel:c,globalClassName:u,componentType:n,isLoading:t||!m})]})};function fA(e){return e==null?[]:Array.isArray(e)?e:[e]}var dA=e=>e!=null&&typeof e=="object",$a=e=>typeof e=="string",ks=e=>typeof e=="function",hA=e=>e==null,pA=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),mA=e=>Object.prototype.toString.call(e),Lg=Function.prototype.toString,gA=Lg.call(Object),EA=e=>{if(!dA(e)||mA(e)!="[object Object]"||bA(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=pA(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&Lg.call(n)==gA},yA=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,TA=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,bA=e=>yA(e)||TA(e),_A=e=>e(),xA=()=>{},Gf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function Kf(e){if(!EA(e)||e===void 0)return e;const t=Reflect.ownKeys(e).filter(r=>typeof r=="string"),n={};for(const r of t){const o=e[r];o!==void 0&&(n[r]=Kf(o))}return n}function Qf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function SA(e,t){if(e==null)throw new Error(t())}var wA=Object.defineProperty,CA=(e,t,n)=>t in e?wA(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xf=(e,t,n)=>CA(e,typeof t!="symbol"?t+"":t,n),Dg=()=>{},Va=e=>typeof e=="object"&&e!==null,AA=e=>e?"":void 0,vA=e=>e?"true":void 0,kA=1,NA=9,OA=11,Vt=e=>Va(e)&&e.nodeType===kA&&typeof e.nodeName=="string",qa=e=>Va(e)&&e.nodeType===NA,IA=e=>Va(e)&&e===e.window,Fg=e=>Vt(e)?e.localName||"":"#document";function PA(e){return["html","body","#document"].includes(Fg(e))}var RA=e=>Va(e)&&e.nodeType!==void 0,Vi=e=>RA(e)&&e.nodeType===OA&&"host"in e,LA=e=>Vt(e)&&e.localName==="input",DA=e=>Vt(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function qo(e){if(!e)return!1;const t=e.getRootNode();return Os(t)===e}var FA=/(textarea|select)/;function MA(e){if(e==null||!Vt(e))return!1;try{return LA(e)&&e.selectionStart!=null||FA.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function Ya(e,t){var r;if(!e||!t||!Vt(e)||!Vt(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Vi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Sr(e){var t;return qa(e)?e:IA(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function BA(e){return Sr(e).documentElement}function Ns(e){var t,n,r;return Vi(e)?Ns(e.host):qa(e)?(t=e.defaultView)!=null?t:window:Vt(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Os(e){let t=e.activeElement;for(;t!=null&&t.shadowRoot;){const n=t.shadowRoot.activeElement;if(!n||n===t)break;t=n}return t}function UA(e){if(Fg(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Vi(e)&&e.host||BA(e);return Vi(t)?t.host:t}function Jf(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),qa(t)||Vi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var Zf=new WeakMap;function Wa(e){return Zf.has(e)||Zf.set(e,Ns(e).getComputedStyle(e)),Zf.get(e)}var ed=new Set(["menu","listbox","dialog","grid","tree","region"]),HA=e=>ed.has(e),Mg=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function Bg(e,t){const n=new Set,r=Jf(e),o=u=>{const a=u.querySelectorAll("[aria-controls]");for(const c of a){if(c.getAttribute("aria-expanded")!=="true")continue;const f=Mg(c);for(const h of f){if(!h||n.has(h))continue;n.add(h);const m=r.getElementById(h);if(m){const E=m.getAttribute("role"),b=m.getAttribute("aria-modal")==="true";if(E&&HA(E)&&!b&&(m===t||m.contains(t)||o(m)))return!0}}}return!1};return o(e)}function Ug(e,t){const n=Jf(e),r=new Set,o=u=>{const a=u.querySelectorAll("[aria-controls]");for(const c of a){if(c.getAttribute("aria-expanded")!=="true")continue;const f=Mg(c);for(const h of f){if(!h||r.has(h))continue;r.add(h);const m=n.getElementById(h);if(m){const E=m.getAttribute("role"),b=m.getAttribute("aria-modal")==="true";E&&ed.has(E)&&!b&&(t(m),o(m))}}}};o(e)}function zA(e){const t=new Set;return Ug(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function jA(e){const t=e.getAttribute("role");return!!(t&&ed.has(t))}function $A(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function VA(e){var t;return $A(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function qA(e){if(!e.id)return!1;const t=Jf(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&jA(e))}var td=()=>typeof document!="undefined";function YA(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var nd=e=>td()&&e.test(YA()),WA=e=>td()&&e.test(navigator.vendor),Hg=()=>td()&&!!navigator.maxTouchPoints,GA=()=>nd(/^iPhone/i),KA=()=>nd(/^iPad/i)||rd()&&navigator.maxTouchPoints>1,zg=()=>GA()||KA(),QA=()=>rd()||zg(),rd=()=>nd(/^Mac/i),XA=()=>QA()&&WA(/apple/i);function JA(e){var t,n,r,o;return(o=(t=e.composedPath)==null?void 0:t.call(e))!=null?o:(r=(n=e.nativeEvent)==null?void 0:n.composedPath)==null?void 0:r.call(n)}function qr(e){var n;const t=JA(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var ZA=e=>e.button===0,ev=e=>e.button===2||rd()&&e.ctrlKey&&e.button===0,ur=(e,t,n,r)=>{const o=typeof e=="function"?e():e;return o==null||o.addEventListener(t,n,r),()=>{o==null||o.removeEventListener(t,n,r)}},jg=e=>Vt(e)&&e.tagName==="IFRAME",tv=/^(audio|video|details)$/;function $g(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var nv=e=>!Number.isNaN($g(e)),rv=e=>$g(e)<0;function iv(e,t){if(!t)return null;if(t===!0)return e.shadowRoot||null;const n=t(e);return(n===!0?e.shadowRoot:n)||null}function Vg(e,t,n){const r=[...e],o=[...e],u=new Set,a=new Map;e.forEach((f,h)=>a.set(f,h));let c=0;for(;c<o.length;){const f=o[c++];if(!f||u.has(f))continue;u.add(f);const h=iv(f,t);if(h){const m=Array.from(h.querySelectorAll(Ga)).filter(n),E=a.get(f);if(E!==void 0){const b=E+1;r.splice(b,0,...m),m.forEach((T,_)=>{a.set(T,b+_)});for(let T=b+m.length;T<r.length;T++)a.set(r[T],T)}else{const b=r.length;r.push(...m),m.forEach((T,_)=>{a.set(T,b+_)})}o.push(...m)}}return r}var Ga="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false']), details > summary:first-of-type",qg=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ga));(n==!0||n=="if-empty"&&o.length===0)&&Vt(e)&&Yr(e)&&o.unshift(e);const a=[];for(const c of o)if(Yr(c)){if(jg(c)&&c.contentDocument){const f=c.contentDocument.body;a.push(...qg(f,{getShadowRoot:r}));continue}a.push(c)}return r?Vg(a,r,Yr):a};function Yr(e){return!Vt(e)||e.closest("[inert]")?!1:e.matches(Ga)&&DA(e)}function Yo(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ga));n&&qi(e)&&o.unshift(e);const u=[];for(const a of o)if(qi(a)){if(jg(a)&&a.contentDocument){const c=a.contentDocument.body;u.push(...Yo(c,{getShadowRoot:r}));continue}u.push(a)}if(r){const a=Vg(u,r,qi);return!a.length&&n?o:a}return!u.length&&n?o:u}function qi(e){return Vt(e)&&e.tabIndex>0?!0:Yr(e)&&!rv(e)}function sv(e,t={}){const n=Yo(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function ov(e,t={}){const{current:n,getShadowRoot:r}=t,o=Yo(e,{getShadowRoot:r}),u=(e==null?void 0:e.ownerDocument)||document,a=n!=null?n:Os(u);if(!a)return null;const c=o.indexOf(a);return o[c+1]||null}function Wo(e){return e.tabIndex<0&&(tv.test(e.localName)||MA(e))&&!nv(e)?0:e.tabIndex}function Yg(e){const{root:t,getInitialEl:n,filter:r,enabled:o=!0}=e;if(!o)return;let u=null;if(u||(u=typeof n=="function"?n():n),u||(u=t==null?void 0:t.querySelector("[data-autofocus],[autofocus]")),!u){const a=Yo(t);u=r?a.filter(r)[0]:a[0]}return u||t||void 0}var uv=class hx{constructor(){Xf(this,"id",null),Xf(this,"fn_cleanup"),Xf(this,"cleanup",()=>{this.cancel()})}static create(){return new hx}request(t){this.cancel(),this.id=globalThis.requestAnimationFrame(()=>{this.id=null,this.fn_cleanup=t==null?void 0:t()})}cancel(){var t;this.id!==null&&(globalThis.cancelAnimationFrame(this.id),this.id=null),(t=this.fn_cleanup)==null||t.call(this),this.fn_cleanup=void 0}isActive(){return this.id!==null}};function _n(e){const t=uv.create();return t.request(e),t.cleanup}function av(e){const t=new Set;function n(r){const o=globalThis.requestAnimationFrame(r);t.add(()=>globalThis.cancelAnimationFrame(o))}return n(()=>n(e)),function(){t.forEach(o=>o())}}function id(e){const t=UA(e);return PA(t)?Sr(t).body:Vt(t)&&fv(t)?t:id(t)}var lv=/auto|scroll|overlay|hidden|clip/,cv=new Set(["inline","contents"]);function fv(e){const t=Ns(e),{overflow:n,overflowX:r,overflowY:o,display:u}=t.getComputedStyle(e);return lv.test(n+o+r)&&!cv.has(u)}function dv(e,t={}){const{triggerElement:n,onFocus:r,onFocusEnter:o,getShadowRoot:u}=t,a=(e==null?void 0:e.ownerDocument)||document,c=a.body;function f(h){if(h.key!=="Tab")return;let m=null;const[E,b]=sv(e,{includeContainer:!0,getShadowRoot:u}),T=ov(c,{current:n,getShadowRoot:u}),_=!E&&!b;h.shiftKey&&qo(T)?(o==null||o(),m=b):h.shiftKey&&(qo(E)||_)?m=n:!h.shiftKey&&qo(n)?(o==null||o(),m=E):!h.shiftKey&&(qo(b)||_)&&(m=T),m&&(h.preventDefault(),typeof r=="function"?r(m):m.focus())}return ur(a,"keydown",f,!0)}function hv(e,t){const c=t,{defer:n,triggerElement:r}=c,o=Xt(c,["defer","triggerElement"]),u=n?_n:f=>f(),a=[];return a.push(u(()=>{const f=typeof e=="function"?e():e,h=typeof r=="function"?r():r;a.push(dv(f,U({triggerElement:h},o)))})),()=>{a.forEach(f=>f==null?void 0:f())}}function Ka(e,t){if(!e)return Dg;const n=Object.keys(t).reduce((r,o)=>(r[o]=e.style.getPropertyValue(o),r),{});return Object.assign(e.style,t),()=>{Object.assign(e.style,n),e.style.length===0&&e.removeAttribute("style")}}function pv(e,t,n){if(!e)return Dg;const r=e.style.getPropertyValue(t);return e.style.setProperty(t,n),()=>{e.style.setProperty(t,r),e.style.length===0&&e.removeAttribute("style")}}function mv(e,t,n){const{signal:r}=t;return[new Promise((a,c)=>{const f=setTimeout(()=>{c(new Error(`Timeout of ${n}ms exceeded`))},n);r.addEventListener("abort",()=>{clearTimeout(f),c(new Error("Promise aborted"))}),e.then(h=>{r.aborted||(clearTimeout(f),a(h))}).catch(h=>{r.aborted||(clearTimeout(f),c(h))})}),()=>t.abort()]}function gv(e,t){const{timeout:n,rootNode:r}=t,o=Ns(r),u=Sr(r),a=new o.AbortController;return mv(new Promise(c=>{const f=e();if(f){c(f);return}const h=new o.MutationObserver(()=>{const m=e();m&&m.isConnected&&(h.disconnect(),c(m))});h.observe(u.body,{childList:!0,subtree:!0})}),a,n)}var Ev=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),yv=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,Wg=e=>{const t={};let n;for(;n=yv.exec(e);)t[n[1]]=n[2];return t},Tv=(e,t)=>{if($a(e)){if($a(t))return`${e};${t}`;e=Wg(e)}else $a(t)&&(t=Wg(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function ar(...e){let t={};for(let n of e){if(!n)continue;for(let o in t){if(o.startsWith("on")&&typeof t[o]=="function"&&typeof n[o]=="function"){t[o]=Gf(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=Ev(t[o],n[o]);continue}if(o==="style"){t[o]=Tv(t[o],n[o]);continue}t[o]=n[o]!==void 0?n[o]:t[o]}for(let o in n)t[o]===void 0&&(t[o]=n[o]);const r=Object.getOwnPropertySymbols(n);for(let o of r)t[o]=n[o]}return t}function $M(e){return e}var Is=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Is||{}),sd="__init__";function bv(e){const t=()=>{var a,c;return(c=(a=e.getRootNode)==null?void 0:a.call(e))!=null?c:document},n=()=>Sr(t()),r=()=>{var a;return(a=n().defaultView)!=null?a:window},o=()=>Os(t()),u=a=>t().getElementById(a);return ye(U({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:qo,getById:u})}var od={exports:{}},xn={},ud={exports:{}},ad={};var Gg;function _v(){return Gg||(Gg=1,function(e){function t(V,ee){var w=V.length;V.push(ee);e:for(;0<w;){var R=w-1>>>1,Q=V[R];if(0<o(Q,ee))V[R]=ee,V[w]=Q,w=R;else break e}}function n(V){return V.length===0?null:V[0]}function r(V){if(V.length===0)return null;var ee=V[0],w=V.pop();if(w!==ee){V[0]=w;e:for(var R=0,Q=V.length,N=Q>>>1;R<N;){var _e=2*(R+1)-1,Me=V[_e],Ie=_e+1,Ye=V[Ie];if(0>o(Me,w))Ie<Q&&0>o(Ye,Me)?(V[R]=Ye,V[Ie]=w,R=Ie):(V[R]=Me,V[_e]=w,R=_e);else if(Ie<Q&&0>o(Ye,w))V[R]=Ye,V[Ie]=w,R=Ie;else break e}}return ee}function o(V,ee){var w=V.sortIndex-ee.sortIndex;return w!==0?w:V.id-ee.id}if(typeof performance=="object"&&typeof performance.now=="function"){var u=performance;e.unstable_now=function(){return u.now()}}else{var a=Date,c=a.now();e.unstable_now=function(){return a.now()-c}}var f=[],h=[],m=1,E=null,b=3,T=!1,_=!1,S=!1,C=typeof setTimeout=="function"?setTimeout:null,k=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function D(V){for(var ee=n(h);ee!==null;){if(ee.callback===null)r(h);else if(ee.startTime<=V)r(h),ee.sortIndex=ee.expirationTime,t(f,ee);else break;ee=n(h)}}function G(V){if(S=!1,D(V),!_)if(n(f)!==null)_=!0,we(q);else{var ee=n(h);ee!==null&&ae(G,ee.startTime-V)}}function q(V,ee){_=!1,S&&(S=!1,k(Te),Te=-1),T=!0;var w=b;try{for(D(ee),E=n(f);E!==null&&(!(E.expirationTime>ee)||V&&!fe());){var R=E.callback;if(typeof R=="function"){E.callback=null,b=E.priorityLevel;var Q=R(E.expirationTime<=ee);ee=e.unstable_now(),typeof Q=="function"?E.callback=Q:E===n(f)&&r(f),D(ee)}else r(f);E=n(f)}if(E!==null)var N=!0;else{var _e=n(h);_e!==null&&ae(G,_e.startTime-ee),N=!1}return N}finally{E=null,b=w,T=!1}}var B=!1,te=null,Te=-1,Se=5,H=-1;function fe(){return!(e.unstable_now()-H<Se)}function de(){if(te!==null){var V=e.unstable_now();H=V;var ee=!0;try{ee=te(!0,V)}finally{ee?ue():(B=!1,te=null)}}else B=!1}var ue;if(typeof M=="function")ue=function(){M(de)};else if(typeof MessageChannel!="undefined"){var ie=new MessageChannel,ge=ie.port2;ie.port1.onmessage=de,ue=function(){ge.postMessage(null)}}else ue=function(){C(de,0)};function we(V){te=V,B||(B=!0,ue())}function ae(V,ee){Te=C(function(){V(e.unstable_now())},ee)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(V){V.callback=null},e.unstable_continueExecution=function(){_||T||(_=!0,we(q))},e.unstable_forceFrameRate=function(V){0>V||125<V?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Se=0<V?Math.floor(1e3/V):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_getFirstCallbackNode=function(){return n(f)},e.unstable_next=function(V){switch(b){case 1:case 2:case 3:var ee=3;break;default:ee=b}var w=b;b=ee;try{return V()}finally{b=w}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(V,ee){switch(V){case 1:case 2:case 3:case 4:case 5:break;default:V=3}var w=b;b=V;try{return ee()}finally{b=w}},e.unstable_scheduleCallback=function(V,ee,w){var R=e.unstable_now();switch(typeof w=="object"&&w!==null?(w=w.delay,w=typeof w=="number"&&0<w?R+w:R):w=R,V){case 1:var Q=-1;break;case 2:Q=250;break;case 5:Q=1073741823;break;case 4:Q=1e4;break;default:Q=5e3}return Q=w+Q,V={id:m++,callback:ee,priorityLevel:V,startTime:w,expirationTime:Q,sortIndex:-1},w>R?(V.sortIndex=w,t(h,V),n(f)===null&&V===n(h)&&(S?(k(Te),Te=-1):S=!0,ae(G,w-R))):(V.sortIndex=Q,t(f,V),_||T||(_=!0,we(q))),V},e.unstable_shouldYield=fe,e.unstable_wrapCallback=function(V){var ee=b;return function(){var w=b;b=ee;try{return V.apply(this,arguments)}finally{b=w}}}}(ad)),ad}var Kg;function xv(){return Kg||(Kg=1,ud.exports=_v()),ud.exports}var Qg;function Sv(){if(Qg)return xn;Qg=1;var e=ms(),t=xv();function n(i){for(var s="https://reactjs.org/docs/error-decoder.html?invariant="+i,l=1;l<arguments.length;l++)s+="&args[]="+encodeURIComponent(arguments[l]);return"Minified React error #"+i+"; visit "+s+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,o={};function u(i,s){a(i,s),a(i+"Capture",s)}function a(i,s){for(o[i]=s,i=0;i<s.length;i++)r.add(s[i])}var c=!(typeof window=="undefined"||typeof window.document=="undefined"||typeof window.document.createElement=="undefined"),f=Object.prototype.hasOwnProperty,h=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,m={},E={};function b(i){return f.call(E,i)?!0:f.call(m,i)?!1:h.test(i)?E[i]=!0:(m[i]=!0,!1)}function T(i,s,l,d){if(l!==null&&l.type===0)return!1;switch(typeof s){case"function":case"symbol":return!0;case"boolean":return d?!1:l!==null?!l.acceptsBooleans:(i=i.toLowerCase().slice(0,5),i!=="data-"&&i!=="aria-");default:return!1}}function _(i,s,l,d){if(s===null||typeof s=="undefined"||T(i,s,l,d))return!0;if(d)return!1;if(l!==null)switch(l.type){case 3:return!s;case 4:return s===!1;case 5:return isNaN(s);case 6:return isNaN(s)||1>s}return!1}function S(i,s,l,d,g,y,x){this.acceptsBooleans=s===2||s===3||s===4,this.attributeName=d,this.attributeNamespace=g,this.mustUseProperty=l,this.propertyName=i,this.type=s,this.sanitizeURL=y,this.removeEmptyString=x}var C={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){C[i]=new S(i,0,!1,i,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(i){var s=i[0];C[s]=new S(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){C[i]=new S(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){C[i]=new S(i,2,!1,i,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(i){C[i]=new S(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){C[i]=new S(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){C[i]=new S(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){C[i]=new S(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){C[i]=new S(i,5,!1,i.toLowerCase(),null,!1,!1)});var k=/[\-:]([a-z])/g;function M(i){return i[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(i){var s=i.replace(k,M);C[s]=new S(s,1,!1,i,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(i){var s=i.replace(k,M);C[s]=new S(s,1,!1,i,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(i){var s=i.replace(k,M);C[s]=new S(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){C[i]=new S(i,1,!1,i.toLowerCase(),null,!1,!1)}),C.xlinkHref=new S("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){C[i]=new S(i,1,!1,i.toLowerCase(),null,!0,!0)});function D(i,s,l,d){var g=C.hasOwnProperty(s)?C[s]:null;(g!==null?g.type!==0:d||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(_(s,l,g,d)&&(l=null),d||g===null?b(s)&&(l===null?i.removeAttribute(s):i.setAttribute(s,""+l)):g.mustUseProperty?i[g.propertyName]=l===null?g.type===3?!1:"":l:(s=g.attributeName,d=g.attributeNamespace,l===null?i.removeAttribute(s):(g=g.type,l=g===3||g===4&&l===!0?"":""+l,d?i.setAttributeNS(d,s,l):i.setAttribute(s,l))))}var G=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,q=Symbol.for("react.element"),B=Symbol.for("react.portal"),te=Symbol.for("react.fragment"),Te=Symbol.for("react.strict_mode"),Se=Symbol.for("react.profiler"),H=Symbol.for("react.provider"),fe=Symbol.for("react.context"),de=Symbol.for("react.forward_ref"),ue=Symbol.for("react.suspense"),ie=Symbol.for("react.suspense_list"),ge=Symbol.for("react.memo"),we=Symbol.for("react.lazy"),ae=Symbol.for("react.offscreen"),V=Symbol.iterator;function ee(i){return i===null||typeof i!="object"?null:(i=V&&i[V]||i["@@iterator"],typeof i=="function"?i:null)}var w=Object.assign,R;function Q(i){if(R===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);R=s&&s[1]||""}return`
1
+ (function(Oe,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Oe=typeof globalThis!="undefined"?globalThis:Oe||self,Fe(Oe["cimulate-copilot-widget"]={}))})(this,function(Oe){"use strict";var aM=Object.defineProperty,lM=Object.defineProperties;var cM=Object.getOwnPropertyDescriptors;var Gc=Object.getOwnPropertySymbols;var dx=Object.prototype.hasOwnProperty,hx=Object.prototype.propertyIsEnumerable;var vo=(Oe,Fe)=>(Fe=Symbol[Oe])?Fe:Symbol.for("Symbol."+Oe),fM=Oe=>{throw TypeError(Oe)},Kc=Math.pow,km=(Oe,Fe,Ge)=>Fe in Oe?aM(Oe,Fe,{enumerable:!0,configurable:!0,writable:!0,value:Ge}):Oe[Fe]=Ge,U=(Oe,Fe)=>{for(var Ge in Fe||(Fe={}))dx.call(Fe,Ge)&&km(Oe,Ge,Fe[Ge]);if(Gc)for(var Ge of Gc(Fe))hx.call(Fe,Ge)&&km(Oe,Ge,Fe[Ge]);return Oe},ye=(Oe,Fe)=>lM(Oe,cM(Fe));var en=(Oe,Fe)=>{var Ge={};for(var ut in Oe)dx.call(Oe,ut)&&Fe.indexOf(ut)<0&&(Ge[ut]=Oe[ut]);if(Oe!=null&&Gc)for(var ut of Gc(Oe))Fe.indexOf(ut)<0&&hx.call(Oe,ut)&&(Ge[ut]=Oe[ut]);return Ge};var ke=(Oe,Fe,Ge)=>km(Oe,typeof Fe!="symbol"?Fe+"":Fe,Ge);var st=(Oe,Fe,Ge)=>new Promise((ut,At)=>{var gt=kt=>{try{Ht(Ge.next(kt))}catch(mn){At(mn)}},Pe=kt=>{try{Ht(Ge.throw(kt))}catch(mn){At(mn)}},Ht=kt=>kt.done?ut(kt.value):Promise.resolve(kt.value).then(gt,Pe);Ht((Ge=Ge.apply(Oe,Fe)).next())}),Hr=function(Oe,Fe){this[0]=Oe,this[1]=Fe},Qc=(Oe,Fe,Ge)=>{var ut=(Pe,Ht,kt,mn)=>{try{var ms=Ge[Pe](Ht),ko=(Ht=ms.value)instanceof Hr,Xc=ms.done;Promise.resolve(ko?Ht[0]:Ht).then(tr=>ko?ut(Pe==="return"?Pe:"next",Ht[1]?{done:tr.done,value:tr.value}:tr,kt,mn):kt({value:tr,done:Xc})).catch(tr=>ut("throw",tr,kt,mn))}catch(tr){mn(tr)}},At=Pe=>gt[Pe]=Ht=>new Promise((kt,mn)=>ut(Pe,Ht,kt,mn)),gt={};return Ge=Ge.apply(Oe,Fe),gt[vo("asyncIterator")]=()=>gt,At("next"),At("throw"),At("return"),gt},Nm=Oe=>{var Fe=Oe[vo("asyncIterator")],Ge=!1,ut,At={};return Fe==null?(Fe=Oe[vo("iterator")](),ut=gt=>At[gt]=Pe=>Fe[gt](Pe)):(Fe=Fe.call(Oe),ut=gt=>At[gt]=Pe=>{if(Ge){if(Ge=!1,gt==="throw")throw Pe;return Pe}return Ge=!0,{done:!1,value:new Hr(new Promise(Ht=>{var kt=Fe[gt](Pe);kt instanceof Object||fM("Object expected"),Ht(kt)}),1)}}),At[vo("iterator")]=()=>At,ut("next"),"throw"in Fe?ut("throw"):At.throw=gt=>{throw gt},"return"in Fe&&ut("return"),At},px=(Oe,Fe,Ge)=>(Fe=Oe[vo("asyncIterator")])?Fe.call(Oe):(Oe=Oe[vo("iterator")](),Fe={},Ge=(ut,At)=>(At=Oe[ut])&&(Fe[ut]=gt=>new Promise((Pe,Ht,kt)=>(gt=At.call(Oe,gt),kt=gt.done,Promise.resolve(gt.value).then(mn=>Pe({value:mn,done:kt}),Ht)))),Ge("next"),Ge("return"),Fe);var Fe=document.createElement("style");Fe.textContent=`.cim-widget-button{padding:.5rem;background-color:var(--cim-widget-primary-color, #3182ce);border-radius:4px;border-color:var(--cim-widget-primary-color, #3182ce);border-style:solid;color:#fff;font-family:var(--cim-widget-font-family, inherit);cursor:pointer;&:disabled,&[disabled]{cursor:not-allowed;opacity:.6}}.cim-widget-icon-button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;background-color:transparent;border:1px solid transparent;border-radius:4px;padding:6px;cursor:pointer;color:#333;font-size:18px;&:hover{background-color:#f0f0f0}&:disabled,&[disabled]{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-search-bar{display:flex;align-items:center;justify-content:space-between;padding:1px;border:1px solid var(--cim-widget-border-color);border-radius:4px;font-family:var(--cim-widget-font-family)}.cim-widget-search-input{width:100%;height:100%;margin-left:2px;background-color:transparent;border:none;outline:none}.cim-widget-connection-status-icon{display:inline-block;min-width:8px;width:.6rem;height:.5rem;border-radius:50%;margin:.35rem;vertical-align:middle;&.connected{background-color:#00d60080}&.disconnected{background-color:#c9c7c7}}.cim-widget-overflow-menu{position:relative;height:auto;width:auto}.cim-widget-overflow-menu-list{width:130px;background:#fff;padding:.25rem 0;border-radius:.5rem;border:1px solid var(--cim-widget-border-color)}.cim-widget-overflow-menu-button-trigger,.cim-widget-overflow-menu-button{display:inline-flex;align-items:center;width:100%;background-color:#fff;border:1px solid transparent;border-radius:4px;padding:6px;cursor:pointer;color:#333;&:hover{background-color:#f0f0f0}}.cim-widget-overflow-menu-button{gap:.5rem;padding:.5rem .75rem;svg{font-size:.75rem}}.cim-widget-close-button{display:flex;align-items:center;justify-content:center;padding:.5rem;border-radius:4px;border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-clear-chat-icon-button{min-height:32px}.cim-widget-product-tile{display:inline-flex;flex-direction:column;background-color:var(--cim-widget-background-color, #ffffff);border-radius:4px;box-shadow:0 1px 3px #0000001a}.cim-widget-product-tile.embedded,.cim-widget-product-tile.standalone{min-width:15dvw;max-width:30dvw}.cim-widget-product-tile-image{object-fit:contain;width:100%;height:auto;max-height:25dvh;border-top-left-radius:4px;border-top-right-radius:4px}.cim-widget-product-tile-details{height:100%;display:flex;flex-direction:column;justify-content:space-between;padding:.5rem}.cim-widget-product-tile-brand{color:var(--cim-widget-primary-color)}.cim-widget-product-tile-pdp,.cim-widget-product-tile-name,.cim-widget-product-tile-price,.cim-widget-product-tile-pid{display:inline-block;line-height:1.25rem;font-size:.875rem}.cim-widget-product-tile-name{font-weight:700}.cim-widget-product-tile-pdp{color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 85%,black);text-decoration:none;word-wrap:break-word;&:hover{text-decoration:underline}}.cim-widget-product-tile-pdp-arrow{display:inline-block;transform:rotate(-45deg)}.cim-widget-product-tile-footer{display:flex;justify-content:space-between;align-items:center;padding-top:.5rem;gap:.5rem}.cim-widget-product-tile-price{font-weight:700}@media (max-width: 576px){.cim-widget-product-tile.embedded,.cim-widget-product-tile.standalone{min-width:30dvw;max-width:45dvw}.cim-widget-product-tile-pdp,.cim-widget-product-tile-name{display:-webkit-box;line-clamp:3;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}}.cim-widget-display-products{flex-direction:column;overflow-x:hidden}.cim-widget-product-list{flex:1;display:inline-flex;gap:.5rem;padding:.5rem .5rem .5rem 0;overflow-x:auto}.cim-widget-error-message-text{display:inline-flex;align-items:center;gap:.5rem;color:#e53e3e;&.embedded svg{min-width:1.25rem;height:1.25rem}}.cim-widget-suggestion-container.embedded{display:inline-flex;flex-wrap:wrap;gap:.5rem}.cim-widget-suggestion-button.embedded{height:auto;padding:.2rem .5rem;border:1px solid var(--cim-widget-primary-color);border-radius:4px;background-color:transparent;font-size:.875rem;font-weight:600;font-family:inherit;color:var(--cim-widget-primary-color);white-space:normal;word-break:break-word;text-align:left;cursor:pointer}.cim-widget-suggestion-button.embedded:hover{background-color:#fff;color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-container.standalone{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:.5rem;padding:.5rem 0}@media (max-width: 768px){.cim-widget-suggestion-container.standalone{grid-template-columns:repeat(1,1fr)}}.cim-widget-suggestion-button.standalone{display:inline-flex;align-items:center;padding:.5rem 1rem;border:1px solid var(--cim-widget-primary-color);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent);font-weight:700;color:var(--cim-widget-primary-color);text-align:left;white-space:normal;word-break:break-word}.cim-widget-suggestion-button.standalone:hover{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 15%,transparent);color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-button:disabled{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a;cursor:not-allowed}.cim-widget-suggestion-button:disabled:hover{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a}.cim-widget-blinking-cursor{display:inline-flex;margin-left:2px;line-height:0;animation:cursor-blink 1.5s steps(2) infinite}@keyframes cursor-blink{0%{opacity:0}}.cim-widget-ul{list-style-type:disc;padding-left:1.5rem}.cim-widget-ol{list-style-type:decimal;padding-left:1.5rem}.cim-widget-table{width:100%;margin-top:1rem;margin-bottom:1rem;border-radius:.5rem;border:1px solid #8a8a8a;border-collapse:collapse}.cim-widget-thead{background-color:#f0f0f0;border-bottom-width:2px;border-color:#8a8a8a}.cim-widget-tr{border-bottom-width:1px;border-color:#8a8a8a}.cim-widget-th{padding:.5rem 1rem;text-align:left;font-weight:700;border-bottom-width:1px;border-color:#8a8a8a}.cim-widget-td{padding:.5rem 1rem;border-bottom-width:1px;border-color:#8a8a8a}.cim-widget-message-container pre{margin:0}.cim-widget-progress-message.embedded,.cim-widget-progress-message.standalone{display:flex;align-items:center}.cim-widget-progress-text.embedded{font-size:.85rem;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 80%,white);line-height:1rem;line-clamp:3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cim-widget-progress-text.standalone{font-size:inherit;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 85%,white)}.cim-widget-thought-container{padding-left:.5rem;margin:.5rem;border-left:2px solid var(--cim-widget-primary-color)}p.cim-widget-progress-thought{margin-bottom:1rem;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 70%,white);line-height:1;font-size:.875rem}.cim-widget-thought-context-button{display:inline-flex;align-items:center;justify-content:space-between;padding:.25rem;min-width:84px;background-color:transparent;border-color:transparent;color:var(--cim-widget-primary-color);font-weight:700;cursor:pointer;&:hover{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent);color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}}.cim-widget-message-icon.progress-icon.embedded{color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 50%,white)}.cim-widget-refined-event{display:flex;flex-direction:column}.cim-widget-refined-event-query{display:inline-flex;align-items:center;color:var(--cim-widget-secondary-color)}.cim-widget-message-icon.refined-event-icon{font-size:1.5rem;&.embedded,&.standalone{color:var(--cim-widget-primary-color)}}.cim-widget-facet-pill{display:inline-flex;align-items:center;margin-left:4px;padding:.25rem .5rem;color:var(--cim-widget-primary-color);border-radius:9999px;font-size:.75rem;font-weight:700;&.embedded{background-color:#ffffff90}&.standalone{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent)}}.cim-widget-facet-filters{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:.25rem}.cim-widget-facets{display:flex;flex-direction:column;padding:.25rem}.cim-widget-facets .cim-widget-facet-category{margin-bottom:0;font-size:.875rem;font-weight:700;word-wrap:break-word}.cim-widget-facets .cim-widget-facet-values{margin-top:0;font-size:.675rem}.cim-widget-user-message{display:flex;align-items:center}.cim-widget-user-message.embedded{display:inline-flex;align-self:flex-end;border-radius:8px;padding:.5rem 1rem;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:30%}.cim-widget-user-message.standalone{margin:.5rem 0}.cim-widget-user-message-text{font-weight:700;margin-bottom:.5rem}.standalone .cim-widget-user-message-text{font-size:1.125rem}.cim-widget-message-icon.user-message-icon{margin-right:.5rem}.cim-widget-message-icon.user-message-icon.embedded{color:var(--cim-widget-primary-color)}.cim-widget-user-search{display:flex}.cim-widget-user-search.embedded{display:inline-flex;align-self:flex-end;border-radius:8px;padding:.5rem 1rem;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:30%;gap:4px}.cim-widget-user-search.standalone{flex-direction:column;font-size:1.125rem;padding-top:.5rem;padding-bottom:.5rem}.cim-widget-user-search-query{display:inline-flex}.cim-widget-message-icon.user-search-icon.embedded,.cim-widget-message-icon.user-search-icon.standalone{font-size:1.5rem;color:var(--cim-widget-primary-color)}.message{border-radius:.5rem}.widget-message{display:flex;align-self:flex-start}.user-message{display:flex;align-self:flex-end;padding:1rem}.cim-widget-reset-message{font-size:.75rem;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 75%,white)}.cim-widget-start-search-message{font-size:.875rem;font-weight:700;color:var(--cim-widget-font-color)}.cim-widget-message-group,.cim-widget-message{display:flex;flex-direction:column}.cim-widget-message-group{gap:.5rem;padding:1rem;margin-bottom:1rem;border-radius:8px;&.standalone{padding:0 1rem}.cim-widget-message-group-child{max-width:100%;margin-bottom:.25rem}}.cim-widget-message-group.embedded{max-width:80%;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent)}.cim-widget-message{margin-bottom:1rem}.cim-widget-message.standalone{border-radius:0;background-color:transparent;padding:0 1rem}.cim-widget-message.embedded{margin-bottom:1rem}.cim-widget-embedded-chat{position:relative;width:100%;height:100%;margin:0 auto;border-radius:8px;border:1px solid var(--cim-widget-border-color)}.cim-widget-embedded-chat>.cim-widget-message-container{padding-top:2rem;padding-left:1rem;padding-right:1rem}.cim-widget-embedded-chat-menu{position:absolute;top:.25rem;right:.25rem}.cim-widget-overflow-menu-button-trigger.chat{border:1px solid var(--cim-widget-border-color)}.cim-widget-dialog{position:fixed;width:35dvw;height:55dvh;padding:1rem;border-radius:.5rem;border:1px solid var(--cim-widget-border-color);font-size:.875rem;&.bottom-left{bottom:.5rem;left:.5rem}&.bottom-right{bottom:.5rem;right:.5rem}}.cim-widget-dialog-content{display:flex;flex-direction:column;height:100%}.cim-widget-dialog-header{display:inline-flex;align-items:center;width:100%;margin-bottom:.5rem;gap:8px}.cim-widget-dialog-controls{position:absolute;top:4px;right:4px;display:inline-flex;align-items:center}.cim-widget-dialog-logo{object-fit:contain;max-width:50%;max-height:3rem}.cim-widget-dialog-title{margin-top:0;margin-bottom:0}@media (576px <= width <= 768px){.cim-widget-dialog{width:50%;border-radius:0}}@media (max-width: 576px){.cim-widget-dialog{height:100%;width:100%;border-radius:0;&.bottom-left{bottom:0;left:0}&.bottom-right{bottom:0;right:0}}}.cim-widget-modal-container{display:flex;align-items:center;justify-content:center;position:fixed;top:0;left:0;height:100dvh;width:100dvw}.cim-widget-modal-backdrop{position:absolute;top:0;left:0;height:100%;width:100%;background:#00000080}.cim-widget-modal{position:fixed;width:70dvw;height:80dvh;padding:1rem;border-radius:.5rem;border:1px solid var(--cim-widget-border-color);overflow-y:hidden;&.fullscreen{height:100%;width:100%;border-radius:0}}.cim-widget-modal-content{display:flex;flex-direction:column;height:100%}.cim-widget-modal-header{display:inline-flex;align-items:center;width:100%;margin-bottom:1rem;gap:8px}.cim-widget-modal-controls{position:absolute;top:4px;right:4px;display:inline-flex;align-items:center}.cim-widget-modal-logo{object-fit:contain;max-width:50%;max-height:3rem}.cim-widget-modal-title{margin-top:0;margin-bottom:0}@media (max-width: 576px){.cim-widget-modal{height:100%;width:100%;border-radius:0}}.cim-widget-container{box-sizing:border-box;display:flex;flex-direction:column;background-color:var(--cim-widget-background-color);font-family:var(--cim-widget-font-family, inherit);color:var(--cim-widget-font-color, inherit)}.cim-widget-message-container p{margin:.25rem 0;padding:0;+p{margin-top:.5rem}}.cim-widget-message-container span{line-height:1}.cim-widget-header{font-weight:700;color:inherit}.cim-widget-header.h1{margin-top:2rem;margin-bottom:2rem;font-size:1rem}.cim-widget-header.h2{margin-top:1.5rem;margin-bottom:1.5rem;font-size:1rem}.cim-widget-header.h3{margin-top:1rem;margin-bottom:1rem;font-size:1rem}.cim-widget-link{color:var(--cim-widget-primary-color);text-decoration:underline;cursor:pointer}.cim-widget-link:hover{color:var(--cim-widget-secondary-color);text-decoration:none}.cim-widget-text{line-height:1.5;color:inherit;margin-bottom:.25rem}.cim-widget-text.italic{font-style:italic}.cim-widget-text.bold{font-weight:700}.cim-widget-message-container{flex:1;overflow-y:auto;padding:1rem 0}.cim-widget-message-icon{display:inline-flex;align-items:center;margin-right:.25rem}.cim-widget-message-icon.embedded{font-size:1rem;color:var(--cim-widget-secondary-color)}.cim-widget-message-icon.standalone{font-size:1.5rem;color:var(--cim-widget-primary-color)}
2
+ /*$vite$:1*/`,document.head.appendChild(Fe);function Ge(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ut={exports:{}},At={},gt={exports:{}},Pe={};var Ht;function kt(){if(Ht)return Pe;Ht=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),u=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),E=Symbol.iterator;function b(R){return R===null||typeof R!="object"?null:(R=E&&R[E]||R["@@iterator"],typeof R=="function"?R:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,S={};function C(R,Q,N){this.props=R,this.context=Q,this.refs=S,this.updater=N||T}C.prototype.isReactComponent={},C.prototype.setState=function(R,Q){if(typeof R!="object"&&typeof R!="function"&&R!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,R,Q,"setState")},C.prototype.forceUpdate=function(R){this.updater.enqueueForceUpdate(this,R,"forceUpdate")};function k(){}k.prototype=C.prototype;function M(R,Q,N){this.props=R,this.context=Q,this.refs=S,this.updater=N||T}var D=M.prototype=new k;D.constructor=M,_(D,C.prototype),D.isPureReactComponent=!0;var G=Array.isArray,q=Object.prototype.hasOwnProperty,B={current:null},te={key:!0,ref:!0,__self:!0,__source:!0};function Te(R,Q,N){var _e,Me={},Ie=null,Ye=null;if(Q!=null)for(_e in Q.ref!==void 0&&(Ye=Q.ref),Q.key!==void 0&&(Ie=""+Q.key),Q)q.call(Q,_e)&&!te.hasOwnProperty(_e)&&(Me[_e]=Q[_e]);var Ve=arguments.length-2;if(Ve===1)Me.children=N;else if(1<Ve){for(var Je=Array(Ve),xt=0;xt<Ve;xt++)Je[xt]=arguments[xt+2];Me.children=Je}if(R&&R.defaultProps)for(_e in Ve=R.defaultProps,Ve)Me[_e]===void 0&&(Me[_e]=Ve[_e]);return{$$typeof:e,type:R,key:Ie,ref:Ye,props:Me,_owner:B.current}}function Se(R,Q){return{$$typeof:e,type:R.type,key:Q,ref:R.ref,props:R.props,_owner:R._owner}}function H(R){return typeof R=="object"&&R!==null&&R.$$typeof===e}function fe(R){var Q={"=":"=0",":":"=2"};return"$"+R.replace(/[=:]/g,function(N){return Q[N]})}var de=/\/+/g;function ue(R,Q){return typeof R=="object"&&R!==null&&R.key!=null?fe(""+R.key):Q.toString(36)}function ie(R,Q,N,_e,Me){var Ie=typeof R;(Ie==="undefined"||Ie==="boolean")&&(R=null);var Ye=!1;if(R===null)Ye=!0;else switch(Ie){case"string":case"number":Ye=!0;break;case"object":switch(R.$$typeof){case e:case t:Ye=!0}}if(Ye)return Ye=R,Me=Me(Ye),R=_e===""?"."+ue(Ye,0):_e,G(Me)?(N="",R!=null&&(N=R.replace(de,"$&/")+"/"),ie(Me,Q,N,"",function(xt){return xt})):Me!=null&&(H(Me)&&(Me=Se(Me,N+(!Me.key||Ye&&Ye.key===Me.key?"":(""+Me.key).replace(de,"$&/")+"/")+R)),Q.push(Me)),1;if(Ye=0,_e=_e===""?".":_e+":",G(R))for(var Ve=0;Ve<R.length;Ve++){Ie=R[Ve];var Je=_e+ue(Ie,Ve);Ye+=ie(Ie,Q,N,Je,Me)}else if(Je=b(R),typeof Je=="function")for(R=Je.call(R),Ve=0;!(Ie=R.next()).done;)Ie=Ie.value,Je=_e+ue(Ie,Ve++),Ye+=ie(Ie,Q,N,Je,Me);else if(Ie==="object")throw Q=String(R),Error("Objects are not valid as a React child (found: "+(Q==="[object Object]"?"object with keys {"+Object.keys(R).join(", ")+"}":Q)+"). If you meant to render a collection of children, use an array instead.");return Ye}function ge(R,Q,N){if(R==null)return R;var _e=[],Me=0;return ie(R,_e,"","",function(Ie){return Q.call(N,Ie,Me++)}),_e}function we(R){if(R._status===-1){var Q=R._result;Q=Q(),Q.then(function(N){(R._status===0||R._status===-1)&&(R._status=1,R._result=N)},function(N){(R._status===0||R._status===-1)&&(R._status=2,R._result=N)}),R._status===-1&&(R._status=0,R._result=Q)}if(R._status===1)return R._result.default;throw R._result}var ae={current:null},V={transition:null},ee={ReactCurrentDispatcher:ae,ReactCurrentBatchConfig:V,ReactCurrentOwner:B};function w(){throw Error("act(...) is not supported in production builds of React.")}return Pe.Children={map:ge,forEach:function(R,Q,N){ge(R,function(){Q.apply(this,arguments)},N)},count:function(R){var Q=0;return ge(R,function(){Q++}),Q},toArray:function(R){return ge(R,function(Q){return Q})||[]},only:function(R){if(!H(R))throw Error("React.Children.only expected to receive a single React element child.");return R}},Pe.Component=C,Pe.Fragment=n,Pe.Profiler=o,Pe.PureComponent=M,Pe.StrictMode=r,Pe.Suspense=f,Pe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ee,Pe.act=w,Pe.cloneElement=function(R,Q,N){if(R==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+R+".");var _e=_({},R.props),Me=R.key,Ie=R.ref,Ye=R._owner;if(Q!=null){if(Q.ref!==void 0&&(Ie=Q.ref,Ye=B.current),Q.key!==void 0&&(Me=""+Q.key),R.type&&R.type.defaultProps)var Ve=R.type.defaultProps;for(Je in Q)q.call(Q,Je)&&!te.hasOwnProperty(Je)&&(_e[Je]=Q[Je]===void 0&&Ve!==void 0?Ve[Je]:Q[Je])}var Je=arguments.length-2;if(Je===1)_e.children=N;else if(1<Je){Ve=Array(Je);for(var xt=0;xt<Je;xt++)Ve[xt]=arguments[xt+2];_e.children=Ve}return{$$typeof:e,type:R.type,key:Me,ref:Ie,props:_e,_owner:Ye}},Pe.createContext=function(R){return R={$$typeof:a,_currentValue:R,_currentValue2:R,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},R.Provider={$$typeof:u,_context:R},R.Consumer=R},Pe.createElement=Te,Pe.createFactory=function(R){var Q=Te.bind(null,R);return Q.type=R,Q},Pe.createRef=function(){return{current:null}},Pe.forwardRef=function(R){return{$$typeof:c,render:R}},Pe.isValidElement=H,Pe.lazy=function(R){return{$$typeof:m,_payload:{_status:-1,_result:R},_init:we}},Pe.memo=function(R,Q){return{$$typeof:h,type:R,compare:Q===void 0?null:Q}},Pe.startTransition=function(R){var Q=V.transition;V.transition={};try{R()}finally{V.transition=Q}},Pe.unstable_act=w,Pe.useCallback=function(R,Q){return ae.current.useCallback(R,Q)},Pe.useContext=function(R){return ae.current.useContext(R)},Pe.useDebugValue=function(){},Pe.useDeferredValue=function(R){return ae.current.useDeferredValue(R)},Pe.useEffect=function(R,Q){return ae.current.useEffect(R,Q)},Pe.useId=function(){return ae.current.useId()},Pe.useImperativeHandle=function(R,Q,N){return ae.current.useImperativeHandle(R,Q,N)},Pe.useInsertionEffect=function(R,Q){return ae.current.useInsertionEffect(R,Q)},Pe.useLayoutEffect=function(R,Q){return ae.current.useLayoutEffect(R,Q)},Pe.useMemo=function(R,Q){return ae.current.useMemo(R,Q)},Pe.useReducer=function(R,Q,N){return ae.current.useReducer(R,Q,N)},Pe.useRef=function(R){return ae.current.useRef(R)},Pe.useState=function(R){return ae.current.useState(R)},Pe.useSyncExternalStore=function(R,Q,N){return ae.current.useSyncExternalStore(R,Q,N)},Pe.useTransition=function(){return ae.current.useTransition()},Pe.version="18.3.1",Pe}var mn;function ms(){return mn||(mn=1,gt.exports=kt()),gt.exports}var ko;function Xc(){if(ko)return At;ko=1;var e=ms(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,u={key:!0,ref:!0,__self:!0,__source:!0};function a(c,f,h){var m,E={},b=null,T=null;h!==void 0&&(b=""+h),f.key!==void 0&&(b=""+f.key),f.ref!==void 0&&(T=f.ref);for(m in f)r.call(f,m)&&!u.hasOwnProperty(m)&&(E[m]=f[m]);if(c&&c.defaultProps)for(m in f=c.defaultProps,f)E[m]===void 0&&(E[m]=f[m]);return{$$typeof:t,type:c,key:b,ref:T,props:E,_owner:o.current}}return At.Fragment=n,At.jsx=a,At.jsxs=a,At}var tr;function Ex(){return tr||(tr=1,ut.exports=Xc()),ut.exports}var I=Ex();const br=Object.create(null);br.open="0",br.close="1",br.ping="2",br.pong="3",br.message="4",br.upgrade="5",br.noop="6";const aa=Object.create(null);Object.keys(br).forEach(e=>{aa[br[e]]=e});const Jc={type:"error",data:"parser error"},Om=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",Im=typeof ArrayBuffer=="function",Pm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Zc=({type:e,data:t},n,r)=>Om&&t instanceof Blob?n?r(t):Rm(t,r):Im&&(t instanceof ArrayBuffer||Pm(t))?n?r(t):Rm(new Blob([t]),r):r(br[e]+(t||"")),Rm=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function Lm(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let ef;function yx(e,t){if(Om&&e.data instanceof Blob)return e.data.arrayBuffer().then(Lm).then(t);if(Im&&(e.data instanceof ArrayBuffer||Pm(e.data)))return t(Lm(e.data));Zc(e,!1,n=>{ef||(ef=new TextEncoder),t(ef.encode(n))})}const Dm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",No=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<Dm.length;e++)No[Dm.charCodeAt(e)]=e;const Tx=e=>{let t=e.length*.75,n=e.length,r,o=0,u,a,c,f;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const h=new ArrayBuffer(t),m=new Uint8Array(h);for(r=0;r<n;r+=4)u=No[e.charCodeAt(r)],a=No[e.charCodeAt(r+1)],c=No[e.charCodeAt(r+2)],f=No[e.charCodeAt(r+3)],m[o++]=u<<2|a>>4,m[o++]=(a&15)<<4|c>>2,m[o++]=(c&3)<<6|f&63;return h},bx=typeof ArrayBuffer=="function",tf=(e,t)=>{if(typeof e!="string")return{type:"message",data:Fm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:_x(e.substring(1),t)}:aa[n]?e.length>1?{type:aa[n],data:e.substring(1)}:{type:aa[n]}:Jc},_x=(e,t)=>{if(bx){const n=Tx(e);return Fm(n,t)}else return{base64:!0,data:e}},Fm=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},Mm="",xx=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((u,a)=>{Zc(u,!1,c=>{r[a]=c,++o===n&&t(r.join(Mm))})})},Sx=(e,t)=>{const n=e.split(Mm),r=[];for(let o=0;o<n.length;o++){const u=tf(n[o],t);if(r.push(u),u.type==="error")break}return r};function wx(){return new TransformStream({transform(e,t){yx(e,n=>{const r=n.length;let o;if(r<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,r);else if(r<65536){o=new Uint8Array(3);const u=new DataView(o.buffer);u.setUint8(0,126),u.setUint16(1,r)}else{o=new Uint8Array(9);const u=new DataView(o.buffer);u.setUint8(0,127),u.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let nf;function la(e){return e.reduce((t,n)=>t+n.length,0)}function ca(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let o=0;o<t;o++)n[o]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function Cx(e,t){nf||(nf=new TextDecoder);const n=[];let r=0,o=-1,u=!1;return new TransformStream({transform(a,c){for(n.push(a);;){if(r===0){if(la(n)<1)break;const f=ca(n,1);u=(f[0]&128)===128,o=f[0]&127,o<126?r=3:o===126?r=1:r=2}else if(r===1){if(la(n)<2)break;const f=ca(n,2);o=new DataView(f.buffer,f.byteOffset,f.length).getUint16(0),r=3}else if(r===2){if(la(n)<8)break;const f=ca(n,8),h=new DataView(f.buffer,f.byteOffset,f.length),m=h.getUint32(0);if(m>Math.pow(2,21)-1){c.enqueue(Jc);break}o=m*Math.pow(2,32)+h.getUint32(4),r=3}else{if(la(n)<o)break;const f=ca(n,o);c.enqueue(tf(u?f:nf.decode(f),t)),r=0}if(o===0||o>e){c.enqueue(Jc);break}}}})}const Bm=4;function Lt(e){if(e)return Ax(e)}function Ax(e){for(var t in Lt.prototype)e[t]=Lt.prototype[t];return e}Lt.prototype.on=Lt.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},Lt.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},Lt.prototype.off=Lt.prototype.removeListener=Lt.prototype.removeAllListeners=Lt.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,o=0;o<n.length;o++)if(r=n[o],r===t||r.fn===t){n.splice(o,1);break}return n.length===0&&delete this._callbacks["$"+e],this},Lt.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,o=n.length;r<o;++r)n[r].apply(this,t)}return this},Lt.prototype.emitReserved=Lt.prototype.emit,Lt.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},Lt.prototype.hasListeners=function(e){return!!this.listeners(e).length};const fa=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),zn=typeof self!="undefined"?self:typeof window!="undefined"?window:Function("return this")(),vx="arraybuffer";function dM(){}function Um(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const kx=zn.setTimeout,Nx=zn.clearTimeout;function da(e,t){t.useNativeTimers?(e.setTimeoutFn=kx.bind(zn),e.clearTimeoutFn=Nx.bind(zn)):(e.setTimeoutFn=zn.setTimeout.bind(zn),e.clearTimeoutFn=zn.clearTimeout.bind(zn))}const Ox=1.33;function Ix(e){return typeof e=="string"?Px(e):Math.ceil((e.byteLength||e.size)*Ox)}function Px(e){let t=0,n=0;for(let r=0,o=e.length;r<o;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function Hm(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Rx(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function Lx(e){let t={},n=e.split("&");for(let r=0,o=n.length;r<o;r++){let u=n[r].split("=");t[decodeURIComponent(u[0])]=decodeURIComponent(u[1])}return t}class Dx extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class rf extends Lt{constructor(t){super(),this.writable=!1,da(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new Dx(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=tf(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=Rx(t);return n.length?"?"+n:""}}class Fx extends rf{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};Sx(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,xx(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=Hm()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let zm=!1;try{zm=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const Mx=zm;function Bx(){}class Ux extends Fx{constructor(t){if(super(t),typeof location!="undefined"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location!="undefined"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(o,u)=>{this.onError("xhr post error",o,u)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class _r extends Lt{constructor(t,n,r){super(),this.createRequest=t,da(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=Um(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let o in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(o)&&r.setRequestHeader(o,this._opts.extraHeaders[o])}}catch(o){}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(o){}try{r.setRequestHeader("Accept","*/*")}catch(o){}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var o;r.readyState===3&&((o=this._opts.cookieJar)===null||o===void 0||o.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(o){this.setTimeoutFn(()=>{this._onError(o)},0);return}typeof document!="undefined"&&(this._index=_r.requestsCount++,_r.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr=="undefined"||this._xhr===null)){if(this._xhr.onreadystatechange=Bx,t)try{this._xhr.abort()}catch(n){}typeof document!="undefined"&&delete _r.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}if(_r.requestsCount=0,_r.requests={},typeof document!="undefined"){if(typeof attachEvent=="function")attachEvent("onunload",jm);else if(typeof addEventListener=="function"){const e="onpagehide"in zn?"pagehide":"unload";addEventListener(e,jm,!1)}}function jm(){for(let e in _r.requests)_r.requests.hasOwnProperty(e)&&_r.requests[e].abort()}const Hx=function(){const e=$m({xdomain:!1});return e&&e.responseType!==null}();class zx extends Ux{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=Hx&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new _r($m,this.uri(),t)}}function $m(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||Mx))return new XMLHttpRequest}catch(n){}if(!t)try{return new zn[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const Vm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class jx extends rf{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=Vm?{}:Um(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],o=n===t.length-1;Zc(r,this.supportsBinary,u=>{try{this.doWrite(r,u)}catch(a){}o&&fa(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws!="undefined"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=Hm()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const sf=zn.WebSocket||zn.MozWebSocket;class $x extends jx{createSocket(t,n,r){return Vm?new sf(t,n,r):n?new sf(t,n):new sf(t)}doWrite(t,n){this.ws.send(n)}}class Vx extends rf{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=Cx(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=wx();o.readable.pipeTo(t.writable),this._writer=o.writable.getWriter();const u=()=>{r.read().then(({done:c,value:f})=>{c||(this.onPacket(f),u())}).catch(c=>{})};u();const a={type:"open"};this.query.sid&&(a.data=`{"sid":"${this.query.sid}"}`),this._writer.write(a).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],o=n===t.length-1;this._writer.write(r).then(()=>{o&&fa(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const qx={websocket:$x,webtransport:Vx,polling:zx},Yx=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Wx=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function of(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let o=Yx.exec(e||""),u={},a=14;for(;a--;)u[Wx[a]]=o[a]||"";return n!=-1&&r!=-1&&(u.source=t,u.host=u.host.substring(1,u.host.length-1).replace(/;/g,":"),u.authority=u.authority.replace("[","").replace("]","").replace(/;/g,":"),u.ipv6uri=!0),u.pathNames=Gx(u,u.path),u.queryKey=Kx(u,u.query),u}function Gx(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function Kx(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,u){o&&(n[o]=u)}),n}const uf=typeof addEventListener=="function"&&typeof removeEventListener=="function",ha=[];uf&&addEventListener("offline",()=>{ha.forEach(e=>e())},!1);class ai extends Lt{constructor(t,n){if(super(),this.binaryType=vx,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=of(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=of(n.host).host);da(this,n),this.secure=n.secure!=null?n.secure:typeof location!="undefined"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location!="undefined"?location.hostname:"localhost"),this.port=n.port||(typeof location!="undefined"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const o=r.prototype.name;this.transports.push(o),this._transportsByName[o]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=Lx(this.opts.query)),uf&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},ha.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=Bm,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&ai.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",ai.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const o=this.writeBuffer[r].data;if(o&&(n+=Ix(o)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,fa(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const u={type:t,data:n,options:r};this.emitReserved("packetCreate",u),this.writeBuffer.push(u),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(ai.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),uf&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=ha.indexOf(this._offlineEventListener);r!==-1&&ha.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}ai.protocol=Bm;class Qx extends ai{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;ai.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",E=>{if(!r)if(E.type==="pong"&&E.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;ai.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(m(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const b=new Error("probe error");b.transport=n.name,this.emitReserved("upgradeError",b)}}))};function u(){r||(r=!0,m(),n.close(),n=null)}const a=E=>{const b=new Error("probe error: "+E);b.transport=n.name,u(),this.emitReserved("upgradeError",b)};function c(){a("transport closed")}function f(){a("socket closed")}function h(E){n&&E.name!==n.name&&u()}const m=()=>{n.removeListener("open",o),n.removeListener("error",a),n.removeListener("close",c),this.off("close",f),this.off("upgrading",h)};n.once("open",o),n.once("error",a),n.once("close",c),this.once("close",f),this.once("upgrading",h),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let Xx=class extends Qx{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(o=>qx[o]).filter(o=>!!o)),super(t,r)}};function Jx(e,t="",n){let r=e;n=n||typeof location!="undefined"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n!="undefined"?e=n.protocol+"//"+e:e="https://"+e),r=of(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const u=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+u+":"+r.port+t,r.href=r.protocol+"://"+u+(n&&n.port===r.port?"":":"+r.port),r}const Zx=typeof ArrayBuffer=="function",eS=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,qm=Object.prototype.toString,tS=typeof Blob=="function"||typeof Blob!="undefined"&&qm.call(Blob)==="[object BlobConstructor]",nS=typeof File=="function"||typeof File!="undefined"&&qm.call(File)==="[object FileConstructor]";function af(e){return Zx&&(e instanceof ArrayBuffer||eS(e))||tS&&e instanceof Blob||nS&&e instanceof File}function pa(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(pa(e[n]))return!0;return!1}if(af(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return pa(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&pa(e[n]))return!0;return!1}function rS(e){const t=[],n=e.data,r=e;return r.data=lf(n,t),r.attachments=t.length,{packet:r,buffers:t}}function lf(e,t){if(!e)return e;if(af(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=lf(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=lf(e[r],t));return n}return e}function iS(e,t){return e.data=cf(e.data,t),delete e.attachments,e}function cf(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=cf(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=cf(e[n],t));return e}const sS=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],oS=5;var Qe;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(Qe||(Qe={}));class uS{constructor(t){this.replacer=t}encode(t){return(t.type===Qe.EVENT||t.type===Qe.ACK)&&pa(t)?this.encodeAsBinary({type:t.type===Qe.EVENT?Qe.BINARY_EVENT:Qe.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Qe.BINARY_EVENT||t.type===Qe.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=rS(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}function Ym(e){return Object.prototype.toString.call(e)==="[object Object]"}class ff extends Lt{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===Qe.BINARY_EVENT;r||n.type===Qe.BINARY_ACK?(n.type=r?Qe.EVENT:Qe.ACK,this.reconstructor=new aS(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(af(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(Qe[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Qe.BINARY_EVENT||r.type===Qe.BINARY_ACK){const u=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const a=t.substring(u,n);if(a!=Number(a)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(a)}if(t.charAt(n+1)==="/"){const u=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(u,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const u=n+1;for(;++n;){const a=t.charAt(n);if(a==null||Number(a)!=a){--n;break}if(n===t.length)break}r.id=Number(t.substring(u,n+1))}if(t.charAt(++n)){const u=this.tryParse(t.substr(n));if(ff.isPayloadValid(r.type,u))r.data=u;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch(n){return!1}}static isPayloadValid(t,n){switch(t){case Qe.CONNECT:return Ym(n);case Qe.DISCONNECT:return n===void 0;case Qe.CONNECT_ERROR:return typeof n=="string"||Ym(n);case Qe.EVENT:case Qe.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&sS.indexOf(n[0])===-1);case Qe.ACK:case Qe.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class aS{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=iS(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const lS=Object.freeze(Object.defineProperty({__proto__:null,Decoder:ff,Encoder:uS,get PacketType(){return Qe},protocol:oS},Symbol.toStringTag,{value:"Module"}));function nr(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const cS=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class Wm extends Lt{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[nr(t,"open",this.onopen.bind(this)),nr(t,"packet",this.onpacket.bind(this)),nr(t,"error",this.onerror.bind(this)),nr(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,o,u;if(cS.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const a={type:Qe.EVENT,data:n};if(a.options={},a.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const m=this.ids++,E=n.pop();this._registerAckCallback(m,E),a.id=m}const c=(o=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||o===void 0?void 0:o.writable,f=this.connected&&!(!((u=this.io.engine)===null||u===void 0)&&u._hasPingExpired());return this.flags.volatile&&!c||(f?(this.notifyOutgoingListeners(a),this.packet(a)):this.sendBuffer.push(a)),this.flags={},this}_registerAckCallback(t,n){var r;const o=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(o===void 0){this.acks[t]=n;return}const u=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let c=0;c<this.sendBuffer.length;c++)this.sendBuffer[c].id===t&&this.sendBuffer.splice(c,1);n.call(this,new Error("operation has timed out"))},o),a=(...c)=>{this.io.clearTimeoutFn(u),n.apply(this,c)};a.withError=!0,this.acks[t]=a}emitWithAck(t,...n){return new Promise((r,o)=>{const u=(a,c)=>a?o(a):r(c);u.withError=!0,n.push(u),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((o,...u)=>r!==this._queue[0]?void 0:(o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...u)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:Qe.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case Qe.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case Qe.EVENT:case Qe.BINARY_EVENT:this.onevent(t);break;case Qe.ACK:case Qe.BINARY_ACK:this.onack(t);break;case Qe.DISCONNECT:this.ondisconnect();break;case Qe.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...o){r||(r=!0,n.packet({type:Qe.ACK,id:t,data:o}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:Qe.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function gs(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}gs.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=(Math.floor(t*10)&1)==0?e-n:e+n}return Math.min(e,this.max)|0},gs.prototype.reset=function(){this.attempts=0},gs.prototype.setMin=function(e){this.ms=e},gs.prototype.setMax=function(e){this.max=e},gs.prototype.setJitter=function(e){this.jitter=e};class df extends Lt{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,da(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new gs({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||lS;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new Xx(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=nr(n,"open",function(){r.onopen(),t&&t()}),u=c=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",c),t?t(c):this.maybeReconnectOnOpen()},a=nr(n,"error",u);if(this._timeout!==!1){const c=this._timeout,f=this.setTimeoutFn(()=>{o(),u(new Error("timeout")),n.close()},c);this.opts.autoUnref&&f.unref(),this.subs.push(()=>{this.clearTimeoutFn(f)})}return this.subs.push(o),this.subs.push(a),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(nr(t,"ping",this.onping.bind(this)),nr(t,"data",this.ondata.bind(this)),nr(t,"error",this.onerror.bind(this)),nr(t,"close",this.onclose.bind(this)),nr(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){fa(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new Wm(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const Oo={};function ma(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=Jx(e,t.path||"/socket.io"),r=n.source,o=n.id,u=n.path,a=Oo[o]&&u in Oo[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||a;let f;return c?f=new df(r,t):(Oo[o]||(Oo[o]=new df(r,t)),f=Oo[o]),n.query&&!t.query&&(t.query=n.queryKey),f.socket(n.path,t)}Object.assign(ma,{Manager:df,Socket:Wm,io:ma,connect:ma});var fS=function(e){return function(t){return!!t&&typeof t=="object"}(e)&&!function(t){var n=Object.prototype.toString.call(t);return n==="[object RegExp]"||n==="[object Date]"||function(r){return r.$$typeof===dS}(t)}(e)},dS=typeof Symbol=="function"&&Symbol.for?Symbol.for("react.element"):60103;function Io(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Es((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function hS(e,t,n){return e.concat(t).map(function(r){return Io(r,n)})}function Gm(e){return Object.keys(e).concat(function(t){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter(function(n){return Object.propertyIsEnumerable.call(t,n)}):[]}(e))}function Km(e,t){try{return t in e}catch(n){return!1}}function pS(e,t,n){var r={};return n.isMergeableObject(e)&&Gm(e).forEach(function(o){r[o]=Io(e[o],n)}),Gm(t).forEach(function(o){(function(u,a){return Km(u,a)&&!(Object.hasOwnProperty.call(u,a)&&Object.propertyIsEnumerable.call(u,a))})(e,o)||(Km(e,o)&&n.isMergeableObject(t[o])?r[o]=function(u,a){if(!a.customMerge)return Es;var c=a.customMerge(u);return typeof c=="function"?c:Es}(o,n)(e[o],t[o],n):r[o]=Io(t[o],n))}),r}function Es(e,t,n){(n=n||{}).arrayMerge=n.arrayMerge||hS,n.isMergeableObject=n.isMergeableObject||fS,n.cloneUnlessOtherwiseSpecified=Io;var r=Array.isArray(t);return r===Array.isArray(e)?r?n.arrayMerge(e,t,n):pS(e,t,n):Io(t,n)}Es.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(n,r){return Es(n,r,t)},{})};var mS=Es;class gS{constructor(t){Object.assign(this,t)}}function fn(e){if(e)return function(t){for(var n in fn.prototype)t[n]=fn.prototype[n];return t}(e)}fn.prototype.on=fn.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},fn.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},fn.prototype.off=fn.prototype.removeListener=fn.prototype.removeAllListeners=fn.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return r.length===0&&delete this._callbacks["$"+e],this},fn.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t)}return this},fn.prototype.emitReserved=fn.prototype.emit,fn.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},fn.prototype.hasListeners=function(e){return!!this.listeners(e).length};const ES=typeof ArrayBuffer=="function",Qm=Object.prototype.toString,yS=typeof Blob=="function"||typeof Blob!="undefined"&&Qm.call(Blob)==="[object BlobConstructor]",TS=typeof File=="function"||typeof File!="undefined"&&Qm.call(File)==="[object FileConstructor]";function hf(e){return ES&&(e instanceof ArrayBuffer||(t=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(t):t.buffer instanceof ArrayBuffer)(e))||yS&&e instanceof Blob||TS&&e instanceof File}function ga(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ga(e[n]))return!0;return!1}if(hf(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ga(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ga(e[n]))return!0;return!1}function bS(e){const t=[],n=e.data,r=e;return r.data=pf(n,t),r.attachments=t.length,{packet:r,buffers:t}}function pf(e,t){if(!e)return e;if(hf(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=pf(e[r],t);return n}if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=pf(e[r],t));return n}return e}function _S(e,t){return e.data=mf(e.data,t),delete e.attachments,e}function mf(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=mf(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=mf(e[n],t));return e}const xS=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var _t;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(_t||(_t={}));class SS{constructor(t){this.replacer=t}encode(t){return t.type!==_t.EVENT&&t.type!==_t.ACK||!ga(t)?[this.encodeAsString(t)]:this.encodeAsBinary({type:t.type===_t.EVENT?_t.BINARY_EVENT:_t.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id})}encodeAsString(t){let n=""+t.type;return t.type!==_t.BINARY_EVENT&&t.type!==_t.BINARY_ACK||(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=bS(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}function Xm(e){return Object.prototype.toString.call(e)==="[object Object]"}class gf extends fn{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===_t.BINARY_EVENT;r||n.type===_t.BINARY_ACK?(n.type=r?_t.EVENT:_t.ACK,this.reconstructor=new wS(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else{if(!hf(t)&&!t.base64)throw new Error("Unknown type: "+t);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n))}}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(_t[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===_t.BINARY_EVENT||r.type===_t.BINARY_ACK){const u=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const a=t.substring(u,n);if(a!=Number(a)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(a)}if(t.charAt(n+1)==="/"){const u=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(u,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const u=n+1;for(;++n;){const a=t.charAt(n);if(a==null||Number(a)!=a){--n;break}if(n===t.length)break}r.id=Number(t.substring(u,n+1))}if(t.charAt(++n)){const u=this.tryParse(t.substr(n));if(!gf.isPayloadValid(r.type,u))throw new Error("invalid payload");r.data=u}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch(n){return!1}}static isPayloadValid(t,n){switch(t){case _t.CONNECT:return Xm(n);case _t.DISCONNECT:return n===void 0;case _t.CONNECT_ERROR:return typeof n=="string"||Xm(n);case _t.EVENT:case _t.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&xS.indexOf(n[0])===-1);case _t.ACK:case _t.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class wS{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=_S(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Jm=["searchParams.facetFilters","browseParams.facetFilters","hits","products"],Zm=(e,t,n)=>function r(o,u=[]){const a=Object.entries(o).map(([c,f])=>{const h=[...u,t(c)];return[e(c),f instanceof Object&&!(n!=null&&n.includes(h.join(".")))?r(f,h):f]});return Array.isArray(o)?a.map(c=>c[1]):Object.fromEntries(a)},e0=e=>e.replace(/_([a-z])/g,(t,n)=>n.toUpperCase()),CS=Zm(e=>e.replace(/([A-Z])/g,"_$1").toLowerCase(),e=>e,Jm),AS=Zm(e0,e0,Jm),vS={Encoder:class extends SS{encode(e){var t,n;return super.encode(ye(U({},e),{data:((t=e.data)==null?void 0:t.length)==2?[e.data[0],CS(e.data[1])]:((n=e.data)==null?void 0:n.length)==1?[e.data[0]]:typeof e.data=="object"&&e.data!=null?e.data:void 0}))}},Decoder:class extends gf{constructor(){super((e,t)=>e==""&&Array.isArray(t)?t.map(n=>n instanceof Object?AS(n):n):t)}}},kS={path:"/api/v1/socket.io",autoConnect:!1,transports:["polling","websocket"],upgrade:!0,timeout:1e4};class NS{constructor({apiKey:t,apiToken:n,baseUrl:r,namespace:o="/copilot",socketOptions:u={}}){if(this.sessionIdKey="x-cimulate-copilot-session-id",this.reconnectAttempts=0,this.maxReconnectAttempts=5,this.maxReconnectDelay=3e4,this.handleConnectAck=h=>{console.log("[Copilot SDK] Connect Ack:",h),this.socket.auth={[this.sessionIdKey]:h.sessionId}},this.handleDisconnect=h=>{console.warn(`[Copilot SDK] Disconnected: ${h}`),h!=="io client disconnect"&&(console.log(`[Copilot SDK] Disconnected due to ${h}. Attempting reconnect...`),this.retryConnect())},this.handleConnectError=h=>{console.error(`[Copilot SDK] Connect error: ${h.message}`);const m=h.message.match(/['"]error['"]:\s*['"](\w+)['"]/),E=m==null?void 0:m[1];E&&["InvalidApiKey","InvalidToken","BadRequest"].includes(E)?this.disconnect():this.socket.connected||this.socket.active||(console.log("[Copilot SDK] Retrying connect attempt..."),this.retryConnect())},this.offInternalHandlers=()=>{this.socket.off("connect_ack",this.handleConnectAck),this.socket.off("disconnect",this.handleDisconnect),this.off("connect_error",this.handleConnectError)},t&&n||!t&&!n)throw new Error("Provide exactly one authentication method: either 'apiKey' or 'apiToken', but not both.");const a=`${r}${o}`,c={};t?c["x-cimulate-api-key"]=t:n&&(c.Authorization=`Bearer ${n}`);const f=[kS,u,{parser:vS,withCredentials:!0,transportOptions:{polling:{extraHeaders:c}}}];this.socket=ma(a,mS.all(f))}connect(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0,this.reconnectAttempts=0),this.offInternalHandlers(),this.on("connect_ack",this.handleConnectAck),this.socket.on("disconnect",this.handleDisconnect),this.on("connect_error",this.handleConnectError),this.socket.auth&&this.sessionIdKey in this.socket.auth&&(this.socket.auth={}),this.socket.connect()}retryConnect(){if(!(this.socket.connected||this.socket.active||this.reconnectAttempts>=this.maxReconnectAttempts))if(this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0),this.reconnectAttempts<this.maxReconnectAttempts){const t=Math.min(1e3*Kc(2,this.reconnectAttempts),this.maxReconnectDelay);console.info(`[Copilot SDK] Retry #${this.reconnectAttempts+1} in ${t}ms...`),this.reconnectTimeout=setTimeout(()=>{this.socket.connected||this.socket.active||(this.reconnectAttempts++,this.reconnect())},t)}else console.error("[Copilot SDK] Max reconnect attempts reached.")}reconnect(){this.socket.connected||this.socket.active||this.reconnectAttempts>=this.maxReconnectAttempts||(this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0,this.reconnectAttempts=0),this.socket.connect())}browse(t,n){return st(this,null,function*(){return this.asyncResponse("copilot_browse",t,n)})}search(t,n){return st(this,null,function*(){return this.asyncResponse("copilot_search",t,n)})}facetedNavigation(t,n){return st(this,null,function*(){return this.asyncResponse("faceted_navigation",t,n)})}cancelRequest(t,n){return this.asyncResponse("cancel",t,n)}conversationReset(t,n){return this.asyncResponse("conversation_reset",t,n)}productView(t,n){return st(this,null,function*(){return this.asyncResponse("product_view",t,n)})}requestSessionInformation(t){return st(this,null,function*(){return new Promise(n=>{this.socket.emit("session_info",r=>{t&&t(r),n(r)})})})}getConversationEvents(t,n){return st(this,null,function*(){return new Promise(r=>{this.socket.emit("conversation_events",t,o=>{n&&n(o),r(o)})})})}on(t,n){return this.socket.on(t,n),n}once(t,n){this.socket.once(t,n)}off(t,n){this.socket.off(t,n)}disconnect(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=void 0),this.offInternalHandlers(),this.socket.disconnect()}onDisconnect(t){this.socket.on("disconnect",t)}asyncResponse(t,n,r){return st(this,null,function*(){if(r)return void this.socket.emit(t,n,r);let o="";const u=function(a){return Qc(this,null,function*(){const c=[];let f=!1,h=null;const m=yield new Hr(a({emit:E=>{c.push(E),h&&(h(),h=null)},cancel:()=>{f=!0}}));try{for(;!f;)c.length>0?yield c.shift():yield new Hr(new Promise(E=>{h=E}));for(;c.length>0;)yield c.shift()}finally{yield new Hr(m==null?void 0:m())}})}(({emit:a,cancel:c})=>{const f=(h,m)=>{["done","error"].includes(m.name)&&c(),m.eventSourceId==o&&a(m)};return this.socket.onAny(f),()=>st(this,null,function*(){this.socket.offAny(f)})});return{result:yield new Promise((a,c)=>this.socket.emit(t,n,f=>{f.name==="error"?c(new gS(f)):(o=f==null?void 0:f.id,a(f))})),events:u}})}}var W=ms();const Bi=Ge(W);function t0(e,t){return function(){return e.apply(t,arguments)}}const{toString:OS}=Object.prototype,{getPrototypeOf:Ef}=Object,{iterator:Ea,toStringTag:n0}=Symbol,ya=(e=>t=>{const n=OS.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),rr=e=>(e=e.toLowerCase(),t=>ya(t)===e),Ta=e=>t=>typeof t===e,{isArray:ys}=Array,Ts=Ta("undefined");function Po(e){return e!==null&&!Ts(e)&&e.constructor!==null&&!Ts(e.constructor)&&gn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const r0=rr("ArrayBuffer");function IS(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&r0(e.buffer),t}const PS=Ta("string"),gn=Ta("function"),i0=Ta("number"),Ro=e=>e!==null&&typeof e=="object",RS=e=>e===!0||e===!1,ba=e=>{if(ya(e)!=="object")return!1;const t=Ef(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(n0 in e)&&!(Ea in e)},LS=e=>{if(!Ro(e)||Po(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},DS=rr("Date"),FS=rr("File"),MS=rr("Blob"),BS=rr("FileList"),US=e=>Ro(e)&&gn(e.pipe),HS=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||gn(e.append)&&((t=ya(e))==="formdata"||t==="object"&&gn(e.toString)&&e.toString()==="[object FormData]"))},zS=rr("URLSearchParams"),[jS,$S,VS,qS]=["ReadableStream","Request","Response","Headers"].map(rr),YS=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Lo(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),ys(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(Po(e))return;const u=n?Object.getOwnPropertyNames(e):Object.keys(e),a=u.length;let c;for(r=0;r<a;r++)c=u[r],t.call(null,e[c],c,e)}}function s0(e,t){if(Po(e))return null;t=t.toLowerCase();const n=Object.keys(e);let r=n.length,o;for(;r-- >0;)if(o=n[r],t===o.toLowerCase())return o;return null}const Ui=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,o0=e=>!Ts(e)&&e!==Ui;function yf(){const{caseless:e,skipUndefined:t}=o0(this)&&this||{},n={},r=(o,u)=>{const a=e&&s0(n,u)||u;ba(n[a])&&ba(o)?n[a]=yf(n[a],o):ba(o)?n[a]=yf({},o):ys(o)?n[a]=o.slice():(!t||!Ts(o))&&(n[a]=o)};for(let o=0,u=arguments.length;o<u;o++)arguments[o]&&Lo(arguments[o],r);return n}const WS=(e,t,n,{allOwnKeys:r}={})=>(Lo(t,(o,u)=>{n&&gn(o)?e[u]=t0(o,n):e[u]=o},{allOwnKeys:r}),e),GS=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),KS=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},QS=(e,t,n,r)=>{let o,u,a;const c={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),u=o.length;u-- >0;)a=o[u],(!r||r(a,e,t))&&!c[a]&&(t[a]=e[a],c[a]=!0);e=n!==!1&&Ef(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},XS=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},JS=e=>{if(!e)return null;if(ys(e))return e;let t=e.length;if(!i0(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},ZS=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&Ef(Uint8Array)),ew=(e,t)=>{const r=(e&&e[Ea]).call(e);let o;for(;(o=r.next())&&!o.done;){const u=o.value;t.call(e,u[0],u[1])}},tw=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},nw=rr("HTMLFormElement"),rw=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),u0=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),iw=rr("RegExp"),a0=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Lo(n,(o,u)=>{let a;(a=t(o,u,e))!==!1&&(r[u]=a||o)}),Object.defineProperties(e,r)},sw=e=>{a0(e,(t,n)=>{if(gn(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(gn(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},ow=(e,t)=>{const n={},r=o=>{o.forEach(u=>{n[u]=!0})};return ys(e)?r(e):r(String(e).split(t)),n},uw=()=>{},aw=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function lw(e){return!!(e&&gn(e.append)&&e[n0]==="FormData"&&e[Ea])}const cw=e=>{const t=new Array(10),n=(r,o)=>{if(Ro(r)){if(t.indexOf(r)>=0)return;if(Po(r))return r;if(!("toJSON"in r)){t[o]=r;const u=ys(r)?[]:{};return Lo(r,(a,c)=>{const f=n(a,o+1);!Ts(f)&&(u[c]=f)}),t[o]=void 0,u}}return r};return n(e,0)},fw=rr("AsyncFunction"),dw=e=>e&&(Ro(e)||gn(e))&&gn(e.then)&&gn(e.catch),l0=((e,t)=>e?setImmediate:t?((n,r)=>(Ui.addEventListener("message",({source:o,data:u})=>{o===Ui&&u===n&&r.length&&r.shift()()},!1),o=>{r.push(o),Ui.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",gn(Ui.postMessage)),hw=typeof queueMicrotask!="undefined"?queueMicrotask.bind(Ui):typeof process!="undefined"&&process.nextTick||l0,K={isArray:ys,isArrayBuffer:r0,isBuffer:Po,isFormData:HS,isArrayBufferView:IS,isString:PS,isNumber:i0,isBoolean:RS,isObject:Ro,isPlainObject:ba,isEmptyObject:LS,isReadableStream:jS,isRequest:$S,isResponse:VS,isHeaders:qS,isUndefined:Ts,isDate:DS,isFile:FS,isBlob:MS,isRegExp:iw,isFunction:gn,isStream:US,isURLSearchParams:zS,isTypedArray:ZS,isFileList:BS,forEach:Lo,merge:yf,extend:WS,trim:YS,stripBOM:GS,inherits:KS,toFlatObject:QS,kindOf:ya,kindOfTest:rr,endsWith:XS,toArray:JS,forEachEntry:ew,matchAll:tw,isHTMLForm:nw,hasOwnProperty:u0,hasOwnProp:u0,reduceDescriptors:a0,freezeMethods:sw,toObjectSet:ow,toCamelCase:rw,noop:uw,toFiniteNumber:aw,findKey:s0,global:Ui,isContextDefined:o0,isSpecCompliantForm:lw,toJSONObject:cw,isAsyncFn:fw,isThenable:dw,setImmediate:l0,asap:hw,isIterable:e=>e!=null&&gn(e[Ea])};function ze(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o,this.status=o.status?o.status:null)}K.inherits(ze,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:K.toJSONObject(this.config),code:this.code,status:this.status}}});const c0=ze.prototype,f0={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{f0[e]={value:e}}),Object.defineProperties(ze,f0),Object.defineProperty(c0,"isAxiosError",{value:!0}),ze.from=(e,t,n,r,o,u)=>{const a=Object.create(c0);K.toFlatObject(e,a,function(m){return m!==Error.prototype},h=>h!=="isAxiosError");const c=e&&e.message?e.message:"Error",f=t==null&&e?e.code:t;return ze.call(a,c,f,n,r,o),e&&a.cause==null&&Object.defineProperty(a,"cause",{value:e,configurable:!0}),a.name=e&&e.name||"Error",u&&Object.assign(a,u),a};const pw=null;function Tf(e){return K.isPlainObject(e)||K.isArray(e)}function d0(e){return K.endsWith(e,"[]")?e.slice(0,-2):e}function h0(e,t,n){return e?e.concat(t).map(function(o,u){return o=d0(o),!n&&u?"["+o+"]":o}).join(n?".":""):t}function mw(e){return K.isArray(e)&&!e.some(Tf)}const gw=K.toFlatObject(K,{},null,function(t){return/^is[A-Z]/.test(t)});function _a(e,t,n){if(!K.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=K.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,C){return!K.isUndefined(C[S])});const r=n.metaTokens,o=n.visitor||m,u=n.dots,a=n.indexes,f=(n.Blob||typeof Blob!="undefined"&&Blob)&&K.isSpecCompliantForm(t);if(!K.isFunction(o))throw new TypeError("visitor must be a function");function h(_){if(_===null)return"";if(K.isDate(_))return _.toISOString();if(K.isBoolean(_))return _.toString();if(!f&&K.isBlob(_))throw new ze("Blob is not supported. Use a Buffer instead.");return K.isArrayBuffer(_)||K.isTypedArray(_)?f&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function m(_,S,C){let k=_;if(_&&!C&&typeof _=="object"){if(K.endsWith(S,"{}"))S=r?S:S.slice(0,-2),_=JSON.stringify(_);else if(K.isArray(_)&&mw(_)||(K.isFileList(_)||K.endsWith(S,"[]"))&&(k=K.toArray(_)))return S=d0(S),k.forEach(function(D,G){!(K.isUndefined(D)||D===null)&&t.append(a===!0?h0([S],G,u):a===null?S:S+"[]",h(D))}),!1}return Tf(_)?!0:(t.append(h0(C,S,u),h(_)),!1)}const E=[],b=Object.assign(gw,{defaultVisitor:m,convertValue:h,isVisitable:Tf});function T(_,S){if(!K.isUndefined(_)){if(E.indexOf(_)!==-1)throw Error("Circular reference detected in "+S.join("."));E.push(_),K.forEach(_,function(k,M){(!(K.isUndefined(k)||k===null)&&o.call(t,k,K.isString(M)?M.trim():M,S,b))===!0&&T(k,S?S.concat(M):[M])}),E.pop()}}if(!K.isObject(e))throw new TypeError("data must be an object");return T(e),t}function p0(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function bf(e,t){this._pairs=[],e&&_a(e,this,t)}const m0=bf.prototype;m0.append=function(t,n){this._pairs.push([t,n])},m0.toString=function(t){const n=t?function(r){return t.call(this,r,p0)}:p0;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Ew(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function g0(e,t,n){if(!t)return e;const r=n&&n.encode||Ew;K.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let u;if(o?u=o(t,n):u=K.isURLSearchParams(t)?t.toString():new bf(t,n).toString(r),u){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class E0{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){K.forEach(this.handlers,function(r){r!==null&&t(r)})}}const y0={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},yw={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:bf,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},_f=typeof window!="undefined"&&typeof document!="undefined",xf=typeof navigator=="object"&&navigator||void 0,Tw=_f&&(!xf||["ReactNative","NativeScript","NS"].indexOf(xf.product)<0),bw=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",_w=_f&&window.location.href||"http://localhost",tn=U(U({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:_f,hasStandardBrowserEnv:Tw,hasStandardBrowserWebWorkerEnv:bw,navigator:xf,origin:_w},Symbol.toStringTag,{value:"Module"}))),yw);function xw(e,t){return _a(e,new tn.classes.URLSearchParams,U({visitor:function(n,r,o,u){return tn.isNode&&K.isBuffer(n)?(this.append(r,n.toString("base64")),!1):u.defaultVisitor.apply(this,arguments)}},t))}function Sw(e){return K.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function ww(e){const t={},n=Object.keys(e);let r;const o=n.length;let u;for(r=0;r<o;r++)u=n[r],t[u]=e[u];return t}function T0(e){function t(n,r,o,u){let a=n[u++];if(a==="__proto__")return!0;const c=Number.isFinite(+a),f=u>=n.length;return a=!a&&K.isArray(o)?o.length:a,f?(K.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!c):((!o[a]||!K.isObject(o[a]))&&(o[a]=[]),t(n,r,o[a],u)&&K.isArray(o[a])&&(o[a]=ww(o[a])),!c)}if(K.isFormData(e)&&K.isFunction(e.entries)){const n={};return K.forEachEntry(e,(r,o)=>{t(Sw(r),o,n,0)}),n}return null}function Cw(e,t,n){if(K.isString(e))try{return(t||JSON.parse)(e),K.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Do={transitional:y0,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,u=K.isObject(t);if(u&&K.isHTMLForm(t)&&(t=new FormData(t)),K.isFormData(t))return o?JSON.stringify(T0(t)):t;if(K.isArrayBuffer(t)||K.isBuffer(t)||K.isStream(t)||K.isFile(t)||K.isBlob(t)||K.isReadableStream(t))return t;if(K.isArrayBufferView(t))return t.buffer;if(K.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(u){if(r.indexOf("application/x-www-form-urlencoded")>-1)return xw(t,this.formSerializer).toString();if((c=K.isFileList(t))||r.indexOf("multipart/form-data")>-1){const f=this.env&&this.env.FormData;return _a(c?{"files[]":t}:t,f&&new f,this.formSerializer)}}return u||o?(n.setContentType("application/json",!1),Cw(t)):t}],transformResponse:[function(t){const n=this.transitional||Do.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(K.isResponse(t)||K.isReadableStream(t))return t;if(t&&K.isString(t)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(t,this.parseReviver)}catch(c){if(a)throw c.name==="SyntaxError"?ze.from(c,ze.ERR_BAD_RESPONSE,this,null,this.response):c}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:tn.classes.FormData,Blob:tn.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};K.forEach(["delete","get","head","post","put","patch"],e=>{Do.headers[e]={}});const Aw=K.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),vw=e=>{const t={};let n,r,o;return e&&e.split(`
3
+ `).forEach(function(a){o=a.indexOf(":"),n=a.substring(0,o).trim().toLowerCase(),r=a.substring(o+1).trim(),!(!n||t[n]&&Aw[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},b0=Symbol("internals");function Fo(e){return e&&String(e).trim().toLowerCase()}function xa(e){return e===!1||e==null?e:K.isArray(e)?e.map(xa):String(e)}function kw(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const Nw=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Sf(e,t,n,r,o){if(K.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!K.isString(t)){if(K.isString(r))return t.indexOf(r)!==-1;if(K.isRegExp(r))return r.test(t)}}function Ow(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function Iw(e,t){const n=K.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(o,u,a){return this[r].call(this,t,o,u,a)},configurable:!0})})}let En=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function u(c,f,h){const m=Fo(f);if(!m)throw new Error("header name must be a non-empty string");const E=K.findKey(o,m);(!E||o[E]===void 0||h===!0||h===void 0&&o[E]!==!1)&&(o[E||f]=xa(c))}const a=(c,f)=>K.forEach(c,(h,m)=>u(h,m,f));if(K.isPlainObject(t)||t instanceof this.constructor)a(t,n);else if(K.isString(t)&&(t=t.trim())&&!Nw(t))a(vw(t),n);else if(K.isObject(t)&&K.isIterable(t)){let c={},f,h;for(const m of t){if(!K.isArray(m))throw TypeError("Object iterator must return a key-value pair");c[h=m[0]]=(f=c[h])?K.isArray(f)?[...f,m[1]]:[f,m[1]]:m[1]}a(c,n)}else t!=null&&u(n,t,r);return this}get(t,n){if(t=Fo(t),t){const r=K.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return kw(o);if(K.isFunction(n))return n.call(this,o,r);if(K.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Fo(t),t){const r=K.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Sf(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function u(a){if(a=Fo(a),a){const c=K.findKey(r,a);c&&(!n||Sf(r,r[c],c,n))&&(delete r[c],o=!0)}}return K.isArray(t)?t.forEach(u):u(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const u=n[r];(!t||Sf(this,this[u],u,t,!0))&&(delete this[u],o=!0)}return o}normalize(t){const n=this,r={};return K.forEach(this,(o,u)=>{const a=K.findKey(r,u);if(a){n[a]=xa(o),delete n[u];return}const c=t?Ow(u):String(u).trim();c!==u&&delete n[u],n[c]=xa(o),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return K.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&K.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
4
+ `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(o=>r.set(o)),r}static accessor(t){const r=(this[b0]=this[b0]={accessors:{}}).accessors,o=this.prototype;function u(a){const c=Fo(a);r[c]||(Iw(o,a),r[c]=!0)}return K.isArray(t)?t.forEach(u):u(t),this}};En.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),K.reduceDescriptors(En.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),K.freezeMethods(En);function wf(e,t){const n=this||Do,r=t||n,o=En.from(r.headers);let u=r.data;return K.forEach(e,function(c){u=c.call(n,u,o.normalize(),t?t.status:void 0)}),o.normalize(),u}function _0(e){return!!(e&&e.__CANCEL__)}function bs(e,t,n){ze.call(this,e==null?"canceled":e,ze.ERR_CANCELED,t,n),this.name="CanceledError"}K.inherits(bs,ze,{__CANCEL__:!0});function x0(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ze("Request failed with status code "+n.status,[ze.ERR_BAD_REQUEST,ze.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function Pw(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Rw(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,u=0,a;return t=t!==void 0?t:1e3,function(f){const h=Date.now(),m=r[u];a||(a=h),n[o]=f,r[o]=h;let E=u,b=0;for(;E!==o;)b+=n[E++],E=E%e;if(o=(o+1)%e,o===u&&(u=(u+1)%e),h-a<t)return;const T=m&&h-m;return T?Math.round(b*1e3/T):void 0}}function Lw(e,t){let n=0,r=1e3/t,o,u;const a=(h,m=Date.now())=>{n=m,o=null,u&&(clearTimeout(u),u=null),e(...h)};return[(...h)=>{const m=Date.now(),E=m-n;E>=r?a(h,m):(o=h,u||(u=setTimeout(()=>{u=null,a(o)},r-E)))},()=>o&&a(o)]}const Sa=(e,t,n=3)=>{let r=0;const o=Rw(50,250);return Lw(u=>{const a=u.loaded,c=u.lengthComputable?u.total:void 0,f=a-r,h=o(f),m=a<=c;r=a;const E={loaded:a,total:c,progress:c?a/c:void 0,bytes:f,rate:h||void 0,estimated:h&&c&&m?(c-a)/h:void 0,event:u,lengthComputable:c!=null,[t?"download":"upload"]:!0};e(E)},n)},S0=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},w0=e=>(...t)=>K.asap(()=>e(...t)),Dw=tn.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,tn.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(tn.origin),tn.navigator&&/(msie|trident)/i.test(tn.navigator.userAgent)):()=>!0,Fw=tn.hasStandardBrowserEnv?{write(e,t,n,r,o,u){const a=[e+"="+encodeURIComponent(t)];K.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),K.isString(r)&&a.push("path="+r),K.isString(o)&&a.push("domain="+o),u===!0&&a.push("secure"),document.cookie=a.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Mw(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Bw(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function C0(e,t,n){let r=!Mw(t);return e&&(r||n==!1)?Bw(e,t):t}const A0=e=>e instanceof En?U({},e):e;function Hi(e,t){t=t||{};const n={};function r(h,m,E,b){return K.isPlainObject(h)&&K.isPlainObject(m)?K.merge.call({caseless:b},h,m):K.isPlainObject(m)?K.merge({},m):K.isArray(m)?m.slice():m}function o(h,m,E,b){if(K.isUndefined(m)){if(!K.isUndefined(h))return r(void 0,h,E,b)}else return r(h,m,E,b)}function u(h,m){if(!K.isUndefined(m))return r(void 0,m)}function a(h,m){if(K.isUndefined(m)){if(!K.isUndefined(h))return r(void 0,h)}else return r(void 0,m)}function c(h,m,E){if(E in t)return r(h,m);if(E in e)return r(void 0,h)}const f={url:u,method:u,data:u,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:c,headers:(h,m,E)=>o(A0(h),A0(m),E,!0)};return K.forEach(Object.keys(U(U({},e),t)),function(m){const E=f[m]||o,b=E(e[m],t[m],m);K.isUndefined(b)&&E!==c||(n[m]=b)}),n}const v0=e=>{const t=Hi({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:u,headers:a,auth:c}=t;if(t.headers=a=En.from(a),t.url=g0(C0(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),c&&a.set("Authorization","Basic "+btoa((c.username||"")+":"+(c.password?unescape(encodeURIComponent(c.password)):""))),K.isFormData(n)){if(tn.hasStandardBrowserEnv||tn.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(K.isFunction(n.getHeaders)){const f=n.getHeaders(),h=["content-type","content-length"];Object.entries(f).forEach(([m,E])=>{h.includes(m.toLowerCase())&&a.set(m,E)})}}if(tn.hasStandardBrowserEnv&&(r&&K.isFunction(r)&&(r=r(t)),r||r!==!1&&Dw(t.url))){const f=o&&u&&Fw.read(u);f&&a.set(o,f)}return t},Uw=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=v0(e);let u=o.data;const a=En.from(o.headers).normalize();let{responseType:c,onUploadProgress:f,onDownloadProgress:h}=o,m,E,b,T,_;function S(){T&&T(),_&&_(),o.cancelToken&&o.cancelToken.unsubscribe(m),o.signal&&o.signal.removeEventListener("abort",m)}let C=new XMLHttpRequest;C.open(o.method.toUpperCase(),o.url,!0),C.timeout=o.timeout;function k(){if(!C)return;const D=En.from("getAllResponseHeaders"in C&&C.getAllResponseHeaders()),q={data:!c||c==="text"||c==="json"?C.responseText:C.response,status:C.status,statusText:C.statusText,headers:D,config:e,request:C};x0(function(te){n(te),S()},function(te){r(te),S()},q),C=null}"onloadend"in C?C.onloadend=k:C.onreadystatechange=function(){!C||C.readyState!==4||C.status===0&&!(C.responseURL&&C.responseURL.indexOf("file:")===0)||setTimeout(k)},C.onabort=function(){C&&(r(new ze("Request aborted",ze.ECONNABORTED,e,C)),C=null)},C.onerror=function(G){const q=G&&G.message?G.message:"Network Error",B=new ze(q,ze.ERR_NETWORK,e,C);B.event=G||null,r(B),C=null},C.ontimeout=function(){let G=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const q=o.transitional||y0;o.timeoutErrorMessage&&(G=o.timeoutErrorMessage),r(new ze(G,q.clarifyTimeoutError?ze.ETIMEDOUT:ze.ECONNABORTED,e,C)),C=null},u===void 0&&a.setContentType(null),"setRequestHeader"in C&&K.forEach(a.toJSON(),function(G,q){C.setRequestHeader(q,G)}),K.isUndefined(o.withCredentials)||(C.withCredentials=!!o.withCredentials),c&&c!=="json"&&(C.responseType=o.responseType),h&&([b,_]=Sa(h,!0),C.addEventListener("progress",b)),f&&C.upload&&([E,T]=Sa(f),C.upload.addEventListener("progress",E),C.upload.addEventListener("loadend",T)),(o.cancelToken||o.signal)&&(m=D=>{C&&(r(!D||D.type?new bs(null,e,C):D),C.abort(),C=null)},o.cancelToken&&o.cancelToken.subscribe(m),o.signal&&(o.signal.aborted?m():o.signal.addEventListener("abort",m)));const M=Pw(o.url);if(M&&tn.protocols.indexOf(M)===-1){r(new ze("Unsupported protocol "+M+":",ze.ERR_BAD_REQUEST,e));return}C.send(u||null)})},Hw=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,o;const u=function(h){if(!o){o=!0,c();const m=h instanceof Error?h:this.reason;r.abort(m instanceof ze?m:new bs(m instanceof Error?m.message:m))}};let a=t&&setTimeout(()=>{a=null,u(new ze(`timeout ${t} of ms exceeded`,ze.ETIMEDOUT))},t);const c=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(h=>{h.unsubscribe?h.unsubscribe(u):h.removeEventListener("abort",u)}),e=null)};e.forEach(h=>h.addEventListener("abort",u));const{signal:f}=r;return f.unsubscribe=()=>K.asap(c),f}},zw=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,o;for(;r<n;)o=r+t,yield e.slice(r,o),r=o},jw=function(e,t){return Qc(this,null,function*(){try{for(var n=px($w(e)),r,o,u;r=!(o=yield new Hr(n.next())).done;r=!1){const a=o.value;yield*Nm(zw(a,t))}}catch(o){u=[o]}finally{try{r&&(o=n.return)&&(yield new Hr(o.call(n)))}finally{if(u)throw u[0]}}})},$w=function(e){return Qc(this,null,function*(){if(e[Symbol.asyncIterator]){yield*Nm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new Hr(t.read());if(n)break;yield r}}finally{yield new Hr(t.cancel())}})},k0=(e,t,n,r)=>{const o=jw(e,t);let u=0,a,c=h=>{a||(a=!0,r&&r(h))};return new ReadableStream({pull(h){return st(this,null,function*(){try{const{done:m,value:E}=yield o.next();if(m){c(),h.close();return}let b=E.byteLength;if(n){let T=u+=b;n(T)}h.enqueue(new Uint8Array(E))}catch(m){throw c(m),m}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})},N0=64*1024,{isFunction:wa}=K,Vw=(({Request:e,Response:t})=>({Request:e,Response:t}))(K.global),{ReadableStream:O0,TextEncoder:I0}=K.global,P0=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},qw=e=>{e=K.merge.call({skipUndefined:!0},Vw,e);const{fetch:t,Request:n,Response:r}=e,o=t?wa(t):typeof fetch=="function",u=wa(n),a=wa(r);if(!o)return!1;const c=o&&wa(O0),f=o&&(typeof I0=="function"?(_=>S=>_.encode(S))(new I0):_=>st(null,null,function*(){return new Uint8Array(yield new n(_).arrayBuffer())})),h=u&&c&&P0(()=>{let _=!1;const S=new n(tn.origin,{body:new O0,method:"POST",get duplex(){return _=!0,"half"}}).headers.has("Content-Type");return _&&!S}),m=a&&c&&P0(()=>K.isReadableStream(new r("").body)),E={stream:m&&(_=>_.body)};o&&["text","arrayBuffer","blob","formData","stream"].forEach(_=>{!E[_]&&(E[_]=(S,C)=>{let k=S&&S[_];if(k)return k.call(S);throw new ze(`Response type '${_}' is not supported`,ze.ERR_NOT_SUPPORT,C)})});const b=_=>st(null,null,function*(){if(_==null)return 0;if(K.isBlob(_))return _.size;if(K.isSpecCompliantForm(_))return(yield new n(tn.origin,{method:"POST",body:_}).arrayBuffer()).byteLength;if(K.isArrayBufferView(_)||K.isArrayBuffer(_))return _.byteLength;if(K.isURLSearchParams(_)&&(_=_+""),K.isString(_))return(yield f(_)).byteLength}),T=(_,S)=>st(null,null,function*(){const C=K.toFiniteNumber(_.getContentLength());return C==null?b(S):C});return _=>st(null,null,function*(){let{url:S,method:C,data:k,signal:M,cancelToken:D,timeout:G,onDownloadProgress:q,onUploadProgress:B,responseType:te,headers:Te,withCredentials:Se="same-origin",fetchOptions:H}=v0(_),fe=t||fetch;te=te?(te+"").toLowerCase():"text";let de=Hw([M,D&&D.toAbortSignal()],G),ue=null;const ie=de&&de.unsubscribe&&(()=>{de.unsubscribe()});let ge;try{if(B&&h&&C!=="get"&&C!=="head"&&(ge=yield T(Te,k))!==0){let R=new n(S,{method:"POST",body:k,duplex:"half"}),Q;if(K.isFormData(k)&&(Q=R.headers.get("content-type"))&&Te.setContentType(Q),R.body){const[N,_e]=S0(ge,Sa(w0(B)));k=k0(R.body,N0,N,_e)}}K.isString(Se)||(Se=Se?"include":"omit");const we=u&&"credentials"in n.prototype,ae=ye(U({},H),{signal:de,method:C.toUpperCase(),headers:Te.normalize().toJSON(),body:k,duplex:"half",credentials:we?Se:void 0});ue=u&&new n(S,ae);let V=yield u?fe(ue,H):fe(S,ae);const ee=m&&(te==="stream"||te==="response");if(m&&(q||ee&&ie)){const R={};["status","statusText","headers"].forEach(Me=>{R[Me]=V[Me]});const Q=K.toFiniteNumber(V.headers.get("content-length")),[N,_e]=q&&S0(Q,Sa(w0(q),!0))||[];V=new r(k0(V.body,N0,N,()=>{_e&&_e(),ie&&ie()}),R)}te=te||"text";let w=yield E[K.findKey(E,te)||"text"](V,_);return!ee&&ie&&ie(),yield new Promise((R,Q)=>{x0(R,Q,{data:w,headers:En.from(V.headers),status:V.status,statusText:V.statusText,config:_,request:ue})})}catch(we){throw ie&&ie(),we&&we.name==="TypeError"&&/Load failed|fetch/i.test(we.message)?Object.assign(new ze("Network Error",ze.ERR_NETWORK,_,ue),{cause:we.cause||we}):ze.from(we,we&&we.code,_,ue)}})},Yw=new Map,R0=e=>{let t=e?e.env:{};const{fetch:n,Request:r,Response:o}=t,u=[r,o,n];let a=u.length,c=a,f,h,m=Yw;for(;c--;)f=u[c],h=m.get(f),h===void 0&&m.set(f,h=c?new Map:qw(t)),m=h;return h};R0();const Cf={http:pw,xhr:Uw,fetch:{get:R0}};K.forEach(Cf,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(n){}Object.defineProperty(e,"adapterName",{value:t})}});const L0=e=>`- ${e}`,Ww=e=>K.isFunction(e)||e===null||e===!1,D0={getAdapter:(e,t)=>{e=K.isArray(e)?e:[e];const{length:n}=e;let r,o;const u={};for(let a=0;a<n;a++){r=e[a];let c;if(o=r,!Ww(r)&&(o=Cf[(c=String(r)).toLowerCase()],o===void 0))throw new ze(`Unknown adapter '${c}'`);if(o&&(K.isFunction(o)||(o=o.get(t))))break;u[c||"#"+a]=o}if(!o){const a=Object.entries(u).map(([f,h])=>`adapter ${f} `+(h===!1?"is not supported by the environment":"is not available in the build"));let c=n?a.length>1?`since :
5
+ `+a.map(L0).join(`
6
+ `):" "+L0(a[0]):"as no adapter specified";throw new ze("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return o},adapters:Cf};function Af(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new bs(null,e)}function F0(e){return Af(e),e.headers=En.from(e.headers),e.data=wf.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),D0.getAdapter(e.adapter||Do.adapter,e)(e).then(function(r){return Af(e),r.data=wf.call(e,e.transformResponse,r),r.headers=En.from(r.headers),r},function(r){return _0(r)||(Af(e),r&&r.response&&(r.response.data=wf.call(e,e.transformResponse,r.response),r.response.headers=En.from(r.response.headers))),Promise.reject(r)})}const M0="1.12.2",Ca={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Ca[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const B0={};Ca.transitional=function(t,n,r){function o(u,a){return"[Axios v"+M0+"] Transitional option '"+u+"'"+a+(r?". "+r:"")}return(u,a,c)=>{if(t===!1)throw new ze(o(a," has been removed"+(n?" in "+n:"")),ze.ERR_DEPRECATED);return n&&!B0[a]&&(B0[a]=!0,console.warn(o(a," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(u,a,c):!0}},Ca.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function Gw(e,t,n){if(typeof e!="object")throw new ze("options must be an object",ze.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const u=r[o],a=t[u];if(a){const c=e[u],f=c===void 0||a(c,u,e);if(f!==!0)throw new ze("option "+u+" must be "+f,ze.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ze("Unknown option "+u,ze.ERR_BAD_OPTION)}}const Aa={assertOptions:Gw,validators:Ca},xr=Aa.validators;let zi=class{constructor(t){this.defaults=t||{},this.interceptors={request:new E0,response:new E0}}request(t,n){return st(this,null,function*(){try{return yield this._request(t,n)}catch(r){if(r instanceof Error){let o={};Error.captureStackTrace?Error.captureStackTrace(o):o=new Error;const u=o.stack?o.stack.replace(/^.+\n/,""):"";try{r.stack?u&&!String(r.stack).endsWith(u.replace(/^.+\n.+\n/,""))&&(r.stack+=`
7
+ `+u):r.stack=u}catch(a){}}throw r}})}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Hi(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:u}=n;r!==void 0&&Aa.assertOptions(r,{silentJSONParsing:xr.transitional(xr.boolean),forcedJSONParsing:xr.transitional(xr.boolean),clarifyTimeoutError:xr.transitional(xr.boolean)},!1),o!=null&&(K.isFunction(o)?n.paramsSerializer={serialize:o}:Aa.assertOptions(o,{encode:xr.function,serialize:xr.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),Aa.assertOptions(n,{baseUrl:xr.spelling("baseURL"),withXsrfToken:xr.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=u&&K.merge(u.common,u[n.method]);u&&K.forEach(["delete","get","head","post","put","patch","common"],_=>{delete u[_]}),n.headers=En.concat(a,u);const c=[];let f=!0;this.interceptors.request.forEach(function(S){typeof S.runWhen=="function"&&S.runWhen(n)===!1||(f=f&&S.synchronous,c.unshift(S.fulfilled,S.rejected))});const h=[];this.interceptors.response.forEach(function(S){h.push(S.fulfilled,S.rejected)});let m,E=0,b;if(!f){const _=[F0.bind(this),void 0];for(_.unshift(...c),_.push(...h),b=_.length,m=Promise.resolve(n);E<b;)m=m.then(_[E++],_[E++]);return m}b=c.length;let T=n;for(;E<b;){const _=c[E++],S=c[E++];try{T=_(T)}catch(C){S.call(this,C);break}}try{m=F0.call(this,T)}catch(_){return Promise.reject(_)}for(E=0,b=h.length;E<b;)m=m.then(h[E++],h[E++]);return m}getUri(t){t=Hi(this.defaults,t);const n=C0(t.baseURL,t.url,t.allowAbsoluteUrls);return g0(n,t.params,t.paramsSerializer)}};K.forEach(["delete","get","head","options"],function(t){zi.prototype[t]=function(n,r){return this.request(Hi(r||{},{method:t,url:n,data:(r||{}).data}))}}),K.forEach(["post","put","patch"],function(t){function n(r){return function(u,a,c){return this.request(Hi(c||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:u,data:a}))}}zi.prototype[t]=n(),zi.prototype[t+"Form"]=n(!0)});let Kw=class mx{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(u){n=u});const r=this;this.promise.then(o=>{if(!r._listeners)return;let u=r._listeners.length;for(;u-- >0;)r._listeners[u](o);r._listeners=null}),this.promise.then=o=>{let u;const a=new Promise(c=>{r.subscribe(c),u=c}).then(o);return a.cancel=function(){r.unsubscribe(u)},a},t(function(u,a,c){r.reason||(r.reason=new bs(u,a,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new mx(function(o){t=o}),cancel:t}}};function Qw(e){return function(n){return e.apply(null,n)}}function Xw(e){return K.isObject(e)&&e.isAxiosError===!0}const vf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(vf).forEach(([e,t])=>{vf[t]=e});function U0(e){const t=new zi(e),n=t0(zi.prototype.request,t);return K.extend(n,zi.prototype,t,{allOwnKeys:!0}),K.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return U0(Hi(e,o))},n}const Nt=U0(Do);Nt.Axios=zi,Nt.CanceledError=bs,Nt.CancelToken=Kw,Nt.isCancel=_0,Nt.VERSION=M0,Nt.toFormData=_a,Nt.AxiosError=ze,Nt.Cancel=Nt.CanceledError,Nt.all=function(t){return Promise.all(t)},Nt.spread=Qw,Nt.isAxiosError=Xw,Nt.mergeConfig=Hi,Nt.AxiosHeaders=En,Nt.formToJSON=e=>T0(K.isHTMLForm(e)?new FormData(e):e),Nt.getAdapter=D0.getAdapter,Nt.HttpStatusCode=vf,Nt.default=Nt;const{Axios:TM,AxiosError:bM,CanceledError:_M,isCancel:xM,CancelToken:SM,VERSION:wM,all:CM,Cancel:AM,isAxiosError:vM,spread:kM,toFormData:NM,AxiosHeaders:OM,HttpStatusCode:IM,formToJSON:PM,getAdapter:RM,mergeConfig:LM}=Nt;class H0{constructor(t,n,r=!1){ke(this,"CIMULATE_API_HEADER","x-cimulate-api-key");ke(this,"CIMULATE_SEARCH_API_PATH","api/v1");ke(this,"baseApiUrl");ke(this,"headers",{});ke(this,"fetchConfig",()=>st(this,null,function*(){try{const t=yield Nt.get(`${this.apiUrl}/configs/copilot`,{headers:this.headers}),{customer_config:n}=t.data,r=atob(n);return JSON.parse(r)}catch(t){throw console.error("Error fetching customer config:",t),t}}));if(t&&n||!t&&!n)throw new Error("Provide exactly one authentication method: either 'apiKey' or 'apiToken', but not both.");t?this.headers[this.CIMULATE_API_HEADER]=t:n&&(this.headers.Authorization=`Bearer ${n}`),this.baseApiUrl=r?"https://staging.search.cimulate.ai":"https://prod.search.cimulate.ai"}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}const Jw=W.createContext(void 0),Zw=({apiKey:e,apiToken:t,isDevelopment:n=!1,children:r})=>{const o=W.useMemo(()=>new H0(e,t,n),[e,t,n]);return I.jsx(Jw.Provider,{value:o,children:r})};var z0=Symbol.for("immer-nothing"),j0=Symbol.for("immer-draftable"),it=Symbol.for("immer-state");function jn(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var _s=Object.getPrototypeOf;function xs(e){return!!e&&!!e[it]}function zr(e){var t;return e?$0(e)||Array.isArray(e)||!!e[j0]||!!((t=e.constructor)!=null&&t[j0])||ka(e)||Na(e):!1}var eC=Object.prototype.constructor.toString();function $0(e){if(!e||typeof e!="object")return!1;const t=_s(e);if(t===null)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object?!0:typeof n=="function"&&Function.toString.call(n)===eC}function Mo(e,t){va(e)===0?Reflect.ownKeys(e).forEach(n=>{t(n,e[n],e)}):e.forEach((n,r)=>t(r,n,e))}function va(e){const t=e[it];return t?t.type_:Array.isArray(e)?1:ka(e)?2:Na(e)?3:0}function kf(e,t){return va(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function V0(e,t,n){const r=va(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function tC(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function ka(e){return e instanceof Map}function Na(e){return e instanceof Set}function zt(e){return e.copy_||e.base_}function Nf(e,t){if(ka(e))return new Map(e);if(Na(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=$0(e);if(t===!0||t==="class_only"&&!n){const r=Object.getOwnPropertyDescriptors(e);delete r[it];let o=Reflect.ownKeys(r);for(let u=0;u<o.length;u++){const a=o[u],c=r[a];c.writable===!1&&(c.writable=!0,c.configurable=!0),(c.get||c.set)&&(r[a]={configurable:!0,writable:!0,enumerable:c.enumerable,value:e[a]})}return Object.create(_s(e),r)}else{const r=_s(e);if(r!==null&&n)return U({},e);const o=Object.create(r);return Object.assign(o,e)}}function Of(e,t=!1){return Oa(e)||xs(e)||!zr(e)||(va(e)>1&&(e.set=e.add=e.clear=e.delete=nC),Object.freeze(e),t&&Object.entries(e).forEach(([n,r])=>Of(r,!0))),e}function nC(){jn(2)}function Oa(e){return Object.isFrozen(e)}var If={};function ji(e){const t=If[e];return t||jn(0,e),t}function rC(e,t){If[e]||(If[e]=t)}var Bo;function Ia(){return Bo}function iC(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function q0(e,t){t&&(ji("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Pf(e){Rf(e),e.drafts_.forEach(sC),e.drafts_=null}function Rf(e){e===Bo&&(Bo=e.parent_)}function Y0(e){return Bo=iC(Bo,e)}function sC(e){const t=e[it];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function W0(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[it].modified_&&(Pf(t),jn(4)),zr(e)&&(e=Pa(t,e),t.parent_||Ra(t,e)),t.patches_&&ji("Patches").generateReplacementPatches_(n[it].base_,e,t.patches_,t.inversePatches_)):e=Pa(t,n,[]),Pf(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==z0?e:void 0}function Pa(e,t,n){if(Oa(t))return t;const r=t[it];if(!r)return Mo(t,(o,u)=>G0(e,r,t,o,u,n)),t;if(r.scope_!==e)return t;if(!r.modified_)return Ra(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const o=r.copy_;let u=o,a=!1;r.type_===3&&(u=new Set(o),o.clear(),a=!0),Mo(u,(c,f)=>G0(e,r,o,c,f,n,a)),Ra(e,o,!1),n&&e.patches_&&ji("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function G0(e,t,n,r,o,u,a){if(xs(o)){const c=u&&t&&t.type_!==3&&!kf(t.assigned_,r)?u.concat(r):void 0,f=Pa(e,o,c);if(V0(n,r,f),xs(f))e.canAutoFreeze_=!1;else return}else a&&n.add(o);if(zr(o)&&!Oa(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Pa(e,o),(!t||!t.scope_.parent_)&&typeof r!="symbol"&&Object.prototype.propertyIsEnumerable.call(n,r)&&Ra(e,o)}}function Ra(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Of(t,n)}function oC(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:Ia(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=r,u=Lf;n&&(o=[r],u=Uo);const{revoke:a,proxy:c}=Proxy.revocable(o,u);return r.draft_=c,r.revoke_=a,c}var Lf={get(e,t){if(t===it)return e;const n=zt(e);if(!kf(n,t))return uC(e,n,t);const r=n[t];return e.finalized_||!zr(r)?r:r===Df(e.base_,t)?(Ff(e),e.copy_[t]=Ho(r,e)):r},has(e,t){return t in zt(e)},ownKeys(e){return Reflect.ownKeys(zt(e))},set(e,t,n){const r=K0(zt(e),t);if(r!=null&&r.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const o=Df(zt(e),t),u=o==null?void 0:o[it];if(u&&u.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(tC(n,o)&&(n!==void 0||kf(e.base_,t)))return!0;Ff(e),jr(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return Df(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Ff(e),jr(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=zt(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){jn(11)},getPrototypeOf(e){return _s(e.base_)},setPrototypeOf(){jn(12)}},Uo={};Mo(Lf,(e,t)=>{Uo[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),Uo.deleteProperty=function(e,t){return Uo.set.call(this,e,t,void 0)},Uo.set=function(e,t,n){return Lf.set.call(this,e[0],t,n,e[0])};function Df(e,t){const n=e[it];return(n?zt(n):e)[t]}function uC(e,t,n){var o;const r=K0(t,n);return r?"value"in r?r.value:(o=r.get)==null?void 0:o.call(e.draft_):void 0}function K0(e,t){if(!(t in e))return;let n=_s(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=_s(n)}}function jr(e){e.modified_||(e.modified_=!0,e.parent_&&jr(e.parent_))}function Ff(e){e.copy_||(e.copy_=Nf(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var aC=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const u=n;n=t;const a=this;return function(f=u,...h){return a.produce(f,m=>n.call(this,m,...h))}}typeof n!="function"&&jn(6),r!==void 0&&typeof r!="function"&&jn(7);let o;if(zr(t)){const u=Y0(this),a=Ho(t,void 0);let c=!0;try{o=n(a),c=!1}finally{c?Pf(u):Rf(u)}return q0(u,r),W0(o,u)}else if(!t||typeof t!="object"){if(o=n(t),o===void 0&&(o=t),o===z0&&(o=void 0),this.autoFreeze_&&Of(o,!0),r){const u=[],a=[];ji("Patches").generateReplacementPatches_(t,o,u,a),r(u,a)}return o}else jn(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(a,...c)=>this.produceWithPatches(a,f=>t(f,...c));let r,o;return[this.produce(t,n,(a,c)=>{r=a,o=c}),r,o]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){zr(e)||jn(8),xs(e)&&(e=lC(e));const t=Y0(this),n=Ho(e,void 0);return n[it].isManual_=!0,Rf(t),n}finishDraft(e,t){const n=e&&e[it];(!n||!n.isManual_)&&jn(9);const{scope_:r}=n;return q0(r,t),W0(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const o=t[n];if(o.path.length===0&&o.op==="replace"){e=o.value;break}}n>-1&&(t=t.slice(n+1));const r=ji("Patches").applyPatches_;return xs(e)?r(e,t):this.produce(e,o=>r(o,t))}};function Ho(e,t){const n=ka(e)?ji("MapSet").proxyMap_(e,t):Na(e)?ji("MapSet").proxySet_(e,t):oC(e,t);return(t?t.scope_:Ia()).drafts_.push(n),n}function lC(e){return xs(e)||jn(10,e),Q0(e)}function Q0(e){if(!zr(e)||Oa(e))return e;const t=e[it];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Nf(e,t.scope_.immer_.useStrictShallowCopy_)}else n=Nf(e,!0);return Mo(n,(r,o)=>{V0(n,r,Q0(o))}),t&&(t.finalized_=!1),n}function cC(){class e extends Map{constructor(f,h){super(),this[it]={type_:2,parent_:h,scope_:h?h.scope_:Ia(),modified_:!1,finalized_:!1,copy_:void 0,assigned_:void 0,base_:f,draft_:this,isManual_:!1,revoked_:!1}}get size(){return zt(this[it]).size}has(f){return zt(this[it]).has(f)}set(f,h){const m=this[it];return a(m),(!zt(m).has(f)||zt(m).get(f)!==h)&&(n(m),jr(m),m.assigned_.set(f,!0),m.copy_.set(f,h),m.assigned_.set(f,!0)),this}delete(f){if(!this.has(f))return!1;const h=this[it];return a(h),n(h),jr(h),h.base_.has(f)?h.assigned_.set(f,!1):h.assigned_.delete(f),h.copy_.delete(f),!0}clear(){const f=this[it];a(f),zt(f).size&&(n(f),jr(f),f.assigned_=new Map,Mo(f.base_,h=>{f.assigned_.set(h,!1)}),f.copy_.clear())}forEach(f,h){const m=this[it];zt(m).forEach((E,b,T)=>{f.call(h,this.get(b),b,this)})}get(f){const h=this[it];a(h);const m=zt(h).get(f);if(h.finalized_||!zr(m)||m!==h.base_.get(f))return m;const E=Ho(m,h);return n(h),h.copy_.set(f,E),E}keys(){return zt(this[it]).keys()}values(){const f=this.keys();return{[Symbol.iterator]:()=>this.values(),next:()=>{const h=f.next();return h.done?h:{done:!1,value:this.get(h.value)}}}}entries(){const f=this.keys();return{[Symbol.iterator]:()=>this.entries(),next:()=>{const h=f.next();if(h.done)return h;const m=this.get(h.value);return{done:!1,value:[h.value,m]}}}}[Symbol.iterator](){return this.entries()}}function t(c,f){return new e(c,f)}function n(c){c.copy_||(c.assigned_=new Map,c.copy_=new Map(c.base_))}class r extends Set{constructor(f,h){super(),this[it]={type_:3,parent_:h,scope_:h?h.scope_:Ia(),modified_:!1,finalized_:!1,copy_:void 0,base_:f,draft_:this,drafts_:new Map,revoked_:!1,isManual_:!1}}get size(){return zt(this[it]).size}has(f){const h=this[it];return a(h),h.copy_?!!(h.copy_.has(f)||h.drafts_.has(f)&&h.copy_.has(h.drafts_.get(f))):h.base_.has(f)}add(f){const h=this[it];return a(h),this.has(f)||(u(h),jr(h),h.copy_.add(f)),this}delete(f){if(!this.has(f))return!1;const h=this[it];return a(h),u(h),jr(h),h.copy_.delete(f)||(h.drafts_.has(f)?h.copy_.delete(h.drafts_.get(f)):!1)}clear(){const f=this[it];a(f),zt(f).size&&(u(f),jr(f),f.copy_.clear())}values(){const f=this[it];return a(f),u(f),f.copy_.values()}entries(){const f=this[it];return a(f),u(f),f.copy_.entries()}keys(){return this.values()}[Symbol.iterator](){return this.values()}forEach(f,h){const m=this.values();let E=m.next();for(;!E.done;)f.call(h,E.value,E.value,this),E=m.next()}}function o(c,f){return new r(c,f)}function u(c){c.copy_||(c.copy_=new Set,c.base_.forEach(f=>{if(zr(f)){const h=Ho(f,c);c.drafts_.set(f,h),c.copy_.add(h)}else c.copy_.add(f)}))}function a(c){c.revoked_&&jn(3,JSON.stringify(zt(c)))}rC("MapSet",{proxyMap_:t,proxySet_:o})}var Nn=new aC,fC=Nn.produce;Nn.produceWithPatches.bind(Nn),Nn.setAutoFreeze.bind(Nn),Nn.setUseStrictShallowCopy.bind(Nn),Nn.applyPatches.bind(Nn),Nn.createDraft.bind(Nn),Nn.finishDraft.bind(Nn);function dC(e,t,n){var r=W.useMemo(function(){return fC(e)},[e]);return W.useReducer(r,t,n)}const X0={PAGE_CHANGED:"page-changed",PAGE_SIZE_CHANGED:"page-size-changed",FACET_FILTERS_CHANGED:"facet-filters-changed",RANGE_FILTERS_CHANGED:"range-filters-changed",CATALOG_SEGMENT_CHANGED:"catalog-segment-changed",PRICEBOOKS_CHANGED:"pricebooks-changed"},yn={RESET_STATE:"RESET_STATE",RESET_COPILOT:"RESET_COPILOT",ADD_MESSAGE:"ADD_MESSAGE",SET_COPILOT:"SET_COPILOT",SET_CONNECTED:"SET_CONNECTED",ADD_LOADING_MESSAGE:"ADD_LOADING_MESSAGE",REMOVE_LOADING_MESSAGE:"REMOVE_LOADING_MESSAGE"},La={copilot:null,connected:!1,messages:[],groupedMessages:[],loadingMessages:new Set},zo="cimulate",Mf=`${zo}:pdp-update`,Bf=`${zo}:browse-update`,Uf=`${zo}:search-update`,Hf=`${zo}:ui-state-update`,zf=`${zo}:session-state`,$r=U({CONTEXT_UPDATED:"browse-context-updated",CATEGORY_ID_CHANGED:"category-id-changed"},X0),hC={"browse-context":$r.CONTEXT_UPDATED,categoryId:$r.CATEGORY_ID_CHANGED,page:$r.PAGE_CHANGED,pageSize:$r.PAGE_SIZE_CHANGED,includeFacets:$r.FACET_FILTERS_CHANGED,facetFilters:$r.FACET_FILTERS_CHANGED,rangeFilters:$r.RANGE_FILTERS_CHANGED,catalogSegment:$r.CATALOG_SEGMENT_CHANGED,pricebooks:$r.PRICEBOOKS_CHANGED},Vr=U({SEARCH_CONTEXT_UPDATED:"search-context-updated",QUERY_CHANGED:"query-changed"},X0),pC={"search-context":Vr.SEARCH_CONTEXT_UPDATED,query:Vr.QUERY_CHANGED,page:Vr.PAGE_CHANGED,pageSize:Vr.PAGE_SIZE_CHANGED,includeFacets:Vr.FACET_FILTERS_CHANGED,facetFilters:Vr.FACET_FILTERS_CHANGED,rangeFilters:Vr.RANGE_FILTERS_CHANGED,catalogSegment:Vr.CATALOG_SEGMENT_CHANGED,pricebooks:Vr.PRICEBOOKS_CHANGED},Z="cim-widget",Ss=`--${Z}`,$i={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd"},mC=(e=$i)=>({[`${Ss}-primary-color`]:e.primaryColor||$i.primaryColor,[`${Ss}-secondary-color`]:e.secondaryColor||$i.secondaryColor,[`${Ss}-font-color`]:e.fontColor||$i.fontColor,[`${Ss}-font-family`]:e.fontFamily||$i.fontFamily,[`${Ss}-background-color`]:e.backgroundColor||$i.backgroundColor,[`${Ss}-border-color`]:e.borderColor||$i.borderColor}),li={RESET_CONVERSATION:"reset-conversation",GET_SESSION_INFORMATION:"get-session-information",GET_CONVERSATION_MESSAGES:"get-conversation-messages",LOAD_CONVERSATION:"load-conversation"},J0=W.createContext(null),Z0=W.createContext(null);class gC{constructor(t,n,r=!1){ke(this,"apiService");ke(this,"config",null);ke(this,"getConfig",()=>st(this,null,function*(){if(this.config)return this.config;try{const t=yield this.apiService.fetchConfig();return this.config=t,this.config}catch(t){throw console.error("Failed to fetch customer config:",t),t}}));ke(this,"getPid",t=>this.getProductFieldValue(t,"pidCol"));ke(this,"getName",t=>this.getProductFieldValue(t,"nameCol"));ke(this,"getDescription",t=>this.getProductFieldValue(t,"description"));ke(this,"getBrand",t=>this.getProductFieldValue(t,"productBrandCol"));ke(this,"getPrice",t=>this.getProductFieldValue(t,"priceCol"));ke(this,"getRelativePdp",t=>this.getProductFieldValue(t,"relativePdpCol"));ke(this,"getPdp",t=>this.getProductFieldValue(t,"pdpCol"));ke(this,"getImage",t=>this.getProductFieldValue(t,"imageCol"));ke(this,"getProductHiddenFields",()=>{const t=this.getProductField("productHiddenFields");return Array.isArray(t)?t:[]});ke(this,"getProductField",t=>this.config?this.config[t]:"");ke(this,"getProductFieldValue",(t,n)=>{const r=this.getProductField(n);return r&&t[r]||""});this.apiService=new H0(t,n,r)}getPriceDisplay(t){const n=this.getPrice(t);return n?typeof n=="string"?n.includes("$")?n:`$${n}`:typeof n=="number"?new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}).format(n):n:""}}const ws=(e,t,n,...r)=>{if(!e)return;const o=["background: linear-gradient(90deg,rgba(253, 99, 99, 1) 0%, rgba(245, 139, 35, 1) 65%)","font-weight: bold","color: transparent","background-clip: text","text-fill-color: transparent"].join(";");console[t]("%c[cimulate-widget]",o,n,...r)};class EC{constructor(t=!1){ke(this,"isDevelopment");ke(this,"_log",(t,n,...r)=>{ws(this.isDevelopment,t,n,...r)});this.isDevelopment=t}log(t,...n){this._log("log",t,...n)}warn(t,...n){this._log("warn",t,...n)}error(t,...n){this._log("error",t,...n)}info(t,...n){this._log("info",t,...n)}debug(t,...n){this._log("debug",t,...n)}}const eg=W.createContext(null),yC=({logoUrl:e,headerText:t="Your Search Assistant",globalClassName:n="",searchPlaceholder:r,searchButtonLabel:o,resetConversationMessage:u="What products would you like to explore today?",apiKey:a,apiToken:c,theme:f,isDevelopment:h,children:m})=>{const E=W.useMemo(()=>new gC(a,c,h),[a,c,h]),b=W.useMemo(()=>new EC(h),[h]);W.useEffect(()=>{E.config||E.getConfig()},[E]);const T=W.useMemo(()=>mC(f),[f]),_=W.useMemo(()=>({configModule:E,logoUrl:e,headerText:t,globalClassName:n,themeVariables:T,logger:b,searchPlaceholder:r,searchButtonLabel:o,resetConversationMessage:u}),[E,e,t,n,r,o,u,b,T]);return I.jsx(eg.Provider,{value:_,children:m})},ir=()=>{const e=W.useContext(eg);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e};class TC{constructor(){ke(this,"initialState",{connected:!1,mode:"embedded",status:{type:"dialog",isOpen:!1},dialog:{position:"bottom-left"},modal:{isFullscreen:!1}});ke(this,"connectedProxy");ke(this,"modeProxy");ke(this,"statusProxy");ke(this,"dialogProxy");ke(this,"modalProxy",{isFullscreen:!1});ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>{if(!(n in t))throw new Error(`Property ${n} does not exist on UIState`);return xC(n,r),Reflect.set(t,n,r)});this.connectedProxy=new Proxy({connected:this.initialState.connected},{get:this._fullGet,set:this._fullSet}),this.modeProxy=new Proxy({mode:this.initialState.mode},{get:this._fullGet,set:this._fullSet}),this.statusProxy=new Proxy({type:this.initialState.status.type,isOpen:this.initialState.status.isOpen},{get:this._fullGet,set:this._fullSet}),this.dialogProxy=new Proxy({position:this.initialState.dialog.position},{get:this._fullGet,set:this._fullSet}),this.modalProxy=new Proxy({isFullscreen:this.initialState.modal.isFullscreen},{get:this._fullGet,set:this._fullSet})}get connected(){return this.connectedProxy.connected}get mode(){return this.modeProxy.mode}get isOpen(){return!!this.statusProxy.isOpen}get type(){return this.statusProxy.type}get position(){return this.dialogProxy.position}get state(){return{connected:this.connected,mode:this.mode,status:{type:this.type,isOpen:this.isOpen},dialog:{position:this.position},modal:{isFullscreen:this.modalProxy.isFullscreen}}}}const Ot=new TC,Cs=()=>Ot.connected,bC=e=>{window.addEventListener(Hf,e)},_C=e=>{window.removeEventListener(Hf,e)},xC=(e,t)=>{const n=new CustomEvent(Hf,{detail:{property:e,value:t}});window.dispatchEvent(n)},SC=e=>{Ot.connectedProxy.connected=e},Da=e=>{if(typeof e!="boolean"){Ot.statusProxy.isOpen=!Ot.statusProxy.isOpen;return}Ot.statusProxy.isOpen=e},tg=e=>{Ot.modalProxy.isFullscreen=e},jf=e=>{if(!["chat","dialog","modal"].includes(e))throw new Error(`Invalid type: ${e}. Must be 'chat', 'dialog', or 'modal'.`);Ot.statusProxy.type=e,e==="dialog"||e==="chat"?Ot.modeProxy.mode="embedded":Ot.modeProxy.mode="standalone"},wC=e=>{const t=["top","top-left","top-right","bottom","bottom-left","bottom-right","left","right","center"];if(!t.includes(e))throw new Error(`Invalid position: ${e}. Must be one of ${t.join(", ")}.`);Ot.dialogProxy.position=e},CC=({onCopilotEvent:e,children:t,dispatch:n})=>{const{logger:r}=ir(),o=W.useCallback(b=>{n({type:yn.SET_COPILOT,payload:b})},[n]),u=W.useCallback(b=>{SC(b),n({type:yn.SET_CONNECTED,payload:b})},[n]),a=W.useCallback(()=>{n({type:yn.RESET_COPILOT,payload:{}})},[n]),c=W.useCallback(()=>{n({type:yn.RESET_STATE,payload:{}})},[n]),f=W.useCallback(b=>{r==null||r.log(`${b.name} event received`,b),n({type:yn.ADD_MESSAGE,payload:b}),e==null||e(b)},[e,r,n]),h=W.useCallback(b=>{n({type:yn.ADD_LOADING_MESSAGE,payload:b})},[n]),m=W.useCallback(b=>{n({type:yn.REMOVE_LOADING_MESSAGE,payload:b})},[n]),E=W.useMemo(()=>({setCopilot:o,setConnected:u,resetCopilot:a,resetCopilotState:c,addCopilotEvent:f,addLoadingMessage:h,removeLoadingMessage:m}),[o,u,a,c,f,h,m]);return I.jsx(Z0.Provider,{value:E,children:t})};cC();const AC=(e,t)=>{const{type:n,payload:r}=t;if(n===yn.ADD_MESSAGE){const o=r;if(e.messages.push(o),o.eventSourceId){const u=e.groupedMessages.findIndex(a=>a.eventSourceId===o.eventSourceId);if(u!==-1){let a=e.groupedMessages[u].messages;a||(a=[]);const c=a.findIndex(f=>f.id===o.id);if(c!==-1){a[c]=o;return}a.push(o);return}else{e.groupedMessages.push({type:"group",eventSourceId:o.eventSourceId,messages:[o],createdAt:new Date(o.createdAt)});return}}e.groupedMessages.push({type:"individual",message:o,createdAt:new Date(o.createdAt)});return}switch(n){case yn.RESET_STATE:e.messages=La.messages,e.groupedMessages=La.groupedMessages,e.loadingMessages=La.loadingMessages;break;case yn.RESET_COPILOT:e.copilot=null;break;case yn.SET_COPILOT:e.copilot=r;break;case yn.SET_CONNECTED:e.connected=r;break;case yn.ADD_LOADING_MESSAGE:e.loadingMessages.add(r);break;case yn.REMOVE_LOADING_MESSAGE:e.loadingMessages.delete(r);break}},vC=({onCopilotEvent:e,children:t})=>{const[n,r]=dC(AC,La);return I.jsx(J0.Provider,{value:n,children:I.jsx(CC,{onCopilotEvent:e,dispatch:r,children:t})})};function kC(){var e=W.useRef(!0);return e.current?(e.current=!1,!0):e.current}var NC=function(e){W.useEffect(e,[])},OC=function(e,t){return e===t};function IC(e,t){t===void 0&&(t=OC);var n=W.useRef(),r=W.useRef(e),o=kC();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}class PC{constructor(){ke(this,"items",[]);ke(this,"add",t=>{this.items.push(t)});ke(this,"remove",()=>this.items.shift());ke(this,"first",()=>this.items.length>0?this.items[0]:null);ke(this,"processQueue",t=>{new Array(sr.size).fill(1).forEach(()=>{const r=sr.first();r&&(t(r),sr.remove())})})}get size(){return this.items.length}}const sr=new PC,ng=e=>{window.addEventListener(Uf,e)},rg=e=>{window.removeEventListener(Uf,e)},RC=(e,t,n)=>{const r=new CustomEvent(Uf,{detail:{event:e,property:t,value:n}});window.dispatchEvent(r)},ig=e=>{window.addEventListener(Bf,e)},sg=e=>{window.removeEventListener(Bf,e)},LC=(e,t,n)=>{const r=new CustomEvent(Bf,{detail:{event:e,property:t,value:n}});window.dispatchEvent(r)},og=e=>{window.addEventListener(Mf,e)},ug=e=>{window.removeEventListener(Mf,e)},ag=(e,t,n)=>{const r=new CustomEvent(Mf,{detail:{property:e,value:t,event:n}});window.dispatchEvent(r)},DC=e=>{window.addEventListener(zf,e)},FC=e=>{window.removeEventListener(zf,e)},Fa=(e,t,n)=>{const r=new CustomEvent(zf,{detail:{property:e,value:t,event:n}});window.dispatchEvent(r)};class MC{constructor(){ke(this,"initialParams",{categoryId:"",page:null,pageSize:null,includeFacets:!0,facetFilters:{},rangeFilters:[],catalogSegment:null,pricebooks:null});ke(this,"categoryIdProxy");ke(this,"facetFiltersProxy");ke(this,"rangeFiltersProxy");ke(this,"catalogSegmentProxy");ke(this,"pricebooksProxy");ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>{const o=hC[n];return LC(o,n,r),Reflect.set(t,n,r)});ke(this,"updateFacetFiltersProxy",t=>new Proxy({facetFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updateRangeFiltersProxy",t=>new Proxy({rangeFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updatePricebooksProxy",t=>new Proxy({pricebooks:t},{get:this._fullGet,set:this._fullSet}));this.categoryIdProxy=new Proxy({categoryId:this.initialParams.categoryId},{get:this._fullGet,set:this._fullSet}),this.facetFiltersProxy=this.updateFacetFiltersProxy(this.initialParams.facetFilters||{}),this.rangeFiltersProxy=this.updateRangeFiltersProxy(this.initialParams.rangeFilters||[]),this.catalogSegmentProxy=new Proxy({catalogSegment:this.initialParams.catalogSegment},{get:this._fullGet,set:this._fullSet}),this.pricebooksProxy=this.updatePricebooksProxy(this.initialParams.pricebooks||null)}get categoryId(){return this.categoryIdProxy.categoryId||""}get facetFilters(){return this.facetFiltersProxy.facetFilters||{}}get rangeFilters(){return this.rangeFiltersProxy.rangeFilters||[]}get catalogSegment(){return this.catalogSegmentProxy.catalogSegment||null}get pricebooks(){return this.pricebooksProxy.pricebooks||null}get state(){return{categoryId:this.categoryId,facetFilters:this.facetFilters,rangeFilters:this.rangeFilters,catalogSegment:this.catalogSegment,pricebooks:this.pricebooks,page:this.initialParams.page,pageSize:this.initialParams.pageSize,includeFacets:this.initialParams.includeFacets}}}const lt=new MC,BC={categoryId:lt.categoryId,facetFilters:lt.facetFilters,rangeFilters:lt.rangeFilters,catalogSegment:lt.catalogSegment,pricebooks:lt.pricebooks},lg=W.createContext(BC),UC=({children:e})=>{const[t,n]=W.useState(lt.categoryId),[r,o]=W.useState(lt.facetFilters||{}),[u,a]=W.useState(lt.rangeFilters||[]),[c,f]=W.useState(lt.catalogSegment||null),[h,m]=W.useState(lt.pricebooks||null);W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="categoryId"&&n(T.value),(T==null?void 0:T.property)==="facetFilters"&&o(T.value),(T==null?void 0:T.property)==="rangeFilters"&&a(T.value),(T==null?void 0:T.property)==="catalogSegment"&&f(T.value),(T==null?void 0:T.property)==="pricebooks"&&m(T.value)};return ig(b),()=>{sg(b)}},[]);const E=W.useMemo(()=>({categoryId:t,facetFilters:r,rangeFilters:u,catalogSegment:c,pricebooks:h}),[t,r,u,c,h]);return I.jsx(lg.Provider,{value:E,children:e})},HC=()=>{const e=W.useContext(lg);if(!e)throw new Error("useBrowse must be used within a BrowseProvider");return e},cg=(e,t)=>{const n=t.updateFacetFiltersProxy(e);t.facetFiltersProxy.facetFilters=n.facetFilters},fg=(e,t,n)=>{var a,c;const r=U({},((a=n.facetFiltersProxy)==null?void 0:a.facetFilters)||{});if(!!((c=r[e])!=null&&c.includes(t))){const f=r[e].filter(h=>h!==t);f.length>0?r[e]=f:delete r[e]}else r[e]=r[e]?[...r[e],t]:[t];const u=n.updateFacetFiltersProxy(r);n.facetFiltersProxy.facetFilters=u.facetFilters},dg=(e,t)=>{const n=t.updateRangeFiltersProxy(e);t.rangeFiltersProxy.rangeFilters=n.rangeFilters},hg=({field:e,value:t},n)=>{const[r,o]=Array.isArray(t)?t:[];if(typeof r=="undefined"||typeof o=="undefined")throw new Error("Range values must be an array with two numbers for min and max");const u=[...n.rangeFiltersProxy.rangeFilters||[]],a=u.findIndex(f=>f.field===e);if(a!==-1){u[a]={field:e,min:r,max:o},n.rangeFiltersProxy.rangeFilters=u;return}u.push({field:e,min:r,max:o});const c=n.updateRangeFiltersProxy(u);n.rangeFiltersProxy.rangeFilters=c.rangeFilters},pg=(e,t)=>{t.catalogSegmentProxy.catalogSegment=e},mg=(e,t)=>{const n=t.updatePricebooksProxy(e);t.pricebooksProxy.pricebooks=n.pricebooks},zC=e=>{ct.queryProxy.query=e,Cs()||sr.add({context:"search",payload:U({},ct.state)})},gg=e=>{cg(e,ct)},jC=(e,t)=>{fg(e,t,ct)},Eg=e=>{dg(e,ct)},$C=({field:e,value:t})=>{hg({field:e,value:t},ct)},VC=e=>{pg(e,ct)},yg=e=>{mg(e,ct)},qC=Object.freeze(Object.defineProperty({__proto__:null,setSearchContext:e=>{if(!e||!e.query)throw new Error("Search context must include a query");"facetFilters"in e&&gg(e.facetFilters||{}),"rangeFilters"in e&&Eg(e.rangeFilters||[]),"catalogSegment"in e&&(ct.catalogSegmentProxy.catalogSegment=e.catalogSegment||null),"pricebooks"in e&&yg(e.pricebooks||[]),ct.queryProxy.query=e.query,Cs()||sr.add({context:"search",payload:U({},ct.state)})},updateCatalogSegment:VC,updateFacetFilter:jC,updateFacetFilters:gg,updatePricebooks:yg,updateRangeFilter:$C,updateRangeFilters:Eg,updateSearchQuery:zC},Symbol.toStringTag,{value:"Module"})),YC=e=>{lt.categoryIdProxy.categoryId=e,Cs()||sr.add({context:"browse",payload:U({},lt.state)})},Tg=e=>{cg(e,lt)},WC=(e,t)=>{fg(e,t,lt)},bg=e=>{dg(e,lt)},GC=({field:e,value:t})=>{hg({field:e,value:t},lt)},KC=e=>{pg(e,lt)},_g=e=>{mg(e,lt)},QC=Object.freeze(Object.defineProperty({__proto__:null,setBrowseContext:e=>{if(!e||!e.categoryId)throw new Error("Browse context must include a categoryId");"facetFilters"in e&&Tg(e.facetFilters||{}),"rangeFilters"in e&&bg(e.rangeFilters||[]),"catalogSegment"in e&&(lt.catalogSegmentProxy.catalogSegment=e.catalogSegment||null),"pricebooks"in e&&_g(e.pricebooks||[]),lt.categoryIdProxy.categoryId=e.categoryId,Cs()||sr.add({context:"browse",payload:U({},lt.state)})},updateBrowseCategoryId:YC,updateCatalogSegment:KC,updateFacetFilter:WC,updateFacetFilters:Tg,updatePricebooks:_g,updateRangeFilter:GC,updateRangeFilters:bg},Symbol.toStringTag,{value:"Module"}));class XC{constructor(){ke(this,"initialParams",{productId:"",pdpLink:""});ke(this,"proxy");ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>(ag(n,r),Reflect.set(t,n,r)));ke(this,"updateProxy",t=>{t.productId&&(this.proxy=new Proxy({productId:t.productId,pdpLink:t.pdpLink||""},{get:this._fullGet,set:this._fullSet}))});this.proxy=new Proxy({productId:this.initialParams.productId,pdpLink:this.initialParams.pdpLink},{get:this._fullGet,set:this._fullSet})}get productId(){return this.proxy.productId}get pdpLink(){return this.proxy.pdpLink}get state(){return{productId:this.productId,pdpLink:this.pdpLink}}}const or=new XC,JC=e=>{if(!e||!e.productId)throw new Error("PDP context must include a productId");or.updateProxy(e),ag("pdp-context",e),Cs()||sr.add({context:"pdp",payload:U({},or.state)})},ZC=e=>{or.proxy.productId=e,Cs()||sr.add({context:"pdp",payload:U({},or.state)})},eA=e=>{or.proxy.pdpLink=e},tA=Object.freeze(Object.defineProperty({__proto__:null,getConversationMessages:({payload:e,callback:t})=>{Fa("getConversationMessages",{payload:e,callback:t},li.GET_CONVERSATION_MESSAGES)},getSessionInformation:e=>{Fa("getSessionInformation",{callback:e},li.GET_SESSION_INFORMATION)},loadConversation:e=>{Fa("loadConversation",e,li.LOAD_CONVERSATION)},resetConversation:()=>{Fa("resetConversation",!0,li.RESET_CONVERSATION)}},Symbol.toStringTag,{value:"Module"}));class nA{constructor(){ke(this,"initialParams",{query:"",page:null,pageSize:null,includeFacets:!0,facetFilters:{},rangeFilters:[],catalogSegment:null,pricebooks:null});ke(this,"queryProxy");ke(this,"facetFiltersProxy");ke(this,"rangeFiltersProxy");ke(this,"catalogSegmentProxy");ke(this,"pricebooksProxy");ke(this,"_fullGet",(t,n)=>Reflect.get(t,n));ke(this,"_fullSet",(t,n,r)=>{const o=pC[n];return RC(o,n,r),Reflect.set(t,n,r)});ke(this,"updateFacetFiltersProxy",t=>new Proxy({facetFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updateRangeFiltersProxy",t=>new Proxy({rangeFilters:t},{get:this._fullGet,set:this._fullSet}));ke(this,"updatePricebooksProxy",t=>new Proxy({pricebooks:t},{get:this._fullGet,set:this._fullSet}));this.queryProxy=new Proxy({query:this.initialParams.query},{get:this._fullGet,set:this._fullSet}),this.facetFiltersProxy=this.updateFacetFiltersProxy(this.initialParams.facetFilters||{}),this.rangeFiltersProxy=this.updateRangeFiltersProxy(this.initialParams.rangeFilters||[]),this.catalogSegmentProxy=new Proxy({catalogSegment:this.initialParams.catalogSegment},{get:this._fullGet,set:this._fullSet}),this.pricebooksProxy=this.updatePricebooksProxy(this.initialParams.pricebooks||null)}get query(){return this.queryProxy.query||""}get facetFilters(){return this.facetFiltersProxy.facetFilters||{}}get rangeFilters(){return this.rangeFiltersProxy.rangeFilters||[]}get catalogSegment(){return this.catalogSegmentProxy.catalogSegment||null}get pricebooks(){return this.pricebooksProxy.pricebooks||null}get state(){return{query:this.query,facetFilters:this.facetFilters,rangeFilters:this.rangeFilters,catalogSegment:this.catalogSegment,pricebooks:this.pricebooks,page:this.initialParams.page,pageSize:this.initialParams.pageSize,includeFacets:this.initialParams.includeFacets}}}const ct=new nA,rA={searchQuery:ct.query,facetFilters:ct.facetFilters,rangeFilters:ct.rangeFilters,catalogSegment:ct.catalogSegment,pricebooks:ct.pricebooks},xg=W.createContext(rA),iA=({children:e})=>{const[t,n]=W.useState(ct.query),[r,o]=W.useState(ct.facetFilters),[u,a]=W.useState(ct.rangeFilters),[c,f]=W.useState(ct.catalogSegment),[h,m]=W.useState(ct.pricebooks);W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="query"&&n(T.value),(T==null?void 0:T.property)==="facetFilters"&&o(T.value),(T==null?void 0:T.property)==="rangeFilters"&&a(T.value),(T==null?void 0:T.property)==="catalogSegment"&&f(T.value),(T==null?void 0:T.property)==="pricebooks"&&m(T.value)};return ng(b),()=>{rg(b)}},[]);const E=W.useMemo(()=>({searchQuery:t,facetFilters:r,rangeFilters:u,catalogSegment:c,pricebooks:h}),[t,r,u,c,h]);return I.jsx(xg.Provider,{value:E,children:e})},sA=()=>{const e=W.useContext(xg);if(!e)throw new Error("useSearch must be used within a SearchProvider");return e},Sg=()=>{const e=W.useContext(Z0);if(!e)throw new Error("useCopilotDispatch must be used within a CopilotProvider");return e},wg=()=>{const e=W.useContext(J0);if(!e)throw new Error("useCopilotState must be used within a CopilotProvider");return e},Cg=W.createContext({copilot:null,messages:[],groupedMessages:[],isLoading:!1,isResponseLoading:()=>!1,handleSearch:()=>{},handleBrowse:()=>{},handlePdp:()=>{},handleSuggestion:()=>{},handleUserInput:()=>{},handleCancel:()=>{},resetConversation:()=>{},getSessionInformation:()=>{},getConversationMessages:()=>{}}),oA=({apiKey:e,apiToken:t,baseUrl:n,isDevelopment:r,onConnect:o,onRefinedSearch:u,onRefinedBrowse:a,children:c})=>{const{logger:f}=ir(),Je=sA(),{searchQuery:h}=Je,m=en(Je,["searchQuery"]),xt=HC(),{categoryId:E}=xt,b=en(xt,["categoryId"]),{setCopilot:T,setConnected:_,resetCopilot:S,resetCopilotState:C,addCopilotEvent:k,addLoadingMessage:M,removeLoadingMessage:D}=Sg(),{connected:G,copilot:q,messages:B,groupedMessages:te,loadingMessages:Te}=wg(),Se=W.useRef(!1),H=W.useRef(!1),fe=W.useMemo(()=>Te.size>0,[Te]),de=W.useCallback(be=>Te.has(be),[Te]),ue=W.useCallback(be=>{k(be),M(be.id)},[k,M]),ie=W.useCallback(({query:be,facetFilters:He,rangeFilters:tt,catalogSegment:Tt,pricebooks:St,userPrompt:on,isUserAction:qt})=>{if(!q){f==null||f.error("Copilot is not initialized");return}if(!be)return;const rt={searchParams:{query:be}};on&&(rt.userPrompt=on),He&&Object.keys(He).length>0&&(rt.searchParams.facetFilters=He),tt&&tt.length>0&&(rt.searchParams.rangeFilters=tt),Tt&&(rt.searchParams.catalogSegment=Tt),St&&(rt.searchParams.pricebooks=St);const Rr=!Se.current;q.search(rt,Wn=>{const Yt=U({},Wn);Rr&&(Yt.isInitial=!0,Yt.isUserAction=!0),qt&&(Yt.isUserAction=qt),Se.current=!0,ue(Yt)})},[f,ue,q]),ge=W.useCallback(({categoryId:be,facetFilters:He,rangeFilters:tt,catalogSegment:Tt,pricebooks:St,userPrompt:on,isUserAction:qt})=>{if(!q){f==null||f.error("Copilot is not initialized");return}if(!be)return;const rt={browseParams:{categoryId:be}};on&&(rt.userPrompt=on),He&&Object.keys(He).length>0&&(rt.browseParams.facetFilters=He),tt&&tt.length>0&&(rt.browseParams.rangeFilters=tt),Tt&&(rt.browseParams.catalogSegment=Tt),St&&(rt.browseParams.pricebooks=St);const Rr=!H.current;q.browse(rt,Wn=>{const Yt=U({},Wn);Rr&&(Yt.isInitial=!0,Yt.isUserAction=!0),qt&&(Yt.isUserAction=qt),H.current=!0,ue(Yt)})},[f,ue,q]),we=W.useCallback(({productId:be,pdpLink:He,userPrompt:tt,isUserAction:Tt})=>{if(!q){f==null||f.error("Copilot is not initialized");return}if(!be)return;const St={productId:be};tt&&(St.userPrompt=tt),He&&(St.pdpLink=He),q.productView(St,on=>{const qt=U({},on);Tt&&(qt.isUserAction=Tt),ue(qt)})},[f,q,ue]),ae=W.useCallback(be=>{const He=ye(U({},be),{id:be.inquiryLinkId||be.id});k(He)},[k]),V=W.useCallback(be=>{k(be),u==null||u(be)},[k,u]),ee=W.useCallback(be=>{k(be),a==null||a(be)},[k,a]),w=W.useCallback(be=>{o==null||o(be),_(!0)},[o,_]);W.useEffect(()=>{!q||!G||sr.size>0&&sr.processQueue(be=>{if(be.context==="search"){const He=ye(U({},be.payload),{isUserAction:!0});ie(He)}if(be.context==="browse"){const He=ye(U({},be.payload),{isUserAction:!0});ge(He)}if(be.context==="pdp"){const He=ye(U({},be.payload),{isUserAction:!0});we(He)}})},[q,G,ie,ge,we]);const R=W.useCallback(be=>{q&&q.requestSessionInformation(He=>{f==null||f.log("Retrieved session information: ",He),be==null||be(He)})},[q,f]),Q=W.useCallback((be,He)=>{q&&be.conversationId&&q.getConversationEvents(be,tt=>{f==null||f.log("Retrieved conversation messages: ",tt),He(tt)})},[q,f]),N=W.useCallback(be=>{be.on("connect_ack",w),be.on("follow_up",k),be.on("inquiry",ae),be.on("partial_inquiry",ae),be.on("display_products",k),be.on("progress",k),be.on("refined_search",V),be.on("refined_browse",ee),be.on("done",He=>{D(He.eventSourceId)}),be.on("error",He=>{k(He),D(He.eventSourceId)}),be.onDisconnect(He=>{const tt=["io server disconnect","transport error","server shutting down"];if(f==null||f.log("Connection disconnected with reason: ",He),!tt.includes(He)){_(!1);return}f==null||f.log("De-registering event listeners");const Tt=new Date().toISOString();k({name:"error",message:"Connection was lost. Please try again.",createdAt:Tt,id:`error-${Tt}`,sessionId:"session"}),be.off()})},[f,_,D,ae,V,ee,k,w]);NC(()=>{let be;n?be=n:be=r?"https://staging.copilot.search.cimulate.ai":"https://prod.copilot.search.cimulate.ai";const He={baseUrl:be};e?He.apiKey=e:t&&(He.apiToken=t);const tt=new NS(He);return T(tt),N(tt),tt.connect(),tt.requestSessionInformation(Tt=>{f==null||f.log("Session Information: ",Tt)}),()=>{tt.disconnect(),tt.off(),S()}});const _e=W.useCallback(be=>{if(!q)return;const He={eventId:be,reason:"User cancelled the request"};q.cancelRequest(He,tt=>{k(tt),D(be)})},[k,D,q]),Me=W.useCallback(()=>{q&&q.conversationReset({},be=>{C(),k(be),q.requestSessionInformation(He=>{f==null||f.log("Session Information: ",He)})})},[q,f,k,C]),Ie=W.useCallback(be=>{!be||!h||ie(ye(U({query:h},m),{userPrompt:be}))},[h,m,ie]),Ye=W.useCallback((be,He)=>{var on,qt;const Tt=be.params.userPrompt||"";if(!Tt)return;const St=B.find(rt=>rt.id===He);if(St){if(St.name==="copilot_search"){const{query:rt}=((on=St.request)==null?void 0:on.searchParams)||{};rt&&ie(ye(U({query:rt||h},m),{userPrompt:Tt}));return}if(St.name==="copilot_browse"){const{categoryId:rt}=((qt=St.request)==null?void 0:qt.browseParams)||{};if(rt){ge(ye(U({categoryId:rt||E},b),{userPrompt:Tt}));return}}if(St.name==="product_view"){const rt=St.request;rt!=null&&rt.productId&&we(ye(U({},rt),{userPrompt:Tt}))}}},[h,m,E,b,B,ie,ge,we]),Ve=W.useMemo(()=>({copilot:q,messages:B,groupedMessages:te,isLoading:fe,isResponseLoading:de,handleSearch:ie,handleBrowse:ge,handlePdp:we,handleUserInput:Ie,handleSuggestion:Ye,handleCancel:_e,resetConversation:Me,getSessionInformation:R,getConversationMessages:Q}),[q,B,te,fe,de,ie,ge,we,Ie,Ye,_e,Me,R,Q]);return I.jsx(Cg.Provider,{value:Ve,children:c})},qr=()=>{const e=W.useContext(Cg);if(!e)throw new Error("useCopilot must be used within a CopilotProvider");return e},uA=()=>{const{resetCopilotState:e,addCopilotEvent:t}=Sg(),{copilot:n,handleSearch:r,handleBrowse:o,handlePdp:u,resetConversation:a,getSessionInformation:c,getConversationMessages:f}=qr(),h=W.useCallback(({query:b,isUserAction:T})=>{if(!n||!b)return;const{facetFilters:_}=ct.facetFiltersProxy,{rangeFilters:S}=ct.rangeFiltersProxy,{catalogSegment:C}=ct.catalogSegmentProxy,{pricebooks:k}=ct.pricebooksProxy,M={query:b};_&&Object.keys(_).length>0&&(M.facetFilters=_),S&&S.length>0&&(M.rangeFilters=S),C&&(M.catalogSegment=C),k&&(M.pricebooks=k),r(ye(U({},M),{isUserAction:T}))},[n,r]),m=W.useCallback(({categoryId:b,isUserAction:T})=>{if(!n||!b)return;const{facetFilters:_}=lt.facetFiltersProxy,{rangeFilters:S}=lt.rangeFiltersProxy,{catalogSegment:C}=lt.catalogSegmentProxy,{pricebooks:k}=lt.pricebooksProxy,M={categoryId:b};_&&Object.keys(_).length>0&&(M.facetFilters=_),S&&S.length>0&&(M.rangeFilters=S),C&&(M.catalogSegment=C),k&&(M.pricebooks=k),o(ye(U({},M),{isUserAction:T}))},[n,o]),E=W.useCallback(({productId:b,isUserAction:T})=>{if(!n||!b)return;const _={productId:b,pdpLink:or.pdpLink,isUserAction:T};u(U({},_))},[n,u]);return W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="query"&&h({query:T.value,isUserAction:!0})};return ng(b),()=>{rg(b)}},[h]),W.useEffect(()=>{const b=({detail:T})=>{if((T==null?void 0:T.property)==="pdp-context"){const _=T.value;E({productId:_.productId,isUserAction:!0});return}(T==null?void 0:T.property)==="productId"&&E({productId:T.value,isUserAction:!0})};return og(b),()=>{ug(b)}},[E]),W.useEffect(()=>{const b=({detail:T})=>{(T==null?void 0:T.property)==="categoryId"&&m({categoryId:T.value,isUserAction:!0})};return ig(b),()=>{sg(b)}},[m]),W.useEffect(()=>{const b=({detail:T})=>{if((T==null?void 0:T.event)==li.RESET_CONVERSATION&&a(),(T==null?void 0:T.event)==li.GET_SESSION_INFORMATION){const _=T.value.callback;c(_)}if((T==null?void 0:T.event)==li.GET_CONVERSATION_MESSAGES){const{payload:_,callback:S}=T.value;if(!_.conversationId||typeof S!="function")return;f(_,S)}if((T==null?void 0:T.event)==li.LOAD_CONVERSATION){const _=T.value;if(!_.conversationId)return;f(_,C=>{e(),C.forEach(k=>{t(k)})})}};return DC(b),()=>{FC(b)}},[a,c,f,e,t]),null},aA=({apiKey:e,apiToken:t,baseUrl:n,isDevelopment:r,onConnect:o,onCopilotEvent:u,onRefinedSearch:a,onRefinedBrowse:c,children:f})=>I.jsx(vC,{onCopilotEvent:u,children:I.jsxs(oA,{apiKey:e,apiToken:t,baseUrl:n,isDevelopment:r,onConnect:o,onRefinedSearch:a,onRefinedBrowse:c,children:[I.jsx(uA,{}),f]})}),lA={productId:or.productId,pdpLink:or.pdpLink},cA=W.createContext(lA),fA=({children:e})=>{const[t,n]=W.useState(or.productId),[r,o]=W.useState(or.pdpLink);W.useEffect(()=>{const a=({detail:c})=>{if((c==null?void 0:c.property)==="pdp-context"){const f=c.value;n(f.productId),o(f.pdpLink);return}(c==null?void 0:c.property)==="productId"&&n(c.value),(c==null?void 0:c.property)==="pdpLink"&&o(c.value)};return og(a),()=>{ug(a)}},[]);const u=W.useMemo(()=>({productId:t,pdpLink:r}),[t,r]);return I.jsx(cA.Provider,{value:u,children:e})},Ag=W.createContext({mode:Ot.modeProxy.mode,status:Ot.statusProxy,dialogPosition:Ot.dialogProxy.position,isModalFullscreen:Ot.modalProxy.isFullscreen,previousComponentType:Ot.statusProxy.type}),dA=({componentType:e,children:t})=>{const[n,r]=W.useState(Ot.modeProxy.mode),[o,u]=W.useState({type:e||Ot.statusProxy.type,isOpen:Ot.statusProxy.isOpen}),[a,c]=W.useState(Ot.dialogProxy.position),[f,h]=W.useState(Ot.modalProxy.isFullscreen),m=IC(o.type);W.useEffect(()=>{const b=T=>{const{property:_,value:S}=T.detail||{};if(!(!_||S===void 0)){if(_==="mode"){r(S);return}if(_==="isOpen"){u(C=>ye(U({},C),{isOpen:S}));return}if(_==="type"){u(C=>ye(U({},C),{type:S}));return}if(_==="position"){c(S);return}if(_==="isFullscreen"){h(S);return}}};return bC(b),()=>{_C(b)}},[]);const E=W.useMemo(()=>({mode:n,status:o,previousComponentType:m||"dialog",dialogPosition:a,isModalFullscreen:f}),[n,o,m,a,f]);return I.jsx(Ag.Provider,{value:E,children:t})},vg=({apiKey:e,apiToken:t,baseUrl:n,logoUrl:r,headerText:o,theme:u,globalClassName:a,isDevelopment:c=!1,componentType:f,searchPlaceholder:h,searchButtonLabel:m,resetConversationMessage:E,onConnect:b,onCopilotEvent:T,onRefinedSearch:_,onRefinedBrowse:S,children:C})=>I.jsx(yC,{apiKey:e,logoUrl:r,headerText:o,theme:u,globalClassName:a,searchPlaceholder:h,searchButtonLabel:m,resetConversationMessage:E,isDevelopment:c,children:I.jsx(Zw,{apiKey:e,apiToken:t,isDevelopment:c,children:I.jsx(fA,{children:I.jsx(UC,{children:I.jsx(iA,{children:I.jsx(dA,{componentType:f,children:I.jsx(aA,{apiKey:e,apiToken:t,baseUrl:n,isDevelopment:c,onConnect:b,onCopilotEvent:T,onRefinedSearch:_,onRefinedBrowse:S,children:C})})})})})})}),Ma=()=>{const e=W.useContext(Ag);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};function kg(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=kg(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function oe(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=kg(e))&&(r&&(r+=" "),r+=t);return r}var Ng={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Og=Bi.createContext&&Bi.createContext(Ng),hA=["attr","size","title"];function pA(e,t){if(e==null)return{};var n=mA(e,t),r,o;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);for(o=0;o<u.length;o++)r=u[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function mA(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Ba(){return Ba=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ba.apply(this,arguments)}function Ig(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Ua(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ig(Object(n),!0).forEach(function(r){gA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ig(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gA(e,t,n){return t=EA(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function EA(e){var t=yA(e,"string");return typeof t=="symbol"?t:t+""}function yA(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Pg(e){return e&&e.map((t,n)=>Bi.createElement(t.tag,Ua({key:n},t.attr),Pg(t.child)))}function On(e){return t=>Bi.createElement(TA,Ba({attr:Ua({},e.attr)},t),Pg(e.child))}function TA(e){var t=n=>{var{attr:r,size:o,title:u}=e,a=pA(e,hA),c=o||n.size||"1em",f;return n.className&&(f=n.className),e.className&&(f=(f?f+" ":"")+e.className),Bi.createElement("svg",Ba({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,a,{className:f,style:Ua(Ua({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),u&&Bi.createElement("title",null,u),e.children)};return Og!==void 0?Bi.createElement(Og.Consumer,null,n=>t(n)):t(Ng)}function Rg(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"},child:[]}]})(e)}function Ha(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"},child:[]}]})(e)}function bA(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"},child:[]}]})(e)}function Lg(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 9h12v2H6V9zm8 5H6v-2h8v2zm4-6H6V6h12v2z"},child:[]}]})(e)}function _A(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12 8-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"},child:[]}]})(e)}function xA(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"},child:[]}]})(e)}function SA(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M5 16h3v3h2v-5H5v2zm3-8H5v2h5V5H8v3zm6 11h2v-3h3v-2h-5v5zm2-11V5h-2v5h5V8h-3z"},child:[]}]})(e)}function wA(e){return On({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"},child:[]}]})(e)}const $f=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>I.jsx("button",{className:oe(`${Z}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),jo=({className:e,icon:t,type:n="button",ariaLabel:r,disabled:o=!1,onClick:u})=>I.jsx("button",{className:oe(e,`${Z}-icon-button`),type:n,"aria-label":r,onClick:u,disabled:o,children:t}),CA=({className:e,searchButtonLabel:t,globalClassName:n,componentType:r,isLoading:o})=>t?I.jsx($f,{className:oe(n,r,e),type:"submit",disabled:o,children:t}):I.jsx(jo,{className:oe(n,r,e),type:"submit",disabled:o,ariaLabel:"Search Copilot",icon:I.jsx(Ha,{})}),Vf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{connected:o}=wg(),{globalClassName:u,searchPlaceholder:a,searchButtonLabel:c}=ir(),f=W.useRef(null),h=b=>{var _;b.preventDefault();const T=(((_=f.current)==null?void 0:_.value)||"").trim();T&&(r(T),f.current.value="")},m=!!o||!1,E=m?"connected":"disconnected";return I.jsxs("form",{className:oe(u,e,n,`${Z}-search-bar`),name:`${Z}-search-form`,onSubmit:h,children:[I.jsx("span",{role:"status",className:oe(`${Z}-connection-status-icon`,E)}),I.jsx("input",{className:oe(u,e,n,`${Z}-search-input`),type:"text",ref:f,placeholder:a,name:`${Z}-user-input`}),I.jsx(CA,{searchButtonLabel:c,globalClassName:u,componentType:n,isLoading:t||!m})]})};function AA(e){return e==null?[]:Array.isArray(e)?e:[e]}var vA=e=>e!=null&&typeof e=="object",za=e=>typeof e=="string",As=e=>typeof e=="function",kA=e=>e==null,NA=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),OA=e=>Object.prototype.toString.call(e),Dg=Function.prototype.toString,IA=Dg.call(Object),PA=e=>{if(!vA(e)||OA(e)!="[object Object]"||DA(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=NA(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&Dg.call(n)==IA},RA=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,LA=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,DA=e=>RA(e)||LA(e),FA=e=>e(),MA=()=>{},qf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function Yf(e){if(!PA(e)||e===void 0)return e;const t=Reflect.ownKeys(e).filter(r=>typeof r=="string"),n={};for(const r of t){const o=e[r];o!==void 0&&(n[r]=Yf(o))}return n}function Wf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function BA(e,t){if(e==null)throw new Error(t())}var UA=Object.defineProperty,HA=(e,t,n)=>t in e?UA(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Gf=(e,t,n)=>HA(e,typeof t!="symbol"?t+"":t,n),Fg=()=>{},ja=e=>typeof e=="object"&&e!==null,zA=e=>e?"":void 0,jA=e=>e?"true":void 0,$A=1,VA=9,qA=11,jt=e=>ja(e)&&e.nodeType===$A&&typeof e.nodeName=="string",$a=e=>ja(e)&&e.nodeType===VA,YA=e=>ja(e)&&e===e.window,Mg=e=>jt(e)?e.localName||"":"#document";function WA(e){return["html","body","#document"].includes(Mg(e))}var GA=e=>ja(e)&&e.nodeType!==void 0,Vi=e=>GA(e)&&e.nodeType===qA&&"host"in e,KA=e=>jt(e)&&e.localName==="input",QA=e=>jt(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function $o(e){if(!e)return!1;const t=e.getRootNode();return ks(t)===e}var XA=/(textarea|select)/;function JA(e){if(e==null||!jt(e))return!1;try{return KA(e)&&e.selectionStart!=null||XA.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function Va(e,t){var r;if(!e||!t||!jt(e)||!jt(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Vi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Sr(e){var t;return $a(e)?e:YA(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function ZA(e){return Sr(e).documentElement}function vs(e){var t,n,r;return Vi(e)?vs(e.host):$a(e)?(t=e.defaultView)!=null?t:window:jt(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function ks(e){let t=e.activeElement;for(;t!=null&&t.shadowRoot;){const n=t.shadowRoot.activeElement;if(!n||n===t)break;t=n}return t}function ev(e){if(Mg(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Vi(e)&&e.host||ZA(e);return Vi(t)?t.host:t}function Kf(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),$a(t)||Vi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var Qf=new WeakMap;function qa(e){return Qf.has(e)||Qf.set(e,vs(e).getComputedStyle(e)),Qf.get(e)}var Xf=new Set(["menu","listbox","dialog","grid","tree","region"]),tv=e=>Xf.has(e),Bg=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function Ug(e,t){const n=new Set,r=Kf(e),o=u=>{const a=u.querySelectorAll("[aria-controls]");for(const c of a){if(c.getAttribute("aria-expanded")!=="true")continue;const f=Bg(c);for(const h of f){if(!h||n.has(h))continue;n.add(h);const m=r.getElementById(h);if(m){const E=m.getAttribute("role"),b=m.getAttribute("aria-modal")==="true";if(E&&tv(E)&&!b&&(m===t||m.contains(t)||o(m)))return!0}}}return!1};return o(e)}function Hg(e,t){const n=Kf(e),r=new Set,o=u=>{const a=u.querySelectorAll("[aria-controls]");for(const c of a){if(c.getAttribute("aria-expanded")!=="true")continue;const f=Bg(c);for(const h of f){if(!h||r.has(h))continue;r.add(h);const m=n.getElementById(h);if(m){const E=m.getAttribute("role"),b=m.getAttribute("aria-modal")==="true";E&&Xf.has(E)&&!b&&(t(m),o(m))}}}};o(e)}function nv(e){const t=new Set;return Hg(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function rv(e){const t=e.getAttribute("role");return!!(t&&Xf.has(t))}function iv(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function sv(e){var t;return iv(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function ov(e){if(!e.id)return!1;const t=Kf(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&rv(e))}var Jf=()=>typeof document!="undefined";function uv(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Zf=e=>Jf()&&e.test(uv()),av=e=>Jf()&&e.test(navigator.vendor),zg=()=>Jf()&&!!navigator.maxTouchPoints,lv=()=>Zf(/^iPhone/i),cv=()=>Zf(/^iPad/i)||ed()&&navigator.maxTouchPoints>1,jg=()=>lv()||cv(),fv=()=>ed()||jg(),ed=()=>Zf(/^Mac/i),dv=()=>fv()&&av(/apple/i);function hv(e){var t,n,r,o;return(o=(t=e.composedPath)==null?void 0:t.call(e))!=null?o:(r=(n=e.nativeEvent)==null?void 0:n.composedPath)==null?void 0:r.call(n)}function Yr(e){var n;const t=hv(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var pv=e=>e.button===0,mv=e=>e.button===2||ed()&&e.ctrlKey&&e.button===0,ur=(e,t,n,r)=>{const o=typeof e=="function"?e():e;return o==null||o.addEventListener(t,n,r),()=>{o==null||o.removeEventListener(t,n,r)}},$g=e=>jt(e)&&e.tagName==="IFRAME",gv=/^(audio|video|details)$/;function Vg(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var Ev=e=>!Number.isNaN(Vg(e)),yv=e=>Vg(e)<0;function Tv(e,t){if(!t)return null;if(t===!0)return e.shadowRoot||null;const n=t(e);return(n===!0?e.shadowRoot:n)||null}function qg(e,t,n){const r=[...e],o=[...e],u=new Set,a=new Map;e.forEach((f,h)=>a.set(f,h));let c=0;for(;c<o.length;){const f=o[c++];if(!f||u.has(f))continue;u.add(f);const h=Tv(f,t);if(h){const m=Array.from(h.querySelectorAll(Ya)).filter(n),E=a.get(f);if(E!==void 0){const b=E+1;r.splice(b,0,...m),m.forEach((T,_)=>{a.set(T,b+_)});for(let T=b+m.length;T<r.length;T++)a.set(r[T],T)}else{const b=r.length;r.push(...m),m.forEach((T,_)=>{a.set(T,b+_)})}o.push(...m)}}return r}var Ya="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false']), details > summary:first-of-type",Yg=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ya));(n==!0||n=="if-empty"&&o.length===0)&&jt(e)&&Wr(e)&&o.unshift(e);const a=[];for(const c of o)if(Wr(c)){if($g(c)&&c.contentDocument){const f=c.contentDocument.body;a.push(...Yg(f,{getShadowRoot:r}));continue}a.push(c)}return r?qg(a,r,Wr):a};function Wr(e){return!jt(e)||e.closest("[inert]")?!1:e.matches(Ya)&&QA(e)}function Vo(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ya));n&&qi(e)&&o.unshift(e);const u=[];for(const a of o)if(qi(a)){if($g(a)&&a.contentDocument){const c=a.contentDocument.body;u.push(...Vo(c,{getShadowRoot:r}));continue}u.push(a)}if(r){const a=qg(u,r,qi);return!a.length&&n?o:a}return!u.length&&n?o:u}function qi(e){return jt(e)&&e.tabIndex>0?!0:Wr(e)&&!yv(e)}function bv(e,t={}){const n=Vo(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function _v(e,t={}){const{current:n,getShadowRoot:r}=t,o=Vo(e,{getShadowRoot:r}),u=(e==null?void 0:e.ownerDocument)||document,a=n!=null?n:ks(u);if(!a)return null;const c=o.indexOf(a);return o[c+1]||null}function qo(e){return e.tabIndex<0&&(gv.test(e.localName)||JA(e))&&!Ev(e)?0:e.tabIndex}function Wg(e){const{root:t,getInitialEl:n,filter:r,enabled:o=!0}=e;if(!o)return;let u=null;if(u||(u=typeof n=="function"?n():n),u||(u=t==null?void 0:t.querySelector("[data-autofocus],[autofocus]")),!u){const a=Vo(t);u=r?a.filter(r)[0]:a[0]}return u||t||void 0}var xv=class gx{constructor(){Gf(this,"id",null),Gf(this,"fn_cleanup"),Gf(this,"cleanup",()=>{this.cancel()})}static create(){return new gx}request(t){this.cancel(),this.id=globalThis.requestAnimationFrame(()=>{this.id=null,this.fn_cleanup=t==null?void 0:t()})}cancel(){var t;this.id!==null&&(globalThis.cancelAnimationFrame(this.id),this.id=null),(t=this.fn_cleanup)==null||t.call(this),this.fn_cleanup=void 0}isActive(){return this.id!==null}};function Tn(e){const t=xv.create();return t.request(e),t.cleanup}function Sv(e){const t=new Set;function n(r){const o=globalThis.requestAnimationFrame(r);t.add(()=>globalThis.cancelAnimationFrame(o))}return n(()=>n(e)),function(){t.forEach(o=>o())}}function td(e){const t=ev(e);return WA(t)?Sr(t).body:jt(t)&&Av(t)?t:td(t)}var wv=/auto|scroll|overlay|hidden|clip/,Cv=new Set(["inline","contents"]);function Av(e){const t=vs(e),{overflow:n,overflowX:r,overflowY:o,display:u}=t.getComputedStyle(e);return wv.test(n+o+r)&&!Cv.has(u)}function vv(e,t={}){const{triggerElement:n,onFocus:r,onFocusEnter:o,getShadowRoot:u}=t,a=(e==null?void 0:e.ownerDocument)||document,c=a.body;function f(h){if(h.key!=="Tab")return;let m=null;const[E,b]=bv(e,{includeContainer:!0,getShadowRoot:u}),T=_v(c,{current:n,getShadowRoot:u}),_=!E&&!b;h.shiftKey&&$o(T)?(o==null||o(),m=b):h.shiftKey&&($o(E)||_)?m=n:!h.shiftKey&&$o(n)?(o==null||o(),m=E):!h.shiftKey&&($o(b)||_)&&(m=T),m&&(h.preventDefault(),typeof r=="function"?r(m):m.focus())}return ur(a,"keydown",f,!0)}function kv(e,t){const c=t,{defer:n,triggerElement:r}=c,o=en(c,["defer","triggerElement"]),u=n?Tn:f=>f(),a=[];return a.push(u(()=>{const f=typeof e=="function"?e():e,h=typeof r=="function"?r():r;a.push(vv(f,U({triggerElement:h},o)))})),()=>{a.forEach(f=>f==null?void 0:f())}}function Wa(e,t){if(!e)return Fg;const n=Object.keys(t).reduce((r,o)=>(r[o]=e.style.getPropertyValue(o),r),{});return Object.assign(e.style,t),()=>{Object.assign(e.style,n),e.style.length===0&&e.removeAttribute("style")}}function Nv(e,t,n){if(!e)return Fg;const r=e.style.getPropertyValue(t);return e.style.setProperty(t,n),()=>{e.style.setProperty(t,r),e.style.length===0&&e.removeAttribute("style")}}function Ov(e,t,n){const{signal:r}=t;return[new Promise((a,c)=>{const f=setTimeout(()=>{c(new Error(`Timeout of ${n}ms exceeded`))},n);r.addEventListener("abort",()=>{clearTimeout(f),c(new Error("Promise aborted"))}),e.then(h=>{r.aborted||(clearTimeout(f),a(h))}).catch(h=>{r.aborted||(clearTimeout(f),c(h))})}),()=>t.abort()]}function Iv(e,t){const{timeout:n,rootNode:r}=t,o=vs(r),u=Sr(r),a=new o.AbortController;return Ov(new Promise(c=>{const f=e();if(f){c(f);return}const h=new o.MutationObserver(()=>{const m=e();m&&m.isConnected&&(h.disconnect(),c(m))});h.observe(u.body,{childList:!0,subtree:!0})}),a,n)}var Pv=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),Rv=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,Gg=e=>{const t={};let n;for(;n=Rv.exec(e);)t[n[1]]=n[2];return t},Lv=(e,t)=>{if(za(e)){if(za(t))return`${e};${t}`;e=Gg(e)}else za(t)&&(t=Gg(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function ar(...e){let t={};for(let n of e){if(!n)continue;for(let o in t){if(o.startsWith("on")&&typeof t[o]=="function"&&typeof n[o]=="function"){t[o]=qf(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=Pv(t[o],n[o]);continue}if(o==="style"){t[o]=Lv(t[o],n[o]);continue}t[o]=n[o]!==void 0?n[o]:t[o]}for(let o in n)t[o]===void 0&&(t[o]=n[o]);const r=Object.getOwnPropertySymbols(n);for(let o of r)t[o]=n[o]}return t}function zM(e){return e}var Ns=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Ns||{}),nd="__init__";function Dv(e){const t=()=>{var a,c;return(c=(a=e.getRootNode)==null?void 0:a.call(e))!=null?c:document},n=()=>Sr(t()),r=()=>{var a;return(a=n().defaultView)!=null?a:window},o=()=>ks(t()),u=a=>t().getElementById(a);return ye(U({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:$o,getById:u})}var rd={exports:{}},bn={},id={exports:{}},sd={};var Kg;function Fv(){return Kg||(Kg=1,function(e){function t(V,ee){var w=V.length;V.push(ee);e:for(;0<w;){var R=w-1>>>1,Q=V[R];if(0<o(Q,ee))V[R]=ee,V[w]=Q,w=R;else break e}}function n(V){return V.length===0?null:V[0]}function r(V){if(V.length===0)return null;var ee=V[0],w=V.pop();if(w!==ee){V[0]=w;e:for(var R=0,Q=V.length,N=Q>>>1;R<N;){var _e=2*(R+1)-1,Me=V[_e],Ie=_e+1,Ye=V[Ie];if(0>o(Me,w))Ie<Q&&0>o(Ye,Me)?(V[R]=Ye,V[Ie]=w,R=Ie):(V[R]=Me,V[_e]=w,R=_e);else if(Ie<Q&&0>o(Ye,w))V[R]=Ye,V[Ie]=w,R=Ie;else break e}}return ee}function o(V,ee){var w=V.sortIndex-ee.sortIndex;return w!==0?w:V.id-ee.id}if(typeof performance=="object"&&typeof performance.now=="function"){var u=performance;e.unstable_now=function(){return u.now()}}else{var a=Date,c=a.now();e.unstable_now=function(){return a.now()-c}}var f=[],h=[],m=1,E=null,b=3,T=!1,_=!1,S=!1,C=typeof setTimeout=="function"?setTimeout:null,k=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function D(V){for(var ee=n(h);ee!==null;){if(ee.callback===null)r(h);else if(ee.startTime<=V)r(h),ee.sortIndex=ee.expirationTime,t(f,ee);else break;ee=n(h)}}function G(V){if(S=!1,D(V),!_)if(n(f)!==null)_=!0,we(q);else{var ee=n(h);ee!==null&&ae(G,ee.startTime-V)}}function q(V,ee){_=!1,S&&(S=!1,k(Te),Te=-1),T=!0;var w=b;try{for(D(ee),E=n(f);E!==null&&(!(E.expirationTime>ee)||V&&!fe());){var R=E.callback;if(typeof R=="function"){E.callback=null,b=E.priorityLevel;var Q=R(E.expirationTime<=ee);ee=e.unstable_now(),typeof Q=="function"?E.callback=Q:E===n(f)&&r(f),D(ee)}else r(f);E=n(f)}if(E!==null)var N=!0;else{var _e=n(h);_e!==null&&ae(G,_e.startTime-ee),N=!1}return N}finally{E=null,b=w,T=!1}}var B=!1,te=null,Te=-1,Se=5,H=-1;function fe(){return!(e.unstable_now()-H<Se)}function de(){if(te!==null){var V=e.unstable_now();H=V;var ee=!0;try{ee=te(!0,V)}finally{ee?ue():(B=!1,te=null)}}else B=!1}var ue;if(typeof M=="function")ue=function(){M(de)};else if(typeof MessageChannel!="undefined"){var ie=new MessageChannel,ge=ie.port2;ie.port1.onmessage=de,ue=function(){ge.postMessage(null)}}else ue=function(){C(de,0)};function we(V){te=V,B||(B=!0,ue())}function ae(V,ee){Te=C(function(){V(e.unstable_now())},ee)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(V){V.callback=null},e.unstable_continueExecution=function(){_||T||(_=!0,we(q))},e.unstable_forceFrameRate=function(V){0>V||125<V?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Se=0<V?Math.floor(1e3/V):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_getFirstCallbackNode=function(){return n(f)},e.unstable_next=function(V){switch(b){case 1:case 2:case 3:var ee=3;break;default:ee=b}var w=b;b=ee;try{return V()}finally{b=w}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(V,ee){switch(V){case 1:case 2:case 3:case 4:case 5:break;default:V=3}var w=b;b=V;try{return ee()}finally{b=w}},e.unstable_scheduleCallback=function(V,ee,w){var R=e.unstable_now();switch(typeof w=="object"&&w!==null?(w=w.delay,w=typeof w=="number"&&0<w?R+w:R):w=R,V){case 1:var Q=-1;break;case 2:Q=250;break;case 5:Q=1073741823;break;case 4:Q=1e4;break;default:Q=5e3}return Q=w+Q,V={id:m++,callback:ee,priorityLevel:V,startTime:w,expirationTime:Q,sortIndex:-1},w>R?(V.sortIndex=w,t(h,V),n(f)===null&&V===n(h)&&(S?(k(Te),Te=-1):S=!0,ae(G,w-R))):(V.sortIndex=Q,t(f,V),_||T||(_=!0,we(q))),V},e.unstable_shouldYield=fe,e.unstable_wrapCallback=function(V){var ee=b;return function(){var w=b;b=ee;try{return V.apply(this,arguments)}finally{b=w}}}}(sd)),sd}var Qg;function Mv(){return Qg||(Qg=1,id.exports=Fv()),id.exports}var Xg;function Bv(){if(Xg)return bn;Xg=1;var e=ms(),t=Mv();function n(i){for(var s="https://reactjs.org/docs/error-decoder.html?invariant="+i,l=1;l<arguments.length;l++)s+="&args[]="+encodeURIComponent(arguments[l]);return"Minified React error #"+i+"; visit "+s+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,o={};function u(i,s){a(i,s),a(i+"Capture",s)}function a(i,s){for(o[i]=s,i=0;i<s.length;i++)r.add(s[i])}var c=!(typeof window=="undefined"||typeof window.document=="undefined"||typeof window.document.createElement=="undefined"),f=Object.prototype.hasOwnProperty,h=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,m={},E={};function b(i){return f.call(E,i)?!0:f.call(m,i)?!1:h.test(i)?E[i]=!0:(m[i]=!0,!1)}function T(i,s,l,d){if(l!==null&&l.type===0)return!1;switch(typeof s){case"function":case"symbol":return!0;case"boolean":return d?!1:l!==null?!l.acceptsBooleans:(i=i.toLowerCase().slice(0,5),i!=="data-"&&i!=="aria-");default:return!1}}function _(i,s,l,d){if(s===null||typeof s=="undefined"||T(i,s,l,d))return!0;if(d)return!1;if(l!==null)switch(l.type){case 3:return!s;case 4:return s===!1;case 5:return isNaN(s);case 6:return isNaN(s)||1>s}return!1}function S(i,s,l,d,g,y,x){this.acceptsBooleans=s===2||s===3||s===4,this.attributeName=d,this.attributeNamespace=g,this.mustUseProperty=l,this.propertyName=i,this.type=s,this.sanitizeURL=y,this.removeEmptyString=x}var C={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){C[i]=new S(i,0,!1,i,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(i){var s=i[0];C[s]=new S(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){C[i]=new S(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){C[i]=new S(i,2,!1,i,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(i){C[i]=new S(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){C[i]=new S(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){C[i]=new S(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){C[i]=new S(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){C[i]=new S(i,5,!1,i.toLowerCase(),null,!1,!1)});var k=/[\-:]([a-z])/g;function M(i){return i[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(i){var s=i.replace(k,M);C[s]=new S(s,1,!1,i,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(i){var s=i.replace(k,M);C[s]=new S(s,1,!1,i,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(i){var s=i.replace(k,M);C[s]=new S(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){C[i]=new S(i,1,!1,i.toLowerCase(),null,!1,!1)}),C.xlinkHref=new S("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){C[i]=new S(i,1,!1,i.toLowerCase(),null,!0,!0)});function D(i,s,l,d){var g=C.hasOwnProperty(s)?C[s]:null;(g!==null?g.type!==0:d||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(_(s,l,g,d)&&(l=null),d||g===null?b(s)&&(l===null?i.removeAttribute(s):i.setAttribute(s,""+l)):g.mustUseProperty?i[g.propertyName]=l===null?g.type===3?!1:"":l:(s=g.attributeName,d=g.attributeNamespace,l===null?i.removeAttribute(s):(g=g.type,l=g===3||g===4&&l===!0?"":""+l,d?i.setAttributeNS(d,s,l):i.setAttribute(s,l))))}var G=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,q=Symbol.for("react.element"),B=Symbol.for("react.portal"),te=Symbol.for("react.fragment"),Te=Symbol.for("react.strict_mode"),Se=Symbol.for("react.profiler"),H=Symbol.for("react.provider"),fe=Symbol.for("react.context"),de=Symbol.for("react.forward_ref"),ue=Symbol.for("react.suspense"),ie=Symbol.for("react.suspense_list"),ge=Symbol.for("react.memo"),we=Symbol.for("react.lazy"),ae=Symbol.for("react.offscreen"),V=Symbol.iterator;function ee(i){return i===null||typeof i!="object"?null:(i=V&&i[V]||i["@@iterator"],typeof i=="function"?i:null)}var w=Object.assign,R;function Q(i){if(R===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);R=s&&s[1]||""}return`
8
8
  `+R+i}var N=!1;function _e(i,s){if(!i||N)return"";N=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(s)if(s=function(){throw Error()},Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(s,[])}catch(Y){var d=Y}Reflect.construct(i,[],s)}else{try{s.call()}catch(Y){d=Y}i.call(s.prototype)}else{try{throw Error()}catch(Y){d=Y}i()}}catch(Y){if(Y&&d&&typeof Y.stack=="string"){for(var g=Y.stack.split(`
9
9
  `),y=d.stack.split(`
10
10
  `),x=g.length-1,O=y.length-1;1<=x&&0<=O&&g[x]!==y[O];)O--;for(;1<=x&&0<=O;x--,O--)if(g[x]!==y[O]){if(x!==1||O!==1)do if(x--,O--,0>O||g[x]!==y[O]){var L=`
11
- `+g[x].replace(" at new "," at ");return i.displayName&&L.includes("<anonymous>")&&(L=L.replace("<anonymous>",i.displayName)),L}while(1<=x&&0<=O);break}}}finally{N=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?Q(i):""}function Me(i){switch(i.tag){case 5:return Q(i.type);case 16:return Q("Lazy");case 13:return Q("Suspense");case 19:return Q("SuspenseList");case 0:case 2:case 15:return i=_e(i.type,!1),i;case 11:return i=_e(i.type.render,!1),i;case 1:return i=_e(i.type,!0),i;default:return""}}function Ie(i){if(i==null)return null;if(typeof i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case te:return"Fragment";case B:return"Portal";case Se:return"Profiler";case Te:return"StrictMode";case ue:return"Suspense";case ie:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case fe:return(i.displayName||"Context")+".Consumer";case H:return(i._context.displayName||"Context")+".Provider";case de:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case ge:return s=i.displayName||null,s!==null?s:Ie(i.type)||"Memo";case we:s=i._payload,i=i._init;try{return Ie(i(s))}catch(l){}}return null}function Ye(i){var s=i.type;switch(i.tag){case 24:return"Cache";case 9:return(s.displayName||"Context")+".Consumer";case 10:return(s._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return i=s.render,i=i.displayName||i.name||"",s.displayName||(i!==""?"ForwardRef("+i+")":"ForwardRef");case 7:return"Fragment";case 5:return s;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Ie(s);case 8:return s===Te?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function Ve(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function Je(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function xt(i){var s=Je(i)?"checked":"value",l=Object.getOwnPropertyDescriptor(i.constructor.prototype,s),d=""+i[s];if(!i.hasOwnProperty(s)&&typeof l!="undefined"&&typeof l.get=="function"&&typeof l.set=="function"){var g=l.get,y=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return g.call(this)},set:function(x){d=""+x,y.call(this,x)}}),Object.defineProperty(i,s,{enumerable:l.enumerable}),{getValue:function(){return d},setValue:function(x){d=""+x},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function be(i){i._valueTracker||(i._valueTracker=xt(i))}function He(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var l=s.getValue(),d="";return i&&(d=Je(i)?i.checked?"true":"false":i.value),i=d,i!==l?(s.setValue(i),!0):!1}function tt(i){if(i=i||(typeof document!="undefined"?document:void 0),typeof i=="undefined")return null;try{return i.activeElement||i.body}catch(s){return i.body}}function Tt(i,s){var l=s.checked;return w({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function St(i,s){var l=s.defaultValue==null?"":s.defaultValue,d=s.checked!=null?s.checked:s.defaultChecked;l=Ve(s.value!=null?s.value:l),i._wrapperState={initialChecked:d,initialValue:l,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function un(i,s){s=s.checked,s!=null&&D(i,"checked",s,!1)}function Wt(i,s){un(i,s);var l=Ve(s.value),d=s.type;if(l!=null)d==="number"?(l===0&&i.value===""||i.value!=l)&&(i.value=""+l):i.value!==""+l&&(i.value=""+l);else if(d==="submit"||d==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?Mn(i,s.type,l):s.hasOwnProperty("defaultValue")&&Mn(i,s.type,Ve(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function Rt(i,s,l){if(s.hasOwnProperty("value")||s.hasOwnProperty("defaultValue")){var d=s.type;if(!(d!=="submit"&&d!=="reset"||s.value!==void 0&&s.value!==null))return;s=""+i._wrapperState.initialValue,l||s===i.value||(i.value=s),i.defaultValue=s}l=i.name,l!==""&&(i.name=""),i.defaultChecked=!!i._wrapperState.initialChecked,l!==""&&(i.name=l)}function Mn(i,s,l){(s!=="number"||tt(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var ft=Array.isArray;function vt(i,s,l,d){if(i=i.options,s){s={};for(var g=0;g<l.length;g++)s["$"+l[g]]=!0;for(l=0;l<i.length;l++)g=s.hasOwnProperty("$"+i[l].value),i[l].selected!==g&&(i[l].selected=g),g&&d&&(i[l].defaultSelected=!0)}else{for(l=""+Ve(l),s=null,g=0;g<i.length;g++){if(i[g].value===l){i[g].selected=!0,d&&(i[g].defaultSelected=!0);return}s!==null||i[g].disabled||(s=i[g])}s!==null&&(s.selected=!0)}}function vu(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return w({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function Hl(i,s){var l=s.value;if(l==null){if(l=s.children,s=s.defaultValue,l!=null){if(s!=null)throw Error(n(92));if(ft(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:Ve(l)}}function zl(i,s){var l=Ve(s.value),d=Ve(s.defaultValue);l!=null&&(l=""+l,l!==i.value&&(i.value=l),s.defaultValue==null&&i.defaultValue!==l&&(i.defaultValue=l)),d!=null&&(i.defaultValue=""+d)}function jl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function J(i){switch(i){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Ee(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?J(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Be,We=function(i){return typeof MSApp!="undefined"&&MSApp.execUnsafeLocalFunction?function(s,l,d,g){MSApp.execUnsafeLocalFunction(function(){return i(s,l,d,g)})}:i}(function(i,s){if(i.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in i)i.innerHTML=s;else{for(Be=Be||document.createElement("div"),Be.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=Be.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function Ze(i,s){if(s){var l=i.firstChild;if(l&&l===i.lastChild&&l.nodeType===3){l.nodeValue=s;return}}i.textContent=s}var Jt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Jr=["Webkit","ms","Moz","O"];Object.keys(Jt).forEach(function(i){Jr.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),Jt[s]=Jt[i]})});function Kn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||Jt.hasOwnProperty(i)&&Jt[i]?(""+s).trim():s+"px"}function yi(i,s){i=i.style;for(var l in s)if(s.hasOwnProperty(l)){var d=l.indexOf("--")===0,g=Kn(l,s[l],d);l==="float"&&(l="cssFloat"),d?i.setProperty(l,g):i[l]=g}}var ts=w({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Zt(i,s){if(s){if(ts[i]&&(s.children!=null||s.dangerouslySetInnerHTML!=null))throw Error(n(137,i));if(s.dangerouslySetInnerHTML!=null){if(s.children!=null)throw Error(n(60));if(typeof s.dangerouslySetInnerHTML!="object"||!("__html"in s.dangerouslySetInnerHTML))throw Error(n(61))}if(s.style!=null&&typeof s.style!="object")throw Error(n(62))}}function Rr(i,s){if(i.indexOf("-")===-1)return typeof s.is=="string";switch(i){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Bn=null;function Wh(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var Gh=null,io=null,so=null;function Ab(i){if(i=Ku(i)){if(typeof Gh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=fc(s),Gh(i.stateNode,i.type,s))}}function vb(i){io?so?so.push(i):so=[i]:io=i}function kb(){if(io){var i=io,s=so;if(so=io=null,Ab(i),s)for(i=0;i<s.length;i++)Ab(s[i])}}function Nb(i,s){return i(s)}function Ob(){}var Kh=!1;function Ib(i,s,l){if(Kh)return i(s,l);Kh=!0;try{return Nb(i,s,l)}finally{Kh=!1,(io!==null||so!==null)&&(Ob(),kb())}}function ku(i,s){var l=i.stateNode;if(l===null)return null;var d=fc(l);if(d===null)return null;l=d[s];e:switch(s){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(d=!d.disabled)||(i=i.type,d=!(i==="button"||i==="input"||i==="select"||i==="textarea")),i=!d;break e;default:i=!1}if(i)return null;if(l&&typeof l!="function")throw Error(n(231,s,typeof l));return l}var Qh=!1;if(c)try{var Nu={};Object.defineProperty(Nu,"passive",{get:function(){Qh=!0}}),window.addEventListener("test",Nu,Nu),window.removeEventListener("test",Nu,Nu)}catch(i){Qh=!1}function n8(i,s,l,d,g,y,x,O,L){var Y=Array.prototype.slice.call(arguments,3);try{s.apply(l,Y)}catch(se){this.onError(se)}}var Ou=!1,$l=null,Vl=!1,Xh=null,r8={onError:function(i){Ou=!0,$l=i}};function i8(i,s,l,d,g,y,x,O,L){Ou=!1,$l=null,n8.apply(r8,arguments)}function s8(i,s,l,d,g,y,x,O,L){if(i8.apply(this,arguments),Ou){if(Ou){var Y=$l;Ou=!1,$l=null}else throw Error(n(198));Vl||(Vl=!0,Xh=Y)}}function ns(i){var s=i,l=i;if(i.alternate)for(;s.return;)s=s.return;else{i=s;do s=i,(s.flags&4098)!==0&&(l=s.return),i=s.return;while(i)}return s.tag===3?l:null}function Pb(i){if(i.tag===13){var s=i.memoizedState;if(s===null&&(i=i.alternate,i!==null&&(s=i.memoizedState)),s!==null)return s.dehydrated}return null}function Rb(i){if(ns(i)!==i)throw Error(n(188))}function o8(i){var s=i.alternate;if(!s){if(s=ns(i),s===null)throw Error(n(188));return s!==i?null:i}for(var l=i,d=s;;){var g=l.return;if(g===null)break;var y=g.alternate;if(y===null){if(d=g.return,d!==null){l=d;continue}break}if(g.child===y.child){for(y=g.child;y;){if(y===l)return Rb(g),i;if(y===d)return Rb(g),s;y=y.sibling}throw Error(n(188))}if(l.return!==d.return)l=g,d=y;else{for(var x=!1,O=g.child;O;){if(O===l){x=!0,l=g,d=y;break}if(O===d){x=!0,d=g,l=y;break}O=O.sibling}if(!x){for(O=y.child;O;){if(O===l){x=!0,l=y,d=g;break}if(O===d){x=!0,d=y,l=g;break}O=O.sibling}if(!x)throw Error(n(189))}}if(l.alternate!==d)throw Error(n(190))}if(l.tag!==3)throw Error(n(188));return l.stateNode.current===l?i:s}function Lb(i){return i=o8(i),i!==null?Db(i):null}function Db(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=Db(i);if(s!==null)return s;i=i.sibling}return null}var Fb=t.unstable_scheduleCallback,Mb=t.unstable_cancelCallback,u8=t.unstable_shouldYield,a8=t.unstable_requestPaint,Lt=t.unstable_now,l8=t.unstable_getCurrentPriorityLevel,Jh=t.unstable_ImmediatePriority,Bb=t.unstable_UserBlockingPriority,ql=t.unstable_NormalPriority,c8=t.unstable_LowPriority,Ub=t.unstable_IdlePriority,Yl=null,Lr=null;function f8(i){if(Lr&&typeof Lr.onCommitFiberRoot=="function")try{Lr.onCommitFiberRoot(Yl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var hr=Math.clz32?Math.clz32:p8,d8=Math.log,h8=Math.LN2;function p8(i){return i>>>=0,i===0?32:31-(d8(i)/h8|0)|0}var Wl=64,Gl=4194304;function Iu(i){switch(i&-i){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return i&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return i&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return i}}function Kl(i,s){var l=i.pendingLanes;if(l===0)return 0;var d=0,g=i.suspendedLanes,y=i.pingedLanes,x=l&268435455;if(x!==0){var O=x&~g;O!==0?d=Iu(O):(y&=x,y!==0&&(d=Iu(y)))}else x=l&~g,x!==0?d=Iu(x):y!==0&&(d=Iu(y));if(d===0)return 0;if(s!==0&&s!==d&&(s&g)===0&&(g=d&-d,y=s&-s,g>=y||g===16&&(y&4194240)!==0))return s;if((d&4)!==0&&(d|=l&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=d;0<s;)l=31-hr(s),g=1<<l,d|=i[l],s&=~g;return d}function m8(i,s){switch(i){case 1:case 2:case 4:return s+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return s+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function g8(i,s){for(var l=i.suspendedLanes,d=i.pingedLanes,g=i.expirationTimes,y=i.pendingLanes;0<y;){var x=31-hr(y),O=1<<x,L=g[x];L===-1?((O&l)===0||(O&d)!==0)&&(g[x]=m8(O,s)):L<=s&&(i.expiredLanes|=O),y&=~O}}function Zh(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function Hb(){var i=Wl;return Wl<<=1,(Wl&4194240)===0&&(Wl=64),i}function ep(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function Pu(i,s,l){i.pendingLanes|=s,s!==536870912&&(i.suspendedLanes=0,i.pingedLanes=0),i=i.eventTimes,s=31-hr(s),i[s]=l}function E8(i,s){var l=i.pendingLanes&~s;i.pendingLanes=s,i.suspendedLanes=0,i.pingedLanes=0,i.expiredLanes&=s,i.mutableReadLanes&=s,i.entangledLanes&=s,s=i.entanglements;var d=i.eventTimes;for(i=i.expirationTimes;0<l;){var g=31-hr(l),y=1<<g;s[g]=0,d[g]=-1,i[g]=-1,l&=~y}}function tp(i,s){var l=i.entangledLanes|=s;for(i=i.entanglements;l;){var d=31-hr(l),g=1<<d;g&s|i[d]&s&&(i[d]|=s),l&=~g}}var st=0;function zb(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var jb,np,$b,Vb,qb,rp=!1,Ql=[],Ti=null,bi=null,_i=null,Ru=new Map,Lu=new Map,xi=[],y8="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Yb(i,s){switch(i){case"focusin":case"focusout":Ti=null;break;case"dragenter":case"dragleave":bi=null;break;case"mouseover":case"mouseout":_i=null;break;case"pointerover":case"pointerout":Ru.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":Lu.delete(s.pointerId)}}function Du(i,s,l,d,g,y){return i===null||i.nativeEvent!==y?(i={blockedOn:s,domEventName:l,eventSystemFlags:d,nativeEvent:y,targetContainers:[g]},s!==null&&(s=Ku(s),s!==null&&np(s)),i):(i.eventSystemFlags|=d,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function T8(i,s,l,d,g){switch(s){case"focusin":return Ti=Du(Ti,i,s,l,d,g),!0;case"dragenter":return bi=Du(bi,i,s,l,d,g),!0;case"mouseover":return _i=Du(_i,i,s,l,d,g),!0;case"pointerover":var y=g.pointerId;return Ru.set(y,Du(Ru.get(y)||null,i,s,l,d,g)),!0;case"gotpointercapture":return y=g.pointerId,Lu.set(y,Du(Lu.get(y)||null,i,s,l,d,g)),!0}return!1}function Wb(i){var s=rs(i.target);if(s!==null){var l=ns(s);if(l!==null){if(s=l.tag,s===13){if(s=Pb(l),s!==null){i.blockedOn=s,qb(i.priority,function(){$b(l)});return}}else if(s===3&&l.stateNode.current.memoizedState.isDehydrated){i.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}i.blockedOn=null}function Xl(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=sp(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var d=new l.constructor(l.type,l);Bn=d,l.target.dispatchEvent(d),Bn=null}else return s=Ku(l),s!==null&&np(s),i.blockedOn=l,!1;s.shift()}return!0}function Gb(i,s,l){Xl(i)&&l.delete(s)}function b8(){rp=!1,Ti!==null&&Xl(Ti)&&(Ti=null),bi!==null&&Xl(bi)&&(bi=null),_i!==null&&Xl(_i)&&(_i=null),Ru.forEach(Gb),Lu.forEach(Gb)}function Fu(i,s){i.blockedOn===s&&(i.blockedOn=null,rp||(rp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,b8)))}function Mu(i){function s(g){return Fu(g,i)}if(0<Ql.length){Fu(Ql[0],i);for(var l=1;l<Ql.length;l++){var d=Ql[l];d.blockedOn===i&&(d.blockedOn=null)}}for(Ti!==null&&Fu(Ti,i),bi!==null&&Fu(bi,i),_i!==null&&Fu(_i,i),Ru.forEach(s),Lu.forEach(s),l=0;l<xi.length;l++)d=xi[l],d.blockedOn===i&&(d.blockedOn=null);for(;0<xi.length&&(l=xi[0],l.blockedOn===null);)Wb(l),l.blockedOn===null&&xi.shift()}var oo=G.ReactCurrentBatchConfig,Jl=!0;function _8(i,s,l,d){var g=st,y=oo.transition;oo.transition=null;try{st=1,ip(i,s,l,d)}finally{st=g,oo.transition=y}}function x8(i,s,l,d){var g=st,y=oo.transition;oo.transition=null;try{st=4,ip(i,s,l,d)}finally{st=g,oo.transition=y}}function ip(i,s,l,d){if(Jl){var g=sp(i,s,l,d);if(g===null)xp(i,s,d,Zl,l),Yb(i,d);else if(T8(g,i,s,l,d))d.stopPropagation();else if(Yb(i,d),s&4&&-1<y8.indexOf(i)){for(;g!==null;){var y=Ku(g);if(y!==null&&jb(y),y=sp(i,s,l,d),y===null&&xp(i,s,d,Zl,l),y===g)break;g=y}g!==null&&d.stopPropagation()}else xp(i,s,d,null,l)}}var Zl=null;function sp(i,s,l,d){if(Zl=null,i=Wh(d),i=rs(i),i!==null)if(s=ns(i),s===null)i=null;else if(l=s.tag,l===13){if(i=Pb(s),i!==null)return i;i=null}else if(l===3){if(s.stateNode.current.memoizedState.isDehydrated)return s.tag===3?s.stateNode.containerInfo:null;i=null}else s!==i&&(i=null);return Zl=i,null}function Kb(i){switch(i){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(l8()){case Jh:return 1;case Bb:return 4;case ql:case c8:return 16;case Ub:return 536870912;default:return 16}default:return 16}}var Si=null,op=null,ec=null;function Qb(){if(ec)return ec;var i,s=op,l=s.length,d,g="value"in Si?Si.value:Si.textContent,y=g.length;for(i=0;i<l&&s[i]===g[i];i++);var x=l-i;for(d=1;d<=x&&s[l-d]===g[y-d];d++);return ec=g.slice(i,1<d?1-d:void 0)}function tc(i){var s=i.keyCode;return"charCode"in i?(i=i.charCode,i===0&&s===13&&(i=13)):i=s,i===10&&(i=13),32<=i||i===13?i:0}function nc(){return!0}function Xb(){return!1}function Un(i){function s(l,d,g,y,x){this._reactName=l,this._targetInst=g,this.type=d,this.nativeEvent=y,this.target=x,this.currentTarget=null;for(var O in i)i.hasOwnProperty(O)&&(l=i[O],this[O]=l?l(y):y[O]);return this.isDefaultPrevented=(y.defaultPrevented!=null?y.defaultPrevented:y.returnValue===!1)?nc:Xb,this.isPropagationStopped=Xb,this}return w(s.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=nc)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=nc)},persist:function(){},isPersistent:nc}),s}var uo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},up=Un(uo),Bu=w({},uo,{view:0,detail:0}),S8=Un(Bu),ap,lp,Uu,rc=w({},Bu,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:fp,button:0,buttons:0,relatedTarget:function(i){return i.relatedTarget===void 0?i.fromElement===i.srcElement?i.toElement:i.fromElement:i.relatedTarget},movementX:function(i){return"movementX"in i?i.movementX:(i!==Uu&&(Uu&&i.type==="mousemove"?(ap=i.screenX-Uu.screenX,lp=i.screenY-Uu.screenY):lp=ap=0,Uu=i),ap)},movementY:function(i){return"movementY"in i?i.movementY:lp}}),Jb=Un(rc),w8=w({},rc,{dataTransfer:0}),C8=Un(w8),A8=w({},Bu,{relatedTarget:0}),cp=Un(A8),v8=w({},uo,{animationName:0,elapsedTime:0,pseudoElement:0}),k8=Un(v8),N8=w({},uo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),O8=Un(N8),I8=w({},uo,{data:0}),Zb=Un(I8),P8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},R8={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},L8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function D8(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=L8[i])?!!s[i]:!1}function fp(){return D8}var F8=w({},Bu,{key:function(i){if(i.key){var s=P8[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=tc(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?R8[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:fp,charCode:function(i){return i.type==="keypress"?tc(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?tc(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),M8=Un(F8),B8=w({},rc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),e_=Un(B8),U8=w({},Bu,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:fp}),H8=Un(U8),z8=w({},uo,{propertyName:0,elapsedTime:0,pseudoElement:0}),j8=Un(z8),$8=w({},rc,{deltaX:function(i){return"deltaX"in i?i.deltaX:"wheelDeltaX"in i?-i.wheelDeltaX:0},deltaY:function(i){return"deltaY"in i?i.deltaY:"wheelDeltaY"in i?-i.wheelDeltaY:"wheelDelta"in i?-i.wheelDelta:0},deltaZ:0,deltaMode:0}),V8=Un($8),q8=[9,13,27,32],dp=c&&"CompositionEvent"in window,Hu=null;c&&"documentMode"in document&&(Hu=document.documentMode);var Y8=c&&"TextEvent"in window&&!Hu,t_=c&&(!dp||Hu&&8<Hu&&11>=Hu),n_=" ",r_=!1;function i_(i,s){switch(i){case"keyup":return q8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function s_(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var ao=!1;function W8(i,s){switch(i){case"compositionend":return s_(s);case"keypress":return s.which!==32?null:(r_=!0,n_);case"textInput":return i=s.data,i===n_&&r_?null:i;default:return null}}function G8(i,s){if(ao)return i==="compositionend"||!dp&&i_(i,s)?(i=Qb(),ec=op=Si=null,ao=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return t_&&s.locale!=="ko"?null:s.data;default:return null}}var K8={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function o_(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!K8[i.type]:s==="textarea"}function u_(i,s,l,d){vb(d),s=ac(s,"onChange"),0<s.length&&(l=new up("onChange","change",null,l,d),i.push({event:l,listeners:s}))}var zu=null,ju=null;function Q8(i){C_(i,0)}function ic(i){var s=po(i);if(He(s))return i}function X8(i,s){if(i==="change")return s}var a_=!1;if(c){var hp;if(c){var pp="oninput"in document;if(!pp){var l_=document.createElement("div");l_.setAttribute("oninput","return;"),pp=typeof l_.oninput=="function"}hp=pp}else hp=!1;a_=hp&&(!document.documentMode||9<document.documentMode)}function c_(){zu&&(zu.detachEvent("onpropertychange",f_),ju=zu=null)}function f_(i){if(i.propertyName==="value"&&ic(ju)){var s=[];u_(s,ju,i,Wh(i)),Ib(Q8,s)}}function J8(i,s,l){i==="focusin"?(c_(),zu=s,ju=l,zu.attachEvent("onpropertychange",f_)):i==="focusout"&&c_()}function Z8(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return ic(ju)}function eF(i,s){if(i==="click")return ic(s)}function tF(i,s){if(i==="input"||i==="change")return ic(s)}function nF(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var pr=typeof Object.is=="function"?Object.is:nF;function $u(i,s){if(pr(i,s))return!0;if(typeof i!="object"||i===null||typeof s!="object"||s===null)return!1;var l=Object.keys(i),d=Object.keys(s);if(l.length!==d.length)return!1;for(d=0;d<l.length;d++){var g=l[d];if(!f.call(s,g)||!pr(i[g],s[g]))return!1}return!0}function d_(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function h_(i,s){var l=d_(i);i=0;for(var d;l;){if(l.nodeType===3){if(d=i+l.textContent.length,i<=s&&d>=s)return{node:l,offset:s-i};i=d}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=d_(l)}}function p_(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?p_(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function m_(){for(var i=window,s=tt();s instanceof i.HTMLIFrameElement;){try{var l=typeof s.contentWindow.location.href=="string"}catch(d){l=!1}if(l)i=s.contentWindow;else break;s=tt(i.document)}return s}function mp(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s&&(s==="input"&&(i.type==="text"||i.type==="search"||i.type==="tel"||i.type==="url"||i.type==="password")||s==="textarea"||i.contentEditable==="true")}function rF(i){var s=m_(),l=i.focusedElem,d=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&p_(l.ownerDocument.documentElement,l)){if(d!==null&&mp(l)){if(s=d.start,i=d.end,i===void 0&&(i=s),"selectionStart"in l)l.selectionStart=s,l.selectionEnd=Math.min(i,l.value.length);else if(i=(s=l.ownerDocument||document)&&s.defaultView||window,i.getSelection){i=i.getSelection();var g=l.textContent.length,y=Math.min(d.start,g);d=d.end===void 0?y:Math.min(d.end,g),!i.extend&&y>d&&(g=d,d=y,y=g),g=h_(l,y);var x=h_(l,d);g&&x&&(i.rangeCount!==1||i.anchorNode!==g.node||i.anchorOffset!==g.offset||i.focusNode!==x.node||i.focusOffset!==x.offset)&&(s=s.createRange(),s.setStart(g.node,g.offset),i.removeAllRanges(),y>d?(i.addRange(s),i.extend(x.node,x.offset)):(s.setEnd(x.node,x.offset),i.addRange(s)))}}for(s=[],i=l;i=i.parentNode;)i.nodeType===1&&s.push({element:i,left:i.scrollLeft,top:i.scrollTop});for(typeof l.focus=="function"&&l.focus(),l=0;l<s.length;l++)i=s[l],i.element.scrollLeft=i.left,i.element.scrollTop=i.top}}var iF=c&&"documentMode"in document&&11>=document.documentMode,lo=null,gp=null,Vu=null,Ep=!1;function g_(i,s,l){var d=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Ep||lo==null||lo!==tt(d)||(d=lo,"selectionStart"in d&&mp(d)?d={start:d.selectionStart,end:d.selectionEnd}:(d=(d.ownerDocument&&d.ownerDocument.defaultView||window).getSelection(),d={anchorNode:d.anchorNode,anchorOffset:d.anchorOffset,focusNode:d.focusNode,focusOffset:d.focusOffset}),Vu&&$u(Vu,d)||(Vu=d,d=ac(gp,"onSelect"),0<d.length&&(s=new up("onSelect","select",null,s,l),i.push({event:s,listeners:d}),s.target=lo)))}function sc(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var co={animationend:sc("Animation","AnimationEnd"),animationiteration:sc("Animation","AnimationIteration"),animationstart:sc("Animation","AnimationStart"),transitionend:sc("Transition","TransitionEnd")},yp={},E_={};c&&(E_=document.createElement("div").style,"AnimationEvent"in window||(delete co.animationend.animation,delete co.animationiteration.animation,delete co.animationstart.animation),"TransitionEvent"in window||delete co.transitionend.transition);function oc(i){if(yp[i])return yp[i];if(!co[i])return i;var s=co[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in E_)return yp[i]=s[l];return i}var y_=oc("animationend"),T_=oc("animationiteration"),b_=oc("animationstart"),__=oc("transitionend"),x_=new Map,S_="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function wi(i,s){x_.set(i,s),u(s,[i])}for(var Tp=0;Tp<S_.length;Tp++){var bp=S_[Tp],sF=bp.toLowerCase(),oF=bp[0].toUpperCase()+bp.slice(1);wi(sF,"on"+oF)}wi(y_,"onAnimationEnd"),wi(T_,"onAnimationIteration"),wi(b_,"onAnimationStart"),wi("dblclick","onDoubleClick"),wi("focusin","onFocus"),wi("focusout","onBlur"),wi(__,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),u("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),u("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),u("onBeforeInput",["compositionend","keypress","textInput","paste"]),u("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var qu="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),uF=new Set("cancel close invalid load scroll toggle".split(" ").concat(qu));function w_(i,s,l){var d=i.type||"unknown-event";i.currentTarget=l,s8(d,s,void 0,i),i.currentTarget=null}function C_(i,s){s=(s&4)!==0;for(var l=0;l<i.length;l++){var d=i[l],g=d.event;d=d.listeners;e:{var y=void 0;if(s)for(var x=d.length-1;0<=x;x--){var O=d[x],L=O.instance,Y=O.currentTarget;if(O=O.listener,L!==y&&g.isPropagationStopped())break e;w_(g,O,Y),y=L}else for(x=0;x<d.length;x++){if(O=d[x],L=O.instance,Y=O.currentTarget,O=O.listener,L!==y&&g.isPropagationStopped())break e;w_(g,O,Y),y=L}}}if(Vl)throw i=Xh,Vl=!1,Xh=null,i}function dt(i,s){var l=s[kp];l===void 0&&(l=s[kp]=new Set);var d=i+"__bubble";l.has(d)||(A_(s,i,2,!1),l.add(d))}function _p(i,s,l){var d=0;s&&(d|=4),A_(l,i,d,s)}var uc="_reactListening"+Math.random().toString(36).slice(2);function Yu(i){if(!i[uc]){i[uc]=!0,r.forEach(function(l){l!=="selectionchange"&&(uF.has(l)||_p(l,!1,i),_p(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[uc]||(s[uc]=!0,_p("selectionchange",!1,s))}}function A_(i,s,l,d){switch(Kb(s)){case 1:var g=_8;break;case 4:g=x8;break;default:g=ip}l=g.bind(null,s,l,i),g=void 0,!Qh||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(g=!0),d?g!==void 0?i.addEventListener(s,l,{capture:!0,passive:g}):i.addEventListener(s,l,!0):g!==void 0?i.addEventListener(s,l,{passive:g}):i.addEventListener(s,l,!1)}function xp(i,s,l,d,g){var y=d;if((s&1)===0&&(s&2)===0&&d!==null)e:for(;;){if(d===null)return;var x=d.tag;if(x===3||x===4){var O=d.stateNode.containerInfo;if(O===g||O.nodeType===8&&O.parentNode===g)break;if(x===4)for(x=d.return;x!==null;){var L=x.tag;if((L===3||L===4)&&(L=x.stateNode.containerInfo,L===g||L.nodeType===8&&L.parentNode===g))return;x=x.return}for(;O!==null;){if(x=rs(O),x===null)return;if(L=x.tag,L===5||L===6){d=y=x;continue e}O=O.parentNode}}d=d.return}Ib(function(){var Y=y,se=Wh(l),ce=[];e:{var ne=x_.get(i);if(ne!==void 0){var xe=up,Ae=i;switch(i){case"keypress":if(tc(l)===0)break e;case"keydown":case"keyup":xe=M8;break;case"focusin":Ae="focus",xe=cp;break;case"focusout":Ae="blur",xe=cp;break;case"beforeblur":case"afterblur":xe=cp;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":xe=Jb;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":xe=C8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":xe=H8;break;case y_:case T_:case b_:xe=k8;break;case __:xe=j8;break;case"scroll":xe=S8;break;case"wheel":xe=V8;break;case"copy":case"cut":case"paste":xe=O8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":xe=e_}var ve=(s&4)!==0,Dt=!ve&&i==="scroll",z=ve?ne!==null?ne+"Capture":null:ne;ve=[];for(var F=Y,$;F!==null;){$=F;var me=$.stateNode;if($.tag===5&&me!==null&&($=me,z!==null&&(me=ku(F,z),me!=null&&ve.push(Wu(F,me,$)))),Dt)break;F=F.return}0<ve.length&&(ne=new xe(ne,Ae,null,l,se),ce.push({event:ne,listeners:ve}))}}if((s&7)===0){e:{if(ne=i==="mouseover"||i==="pointerover",xe=i==="mouseout"||i==="pointerout",ne&&l!==Bn&&(Ae=l.relatedTarget||l.fromElement)&&(rs(Ae)||Ae[Zr]))break e;if((xe||ne)&&(ne=se.window===se?se:(ne=se.ownerDocument)?ne.defaultView||ne.parentWindow:window,xe?(Ae=l.relatedTarget||l.toElement,xe=Y,Ae=Ae?rs(Ae):null,Ae!==null&&(Dt=ns(Ae),Ae!==Dt||Ae.tag!==5&&Ae.tag!==6)&&(Ae=null)):(xe=null,Ae=Y),xe!==Ae)){if(ve=Jb,me="onMouseLeave",z="onMouseEnter",F="mouse",(i==="pointerout"||i==="pointerover")&&(ve=e_,me="onPointerLeave",z="onPointerEnter",F="pointer"),Dt=xe==null?ne:po(xe),$=Ae==null?ne:po(Ae),ne=new ve(me,F+"leave",xe,l,se),ne.target=Dt,ne.relatedTarget=$,me=null,rs(se)===Y&&(ve=new ve(z,F+"enter",Ae,l,se),ve.target=$,ve.relatedTarget=Dt,me=ve),Dt=me,xe&&Ae)t:{for(ve=xe,z=Ae,F=0,$=ve;$;$=fo($))F++;for($=0,me=z;me;me=fo(me))$++;for(;0<F-$;)ve=fo(ve),F--;for(;0<$-F;)z=fo(z),$--;for(;F--;){if(ve===z||z!==null&&ve===z.alternate)break t;ve=fo(ve),z=fo(z)}ve=null}else ve=null;xe!==null&&v_(ce,ne,xe,ve,!1),Ae!==null&&Dt!==null&&v_(ce,Dt,Ae,ve,!0)}}e:{if(ne=Y?po(Y):window,xe=ne.nodeName&&ne.nodeName.toLowerCase(),xe==="select"||xe==="input"&&ne.type==="file")var Ne=X8;else if(o_(ne))if(a_)Ne=tF;else{Ne=Z8;var Le=J8}else(xe=ne.nodeName)&&xe.toLowerCase()==="input"&&(ne.type==="checkbox"||ne.type==="radio")&&(Ne=eF);if(Ne&&(Ne=Ne(i,Y))){u_(ce,Ne,l,se);break e}Le&&Le(i,ne,Y),i==="focusout"&&(Le=ne._wrapperState)&&Le.controlled&&ne.type==="number"&&Mn(ne,"number",ne.value)}switch(Le=Y?po(Y):window,i){case"focusin":(o_(Le)||Le.contentEditable==="true")&&(lo=Le,gp=Y,Vu=null);break;case"focusout":Vu=gp=lo=null;break;case"mousedown":Ep=!0;break;case"contextmenu":case"mouseup":case"dragend":Ep=!1,g_(ce,l,se);break;case"selectionchange":if(iF)break;case"keydown":case"keyup":g_(ce,l,se)}var De;if(dp)e:{switch(i){case"compositionstart":var Ue="onCompositionStart";break e;case"compositionend":Ue="onCompositionEnd";break e;case"compositionupdate":Ue="onCompositionUpdate";break e}Ue=void 0}else ao?i_(i,l)&&(Ue="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(Ue="onCompositionStart");Ue&&(t_&&l.locale!=="ko"&&(ao||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&ao&&(De=Qb()):(Si=se,op="value"in Si?Si.value:Si.textContent,ao=!0)),Le=ac(Y,Ue),0<Le.length&&(Ue=new Zb(Ue,i,null,l,se),ce.push({event:Ue,listeners:Le}),De?Ue.data=De:(De=s_(l),De!==null&&(Ue.data=De)))),(De=Y8?W8(i,l):G8(i,l))&&(Y=ac(Y,"onBeforeInput"),0<Y.length&&(se=new Zb("onBeforeInput","beforeinput",null,l,se),ce.push({event:se,listeners:Y}),se.data=De))}C_(ce,s)})}function Wu(i,s,l){return{instance:i,listener:s,currentTarget:l}}function ac(i,s){for(var l=s+"Capture",d=[];i!==null;){var g=i,y=g.stateNode;g.tag===5&&y!==null&&(g=y,y=ku(i,l),y!=null&&d.unshift(Wu(i,y,g)),y=ku(i,s),y!=null&&d.push(Wu(i,y,g))),i=i.return}return d}function fo(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function v_(i,s,l,d,g){for(var y=s._reactName,x=[];l!==null&&l!==d;){var O=l,L=O.alternate,Y=O.stateNode;if(L!==null&&L===d)break;O.tag===5&&Y!==null&&(O=Y,g?(L=ku(l,y),L!=null&&x.unshift(Wu(l,L,O))):g||(L=ku(l,y),L!=null&&x.push(Wu(l,L,O)))),l=l.return}x.length!==0&&i.push({event:s,listeners:x})}var aF=/\r\n?/g,lF=/\u0000|\uFFFD/g;function k_(i){return(typeof i=="string"?i:""+i).replace(aF,`
12
- `).replace(lF,"")}function lc(i,s,l){if(s=k_(s),k_(i)!==s&&l)throw Error(n(425))}function cc(){}var Sp=null,wp=null;function Cp(i,s){return i==="textarea"||i==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}var Ap=typeof setTimeout=="function"?setTimeout:void 0,cF=typeof clearTimeout=="function"?clearTimeout:void 0,N_=typeof Promise=="function"?Promise:void 0,fF=typeof queueMicrotask=="function"?queueMicrotask:typeof N_!="undefined"?function(i){return N_.resolve(null).then(i).catch(dF)}:Ap;function dF(i){setTimeout(function(){throw i})}function vp(i,s){var l=s,d=0;do{var g=l.nextSibling;if(i.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(d===0){i.removeChild(g),Mu(s);return}d--}else l!=="$"&&l!=="$?"&&l!=="$!"||d++;l=g}while(l);Mu(s)}function Ci(i){for(;i!=null;i=i.nextSibling){var s=i.nodeType;if(s===1||s===3)break;if(s===8){if(s=i.data,s==="$"||s==="$!"||s==="$?")break;if(s==="/$")return null}}return i}function O_(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var l=i.data;if(l==="$"||l==="$!"||l==="$?"){if(s===0)return i;s--}else l==="/$"&&s++}i=i.previousSibling}return null}var ho=Math.random().toString(36).slice(2),Dr="__reactFiber$"+ho,Gu="__reactProps$"+ho,Zr="__reactContainer$"+ho,kp="__reactEvents$"+ho,hF="__reactListeners$"+ho,pF="__reactHandles$"+ho;function rs(i){var s=i[Dr];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Zr]||l[Dr]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=O_(i);i!==null;){if(l=i[Dr])return l;i=O_(i)}return s}i=l,l=i.parentNode}return null}function Ku(i){return i=i[Dr]||i[Zr],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function po(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function fc(i){return i[Gu]||null}var Np=[],mo=-1;function Ai(i){return{current:i}}function ht(i){0>mo||(i.current=Np[mo],Np[mo]=null,mo--)}function ct(i,s){mo++,Np[mo]=i.current,i.current=s}var vi={},an=Ai(vi),An=Ai(!1),is=vi;function go(i,s){var l=i.type.contextTypes;if(!l)return vi;var d=i.stateNode;if(d&&d.__reactInternalMemoizedUnmaskedChildContext===s)return d.__reactInternalMemoizedMaskedChildContext;var g={},y;for(y in l)g[y]=s[y];return d&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function vn(i){return i=i.childContextTypes,i!=null}function dc(){ht(An),ht(an)}function I_(i,s,l){if(an.current!==vi)throw Error(n(168));ct(an,s),ct(An,l)}function P_(i,s,l){var d=i.stateNode;if(s=s.childContextTypes,typeof d.getChildContext!="function")return l;d=d.getChildContext();for(var g in d)if(!(g in s))throw Error(n(108,Ye(i)||"Unknown",g));return w({},l,d)}function hc(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||vi,is=an.current,ct(an,i),ct(An,An.current),!0}function R_(i,s,l){var d=i.stateNode;if(!d)throw Error(n(169));l?(i=P_(i,s,is),d.__reactInternalMemoizedMergedChildContext=i,ht(An),ht(an),ct(an,i)):ht(An),ct(An,l)}var ei=null,pc=!1,Op=!1;function L_(i){ei===null?ei=[i]:ei.push(i)}function mF(i){pc=!0,L_(i)}function ki(){if(!Op&&ei!==null){Op=!0;var i=0,s=st;try{var l=ei;for(st=1;i<l.length;i++){var d=l[i];do d=d(!0);while(d!==null)}ei=null,pc=!1}catch(g){throw ei!==null&&(ei=ei.slice(i+1)),Fb(Jh,ki),g}finally{st=s,Op=!1}}return null}var Eo=[],yo=0,mc=null,gc=0,Qn=[],Xn=0,ss=null,ti=1,ni="";function os(i,s){Eo[yo++]=gc,Eo[yo++]=mc,mc=i,gc=s}function D_(i,s,l){Qn[Xn++]=ti,Qn[Xn++]=ni,Qn[Xn++]=ss,ss=i;var d=ti;i=ni;var g=32-hr(d)-1;d&=~(1<<g),l+=1;var y=32-hr(s)+g;if(30<y){var x=g-g%5;y=(d&(1<<x)-1).toString(32),d>>=x,g-=x,ti=1<<32-hr(s)+g|l<<g|d,ni=y+i}else ti=1<<y|l<<g|d,ni=i}function Ip(i){i.return!==null&&(os(i,1),D_(i,1,0))}function Pp(i){for(;i===mc;)mc=Eo[--yo],Eo[yo]=null,gc=Eo[--yo],Eo[yo]=null;for(;i===ss;)ss=Qn[--Xn],Qn[Xn]=null,ni=Qn[--Xn],Qn[Xn]=null,ti=Qn[--Xn],Qn[Xn]=null}var Hn=null,zn=null,bt=!1,mr=null;function F_(i,s){var l=tr(5,null,null,0);l.elementType="DELETED",l.stateNode=s,l.return=i,s=i.deletions,s===null?(i.deletions=[l],i.flags|=16):s.push(l)}function M_(i,s){switch(i.tag){case 5:var l=i.type;return s=s.nodeType!==1||l.toLowerCase()!==s.nodeName.toLowerCase()?null:s,s!==null?(i.stateNode=s,Hn=i,zn=Ci(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Hn=i,zn=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(l=ss!==null?{id:ti,overflow:ni}:null,i.memoizedState={dehydrated:s,treeContext:l,retryLane:1073741824},l=tr(18,null,null,0),l.stateNode=s,l.return=i,i.child=l,Hn=i,zn=null,!0):!1;default:return!1}}function Rp(i){return(i.mode&1)!==0&&(i.flags&128)===0}function Lp(i){if(bt){var s=zn;if(s){var l=s;if(!M_(i,s)){if(Rp(i))throw Error(n(418));s=Ci(l.nextSibling);var d=Hn;s&&M_(i,s)?F_(d,l):(i.flags=i.flags&-4097|2,bt=!1,Hn=i)}}else{if(Rp(i))throw Error(n(418));i.flags=i.flags&-4097|2,bt=!1,Hn=i}}}function B_(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Hn=i}function Ec(i){if(i!==Hn)return!1;if(!bt)return B_(i),bt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!Cp(i.type,i.memoizedProps)),s&&(s=zn)){if(Rp(i))throw U_(),Error(n(418));for(;s;)F_(i,s),s=Ci(s.nextSibling)}if(B_(i),i.tag===13){if(i=i.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(n(317));e:{for(i=i.nextSibling,s=0;i;){if(i.nodeType===8){var l=i.data;if(l==="/$"){if(s===0){zn=Ci(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}zn=null}}else zn=Hn?Ci(i.stateNode.nextSibling):null;return!0}function U_(){for(var i=zn;i;)i=Ci(i.nextSibling)}function To(){zn=Hn=null,bt=!1}function Dp(i){mr===null?mr=[i]:mr.push(i)}var gF=G.ReactCurrentBatchConfig;function Qu(i,s,l){if(i=l.ref,i!==null&&typeof i!="function"&&typeof i!="object"){if(l._owner){if(l=l._owner,l){if(l.tag!==1)throw Error(n(309));var d=l.stateNode}if(!d)throw Error(n(147,i));var g=d,y=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===y?s.ref:(s=function(x){var O=g.refs;x===null?delete O[y]:O[y]=x},s._stringRef=y,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function yc(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function H_(i){var s=i._init;return s(i._payload)}function z_(i){function s(z,F){if(i){var $=z.deletions;$===null?(z.deletions=[F],z.flags|=16):$.push(F)}}function l(z,F){if(!i)return null;for(;F!==null;)s(z,F),F=F.sibling;return null}function d(z,F){for(z=new Map;F!==null;)F.key!==null?z.set(F.key,F):z.set(F.index,F),F=F.sibling;return z}function g(z,F){return z=Fi(z,F),z.index=0,z.sibling=null,z}function y(z,F,$){return z.index=$,i?($=z.alternate,$!==null?($=$.index,$<F?(z.flags|=2,F):$):(z.flags|=2,F)):(z.flags|=1048576,F)}function x(z){return i&&z.alternate===null&&(z.flags|=2),z}function O(z,F,$,me){return F===null||F.tag!==6?(F=Am($,z.mode,me),F.return=z,F):(F=g(F,$),F.return=z,F)}function L(z,F,$,me){var Ne=$.type;return Ne===te?se(z,F,$.props.children,me,$.key):F!==null&&(F.elementType===Ne||typeof Ne=="object"&&Ne!==null&&Ne.$$typeof===we&&H_(Ne)===F.type)?(me=g(F,$.props),me.ref=Qu(z,F,$),me.return=z,me):(me=jc($.type,$.key,$.props,null,z.mode,me),me.ref=Qu(z,F,$),me.return=z,me)}function Y(z,F,$,me){return F===null||F.tag!==4||F.stateNode.containerInfo!==$.containerInfo||F.stateNode.implementation!==$.implementation?(F=vm($,z.mode,me),F.return=z,F):(F=g(F,$.children||[]),F.return=z,F)}function se(z,F,$,me,Ne){return F===null||F.tag!==7?(F=ps($,z.mode,me,Ne),F.return=z,F):(F=g(F,$),F.return=z,F)}function ce(z,F,$){if(typeof F=="string"&&F!==""||typeof F=="number")return F=Am(""+F,z.mode,$),F.return=z,F;if(typeof F=="object"&&F!==null){switch(F.$$typeof){case q:return $=jc(F.type,F.key,F.props,null,z.mode,$),$.ref=Qu(z,null,F),$.return=z,$;case B:return F=vm(F,z.mode,$),F.return=z,F;case we:var me=F._init;return ce(z,me(F._payload),$)}if(ft(F)||ee(F))return F=ps(F,z.mode,$,null),F.return=z,F;yc(z,F)}return null}function ne(z,F,$,me){var Ne=F!==null?F.key:null;if(typeof $=="string"&&$!==""||typeof $=="number")return Ne!==null?null:O(z,F,""+$,me);if(typeof $=="object"&&$!==null){switch($.$$typeof){case q:return $.key===Ne?L(z,F,$,me):null;case B:return $.key===Ne?Y(z,F,$,me):null;case we:return Ne=$._init,ne(z,F,Ne($._payload),me)}if(ft($)||ee($))return Ne!==null?null:se(z,F,$,me,null);yc(z,$)}return null}function xe(z,F,$,me,Ne){if(typeof me=="string"&&me!==""||typeof me=="number")return z=z.get($)||null,O(F,z,""+me,Ne);if(typeof me=="object"&&me!==null){switch(me.$$typeof){case q:return z=z.get(me.key===null?$:me.key)||null,L(F,z,me,Ne);case B:return z=z.get(me.key===null?$:me.key)||null,Y(F,z,me,Ne);case we:var Le=me._init;return xe(z,F,$,Le(me._payload),Ne)}if(ft(me)||ee(me))return z=z.get($)||null,se(F,z,me,Ne,null);yc(F,me)}return null}function Ae(z,F,$,me){for(var Ne=null,Le=null,De=F,Ue=F=0,Qt=null;De!==null&&Ue<$.length;Ue++){De.index>Ue?(Qt=De,De=null):Qt=De.sibling;var nt=ne(z,De,$[Ue],me);if(nt===null){De===null&&(De=Qt);break}i&&De&&nt.alternate===null&&s(z,De),F=y(nt,F,Ue),Le===null?Ne=nt:Le.sibling=nt,Le=nt,De=Qt}if(Ue===$.length)return l(z,De),bt&&os(z,Ue),Ne;if(De===null){for(;Ue<$.length;Ue++)De=ce(z,$[Ue],me),De!==null&&(F=y(De,F,Ue),Le===null?Ne=De:Le.sibling=De,Le=De);return bt&&os(z,Ue),Ne}for(De=d(z,De);Ue<$.length;Ue++)Qt=xe(De,z,Ue,$[Ue],me),Qt!==null&&(i&&Qt.alternate!==null&&De.delete(Qt.key===null?Ue:Qt.key),F=y(Qt,F,Ue),Le===null?Ne=Qt:Le.sibling=Qt,Le=Qt);return i&&De.forEach(function(Mi){return s(z,Mi)}),bt&&os(z,Ue),Ne}function ve(z,F,$,me){var Ne=ee($);if(typeof Ne!="function")throw Error(n(150));if($=Ne.call($),$==null)throw Error(n(151));for(var Le=Ne=null,De=F,Ue=F=0,Qt=null,nt=$.next();De!==null&&!nt.done;Ue++,nt=$.next()){De.index>Ue?(Qt=De,De=null):Qt=De.sibling;var Mi=ne(z,De,nt.value,me);if(Mi===null){De===null&&(De=Qt);break}i&&De&&Mi.alternate===null&&s(z,De),F=y(Mi,F,Ue),Le===null?Ne=Mi:Le.sibling=Mi,Le=Mi,De=Qt}if(nt.done)return l(z,De),bt&&os(z,Ue),Ne;if(De===null){for(;!nt.done;Ue++,nt=$.next())nt=ce(z,nt.value,me),nt!==null&&(F=y(nt,F,Ue),Le===null?Ne=nt:Le.sibling=nt,Le=nt);return bt&&os(z,Ue),Ne}for(De=d(z,De);!nt.done;Ue++,nt=$.next())nt=xe(De,z,Ue,nt.value,me),nt!==null&&(i&&nt.alternate!==null&&De.delete(nt.key===null?Ue:nt.key),F=y(nt,F,Ue),Le===null?Ne=nt:Le.sibling=nt,Le=nt);return i&&De.forEach(function(KF){return s(z,KF)}),bt&&os(z,Ue),Ne}function Dt(z,F,$,me){if(typeof $=="object"&&$!==null&&$.type===te&&$.key===null&&($=$.props.children),typeof $=="object"&&$!==null){switch($.$$typeof){case q:e:{for(var Ne=$.key,Le=F;Le!==null;){if(Le.key===Ne){if(Ne=$.type,Ne===te){if(Le.tag===7){l(z,Le.sibling),F=g(Le,$.props.children),F.return=z,z=F;break e}}else if(Le.elementType===Ne||typeof Ne=="object"&&Ne!==null&&Ne.$$typeof===we&&H_(Ne)===Le.type){l(z,Le.sibling),F=g(Le,$.props),F.ref=Qu(z,Le,$),F.return=z,z=F;break e}l(z,Le);break}else s(z,Le);Le=Le.sibling}$.type===te?(F=ps($.props.children,z.mode,me,$.key),F.return=z,z=F):(me=jc($.type,$.key,$.props,null,z.mode,me),me.ref=Qu(z,F,$),me.return=z,z=me)}return x(z);case B:e:{for(Le=$.key;F!==null;){if(F.key===Le)if(F.tag===4&&F.stateNode.containerInfo===$.containerInfo&&F.stateNode.implementation===$.implementation){l(z,F.sibling),F=g(F,$.children||[]),F.return=z,z=F;break e}else{l(z,F);break}else s(z,F);F=F.sibling}F=vm($,z.mode,me),F.return=z,z=F}return x(z);case we:return Le=$._init,Dt(z,F,Le($._payload),me)}if(ft($))return Ae(z,F,$,me);if(ee($))return ve(z,F,$,me);yc(z,$)}return typeof $=="string"&&$!==""||typeof $=="number"?($=""+$,F!==null&&F.tag===6?(l(z,F.sibling),F=g(F,$),F.return=z,z=F):(l(z,F),F=Am($,z.mode,me),F.return=z,z=F),x(z)):l(z,F)}return Dt}var bo=z_(!0),j_=z_(!1),Tc=Ai(null),bc=null,_o=null,Fp=null;function Mp(){Fp=_o=bc=null}function Bp(i){var s=Tc.current;ht(Tc),i._currentValue=s}function Up(i,s,l){for(;i!==null;){var d=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,d!==null&&(d.childLanes|=s)):d!==null&&(d.childLanes&s)!==s&&(d.childLanes|=s),i===l)break;i=i.return}}function xo(i,s){bc=i,Fp=_o=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(kn=!0),i.firstContext=null)}function Jn(i){var s=i._currentValue;if(Fp!==i)if(i={context:i,memoizedValue:s,next:null},_o===null){if(bc===null)throw Error(n(308));_o=i,bc.dependencies={lanes:0,firstContext:i}}else _o=_o.next=i;return s}var us=null;function Hp(i){us===null?us=[i]:us.push(i)}function $_(i,s,l,d){var g=s.interleaved;return g===null?(l.next=l,Hp(s)):(l.next=g.next,g.next=l),s.interleaved=l,ri(i,d)}function ri(i,s){i.lanes|=s;var l=i.alternate;for(l!==null&&(l.lanes|=s),l=i,i=i.return;i!==null;)i.childLanes|=s,l=i.alternate,l!==null&&(l.childLanes|=s),l=i,i=i.return;return l.tag===3?l.stateNode:null}var Ni=!1;function zp(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function V_(i,s){i=i.updateQueue,s.updateQueue===i&&(s.updateQueue={baseState:i.baseState,firstBaseUpdate:i.firstBaseUpdate,lastBaseUpdate:i.lastBaseUpdate,shared:i.shared,effects:i.effects})}function ii(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function Oi(i,s,l){var d=i.updateQueue;if(d===null)return null;if(d=d.shared,(et&2)!==0){var g=d.pending;return g===null?s.next=s:(s.next=g.next,g.next=s),d.pending=s,ri(i,l)}return g=d.interleaved,g===null?(s.next=s,Hp(d)):(s.next=g.next,g.next=s),d.interleaved=s,ri(i,l)}function _c(i,s,l){if(s=s.updateQueue,s!==null&&(s=s.shared,(l&4194240)!==0)){var d=s.lanes;d&=i.pendingLanes,l|=d,s.lanes=l,tp(i,l)}}function q_(i,s){var l=i.updateQueue,d=i.alternate;if(d!==null&&(d=d.updateQueue,l===d)){var g=null,y=null;if(l=l.firstBaseUpdate,l!==null){do{var x={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};y===null?g=y=x:y=y.next=x,l=l.next}while(l!==null);y===null?g=y=s:y=y.next=s}else g=y=s;l={baseState:d.baseState,firstBaseUpdate:g,lastBaseUpdate:y,shared:d.shared,effects:d.effects},i.updateQueue=l;return}i=l.lastBaseUpdate,i===null?l.firstBaseUpdate=s:i.next=s,l.lastBaseUpdate=s}function xc(i,s,l,d){var g=i.updateQueue;Ni=!1;var y=g.firstBaseUpdate,x=g.lastBaseUpdate,O=g.shared.pending;if(O!==null){g.shared.pending=null;var L=O,Y=L.next;L.next=null,x===null?y=Y:x.next=Y,x=L;var se=i.alternate;se!==null&&(se=se.updateQueue,O=se.lastBaseUpdate,O!==x&&(O===null?se.firstBaseUpdate=Y:O.next=Y,se.lastBaseUpdate=L))}if(y!==null){var ce=g.baseState;x=0,se=Y=L=null,O=y;do{var ne=O.lane,xe=O.eventTime;if((d&ne)===ne){se!==null&&(se=se.next={eventTime:xe,lane:0,tag:O.tag,payload:O.payload,callback:O.callback,next:null});e:{var Ae=i,ve=O;switch(ne=s,xe=l,ve.tag){case 1:if(Ae=ve.payload,typeof Ae=="function"){ce=Ae.call(xe,ce,ne);break e}ce=Ae;break e;case 3:Ae.flags=Ae.flags&-65537|128;case 0:if(Ae=ve.payload,ne=typeof Ae=="function"?Ae.call(xe,ce,ne):Ae,ne==null)break e;ce=w({},ce,ne);break e;case 2:Ni=!0}}O.callback!==null&&O.lane!==0&&(i.flags|=64,ne=g.effects,ne===null?g.effects=[O]:ne.push(O))}else xe={eventTime:xe,lane:ne,tag:O.tag,payload:O.payload,callback:O.callback,next:null},se===null?(Y=se=xe,L=ce):se=se.next=xe,x|=ne;if(O=O.next,O===null){if(O=g.shared.pending,O===null)break;ne=O,O=ne.next,ne.next=null,g.lastBaseUpdate=ne,g.shared.pending=null}}while(!0);if(se===null&&(L=ce),g.baseState=L,g.firstBaseUpdate=Y,g.lastBaseUpdate=se,s=g.shared.interleaved,s!==null){g=s;do x|=g.lane,g=g.next;while(g!==s)}else y===null&&(g.shared.lanes=0);cs|=x,i.lanes=x,i.memoizedState=ce}}function Y_(i,s,l){if(i=s.effects,s.effects=null,i!==null)for(s=0;s<i.length;s++){var d=i[s],g=d.callback;if(g!==null){if(d.callback=null,d=l,typeof g!="function")throw Error(n(191,g));g.call(d)}}}var Xu={},Fr=Ai(Xu),Ju=Ai(Xu),Zu=Ai(Xu);function as(i){if(i===Xu)throw Error(n(174));return i}function jp(i,s){switch(ct(Zu,s),ct(Ju,i),ct(Fr,Xu),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:Ee(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=Ee(s,i)}ht(Fr),ct(Fr,s)}function So(){ht(Fr),ht(Ju),ht(Zu)}function W_(i){as(Zu.current);var s=as(Fr.current),l=Ee(s,i.type);s!==l&&(ct(Ju,i),ct(Fr,l))}function $p(i){Ju.current===i&&(ht(Fr),ht(Ju))}var wt=Ai(0);function Sc(i){for(var s=i;s!==null;){if(s.tag===13){var l=s.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||l.data==="$!"))return s}else if(s.tag===19&&s.memoizedProps.revealOrder!==void 0){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var Vp=[];function qp(){for(var i=0;i<Vp.length;i++)Vp[i]._workInProgressVersionPrimary=null;Vp.length=0}var wc=G.ReactCurrentDispatcher,Yp=G.ReactCurrentBatchConfig,ls=0,Ct=null,Ht=null,Gt=null,Cc=!1,ea=!1,ta=0,EF=0;function ln(){throw Error(n(321))}function Wp(i,s){if(s===null)return!1;for(var l=0;l<s.length&&l<i.length;l++)if(!pr(i[l],s[l]))return!1;return!0}function Gp(i,s,l,d,g,y){if(ls=y,Ct=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,wc.current=i===null||i.memoizedState===null?_F:xF,i=l(d,g),ea){y=0;do{if(ea=!1,ta=0,25<=y)throw Error(n(301));y+=1,Gt=Ht=null,s.updateQueue=null,wc.current=SF,i=l(d,g)}while(ea)}if(wc.current=kc,s=Ht!==null&&Ht.next!==null,ls=0,Gt=Ht=Ct=null,Cc=!1,s)throw Error(n(300));return i}function Kp(){var i=ta!==0;return ta=0,i}function Mr(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Gt===null?Ct.memoizedState=Gt=i:Gt=Gt.next=i,Gt}function Zn(){if(Ht===null){var i=Ct.alternate;i=i!==null?i.memoizedState:null}else i=Ht.next;var s=Gt===null?Ct.memoizedState:Gt.next;if(s!==null)Gt=s,Ht=i;else{if(i===null)throw Error(n(310));Ht=i,i={memoizedState:Ht.memoizedState,baseState:Ht.baseState,baseQueue:Ht.baseQueue,queue:Ht.queue,next:null},Gt===null?Ct.memoizedState=Gt=i:Gt=Gt.next=i}return Gt}function na(i,s){return typeof s=="function"?s(i):s}function Qp(i){var s=Zn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var d=Ht,g=d.baseQueue,y=l.pending;if(y!==null){if(g!==null){var x=g.next;g.next=y.next,y.next=x}d.baseQueue=g=y,l.pending=null}if(g!==null){y=g.next,d=d.baseState;var O=x=null,L=null,Y=y;do{var se=Y.lane;if((ls&se)===se)L!==null&&(L=L.next={lane:0,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null}),d=Y.hasEagerState?Y.eagerState:i(d,Y.action);else{var ce={lane:se,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null};L===null?(O=L=ce,x=d):L=L.next=ce,Ct.lanes|=se,cs|=se}Y=Y.next}while(Y!==null&&Y!==y);L===null?x=d:L.next=O,pr(d,s.memoizedState)||(kn=!0),s.memoizedState=d,s.baseState=x,s.baseQueue=L,l.lastRenderedState=d}if(i=l.interleaved,i!==null){g=i;do y=g.lane,Ct.lanes|=y,cs|=y,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function Xp(i){var s=Zn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var d=l.dispatch,g=l.pending,y=s.memoizedState;if(g!==null){l.pending=null;var x=g=g.next;do y=i(y,x.action),x=x.next;while(x!==g);pr(y,s.memoizedState)||(kn=!0),s.memoizedState=y,s.baseQueue===null&&(s.baseState=y),l.lastRenderedState=y}return[y,d]}function G_(){}function K_(i,s){var l=Ct,d=Zn(),g=s(),y=!pr(d.memoizedState,g);if(y&&(d.memoizedState=g,kn=!0),d=d.queue,Jp(J_.bind(null,l,d,i),[i]),d.getSnapshot!==s||y||Gt!==null&&Gt.memoizedState.tag&1){if(l.flags|=2048,ra(9,X_.bind(null,l,d,g,s),void 0,null),Kt===null)throw Error(n(349));(ls&30)!==0||Q_(l,s,g)}return g}function Q_(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=Ct.updateQueue,s===null?(s={lastEffect:null,stores:null},Ct.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function X_(i,s,l,d){s.value=l,s.getSnapshot=d,Z_(s)&&e2(i)}function J_(i,s,l){return l(function(){Z_(s)&&e2(i)})}function Z_(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!pr(i,l)}catch(d){return!0}}function e2(i){var s=ri(i,1);s!==null&&Tr(s,i,1,-1)}function t2(i){var s=Mr();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:na,lastRenderedState:i},s.queue=i,i=i.dispatch=bF.bind(null,Ct,i),[s.memoizedState,i]}function ra(i,s,l,d){return i={tag:i,create:s,destroy:l,deps:d,next:null},s=Ct.updateQueue,s===null?(s={lastEffect:null,stores:null},Ct.updateQueue=s,s.lastEffect=i.next=i):(l=s.lastEffect,l===null?s.lastEffect=i.next=i:(d=l.next,l.next=i,i.next=d,s.lastEffect=i)),i}function n2(){return Zn().memoizedState}function Ac(i,s,l,d){var g=Mr();Ct.flags|=i,g.memoizedState=ra(1|s,l,void 0,d===void 0?null:d)}function vc(i,s,l,d){var g=Zn();d=d===void 0?null:d;var y=void 0;if(Ht!==null){var x=Ht.memoizedState;if(y=x.destroy,d!==null&&Wp(d,x.deps)){g.memoizedState=ra(s,l,y,d);return}}Ct.flags|=i,g.memoizedState=ra(1|s,l,y,d)}function r2(i,s){return Ac(8390656,8,i,s)}function Jp(i,s){return vc(2048,8,i,s)}function i2(i,s){return vc(4,2,i,s)}function s2(i,s){return vc(4,4,i,s)}function o2(i,s){if(typeof s=="function")return i=i(),s(i),function(){s(null)};if(s!=null)return i=i(),s.current=i,function(){s.current=null}}function u2(i,s,l){return l=l!=null?l.concat([i]):null,vc(4,4,o2.bind(null,s,i),l)}function Zp(){}function a2(i,s){var l=Zn();s=s===void 0?null:s;var d=l.memoizedState;return d!==null&&s!==null&&Wp(s,d[1])?d[0]:(l.memoizedState=[i,s],i)}function l2(i,s){var l=Zn();s=s===void 0?null:s;var d=l.memoizedState;return d!==null&&s!==null&&Wp(s,d[1])?d[0]:(i=i(),l.memoizedState=[i,s],i)}function c2(i,s,l){return(ls&21)===0?(i.baseState&&(i.baseState=!1,kn=!0),i.memoizedState=l):(pr(l,s)||(l=Hb(),Ct.lanes|=l,cs|=l,i.baseState=!0),s)}function yF(i,s){var l=st;st=l!==0&&4>l?l:4,i(!0);var d=Yp.transition;Yp.transition={};try{i(!1),s()}finally{st=l,Yp.transition=d}}function f2(){return Zn().memoizedState}function TF(i,s,l){var d=Li(i);if(l={lane:d,action:l,hasEagerState:!1,eagerState:null,next:null},d2(i))h2(s,l);else if(l=$_(i,s,l,d),l!==null){var g=gn();Tr(l,i,d,g),p2(l,s,d)}}function bF(i,s,l){var d=Li(i),g={lane:d,action:l,hasEagerState:!1,eagerState:null,next:null};if(d2(i))h2(s,g);else{var y=i.alternate;if(i.lanes===0&&(y===null||y.lanes===0)&&(y=s.lastRenderedReducer,y!==null))try{var x=s.lastRenderedState,O=y(x,l);if(g.hasEagerState=!0,g.eagerState=O,pr(O,x)){var L=s.interleaved;L===null?(g.next=g,Hp(s)):(g.next=L.next,L.next=g),s.interleaved=g;return}}catch(Y){}finally{}l=$_(i,s,g,d),l!==null&&(g=gn(),Tr(l,i,d,g),p2(l,s,d))}}function d2(i){var s=i.alternate;return i===Ct||s!==null&&s===Ct}function h2(i,s){ea=Cc=!0;var l=i.pending;l===null?s.next=s:(s.next=l.next,l.next=s),i.pending=s}function p2(i,s,l){if((l&4194240)!==0){var d=s.lanes;d&=i.pendingLanes,l|=d,s.lanes=l,tp(i,l)}}var kc={readContext:Jn,useCallback:ln,useContext:ln,useEffect:ln,useImperativeHandle:ln,useInsertionEffect:ln,useLayoutEffect:ln,useMemo:ln,useReducer:ln,useRef:ln,useState:ln,useDebugValue:ln,useDeferredValue:ln,useTransition:ln,useMutableSource:ln,useSyncExternalStore:ln,useId:ln,unstable_isNewReconciler:!1},_F={readContext:Jn,useCallback:function(i,s){return Mr().memoizedState=[i,s===void 0?null:s],i},useContext:Jn,useEffect:r2,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,Ac(4194308,4,o2.bind(null,s,i),l)},useLayoutEffect:function(i,s){return Ac(4194308,4,i,s)},useInsertionEffect:function(i,s){return Ac(4,2,i,s)},useMemo:function(i,s){var l=Mr();return s=s===void 0?null:s,i=i(),l.memoizedState=[i,s],i},useReducer:function(i,s,l){var d=Mr();return s=l!==void 0?l(s):s,d.memoizedState=d.baseState=s,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:i,lastRenderedState:s},d.queue=i,i=i.dispatch=TF.bind(null,Ct,i),[d.memoizedState,i]},useRef:function(i){var s=Mr();return i={current:i},s.memoizedState=i},useState:t2,useDebugValue:Zp,useDeferredValue:function(i){return Mr().memoizedState=i},useTransition:function(){var i=t2(!1),s=i[0];return i=yF.bind(null,i[1]),Mr().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var d=Ct,g=Mr();if(bt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Kt===null)throw Error(n(349));(ls&30)!==0||Q_(d,s,l)}g.memoizedState=l;var y={value:l,getSnapshot:s};return g.queue=y,r2(J_.bind(null,d,y,i),[i]),d.flags|=2048,ra(9,X_.bind(null,d,y,l,s),void 0,null),l},useId:function(){var i=Mr(),s=Kt.identifierPrefix;if(bt){var l=ni,d=ti;l=(d&~(1<<32-hr(d)-1)).toString(32)+l,s=":"+s+"R"+l,l=ta++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=EF++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},xF={readContext:Jn,useCallback:a2,useContext:Jn,useEffect:Jp,useImperativeHandle:u2,useInsertionEffect:i2,useLayoutEffect:s2,useMemo:l2,useReducer:Qp,useRef:n2,useState:function(){return Qp(na)},useDebugValue:Zp,useDeferredValue:function(i){var s=Zn();return c2(s,Ht.memoizedState,i)},useTransition:function(){var i=Qp(na)[0],s=Zn().memoizedState;return[i,s]},useMutableSource:G_,useSyncExternalStore:K_,useId:f2,unstable_isNewReconciler:!1},SF={readContext:Jn,useCallback:a2,useContext:Jn,useEffect:Jp,useImperativeHandle:u2,useInsertionEffect:i2,useLayoutEffect:s2,useMemo:l2,useReducer:Xp,useRef:n2,useState:function(){return Xp(na)},useDebugValue:Zp,useDeferredValue:function(i){var s=Zn();return Ht===null?s.memoizedState=i:c2(s,Ht.memoizedState,i)},useTransition:function(){var i=Xp(na)[0],s=Zn().memoizedState;return[i,s]},useMutableSource:G_,useSyncExternalStore:K_,useId:f2,unstable_isNewReconciler:!1};function gr(i,s){if(i&&i.defaultProps){s=w({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function em(i,s,l,d){s=i.memoizedState,l=l(d,s),l=l==null?s:w({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var Nc={isMounted:function(i){return(i=i._reactInternals)?ns(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var d=gn(),g=Li(i),y=ii(d,g);y.payload=s,l!=null&&(y.callback=l),s=Oi(i,y,g),s!==null&&(Tr(s,i,g,d),_c(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var d=gn(),g=Li(i),y=ii(d,g);y.tag=1,y.payload=s,l!=null&&(y.callback=l),s=Oi(i,y,g),s!==null&&(Tr(s,i,g,d),_c(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=gn(),d=Li(i),g=ii(l,d);g.tag=2,s!=null&&(g.callback=s),s=Oi(i,g,d),s!==null&&(Tr(s,i,d,l),_c(s,i,d))}};function m2(i,s,l,d,g,y,x){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(d,y,x):s.prototype&&s.prototype.isPureReactComponent?!$u(l,d)||!$u(g,y):!0}function g2(i,s,l){var d=!1,g=vi,y=s.contextType;return typeof y=="object"&&y!==null?y=Jn(y):(g=vn(s)?is:an.current,d=s.contextTypes,y=(d=d!=null)?go(i,g):vi),s=new s(l,y),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=Nc,i.stateNode=s,s._reactInternals=i,d&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=y),s}function E2(i,s,l,d){i=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(l,d),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(l,d),s.state!==i&&Nc.enqueueReplaceState(s,s.state,null)}function tm(i,s,l,d){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},zp(i);var y=s.contextType;typeof y=="object"&&y!==null?g.context=Jn(y):(y=vn(s)?is:an.current,g.context=go(i,y)),g.state=i.memoizedState,y=s.getDerivedStateFromProps,typeof y=="function"&&(em(i,s,y,l),g.state=i.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(s=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),s!==g.state&&Nc.enqueueReplaceState(g,g.state,null),xc(i,l,g,d),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function wo(i,s){try{var l="",d=s;do l+=Me(d),d=d.return;while(d);var g=l}catch(y){g=`
11
+ `+g[x].replace(" at new "," at ");return i.displayName&&L.includes("<anonymous>")&&(L=L.replace("<anonymous>",i.displayName)),L}while(1<=x&&0<=O);break}}}finally{N=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?Q(i):""}function Me(i){switch(i.tag){case 5:return Q(i.type);case 16:return Q("Lazy");case 13:return Q("Suspense");case 19:return Q("SuspenseList");case 0:case 2:case 15:return i=_e(i.type,!1),i;case 11:return i=_e(i.type.render,!1),i;case 1:return i=_e(i.type,!0),i;default:return""}}function Ie(i){if(i==null)return null;if(typeof i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case te:return"Fragment";case B:return"Portal";case Se:return"Profiler";case Te:return"StrictMode";case ue:return"Suspense";case ie:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case fe:return(i.displayName||"Context")+".Consumer";case H:return(i._context.displayName||"Context")+".Provider";case de:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case ge:return s=i.displayName||null,s!==null?s:Ie(i.type)||"Memo";case we:s=i._payload,i=i._init;try{return Ie(i(s))}catch(l){}}return null}function Ye(i){var s=i.type;switch(i.tag){case 24:return"Cache";case 9:return(s.displayName||"Context")+".Consumer";case 10:return(s._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return i=s.render,i=i.displayName||i.name||"",s.displayName||(i!==""?"ForwardRef("+i+")":"ForwardRef");case 7:return"Fragment";case 5:return s;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Ie(s);case 8:return s===Te?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function Ve(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function Je(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function xt(i){var s=Je(i)?"checked":"value",l=Object.getOwnPropertyDescriptor(i.constructor.prototype,s),d=""+i[s];if(!i.hasOwnProperty(s)&&typeof l!="undefined"&&typeof l.get=="function"&&typeof l.set=="function"){var g=l.get,y=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return g.call(this)},set:function(x){d=""+x,y.call(this,x)}}),Object.defineProperty(i,s,{enumerable:l.enumerable}),{getValue:function(){return d},setValue:function(x){d=""+x},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function be(i){i._valueTracker||(i._valueTracker=xt(i))}function He(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var l=s.getValue(),d="";return i&&(d=Je(i)?i.checked?"true":"false":i.value),i=d,i!==l?(s.setValue(i),!0):!1}function tt(i){if(i=i||(typeof document!="undefined"?document:void 0),typeof i=="undefined")return null;try{return i.activeElement||i.body}catch(s){return i.body}}function Tt(i,s){var l=s.checked;return w({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function St(i,s){var l=s.defaultValue==null?"":s.defaultValue,d=s.checked!=null?s.checked:s.defaultChecked;l=Ve(s.value!=null?s.value:l),i._wrapperState={initialChecked:d,initialValue:l,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function on(i,s){s=s.checked,s!=null&&D(i,"checked",s,!1)}function qt(i,s){on(i,s);var l=Ve(s.value),d=s.type;if(l!=null)d==="number"?(l===0&&i.value===""||i.value!=l)&&(i.value=""+l):i.value!==""+l&&(i.value=""+l);else if(d==="submit"||d==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?Rr(i,s.type,l):s.hasOwnProperty("defaultValue")&&Rr(i,s.type,Ve(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function rt(i,s,l){if(s.hasOwnProperty("value")||s.hasOwnProperty("defaultValue")){var d=s.type;if(!(d!=="submit"&&d!=="reset"||s.value!==void 0&&s.value!==null))return;s=""+i._wrapperState.initialValue,l||s===i.value||(i.value=s),i.defaultValue=s}l=i.name,l!==""&&(i.name=""),i.defaultChecked=!!i._wrapperState.initialChecked,l!==""&&(i.name=l)}function Rr(i,s,l){(s!=="number"||tt(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var Wn=Array.isArray;function Yt(i,s,l,d){if(i=i.options,s){s={};for(var g=0;g<l.length;g++)s["$"+l[g]]=!0;for(l=0;l<i.length;l++)g=s.hasOwnProperty("$"+i[l].value),i[l].selected!==g&&(i[l].selected=g),g&&d&&(i[l].defaultSelected=!0)}else{for(l=""+Ve(l),s=null,g=0;g<i.length;g++){if(i[g].value===l){i[g].selected=!0,d&&(i[g].defaultSelected=!0);return}s!==null||i[g].disabled||(s=i[g])}s!==null&&(s.selected=!0)}}function Cu(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return w({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function Bl(i,s){var l=s.value;if(l==null){if(l=s.children,s=s.defaultValue,l!=null){if(s!=null)throw Error(n(92));if(Wn(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:Ve(l)}}function Ul(i,s){var l=Ve(s.value),d=Ve(s.defaultValue);l!=null&&(l=""+l,l!==i.value&&(i.value=l),s.defaultValue==null&&i.defaultValue!==l&&(i.defaultValue=l)),d!=null&&(i.defaultValue=""+d)}function Hl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function J(i){switch(i){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Ee(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?J(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Be,We=function(i){return typeof MSApp!="undefined"&&MSApp.execUnsafeLocalFunction?function(s,l,d,g){MSApp.execUnsafeLocalFunction(function(){return i(s,l,d,g)})}:i}(function(i,s){if(i.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in i)i.innerHTML=s;else{for(Be=Be||document.createElement("div"),Be.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=Be.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function Ze(i,s){if(s){var l=i.firstChild;if(l&&l===i.lastChild&&l.nodeType===3){l.nodeValue=s;return}}i.textContent=s}var Qt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Zr=["Webkit","ms","Moz","O"];Object.keys(Qt).forEach(function(i){Zr.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),Qt[s]=Qt[i]})});function Gn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||Qt.hasOwnProperty(i)&&Qt[i]?(""+s).trim():s+"px"}function yi(i,s){i=i.style;for(var l in s)if(s.hasOwnProperty(l)){var d=l.indexOf("--")===0,g=Gn(l,s[l],d);l==="float"&&(l="cssFloat"),d?i.setProperty(l,g):i[l]=g}}var ts=w({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Xt(i,s){if(s){if(ts[i]&&(s.children!=null||s.dangerouslySetInnerHTML!=null))throw Error(n(137,i));if(s.dangerouslySetInnerHTML!=null){if(s.children!=null)throw Error(n(60));if(typeof s.dangerouslySetInnerHTML!="object"||!("__html"in s.dangerouslySetInnerHTML))throw Error(n(61))}if(s.style!=null&&typeof s.style!="object")throw Error(n(62))}}function Lr(i,s){if(i.indexOf("-")===-1)return typeof s.is=="string";switch(i){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Fn=null;function $h(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var Vh=null,no=null,ro=null;function Nb(i){if(i=Wu(i)){if(typeof Vh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=lc(s),Vh(i.stateNode,i.type,s))}}function Ob(i){no?ro?ro.push(i):ro=[i]:no=i}function Ib(){if(no){var i=no,s=ro;if(ro=no=null,Nb(i),s)for(i=0;i<s.length;i++)Nb(s[i])}}function Pb(i,s){return i(s)}function Rb(){}var qh=!1;function Lb(i,s,l){if(qh)return i(s,l);qh=!0;try{return Pb(i,s,l)}finally{qh=!1,(no!==null||ro!==null)&&(Rb(),Ib())}}function Au(i,s){var l=i.stateNode;if(l===null)return null;var d=lc(l);if(d===null)return null;l=d[s];e:switch(s){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(d=!d.disabled)||(i=i.type,d=!(i==="button"||i==="input"||i==="select"||i==="textarea")),i=!d;break e;default:i=!1}if(i)return null;if(l&&typeof l!="function")throw Error(n(231,s,typeof l));return l}var Yh=!1;if(c)try{var vu={};Object.defineProperty(vu,"passive",{get:function(){Yh=!0}}),window.addEventListener("test",vu,vu),window.removeEventListener("test",vu,vu)}catch(i){Yh=!1}function p8(i,s,l,d,g,y,x,O,L){var Y=Array.prototype.slice.call(arguments,3);try{s.apply(l,Y)}catch(se){this.onError(se)}}var ku=!1,zl=null,jl=!1,Wh=null,m8={onError:function(i){ku=!0,zl=i}};function g8(i,s,l,d,g,y,x,O,L){ku=!1,zl=null,p8.apply(m8,arguments)}function E8(i,s,l,d,g,y,x,O,L){if(g8.apply(this,arguments),ku){if(ku){var Y=zl;ku=!1,zl=null}else throw Error(n(198));jl||(jl=!0,Wh=Y)}}function ns(i){var s=i,l=i;if(i.alternate)for(;s.return;)s=s.return;else{i=s;do s=i,(s.flags&4098)!==0&&(l=s.return),i=s.return;while(i)}return s.tag===3?l:null}function Db(i){if(i.tag===13){var s=i.memoizedState;if(s===null&&(i=i.alternate,i!==null&&(s=i.memoizedState)),s!==null)return s.dehydrated}return null}function Fb(i){if(ns(i)!==i)throw Error(n(188))}function y8(i){var s=i.alternate;if(!s){if(s=ns(i),s===null)throw Error(n(188));return s!==i?null:i}for(var l=i,d=s;;){var g=l.return;if(g===null)break;var y=g.alternate;if(y===null){if(d=g.return,d!==null){l=d;continue}break}if(g.child===y.child){for(y=g.child;y;){if(y===l)return Fb(g),i;if(y===d)return Fb(g),s;y=y.sibling}throw Error(n(188))}if(l.return!==d.return)l=g,d=y;else{for(var x=!1,O=g.child;O;){if(O===l){x=!0,l=g,d=y;break}if(O===d){x=!0,d=g,l=y;break}O=O.sibling}if(!x){for(O=y.child;O;){if(O===l){x=!0,l=y,d=g;break}if(O===d){x=!0,d=y,l=g;break}O=O.sibling}if(!x)throw Error(n(189))}}if(l.alternate!==d)throw Error(n(190))}if(l.tag!==3)throw Error(n(188));return l.stateNode.current===l?i:s}function Mb(i){return i=y8(i),i!==null?Bb(i):null}function Bb(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=Bb(i);if(s!==null)return s;i=i.sibling}return null}var Ub=t.unstable_scheduleCallback,Hb=t.unstable_cancelCallback,T8=t.unstable_shouldYield,b8=t.unstable_requestPaint,Pt=t.unstable_now,_8=t.unstable_getCurrentPriorityLevel,Gh=t.unstable_ImmediatePriority,zb=t.unstable_UserBlockingPriority,$l=t.unstable_NormalPriority,x8=t.unstable_LowPriority,jb=t.unstable_IdlePriority,Vl=null,Dr=null;function S8(i){if(Dr&&typeof Dr.onCommitFiberRoot=="function")try{Dr.onCommitFiberRoot(Vl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var hr=Math.clz32?Math.clz32:A8,w8=Math.log,C8=Math.LN2;function A8(i){return i>>>=0,i===0?32:31-(w8(i)/C8|0)|0}var ql=64,Yl=4194304;function Nu(i){switch(i&-i){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return i&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return i&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return i}}function Wl(i,s){var l=i.pendingLanes;if(l===0)return 0;var d=0,g=i.suspendedLanes,y=i.pingedLanes,x=l&268435455;if(x!==0){var O=x&~g;O!==0?d=Nu(O):(y&=x,y!==0&&(d=Nu(y)))}else x=l&~g,x!==0?d=Nu(x):y!==0&&(d=Nu(y));if(d===0)return 0;if(s!==0&&s!==d&&(s&g)===0&&(g=d&-d,y=s&-s,g>=y||g===16&&(y&4194240)!==0))return s;if((d&4)!==0&&(d|=l&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=d;0<s;)l=31-hr(s),g=1<<l,d|=i[l],s&=~g;return d}function v8(i,s){switch(i){case 1:case 2:case 4:return s+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return s+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function k8(i,s){for(var l=i.suspendedLanes,d=i.pingedLanes,g=i.expirationTimes,y=i.pendingLanes;0<y;){var x=31-hr(y),O=1<<x,L=g[x];L===-1?((O&l)===0||(O&d)!==0)&&(g[x]=v8(O,s)):L<=s&&(i.expiredLanes|=O),y&=~O}}function Kh(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function $b(){var i=ql;return ql<<=1,(ql&4194240)===0&&(ql=64),i}function Qh(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function Ou(i,s,l){i.pendingLanes|=s,s!==536870912&&(i.suspendedLanes=0,i.pingedLanes=0),i=i.eventTimes,s=31-hr(s),i[s]=l}function N8(i,s){var l=i.pendingLanes&~s;i.pendingLanes=s,i.suspendedLanes=0,i.pingedLanes=0,i.expiredLanes&=s,i.mutableReadLanes&=s,i.entangledLanes&=s,s=i.entanglements;var d=i.eventTimes;for(i=i.expirationTimes;0<l;){var g=31-hr(l),y=1<<g;s[g]=0,d[g]=-1,i[g]=-1,l&=~y}}function Xh(i,s){var l=i.entangledLanes|=s;for(i=i.entanglements;l;){var d=31-hr(l),g=1<<d;g&s|i[d]&s&&(i[d]|=s),l&=~g}}var ot=0;function Vb(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var qb,Jh,Yb,Wb,Gb,Zh=!1,Gl=[],Ti=null,bi=null,_i=null,Iu=new Map,Pu=new Map,xi=[],O8="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Kb(i,s){switch(i){case"focusin":case"focusout":Ti=null;break;case"dragenter":case"dragleave":bi=null;break;case"mouseover":case"mouseout":_i=null;break;case"pointerover":case"pointerout":Iu.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":Pu.delete(s.pointerId)}}function Ru(i,s,l,d,g,y){return i===null||i.nativeEvent!==y?(i={blockedOn:s,domEventName:l,eventSystemFlags:d,nativeEvent:y,targetContainers:[g]},s!==null&&(s=Wu(s),s!==null&&Jh(s)),i):(i.eventSystemFlags|=d,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function I8(i,s,l,d,g){switch(s){case"focusin":return Ti=Ru(Ti,i,s,l,d,g),!0;case"dragenter":return bi=Ru(bi,i,s,l,d,g),!0;case"mouseover":return _i=Ru(_i,i,s,l,d,g),!0;case"pointerover":var y=g.pointerId;return Iu.set(y,Ru(Iu.get(y)||null,i,s,l,d,g)),!0;case"gotpointercapture":return y=g.pointerId,Pu.set(y,Ru(Pu.get(y)||null,i,s,l,d,g)),!0}return!1}function Qb(i){var s=rs(i.target);if(s!==null){var l=ns(s);if(l!==null){if(s=l.tag,s===13){if(s=Db(l),s!==null){i.blockedOn=s,Gb(i.priority,function(){Yb(l)});return}}else if(s===3&&l.stateNode.current.memoizedState.isDehydrated){i.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}i.blockedOn=null}function Kl(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=tp(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var d=new l.constructor(l.type,l);Fn=d,l.target.dispatchEvent(d),Fn=null}else return s=Wu(l),s!==null&&Jh(s),i.blockedOn=l,!1;s.shift()}return!0}function Xb(i,s,l){Kl(i)&&l.delete(s)}function P8(){Zh=!1,Ti!==null&&Kl(Ti)&&(Ti=null),bi!==null&&Kl(bi)&&(bi=null),_i!==null&&Kl(_i)&&(_i=null),Iu.forEach(Xb),Pu.forEach(Xb)}function Lu(i,s){i.blockedOn===s&&(i.blockedOn=null,Zh||(Zh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,P8)))}function Du(i){function s(g){return Lu(g,i)}if(0<Gl.length){Lu(Gl[0],i);for(var l=1;l<Gl.length;l++){var d=Gl[l];d.blockedOn===i&&(d.blockedOn=null)}}for(Ti!==null&&Lu(Ti,i),bi!==null&&Lu(bi,i),_i!==null&&Lu(_i,i),Iu.forEach(s),Pu.forEach(s),l=0;l<xi.length;l++)d=xi[l],d.blockedOn===i&&(d.blockedOn=null);for(;0<xi.length&&(l=xi[0],l.blockedOn===null);)Qb(l),l.blockedOn===null&&xi.shift()}var io=G.ReactCurrentBatchConfig,Ql=!0;function R8(i,s,l,d){var g=ot,y=io.transition;io.transition=null;try{ot=1,ep(i,s,l,d)}finally{ot=g,io.transition=y}}function L8(i,s,l,d){var g=ot,y=io.transition;io.transition=null;try{ot=4,ep(i,s,l,d)}finally{ot=g,io.transition=y}}function ep(i,s,l,d){if(Ql){var g=tp(i,s,l,d);if(g===null)yp(i,s,d,Xl,l),Kb(i,d);else if(I8(g,i,s,l,d))d.stopPropagation();else if(Kb(i,d),s&4&&-1<O8.indexOf(i)){for(;g!==null;){var y=Wu(g);if(y!==null&&qb(y),y=tp(i,s,l,d),y===null&&yp(i,s,d,Xl,l),y===g)break;g=y}g!==null&&d.stopPropagation()}else yp(i,s,d,null,l)}}var Xl=null;function tp(i,s,l,d){if(Xl=null,i=$h(d),i=rs(i),i!==null)if(s=ns(i),s===null)i=null;else if(l=s.tag,l===13){if(i=Db(s),i!==null)return i;i=null}else if(l===3){if(s.stateNode.current.memoizedState.isDehydrated)return s.tag===3?s.stateNode.containerInfo:null;i=null}else s!==i&&(i=null);return Xl=i,null}function Jb(i){switch(i){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(_8()){case Gh:return 1;case zb:return 4;case $l:case x8:return 16;case jb:return 536870912;default:return 16}default:return 16}}var Si=null,np=null,Jl=null;function Zb(){if(Jl)return Jl;var i,s=np,l=s.length,d,g="value"in Si?Si.value:Si.textContent,y=g.length;for(i=0;i<l&&s[i]===g[i];i++);var x=l-i;for(d=1;d<=x&&s[l-d]===g[y-d];d++);return Jl=g.slice(i,1<d?1-d:void 0)}function Zl(i){var s=i.keyCode;return"charCode"in i?(i=i.charCode,i===0&&s===13&&(i=13)):i=s,i===10&&(i=13),32<=i||i===13?i:0}function ec(){return!0}function e_(){return!1}function Mn(i){function s(l,d,g,y,x){this._reactName=l,this._targetInst=g,this.type=d,this.nativeEvent=y,this.target=x,this.currentTarget=null;for(var O in i)i.hasOwnProperty(O)&&(l=i[O],this[O]=l?l(y):y[O]);return this.isDefaultPrevented=(y.defaultPrevented!=null?y.defaultPrevented:y.returnValue===!1)?ec:e_,this.isPropagationStopped=e_,this}return w(s.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=ec)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=ec)},persist:function(){},isPersistent:ec}),s}var so={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},rp=Mn(so),Fu=w({},so,{view:0,detail:0}),D8=Mn(Fu),ip,sp,Mu,tc=w({},Fu,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:up,button:0,buttons:0,relatedTarget:function(i){return i.relatedTarget===void 0?i.fromElement===i.srcElement?i.toElement:i.fromElement:i.relatedTarget},movementX:function(i){return"movementX"in i?i.movementX:(i!==Mu&&(Mu&&i.type==="mousemove"?(ip=i.screenX-Mu.screenX,sp=i.screenY-Mu.screenY):sp=ip=0,Mu=i),ip)},movementY:function(i){return"movementY"in i?i.movementY:sp}}),t_=Mn(tc),F8=w({},tc,{dataTransfer:0}),M8=Mn(F8),B8=w({},Fu,{relatedTarget:0}),op=Mn(B8),U8=w({},so,{animationName:0,elapsedTime:0,pseudoElement:0}),H8=Mn(U8),z8=w({},so,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),j8=Mn(z8),$8=w({},so,{data:0}),n_=Mn($8),V8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},q8={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Y8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function W8(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=Y8[i])?!!s[i]:!1}function up(){return W8}var G8=w({},Fu,{key:function(i){if(i.key){var s=V8[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=Zl(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?q8[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:up,charCode:function(i){return i.type==="keypress"?Zl(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?Zl(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),K8=Mn(G8),Q8=w({},tc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),r_=Mn(Q8),X8=w({},Fu,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:up}),J8=Mn(X8),Z8=w({},so,{propertyName:0,elapsedTime:0,pseudoElement:0}),eF=Mn(Z8),tF=w({},tc,{deltaX:function(i){return"deltaX"in i?i.deltaX:"wheelDeltaX"in i?-i.wheelDeltaX:0},deltaY:function(i){return"deltaY"in i?i.deltaY:"wheelDeltaY"in i?-i.wheelDeltaY:"wheelDelta"in i?-i.wheelDelta:0},deltaZ:0,deltaMode:0}),nF=Mn(tF),rF=[9,13,27,32],ap=c&&"CompositionEvent"in window,Bu=null;c&&"documentMode"in document&&(Bu=document.documentMode);var iF=c&&"TextEvent"in window&&!Bu,i_=c&&(!ap||Bu&&8<Bu&&11>=Bu),s_=" ",o_=!1;function u_(i,s){switch(i){case"keyup":return rF.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function a_(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var oo=!1;function sF(i,s){switch(i){case"compositionend":return a_(s);case"keypress":return s.which!==32?null:(o_=!0,s_);case"textInput":return i=s.data,i===s_&&o_?null:i;default:return null}}function oF(i,s){if(oo)return i==="compositionend"||!ap&&u_(i,s)?(i=Zb(),Jl=np=Si=null,oo=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return i_&&s.locale!=="ko"?null:s.data;default:return null}}var uF={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function l_(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!uF[i.type]:s==="textarea"}function c_(i,s,l,d){Ob(d),s=oc(s,"onChange"),0<s.length&&(l=new rp("onChange","change",null,l,d),i.push({event:l,listeners:s}))}var Uu=null,Hu=null;function aF(i){k_(i,0)}function nc(i){var s=fo(i);if(He(s))return i}function lF(i,s){if(i==="change")return s}var f_=!1;if(c){var lp;if(c){var cp="oninput"in document;if(!cp){var d_=document.createElement("div");d_.setAttribute("oninput","return;"),cp=typeof d_.oninput=="function"}lp=cp}else lp=!1;f_=lp&&(!document.documentMode||9<document.documentMode)}function h_(){Uu&&(Uu.detachEvent("onpropertychange",p_),Hu=Uu=null)}function p_(i){if(i.propertyName==="value"&&nc(Hu)){var s=[];c_(s,Hu,i,$h(i)),Lb(aF,s)}}function cF(i,s,l){i==="focusin"?(h_(),Uu=s,Hu=l,Uu.attachEvent("onpropertychange",p_)):i==="focusout"&&h_()}function fF(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return nc(Hu)}function dF(i,s){if(i==="click")return nc(s)}function hF(i,s){if(i==="input"||i==="change")return nc(s)}function pF(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var pr=typeof Object.is=="function"?Object.is:pF;function zu(i,s){if(pr(i,s))return!0;if(typeof i!="object"||i===null||typeof s!="object"||s===null)return!1;var l=Object.keys(i),d=Object.keys(s);if(l.length!==d.length)return!1;for(d=0;d<l.length;d++){var g=l[d];if(!f.call(s,g)||!pr(i[g],s[g]))return!1}return!0}function m_(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function g_(i,s){var l=m_(i);i=0;for(var d;l;){if(l.nodeType===3){if(d=i+l.textContent.length,i<=s&&d>=s)return{node:l,offset:s-i};i=d}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=m_(l)}}function E_(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?E_(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function y_(){for(var i=window,s=tt();s instanceof i.HTMLIFrameElement;){try{var l=typeof s.contentWindow.location.href=="string"}catch(d){l=!1}if(l)i=s.contentWindow;else break;s=tt(i.document)}return s}function fp(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s&&(s==="input"&&(i.type==="text"||i.type==="search"||i.type==="tel"||i.type==="url"||i.type==="password")||s==="textarea"||i.contentEditable==="true")}function mF(i){var s=y_(),l=i.focusedElem,d=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&E_(l.ownerDocument.documentElement,l)){if(d!==null&&fp(l)){if(s=d.start,i=d.end,i===void 0&&(i=s),"selectionStart"in l)l.selectionStart=s,l.selectionEnd=Math.min(i,l.value.length);else if(i=(s=l.ownerDocument||document)&&s.defaultView||window,i.getSelection){i=i.getSelection();var g=l.textContent.length,y=Math.min(d.start,g);d=d.end===void 0?y:Math.min(d.end,g),!i.extend&&y>d&&(g=d,d=y,y=g),g=g_(l,y);var x=g_(l,d);g&&x&&(i.rangeCount!==1||i.anchorNode!==g.node||i.anchorOffset!==g.offset||i.focusNode!==x.node||i.focusOffset!==x.offset)&&(s=s.createRange(),s.setStart(g.node,g.offset),i.removeAllRanges(),y>d?(i.addRange(s),i.extend(x.node,x.offset)):(s.setEnd(x.node,x.offset),i.addRange(s)))}}for(s=[],i=l;i=i.parentNode;)i.nodeType===1&&s.push({element:i,left:i.scrollLeft,top:i.scrollTop});for(typeof l.focus=="function"&&l.focus(),l=0;l<s.length;l++)i=s[l],i.element.scrollLeft=i.left,i.element.scrollTop=i.top}}var gF=c&&"documentMode"in document&&11>=document.documentMode,uo=null,dp=null,ju=null,hp=!1;function T_(i,s,l){var d=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;hp||uo==null||uo!==tt(d)||(d=uo,"selectionStart"in d&&fp(d)?d={start:d.selectionStart,end:d.selectionEnd}:(d=(d.ownerDocument&&d.ownerDocument.defaultView||window).getSelection(),d={anchorNode:d.anchorNode,anchorOffset:d.anchorOffset,focusNode:d.focusNode,focusOffset:d.focusOffset}),ju&&zu(ju,d)||(ju=d,d=oc(dp,"onSelect"),0<d.length&&(s=new rp("onSelect","select",null,s,l),i.push({event:s,listeners:d}),s.target=uo)))}function rc(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var ao={animationend:rc("Animation","AnimationEnd"),animationiteration:rc("Animation","AnimationIteration"),animationstart:rc("Animation","AnimationStart"),transitionend:rc("Transition","TransitionEnd")},pp={},b_={};c&&(b_=document.createElement("div").style,"AnimationEvent"in window||(delete ao.animationend.animation,delete ao.animationiteration.animation,delete ao.animationstart.animation),"TransitionEvent"in window||delete ao.transitionend.transition);function ic(i){if(pp[i])return pp[i];if(!ao[i])return i;var s=ao[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in b_)return pp[i]=s[l];return i}var __=ic("animationend"),x_=ic("animationiteration"),S_=ic("animationstart"),w_=ic("transitionend"),C_=new Map,A_="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function wi(i,s){C_.set(i,s),u(s,[i])}for(var mp=0;mp<A_.length;mp++){var gp=A_[mp],EF=gp.toLowerCase(),yF=gp[0].toUpperCase()+gp.slice(1);wi(EF,"on"+yF)}wi(__,"onAnimationEnd"),wi(x_,"onAnimationIteration"),wi(S_,"onAnimationStart"),wi("dblclick","onDoubleClick"),wi("focusin","onFocus"),wi("focusout","onBlur"),wi(w_,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),u("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),u("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),u("onBeforeInput",["compositionend","keypress","textInput","paste"]),u("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),u("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var $u="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),TF=new Set("cancel close invalid load scroll toggle".split(" ").concat($u));function v_(i,s,l){var d=i.type||"unknown-event";i.currentTarget=l,E8(d,s,void 0,i),i.currentTarget=null}function k_(i,s){s=(s&4)!==0;for(var l=0;l<i.length;l++){var d=i[l],g=d.event;d=d.listeners;e:{var y=void 0;if(s)for(var x=d.length-1;0<=x;x--){var O=d[x],L=O.instance,Y=O.currentTarget;if(O=O.listener,L!==y&&g.isPropagationStopped())break e;v_(g,O,Y),y=L}else for(x=0;x<d.length;x++){if(O=d[x],L=O.instance,Y=O.currentTarget,O=O.listener,L!==y&&g.isPropagationStopped())break e;v_(g,O,Y),y=L}}}if(jl)throw i=Wh,jl=!1,Wh=null,i}function pt(i,s){var l=s[wp];l===void 0&&(l=s[wp]=new Set);var d=i+"__bubble";l.has(d)||(N_(s,i,2,!1),l.add(d))}function Ep(i,s,l){var d=0;s&&(d|=4),N_(l,i,d,s)}var sc="_reactListening"+Math.random().toString(36).slice(2);function Vu(i){if(!i[sc]){i[sc]=!0,r.forEach(function(l){l!=="selectionchange"&&(TF.has(l)||Ep(l,!1,i),Ep(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[sc]||(s[sc]=!0,Ep("selectionchange",!1,s))}}function N_(i,s,l,d){switch(Jb(s)){case 1:var g=R8;break;case 4:g=L8;break;default:g=ep}l=g.bind(null,s,l,i),g=void 0,!Yh||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(g=!0),d?g!==void 0?i.addEventListener(s,l,{capture:!0,passive:g}):i.addEventListener(s,l,!0):g!==void 0?i.addEventListener(s,l,{passive:g}):i.addEventListener(s,l,!1)}function yp(i,s,l,d,g){var y=d;if((s&1)===0&&(s&2)===0&&d!==null)e:for(;;){if(d===null)return;var x=d.tag;if(x===3||x===4){var O=d.stateNode.containerInfo;if(O===g||O.nodeType===8&&O.parentNode===g)break;if(x===4)for(x=d.return;x!==null;){var L=x.tag;if((L===3||L===4)&&(L=x.stateNode.containerInfo,L===g||L.nodeType===8&&L.parentNode===g))return;x=x.return}for(;O!==null;){if(x=rs(O),x===null)return;if(L=x.tag,L===5||L===6){d=y=x;continue e}O=O.parentNode}}d=d.return}Lb(function(){var Y=y,se=$h(l),ce=[];e:{var ne=C_.get(i);if(ne!==void 0){var xe=rp,Ae=i;switch(i){case"keypress":if(Zl(l)===0)break e;case"keydown":case"keyup":xe=K8;break;case"focusin":Ae="focus",xe=op;break;case"focusout":Ae="blur",xe=op;break;case"beforeblur":case"afterblur":xe=op;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":xe=t_;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":xe=M8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":xe=J8;break;case __:case x_:case S_:xe=H8;break;case w_:xe=eF;break;case"scroll":xe=D8;break;case"wheel":xe=nF;break;case"copy":case"cut":case"paste":xe=j8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":xe=r_}var ve=(s&4)!==0,Rt=!ve&&i==="scroll",z=ve?ne!==null?ne+"Capture":null:ne;ve=[];for(var F=Y,$;F!==null;){$=F;var me=$.stateNode;if($.tag===5&&me!==null&&($=me,z!==null&&(me=Au(F,z),me!=null&&ve.push(qu(F,me,$)))),Rt)break;F=F.return}0<ve.length&&(ne=new xe(ne,Ae,null,l,se),ce.push({event:ne,listeners:ve}))}}if((s&7)===0){e:{if(ne=i==="mouseover"||i==="pointerover",xe=i==="mouseout"||i==="pointerout",ne&&l!==Fn&&(Ae=l.relatedTarget||l.fromElement)&&(rs(Ae)||Ae[ei]))break e;if((xe||ne)&&(ne=se.window===se?se:(ne=se.ownerDocument)?ne.defaultView||ne.parentWindow:window,xe?(Ae=l.relatedTarget||l.toElement,xe=Y,Ae=Ae?rs(Ae):null,Ae!==null&&(Rt=ns(Ae),Ae!==Rt||Ae.tag!==5&&Ae.tag!==6)&&(Ae=null)):(xe=null,Ae=Y),xe!==Ae)){if(ve=t_,me="onMouseLeave",z="onMouseEnter",F="mouse",(i==="pointerout"||i==="pointerover")&&(ve=r_,me="onPointerLeave",z="onPointerEnter",F="pointer"),Rt=xe==null?ne:fo(xe),$=Ae==null?ne:fo(Ae),ne=new ve(me,F+"leave",xe,l,se),ne.target=Rt,ne.relatedTarget=$,me=null,rs(se)===Y&&(ve=new ve(z,F+"enter",Ae,l,se),ve.target=$,ve.relatedTarget=Rt,me=ve),Rt=me,xe&&Ae)t:{for(ve=xe,z=Ae,F=0,$=ve;$;$=lo($))F++;for($=0,me=z;me;me=lo(me))$++;for(;0<F-$;)ve=lo(ve),F--;for(;0<$-F;)z=lo(z),$--;for(;F--;){if(ve===z||z!==null&&ve===z.alternate)break t;ve=lo(ve),z=lo(z)}ve=null}else ve=null;xe!==null&&O_(ce,ne,xe,ve,!1),Ae!==null&&Rt!==null&&O_(ce,Rt,Ae,ve,!0)}}e:{if(ne=Y?fo(Y):window,xe=ne.nodeName&&ne.nodeName.toLowerCase(),xe==="select"||xe==="input"&&ne.type==="file")var Ne=lF;else if(l_(ne))if(f_)Ne=hF;else{Ne=fF;var Le=cF}else(xe=ne.nodeName)&&xe.toLowerCase()==="input"&&(ne.type==="checkbox"||ne.type==="radio")&&(Ne=dF);if(Ne&&(Ne=Ne(i,Y))){c_(ce,Ne,l,se);break e}Le&&Le(i,ne,Y),i==="focusout"&&(Le=ne._wrapperState)&&Le.controlled&&ne.type==="number"&&Rr(ne,"number",ne.value)}switch(Le=Y?fo(Y):window,i){case"focusin":(l_(Le)||Le.contentEditable==="true")&&(uo=Le,dp=Y,ju=null);break;case"focusout":ju=dp=uo=null;break;case"mousedown":hp=!0;break;case"contextmenu":case"mouseup":case"dragend":hp=!1,T_(ce,l,se);break;case"selectionchange":if(gF)break;case"keydown":case"keyup":T_(ce,l,se)}var De;if(ap)e:{switch(i){case"compositionstart":var Ue="onCompositionStart";break e;case"compositionend":Ue="onCompositionEnd";break e;case"compositionupdate":Ue="onCompositionUpdate";break e}Ue=void 0}else oo?u_(i,l)&&(Ue="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(Ue="onCompositionStart");Ue&&(i_&&l.locale!=="ko"&&(oo||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&oo&&(De=Zb()):(Si=se,np="value"in Si?Si.value:Si.textContent,oo=!0)),Le=oc(Y,Ue),0<Le.length&&(Ue=new n_(Ue,i,null,l,se),ce.push({event:Ue,listeners:Le}),De?Ue.data=De:(De=a_(l),De!==null&&(Ue.data=De)))),(De=iF?sF(i,l):oF(i,l))&&(Y=oc(Y,"onBeforeInput"),0<Y.length&&(se=new n_("onBeforeInput","beforeinput",null,l,se),ce.push({event:se,listeners:Y}),se.data=De))}k_(ce,s)})}function qu(i,s,l){return{instance:i,listener:s,currentTarget:l}}function oc(i,s){for(var l=s+"Capture",d=[];i!==null;){var g=i,y=g.stateNode;g.tag===5&&y!==null&&(g=y,y=Au(i,l),y!=null&&d.unshift(qu(i,y,g)),y=Au(i,s),y!=null&&d.push(qu(i,y,g))),i=i.return}return d}function lo(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function O_(i,s,l,d,g){for(var y=s._reactName,x=[];l!==null&&l!==d;){var O=l,L=O.alternate,Y=O.stateNode;if(L!==null&&L===d)break;O.tag===5&&Y!==null&&(O=Y,g?(L=Au(l,y),L!=null&&x.unshift(qu(l,L,O))):g||(L=Au(l,y),L!=null&&x.push(qu(l,L,O)))),l=l.return}x.length!==0&&i.push({event:s,listeners:x})}var bF=/\r\n?/g,_F=/\u0000|\uFFFD/g;function I_(i){return(typeof i=="string"?i:""+i).replace(bF,`
12
+ `).replace(_F,"")}function uc(i,s,l){if(s=I_(s),I_(i)!==s&&l)throw Error(n(425))}function ac(){}var Tp=null,bp=null;function _p(i,s){return i==="textarea"||i==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}var xp=typeof setTimeout=="function"?setTimeout:void 0,xF=typeof clearTimeout=="function"?clearTimeout:void 0,P_=typeof Promise=="function"?Promise:void 0,SF=typeof queueMicrotask=="function"?queueMicrotask:typeof P_!="undefined"?function(i){return P_.resolve(null).then(i).catch(wF)}:xp;function wF(i){setTimeout(function(){throw i})}function Sp(i,s){var l=s,d=0;do{var g=l.nextSibling;if(i.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(d===0){i.removeChild(g),Du(s);return}d--}else l!=="$"&&l!=="$?"&&l!=="$!"||d++;l=g}while(l);Du(s)}function Ci(i){for(;i!=null;i=i.nextSibling){var s=i.nodeType;if(s===1||s===3)break;if(s===8){if(s=i.data,s==="$"||s==="$!"||s==="$?")break;if(s==="/$")return null}}return i}function R_(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var l=i.data;if(l==="$"||l==="$!"||l==="$?"){if(s===0)return i;s--}else l==="/$"&&s++}i=i.previousSibling}return null}var co=Math.random().toString(36).slice(2),Fr="__reactFiber$"+co,Yu="__reactProps$"+co,ei="__reactContainer$"+co,wp="__reactEvents$"+co,CF="__reactListeners$"+co,AF="__reactHandles$"+co;function rs(i){var s=i[Fr];if(s)return s;for(var l=i.parentNode;l;){if(s=l[ei]||l[Fr]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=R_(i);i!==null;){if(l=i[Fr])return l;i=R_(i)}return s}i=l,l=i.parentNode}return null}function Wu(i){return i=i[Fr]||i[ei],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function fo(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function lc(i){return i[Yu]||null}var Cp=[],ho=-1;function Ai(i){return{current:i}}function mt(i){0>ho||(i.current=Cp[ho],Cp[ho]=null,ho--)}function ht(i,s){ho++,Cp[ho]=i.current,i.current=s}var vi={},un=Ai(vi),wn=Ai(!1),is=vi;function po(i,s){var l=i.type.contextTypes;if(!l)return vi;var d=i.stateNode;if(d&&d.__reactInternalMemoizedUnmaskedChildContext===s)return d.__reactInternalMemoizedMaskedChildContext;var g={},y;for(y in l)g[y]=s[y];return d&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function Cn(i){return i=i.childContextTypes,i!=null}function cc(){mt(wn),mt(un)}function L_(i,s,l){if(un.current!==vi)throw Error(n(168));ht(un,s),ht(wn,l)}function D_(i,s,l){var d=i.stateNode;if(s=s.childContextTypes,typeof d.getChildContext!="function")return l;d=d.getChildContext();for(var g in d)if(!(g in s))throw Error(n(108,Ye(i)||"Unknown",g));return w({},l,d)}function fc(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||vi,is=un.current,ht(un,i),ht(wn,wn.current),!0}function F_(i,s,l){var d=i.stateNode;if(!d)throw Error(n(169));l?(i=D_(i,s,is),d.__reactInternalMemoizedMergedChildContext=i,mt(wn),mt(un),ht(un,i)):mt(wn),ht(wn,l)}var ti=null,dc=!1,Ap=!1;function M_(i){ti===null?ti=[i]:ti.push(i)}function vF(i){dc=!0,M_(i)}function ki(){if(!Ap&&ti!==null){Ap=!0;var i=0,s=ot;try{var l=ti;for(ot=1;i<l.length;i++){var d=l[i];do d=d(!0);while(d!==null)}ti=null,dc=!1}catch(g){throw ti!==null&&(ti=ti.slice(i+1)),Ub(Gh,ki),g}finally{ot=s,Ap=!1}}return null}var mo=[],go=0,hc=null,pc=0,Kn=[],Qn=0,ss=null,ni=1,ri="";function os(i,s){mo[go++]=pc,mo[go++]=hc,hc=i,pc=s}function B_(i,s,l){Kn[Qn++]=ni,Kn[Qn++]=ri,Kn[Qn++]=ss,ss=i;var d=ni;i=ri;var g=32-hr(d)-1;d&=~(1<<g),l+=1;var y=32-hr(s)+g;if(30<y){var x=g-g%5;y=(d&(1<<x)-1).toString(32),d>>=x,g-=x,ni=1<<32-hr(s)+g|l<<g|d,ri=y+i}else ni=1<<y|l<<g|d,ri=i}function vp(i){i.return!==null&&(os(i,1),B_(i,1,0))}function kp(i){for(;i===hc;)hc=mo[--go],mo[go]=null,pc=mo[--go],mo[go]=null;for(;i===ss;)ss=Kn[--Qn],Kn[Qn]=null,ri=Kn[--Qn],Kn[Qn]=null,ni=Kn[--Qn],Kn[Qn]=null}var Bn=null,Un=null,bt=!1,mr=null;function U_(i,s){var l=er(5,null,null,0);l.elementType="DELETED",l.stateNode=s,l.return=i,s=i.deletions,s===null?(i.deletions=[l],i.flags|=16):s.push(l)}function H_(i,s){switch(i.tag){case 5:var l=i.type;return s=s.nodeType!==1||l.toLowerCase()!==s.nodeName.toLowerCase()?null:s,s!==null?(i.stateNode=s,Bn=i,Un=Ci(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Bn=i,Un=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(l=ss!==null?{id:ni,overflow:ri}:null,i.memoizedState={dehydrated:s,treeContext:l,retryLane:1073741824},l=er(18,null,null,0),l.stateNode=s,l.return=i,i.child=l,Bn=i,Un=null,!0):!1;default:return!1}}function Np(i){return(i.mode&1)!==0&&(i.flags&128)===0}function Op(i){if(bt){var s=Un;if(s){var l=s;if(!H_(i,s)){if(Np(i))throw Error(n(418));s=Ci(l.nextSibling);var d=Bn;s&&H_(i,s)?U_(d,l):(i.flags=i.flags&-4097|2,bt=!1,Bn=i)}}else{if(Np(i))throw Error(n(418));i.flags=i.flags&-4097|2,bt=!1,Bn=i}}}function z_(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Bn=i}function mc(i){if(i!==Bn)return!1;if(!bt)return z_(i),bt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!_p(i.type,i.memoizedProps)),s&&(s=Un)){if(Np(i))throw j_(),Error(n(418));for(;s;)U_(i,s),s=Ci(s.nextSibling)}if(z_(i),i.tag===13){if(i=i.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(n(317));e:{for(i=i.nextSibling,s=0;i;){if(i.nodeType===8){var l=i.data;if(l==="/$"){if(s===0){Un=Ci(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}Un=null}}else Un=Bn?Ci(i.stateNode.nextSibling):null;return!0}function j_(){for(var i=Un;i;)i=Ci(i.nextSibling)}function Eo(){Un=Bn=null,bt=!1}function Ip(i){mr===null?mr=[i]:mr.push(i)}var kF=G.ReactCurrentBatchConfig;function Gu(i,s,l){if(i=l.ref,i!==null&&typeof i!="function"&&typeof i!="object"){if(l._owner){if(l=l._owner,l){if(l.tag!==1)throw Error(n(309));var d=l.stateNode}if(!d)throw Error(n(147,i));var g=d,y=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===y?s.ref:(s=function(x){var O=g.refs;x===null?delete O[y]:O[y]=x},s._stringRef=y,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function gc(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function $_(i){var s=i._init;return s(i._payload)}function V_(i){function s(z,F){if(i){var $=z.deletions;$===null?(z.deletions=[F],z.flags|=16):$.push(F)}}function l(z,F){if(!i)return null;for(;F!==null;)s(z,F),F=F.sibling;return null}function d(z,F){for(z=new Map;F!==null;)F.key!==null?z.set(F.key,F):z.set(F.index,F),F=F.sibling;return z}function g(z,F){return z=Fi(z,F),z.index=0,z.sibling=null,z}function y(z,F,$){return z.index=$,i?($=z.alternate,$!==null?($=$.index,$<F?(z.flags|=2,F):$):(z.flags|=2,F)):(z.flags|=1048576,F)}function x(z){return i&&z.alternate===null&&(z.flags|=2),z}function O(z,F,$,me){return F===null||F.tag!==6?(F=xm($,z.mode,me),F.return=z,F):(F=g(F,$),F.return=z,F)}function L(z,F,$,me){var Ne=$.type;return Ne===te?se(z,F,$.props.children,me,$.key):F!==null&&(F.elementType===Ne||typeof Ne=="object"&&Ne!==null&&Ne.$$typeof===we&&$_(Ne)===F.type)?(me=g(F,$.props),me.ref=Gu(z,F,$),me.return=z,me):(me=Hc($.type,$.key,$.props,null,z.mode,me),me.ref=Gu(z,F,$),me.return=z,me)}function Y(z,F,$,me){return F===null||F.tag!==4||F.stateNode.containerInfo!==$.containerInfo||F.stateNode.implementation!==$.implementation?(F=Sm($,z.mode,me),F.return=z,F):(F=g(F,$.children||[]),F.return=z,F)}function se(z,F,$,me,Ne){return F===null||F.tag!==7?(F=ps($,z.mode,me,Ne),F.return=z,F):(F=g(F,$),F.return=z,F)}function ce(z,F,$){if(typeof F=="string"&&F!==""||typeof F=="number")return F=xm(""+F,z.mode,$),F.return=z,F;if(typeof F=="object"&&F!==null){switch(F.$$typeof){case q:return $=Hc(F.type,F.key,F.props,null,z.mode,$),$.ref=Gu(z,null,F),$.return=z,$;case B:return F=Sm(F,z.mode,$),F.return=z,F;case we:var me=F._init;return ce(z,me(F._payload),$)}if(Wn(F)||ee(F))return F=ps(F,z.mode,$,null),F.return=z,F;gc(z,F)}return null}function ne(z,F,$,me){var Ne=F!==null?F.key:null;if(typeof $=="string"&&$!==""||typeof $=="number")return Ne!==null?null:O(z,F,""+$,me);if(typeof $=="object"&&$!==null){switch($.$$typeof){case q:return $.key===Ne?L(z,F,$,me):null;case B:return $.key===Ne?Y(z,F,$,me):null;case we:return Ne=$._init,ne(z,F,Ne($._payload),me)}if(Wn($)||ee($))return Ne!==null?null:se(z,F,$,me,null);gc(z,$)}return null}function xe(z,F,$,me,Ne){if(typeof me=="string"&&me!==""||typeof me=="number")return z=z.get($)||null,O(F,z,""+me,Ne);if(typeof me=="object"&&me!==null){switch(me.$$typeof){case q:return z=z.get(me.key===null?$:me.key)||null,L(F,z,me,Ne);case B:return z=z.get(me.key===null?$:me.key)||null,Y(F,z,me,Ne);case we:var Le=me._init;return xe(z,F,$,Le(me._payload),Ne)}if(Wn(me)||ee(me))return z=z.get($)||null,se(F,z,me,Ne,null);gc(F,me)}return null}function Ae(z,F,$,me){for(var Ne=null,Le=null,De=F,Ue=F=0,Kt=null;De!==null&&Ue<$.length;Ue++){De.index>Ue?(Kt=De,De=null):Kt=De.sibling;var nt=ne(z,De,$[Ue],me);if(nt===null){De===null&&(De=Kt);break}i&&De&&nt.alternate===null&&s(z,De),F=y(nt,F,Ue),Le===null?Ne=nt:Le.sibling=nt,Le=nt,De=Kt}if(Ue===$.length)return l(z,De),bt&&os(z,Ue),Ne;if(De===null){for(;Ue<$.length;Ue++)De=ce(z,$[Ue],me),De!==null&&(F=y(De,F,Ue),Le===null?Ne=De:Le.sibling=De,Le=De);return bt&&os(z,Ue),Ne}for(De=d(z,De);Ue<$.length;Ue++)Kt=xe(De,z,Ue,$[Ue],me),Kt!==null&&(i&&Kt.alternate!==null&&De.delete(Kt.key===null?Ue:Kt.key),F=y(Kt,F,Ue),Le===null?Ne=Kt:Le.sibling=Kt,Le=Kt);return i&&De.forEach(function(Mi){return s(z,Mi)}),bt&&os(z,Ue),Ne}function ve(z,F,$,me){var Ne=ee($);if(typeof Ne!="function")throw Error(n(150));if($=Ne.call($),$==null)throw Error(n(151));for(var Le=Ne=null,De=F,Ue=F=0,Kt=null,nt=$.next();De!==null&&!nt.done;Ue++,nt=$.next()){De.index>Ue?(Kt=De,De=null):Kt=De.sibling;var Mi=ne(z,De,nt.value,me);if(Mi===null){De===null&&(De=Kt);break}i&&De&&Mi.alternate===null&&s(z,De),F=y(Mi,F,Ue),Le===null?Ne=Mi:Le.sibling=Mi,Le=Mi,De=Kt}if(nt.done)return l(z,De),bt&&os(z,Ue),Ne;if(De===null){for(;!nt.done;Ue++,nt=$.next())nt=ce(z,nt.value,me),nt!==null&&(F=y(nt,F,Ue),Le===null?Ne=nt:Le.sibling=nt,Le=nt);return bt&&os(z,Ue),Ne}for(De=d(z,De);!nt.done;Ue++,nt=$.next())nt=xe(De,z,Ue,nt.value,me),nt!==null&&(i&&nt.alternate!==null&&De.delete(nt.key===null?Ue:nt.key),F=y(nt,F,Ue),Le===null?Ne=nt:Le.sibling=nt,Le=nt);return i&&De.forEach(function(uM){return s(z,uM)}),bt&&os(z,Ue),Ne}function Rt(z,F,$,me){if(typeof $=="object"&&$!==null&&$.type===te&&$.key===null&&($=$.props.children),typeof $=="object"&&$!==null){switch($.$$typeof){case q:e:{for(var Ne=$.key,Le=F;Le!==null;){if(Le.key===Ne){if(Ne=$.type,Ne===te){if(Le.tag===7){l(z,Le.sibling),F=g(Le,$.props.children),F.return=z,z=F;break e}}else if(Le.elementType===Ne||typeof Ne=="object"&&Ne!==null&&Ne.$$typeof===we&&$_(Ne)===Le.type){l(z,Le.sibling),F=g(Le,$.props),F.ref=Gu(z,Le,$),F.return=z,z=F;break e}l(z,Le);break}else s(z,Le);Le=Le.sibling}$.type===te?(F=ps($.props.children,z.mode,me,$.key),F.return=z,z=F):(me=Hc($.type,$.key,$.props,null,z.mode,me),me.ref=Gu(z,F,$),me.return=z,z=me)}return x(z);case B:e:{for(Le=$.key;F!==null;){if(F.key===Le)if(F.tag===4&&F.stateNode.containerInfo===$.containerInfo&&F.stateNode.implementation===$.implementation){l(z,F.sibling),F=g(F,$.children||[]),F.return=z,z=F;break e}else{l(z,F);break}else s(z,F);F=F.sibling}F=Sm($,z.mode,me),F.return=z,z=F}return x(z);case we:return Le=$._init,Rt(z,F,Le($._payload),me)}if(Wn($))return Ae(z,F,$,me);if(ee($))return ve(z,F,$,me);gc(z,$)}return typeof $=="string"&&$!==""||typeof $=="number"?($=""+$,F!==null&&F.tag===6?(l(z,F.sibling),F=g(F,$),F.return=z,z=F):(l(z,F),F=xm($,z.mode,me),F.return=z,z=F),x(z)):l(z,F)}return Rt}var yo=V_(!0),q_=V_(!1),Ec=Ai(null),yc=null,To=null,Pp=null;function Rp(){Pp=To=yc=null}function Lp(i){var s=Ec.current;mt(Ec),i._currentValue=s}function Dp(i,s,l){for(;i!==null;){var d=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,d!==null&&(d.childLanes|=s)):d!==null&&(d.childLanes&s)!==s&&(d.childLanes|=s),i===l)break;i=i.return}}function bo(i,s){yc=i,Pp=To=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(An=!0),i.firstContext=null)}function Xn(i){var s=i._currentValue;if(Pp!==i)if(i={context:i,memoizedValue:s,next:null},To===null){if(yc===null)throw Error(n(308));To=i,yc.dependencies={lanes:0,firstContext:i}}else To=To.next=i;return s}var us=null;function Fp(i){us===null?us=[i]:us.push(i)}function Y_(i,s,l,d){var g=s.interleaved;return g===null?(l.next=l,Fp(s)):(l.next=g.next,g.next=l),s.interleaved=l,ii(i,d)}function ii(i,s){i.lanes|=s;var l=i.alternate;for(l!==null&&(l.lanes|=s),l=i,i=i.return;i!==null;)i.childLanes|=s,l=i.alternate,l!==null&&(l.childLanes|=s),l=i,i=i.return;return l.tag===3?l.stateNode:null}var Ni=!1;function Mp(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function W_(i,s){i=i.updateQueue,s.updateQueue===i&&(s.updateQueue={baseState:i.baseState,firstBaseUpdate:i.firstBaseUpdate,lastBaseUpdate:i.lastBaseUpdate,shared:i.shared,effects:i.effects})}function si(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function Oi(i,s,l){var d=i.updateQueue;if(d===null)return null;if(d=d.shared,(et&2)!==0){var g=d.pending;return g===null?s.next=s:(s.next=g.next,g.next=s),d.pending=s,ii(i,l)}return g=d.interleaved,g===null?(s.next=s,Fp(d)):(s.next=g.next,g.next=s),d.interleaved=s,ii(i,l)}function Tc(i,s,l){if(s=s.updateQueue,s!==null&&(s=s.shared,(l&4194240)!==0)){var d=s.lanes;d&=i.pendingLanes,l|=d,s.lanes=l,Xh(i,l)}}function G_(i,s){var l=i.updateQueue,d=i.alternate;if(d!==null&&(d=d.updateQueue,l===d)){var g=null,y=null;if(l=l.firstBaseUpdate,l!==null){do{var x={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};y===null?g=y=x:y=y.next=x,l=l.next}while(l!==null);y===null?g=y=s:y=y.next=s}else g=y=s;l={baseState:d.baseState,firstBaseUpdate:g,lastBaseUpdate:y,shared:d.shared,effects:d.effects},i.updateQueue=l;return}i=l.lastBaseUpdate,i===null?l.firstBaseUpdate=s:i.next=s,l.lastBaseUpdate=s}function bc(i,s,l,d){var g=i.updateQueue;Ni=!1;var y=g.firstBaseUpdate,x=g.lastBaseUpdate,O=g.shared.pending;if(O!==null){g.shared.pending=null;var L=O,Y=L.next;L.next=null,x===null?y=Y:x.next=Y,x=L;var se=i.alternate;se!==null&&(se=se.updateQueue,O=se.lastBaseUpdate,O!==x&&(O===null?se.firstBaseUpdate=Y:O.next=Y,se.lastBaseUpdate=L))}if(y!==null){var ce=g.baseState;x=0,se=Y=L=null,O=y;do{var ne=O.lane,xe=O.eventTime;if((d&ne)===ne){se!==null&&(se=se.next={eventTime:xe,lane:0,tag:O.tag,payload:O.payload,callback:O.callback,next:null});e:{var Ae=i,ve=O;switch(ne=s,xe=l,ve.tag){case 1:if(Ae=ve.payload,typeof Ae=="function"){ce=Ae.call(xe,ce,ne);break e}ce=Ae;break e;case 3:Ae.flags=Ae.flags&-65537|128;case 0:if(Ae=ve.payload,ne=typeof Ae=="function"?Ae.call(xe,ce,ne):Ae,ne==null)break e;ce=w({},ce,ne);break e;case 2:Ni=!0}}O.callback!==null&&O.lane!==0&&(i.flags|=64,ne=g.effects,ne===null?g.effects=[O]:ne.push(O))}else xe={eventTime:xe,lane:ne,tag:O.tag,payload:O.payload,callback:O.callback,next:null},se===null?(Y=se=xe,L=ce):se=se.next=xe,x|=ne;if(O=O.next,O===null){if(O=g.shared.pending,O===null)break;ne=O,O=ne.next,ne.next=null,g.lastBaseUpdate=ne,g.shared.pending=null}}while(!0);if(se===null&&(L=ce),g.baseState=L,g.firstBaseUpdate=Y,g.lastBaseUpdate=se,s=g.shared.interleaved,s!==null){g=s;do x|=g.lane,g=g.next;while(g!==s)}else y===null&&(g.shared.lanes=0);cs|=x,i.lanes=x,i.memoizedState=ce}}function K_(i,s,l){if(i=s.effects,s.effects=null,i!==null)for(s=0;s<i.length;s++){var d=i[s],g=d.callback;if(g!==null){if(d.callback=null,d=l,typeof g!="function")throw Error(n(191,g));g.call(d)}}}var Ku={},Mr=Ai(Ku),Qu=Ai(Ku),Xu=Ai(Ku);function as(i){if(i===Ku)throw Error(n(174));return i}function Bp(i,s){switch(ht(Xu,s),ht(Qu,i),ht(Mr,Ku),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:Ee(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=Ee(s,i)}mt(Mr),ht(Mr,s)}function _o(){mt(Mr),mt(Qu),mt(Xu)}function Q_(i){as(Xu.current);var s=as(Mr.current),l=Ee(s,i.type);s!==l&&(ht(Qu,i),ht(Mr,l))}function Up(i){Qu.current===i&&(mt(Mr),mt(Qu))}var wt=Ai(0);function _c(i){for(var s=i;s!==null;){if(s.tag===13){var l=s.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||l.data==="$!"))return s}else if(s.tag===19&&s.memoizedProps.revealOrder!==void 0){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var Hp=[];function zp(){for(var i=0;i<Hp.length;i++)Hp[i]._workInProgressVersionPrimary=null;Hp.length=0}var xc=G.ReactCurrentDispatcher,jp=G.ReactCurrentBatchConfig,ls=0,Ct=null,Bt=null,Wt=null,Sc=!1,Ju=!1,Zu=0,NF=0;function an(){throw Error(n(321))}function $p(i,s){if(s===null)return!1;for(var l=0;l<s.length&&l<i.length;l++)if(!pr(i[l],s[l]))return!1;return!0}function Vp(i,s,l,d,g,y){if(ls=y,Ct=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,xc.current=i===null||i.memoizedState===null?RF:LF,i=l(d,g),Ju){y=0;do{if(Ju=!1,Zu=0,25<=y)throw Error(n(301));y+=1,Wt=Bt=null,s.updateQueue=null,xc.current=DF,i=l(d,g)}while(Ju)}if(xc.current=Ac,s=Bt!==null&&Bt.next!==null,ls=0,Wt=Bt=Ct=null,Sc=!1,s)throw Error(n(300));return i}function qp(){var i=Zu!==0;return Zu=0,i}function Br(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Wt===null?Ct.memoizedState=Wt=i:Wt=Wt.next=i,Wt}function Jn(){if(Bt===null){var i=Ct.alternate;i=i!==null?i.memoizedState:null}else i=Bt.next;var s=Wt===null?Ct.memoizedState:Wt.next;if(s!==null)Wt=s,Bt=i;else{if(i===null)throw Error(n(310));Bt=i,i={memoizedState:Bt.memoizedState,baseState:Bt.baseState,baseQueue:Bt.baseQueue,queue:Bt.queue,next:null},Wt===null?Ct.memoizedState=Wt=i:Wt=Wt.next=i}return Wt}function ea(i,s){return typeof s=="function"?s(i):s}function Yp(i){var s=Jn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var d=Bt,g=d.baseQueue,y=l.pending;if(y!==null){if(g!==null){var x=g.next;g.next=y.next,y.next=x}d.baseQueue=g=y,l.pending=null}if(g!==null){y=g.next,d=d.baseState;var O=x=null,L=null,Y=y;do{var se=Y.lane;if((ls&se)===se)L!==null&&(L=L.next={lane:0,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null}),d=Y.hasEagerState?Y.eagerState:i(d,Y.action);else{var ce={lane:se,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null};L===null?(O=L=ce,x=d):L=L.next=ce,Ct.lanes|=se,cs|=se}Y=Y.next}while(Y!==null&&Y!==y);L===null?x=d:L.next=O,pr(d,s.memoizedState)||(An=!0),s.memoizedState=d,s.baseState=x,s.baseQueue=L,l.lastRenderedState=d}if(i=l.interleaved,i!==null){g=i;do y=g.lane,Ct.lanes|=y,cs|=y,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function Wp(i){var s=Jn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var d=l.dispatch,g=l.pending,y=s.memoizedState;if(g!==null){l.pending=null;var x=g=g.next;do y=i(y,x.action),x=x.next;while(x!==g);pr(y,s.memoizedState)||(An=!0),s.memoizedState=y,s.baseQueue===null&&(s.baseState=y),l.lastRenderedState=y}return[y,d]}function X_(){}function J_(i,s){var l=Ct,d=Jn(),g=s(),y=!pr(d.memoizedState,g);if(y&&(d.memoizedState=g,An=!0),d=d.queue,Gp(t2.bind(null,l,d,i),[i]),d.getSnapshot!==s||y||Wt!==null&&Wt.memoizedState.tag&1){if(l.flags|=2048,ta(9,e2.bind(null,l,d,g,s),void 0,null),Gt===null)throw Error(n(349));(ls&30)!==0||Z_(l,s,g)}return g}function Z_(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=Ct.updateQueue,s===null?(s={lastEffect:null,stores:null},Ct.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function e2(i,s,l,d){s.value=l,s.getSnapshot=d,n2(s)&&r2(i)}function t2(i,s,l){return l(function(){n2(s)&&r2(i)})}function n2(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!pr(i,l)}catch(d){return!0}}function r2(i){var s=ii(i,1);s!==null&&Tr(s,i,1,-1)}function i2(i){var s=Br();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:i},s.queue=i,i=i.dispatch=PF.bind(null,Ct,i),[s.memoizedState,i]}function ta(i,s,l,d){return i={tag:i,create:s,destroy:l,deps:d,next:null},s=Ct.updateQueue,s===null?(s={lastEffect:null,stores:null},Ct.updateQueue=s,s.lastEffect=i.next=i):(l=s.lastEffect,l===null?s.lastEffect=i.next=i:(d=l.next,l.next=i,i.next=d,s.lastEffect=i)),i}function s2(){return Jn().memoizedState}function wc(i,s,l,d){var g=Br();Ct.flags|=i,g.memoizedState=ta(1|s,l,void 0,d===void 0?null:d)}function Cc(i,s,l,d){var g=Jn();d=d===void 0?null:d;var y=void 0;if(Bt!==null){var x=Bt.memoizedState;if(y=x.destroy,d!==null&&$p(d,x.deps)){g.memoizedState=ta(s,l,y,d);return}}Ct.flags|=i,g.memoizedState=ta(1|s,l,y,d)}function o2(i,s){return wc(8390656,8,i,s)}function Gp(i,s){return Cc(2048,8,i,s)}function u2(i,s){return Cc(4,2,i,s)}function a2(i,s){return Cc(4,4,i,s)}function l2(i,s){if(typeof s=="function")return i=i(),s(i),function(){s(null)};if(s!=null)return i=i(),s.current=i,function(){s.current=null}}function c2(i,s,l){return l=l!=null?l.concat([i]):null,Cc(4,4,l2.bind(null,s,i),l)}function Kp(){}function f2(i,s){var l=Jn();s=s===void 0?null:s;var d=l.memoizedState;return d!==null&&s!==null&&$p(s,d[1])?d[0]:(l.memoizedState=[i,s],i)}function d2(i,s){var l=Jn();s=s===void 0?null:s;var d=l.memoizedState;return d!==null&&s!==null&&$p(s,d[1])?d[0]:(i=i(),l.memoizedState=[i,s],i)}function h2(i,s,l){return(ls&21)===0?(i.baseState&&(i.baseState=!1,An=!0),i.memoizedState=l):(pr(l,s)||(l=$b(),Ct.lanes|=l,cs|=l,i.baseState=!0),s)}function OF(i,s){var l=ot;ot=l!==0&&4>l?l:4,i(!0);var d=jp.transition;jp.transition={};try{i(!1),s()}finally{ot=l,jp.transition=d}}function p2(){return Jn().memoizedState}function IF(i,s,l){var d=Li(i);if(l={lane:d,action:l,hasEagerState:!1,eagerState:null,next:null},m2(i))g2(s,l);else if(l=Y_(i,s,l,d),l!==null){var g=pn();Tr(l,i,d,g),E2(l,s,d)}}function PF(i,s,l){var d=Li(i),g={lane:d,action:l,hasEagerState:!1,eagerState:null,next:null};if(m2(i))g2(s,g);else{var y=i.alternate;if(i.lanes===0&&(y===null||y.lanes===0)&&(y=s.lastRenderedReducer,y!==null))try{var x=s.lastRenderedState,O=y(x,l);if(g.hasEagerState=!0,g.eagerState=O,pr(O,x)){var L=s.interleaved;L===null?(g.next=g,Fp(s)):(g.next=L.next,L.next=g),s.interleaved=g;return}}catch(Y){}finally{}l=Y_(i,s,g,d),l!==null&&(g=pn(),Tr(l,i,d,g),E2(l,s,d))}}function m2(i){var s=i.alternate;return i===Ct||s!==null&&s===Ct}function g2(i,s){Ju=Sc=!0;var l=i.pending;l===null?s.next=s:(s.next=l.next,l.next=s),i.pending=s}function E2(i,s,l){if((l&4194240)!==0){var d=s.lanes;d&=i.pendingLanes,l|=d,s.lanes=l,Xh(i,l)}}var Ac={readContext:Xn,useCallback:an,useContext:an,useEffect:an,useImperativeHandle:an,useInsertionEffect:an,useLayoutEffect:an,useMemo:an,useReducer:an,useRef:an,useState:an,useDebugValue:an,useDeferredValue:an,useTransition:an,useMutableSource:an,useSyncExternalStore:an,useId:an,unstable_isNewReconciler:!1},RF={readContext:Xn,useCallback:function(i,s){return Br().memoizedState=[i,s===void 0?null:s],i},useContext:Xn,useEffect:o2,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,wc(4194308,4,l2.bind(null,s,i),l)},useLayoutEffect:function(i,s){return wc(4194308,4,i,s)},useInsertionEffect:function(i,s){return wc(4,2,i,s)},useMemo:function(i,s){var l=Br();return s=s===void 0?null:s,i=i(),l.memoizedState=[i,s],i},useReducer:function(i,s,l){var d=Br();return s=l!==void 0?l(s):s,d.memoizedState=d.baseState=s,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:i,lastRenderedState:s},d.queue=i,i=i.dispatch=IF.bind(null,Ct,i),[d.memoizedState,i]},useRef:function(i){var s=Br();return i={current:i},s.memoizedState=i},useState:i2,useDebugValue:Kp,useDeferredValue:function(i){return Br().memoizedState=i},useTransition:function(){var i=i2(!1),s=i[0];return i=OF.bind(null,i[1]),Br().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var d=Ct,g=Br();if(bt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Gt===null)throw Error(n(349));(ls&30)!==0||Z_(d,s,l)}g.memoizedState=l;var y={value:l,getSnapshot:s};return g.queue=y,o2(t2.bind(null,d,y,i),[i]),d.flags|=2048,ta(9,e2.bind(null,d,y,l,s),void 0,null),l},useId:function(){var i=Br(),s=Gt.identifierPrefix;if(bt){var l=ri,d=ni;l=(d&~(1<<32-hr(d)-1)).toString(32)+l,s=":"+s+"R"+l,l=Zu++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=NF++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},LF={readContext:Xn,useCallback:f2,useContext:Xn,useEffect:Gp,useImperativeHandle:c2,useInsertionEffect:u2,useLayoutEffect:a2,useMemo:d2,useReducer:Yp,useRef:s2,useState:function(){return Yp(ea)},useDebugValue:Kp,useDeferredValue:function(i){var s=Jn();return h2(s,Bt.memoizedState,i)},useTransition:function(){var i=Yp(ea)[0],s=Jn().memoizedState;return[i,s]},useMutableSource:X_,useSyncExternalStore:J_,useId:p2,unstable_isNewReconciler:!1},DF={readContext:Xn,useCallback:f2,useContext:Xn,useEffect:Gp,useImperativeHandle:c2,useInsertionEffect:u2,useLayoutEffect:a2,useMemo:d2,useReducer:Wp,useRef:s2,useState:function(){return Wp(ea)},useDebugValue:Kp,useDeferredValue:function(i){var s=Jn();return Bt===null?s.memoizedState=i:h2(s,Bt.memoizedState,i)},useTransition:function(){var i=Wp(ea)[0],s=Jn().memoizedState;return[i,s]},useMutableSource:X_,useSyncExternalStore:J_,useId:p2,unstable_isNewReconciler:!1};function gr(i,s){if(i&&i.defaultProps){s=w({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function Qp(i,s,l,d){s=i.memoizedState,l=l(d,s),l=l==null?s:w({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var vc={isMounted:function(i){return(i=i._reactInternals)?ns(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var d=pn(),g=Li(i),y=si(d,g);y.payload=s,l!=null&&(y.callback=l),s=Oi(i,y,g),s!==null&&(Tr(s,i,g,d),Tc(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var d=pn(),g=Li(i),y=si(d,g);y.tag=1,y.payload=s,l!=null&&(y.callback=l),s=Oi(i,y,g),s!==null&&(Tr(s,i,g,d),Tc(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=pn(),d=Li(i),g=si(l,d);g.tag=2,s!=null&&(g.callback=s),s=Oi(i,g,d),s!==null&&(Tr(s,i,d,l),Tc(s,i,d))}};function y2(i,s,l,d,g,y,x){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(d,y,x):s.prototype&&s.prototype.isPureReactComponent?!zu(l,d)||!zu(g,y):!0}function T2(i,s,l){var d=!1,g=vi,y=s.contextType;return typeof y=="object"&&y!==null?y=Xn(y):(g=Cn(s)?is:un.current,d=s.contextTypes,y=(d=d!=null)?po(i,g):vi),s=new s(l,y),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=vc,i.stateNode=s,s._reactInternals=i,d&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=y),s}function b2(i,s,l,d){i=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(l,d),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(l,d),s.state!==i&&vc.enqueueReplaceState(s,s.state,null)}function Xp(i,s,l,d){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},Mp(i);var y=s.contextType;typeof y=="object"&&y!==null?g.context=Xn(y):(y=Cn(s)?is:un.current,g.context=po(i,y)),g.state=i.memoizedState,y=s.getDerivedStateFromProps,typeof y=="function"&&(Qp(i,s,y,l),g.state=i.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(s=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),s!==g.state&&vc.enqueueReplaceState(g,g.state,null),bc(i,l,g,d),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function xo(i,s){try{var l="",d=s;do l+=Me(d),d=d.return;while(d);var g=l}catch(y){g=`
13
13
  Error generating stack: `+y.message+`
14
- `+y.stack}return{value:i,source:s,stack:g,digest:null}}function nm(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function rm(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var wF=typeof WeakMap=="function"?WeakMap:Map;function y2(i,s,l){l=ii(-1,l),l.tag=3,l.payload={element:null};var d=s.value;return l.callback=function(){Fc||(Fc=!0,ym=d),rm(i,s)},l}function T2(i,s,l){l=ii(-1,l),l.tag=3;var d=i.type.getDerivedStateFromError;if(typeof d=="function"){var g=s.value;l.payload=function(){return d(g)},l.callback=function(){rm(i,s)}}var y=i.stateNode;return y!==null&&typeof y.componentDidCatch=="function"&&(l.callback=function(){rm(i,s),typeof d!="function"&&(Pi===null?Pi=new Set([this]):Pi.add(this));var x=s.stack;this.componentDidCatch(s.value,{componentStack:x!==null?x:""})}),l}function b2(i,s,l){var d=i.pingCache;if(d===null){d=i.pingCache=new wF;var g=new Set;d.set(s,g)}else g=d.get(s),g===void 0&&(g=new Set,d.set(s,g));g.has(l)||(g.add(l),i=BF.bind(null,i,s,l),s.then(i,i))}function _2(i){do{var s;if((s=i.tag===13)&&(s=i.memoizedState,s=s!==null?s.dehydrated!==null:!0),s)return i;i=i.return}while(i!==null);return null}function x2(i,s,l,d,g){return(i.mode&1)===0?(i===s?i.flags|=65536:(i.flags|=128,l.flags|=131072,l.flags&=-52805,l.tag===1&&(l.alternate===null?l.tag=17:(s=ii(-1,1),s.tag=2,Oi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var CF=G.ReactCurrentOwner,kn=!1;function mn(i,s,l,d){s.child=i===null?j_(s,null,l,d):bo(s,i.child,l,d)}function S2(i,s,l,d,g){l=l.render;var y=s.ref;return xo(s,g),d=Gp(i,s,l,d,y,g),l=Kp(),i!==null&&!kn?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,si(i,s,g)):(bt&&l&&Ip(s),s.flags|=1,mn(i,s,d,g),s.child)}function w2(i,s,l,d,g){if(i===null){var y=l.type;return typeof y=="function"&&!Cm(y)&&y.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=y,C2(i,s,y,d,g)):(i=jc(l.type,null,d,s,s.mode,g),i.ref=s.ref,i.return=s,s.child=i)}if(y=i.child,(i.lanes&g)===0){var x=y.memoizedProps;if(l=l.compare,l=l!==null?l:$u,l(x,d)&&i.ref===s.ref)return si(i,s,g)}return s.flags|=1,i=Fi(y,d),i.ref=s.ref,i.return=s,s.child=i}function C2(i,s,l,d,g){if(i!==null){var y=i.memoizedProps;if($u(y,d)&&i.ref===s.ref)if(kn=!1,s.pendingProps=d=y,(i.lanes&g)!==0)(i.flags&131072)!==0&&(kn=!0);else return s.lanes=i.lanes,si(i,s,g)}return im(i,s,l,d,g)}function A2(i,s,l){var d=s.pendingProps,g=d.children,y=i!==null?i.memoizedState:null;if(d.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},ct(Ao,jn),jn|=l;else{if((l&1073741824)===0)return i=y!==null?y.baseLanes|l:l,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,ct(Ao,jn),jn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},d=y!==null?y.baseLanes:l,ct(Ao,jn),jn|=d}else y!==null?(d=y.baseLanes|l,s.memoizedState=null):d=l,ct(Ao,jn),jn|=d;return mn(i,s,g,l),s.child}function v2(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function im(i,s,l,d,g){var y=vn(l)?is:an.current;return y=go(s,y),xo(s,g),l=Gp(i,s,l,d,y,g),d=Kp(),i!==null&&!kn?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,si(i,s,g)):(bt&&d&&Ip(s),s.flags|=1,mn(i,s,l,g),s.child)}function k2(i,s,l,d,g){if(vn(l)){var y=!0;hc(s)}else y=!1;if(xo(s,g),s.stateNode===null)Ic(i,s),g2(s,l,d),tm(s,l,d,g),d=!0;else if(i===null){var x=s.stateNode,O=s.memoizedProps;x.props=O;var L=x.context,Y=l.contextType;typeof Y=="object"&&Y!==null?Y=Jn(Y):(Y=vn(l)?is:an.current,Y=go(s,Y));var se=l.getDerivedStateFromProps,ce=typeof se=="function"||typeof x.getSnapshotBeforeUpdate=="function";ce||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(O!==d||L!==Y)&&E2(s,x,d,Y),Ni=!1;var ne=s.memoizedState;x.state=ne,xc(s,d,x,g),L=s.memoizedState,O!==d||ne!==L||An.current||Ni?(typeof se=="function"&&(em(s,l,se,d),L=s.memoizedState),(O=Ni||m2(s,l,O,d,ne,L,Y))?(ce||typeof x.UNSAFE_componentWillMount!="function"&&typeof x.componentWillMount!="function"||(typeof x.componentWillMount=="function"&&x.componentWillMount(),typeof x.UNSAFE_componentWillMount=="function"&&x.UNSAFE_componentWillMount()),typeof x.componentDidMount=="function"&&(s.flags|=4194308)):(typeof x.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=d,s.memoizedState=L),x.props=d,x.state=L,x.context=Y,d=O):(typeof x.componentDidMount=="function"&&(s.flags|=4194308),d=!1)}else{x=s.stateNode,V_(i,s),O=s.memoizedProps,Y=s.type===s.elementType?O:gr(s.type,O),x.props=Y,ce=s.pendingProps,ne=x.context,L=l.contextType,typeof L=="object"&&L!==null?L=Jn(L):(L=vn(l)?is:an.current,L=go(s,L));var xe=l.getDerivedStateFromProps;(se=typeof xe=="function"||typeof x.getSnapshotBeforeUpdate=="function")||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(O!==ce||ne!==L)&&E2(s,x,d,L),Ni=!1,ne=s.memoizedState,x.state=ne,xc(s,d,x,g);var Ae=s.memoizedState;O!==ce||ne!==Ae||An.current||Ni?(typeof xe=="function"&&(em(s,l,xe,d),Ae=s.memoizedState),(Y=Ni||m2(s,l,Y,d,ne,Ae,L)||!1)?(se||typeof x.UNSAFE_componentWillUpdate!="function"&&typeof x.componentWillUpdate!="function"||(typeof x.componentWillUpdate=="function"&&x.componentWillUpdate(d,Ae,L),typeof x.UNSAFE_componentWillUpdate=="function"&&x.UNSAFE_componentWillUpdate(d,Ae,L)),typeof x.componentDidUpdate=="function"&&(s.flags|=4),typeof x.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof x.componentDidUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=1024),s.memoizedProps=d,s.memoizedState=Ae),x.props=d,x.state=Ae,x.context=L,d=Y):(typeof x.componentDidUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=1024),d=!1)}return sm(i,s,l,d,y,g)}function sm(i,s,l,d,g,y){v2(i,s);var x=(s.flags&128)!==0;if(!d&&!x)return g&&R_(s,l,!1),si(i,s,y);d=s.stateNode,CF.current=s;var O=x&&typeof l.getDerivedStateFromError!="function"?null:d.render();return s.flags|=1,i!==null&&x?(s.child=bo(s,i.child,null,y),s.child=bo(s,null,O,y)):mn(i,s,O,y),s.memoizedState=d.state,g&&R_(s,l,!0),s.child}function N2(i){var s=i.stateNode;s.pendingContext?I_(i,s.pendingContext,s.pendingContext!==s.context):s.context&&I_(i,s.context,!1),jp(i,s.containerInfo)}function O2(i,s,l,d,g){return To(),Dp(g),s.flags|=256,mn(i,s,l,d),s.child}var om={dehydrated:null,treeContext:null,retryLane:0};function um(i){return{baseLanes:i,cachePool:null,transitions:null}}function I2(i,s,l){var d=s.pendingProps,g=wt.current,y=!1,x=(s.flags&128)!==0,O;if((O=x)||(O=i!==null&&i.memoizedState===null?!1:(g&2)!==0),O?(y=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(g|=1),ct(wt,g&1),i===null)return Lp(s),i=s.memoizedState,i!==null&&(i=i.dehydrated,i!==null)?((s.mode&1)===0?s.lanes=1:i.data==="$!"?s.lanes=8:s.lanes=1073741824,null):(x=d.children,i=d.fallback,y?(d=s.mode,y=s.child,x={mode:"hidden",children:x},(d&1)===0&&y!==null?(y.childLanes=0,y.pendingProps=x):y=$c(x,d,0,null),i=ps(i,d,l,null),y.return=s,i.return=s,y.sibling=i,s.child=y,s.child.memoizedState=um(l),s.memoizedState=om,i):am(s,x));if(g=i.memoizedState,g!==null&&(O=g.dehydrated,O!==null))return AF(i,s,x,d,O,g,l);if(y){y=d.fallback,x=s.mode,g=i.child,O=g.sibling;var L={mode:"hidden",children:d.children};return(x&1)===0&&s.child!==g?(d=s.child,d.childLanes=0,d.pendingProps=L,s.deletions=null):(d=Fi(g,L),d.subtreeFlags=g.subtreeFlags&14680064),O!==null?y=Fi(O,y):(y=ps(y,x,l,null),y.flags|=2),y.return=s,d.return=s,d.sibling=y,s.child=d,d=y,y=s.child,x=i.child.memoizedState,x=x===null?um(l):{baseLanes:x.baseLanes|l,cachePool:null,transitions:x.transitions},y.memoizedState=x,y.childLanes=i.childLanes&~l,s.memoizedState=om,d}return y=i.child,i=y.sibling,d=Fi(y,{mode:"visible",children:d.children}),(s.mode&1)===0&&(d.lanes=l),d.return=s,d.sibling=null,i!==null&&(l=s.deletions,l===null?(s.deletions=[i],s.flags|=16):l.push(i)),s.child=d,s.memoizedState=null,d}function am(i,s){return s=$c({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function Oc(i,s,l,d){return d!==null&&Dp(d),bo(s,i.child,null,l),i=am(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function AF(i,s,l,d,g,y,x){if(l)return s.flags&256?(s.flags&=-257,d=nm(Error(n(422))),Oc(i,s,x,d)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(y=d.fallback,g=s.mode,d=$c({mode:"visible",children:d.children},g,0,null),y=ps(y,g,x,null),y.flags|=2,d.return=s,y.return=s,d.sibling=y,s.child=d,(s.mode&1)!==0&&bo(s,i.child,null,x),s.child.memoizedState=um(x),s.memoizedState=om,y);if((s.mode&1)===0)return Oc(i,s,x,null);if(g.data==="$!"){if(d=g.nextSibling&&g.nextSibling.dataset,d)var O=d.dgst;return d=O,y=Error(n(419)),d=nm(y,d,void 0),Oc(i,s,x,d)}if(O=(x&i.childLanes)!==0,kn||O){if(d=Kt,d!==null){switch(x&-x){case 4:g=2;break;case 16:g=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:g=32;break;case 536870912:g=268435456;break;default:g=0}g=(g&(d.suspendedLanes|x))!==0?0:g,g!==0&&g!==y.retryLane&&(y.retryLane=g,ri(i,g),Tr(d,i,g,-1))}return wm(),d=nm(Error(n(421))),Oc(i,s,x,d)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=UF.bind(null,i),g._reactRetry=s,null):(i=y.treeContext,zn=Ci(g.nextSibling),Hn=s,bt=!0,mr=null,i!==null&&(Qn[Xn++]=ti,Qn[Xn++]=ni,Qn[Xn++]=ss,ti=i.id,ni=i.overflow,ss=s),s=am(s,d.children),s.flags|=4096,s)}function P2(i,s,l){i.lanes|=s;var d=i.alternate;d!==null&&(d.lanes|=s),Up(i.return,s,l)}function lm(i,s,l,d,g){var y=i.memoizedState;y===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:d,tail:l,tailMode:g}:(y.isBackwards=s,y.rendering=null,y.renderingStartTime=0,y.last=d,y.tail=l,y.tailMode=g)}function R2(i,s,l){var d=s.pendingProps,g=d.revealOrder,y=d.tail;if(mn(i,s,d.children,l),d=wt.current,(d&2)!==0)d=d&1|2,s.flags|=128;else{if(i!==null&&(i.flags&128)!==0)e:for(i=s.child;i!==null;){if(i.tag===13)i.memoizedState!==null&&P2(i,l,s);else if(i.tag===19)P2(i,l,s);else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===s)break e;for(;i.sibling===null;){if(i.return===null||i.return===s)break e;i=i.return}i.sibling.return=i.return,i=i.sibling}d&=1}if(ct(wt,d),(s.mode&1)===0)s.memoizedState=null;else switch(g){case"forwards":for(l=s.child,g=null;l!==null;)i=l.alternate,i!==null&&Sc(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),lm(s,!1,g,l,y);break;case"backwards":for(l=null,g=s.child,s.child=null;g!==null;){if(i=g.alternate,i!==null&&Sc(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}lm(s,!0,l,null,y);break;case"together":lm(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function Ic(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function si(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),cs|=s.lanes,(l&s.childLanes)===0)return null;if(i!==null&&s.child!==i.child)throw Error(n(153));if(s.child!==null){for(i=s.child,l=Fi(i,i.pendingProps),s.child=l,l.return=s;i.sibling!==null;)i=i.sibling,l=l.sibling=Fi(i,i.pendingProps),l.return=s;l.sibling=null}return s.child}function vF(i,s,l){switch(s.tag){case 3:N2(s),To();break;case 5:W_(s);break;case 1:vn(s.type)&&hc(s);break;case 4:jp(s,s.stateNode.containerInfo);break;case 10:var d=s.type._context,g=s.memoizedProps.value;ct(Tc,d._currentValue),d._currentValue=g;break;case 13:if(d=s.memoizedState,d!==null)return d.dehydrated!==null?(ct(wt,wt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?I2(i,s,l):(ct(wt,wt.current&1),i=si(i,s,l),i!==null?i.sibling:null);ct(wt,wt.current&1);break;case 19:if(d=(l&s.childLanes)!==0,(i.flags&128)!==0){if(d)return R2(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),ct(wt,wt.current),d)break;return null;case 22:case 23:return s.lanes=0,A2(i,s,l)}return si(i,s,l)}var L2,cm,D2,F2;L2=function(i,s){for(var l=s.child;l!==null;){if(l.tag===5||l.tag===6)i.appendChild(l.stateNode);else if(l.tag!==4&&l.child!==null){l.child.return=l,l=l.child;continue}if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return;l=l.return}l.sibling.return=l.return,l=l.sibling}},cm=function(){},D2=function(i,s,l,d){var g=i.memoizedProps;if(g!==d){i=s.stateNode,as(Fr.current);var y=null;switch(l){case"input":g=Tt(i,g),d=Tt(i,d),y=[];break;case"select":g=w({},g,{value:void 0}),d=w({},d,{value:void 0}),y=[];break;case"textarea":g=vu(i,g),d=vu(i,d),y=[];break;default:typeof g.onClick!="function"&&typeof d.onClick=="function"&&(i.onclick=cc)}Zt(l,d);var x;l=null;for(Y in g)if(!d.hasOwnProperty(Y)&&g.hasOwnProperty(Y)&&g[Y]!=null)if(Y==="style"){var O=g[Y];for(x in O)O.hasOwnProperty(x)&&(l||(l={}),l[x]="")}else Y!=="dangerouslySetInnerHTML"&&Y!=="children"&&Y!=="suppressContentEditableWarning"&&Y!=="suppressHydrationWarning"&&Y!=="autoFocus"&&(o.hasOwnProperty(Y)?y||(y=[]):(y=y||[]).push(Y,null));for(Y in d){var L=d[Y];if(O=g!=null?g[Y]:void 0,d.hasOwnProperty(Y)&&L!==O&&(L!=null||O!=null))if(Y==="style")if(O){for(x in O)!O.hasOwnProperty(x)||L&&L.hasOwnProperty(x)||(l||(l={}),l[x]="");for(x in L)L.hasOwnProperty(x)&&O[x]!==L[x]&&(l||(l={}),l[x]=L[x])}else l||(y||(y=[]),y.push(Y,l)),l=L;else Y==="dangerouslySetInnerHTML"?(L=L?L.__html:void 0,O=O?O.__html:void 0,L!=null&&O!==L&&(y=y||[]).push(Y,L)):Y==="children"?typeof L!="string"&&typeof L!="number"||(y=y||[]).push(Y,""+L):Y!=="suppressContentEditableWarning"&&Y!=="suppressHydrationWarning"&&(o.hasOwnProperty(Y)?(L!=null&&Y==="onScroll"&&dt("scroll",i),y||O===L||(y=[])):(y=y||[]).push(Y,L))}l&&(y=y||[]).push("style",l);var Y=y;(s.updateQueue=Y)&&(s.flags|=4)}},F2=function(i,s,l,d){l!==d&&(s.flags|=4)};function ia(i,s){if(!bt)switch(i.tailMode){case"hidden":s=i.tail;for(var l=null;s!==null;)s.alternate!==null&&(l=s),s=s.sibling;l===null?i.tail=null:l.sibling=null;break;case"collapsed":l=i.tail;for(var d=null;l!==null;)l.alternate!==null&&(d=l),l=l.sibling;d===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:d.sibling=null}}function cn(i){var s=i.alternate!==null&&i.alternate.child===i.child,l=0,d=0;if(s)for(var g=i.child;g!==null;)l|=g.lanes|g.childLanes,d|=g.subtreeFlags&14680064,d|=g.flags&14680064,g.return=i,g=g.sibling;else for(g=i.child;g!==null;)l|=g.lanes|g.childLanes,d|=g.subtreeFlags,d|=g.flags,g.return=i,g=g.sibling;return i.subtreeFlags|=d,i.childLanes=l,s}function kF(i,s,l){var d=s.pendingProps;switch(Pp(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return cn(s),null;case 1:return vn(s.type)&&dc(),cn(s),null;case 3:return d=s.stateNode,So(),ht(An),ht(an),qp(),d.pendingContext&&(d.context=d.pendingContext,d.pendingContext=null),(i===null||i.child===null)&&(Ec(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,mr!==null&&(_m(mr),mr=null))),cm(i,s),cn(s),null;case 5:$p(s);var g=as(Zu.current);if(l=s.type,i!==null&&s.stateNode!=null)D2(i,s,l,d,g),i.ref!==s.ref&&(s.flags|=512,s.flags|=2097152);else{if(!d){if(s.stateNode===null)throw Error(n(166));return cn(s),null}if(i=as(Fr.current),Ec(s)){d=s.stateNode,l=s.type;var y=s.memoizedProps;switch(d[Dr]=s,d[Gu]=y,i=(s.mode&1)!==0,l){case"dialog":dt("cancel",d),dt("close",d);break;case"iframe":case"object":case"embed":dt("load",d);break;case"video":case"audio":for(g=0;g<qu.length;g++)dt(qu[g],d);break;case"source":dt("error",d);break;case"img":case"image":case"link":dt("error",d),dt("load",d);break;case"details":dt("toggle",d);break;case"input":St(d,y),dt("invalid",d);break;case"select":d._wrapperState={wasMultiple:!!y.multiple},dt("invalid",d);break;case"textarea":Hl(d,y),dt("invalid",d)}Zt(l,y),g=null;for(var x in y)if(y.hasOwnProperty(x)){var O=y[x];x==="children"?typeof O=="string"?d.textContent!==O&&(y.suppressHydrationWarning!==!0&&lc(d.textContent,O,i),g=["children",O]):typeof O=="number"&&d.textContent!==""+O&&(y.suppressHydrationWarning!==!0&&lc(d.textContent,O,i),g=["children",""+O]):o.hasOwnProperty(x)&&O!=null&&x==="onScroll"&&dt("scroll",d)}switch(l){case"input":be(d),Rt(d,y,!0);break;case"textarea":be(d),jl(d);break;case"select":case"option":break;default:typeof y.onClick=="function"&&(d.onclick=cc)}d=g,s.updateQueue=d,d!==null&&(s.flags|=4)}else{x=g.nodeType===9?g:g.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=J(l)),i==="http://www.w3.org/1999/xhtml"?l==="script"?(i=x.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof d.is=="string"?i=x.createElement(l,{is:d.is}):(i=x.createElement(l),l==="select"&&(x=i,d.multiple?x.multiple=!0:d.size&&(x.size=d.size))):i=x.createElementNS(i,l),i[Dr]=s,i[Gu]=d,L2(i,s,!1,!1),s.stateNode=i;e:{switch(x=Rr(l,d),l){case"dialog":dt("cancel",i),dt("close",i),g=d;break;case"iframe":case"object":case"embed":dt("load",i),g=d;break;case"video":case"audio":for(g=0;g<qu.length;g++)dt(qu[g],i);g=d;break;case"source":dt("error",i),g=d;break;case"img":case"image":case"link":dt("error",i),dt("load",i),g=d;break;case"details":dt("toggle",i),g=d;break;case"input":St(i,d),g=Tt(i,d),dt("invalid",i);break;case"option":g=d;break;case"select":i._wrapperState={wasMultiple:!!d.multiple},g=w({},d,{value:void 0}),dt("invalid",i);break;case"textarea":Hl(i,d),g=vu(i,d),dt("invalid",i);break;default:g=d}Zt(l,g),O=g;for(y in O)if(O.hasOwnProperty(y)){var L=O[y];y==="style"?yi(i,L):y==="dangerouslySetInnerHTML"?(L=L?L.__html:void 0,L!=null&&We(i,L)):y==="children"?typeof L=="string"?(l!=="textarea"||L!=="")&&Ze(i,L):typeof L=="number"&&Ze(i,""+L):y!=="suppressContentEditableWarning"&&y!=="suppressHydrationWarning"&&y!=="autoFocus"&&(o.hasOwnProperty(y)?L!=null&&y==="onScroll"&&dt("scroll",i):L!=null&&D(i,y,L,x))}switch(l){case"input":be(i),Rt(i,d,!1);break;case"textarea":be(i),jl(i);break;case"option":d.value!=null&&i.setAttribute("value",""+Ve(d.value));break;case"select":i.multiple=!!d.multiple,y=d.value,y!=null?vt(i,!!d.multiple,y,!1):d.defaultValue!=null&&vt(i,!!d.multiple,d.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=cc)}switch(l){case"button":case"input":case"select":case"textarea":d=!!d.autoFocus;break e;case"img":d=!0;break e;default:d=!1}}d&&(s.flags|=4)}s.ref!==null&&(s.flags|=512,s.flags|=2097152)}return cn(s),null;case 6:if(i&&s.stateNode!=null)F2(i,s,i.memoizedProps,d);else{if(typeof d!="string"&&s.stateNode===null)throw Error(n(166));if(l=as(Zu.current),as(Fr.current),Ec(s)){if(d=s.stateNode,l=s.memoizedProps,d[Dr]=s,(y=d.nodeValue!==l)&&(i=Hn,i!==null))switch(i.tag){case 3:lc(d.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&lc(d.nodeValue,l,(i.mode&1)!==0)}y&&(s.flags|=4)}else d=(l.nodeType===9?l:l.ownerDocument).createTextNode(d),d[Dr]=s,s.stateNode=d}return cn(s),null;case 13:if(ht(wt),d=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(bt&&zn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)U_(),To(),s.flags|=98560,y=!1;else if(y=Ec(s),d!==null&&d.dehydrated!==null){if(i===null){if(!y)throw Error(n(318));if(y=s.memoizedState,y=y!==null?y.dehydrated:null,!y)throw Error(n(317));y[Dr]=s}else To(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;cn(s),y=!1}else mr!==null&&(_m(mr),mr=null),y=!0;if(!y)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=l,s):(d=d!==null,d!==(i!==null&&i.memoizedState!==null)&&d&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(wt.current&1)!==0?zt===0&&(zt=3):wm())),s.updateQueue!==null&&(s.flags|=4),cn(s),null);case 4:return So(),cm(i,s),i===null&&Yu(s.stateNode.containerInfo),cn(s),null;case 10:return Bp(s.type._context),cn(s),null;case 17:return vn(s.type)&&dc(),cn(s),null;case 19:if(ht(wt),y=s.memoizedState,y===null)return cn(s),null;if(d=(s.flags&128)!==0,x=y.rendering,x===null)if(d)ia(y,!1);else{if(zt!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(x=Sc(i),x!==null){for(s.flags|=128,ia(y,!1),d=x.updateQueue,d!==null&&(s.updateQueue=d,s.flags|=4),s.subtreeFlags=0,d=l,l=s.child;l!==null;)y=l,i=d,y.flags&=14680066,x=y.alternate,x===null?(y.childLanes=0,y.lanes=i,y.child=null,y.subtreeFlags=0,y.memoizedProps=null,y.memoizedState=null,y.updateQueue=null,y.dependencies=null,y.stateNode=null):(y.childLanes=x.childLanes,y.lanes=x.lanes,y.child=x.child,y.subtreeFlags=0,y.deletions=null,y.memoizedProps=x.memoizedProps,y.memoizedState=x.memoizedState,y.updateQueue=x.updateQueue,y.type=x.type,i=x.dependencies,y.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return ct(wt,wt.current&1|2),s.child}i=i.sibling}y.tail!==null&&Lt()>vo&&(s.flags|=128,d=!0,ia(y,!1),s.lanes=4194304)}else{if(!d)if(i=Sc(x),i!==null){if(s.flags|=128,d=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),ia(y,!0),y.tail===null&&y.tailMode==="hidden"&&!x.alternate&&!bt)return cn(s),null}else 2*Lt()-y.renderingStartTime>vo&&l!==1073741824&&(s.flags|=128,d=!0,ia(y,!1),s.lanes=4194304);y.isBackwards?(x.sibling=s.child,s.child=x):(l=y.last,l!==null?l.sibling=x:s.child=x,y.last=x)}return y.tail!==null?(s=y.tail,y.rendering=s,y.tail=s.sibling,y.renderingStartTime=Lt(),s.sibling=null,l=wt.current,ct(wt,d?l&1|2:l&1),s):(cn(s),null);case 22:case 23:return Sm(),d=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==d&&(s.flags|=8192),d&&(s.mode&1)!==0?(jn&1073741824)!==0&&(cn(s),s.subtreeFlags&6&&(s.flags|=8192)):cn(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function NF(i,s){switch(Pp(s),s.tag){case 1:return vn(s.type)&&dc(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return So(),ht(An),ht(an),qp(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return $p(s),null;case 13:if(ht(wt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));To()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ht(wt),null;case 4:return So(),null;case 10:return Bp(s.type._context),null;case 22:case 23:return Sm(),null;case 24:return null;default:return null}}var Pc=!1,fn=!1,OF=typeof WeakSet=="function"?WeakSet:Set,Ce=null;function Co(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(d){kt(i,s,d)}else l.current=null}function fm(i,s,l){try{l()}catch(d){kt(i,s,d)}}var M2=!1;function IF(i,s){if(Sp=Jl,i=m_(),mp(i)){if("selectionStart"in i)var l={start:i.selectionStart,end:i.selectionEnd};else e:{l=(l=i.ownerDocument)&&l.defaultView||window;var d=l.getSelection&&l.getSelection();if(d&&d.rangeCount!==0){l=d.anchorNode;var g=d.anchorOffset,y=d.focusNode;d=d.focusOffset;try{l.nodeType,y.nodeType}catch(me){l=null;break e}var x=0,O=-1,L=-1,Y=0,se=0,ce=i,ne=null;t:for(;;){for(var xe;ce!==l||g!==0&&ce.nodeType!==3||(O=x+g),ce!==y||d!==0&&ce.nodeType!==3||(L=x+d),ce.nodeType===3&&(x+=ce.nodeValue.length),(xe=ce.firstChild)!==null;)ne=ce,ce=xe;for(;;){if(ce===i)break t;if(ne===l&&++Y===g&&(O=x),ne===y&&++se===d&&(L=x),(xe=ce.nextSibling)!==null)break;ce=ne,ne=ce.parentNode}ce=xe}l=O===-1||L===-1?null:{start:O,end:L}}else l=null}l=l||{start:0,end:0}}else l=null;for(wp={focusedElem:i,selectionRange:l},Jl=!1,Ce=s;Ce!==null;)if(s=Ce,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,Ce=i;else for(;Ce!==null;){s=Ce;try{var Ae=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(Ae!==null){var ve=Ae.memoizedProps,Dt=Ae.memoizedState,z=s.stateNode,F=z.getSnapshotBeforeUpdate(s.elementType===s.type?ve:gr(s.type,ve),Dt);z.__reactInternalSnapshotBeforeUpdate=F}break;case 3:var $=s.stateNode.containerInfo;$.nodeType===1?$.textContent="":$.nodeType===9&&$.documentElement&&$.removeChild($.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(me){kt(s,s.return,me)}if(i=s.sibling,i!==null){i.return=s.return,Ce=i;break}Ce=s.return}return Ae=M2,M2=!1,Ae}function sa(i,s,l){var d=s.updateQueue;if(d=d!==null?d.lastEffect:null,d!==null){var g=d=d.next;do{if((g.tag&i)===i){var y=g.destroy;g.destroy=void 0,y!==void 0&&fm(s,l,y)}g=g.next}while(g!==d)}}function Rc(i,s){if(s=s.updateQueue,s=s!==null?s.lastEffect:null,s!==null){var l=s=s.next;do{if((l.tag&i)===i){var d=l.create;l.destroy=d()}l=l.next}while(l!==s)}}function dm(i){var s=i.ref;if(s!==null){var l=i.stateNode;switch(i.tag){case 5:i=l;break;default:i=l}typeof s=="function"?s(i):s.current=i}}function B2(i){var s=i.alternate;s!==null&&(i.alternate=null,B2(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[Dr],delete s[Gu],delete s[kp],delete s[hF],delete s[pF])),i.stateNode=null,i.return=null,i.dependencies=null,i.memoizedProps=null,i.memoizedState=null,i.pendingProps=null,i.stateNode=null,i.updateQueue=null}function U2(i){return i.tag===5||i.tag===3||i.tag===4}function H2(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||U2(i.return))return null;i=i.return}for(i.sibling.return=i.return,i=i.sibling;i.tag!==5&&i.tag!==6&&i.tag!==18;){if(i.flags&2||i.child===null||i.tag===4)continue e;i.child.return=i,i=i.child}if(!(i.flags&2))return i.stateNode}}function hm(i,s,l){var d=i.tag;if(d===5||d===6)i=i.stateNode,s?l.nodeType===8?l.parentNode.insertBefore(i,s):l.insertBefore(i,s):(l.nodeType===8?(s=l.parentNode,s.insertBefore(i,l)):(s=l,s.appendChild(i)),l=l._reactRootContainer,l!=null||s.onclick!==null||(s.onclick=cc));else if(d!==4&&(i=i.child,i!==null))for(hm(i,s,l),i=i.sibling;i!==null;)hm(i,s,l),i=i.sibling}function pm(i,s,l){var d=i.tag;if(d===5||d===6)i=i.stateNode,s?l.insertBefore(i,s):l.appendChild(i);else if(d!==4&&(i=i.child,i!==null))for(pm(i,s,l),i=i.sibling;i!==null;)pm(i,s,l),i=i.sibling}var en=null,Er=!1;function Ii(i,s,l){for(l=l.child;l!==null;)z2(i,s,l),l=l.sibling}function z2(i,s,l){if(Lr&&typeof Lr.onCommitFiberUnmount=="function")try{Lr.onCommitFiberUnmount(Yl,l)}catch(O){}switch(l.tag){case 5:fn||Co(l,s);case 6:var d=en,g=Er;en=null,Ii(i,s,l),en=d,Er=g,en!==null&&(Er?(i=en,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):en.removeChild(l.stateNode));break;case 18:en!==null&&(Er?(i=en,l=l.stateNode,i.nodeType===8?vp(i.parentNode,l):i.nodeType===1&&vp(i,l),Mu(i)):vp(en,l.stateNode));break;case 4:d=en,g=Er,en=l.stateNode.containerInfo,Er=!0,Ii(i,s,l),en=d,Er=g;break;case 0:case 11:case 14:case 15:if(!fn&&(d=l.updateQueue,d!==null&&(d=d.lastEffect,d!==null))){g=d=d.next;do{var y=g,x=y.destroy;y=y.tag,x!==void 0&&((y&2)!==0||(y&4)!==0)&&fm(l,s,x),g=g.next}while(g!==d)}Ii(i,s,l);break;case 1:if(!fn&&(Co(l,s),d=l.stateNode,typeof d.componentWillUnmount=="function"))try{d.props=l.memoizedProps,d.state=l.memoizedState,d.componentWillUnmount()}catch(O){kt(l,s,O)}Ii(i,s,l);break;case 21:Ii(i,s,l);break;case 22:l.mode&1?(fn=(d=fn)||l.memoizedState!==null,Ii(i,s,l),fn=d):Ii(i,s,l);break;default:Ii(i,s,l)}}function j2(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new OF),s.forEach(function(d){var g=HF.bind(null,i,d);l.has(d)||(l.add(d),d.then(g,g))})}}function yr(i,s){var l=s.deletions;if(l!==null)for(var d=0;d<l.length;d++){var g=l[d];try{var y=i,x=s,O=x;e:for(;O!==null;){switch(O.tag){case 5:en=O.stateNode,Er=!1;break e;case 3:en=O.stateNode.containerInfo,Er=!0;break e;case 4:en=O.stateNode.containerInfo,Er=!0;break e}O=O.return}if(en===null)throw Error(n(160));z2(y,x,g),en=null,Er=!1;var L=g.alternate;L!==null&&(L.return=null),g.return=null}catch(Y){kt(g,s,Y)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)$2(s,i),s=s.sibling}function $2(i,s){var l=i.alternate,d=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(yr(s,i),Br(i),d&4){try{sa(3,i,i.return),Rc(3,i)}catch(ve){kt(i,i.return,ve)}try{sa(5,i,i.return)}catch(ve){kt(i,i.return,ve)}}break;case 1:yr(s,i),Br(i),d&512&&l!==null&&Co(l,l.return);break;case 5:if(yr(s,i),Br(i),d&512&&l!==null&&Co(l,l.return),i.flags&32){var g=i.stateNode;try{Ze(g,"")}catch(ve){kt(i,i.return,ve)}}if(d&4&&(g=i.stateNode,g!=null)){var y=i.memoizedProps,x=l!==null?l.memoizedProps:y,O=i.type,L=i.updateQueue;if(i.updateQueue=null,L!==null)try{O==="input"&&y.type==="radio"&&y.name!=null&&un(g,y),Rr(O,x);var Y=Rr(O,y);for(x=0;x<L.length;x+=2){var se=L[x],ce=L[x+1];se==="style"?yi(g,ce):se==="dangerouslySetInnerHTML"?We(g,ce):se==="children"?Ze(g,ce):D(g,se,ce,Y)}switch(O){case"input":Wt(g,y);break;case"textarea":zl(g,y);break;case"select":var ne=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!y.multiple;var xe=y.value;xe!=null?vt(g,!!y.multiple,xe,!1):ne!==!!y.multiple&&(y.defaultValue!=null?vt(g,!!y.multiple,y.defaultValue,!0):vt(g,!!y.multiple,y.multiple?[]:"",!1))}g[Gu]=y}catch(ve){kt(i,i.return,ve)}}break;case 6:if(yr(s,i),Br(i),d&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,y=i.memoizedProps;try{g.nodeValue=y}catch(ve){kt(i,i.return,ve)}}break;case 3:if(yr(s,i),Br(i),d&4&&l!==null&&l.memoizedState.isDehydrated)try{Mu(s.containerInfo)}catch(ve){kt(i,i.return,ve)}break;case 4:yr(s,i),Br(i);break;case 13:yr(s,i),Br(i),g=i.child,g.flags&8192&&(y=g.memoizedState!==null,g.stateNode.isHidden=y,!y||g.alternate!==null&&g.alternate.memoizedState!==null||(Em=Lt())),d&4&&j2(i);break;case 22:if(se=l!==null&&l.memoizedState!==null,i.mode&1?(fn=(Y=fn)||se,yr(s,i),fn=Y):yr(s,i),Br(i),d&8192){if(Y=i.memoizedState!==null,(i.stateNode.isHidden=Y)&&!se&&(i.mode&1)!==0)for(Ce=i,se=i.child;se!==null;){for(ce=Ce=se;Ce!==null;){switch(ne=Ce,xe=ne.child,ne.tag){case 0:case 11:case 14:case 15:sa(4,ne,ne.return);break;case 1:Co(ne,ne.return);var Ae=ne.stateNode;if(typeof Ae.componentWillUnmount=="function"){d=ne,l=ne.return;try{s=d,Ae.props=s.memoizedProps,Ae.state=s.memoizedState,Ae.componentWillUnmount()}catch(ve){kt(d,l,ve)}}break;case 5:Co(ne,ne.return);break;case 22:if(ne.memoizedState!==null){Y2(ce);continue}}xe!==null?(xe.return=ne,Ce=xe):Y2(ce)}se=se.sibling}e:for(se=null,ce=i;;){if(ce.tag===5){if(se===null){se=ce;try{g=ce.stateNode,Y?(y=g.style,typeof y.setProperty=="function"?y.setProperty("display","none","important"):y.display="none"):(O=ce.stateNode,L=ce.memoizedProps.style,x=L!=null&&L.hasOwnProperty("display")?L.display:null,O.style.display=Kn("display",x))}catch(ve){kt(i,i.return,ve)}}}else if(ce.tag===6){if(se===null)try{ce.stateNode.nodeValue=Y?"":ce.memoizedProps}catch(ve){kt(i,i.return,ve)}}else if((ce.tag!==22&&ce.tag!==23||ce.memoizedState===null||ce===i)&&ce.child!==null){ce.child.return=ce,ce=ce.child;continue}if(ce===i)break e;for(;ce.sibling===null;){if(ce.return===null||ce.return===i)break e;se===ce&&(se=null),ce=ce.return}se===ce&&(se=null),ce.sibling.return=ce.return,ce=ce.sibling}}break;case 19:yr(s,i),Br(i),d&4&&j2(i);break;case 21:break;default:yr(s,i),Br(i)}}function Br(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(U2(l)){var d=l;break e}l=l.return}throw Error(n(160))}switch(d.tag){case 5:var g=d.stateNode;d.flags&32&&(Ze(g,""),d.flags&=-33);var y=H2(i);pm(i,y,g);break;case 3:case 4:var x=d.stateNode.containerInfo,O=H2(i);hm(i,O,x);break;default:throw Error(n(161))}}catch(L){kt(i,i.return,L)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function PF(i,s,l){Ce=i,V2(i)}function V2(i,s,l){for(var d=(i.mode&1)!==0;Ce!==null;){var g=Ce,y=g.child;if(g.tag===22&&d){var x=g.memoizedState!==null||Pc;if(!x){var O=g.alternate,L=O!==null&&O.memoizedState!==null||fn;O=Pc;var Y=fn;if(Pc=x,(fn=L)&&!Y)for(Ce=g;Ce!==null;)x=Ce,L=x.child,x.tag===22&&x.memoizedState!==null?W2(g):L!==null?(L.return=x,Ce=L):W2(g);for(;y!==null;)Ce=y,V2(y),y=y.sibling;Ce=g,Pc=O,fn=Y}q2(i)}else(g.subtreeFlags&8772)!==0&&y!==null?(y.return=g,Ce=y):q2(i)}}function q2(i){for(;Ce!==null;){var s=Ce;if((s.flags&8772)!==0){var l=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:fn||Rc(5,s);break;case 1:var d=s.stateNode;if(s.flags&4&&!fn)if(l===null)d.componentDidMount();else{var g=s.elementType===s.type?l.memoizedProps:gr(s.type,l.memoizedProps);d.componentDidUpdate(g,l.memoizedState,d.__reactInternalSnapshotBeforeUpdate)}var y=s.updateQueue;y!==null&&Y_(s,y,d);break;case 3:var x=s.updateQueue;if(x!==null){if(l=null,s.child!==null)switch(s.child.tag){case 5:l=s.child.stateNode;break;case 1:l=s.child.stateNode}Y_(s,x,l)}break;case 5:var O=s.stateNode;if(l===null&&s.flags&4){l=O;var L=s.memoizedProps;switch(s.type){case"button":case"input":case"select":case"textarea":L.autoFocus&&l.focus();break;case"img":L.src&&(l.src=L.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(s.memoizedState===null){var Y=s.alternate;if(Y!==null){var se=Y.memoizedState;if(se!==null){var ce=se.dehydrated;ce!==null&&Mu(ce)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}fn||s.flags&512&&dm(s)}catch(ne){kt(s,s.return,ne)}}if(s===i){Ce=null;break}if(l=s.sibling,l!==null){l.return=s.return,Ce=l;break}Ce=s.return}}function Y2(i){for(;Ce!==null;){var s=Ce;if(s===i){Ce=null;break}var l=s.sibling;if(l!==null){l.return=s.return,Ce=l;break}Ce=s.return}}function W2(i){for(;Ce!==null;){var s=Ce;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{Rc(4,s)}catch(L){kt(s,l,L)}break;case 1:var d=s.stateNode;if(typeof d.componentDidMount=="function"){var g=s.return;try{d.componentDidMount()}catch(L){kt(s,g,L)}}var y=s.return;try{dm(s)}catch(L){kt(s,y,L)}break;case 5:var x=s.return;try{dm(s)}catch(L){kt(s,x,L)}}}catch(L){kt(s,s.return,L)}if(s===i){Ce=null;break}var O=s.sibling;if(O!==null){O.return=s.return,Ce=O;break}Ce=s.return}}var RF=Math.ceil,Lc=G.ReactCurrentDispatcher,mm=G.ReactCurrentOwner,er=G.ReactCurrentBatchConfig,et=0,Kt=null,Ut=null,tn=0,jn=0,Ao=Ai(0),zt=0,oa=null,cs=0,Dc=0,gm=0,ua=null,Nn=null,Em=0,vo=1/0,oi=null,Fc=!1,ym=null,Pi=null,Mc=!1,Ri=null,Bc=0,aa=0,Tm=null,Uc=-1,Hc=0;function gn(){return(et&6)!==0?Lt():Uc!==-1?Uc:Uc=Lt()}function Li(i){return(i.mode&1)===0?1:(et&2)!==0&&tn!==0?tn&-tn:gF.transition!==null?(Hc===0&&(Hc=Hb()),Hc):(i=st,i!==0||(i=window.event,i=i===void 0?16:Kb(i.type)),i)}function Tr(i,s,l,d){if(50<aa)throw aa=0,Tm=null,Error(n(185));Pu(i,l,d),((et&2)===0||i!==Kt)&&(i===Kt&&((et&2)===0&&(Dc|=l),zt===4&&Di(i,tn)),On(i,d),l===1&&et===0&&(s.mode&1)===0&&(vo=Lt()+500,pc&&ki()))}function On(i,s){var l=i.callbackNode;g8(i,s);var d=Kl(i,i===Kt?tn:0);if(d===0)l!==null&&Mb(l),i.callbackNode=null,i.callbackPriority=0;else if(s=d&-d,i.callbackPriority!==s){if(l!=null&&Mb(l),s===1)i.tag===0?mF(K2.bind(null,i)):L_(K2.bind(null,i)),fF(function(){(et&6)===0&&ki()}),l=null;else{switch(zb(d)){case 1:l=Jh;break;case 4:l=Bb;break;case 16:l=ql;break;case 536870912:l=Ub;break;default:l=ql}l=rx(l,G2.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function G2(i,s){if(Uc=-1,Hc=0,(et&6)!==0)throw Error(n(327));var l=i.callbackNode;if(ko()&&i.callbackNode!==l)return null;var d=Kl(i,i===Kt?tn:0);if(d===0)return null;if((d&30)!==0||(d&i.expiredLanes)!==0||s)s=zc(i,d);else{s=d;var g=et;et|=2;var y=X2();(Kt!==i||tn!==s)&&(oi=null,vo=Lt()+500,ds(i,s));do try{FF();break}catch(O){Q2(i,O)}while(!0);Mp(),Lc.current=y,et=g,Ut!==null?s=0:(Kt=null,tn=0,s=zt)}if(s!==0){if(s===2&&(g=Zh(i),g!==0&&(d=g,s=bm(i,g))),s===1)throw l=oa,ds(i,0),Di(i,d),On(i,Lt()),l;if(s===6)Di(i,d);else{if(g=i.current.alternate,(d&30)===0&&!LF(g)&&(s=zc(i,d),s===2&&(y=Zh(i),y!==0&&(d=y,s=bm(i,y))),s===1))throw l=oa,ds(i,0),Di(i,d),On(i,Lt()),l;switch(i.finishedWork=g,i.finishedLanes=d,s){case 0:case 1:throw Error(n(345));case 2:hs(i,Nn,oi);break;case 3:if(Di(i,d),(d&130023424)===d&&(s=Em+500-Lt(),10<s)){if(Kl(i,0)!==0)break;if(g=i.suspendedLanes,(g&d)!==d){gn(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=Ap(hs.bind(null,i,Nn,oi),s);break}hs(i,Nn,oi);break;case 4:if(Di(i,d),(d&4194240)===d)break;for(s=i.eventTimes,g=-1;0<d;){var x=31-hr(d);y=1<<x,x=s[x],x>g&&(g=x),d&=~y}if(d=g,d=Lt()-d,d=(120>d?120:480>d?480:1080>d?1080:1920>d?1920:3e3>d?3e3:4320>d?4320:1960*RF(d/1960))-d,10<d){i.timeoutHandle=Ap(hs.bind(null,i,Nn,oi),d);break}hs(i,Nn,oi);break;case 5:hs(i,Nn,oi);break;default:throw Error(n(329))}}}return On(i,Lt()),i.callbackNode===l?G2.bind(null,i):null}function bm(i,s){var l=ua;return i.current.memoizedState.isDehydrated&&(ds(i,s).flags|=256),i=zc(i,s),i!==2&&(s=Nn,Nn=l,s!==null&&_m(s)),i}function _m(i){Nn===null?Nn=i:Nn.push.apply(Nn,i)}function LF(i){for(var s=i;;){if(s.flags&16384){var l=s.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var d=0;d<l.length;d++){var g=l[d],y=g.getSnapshot;g=g.value;try{if(!pr(y(),g))return!1}catch(x){return!1}}}if(l=s.child,s.subtreeFlags&16384&&l!==null)l.return=s,s=l;else{if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return!0;s=s.return}s.sibling.return=s.return,s=s.sibling}}return!0}function Di(i,s){for(s&=~gm,s&=~Dc,i.suspendedLanes|=s,i.pingedLanes&=~s,i=i.expirationTimes;0<s;){var l=31-hr(s),d=1<<l;i[l]=-1,s&=~d}}function K2(i){if((et&6)!==0)throw Error(n(327));ko();var s=Kl(i,0);if((s&1)===0)return On(i,Lt()),null;var l=zc(i,s);if(i.tag!==0&&l===2){var d=Zh(i);d!==0&&(s=d,l=bm(i,d))}if(l===1)throw l=oa,ds(i,0),Di(i,s),On(i,Lt()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,hs(i,Nn,oi),On(i,Lt()),null}function xm(i,s){var l=et;et|=1;try{return i(s)}finally{et=l,et===0&&(vo=Lt()+500,pc&&ki())}}function fs(i){Ri!==null&&Ri.tag===0&&(et&6)===0&&ko();var s=et;et|=1;var l=er.transition,d=st;try{if(er.transition=null,st=1,i)return i()}finally{st=d,er.transition=l,et=s,(et&6)===0&&ki()}}function Sm(){jn=Ao.current,ht(Ao)}function ds(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,cF(l)),Ut!==null)for(l=Ut.return;l!==null;){var d=l;switch(Pp(d),d.tag){case 1:d=d.type.childContextTypes,d!=null&&dc();break;case 3:So(),ht(An),ht(an),qp();break;case 5:$p(d);break;case 4:So();break;case 13:ht(wt);break;case 19:ht(wt);break;case 10:Bp(d.type._context);break;case 22:case 23:Sm()}l=l.return}if(Kt=i,Ut=i=Fi(i.current,null),tn=jn=s,zt=0,oa=null,gm=Dc=cs=0,Nn=ua=null,us!==null){for(s=0;s<us.length;s++)if(l=us[s],d=l.interleaved,d!==null){l.interleaved=null;var g=d.next,y=l.pending;if(y!==null){var x=y.next;y.next=g,d.next=x}l.pending=d}us=null}return i}function Q2(i,s){do{var l=Ut;try{if(Mp(),wc.current=kc,Cc){for(var d=Ct.memoizedState;d!==null;){var g=d.queue;g!==null&&(g.pending=null),d=d.next}Cc=!1}if(ls=0,Gt=Ht=Ct=null,ea=!1,ta=0,mm.current=null,l===null||l.return===null){zt=1,oa=s,Ut=null;break}e:{var y=i,x=l.return,O=l,L=s;if(s=tn,O.flags|=32768,L!==null&&typeof L=="object"&&typeof L.then=="function"){var Y=L,se=O,ce=se.tag;if((se.mode&1)===0&&(ce===0||ce===11||ce===15)){var ne=se.alternate;ne?(se.updateQueue=ne.updateQueue,se.memoizedState=ne.memoizedState,se.lanes=ne.lanes):(se.updateQueue=null,se.memoizedState=null)}var xe=_2(x);if(xe!==null){xe.flags&=-257,x2(xe,x,O,y,s),xe.mode&1&&b2(y,Y,s),s=xe,L=Y;var Ae=s.updateQueue;if(Ae===null){var ve=new Set;ve.add(L),s.updateQueue=ve}else Ae.add(L);break e}else{if((s&1)===0){b2(y,Y,s),wm();break e}L=Error(n(426))}}else if(bt&&O.mode&1){var Dt=_2(x);if(Dt!==null){(Dt.flags&65536)===0&&(Dt.flags|=256),x2(Dt,x,O,y,s),Dp(wo(L,O));break e}}y=L=wo(L,O),zt!==4&&(zt=2),ua===null?ua=[y]:ua.push(y),y=x;do{switch(y.tag){case 3:y.flags|=65536,s&=-s,y.lanes|=s;var z=y2(y,L,s);q_(y,z);break e;case 1:O=L;var F=y.type,$=y.stateNode;if((y.flags&128)===0&&(typeof F.getDerivedStateFromError=="function"||$!==null&&typeof $.componentDidCatch=="function"&&(Pi===null||!Pi.has($)))){y.flags|=65536,s&=-s,y.lanes|=s;var me=T2(y,O,s);q_(y,me);break e}}y=y.return}while(y!==null)}Z2(l)}catch(Ne){s=Ne,Ut===l&&l!==null&&(Ut=l=l.return);continue}break}while(!0)}function X2(){var i=Lc.current;return Lc.current=kc,i===null?kc:i}function wm(){(zt===0||zt===3||zt===2)&&(zt=4),Kt===null||(cs&268435455)===0&&(Dc&268435455)===0||Di(Kt,tn)}function zc(i,s){var l=et;et|=2;var d=X2();(Kt!==i||tn!==s)&&(oi=null,ds(i,s));do try{DF();break}catch(g){Q2(i,g)}while(!0);if(Mp(),et=l,Lc.current=d,Ut!==null)throw Error(n(261));return Kt=null,tn=0,zt}function DF(){for(;Ut!==null;)J2(Ut)}function FF(){for(;Ut!==null&&!u8();)J2(Ut)}function J2(i){var s=nx(i.alternate,i,jn);i.memoizedProps=i.pendingProps,s===null?Z2(i):Ut=s,mm.current=null}function Z2(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=kF(l,s,jn),l!==null){Ut=l;return}}else{if(l=NF(l,s),l!==null){l.flags&=32767,Ut=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{zt=6,Ut=null;return}}if(s=s.sibling,s!==null){Ut=s;return}Ut=s=i}while(s!==null);zt===0&&(zt=5)}function hs(i,s,l){var d=st,g=er.transition;try{er.transition=null,st=1,MF(i,s,l,d)}finally{er.transition=g,st=d}return null}function MF(i,s,l,d){do ko();while(Ri!==null);if((et&6)!==0)throw Error(n(327));l=i.finishedWork;var g=i.finishedLanes;if(l===null)return null;if(i.finishedWork=null,i.finishedLanes=0,l===i.current)throw Error(n(177));i.callbackNode=null,i.callbackPriority=0;var y=l.lanes|l.childLanes;if(E8(i,y),i===Kt&&(Ut=Kt=null,tn=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||Mc||(Mc=!0,rx(ql,function(){return ko(),null})),y=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||y){y=er.transition,er.transition=null;var x=st;st=1;var O=et;et|=4,mm.current=null,IF(i,l),$2(l,i),rF(wp),Jl=!!Sp,wp=Sp=null,i.current=l,PF(l),a8(),et=O,st=x,er.transition=y}else i.current=l;if(Mc&&(Mc=!1,Ri=i,Bc=g),y=i.pendingLanes,y===0&&(Pi=null),f8(l.stateNode),On(i,Lt()),s!==null)for(d=i.onRecoverableError,l=0;l<s.length;l++)g=s[l],d(g.value,{componentStack:g.stack,digest:g.digest});if(Fc)throw Fc=!1,i=ym,ym=null,i;return(Bc&1)!==0&&i.tag!==0&&ko(),y=i.pendingLanes,(y&1)!==0?i===Tm?aa++:(aa=0,Tm=i):aa=0,ki(),null}function ko(){if(Ri!==null){var i=zb(Bc),s=er.transition,l=st;try{if(er.transition=null,st=16>i?16:i,Ri===null)var d=!1;else{if(i=Ri,Ri=null,Bc=0,(et&6)!==0)throw Error(n(331));var g=et;for(et|=4,Ce=i.current;Ce!==null;){var y=Ce,x=y.child;if((Ce.flags&16)!==0){var O=y.deletions;if(O!==null){for(var L=0;L<O.length;L++){var Y=O[L];for(Ce=Y;Ce!==null;){var se=Ce;switch(se.tag){case 0:case 11:case 15:sa(8,se,y)}var ce=se.child;if(ce!==null)ce.return=se,Ce=ce;else for(;Ce!==null;){se=Ce;var ne=se.sibling,xe=se.return;if(B2(se),se===Y){Ce=null;break}if(ne!==null){ne.return=xe,Ce=ne;break}Ce=xe}}}var Ae=y.alternate;if(Ae!==null){var ve=Ae.child;if(ve!==null){Ae.child=null;do{var Dt=ve.sibling;ve.sibling=null,ve=Dt}while(ve!==null)}}Ce=y}}if((y.subtreeFlags&2064)!==0&&x!==null)x.return=y,Ce=x;else e:for(;Ce!==null;){if(y=Ce,(y.flags&2048)!==0)switch(y.tag){case 0:case 11:case 15:sa(9,y,y.return)}var z=y.sibling;if(z!==null){z.return=y.return,Ce=z;break e}Ce=y.return}}var F=i.current;for(Ce=F;Ce!==null;){x=Ce;var $=x.child;if((x.subtreeFlags&2064)!==0&&$!==null)$.return=x,Ce=$;else e:for(x=F;Ce!==null;){if(O=Ce,(O.flags&2048)!==0)try{switch(O.tag){case 0:case 11:case 15:Rc(9,O)}}catch(Ne){kt(O,O.return,Ne)}if(O===x){Ce=null;break e}var me=O.sibling;if(me!==null){me.return=O.return,Ce=me;break e}Ce=O.return}}if(et=g,ki(),Lr&&typeof Lr.onPostCommitFiberRoot=="function")try{Lr.onPostCommitFiberRoot(Yl,i)}catch(Ne){}d=!0}return d}finally{st=l,er.transition=s}}return!1}function ex(i,s,l){s=wo(l,s),s=y2(i,s,1),i=Oi(i,s,1),s=gn(),i!==null&&(Pu(i,1,s),On(i,s))}function kt(i,s,l){if(i.tag===3)ex(i,i,l);else for(;s!==null;){if(s.tag===3){ex(s,i,l);break}else if(s.tag===1){var d=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof d.componentDidCatch=="function"&&(Pi===null||!Pi.has(d))){i=wo(l,i),i=T2(s,i,1),s=Oi(s,i,1),i=gn(),s!==null&&(Pu(s,1,i),On(s,i));break}}s=s.return}}function BF(i,s,l){var d=i.pingCache;d!==null&&d.delete(s),s=gn(),i.pingedLanes|=i.suspendedLanes&l,Kt===i&&(tn&l)===l&&(zt===4||zt===3&&(tn&130023424)===tn&&500>Lt()-Em?ds(i,0):gm|=l),On(i,s)}function tx(i,s){s===0&&((i.mode&1)===0?s=1:(s=Gl,Gl<<=1,(Gl&130023424)===0&&(Gl=4194304)));var l=gn();i=ri(i,s),i!==null&&(Pu(i,s,l),On(i,l))}function UF(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),tx(i,l)}function HF(i,s){var l=0;switch(i.tag){case 13:var d=i.stateNode,g=i.memoizedState;g!==null&&(l=g.retryLane);break;case 19:d=i.stateNode;break;default:throw Error(n(314))}d!==null&&d.delete(s),tx(i,l)}var nx;nx=function(i,s,l){if(i!==null)if(i.memoizedProps!==s.pendingProps||An.current)kn=!0;else{if((i.lanes&l)===0&&(s.flags&128)===0)return kn=!1,vF(i,s,l);kn=(i.flags&131072)!==0}else kn=!1,bt&&(s.flags&1048576)!==0&&D_(s,gc,s.index);switch(s.lanes=0,s.tag){case 2:var d=s.type;Ic(i,s),i=s.pendingProps;var g=go(s,an.current);xo(s,l),g=Gp(null,s,d,i,g,l);var y=Kp();return s.flags|=1,typeof g=="object"&&g!==null&&typeof g.render=="function"&&g.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,vn(d)?(y=!0,hc(s)):y=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,zp(s),g.updater=Nc,s.stateNode=g,g._reactInternals=s,tm(s,d,i,l),s=sm(null,s,d,!0,y,l)):(s.tag=0,bt&&y&&Ip(s),mn(null,s,g,l),s=s.child),s;case 16:d=s.elementType;e:{switch(Ic(i,s),i=s.pendingProps,g=d._init,d=g(d._payload),s.type=d,g=s.tag=jF(d),i=gr(d,i),g){case 0:s=im(null,s,d,i,l);break e;case 1:s=k2(null,s,d,i,l);break e;case 11:s=S2(null,s,d,i,l);break e;case 14:s=w2(null,s,d,gr(d.type,i),l);break e}throw Error(n(306,d,""))}return s;case 0:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),im(i,s,d,g,l);case 1:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),k2(i,s,d,g,l);case 3:e:{if(N2(s),i===null)throw Error(n(387));d=s.pendingProps,y=s.memoizedState,g=y.element,V_(i,s),xc(s,d,null,l);var x=s.memoizedState;if(d=x.element,y.isDehydrated)if(y={element:d,isDehydrated:!1,cache:x.cache,pendingSuspenseBoundaries:x.pendingSuspenseBoundaries,transitions:x.transitions},s.updateQueue.baseState=y,s.memoizedState=y,s.flags&256){g=wo(Error(n(423)),s),s=O2(i,s,d,l,g);break e}else if(d!==g){g=wo(Error(n(424)),s),s=O2(i,s,d,l,g);break e}else for(zn=Ci(s.stateNode.containerInfo.firstChild),Hn=s,bt=!0,mr=null,l=j_(s,null,d,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(To(),d===g){s=si(i,s,l);break e}mn(i,s,d,l)}s=s.child}return s;case 5:return W_(s),i===null&&Lp(s),d=s.type,g=s.pendingProps,y=i!==null?i.memoizedProps:null,x=g.children,Cp(d,g)?x=null:y!==null&&Cp(d,y)&&(s.flags|=32),v2(i,s),mn(i,s,x,l),s.child;case 6:return i===null&&Lp(s),null;case 13:return I2(i,s,l);case 4:return jp(s,s.stateNode.containerInfo),d=s.pendingProps,i===null?s.child=bo(s,null,d,l):mn(i,s,d,l),s.child;case 11:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),S2(i,s,d,g,l);case 7:return mn(i,s,s.pendingProps,l),s.child;case 8:return mn(i,s,s.pendingProps.children,l),s.child;case 12:return mn(i,s,s.pendingProps.children,l),s.child;case 10:e:{if(d=s.type._context,g=s.pendingProps,y=s.memoizedProps,x=g.value,ct(Tc,d._currentValue),d._currentValue=x,y!==null)if(pr(y.value,x)){if(y.children===g.children&&!An.current){s=si(i,s,l);break e}}else for(y=s.child,y!==null&&(y.return=s);y!==null;){var O=y.dependencies;if(O!==null){x=y.child;for(var L=O.firstContext;L!==null;){if(L.context===d){if(y.tag===1){L=ii(-1,l&-l),L.tag=2;var Y=y.updateQueue;if(Y!==null){Y=Y.shared;var se=Y.pending;se===null?L.next=L:(L.next=se.next,se.next=L),Y.pending=L}}y.lanes|=l,L=y.alternate,L!==null&&(L.lanes|=l),Up(y.return,l,s),O.lanes|=l;break}L=L.next}}else if(y.tag===10)x=y.type===s.type?null:y.child;else if(y.tag===18){if(x=y.return,x===null)throw Error(n(341));x.lanes|=l,O=x.alternate,O!==null&&(O.lanes|=l),Up(x,l,s),x=y.sibling}else x=y.child;if(x!==null)x.return=y;else for(x=y;x!==null;){if(x===s){x=null;break}if(y=x.sibling,y!==null){y.return=x.return,x=y;break}x=x.return}y=x}mn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,d=s.pendingProps.children,xo(s,l),g=Jn(g),d=d(g),s.flags|=1,mn(i,s,d,l),s.child;case 14:return d=s.type,g=gr(d,s.pendingProps),g=gr(d.type,g),w2(i,s,d,g,l);case 15:return C2(i,s,s.type,s.pendingProps,l);case 17:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),Ic(i,s),s.tag=1,vn(d)?(i=!0,hc(s)):i=!1,xo(s,l),g2(s,d,g),tm(s,d,g,l),sm(null,s,d,!0,i,l);case 19:return R2(i,s,l);case 22:return A2(i,s,l)}throw Error(n(156,s.tag))};function rx(i,s){return Fb(i,s)}function zF(i,s,l,d){this.tag=i,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=s,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=d,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function tr(i,s,l,d){return new zF(i,s,l,d)}function Cm(i){return i=i.prototype,!(!i||!i.isReactComponent)}function jF(i){if(typeof i=="function")return Cm(i)?1:0;if(i!=null){if(i=i.$$typeof,i===de)return 11;if(i===ge)return 14}return 2}function Fi(i,s){var l=i.alternate;return l===null?(l=tr(i.tag,s,i.key,i.mode),l.elementType=i.elementType,l.type=i.type,l.stateNode=i.stateNode,l.alternate=i,i.alternate=l):(l.pendingProps=s,l.type=i.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=i.flags&14680064,l.childLanes=i.childLanes,l.lanes=i.lanes,l.child=i.child,l.memoizedProps=i.memoizedProps,l.memoizedState=i.memoizedState,l.updateQueue=i.updateQueue,s=i.dependencies,l.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext},l.sibling=i.sibling,l.index=i.index,l.ref=i.ref,l}function jc(i,s,l,d,g,y){var x=2;if(d=i,typeof i=="function")Cm(i)&&(x=1);else if(typeof i=="string")x=5;else e:switch(i){case te:return ps(l.children,g,y,s);case Te:x=8,g|=8;break;case Se:return i=tr(12,l,s,g|2),i.elementType=Se,i.lanes=y,i;case ue:return i=tr(13,l,s,g),i.elementType=ue,i.lanes=y,i;case ie:return i=tr(19,l,s,g),i.elementType=ie,i.lanes=y,i;case ae:return $c(l,g,y,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case H:x=10;break e;case fe:x=9;break e;case de:x=11;break e;case ge:x=14;break e;case we:x=16,d=null;break e}throw Error(n(130,i==null?i:typeof i,""))}return s=tr(x,l,s,g),s.elementType=i,s.type=d,s.lanes=y,s}function ps(i,s,l,d){return i=tr(7,i,d,s),i.lanes=l,i}function $c(i,s,l,d){return i=tr(22,i,d,s),i.elementType=ae,i.lanes=l,i.stateNode={isHidden:!1},i}function Am(i,s,l){return i=tr(6,i,null,s),i.lanes=l,i}function vm(i,s,l){return s=tr(4,i.children!==null?i.children:[],i.key,s),s.lanes=l,s.stateNode={containerInfo:i.containerInfo,pendingChildren:null,implementation:i.implementation},s}function $F(i,s,l,d,g){this.tag=s,this.containerInfo=i,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=ep(0),this.expirationTimes=ep(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ep(0),this.identifierPrefix=d,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function km(i,s,l,d,g,y,x,O,L){return i=new $F(i,s,l,O,L),s===1?(s=1,y===!0&&(s|=8)):s=0,y=tr(3,null,null,s),i.current=y,y.stateNode=i,y.memoizedState={element:d,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},zp(y),i}function VF(i,s,l){var d=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:B,key:d==null?null:""+d,children:i,containerInfo:s,implementation:l}}function ix(i){if(!i)return vi;i=i._reactInternals;e:{if(ns(i)!==i||i.tag!==1)throw Error(n(170));var s=i;do{switch(s.tag){case 3:s=s.stateNode.context;break e;case 1:if(vn(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break e}}s=s.return}while(s!==null);throw Error(n(171))}if(i.tag===1){var l=i.type;if(vn(l))return P_(i,l,s)}return s}function sx(i,s,l,d,g,y,x,O,L){return i=km(l,d,!0,i,g,y,x,O,L),i.context=ix(null),l=i.current,d=gn(),g=Li(l),y=ii(d,g),y.callback=s!=null?s:null,Oi(l,y,g),i.current.lanes=g,Pu(i,g,d),On(i,d),i}function Vc(i,s,l,d){var g=s.current,y=gn(),x=Li(g);return l=ix(l),s.context===null?s.context=l:s.pendingContext=l,s=ii(y,x),s.payload={element:i},d=d===void 0?null:d,d!==null&&(s.callback=d),i=Oi(g,s,x),i!==null&&(Tr(i,g,x,y),_c(i,g,x)),x}function qc(i){if(i=i.current,!i.child)return null;switch(i.child.tag){case 5:return i.child.stateNode;default:return i.child.stateNode}}function ox(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function Nm(i,s){ox(i,s),(i=i.alternate)&&ox(i,s)}function qF(){return null}var ux=typeof reportError=="function"?reportError:function(i){console.error(i)};function Om(i){this._internalRoot=i}Yc.prototype.render=Om.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Vc(i,s,null,null)},Yc.prototype.unmount=Om.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;fs(function(){Vc(null,i,null,null)}),s[Zr]=null}};function Yc(i){this._internalRoot=i}Yc.prototype.unstable_scheduleHydration=function(i){if(i){var s=Vb();i={blockedOn:null,target:i,priority:s};for(var l=0;l<xi.length&&s!==0&&s<xi[l].priority;l++);xi.splice(l,0,i),l===0&&Wb(i)}};function Im(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function Wc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function ax(){}function YF(i,s,l,d,g){if(g){if(typeof d=="function"){var y=d;d=function(){var Y=qc(x);y.call(Y)}}var x=sx(s,d,i,0,null,!1,!1,"",ax);return i._reactRootContainer=x,i[Zr]=x.current,Yu(i.nodeType===8?i.parentNode:i),fs(),x}for(;g=i.lastChild;)i.removeChild(g);if(typeof d=="function"){var O=d;d=function(){var Y=qc(L);O.call(Y)}}var L=km(i,0,!1,null,null,!1,!1,"",ax);return i._reactRootContainer=L,i[Zr]=L.current,Yu(i.nodeType===8?i.parentNode:i),fs(function(){Vc(s,L,l,d)}),L}function Gc(i,s,l,d,g){var y=l._reactRootContainer;if(y){var x=y;if(typeof g=="function"){var O=g;g=function(){var L=qc(x);O.call(L)}}Vc(s,x,i,g)}else x=YF(l,s,i,g,d);return qc(x)}jb=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=Iu(s.pendingLanes);l!==0&&(tp(s,l|1),On(s,Lt()),(et&6)===0&&(vo=Lt()+500,ki()))}break;case 13:fs(function(){var d=ri(i,1);if(d!==null){var g=gn();Tr(d,i,1,g)}}),Nm(i,1)}},np=function(i){if(i.tag===13){var s=ri(i,134217728);if(s!==null){var l=gn();Tr(s,i,134217728,l)}Nm(i,134217728)}},$b=function(i){if(i.tag===13){var s=Li(i),l=ri(i,s);if(l!==null){var d=gn();Tr(l,i,s,d)}Nm(i,s)}},Vb=function(){return st},qb=function(i,s){var l=st;try{return st=i,s()}finally{st=l}},Gh=function(i,s,l){switch(s){case"input":if(Wt(i,l),s=l.name,l.type==="radio"&&s!=null){for(l=i;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll("input[name="+JSON.stringify(""+s)+'][type="radio"]'),s=0;s<l.length;s++){var d=l[s];if(d!==i&&d.form===i.form){var g=fc(d);if(!g)throw Error(n(90));He(d),Wt(d,g)}}}break;case"textarea":zl(i,l);break;case"select":s=l.value,s!=null&&vt(i,!!l.multiple,s,!1)}},Nb=xm,Ob=fs;var WF={usingClientEntryPoint:!1,Events:[Ku,po,fc,vb,kb,xm]},la={findFiberByHostInstance:rs,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},GF={bundleType:la.bundleType,version:la.version,rendererPackageName:la.rendererPackageName,rendererConfig:la.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:G.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=Lb(i),i===null?null:i.stateNode},findFiberByHostInstance:la.findFiberByHostInstance||qF,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!="undefined"){var Kc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Kc.isDisabled&&Kc.supportsFiber)try{Yl=Kc.inject(GF),Lr=Kc}catch(i){}}return xn.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=WF,xn.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Im(s))throw Error(n(200));return VF(i,s,null,l)},xn.createRoot=function(i,s){if(!Im(i))throw Error(n(299));var l=!1,d="",g=ux;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(d=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=km(i,1,!1,null,null,l,!1,d,g),i[Zr]=s.current,Yu(i.nodeType===8?i.parentNode:i),new Om(s)},xn.findDOMNode=function(i){if(i==null)return null;if(i.nodeType===1)return i;var s=i._reactInternals;if(s===void 0)throw typeof i.render=="function"?Error(n(188)):(i=Object.keys(i).join(","),Error(n(268,i)));return i=Lb(s),i=i===null?null:i.stateNode,i},xn.flushSync=function(i){return fs(i)},xn.hydrate=function(i,s,l){if(!Wc(s))throw Error(n(200));return Gc(null,i,s,!0,l)},xn.hydrateRoot=function(i,s,l){if(!Im(i))throw Error(n(405));var d=l!=null&&l.hydratedSources||null,g=!1,y="",x=ux;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(y=l.identifierPrefix),l.onRecoverableError!==void 0&&(x=l.onRecoverableError)),s=sx(s,null,i,1,l!=null?l:null,g,!1,y,x),i[Zr]=s.current,Yu(i),d)for(i=0;i<d.length;i++)l=d[i],g=l._getVersion,g=g(l._source),s.mutableSourceEagerHydrationData==null?s.mutableSourceEagerHydrationData=[l,g]:s.mutableSourceEagerHydrationData.push(l,g);return new Yc(s)},xn.render=function(i,s,l){if(!Wc(s))throw Error(n(200));return Gc(null,i,s,!1,l)},xn.unmountComponentAtNode=function(i){if(!Wc(i))throw Error(n(40));return i._reactRootContainer?(fs(function(){Gc(null,null,i,!1,function(){i._reactRootContainer=null,i[Zr]=null})}),!0):!1},xn.unstable_batchedUpdates=xm,xn.unstable_renderSubtreeIntoContainer=function(i,s,l,d){if(!Wc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Gc(i,s,l,!1,d)},xn.version="18.3.1-next-f1338f8080-20240426",xn}var Xg;function Jg(){if(Xg)return od.exports;Xg=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__=="undefined"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),od.exports=Sv(),od.exports}var Qa=Jg();function wv(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var ld=()=>e=>Array.from(new Set(e)),Zg=typeof globalThis.document!="undefined"?W.useLayoutEffect:W.useEffect;function Xa(e){var E,b;const t=(E=e().value)!=null?E:e().defaultValue,n=(b=e().isEqual)!=null?b:Object.is,[r]=W.useState(t),[o,u]=W.useState(r),a=e().value!==void 0,c=W.useRef(o);c.current=a?e().value:o;const f=W.useRef(c.current);Zg(()=>{f.current=c.current},[o,e().value]);const h=T=>{var C,k;const _=f.current,S=ks(T)?T(_):T;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:S,prev:_}),a||u(S),n(S,_)||(k=(C=e()).onChange)==null||k.call(C,S,_)};function m(){return a?e().value:o}return{initial:r,ref:c,get:m,set(T){(e().sync?Qa.flushSync:_A)(()=>h(T))},invoke(T,_){var S,C;(C=(S=e()).onChange)==null||C.call(S,T,_)},hash(T){var _,S,C;return(C=(S=(_=e()).hash)==null?void 0:S.call(_,T))!=null?C:String(T)}}}Xa.cleanup=e=>{W.useEffect(()=>e,[])},Xa.ref=e=>{const t=W.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function Cv(e){const t=W.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var Av=(e,t)=>{const n=W.useRef(!1),r=W.useRef(!1);W.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),W.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function cd(e,t={}){var fe,de,ue,ie,ge,we;const n=W.useMemo(()=>{const{id:ae,ids:V,getRootNode:ee}=t;return bv({id:ae,ids:V,getRootNode:ee})},[t]),r=(...ae)=>{e.debug&&console.log(...ae)},o=(de=(fe=e.props)==null?void 0:fe.call(e,{props:Kf(t),scope:n}))!=null?de:t,u=vv(o),a=(ue=e.context)==null?void 0:ue.call(e,{prop:u,bindable:Xa,scope:n,flush:t1,getContext(){return f},getComputed(){return q},getRefs(){return S},getEvent(){return T()}}),c=e1(a),f={get(ae){var V;return(V=c.current)==null?void 0:V[ae].ref.current},set(ae,V){var ee;(ee=c.current)==null||ee[ae].set(V)},initial(ae){var V;return(V=c.current)==null?void 0:V[ae].initial},hash(ae){var ee,w;const V=(ee=c.current)==null?void 0:ee[ae].get();return(w=c.current)==null?void 0:w[ae].hash(V)}},h=W.useRef(new Map),m=W.useRef(null),E=W.useRef(null),b=W.useRef({type:""}),T=()=>ye(U({},b.current),{current(){return b.current},previous(){return E.current}}),_=()=>ye(U({},B),{matches(...ae){return ae.includes(B.ref.current)},hasTag(ae){var V,ee;return!!((ee=(V=e.states[B.ref.current])==null?void 0:V.tags)!=null&&ee.includes(ae))}}),S=Cv((ge=(ie=e.refs)==null?void 0:ie.call(e,{prop:u,context:f}))!=null?ge:{}),C=()=>({state:_(),context:f,event:T(),prop:u,send:H,action:k,guard:M,track:Av,refs:S,computed:q,flush:t1,scope:n,choose:G}),k=ae=>{const V=ks(ae)?ae(C()):ae;if(!V)return;const ee=V.map(w=>{var Q,N;const R=(N=(Q=e.implementations)==null?void 0:Q.actions)==null?void 0:N[w];return R||Qf(`[zag-js] No implementation found for action "${JSON.stringify(w)}"`),R});for(const w of ee)w==null||w(C())},M=ae=>{var V,ee;return ks(ae)?ae(C()):(ee=(V=e.implementations)==null?void 0:V.guards)==null?void 0:ee[ae](C())},D=ae=>{const V=ks(ae)?ae(C()):ae;if(!V)return;const ee=V.map(R=>{var N,_e;const Q=(_e=(N=e.implementations)==null?void 0:N.effects)==null?void 0:_e[R];return Q||Qf(`[zag-js] No implementation found for effect "${JSON.stringify(R)}"`),Q}),w=[];for(const R of ee){const Q=R==null?void 0:R(C());Q&&w.push(Q)}return()=>w.forEach(R=>R==null?void 0:R())},G=ae=>fA(ae).find(V=>{let ee=!V.guard;return $a(V.guard)?ee=!!M(V.guard):ks(V.guard)&&(ee=V.guard(C())),ee}),q=ae=>{SA(e.computed,()=>"[zag-js] No computed object found on machine");const V=e.computed[ae];return V({context:f,event:T(),prop:u,refs:S,scope:n,computed:q})},B=Xa(()=>({defaultValue:e.initialState({prop:u}),onChange(ae,V){var w,R,Q,N;if(V){const _e=h.current.get(V);_e==null||_e(),h.current.delete(V)}V&&k((w=e.states[V])==null?void 0:w.exit),k((R=m.current)==null?void 0:R.actions);const ee=D((Q=e.states[ae])==null?void 0:Q.effects);if(ee&&h.current.set(ae,ee),V===sd){k(e.entry);const _e=D(e.effects);_e&&h.current.set(sd,_e)}k((N=e.states[ae])==null?void 0:N.entry)}})),te=W.useRef(void 0),Te=W.useRef(Is.NotStarted);Zg(()=>{queueMicrotask(()=>{var R;const ee=Te.current===Is.Started;Te.current=Is.Started,r(ee?"rehydrating...":"initializing...");const w=(R=te.current)!=null?R:B.initial;B.invoke(w,ee?B.get():sd)});const ae=h.current,V=B.ref.current;return()=>{r("unmounting..."),te.current=V,Te.current=Is.Stopped,ae.forEach(ee=>ee==null?void 0:ee()),h.current=new Map,m.current=null,queueMicrotask(()=>{k(e.exit)})}},[]);const Se=()=>"ref"in B?B.ref.current:B.get(),H=ae=>{queueMicrotask(()=>{var N,_e,Me,Ie,Ye;if(Te.current!==Is.Started)return;E.current=b.current,b.current=ae;let V=Se();const ee=(Me=(N=e.states[V].on)==null?void 0:N[ae.type])!=null?Me:(_e=e.on)==null?void 0:_e[ae.type],w=G(ee);if(!w)return;m.current=w;const R=(Ie=w.target)!=null?Ie:V;r("transition",ae.type,w.target||V,`(${w.actions})`);const Q=R!==V;Q?Qa.flushSync(()=>B.set(R)):w.reenter&&!Q?B.invoke(V,V):k((Ye=w.actions)!=null?Ye:[])})};return(we=e.watch)==null||we.call(e,C()),{state:_(),send:H,context:f,prop:u,scope:n,refs:S,computed:q,event:T(),getStatus:()=>Te.current}}function e1(e){const t=W.useRef(e);return t.current=e,t}function vv(e){const t=e1(e);return function(r){return t.current[r]}}function t1(e){queueMicrotask(()=>{Qa.flushSync(()=>e())})}var n1=wv(e=>e);function Ja(...e){return t=>{const n=[];for(const r of e)if(typeof r=="function"){const o=r(t);typeof o=="function"&&n.push(o)}else r&&(r.current=t);if(n.length)return()=>{for(const r of n)r()}}}function kv(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const fd=e=>{const t=W.memo(W.forwardRef((n,r)=>{const h=n,{asChild:o,children:u}=h,a=Xt(h,["asChild","children"]);if(!o)return W.createElement(e,ye(U({},a),{ref:r}),u);if(!W.isValidElement(u))return null;const c=W.Children.only(u),f=kv(c);return W.cloneElement(c,ye(U({},ar(a,c.props)),{ref:r?Ja(r,f):f}))}));return t.displayName=e.displayName||e.name,t},ci=(()=>{const e=new Map;return new Proxy(fd,{apply(t,n,r){return fd(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,fd(r)),e.get(r)}})})();function Nv(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Ps(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:u,defaultValue:a}=e,c=W.createContext(a);c.displayName=t;function f(){var m;const h=W.useContext(c);if(!h&&n){const E=new Error(u!=null?u:Nv(r,o));throw E.name="ContextError",(m=Error.captureStackTrace)==null||m.call(Error,E,f),E}return h}return[c.Provider,f,c]}const[Ov,dd]=Ps({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[r1,Go]=Ps({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),i1=W.forwardRef((e,t)=>{const n=dd(),r=Go(),o=ar(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:I.jsx(ci.div,ye(U({},o),{ref:Ja(r.ref,t)}))});i1.displayName="PopoverContent";const s1=W.forwardRef((e,t)=>{const n=dd(),r=Go(),o=ar(n.getPositionerProps(),e);return r.unmounted?null:I.jsx(ci.div,ye(U({},o),{ref:t}))});s1.displayName="PopoverPositioner";const o1=()=>(e,t)=>t.reduce((n,r)=>{const[o,u]=n,a=r;return u[a]!==void 0&&(o[a]=u[a]),delete u[a],[o,u]},[{},U({},e)]),u1=e=>o1()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function Iv(e,t){const{state:n,send:r,context:o}=e,u=n.matches("mounted","unmountSuspended");return{skip:!o.get("initial"),present:u,setNode(a){a&&r({type:"NODE.SET",node:a})},unmount(){r({type:"UNMOUNT"})}}}var Pv={props({props:e}){return ye(U({},e),{present:!!e.present})},initialState({prop:e}){return e("present")?"mounted":"unmounted"},refs(){return{node:null,styles:null}},context({bindable:e}){return{unmountAnimationName:e(()=>({defaultValue:null})),prevAnimationName:e(()=>({defaultValue:null})),present:e(()=>({defaultValue:!1})),initial:e(()=>({sync:!0,defaultValue:!1}))}},exit:["clearInitial","cleanupNode"],watch({track:e,prop:t,send:n}){e([()=>t("present")],()=>{n({type:"PRESENCE.CHANGED"})})},on:{"NODE.SET":{actions:["setupNode"]},"PRESENCE.CHANGED":{actions:["setInitial","syncPresence"]}},states:{mounted:{on:{UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]},"UNMOUNT.SUSPEND":{target:"unmountSuspended"}}},unmountSuspended:{effects:["trackAnimationEvents"],on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]},UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]}}},unmounted:{on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]}}}},implementations:{actions:{setInitial:({context:e})=>{e.get("initial")||queueMicrotask(()=>{e.set("initial",!0)})},clearInitial:({context:e})=>{e.set("initial",!1)},invokeOnExitComplete:({prop:e})=>{var t;(t=e("onExitComplete"))==null||t()},setupNode:({refs:e,event:t})=>{e.get("node")!==t.node&&(e.set("node",t.node),e.set("styles",Wa(t.node)))},cleanupNode:({refs:e})=>{e.set("node",null),e.set("styles",null)},syncPresence:({context:e,refs:t,send:n,prop:r})=>{const o=r("present");if(o)return n({type:"MOUNT",src:"presence.changed"});const u=t.get("node");if(!o&&(u==null?void 0:u.ownerDocument.visibilityState)==="hidden")return n({type:"UNMOUNT",src:"visibilitychange"});_n(()=>{var c,f;const a=Za(t.get("styles"));e.set("unmountAnimationName",a),a==="none"||a===e.get("prevAnimationName")||((c=t.get("styles"))==null?void 0:c.display)==="none"||((f=t.get("styles"))==null?void 0:f.animationDuration)==="0s"?n({type:"UNMOUNT",src:"presence.changed"}):n({type:"UNMOUNT.SUSPEND"})})},setPrevAnimationName:({context:e,refs:t})=>{_n(()=>{e.set("prevAnimationName",Za(t.get("styles")))})},clearPrevAnimationName:({context:e})=>{e.set("prevAnimationName",null)}},effects:{trackAnimationEvents:({context:e,refs:t,send:n,prop:r})=>{const o=t.get("node");if(!o)return;const u=f=>{var m,E,b;((b=(E=(m=f.composedPath)==null?void 0:m.call(f))==null?void 0:E[0])!=null?b:f.target)===o&&e.set("prevAnimationName",Za(t.get("styles")))},a=f=>{const h=Za(t.get("styles"));qr(f)===o&&h===e.get("unmountAnimationName")&&!r("present")&&n({type:"UNMOUNT",src:"animationend"})};o.addEventListener("animationstart",u),o.addEventListener("animationcancel",a),o.addEventListener("animationend",a);const c=Ka(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",u),o.removeEventListener("animationcancel",a),o.removeEventListener("animationend",a),av(()=>c())}}}}};function Za(e){return(e==null?void 0:e.animationName)||"none"}ld()(["onExitComplete","present","immediate"]);function Rv(e,t={}){const{sync:n=!1}=t,r=Lv(e);return W.useCallback((...o)=>{var u;return n?queueMicrotask(()=>{var a;return(a=r.current)==null?void 0:a.call(r,...o)}):(u=r.current)==null?void 0:u.call(r,...o)},[n,r])}function Lv(e){const t=W.useRef(e);return t.current=e,t}const hd=(e={})=>{const b=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=b,u=Xt(b,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),a=W.useRef(!1),c=ye(U({},u),{present:r,onExitComplete:Rv(e.onExitComplete)}),f=cd(Pv,c),h=Iv(f);h.present&&(a.current=!0);const m=!h.present&&!a.current&&t||n&&!h.present&&a.current,E=()=>({"data-state":h.skip&&o?void 0:r?"open":"closed",hidden:!h.present});return{ref:h.setNode,getPresenceProps:E,present:h.present,unmounted:m}};var Rs=(e,t=[])=>({parts:(...n)=>{if(Dv(t))return Rs(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>Rs(e,[...t,...n]),omit:(...n)=>Rs(e,t.filter(r=>!n.includes(r))),rename:n=>Rs(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Ls(e)}"][data-part="${Ls(r)}"]`,`& [data-scope="${Ls(e)}"][data-part="${Ls(r)}"]`].join(", "),attrs:{"data-scope":Ls(e),"data-part":Ls(r)}}}),{})}),Ls=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),Dv=e=>e.length===0;const Fv=["top","right","bottom","left"],fi=Math.min,Pn=Math.max,el=Math.round,tl=Math.floor,wr=e=>({x:e,y:e}),Mv={left:"right",right:"left",bottom:"top",top:"bottom"},Bv={start:"end",end:"start"};function pd(e,t,n){return Pn(e,fi(t,n))}function Wr(e,t){return typeof e=="function"?e(t):e}function Gr(e){return e.split("-")[0]}function Ds(e){return e.split("-")[1]}function md(e){return e==="x"?"y":"x"}function gd(e){return e==="y"?"height":"width"}const Uv=new Set(["top","bottom"]);function Cr(e){return Uv.has(Gr(e))?"y":"x"}function Ed(e){return md(Cr(e))}function Hv(e,t,n){n===void 0&&(n=!1);const r=Ds(e),o=Ed(e),u=gd(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[u]>t.floating[u]&&(a=nl(a)),[a,nl(a)]}function zv(e){const t=nl(e);return[yd(e),t,yd(t)]}function yd(e){return e.replace(/start|end/g,t=>Bv[t])}const a1=["left","right"],l1=["right","left"],jv=["top","bottom"],$v=["bottom","top"];function Vv(e,t,n){switch(e){case"top":case"bottom":return n?t?l1:a1:t?a1:l1;case"left":case"right":return t?jv:$v;default:return[]}}function qv(e,t,n,r){const o=Ds(e);let u=Vv(Gr(e),n==="start",r);return o&&(u=u.map(a=>a+"-"+o),t&&(u=u.concat(u.map(yd)))),u}function nl(e){return e.replace(/left|right|bottom|top/g,t=>Mv[t])}function Yv(e){return U({top:0,right:0,bottom:0,left:0},e)}function c1(e){return typeof e!="number"?Yv(e):{top:e,right:e,bottom:e,left:e}}function rl(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function f1(e,t,n){let{reference:r,floating:o}=e;const u=Cr(t),a=Ed(t),c=gd(a),f=Gr(t),h=u==="y",m=r.x+r.width/2-o.width/2,E=r.y+r.height/2-o.height/2,b=r[c]/2-o[c]/2;let T;switch(f){case"top":T={x:m,y:r.y-o.height};break;case"bottom":T={x:m,y:r.y+r.height};break;case"right":T={x:r.x+r.width,y:E};break;case"left":T={x:r.x-o.width,y:E};break;default:T={x:r.x,y:r.y}}switch(Ds(t)){case"start":T[a]-=b*(n&&h?-1:1);break;case"end":T[a]+=b*(n&&h?-1:1);break}return T}const Wv=(e,t,n)=>it(null,null,function*(){const{placement:r="bottom",strategy:o="absolute",middleware:u=[],platform:a}=n,c=u.filter(Boolean),f=yield a.isRTL==null?void 0:a.isRTL(t);let h=yield a.getElementRects({reference:e,floating:t,strategy:o}),{x:m,y:E}=f1(h,r,f),b=r,T={},_=0;for(let S=0;S<c.length;S++){const{name:C,fn:k}=c[S],{x:M,y:D,data:G,reset:q}=yield k({x:m,y:E,initialPlacement:r,placement:b,strategy:o,middlewareData:T,rects:h,platform:a,elements:{reference:e,floating:t}});m=M!=null?M:m,E=D!=null?D:E,T=ye(U({},T),{[C]:U(U({},T[C]),G)}),q&&_<=50&&(_++,typeof q=="object"&&(q.placement&&(b=q.placement),q.rects&&(h=q.rects===!0?yield a.getElementRects({reference:e,floating:t,strategy:o}):q.rects),{x:m,y:E}=f1(h,b,f)),S=-1)}return{x:m,y:E,placement:b,strategy:o,middlewareData:T}});function Ko(e,t){return it(this,null,function*(){var n;t===void 0&&(t={});const{x:r,y:o,platform:u,rects:a,elements:c,strategy:f}=e,{boundary:h="clippingAncestors",rootBoundary:m="viewport",elementContext:E="floating",altBoundary:b=!1,padding:T=0}=Wr(t,e),_=c1(T),C=c[b?E==="floating"?"reference":"floating":E],k=rl(yield u.getClippingRect({element:(n=yield u.isElement==null?void 0:u.isElement(C))==null||n?C:C.contextElement||(yield u.getDocumentElement==null?void 0:u.getDocumentElement(c.floating)),boundary:h,rootBoundary:m,strategy:f})),M=E==="floating"?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,D=yield u.getOffsetParent==null?void 0:u.getOffsetParent(c.floating),G=(yield u.isElement==null?void 0:u.isElement(D))?(yield u.getScale==null?void 0:u.getScale(D))||{x:1,y:1}:{x:1,y:1},q=rl(u.convertOffsetParentRelativeRectToViewportRelativeRect?yield u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:M,offsetParent:D,strategy:f}):M);return{top:(k.top-q.top+_.top)/G.y,bottom:(q.bottom-k.bottom+_.bottom)/G.y,left:(k.left-q.left+_.left)/G.x,right:(q.right-k.right+_.right)/G.x}})}const Gv=e=>({name:"arrow",options:e,fn(n){return it(this,null,function*(){const{x:r,y:o,placement:u,rects:a,platform:c,elements:f,middlewareData:h}=n,{element:m,padding:E=0}=Wr(e,n)||{};if(m==null)return{};const b=c1(E),T={x:r,y:o},_=Ed(u),S=gd(_),C=yield c.getDimensions(m),k=_==="y",M=k?"top":"left",D=k?"bottom":"right",G=k?"clientHeight":"clientWidth",q=a.reference[S]+a.reference[_]-T[_]-a.floating[S],B=T[_]-a.reference[_],te=yield c.getOffsetParent==null?void 0:c.getOffsetParent(m);let Te=te?te[G]:0;(!Te||!(yield c.isElement==null?void 0:c.isElement(te)))&&(Te=f.floating[G]||a.floating[S]);const Se=q/2-B/2,H=Te/2-C[S]/2-1,fe=fi(b[M],H),de=fi(b[D],H),ue=fe,ie=Te-C[S]-de,ge=Te/2-C[S]/2+Se,we=pd(ue,ge,ie),ae=!h.arrow&&Ds(u)!=null&&ge!==we&&a.reference[S]/2-(ge<ue?fe:de)-C[S]/2<0,V=ae?ge<ue?ge-ue:ge-ie:0;return{[_]:T[_]+V,data:U({[_]:we,centerOffset:ge-we-V},ae&&{alignmentOffset:V}),reset:ae}})}}),Kv=function(e){return e===void 0&&(e={}),{name:"flip",options:e,fn(n){return it(this,null,function*(){var r,o;const{placement:u,middlewareData:a,rects:c,initialPlacement:f,platform:h,elements:m}=n,ge=Wr(e,n),{mainAxis:E=!0,crossAxis:b=!0,fallbackPlacements:T,fallbackStrategy:_="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:C=!0}=ge,k=Xt(ge,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=a.arrow)!=null&&r.alignmentOffset)return{};const M=Gr(u),D=Cr(f),G=Gr(f)===f,q=yield h.isRTL==null?void 0:h.isRTL(m.floating),B=T||(G||!C?[nl(f)]:zv(f)),te=S!=="none";!T&&te&&B.push(...qv(f,C,S,q));const Te=[f,...B],Se=yield Ko(n,k),H=[];let fe=((o=a.flip)==null?void 0:o.overflows)||[];if(E&&H.push(Se[M]),b){const we=Hv(u,c,q);H.push(Se[we[0]],Se[we[1]])}if(fe=[...fe,{placement:u,overflows:H}],!H.every(we=>we<=0)){var de,ue;const we=(((de=a.flip)==null?void 0:de.index)||0)+1,ae=Te[we];if(ae&&(!(b==="alignment"?D!==Cr(ae):!1)||fe.every(w=>Cr(w.placement)===D?w.overflows[0]>0:!0)))return{data:{index:we,overflows:fe},reset:{placement:ae}};let V=(ue=fe.filter(ee=>ee.overflows[0]<=0).sort((ee,w)=>ee.overflows[1]-w.overflows[1])[0])==null?void 0:ue.placement;if(!V)switch(_){case"bestFit":{var ie;const ee=(ie=fe.filter(w=>{if(te){const R=Cr(w.placement);return R===D||R==="y"}return!0}).map(w=>[w.placement,w.overflows.filter(R=>R>0).reduce((R,Q)=>R+Q,0)]).sort((w,R)=>w[1]-R[1])[0])==null?void 0:ie[0];ee&&(V=ee);break}case"initialPlacement":V=f;break}if(u!==V)return{reset:{placement:V}}}return{}})}}};function d1(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function h1(e){return Fv.some(t=>e[t]>=0)}const Qv=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return it(this,null,function*(){const{rects:r}=n,a=Wr(e,n),{strategy:o="referenceHidden"}=a,u=Xt(a,["strategy"]);switch(o){case"referenceHidden":{const c=yield Ko(n,ye(U({},u),{elementContext:"reference"})),f=d1(c,r.reference);return{data:{referenceHiddenOffsets:f,referenceHidden:h1(f)}}}case"escaped":{const c=yield Ko(n,ye(U({},u),{altBoundary:!0})),f=d1(c,r.floating);return{data:{escapedOffsets:f,escaped:h1(f)}}}default:return{}}})}}},p1=new Set(["left","top"]);function Xv(e,t){return it(this,null,function*(){const{placement:n,platform:r,elements:o}=e,u=yield r.isRTL==null?void 0:r.isRTL(o.floating),a=Gr(n),c=Ds(n),f=Cr(n)==="y",h=p1.has(a)?-1:1,m=u&&f?-1:1,E=Wr(t,e);let{mainAxis:b,crossAxis:T,alignmentAxis:_}=typeof E=="number"?{mainAxis:E,crossAxis:0,alignmentAxis:null}:{mainAxis:E.mainAxis||0,crossAxis:E.crossAxis||0,alignmentAxis:E.alignmentAxis};return c&&typeof _=="number"&&(T=c==="end"?_*-1:_),f?{x:T*m,y:b*h}:{x:b*h,y:T*m}})}const Jv=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(n){return it(this,null,function*(){var r,o;const{x:u,y:a,placement:c,middlewareData:f}=n,h=yield Xv(n,e);return c===((r=f.offset)==null?void 0:r.placement)&&(o=f.arrow)!=null&&o.alignmentOffset?{}:{x:u+h.x,y:a+h.y,data:ye(U({},h),{placement:c})}})}}},Zv=function(e){return e===void 0&&(e={}),{name:"shift",options:e,fn(n){return it(this,null,function*(){const{x:r,y:o,placement:u}=n,k=Wr(e,n),{mainAxis:a=!0,crossAxis:c=!1,limiter:f={fn:M=>{let{x:D,y:G}=M;return{x:D,y:G}}}}=k,h=Xt(k,["mainAxis","crossAxis","limiter"]),m={x:r,y:o},E=yield Ko(n,h),b=Cr(Gr(u)),T=md(b);let _=m[T],S=m[b];if(a){const M=T==="y"?"top":"left",D=T==="y"?"bottom":"right",G=_+E[M],q=_-E[D];_=pd(G,_,q)}if(c){const M=b==="y"?"top":"left",D=b==="y"?"bottom":"right",G=S+E[M],q=S-E[D];S=pd(G,S,q)}const C=f.fn(ye(U({},n),{[T]:_,[b]:S}));return ye(U({},C),{data:{x:C.x-r,y:C.y-o,enabled:{[T]:a,[b]:c}}})})}}},ek=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:u,middlewareData:a}=t,{offset:c=0,mainAxis:f=!0,crossAxis:h=!0}=Wr(e,t),m={x:n,y:r},E=Cr(o),b=md(E);let T=m[b],_=m[E];const S=Wr(c,t),C=typeof S=="number"?{mainAxis:S,crossAxis:0}:U({mainAxis:0,crossAxis:0},S);if(f){const D=b==="y"?"height":"width",G=u.reference[b]-u.floating[D]+C.mainAxis,q=u.reference[b]+u.reference[D]-C.mainAxis;T<G?T=G:T>q&&(T=q)}if(h){var k,M;const D=b==="y"?"width":"height",G=p1.has(Gr(o)),q=u.reference[E]-u.floating[D]+(G&&((k=a.offset)==null?void 0:k[E])||0)+(G?0:C.crossAxis),B=u.reference[E]+u.reference[D]+(G?0:((M=a.offset)==null?void 0:M[E])||0)-(G?C.crossAxis:0);_<q?_=q:_>B&&(_=B)}return{[b]:T,[E]:_}}}},tk=function(e){return e===void 0&&(e={}),{name:"size",options:e,fn(n){return it(this,null,function*(){var r,o;const{placement:u,rects:a,platform:c,elements:f}=n,fe=Wr(e,n),{apply:h=()=>{}}=fe,m=Xt(fe,["apply"]),E=yield Ko(n,m),b=Gr(u),T=Ds(u),_=Cr(u)==="y",{width:S,height:C}=a.floating;let k,M;b==="top"||b==="bottom"?(k=b,M=T===((yield c.isRTL==null?void 0:c.isRTL(f.floating))?"start":"end")?"left":"right"):(M=b,k=T==="end"?"top":"bottom");const D=C-E.top-E.bottom,G=S-E.left-E.right,q=fi(C-E[k],D),B=fi(S-E[M],G),te=!n.middlewareData.shift;let Te=q,Se=B;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(Se=G),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(Te=D),te&&!T){const de=Pn(E.left,0),ue=Pn(E.right,0),ie=Pn(E.top,0),ge=Pn(E.bottom,0);_?Se=S-2*(de!==0||ue!==0?de+ue:Pn(E.left,E.right)):Te=C-2*(ie!==0||ge!==0?ie+ge:Pn(E.top,E.bottom))}yield h(ye(U({},n),{availableWidth:Se,availableHeight:Te}));const H=yield c.getDimensions(f.floating);return S!==H.width||C!==H.height?{reset:{rects:!0}}:{}})}}};function il(){return typeof window!="undefined"}function Fs(e){return m1(e)?(e.nodeName||"").toLowerCase():"#document"}function Rn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ar(e){var t;return(t=(m1(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function m1(e){return il()?e instanceof Node||e instanceof Rn(e).Node:!1}function lr(e){return il()?e instanceof Element||e instanceof Rn(e).Element:!1}function vr(e){return il()?e instanceof HTMLElement||e instanceof Rn(e).HTMLElement:!1}function g1(e){return!il()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof Rn(e).ShadowRoot}const nk=new Set(["inline","contents"]);function Qo(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=cr(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!nk.has(o)}const rk=new Set(["table","td","th"]);function ik(e){return rk.has(Fs(e))}const sk=[":popover-open",":modal"];function sl(e){return sk.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const ok=["transform","translate","scale","rotate","perspective"],uk=["transform","translate","scale","rotate","perspective","filter"],ak=["paint","layout","strict","content"];function Td(e){const t=bd(),n=lr(e)?cr(e):e;return ok.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||uk.some(r=>(n.willChange||"").includes(r))||ak.some(r=>(n.contain||"").includes(r))}function lk(e){let t=di(e);for(;vr(t)&&!Ms(t);){if(Td(t))return t;if(sl(t))return null;t=di(t)}return null}function bd(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const ck=new Set(["html","body","#document"]);function Ms(e){return ck.has(Fs(e))}function cr(e){return Rn(e).getComputedStyle(e)}function ol(e){return lr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function di(e){if(Fs(e)==="html")return e;const t=e.assignedSlot||e.parentNode||g1(e)&&e.host||Ar(e);return g1(t)?t.host:t}function E1(e){const t=di(e);return Ms(t)?e.ownerDocument?e.ownerDocument.body:e.body:vr(t)&&Qo(t)?t:E1(t)}function Xo(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=E1(e),u=o===((r=e.ownerDocument)==null?void 0:r.body),a=Rn(o);if(u){const c=_d(a);return t.concat(a,a.visualViewport||[],Qo(o)?o:[],c&&n?Xo(c):[])}return t.concat(o,Xo(o,[],n))}function _d(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function y1(e){const t=cr(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=vr(e),u=o?e.offsetWidth:n,a=o?e.offsetHeight:r,c=el(n)!==u||el(r)!==a;return c&&(n=u,r=a),{width:n,height:r,$:c}}function xd(e){return lr(e)?e:e.contextElement}function Bs(e){const t=xd(e);if(!vr(t))return wr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:u}=y1(t);let a=(u?el(n.width):n.width)/r,c=(u?el(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!c||!Number.isFinite(c))&&(c=1),{x:a,y:c}}const fk=wr(0);function T1(e){const t=Rn(e);return!bd()||!t.visualViewport?fk:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function dk(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Rn(e)?!1:t}function Yi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),u=xd(e);let a=wr(1);t&&(r?lr(r)&&(a=Bs(r)):a=Bs(e));const c=dk(u,n,r)?T1(u):wr(0);let f=(o.left+c.x)/a.x,h=(o.top+c.y)/a.y,m=o.width/a.x,E=o.height/a.y;if(u){const b=Rn(u),T=r&&lr(r)?Rn(r):r;let _=b,S=_d(_);for(;S&&r&&T!==_;){const C=Bs(S),k=S.getBoundingClientRect(),M=cr(S),D=k.left+(S.clientLeft+parseFloat(M.paddingLeft))*C.x,G=k.top+(S.clientTop+parseFloat(M.paddingTop))*C.y;f*=C.x,h*=C.y,m*=C.x,E*=C.y,f+=D,h+=G,_=Rn(S),S=_d(_)}}return rl({width:m,height:E,x:f,y:h})}function ul(e,t){const n=ol(e).scrollLeft;return t?t.left+n:Yi(Ar(e)).left+n}function b1(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-ul(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function hk(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const u=o==="fixed",a=Ar(r),c=t?sl(t.floating):!1;if(r===a||c&&u)return n;let f={scrollLeft:0,scrollTop:0},h=wr(1);const m=wr(0),E=vr(r);if((E||!E&&!u)&&((Fs(r)!=="body"||Qo(a))&&(f=ol(r)),vr(r))){const T=Yi(r);h=Bs(r),m.x=T.x+r.clientLeft,m.y=T.y+r.clientTop}const b=a&&!E&&!u?b1(a,f):wr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-f.scrollLeft*h.x+m.x+b.x,y:n.y*h.y-f.scrollTop*h.y+m.y+b.y}}function pk(e){return Array.from(e.getClientRects())}function mk(e){const t=Ar(e),n=ol(e),r=e.ownerDocument.body,o=Pn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),u=Pn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+ul(e);const c=-n.scrollTop;return cr(r).direction==="rtl"&&(a+=Pn(t.clientWidth,r.clientWidth)-o),{width:o,height:u,x:a,y:c}}const _1=25;function gk(e,t){const n=Rn(e),r=Ar(e),o=n.visualViewport;let u=r.clientWidth,a=r.clientHeight,c=0,f=0;if(o){u=o.width,a=o.height;const m=bd();(!m||m&&t==="fixed")&&(c=o.offsetLeft,f=o.offsetTop)}const h=ul(r);if(h<=0){const m=r.ownerDocument,E=m.body,b=getComputedStyle(E),T=m.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,_=Math.abs(r.clientWidth-E.clientWidth-T);_<=_1&&(u-=_)}else h<=_1&&(u+=h);return{width:u,height:a,x:c,y:f}}const Ek=new Set(["absolute","fixed"]);function yk(e,t){const n=Yi(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,u=vr(e)?Bs(e):wr(1),a=e.clientWidth*u.x,c=e.clientHeight*u.y,f=o*u.x,h=r*u.y;return{width:a,height:c,x:f,y:h}}function x1(e,t,n){let r;if(t==="viewport")r=gk(e,n);else if(t==="document")r=mk(Ar(e));else if(lr(t))r=yk(t,n);else{const o=T1(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return rl(r)}function S1(e,t){const n=di(e);return n===t||!lr(n)||Ms(n)?!1:cr(n).position==="fixed"||S1(n,t)}function Tk(e,t){const n=t.get(e);if(n)return n;let r=Xo(e,[],!1).filter(c=>lr(c)&&Fs(c)!=="body"),o=null;const u=cr(e).position==="fixed";let a=u?di(e):e;for(;lr(a)&&!Ms(a);){const c=cr(a),f=Td(a);!f&&c.position==="fixed"&&(o=null),(u?!f&&!o:!f&&c.position==="static"&&!!o&&Ek.has(o.position)||Qo(a)&&!f&&S1(e,a))?r=r.filter(m=>m!==a):o=c,a=di(a)}return t.set(e,r),r}function bk(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?sl(t)?[]:Tk(t,this._c):[].concat(n),r],c=a[0],f=a.reduce((h,m)=>{const E=x1(t,m,o);return h.top=Pn(E.top,h.top),h.right=fi(E.right,h.right),h.bottom=fi(E.bottom,h.bottom),h.left=Pn(E.left,h.left),h},x1(t,c,o));return{width:f.right-f.left,height:f.bottom-f.top,x:f.left,y:f.top}}function _k(e){const{width:t,height:n}=y1(e);return{width:t,height:n}}function xk(e,t,n){const r=vr(t),o=Ar(t),u=n==="fixed",a=Yi(e,!0,u,t);let c={scrollLeft:0,scrollTop:0};const f=wr(0);function h(){f.x=ul(o)}if(r||!r&&!u)if((Fs(t)!=="body"||Qo(o))&&(c=ol(t)),r){const T=Yi(t,!0,u,t);f.x=T.x+t.clientLeft,f.y=T.y+t.clientTop}else o&&h();u&&!r&&o&&h();const m=o&&!r&&!u?b1(o,c):wr(0),E=a.left+c.scrollLeft-f.x-m.x,b=a.top+c.scrollTop-f.y-m.y;return{x:E,y:b,width:a.width,height:a.height}}function Sd(e){return cr(e).position==="static"}function w1(e,t){if(!vr(e)||cr(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ar(e)===n&&(n=n.ownerDocument.body),n}function C1(e,t){const n=Rn(e);if(sl(e))return n;if(!vr(e)){let o=di(e);for(;o&&!Ms(o);){if(lr(o)&&!Sd(o))return o;o=di(o)}return n}let r=w1(e,t);for(;r&&ik(r)&&Sd(r);)r=w1(r,t);return r&&Ms(r)&&Sd(r)&&!Td(r)?n:r||lk(e)||n}const Sk=function(e){return it(this,null,function*(){const t=this.getOffsetParent||C1,n=this.getDimensions,r=yield n(e.floating);return{reference:xk(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function wk(e){return cr(e).direction==="rtl"}const Ck={convertOffsetParentRelativeRectToViewportRelativeRect:hk,getDocumentElement:Ar,getClippingRect:bk,getOffsetParent:C1,getElementRects:Sk,getClientRects:pk,getDimensions:_k,getScale:Bs,isElement:lr,isRTL:wk};function A1(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Ak(e,t){let n=null,r;const o=Ar(e);function u(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function a(c,f){c===void 0&&(c=!1),f===void 0&&(f=1),u();const h=e.getBoundingClientRect(),{left:m,top:E,width:b,height:T}=h;if(c||t(),!b||!T)return;const _=tl(E),S=tl(o.clientWidth-(m+b)),C=tl(o.clientHeight-(E+T)),k=tl(m),D={rootMargin:-_+"px "+-S+"px "+-C+"px "+-k+"px",threshold:Pn(0,fi(1,f))||1};let G=!0;function q(B){const te=B[0].intersectionRatio;if(te!==f){if(!G)return a();te?a(!1,te):r=setTimeout(()=>{a(!1,1e-7)},1e3)}te===1&&!A1(h,e.getBoundingClientRect())&&a(),G=!1}try{n=new IntersectionObserver(q,ye(U({},D),{root:o.ownerDocument}))}catch(B){n=new IntersectionObserver(q,D)}n.observe(e)}return a(!0),u}function vk(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:u=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:f=!1}=r,h=xd(e),m=o||u?[...h?Xo(h):[],...Xo(t)]:[];m.forEach(k=>{o&&k.addEventListener("scroll",n,{passive:!0}),u&&k.addEventListener("resize",n)});const E=h&&c?Ak(h,n):null;let b=-1,T=null;a&&(T=new ResizeObserver(k=>{let[M]=k;M&&M.target===h&&T&&(T.unobserve(t),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var D;(D=T)==null||D.observe(t)})),n()}),h&&!f&&T.observe(h),T.observe(t));let _,S=f?Yi(e):null;f&&C();function C(){const k=Yi(e);S&&!A1(S,k)&&n(),S=k,_=requestAnimationFrame(C)}return n(),()=>{var k;m.forEach(M=>{o&&M.removeEventListener("scroll",n),u&&M.removeEventListener("resize",n)}),E==null||E(),(k=T)==null||k.disconnect(),T=null,f&&cancelAnimationFrame(_)}}const kk=Jv,Nk=Zv,Ok=Kv,Ik=tk,Pk=Qv,Rk=Gv,Lk=ek,Dk=(e,t,n)=>{const r=new Map,o=U({platform:Ck},n),u=ye(U({},o.platform),{_c:r});return Wv(e,t,ye(U({},o),{platform:u}))};function v1(e=0,t=0,n=0,r=0){if(typeof DOMRect=="function")return new DOMRect(e,t,n,r);const o={x:e,y:t,width:n,height:r,top:t,right:e+n,bottom:t+r,left:e};return ye(U({},o),{toJSON:()=>o})}function Fk(e){if(!e)return v1();const{x:t,y:n,width:r,height:o}=e;return v1(t,n,r,o)}function Mk(e,t){return{contextElement:Vt(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?Fk(r):n.getBoundingClientRect()}}}var Jo=e=>({variable:e,reference:`var(${e})`}),Kr={arrowSize:Jo("--arrow-size"),arrowSizeHalf:Jo("--arrow-size-half"),arrowBg:Jo("--arrow-background"),transformOrigin:Jo("--transform-origin"),arrowOffset:Jo("--arrow-offset")},Bk=e=>e==="top"||e==="bottom"?"y":"x";function Uk(e,t){return{name:"transformOrigin",fn(n){var Se,H,fe,de,ue;const{elements:r,middlewareData:o,placement:u,rects:a,y:c}=n,f=u.split("-")[0],h=Bk(f),m=((Se=o.arrow)==null?void 0:Se.x)||0,E=((H=o.arrow)==null?void 0:H.y)||0,b=(t==null?void 0:t.clientWidth)||0,T=(t==null?void 0:t.clientHeight)||0,_=m+b/2,S=E+T/2,C=Math.abs(((fe=o.shift)==null?void 0:fe.y)||0),k=a.reference.height/2,M=T/2,D=(ue=(de=e.offset)==null?void 0:de.mainAxis)!=null?ue:e.gutter,G=typeof D=="number"?D+M:D!=null?D:M,q=C>G,B={top:`${_}px calc(100% + ${G}px)`,bottom:`${_}px ${-G}px`,left:`calc(100% + ${G}px) ${S}px`,right:`${-G}px ${S}px`}[f],te=`${_}px ${a.reference.y+k-c}px`,Te=!!e.overlap&&h==="y"&&q;return r.floating.style.setProperty(Kr.transformOrigin.variable,Te?te:B),{data:{transformOrigin:Te?te:B}}}}}var Hk={name:"rects",fn({rects:e}){return{data:e}}},zk=e=>{if(e)return{name:"shiftArrow",fn({placement:t,middlewareData:n}){if(!n.arrow)return{};const{x:r,y:o}=n.arrow,u=t.split("-")[0];return Object.assign(e.style,{left:r!=null?`${r}px`:"",top:o!=null?`${o}px`:"",[u]:`calc(100% + ${Kr.arrowOffset.reference})`}),{}}}};function jk(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var $k={strategy:"absolute",placement:"bottom",listeners:!0,gutter:8,flip:!0,slide:!0,overlap:!1,sameWidth:!1,fitViewport:!1,overflowPadding:8,arrowPadding:4};function k1(e,t){const n=e.devicePixelRatio||1;return Math.round(t*n)/n}function wd(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function Vk(e,t,n){const r=e||t.createElement("div");return Rk({element:r,padding:n.arrowPadding})}function qk(e,t){var n;if(!hA((n=t.offset)!=null?n:t.gutter))return kk(({placement:r})=>{var m,E,b,T;const o=((e==null?void 0:e.clientHeight)||0)/2,u=(E=(m=t.offset)==null?void 0:m.mainAxis)!=null?E:t.gutter,a=typeof u=="number"?u+o:u!=null?u:o,{hasAlign:c}=jk(r),f=c?void 0:t.shift,h=(T=(b=t.offset)==null?void 0:b.crossAxis)!=null?T:f;return Kf({crossAxis:h,mainAxis:a,alignmentAxis:t.shift})})}function Yk(e){if(!e.flip)return;const t=wd(e.boundary);return Ok(ye(U({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function Wk(e){if(!e.slide&&!e.overlap)return;const t=wd(e.boundary);return Nk(ye(U({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:Lk()}))}function Gk(e){return Ik({padding:e.overflowPadding,apply({elements:t,rects:n,availableHeight:r,availableWidth:o}){const u=t.floating,a=Math.round(n.reference.width),c=Math.round(n.reference.height);o=Math.floor(o),r=Math.floor(r),u.style.setProperty("--reference-width",`${a}px`),u.style.setProperty("--reference-height",`${c}px`),u.style.setProperty("--available-width",`${o}px`),u.style.setProperty("--available-height",`${r}px`)}})}function Kk(e){var t;if(e.hideWhenDetached)return Pk({strategy:"referenceHidden",boundary:(t=wd(e.boundary))!=null?t:"clippingAncestors"})}function Qk(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function Xk(e,t,n={}){const r=Mk(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},$k,n),u=t.querySelector("[data-part=arrow]"),a=[qk(u,o),Yk(o),Wk(o),Vk(u,t.ownerDocument,o),zk(u),Uk({gutter:o.gutter,offset:o.offset,overlap:o.overlap},u),Gk(o),Kk(o),Hk],{placement:c,strategy:f,onComplete:h,onPositioned:m}=o,E=()=>it(null,null,function*(){var G;if(!r||!t)return;const S=yield Dk(r,t,{placement:c,middleware:a,strategy:f});h==null||h(S),m==null||m({placed:!0});const C=Ns(t),k=k1(C,S.x),M=k1(C,S.y);t.style.setProperty("--x",`${k}px`),t.style.setProperty("--y",`${M}px`),o.hideWhenDetached&&(((G=S.middlewareData.hide)==null?void 0:G.referenceHidden)?(t.style.setProperty("visibility","hidden"),t.style.setProperty("pointer-events","none")):(t.style.removeProperty("visibility"),t.style.removeProperty("pointer-events")));const D=t.firstElementChild;if(D){const q=Wa(D);t.style.setProperty("--z-index",q.zIndex)}}),b=()=>it(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),m==null||m({placed:!0})):yield E()}),T=Qk(o.listeners),_=o.listeners?vk(r,t,b,T):xA;return b(),()=>{_==null||_(),m==null||m({placed:!1})}}function N1(e,t,n={}){const c=n,{defer:r}=c,o=Xt(c,["defer"]),u=r?_n:f=>f(),a=[];return a.push(u(()=>{const f=typeof e=="function"?e():e,h=typeof t=="function"?t():t;a.push(Xk(f,h,o))})),()=>{a.forEach(f=>f==null?void 0:f())}}var Jk={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function Zk(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:Kr.arrowSize.reference,height:Kr.arrowSize.reference,[Kr.arrowSizeHalf.variable]:`calc(${Kr.arrowSize.reference} / 2)`,[Kr.arrowOffset.variable]:`calc(${Kr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?Jk[t.split("-")[0]]:void 0,background:Kr.arrowBg.reference,top:"0",left:"0",width:"100%",height:"100%",position:"absolute",zIndex:"inherit"},floating:{position:o,isolation:"isolate",minWidth:n?void 0:"max-content",width:n?"var(--reference-width)":void 0,maxWidth:r?"var(--available-width)":void 0,maxHeight:r?"var(--available-height)":void 0,pointerEvents:t?void 0:"none",top:"0px",left:"0px",transform:t?"translate3d(var(--x), var(--y), 0)":"translate3d(0, -100vh, 0)",zIndex:"var(--z-index)"}}}var Us=new WeakMap,al=new WeakMap,ll={},Cd=0,O1=e=>e&&(e.host||O1(e.parentNode)),eN=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=O1(n);return r&&e.contains(r)?r:(console.error("[zag-js > ariaHidden] target",n,"in not contained inside",e,". Doing nothing"),null)}).filter(n=>!!n),tN=new Set(["script","output","status","next-route-announcer"]),nN=e=>tN.has(e.localName)||e.role==="status"||e.hasAttribute("aria-live")?!0:e.matches("[data-live-announcer]"),rN=(e,t)=>{const{parentNode:n,markerName:r,controlAttribute:o,followControlledElements:u=!0}=t,a=eN(n,Array.isArray(e)?e:[e]);ll[r]||(ll[r]=new WeakMap);const c=ll[r],f=[],h=new Set,m=new Set(a),E=T=>{!T||h.has(T)||(h.add(T),E(T.parentNode))};a.forEach(T=>{E(T),u&&Vt(T)&&Ug(T,_=>{E(_)})});const b=T=>{!T||m.has(T)||Array.prototype.forEach.call(T.children,_=>{if(h.has(_))b(_);else try{if(nN(_))return;const C=_.getAttribute(o)==="true",k=(Us.get(_)||0)+1,M=(c.get(_)||0)+1;Us.set(_,k),c.set(_,M),f.push(_),k===1&&C&&al.set(_,!0),M===1&&_.setAttribute(r,""),C||_.setAttribute(o,"true")}catch(S){console.error("[zag-js > ariaHidden] cannot operate on ",_,S)}})};return b(n),h.clear(),Cd++,()=>{f.forEach(T=>{const _=Us.get(T)-1,S=c.get(T)-1;Us.set(T,_),c.set(T,S),_||(al.has(T)||T.removeAttribute(o),al.delete(T)),S||T.removeAttribute(r)}),Cd--,Cd||(Us=new WeakMap,Us=new WeakMap,al=new WeakMap,ll={})}},iN=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,sN=(e,t=iN(e),n="data-aria-hidden",r=!0)=>{if(t)return rN(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},oN=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function I1(e,t={}){const{defer:n=!0}=t,r=n?oN:u=>u(),o=[];return o.push(r(()=>{const a=(typeof e=="function"?e():e).filter(Boolean);a.length!==0&&o.push(sN(a))})),()=>{o.forEach(u=>u==null?void 0:u())}}function uN(e){const t={each(n){var r;for(let o=0;o<((r=e.frames)==null?void 0:r.length);o+=1){const u=e.frames[o];u&&n(u)}},addEventListener(n,r,o){return t.each(u=>{try{u.document.addEventListener(n,r,o)}catch(a){}}),()=>{try{t.removeEventListener(n,r,o)}catch(u){}}},removeEventListener(n,r,o){t.each(u=>{try{u.document.removeEventListener(n,r,o)}catch(a){}})}};return t}function aN(e){const t=e.frameElement!=null?e.parent:null;return{addEventListener:(n,r,o)=>{try{t==null||t.addEventListener(n,r,o)}catch(u){}return()=>{try{t==null||t.removeEventListener(n,r,o)}catch(u){}}},removeEventListener:(n,r,o)=>{try{t==null||t.removeEventListener(n,r,o)}catch(u){}}}}var P1="pointerdown.outside",R1="focus.outside";function lN(e){for(const t of e)if(Vt(t)&&Yr(t))return!0;return!1}var L1=e=>"clientY"in e;function cN(e,t){if(!L1(t)||!e)return!1;const n=e.getBoundingClientRect();return n.width===0||n.height===0?!1:n.top<=t.clientY&&t.clientY<=n.top+n.height&&n.left<=t.clientX&&t.clientX<=n.left+n.width}function fN(e,t){return e.y<=t.y&&t.y<=e.y+e.height&&e.x<=t.x&&t.x<=e.x+e.width}function D1(e,t){if(!t||!L1(e))return!1;const n=t.scrollHeight>t.clientHeight,r=n&&e.clientX>t.offsetLeft+t.clientWidth,o=t.scrollWidth>t.clientWidth,u=o&&e.clientY>t.offsetTop+t.clientHeight,a={x:t.offsetLeft,y:t.offsetTop,width:t.clientWidth+(n?16:0),height:t.clientHeight+(o?16:0)},c={x:e.clientX,y:e.clientY};return fN(a,c)?r||u:!1}function dN(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:u,defer:a,followControlledElements:c=!0}=t;if(!e)return;const f=Sr(e),h=Ns(e),m=uN(h),E=aN(h);function b(D,G){if(!Vt(G)||!G.isConnected||Ya(e,G)||cN(e,D)||c&&Bg(e,G))return!1;const q=f.querySelector(`[aria-controls="${e.id}"]`);if(q){const te=id(q);if(D1(D,te))return!1}const B=id(e);return D1(D,B)?!1:!(n!=null&&n(G))}const T=new Set,_=Vi(e==null?void 0:e.getRootNode());function S(D){function G(q){var Se,H;const B=a&&!Hg()?_n:fe=>fe(),te=q!=null?q:D,Te=(H=(Se=te==null?void 0:te.composedPath)==null?void 0:Se.call(te))!=null?H:[te==null?void 0:te.target];B(()=>{const fe=_?Te[0]:qr(D);if(!(!e||!b(D,fe))){if(o||u){const de=Gf(o,u);e.addEventListener(P1,de,{once:!0})}F1(e,P1,{bubbles:!1,cancelable:!0,detail:{originalEvent:te,contextmenu:ev(te),focusable:lN(Te),target:fe}})}})}D.pointerType==="touch"?(T.forEach(q=>q()),T.add(ur(f,"click",G,{once:!0})),T.add(E.addEventListener("click",G,{once:!0})),T.add(m.addEventListener("click",G,{once:!0}))):G()}const C=new Set,k=setTimeout(()=>{C.add(ur(f,"pointerdown",S,!0)),C.add(E.addEventListener("pointerdown",S,!0)),C.add(m.addEventListener("pointerdown",S,!0))},0);function M(D){(a?_n:q=>q())(()=>{var te,Te;const q=(Te=(te=D==null?void 0:D.composedPath)==null?void 0:te.call(D))!=null?Te:[D==null?void 0:D.target],B=_?q[0]:qr(D);if(!(!e||!b(D,B))){if(r||u){const Se=Gf(r,u);e.addEventListener(R1,Se,{once:!0})}F1(e,R1,{bubbles:!1,cancelable:!0,detail:{originalEvent:D,contextmenu:!1,focusable:Yr(B),target:B}})}})}return Hg()||(C.add(ur(f,"focusin",M,!0)),C.add(E.addEventListener("focusin",M,!0)),C.add(m.addEventListener("focusin",M,!0))),()=>{clearTimeout(k),T.forEach(D=>D()),C.forEach(D=>D())}}function hN(e,t){const{defer:n}=t,r=n?_n:u=>u(),o=[];return o.push(r(()=>{const u=typeof e=="function"?e():e;o.push(dN(u,t))})),()=>{o.forEach(u=>u==null?void 0:u())}}function F1(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function pN(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return ur(Sr(e),"keydown",n,{capture:!0})}var M1="layer:request-dismiss",qn={layers:[],branches:[],count(){return this.layers.length},pointerBlockingLayers(){return this.layers.filter(e=>e.pointerBlocking)},topMostPointerBlockingLayer(){return[...this.pointerBlockingLayers()].slice(-1)[0]},hasPointerBlockingLayer(){return this.pointerBlockingLayers().length>0},isBelowPointerBlockingLayer(e){var r;const t=this.indexOf(e),n=this.topMostPointerBlockingLayer()?this.indexOf((r=this.topMostPointerBlockingLayer())==null?void 0:r.node):-1;return t<n},isTopMost(e){const t=this.layers[this.count()-1];return(t==null?void 0:t.node)===e},getNestedLayers(e){return Array.from(this.layers).slice(this.indexOf(e)+1)},getLayersByType(e){return this.layers.filter(t=>t.type===e)},getNestedLayersByType(e,t){const n=this.indexOf(e);return n===-1?[]:this.layers.slice(n+1).filter(r=>r.type===t)},getParentLayerOfType(e,t){const n=this.indexOf(e);if(!(n<=0))return this.layers.slice(0,n).reverse().find(r=>r.type===t)},countNestedLayersOfType(e,t){return this.getNestedLayersByType(e,t).length},isInNestedLayer(e,t){return this.getNestedLayers(e).some(n=>Ya(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>Ya(t,e))},add(e){this.layers.push(e),this.syncLayers()},addBranch(e){this.branches.push(e)},remove(e){const t=this.indexOf(e);t<0||(t<this.count()-1&&this.getNestedLayers(e).forEach(r=>qn.dismiss(r.node,e)),this.layers.splice(t,1),this.syncLayers())},removeBranch(e){const t=this.branches.indexOf(e);t>=0&&this.branches.splice(t,1)},syncLayers(){this.layers.forEach((e,t)=>{e.node.style.setProperty("--layer-index",`${t}`),e.node.removeAttribute("data-nested"),e.node.removeAttribute("data-has-nested"),this.getParentLayerOfType(e.node,e.type)&&e.node.setAttribute("data-nested",e.type);const r=this.countNestedLayersOfType(e.node,e.type);r>0&&e.node.setAttribute("data-has-nested",e.type),e.node.style.setProperty("--nested-layer-count",`${r}`)})},indexOf(e){return this.layers.findIndex(t=>t.node===e)},dismiss(e,t){const n=this.indexOf(e);if(n===-1)return;const r=this.layers[n];gN(e,M1,o=>{var u;(u=r.requestDismiss)==null||u.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),mN(e,M1,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function mN(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,{cancelable:!0,bubbles:!0,detail:n});return e.dispatchEvent(o)}function gN(e,t,n){e.addEventListener(t,n,{once:!0})}var B1;function U1(){qn.layers.forEach(({node:e})=>{e.style.pointerEvents=qn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function EN(e){e.style.pointerEvents=""}function yN(e,t){const n=Sr(e),r=[];return qn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(B1=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[u,a]=gv(()=>{const c=o();return Vt(c)?c:null},{timeout:1e3});u.then(c=>r.push(Ka(c,{pointerEvents:"auto"}))),r.push(a)}),()=>{qn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=B1,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function TN(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Qf("[@zag-js/dismissable] node is `null` or `undefined`");return}if(!e)return;const{onDismiss:r,onRequestDismiss:o,pointerBlocking:u,exclude:a,debug:c,type:f="dialog"}=t,h={dismiss:r,node:e,type:f,pointerBlocking:u,requestDismiss:o};qn.add(h),U1();function m(S){var k,M;const C=qr(S.detail.originalEvent);qn.isBelowPointerBlockingLayer(e)||qn.isInBranch(C)||((k=t.onPointerDownOutside)==null||k.call(t,S),(M=t.onInteractOutside)==null||M.call(t,S),!S.defaultPrevented&&(c&&console.log("onPointerDownOutside:",S.detail.originalEvent),r==null||r()))}function E(S){var k,M;const C=qr(S.detail.originalEvent);qn.isInBranch(C)||((k=t.onFocusOutside)==null||k.call(t,S),(M=t.onInteractOutside)==null||M.call(t,S),!S.defaultPrevented&&(c&&console.log("onFocusOutside:",S.detail.originalEvent),r==null||r()))}function b(S){var C;qn.isTopMost(e)&&((C=t.onEscapeKeyDown)==null||C.call(t,S),!S.defaultPrevented&&r&&(S.preventDefault(),r()))}function T(S){var D;if(!e)return!1;const C=typeof a=="function"?a():a,k=Array.isArray(C)?C:[C],M=(D=t.persistentElements)==null?void 0:D.map(G=>G()).filter(Vt);return M&&k.push(...M),k.some(G=>Ya(G,S))||qn.isInNestedLayer(e,S)}const _=[u?yN(e,t.persistentElements):void 0,pN(e,b),hN(e,{exclude:T,onFocusOutside:E,onPointerDownOutside:m,defer:t.defer})];return()=>{qn.remove(e),U1(),EN(e),_.forEach(S=>S==null?void 0:S())}}function H1(e,t){const{defer:n}=t,r=n?_n:u=>u(),o=[];return o.push(r(()=>{const u=ks(e)?e():e;o.push(TN(u,t))})),()=>{o.forEach(u=>u==null?void 0:u())}}var bN=Object.defineProperty,_N=(e,t,n)=>t in e?bN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Et=(e,t,n)=>_N(e,typeof t!="symbol"?t+"":t,n),z1={activateTrap(e,t){if(e.length>0){const r=e[e.length-1];r!==t&&r.pause()}const n=e.indexOf(t);n===-1||e.splice(n,1),e.push(t)},deactivateTrap(e,t){const n=e.indexOf(t);n!==-1&&e.splice(n,1),e.length>0&&e[e.length-1].unpause()}},xN=[],SN=class{constructor(e,t){Et(this,"trapStack"),Et(this,"config"),Et(this,"doc"),Et(this,"state",{containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0}),Et(this,"portalContainers",new Set),Et(this,"listenerCleanups",[]),Et(this,"handleFocus",r=>{const o=qr(r),u=this.findContainerIndex(o,r)>=0;if(u||qa(o))u&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let a,c=!0;if(this.state.mostRecentlyFocusedNode)if(Wo(this.state.mostRecentlyFocusedNode)>0){const f=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:h}=this.state.containerGroups[f];if(h.length>0){const m=h.findIndex(E=>E===this.state.mostRecentlyFocusedNode);m>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?m+1<h.length&&(a=h[m+1],c=!1):m-1>=0&&(a=h[m-1],c=!1))}}else this.state.containerGroups.some(f=>f.tabbableNodes.some(h=>Wo(h)>0))||(c=!1);else c=!1;c&&(a=this.findNextNavNode({target:this.state.mostRecentlyFocusedNode,isBackward:this.config.isKeyBackward(this.state.recentNavEvent)})),a?this.tryFocus(a):this.tryFocus(this.state.mostRecentlyFocusedNode||this.getInitialFocusNode())}this.state.recentNavEvent=void 0}),Et(this,"handlePointerDown",r=>{const o=qr(r);if(!(this.findContainerIndex(o,r)>=0)){if(eu(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}eu(this.config.allowOutsideClick,r)||r.preventDefault()}}),Et(this,"handleClick",r=>{const o=qr(r);this.findContainerIndex(o,r)>=0||eu(this.config.clickOutsideDeactivates,r)||eu(this.config.allowOutsideClick,r)||(r.preventDefault(),r.stopImmediatePropagation())}),Et(this,"handleTabKey",r=>{if(this.config.isKeyForward(r)||this.config.isKeyBackward(r)){this.state.recentNavEvent=r;const o=this.config.isKeyBackward(r),u=this.findNextNavNode({event:r,isBackward:o});if(!u)return;Zo(r)&&r.preventDefault(),this.tryFocus(u)}}),Et(this,"handleEscapeKey",r=>{wN(r)&&eu(this.config.escapeDeactivates,r)!==!1&&(r.preventDefault(),this.deactivate())}),Et(this,"_mutationObserver"),Et(this,"setupMutationObserver",()=>{const r=this.doc.defaultView||window;this._mutationObserver=new r.MutationObserver(o=>{o.some(c=>Array.from(c.removedNodes).some(h=>h===this.state.mostRecentlyFocusedNode))&&this.tryFocus(this.getInitialFocusNode()),o.some(c=>c.type==="attributes"&&(c.attributeName==="aria-controls"||c.attributeName==="aria-expanded")?!0:c.type==="childList"&&c.addedNodes.length>0?Array.from(c.addedNodes).some(f=>{if(f.nodeType!==Node.ELEMENT_NODE)return!1;const h=f;return VA(h)?!0:h.id&&!this.state.containers.some(m=>m.contains(h))?qA(h):!1}):!1)&&this.state.active&&!this.state.paused&&(this.updateTabbableNodes(),this.updatePortalContainers())})}),Et(this,"updateObservedNodes",()=>{var r;(r=this._mutationObserver)==null||r.disconnect(),this.state.active&&!this.state.paused&&(this.state.containers.map(o=>{var u;(u=this._mutationObserver)==null||u.observe(o,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}),this.portalContainers.forEach(o=>{this.observePortalContainer(o)}))}),Et(this,"getInitialFocusNode",()=>{let r=this.getNodeForOption("initialFocus",{hasFallback:!0});if(r===!1)return!1;if(r===void 0||r&&!Yr(r)){const o=Os(this.doc);if(o&&this.findContainerIndex(o)>=0)r=o;else{const u=this.state.tabbableGroups[0];r=u&&u.firstTabbableNode||this.getNodeForOption("fallbackFocus")}}else r===null&&(r=this.getNodeForOption("fallbackFocus"));if(!r)throw new Error("Your focus-trap needs to have at least one focusable element");return r.isConnected||(r=this.getNodeForOption("fallbackFocus")),r}),Et(this,"tryFocus",r=>{if(r!==!1&&r!==Os(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,CN(r)&&r.select()}}),Et(this,"deactivate",r=>{if(!this.state.active)return this;const o=U({onDeactivate:this.config.onDeactivate,onPostDeactivate:this.config.onPostDeactivate,checkCanReturnFocus:this.config.checkCanReturnFocus},r);clearTimeout(this.state.delayInitialFocusTimer),this.state.delayInitialFocusTimer=void 0,this.removeListeners(),this.state.active=!1,this.state.paused=!1,this.updateObservedNodes(),z1.deactivateTrap(this.trapStack,this),this.portalContainers.clear();const u=this.getOption(o,"onDeactivate"),a=this.getOption(o,"onPostDeactivate"),c=this.getOption(o,"checkCanReturnFocus"),f=this.getOption(o,"returnFocus","returnFocusOnDeactivate");u==null||u();const h=()=>{j1(()=>{if(f){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(m)}a==null||a()})};if(f&&c){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);return c(m).then(h,h),this}return h(),this}),Et(this,"pause",r=>{if(this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onPause"),u=this.getOption(r,"onPostPause");return this.state.paused=!0,o==null||o(),this.removeListeners(),this.updateObservedNodes(),u==null||u(),this}),Et(this,"unpause",r=>{if(!this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onUnpause"),u=this.getOption(r,"onPostUnpause");return this.state.paused=!1,o==null||o(),this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),u==null||u(),this}),Et(this,"updateContainerElements",r=>(this.state.containers=Array.isArray(r)?r.filter(Boolean):[r].filter(Boolean),this.state.active&&this.updateTabbableNodes(),this.updateObservedNodes(),this)),Et(this,"getReturnFocusNode",r=>{const o=this.getNodeForOption("setReturnFocus",{params:[r]});return o||(o===!1?!1:r)}),Et(this,"getOption",(r,o,u)=>r&&r[o]!==void 0?r[o]:this.config[u||o]),Et(this,"getNodeForOption",(r,{hasFallback:o=!1,params:u=[]}={})=>{let a=this.config[r];if(typeof a=="function"&&(a=a(...u)),a===!0&&(a=void 0),!a){if(a===void 0||a===!1)return a;throw new Error(`\`${r}\` was specified but was not a node, or did not return a node`)}let c=a;if(typeof a=="string"){try{c=this.doc.querySelector(a)}catch(f){throw new Error(`\`${r}\` appears to be an invalid selector; error="${f.message}"`)}if(!c&&!o)throw new Error(`\`${r}\` as selector refers to no known node`)}return c}),Et(this,"findNextNavNode",r=>{const{event:o,isBackward:u=!1}=r,a=r.target||qr(o);this.updateTabbableNodes();let c=null;if(this.state.tabbableGroups.length>0){const f=this.findContainerIndex(a,o),h=f>=0?this.state.containerGroups[f]:void 0;if(f<0)u?c=this.state.tabbableGroups[this.state.tabbableGroups.length-1].lastTabbableNode:c=this.state.tabbableGroups[0].firstTabbableNode;else if(u){let m=this.state.tabbableGroups.findIndex(({firstTabbableNode:E})=>a===E);if(m<0&&((h==null?void 0:h.container)===a||Yr(a)&&!qi(a)&&!(h!=null&&h.nextTabbableNode(a,!1)))&&(m=f),m>=0){const E=m===0?this.state.tabbableGroups.length-1:m-1,b=this.state.tabbableGroups[E];c=Wo(a)>=0?b.lastTabbableNode:b.lastDomTabbableNode}else Zo(o)||(c=h==null?void 0:h.nextTabbableNode(a,!1))}else{let m=this.state.tabbableGroups.findIndex(({lastTabbableNode:E})=>a===E);if(m<0&&((h==null?void 0:h.container)===a||Yr(a)&&!qi(a)&&!(h!=null&&h.nextTabbableNode(a)))&&(m=f),m>=0){const E=m===this.state.tabbableGroups.length-1?0:m+1,b=this.state.tabbableGroups[E];c=Wo(a)>=0?b.firstTabbableNode:b.firstDomTabbableNode}else Zo(o)||(c=h==null?void 0:h.nextTabbableNode(a))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||xN;const n=U({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return Zo(r)&&!r.shiftKey},isKeyBackward(r){return Zo(r)&&r.shiftKey}},t);this.doc=n.document||Sr(Array.isArray(e)?e[0]:e),this.config=n,this.updateContainerElements(e),this.setupMutationObserver()}addPortalContainer(e){const t=e.parentElement;t&&!this.portalContainers.has(t)&&(this.portalContainers.add(t),this.state.active&&!this.state.paused&&this.observePortalContainer(t))}observePortalContainer(e){var t;(t=this._mutationObserver)==null||t.observe(e,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}updatePortalContainers(){this.config.followControlledElements&&this.state.containers.forEach(e=>{zA(e).forEach(n=>{this.addPortalContainer(n)})})}get active(){return this.state.active}get paused(){return this.state.paused}findContainerIndex(e,t){const n=typeof(t==null?void 0:t.composedPath)=="function"?t.composedPath():void 0;return this.state.containerGroups.findIndex(({container:r,tabbableNodes:o})=>r.contains(e)||(n==null?void 0:n.includes(r))||o.find(u=>u===e)||this.isControlledElement(r,e))}isControlledElement(e,t){return this.config.followControlledElements?Bg(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Yo(e,{getShadowRoot:this.config.getShadowRoot}),n=qg(e,{getShadowRoot:this.config.getShadowRoot}),r=t[0],o=t[t.length-1],u=r,a=o;let c=!1;for(let h=0;h<t.length;h++)if(Wo(t[h])>0){c=!0;break}function f(h,m=!0){const E=t.indexOf(h);if(E>=0)return t[E+(m?1:-1)];const b=n.indexOf(h);if(!(b<0)){if(m){for(let T=b+1;T<n.length;T++)if(qi(n[T]))return n[T]}else for(let T=b-1;T>=0;T--)if(qi(n[T]))return n[T]}}return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:c,firstTabbableNode:r,lastTabbableNode:o,firstDomTabbableNode:u,lastDomTabbableNode:a,nextTabbableNode:f}}),this.state.tabbableGroups=this.state.containerGroups.filter(e=>e.tabbableNodes.length>0),this.state.tabbableGroups.length<=0&&!this.getNodeForOption("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(this.state.containerGroups.find(e=>e.posTabIndexesFound)&&this.state.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")}addListeners(){if(this.state.active)return z1.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?j1(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(ur(this.doc,"focusin",this.handleFocus,!0),ur(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),ur(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),ur(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),ur(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),ur(this.doc,"keydown",this.handleEscapeKey)),this}removeListeners(){if(this.state.active)return this.listenerCleanups.forEach(e=>e()),this.listenerCleanups=[],this}activate(e){if(this.state.active)return this;const t=this.getOption(e,"onActivate"),n=this.getOption(e,"onPostActivate"),r=this.getOption(e,"checkCanFocusTrap");r||this.updateTabbableNodes(),this.state.active=!0,this.state.paused=!1,this.state.nodeFocusedBeforeActivation=Os(this.doc),t==null||t();const o=()=>{r&&this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),n==null||n()};return r?(r(this.state.containers.concat()).then(o,o),this):(o(),this)}},Zo=e=>e.key==="Tab",eu=(e,...t)=>typeof e=="function"?e(...t):e,wN=e=>!e.isComposing&&e.key==="Escape",j1=e=>setTimeout(e,0),CN=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function $1(e,t={}){let n;const r=_n(()=>{const o=typeof e=="function"?e():e;if(o){n=new SN(o,ye(U({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:Sr(o)}));try{n.activate()}catch(u){}}});return function(){n==null||n.deactivate(),r()}}var Ad="data-scroll-lock";function AN(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function V1(e){const t=Wa(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function q1(e){var T;const t=e!=null?e:document,n=(T=t.defaultView)!=null?T:window,{documentElement:r,body:o}=t;if(o.hasAttribute(Ad))return;const a=V1(r)||V1(o),c=n.innerWidth-r.clientWidth;o.setAttribute(Ad,"");const f=()=>pv(r,"--scrollbar-width",`${c}px`),h=AN(r),m=()=>{const _={overflow:"hidden"};return!a&&c>0&&(_[h]=`${c}px`),Ka(o,_)},E=()=>{var q,B;const{scrollX:_,scrollY:S,visualViewport:C}=n,k=(q=C==null?void 0:C.offsetLeft)!=null?q:0,M=(B=C==null?void 0:C.offsetTop)!=null?B:0,D={position:"fixed",overflow:"hidden",top:`${-(S-Math.floor(M))}px`,left:`${-(_-Math.floor(k))}px`,right:"0"};!a&&c>0&&(D[h]=`${c}px`);const G=Ka(o,D);return()=>{G==null||G(),n.scrollTo({left:_,top:S,behavior:"instant"})}},b=[f(),zg()?E():m()];return()=>{b.forEach(_=>_==null?void 0:_()),o.removeAttribute(Ad)}}var vN=Rs("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),kr=vN.build(),Y1=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},W1=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},vd=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},G1=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},kN=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},kd=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},Nd=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},NN=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},K1=e=>e.getById(Y1(e)),Hs=e=>e.getById(W1(e)),zs=e=>e.getById(vd(e)),Q1=e=>e.getById(G1(e)),ON=e=>e.getById(kd(e)),IN=e=>e.getById(Nd(e));function PN(e,t){const{state:n,context:r,send:o,computed:u,prop:a,scope:c}=e,f=n.matches("open"),h=r.get("currentPlacement"),m=u("currentPortalled"),E=r.get("renderedElements"),b=Zk(ye(U({},a("positioning")),{placement:h}));return{portalled:m,open:f,setOpen(T){n.matches("open")!==T&&o({type:T?"OPEN":"CLOSE"})},reposition(T={}){o({type:"POSITIONING.SET",options:T})},getArrowProps(){return t.element(ye(U({id:kN(c)},kr.arrow.attrs),{dir:a("dir"),style:b.arrow}))},getArrowTipProps(){return t.element(ye(U({},kr.arrowTip.attrs),{dir:a("dir"),style:b.arrowTip}))},getAnchorProps(){return t.element(ye(U({},kr.anchor.attrs),{dir:a("dir"),id:Y1(c)}))},getTriggerProps(){return t.button(ye(U({},kr.trigger.attrs),{dir:a("dir"),type:"button","data-placement":h,id:W1(c),"aria-haspopup":"dialog","aria-expanded":f,"data-state":f?"open":"closed","aria-controls":vd(c),onPointerDown(T){ZA(T)&&XA()&&T.currentTarget.focus()},onClick(T){T.defaultPrevented||o({type:"TOGGLE"})},onBlur(T){o({type:"TRIGGER_BLUR",target:T.relatedTarget})}}))},getIndicatorProps(){return t.element(ye(U({},kr.indicator.attrs),{dir:a("dir"),"data-state":f?"open":"closed"}))},getPositionerProps(){return t.element(ye(U({id:G1(c)},kr.positioner.attrs),{dir:a("dir"),style:b.floating}))},getContentProps(){return t.element(ye(U({},kr.content.attrs),{dir:a("dir"),id:vd(c),tabIndex:-1,role:"dialog","aria-modal":vA(a("modal")),hidden:!f,"data-state":f?"open":"closed","data-expanded":AA(f),"aria-labelledby":E.title?kd(c):void 0,"aria-describedby":E.description?Nd(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(ye(U({},kr.title.attrs),{id:kd(c),dir:a("dir")}))},getDescriptionProps(){return t.element(ye(U({},kr.description.attrs),{id:Nd(c),dir:a("dir")}))},getCloseTriggerProps(){return t.button(ye(U({},kr.closeTrigger.attrs),{dir:a("dir"),id:NN(c),type:"button","aria-label":"close",onClick(T){T.defaultPrevented||(T.stopPropagation(),o({type:"CLOSE"}))}}))}}}var RN={props({props:e}){return ye(U({closeOnInteractOutside:!0,closeOnEscape:!0,autoFocus:!0,modal:!1,portalled:!0},e),{positioning:U({placement:"bottom"},e.positioning)})},initialState({prop:e}){return e("open")||e("defaultOpen")?"open":"closed"},context({bindable:e}){return{currentPlacement:e(()=>({defaultValue:void 0})),renderedElements:e(()=>({defaultValue:{title:!0,description:!0}}))}},computed:{currentPortalled:({prop:e})=>!!e("modal")||!!e("portalled")},watch({track:e,prop:t,action:n}){e([()=>t("open")],()=>{n(["toggleVisibility"])})},entry:["checkRenderedElements"],states:{closed:{on:{"CONTROLLED.OPEN":{target:"open",actions:["setInitialFocus"]},TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen","setInitialFocus"]}],OPEN:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen","setInitialFocus"]}]}},open:{effects:["trapFocus","preventScroll","hideContentBelow","trackPositioning","trackDismissableElement","proxyTabFocus"],on:{"CONTROLLED.CLOSE":{target:"closed",actions:["setFinalFocus"]},CLOSE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose","setFinalFocus"]}],TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose"]}],"POSITIONING.SET":{actions:["reposition"]}}}},implementations:{guards:{isOpenControlled:({prop:e})=>e("open")!=null},effects:{trackPositioning({context:e,prop:t,scope:n}){var u;e.set("currentPlacement",t("positioning").placement);const r=(u=K1(n))!=null?u:Hs(n);return N1(r,()=>Q1(n),ye(U({},t("positioning")),{defer:!0,onComplete(a){e.set("currentPlacement",a.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>zs(n);let o=!0;return H1(r,{type:"popover",pointerBlocking:t("modal"),exclude:Hs(n),defer:!0,onEscapeKeyDown(u){var a;(a=t("onEscapeKeyDown"))==null||a(u),!t("closeOnEscape")&&u.preventDefault()},onInteractOutside(u){var a;(a=t("onInteractOutside"))==null||a(u),!u.defaultPrevented&&(o=!(u.detail.focusable||u.detail.contextmenu),t("closeOnInteractOutside")||u.preventDefault())},onPointerDownOutside:t("onPointerDownOutside"),onFocusOutside:t("onFocusOutside"),persistentElements:t("persistentElements"),onRequestDismiss:t("onRequestDismiss"),onDismiss(){e({type:"CLOSE",src:"interact-outside",restoreFocus:o})}})},proxyTabFocus({prop:e,scope:t}){return e("modal")||!e("portalled")?void 0:hv(()=>zs(t),{triggerElement:Hs(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?I1(()=>[zs(t),Hs(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return q1(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?$1(()=>zs(t),{initialFocus:()=>Yg({root:zs(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")}),getShadowRoot:!0}):void 0}},actions:{reposition({event:e,prop:t,scope:n,context:r}){var a;const o=(a=K1(n))!=null?a:Hs(n);N1(o,()=>Q1(n),ye(U(U({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){_n(()=>{Object.assign(e.get("renderedElements"),{title:!!ON(t),description:!!IN(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||_n(()=>{const n=Yg({root:zs(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")});n==null||n.focus({preventScroll:!0})})},setFinalFocus({event:e,scope:t}){var r,o;const n=(o=e.restoreFocus)!=null?o:(r=e.previousEvent)==null?void 0:r.restoreFocus;n!=null&&!n||_n(()=>{const u=Hs(t);u==null||u.focus({preventScroll:!0})})},invokeOnOpen({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!0})})},invokeOnClose({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!1})})},toggleVisibility({event:e,send:t,prop:n}){t({type:n("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:e})}}}};ld()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[qM,Od]=Ps({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[YM,X1]=Ps({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),LN=e=>{const t=W.useId(),{getRootNode:n}=Od(),{dir:r}=X1(),o=U({id:t,dir:r,getRootNode:n},e),u=cd(RN,o);return PN(u,n1)},DN=e=>{const[t,a]=u1(e),c=a,{children:n}=c,r=Xt(c,["children"]),o=LN(r),u=hd(ar({present:o.open},t));return I.jsx(Ov,{value:o,children:I.jsx(r1,{value:u,children:n})})},J1=W.forwardRef((e,t)=>{const n=dd(),r=Go(),o=ar(ye(U({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return I.jsx(ci.button,ye(U({},o),{ref:t}))});J1.displayName="PopoverTrigger";function FN(e){return hn({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M11.854 3.646a.5.5 0 0 1 0 .708L8.207 8l3.647 3.646a.5.5 0 0 1-.708.708l-4-4a.5.5 0 0 1 0-.708l4-4a.5.5 0 0 1 .708 0M4.5 1a.5.5 0 0 0-.5.5v13a.5.5 0 0 0 1 0v-13a.5.5 0 0 0-.5-.5"},child:[]}]})(e)}function MN(e){return hn({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M4.146 3.646a.5.5 0 0 0 0 .708L7.793 8l-3.647 3.646a.5.5 0 0 0 .708.708l4-4a.5.5 0 0 0 0-.708l-4-4a.5.5 0 0 0-.708 0M11.5 1a.5.5 0 0 1 .5.5v13a.5.5 0 0 1-1 0v-13a.5.5 0 0 1 .5-.5"},child:[]}]})(e)}function BN(e){return hn({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M3 9.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"},child:[]}]})(e)}function UN(e){return hn({attr:{version:"1.1",viewBox:"0 0 17 17"},child:[{tag:"g",attr:{},child:[]},{tag:"path",attr:{d:"M6 8h-6v-6h1v4.109c1.013-3.193 4.036-5.484 7.5-5.484 3.506 0 6.621 2.36 7.574 5.739l-0.963 0.271c-0.832-2.95-3.551-5.011-6.611-5.011-3.226 0.001-6.016 2.276-6.708 5.376h4.208v1zM11 9v1h4.208c-0.693 3.101-3.479 5.375-6.708 5.375-3.062 0-5.78-2.061-6.611-5.011l-0.963 0.271c0.952 3.379 4.067 5.739 7.574 5.739 3.459 0 6.475-2.28 7.5-5.482v4.108h1v-6h-6z"},child:[]}]})(e)}const HN=({onClearChat:e,componentType:t})=>{const{resetConversation:n}=li(),r=()=>{n(),e()};return I.jsxs("button",{className:oe(`${Z}-overflow-menu-button`,"clear-chat-button",t),onClick:r,children:[I.jsx(UN,{}),"Clear chat"]})},Id=({className:e,componentType:t,children:n})=>{const[r,o]=W.useState(!1),{globalClassName:u}=sr(),a=()=>{o(!1)},c=f=>{o(f.open)};return I.jsxs(DN,{open:r,onOpenChange:c,positioning:{placement:"bottom-end"},children:[I.jsx(J1,{"aria-label":`Overflow menu for ${t}`,className:oe(`${Z}-overflow-menu-button-trigger`,u,e,t),children:I.jsx(BN,{})}),I.jsx(s1,{children:I.jsxs(i1,{className:oe(`${Z}-overflow-menu-list`,u,t),children:[n,I.jsx(HN,{componentType:t,onClearChat:a})]})})]})};function zN(e){return hn({attr:{viewBox:"0 0 24 24",fill:"currentColor"},child:[{tag:"path",attr:{d:"M15 4.00008H13V11.0001H20V9.00008H16.4142L20.7071 4.70718L19.2929 3.29297L15 7.58586V4.00008ZM4.00008 15H7.58586L3.29297 19.2929L4.70718 20.7071L9.00008 16.4142V20H11.0001V13H4.00008V15Z"},child:[]}]})(e)}function Z1(e){return hn({attr:{viewBox:"0 0 24 24",fill:"currentColor"},child:[{tag:"path",attr:{d:"M17.5858 5H14V3H21V10H19V6.41421L14.7071 10.7071L13.2929 9.29289L17.5858 5ZM3 14H5V17.5858L9.29289 13.2929L10.7071 14.7071L6.41421 19H10V21H3V14Z"},child:[]}]})(e)}const eE=({className:e,onClick:t,disabled:n=!1})=>I.jsx("button",{"aria-label":"Close",className:oe(e,`${Z}-close-button`),disabled:n,onClick:t,children:I.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:I.jsx("path",{d:"M18.3 5.7a1 1 0 0 0-1.4-1.4L12 9.6 7.1 4.7a1 1 0 1 0-1.4 1.4l4.9 4.9-4.9 4.9a1 1 0 1 0 1.4 1.4l4.9-4.9 4.9 4.9a1 1 0 0 0 1.4-1.4l-4.9-4.9 4.9-4.9z"})})}),tE=({componentType:e,isIcon:t})=>{const n=()=>{Vf("modal")};return t?I.jsx(ja,{className:oe("toggle-modal-button",e),ariaLabel:"Toggle Modal",onClick:n,icon:I.jsx(Z1,{})}):I.jsxs("button",{className:oe(`${Z}-overflow-menu-button`,e,"toggle-modal-button"),onClick:n,children:[I.jsx(Z1,{}),"Show modal"]})},jN=({isWidgetStandalone:e,product:t})=>{const{configModule:n,globalClassName:r}=sr();if(!n)return null;const o=n.getName(t),u=n.getBrand(t),a=n.getPriceDisplay(t),c=n.getRelativePdp(t),f=n.getPdp(t),h=n.getImage(t),m=c&&typeof c=="string"?new URL(c,window.location.origin).href:f;return I.jsxs("div",{className:oe(r,`${Z}-product-tile`,{embedded:!e,standalone:e}),children:[I.jsx("img",{className:oe(r,`${Z}-product-tile-image`,{embedded:!e,standalone:e}),src:`${h}`,alt:`${o}`,loading:"lazy"}),I.jsxs("div",{className:oe(r,`${Z}-product-tile-details`,{embedded:!e,standalone:e}),children:[I.jsxs("div",{className:oe(r,`${Z}-product-tile-content`),children:[u&&I.jsx("p",{className:`${Z}-product-tile-brand`,children:u}),m?I.jsxs("a",{"aria-label":`Go to product page for ${o}`,className:oe(r,`${Z}-product-tile-pdp`),href:`${m}`,target:"_blank",rel:"noopener noreferrer",children:[o," ",I.jsx("span",{className:oe(r,`${Z}-product-tile-pdp-arrow`),children:"→"})]}):I.jsx("p",{className:oe(r,`${Z}-product-tile-name`),title:o,children:o})]}),I.jsx("div",{className:oe(r,`${Z}-product-tile-footer`),children:I.jsx("p",{className:oe(r,`${Z}-product-tile-price`),children:a})})]})]})},$N=({isWidgetStandalone:e,message:t})=>{const{configModule:n,globalClassName:r}=sr(),o=t;return n?I.jsxs("div",{className:oe(r,`${Z}-display-products widget-message`),children:[I.jsx("p",{children:o.message}),o.products&&o.products.length>0&&I.jsx("div",{className:oe(r,`${Z}-product-list`,{embedded:!e,standalone:e}),children:o.products.map(u=>{const a=n.getPid(u);return I.jsx(jN,{isWidgetStandalone:e,product:u},`${a}`)})})]}):null},VN=({globalClassName:e,message:t,isWidgetStandalone:n})=>I.jsx("div",{className:oe(e,`${Z}-error-message`,{standalone:n,embedded:!n}),children:I.jsxs("p",{className:oe(e,`${Z}-error-message-text`,{standalone:n,embedded:!n}),children:[I.jsx(sA,{})," ",t.message||"An error occurred while processing your request."]})});function qN(e){return hn({attr:{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{d:"M10.75 6.75a.75.75 0 0 0-1.5 0v2.5h-2.5a.75.75 0 0 0 0 1.5h2.5v2.5a.75.75 0 0 0 1.5 0v-2.5h2.5a.75.75 0 0 0 0-1.5h-2.5v-2.5Z"},child:[]}]})(e)}const YN=({globalClassName:e,messageId:t,messageEventSourceId:n,isLoading:r,suggestions:o,handleSuggestionClick:u})=>I.jsx("div",{className:oe(e,`${Z}-suggestion-container standalone`),children:o.map(a=>I.jsxs(Yf,{disabled:r,className:oe(e,`${Z}-suggestion-button standalone`),onClick:()=>u(a,n||t),children:[I.jsx(qN,{size:"1.5rem",style:{minHeight:"1.5rem",minWidth:"1.5rem"}})," ",a.displayText]},a.displayText))}),WN=({globalClassName:e,message:t,isWidgetStandalone:n,handleSuggestionClick:r})=>{const{isLoading:o}=li();return I.jsxs("div",{className:oe(e,`${Z}-follow-up`),children:[I.jsx("p",{className:oe(e,`${Z}-text`),children:t.message}),n&&I.jsx(YN,{globalClassName:e,isLoading:o,messageId:t.id,messageEventSourceId:t.eventSourceId,suggestions:t.suggestions,handleSuggestionClick:r}),!n&&I.jsx("div",{className:oe(e,`${Z}-suggestion-container embedded`),children:t.suggestions.map(u=>I.jsx("button",{disabled:o,className:oe(e,`${Z}-suggestion-button embedded`),onClick:()=>r(u,t.eventSourceId||t.id),children:u.displayText},u.displayText))})]})};function WM(){}function GM(){}function nE(e){const t=[],n=String(e||"");let r=n.indexOf(","),o=0,u=!1;for(;!u;){r===-1&&(r=n.length,u=!0);const a=n.slice(o,r).trim();(a||!u)&&t.push(a),o=r+1,r=n.indexOf(",",o)}return t}function rE(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const GN=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,KN=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,QN={};function iE(e,t){return(QN.jsx?KN:GN).test(e)}const XN=/[ \t\n\f\r]/g;function JN(e){return typeof e=="object"?e.type==="text"?sE(e.value):!1:sE(e)}function sE(e){return e.replace(XN,"")===""}let tu=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};tu.prototype.normal={},tu.prototype.property={},tu.prototype.space=void 0;function oE(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new tu(n,r,t)}function nu(e){return e.toLowerCase()}let Sn=class{constructor(t,n){this.attribute=n,this.property=t}};Sn.prototype.attribute="",Sn.prototype.booleanish=!1,Sn.prototype.boolean=!1,Sn.prototype.commaOrSpaceSeparated=!1,Sn.prototype.commaSeparated=!1,Sn.prototype.defined=!1,Sn.prototype.mustUseProperty=!1,Sn.prototype.number=!1,Sn.prototype.overloadedBoolean=!1,Sn.prototype.property="",Sn.prototype.spaceSeparated=!1,Sn.prototype.space=void 0;let ZN=0;const $e=Wi(),Mt=Wi(),Pd=Wi(),he=Wi(),at=Wi(),js=Wi(),Ln=Wi();function Wi(){return Xc(2,++ZN)}const Rd=Object.freeze(Object.defineProperty({__proto__:null,boolean:$e,booleanish:Mt,commaOrSpaceSeparated:Ln,commaSeparated:js,number:he,overloadedBoolean:Pd,spaceSeparated:at},Symbol.toStringTag,{value:"Module"})),Ld=Object.keys(Rd);let Dd=class extends Sn{constructor(t,n,r,o){let u=-1;if(super(t,n),uE(this,"space",o),typeof r=="number")for(;++u<Ld.length;){const a=Ld[u];uE(this,Ld[u],(r&Rd[a])===Rd[a])}}};Dd.prototype.defined=!0;function uE(e,t,n){n&&(e[t]=n)}function $s(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const u=new Dd(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(u.mustUseProperty=!0),t[r]=u,n[nu(r)]=r,n[nu(u.attribute)]=r}return new tu(t,n,e.space)}const aE=$s({properties:{ariaActiveDescendant:null,ariaAtomic:Mt,ariaAutoComplete:null,ariaBusy:Mt,ariaChecked:Mt,ariaColCount:he,ariaColIndex:he,ariaColSpan:he,ariaControls:at,ariaCurrent:null,ariaDescribedBy:at,ariaDetails:null,ariaDisabled:Mt,ariaDropEffect:at,ariaErrorMessage:null,ariaExpanded:Mt,ariaFlowTo:at,ariaGrabbed:Mt,ariaHasPopup:null,ariaHidden:Mt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:at,ariaLevel:he,ariaLive:null,ariaModal:Mt,ariaMultiLine:Mt,ariaMultiSelectable:Mt,ariaOrientation:null,ariaOwns:at,ariaPlaceholder:null,ariaPosInSet:he,ariaPressed:Mt,ariaReadOnly:Mt,ariaRelevant:null,ariaRequired:Mt,ariaRoleDescription:at,ariaRowCount:he,ariaRowIndex:he,ariaRowSpan:he,ariaSelected:Mt,ariaSetSize:he,ariaSort:null,ariaValueMax:he,ariaValueMin:he,ariaValueNow:he,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function lE(e,t){return t in e?e[t]:t}function cE(e,t){return lE(e,t.toLowerCase())}const e3=$s({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:js,acceptCharset:at,accessKey:at,action:null,allow:null,allowFullScreen:$e,allowPaymentRequest:$e,allowUserMedia:$e,alt:null,as:null,async:$e,autoCapitalize:null,autoComplete:at,autoFocus:$e,autoPlay:$e,blocking:at,capture:null,charSet:null,checked:$e,cite:null,className:at,cols:he,colSpan:null,content:null,contentEditable:Mt,controls:$e,controlsList:at,coords:he|js,crossOrigin:null,data:null,dateTime:null,decoding:null,default:$e,defer:$e,dir:null,dirName:null,disabled:$e,download:Pd,draggable:Mt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:$e,formTarget:null,headers:at,height:he,hidden:Pd,high:he,href:null,hrefLang:null,htmlFor:at,httpEquiv:at,id:null,imageSizes:null,imageSrcSet:null,inert:$e,inputMode:null,integrity:null,is:null,isMap:$e,itemId:null,itemProp:at,itemRef:at,itemScope:$e,itemType:at,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:$e,low:he,manifest:null,max:null,maxLength:he,media:null,method:null,min:null,minLength:he,multiple:$e,muted:$e,name:null,nonce:null,noModule:$e,noValidate:$e,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:$e,optimum:he,pattern:null,ping:at,placeholder:null,playsInline:$e,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:$e,referrerPolicy:null,rel:at,required:$e,reversed:$e,rows:he,rowSpan:he,sandbox:at,scope:null,scoped:$e,seamless:$e,selected:$e,shadowRootClonable:$e,shadowRootDelegatesFocus:$e,shadowRootMode:null,shape:null,size:he,sizes:null,slot:null,span:he,spellCheck:Mt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:he,step:null,style:null,tabIndex:he,target:null,title:null,translate:null,type:null,typeMustMatch:$e,useMap:null,value:Mt,width:he,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:at,axis:null,background:null,bgColor:null,border:he,borderColor:null,bottomMargin:he,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:$e,declare:$e,event:null,face:null,frame:null,frameBorder:null,hSpace:he,leftMargin:he,link:null,longDesc:null,lowSrc:null,marginHeight:he,marginWidth:he,noResize:$e,noHref:$e,noShade:$e,noWrap:$e,object:null,profile:null,prompt:null,rev:null,rightMargin:he,rules:null,scheme:null,scrolling:Mt,standby:null,summary:null,text:null,topMargin:he,valueType:null,version:null,vAlign:null,vLink:null,vSpace:he,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:$e,disableRemotePlayback:$e,prefix:null,property:null,results:he,security:null,unselectable:null},space:"html",transform:cE}),t3=$s({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:Ln,accentHeight:he,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:he,amplitude:he,arabicForm:null,ascent:he,attributeName:null,attributeType:null,azimuth:he,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:he,by:null,calcMode:null,capHeight:he,className:at,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:he,diffuseConstant:he,direction:null,display:null,dur:null,divisor:he,dominantBaseline:null,download:$e,dx:null,dy:null,edgeMode:null,editable:null,elevation:he,enableBackground:null,end:null,event:null,exponent:he,externalResourcesRequired:null,fill:null,fillOpacity:he,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:js,g2:js,glyphName:js,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:he,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:he,horizOriginX:he,horizOriginY:he,id:null,ideographic:he,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:he,k:he,k1:he,k2:he,k3:he,k4:he,kernelMatrix:Ln,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:he,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:he,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:he,overlineThickness:he,paintOrder:null,panose1:null,path:null,pathLength:he,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:at,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:he,pointsAtY:he,pointsAtZ:he,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Ln,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Ln,rev:Ln,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Ln,requiredFeatures:Ln,requiredFonts:Ln,requiredFormats:Ln,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:he,specularExponent:he,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:he,strikethroughThickness:he,string:null,stroke:null,strokeDashArray:Ln,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:he,strokeOpacity:he,strokeWidth:null,style:null,surfaceScale:he,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Ln,tabIndex:he,tableValues:null,target:null,targetX:he,targetY:he,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Ln,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:he,underlineThickness:he,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:he,values:null,vAlphabetic:he,vMathematical:he,vectorEffect:null,vHanging:he,vIdeographic:he,version:null,vertAdvY:he,vertOriginX:he,vertOriginY:he,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:he,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:lE}),fE=$s({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),dE=$s({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:cE}),hE=$s({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),n3={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},r3=/[A-Z]/g,pE=/-[a-z]/g,i3=/^data[-\w.:]+$/i;function Fd(e,t){const n=nu(t);let r=t,o=Sn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&i3.test(t)){if(t.charAt(4)==="-"){const u=t.slice(5).replace(pE,o3);r="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=t.slice(4);if(!pE.test(u)){let a=u.replace(r3,s3);a.charAt(0)!=="-"&&(a="-"+a),t="data"+a}}o=Dd}return new o(r,t)}function s3(e){return"-"+e.toLowerCase()}function o3(e){return e.charAt(1).toUpperCase()}const cl=oE([aE,e3,fE,dE,hE],"html"),Vs=oE([aE,t3,fE,dE,hE],"svg");function mE(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function gE(e){return e.join(" ").trim()}var qs={},Md,EE;function u3(){if(EE)return Md;EE=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,u=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,c=/^\s+|\s+$/g,f=`
15
- `,h="/",m="*",E="",b="comment",T="declaration";Md=function(S,C){if(typeof S!="string")throw new TypeError("First argument must be a string");if(!S)return[];C=C||{};var k=1,M=1;function D(ue){var ie=ue.match(t);ie&&(k+=ie.length);var ge=ue.lastIndexOf(f);M=~ge?ue.length-ge:M+ue.length}function G(){var ue={line:k,column:M};return function(ie){return ie.position=new q(ue),Te(),ie}}function q(ue){this.start=ue,this.end={line:k,column:M},this.source=C.source}q.prototype.content=S;function B(ue){var ie=new Error(C.source+":"+k+":"+M+": "+ue);if(ie.reason=ue,ie.filename=C.source,ie.line=k,ie.column=M,ie.source=S,!C.silent)throw ie}function te(ue){var ie=ue.exec(S);if(ie){var ge=ie[0];return D(ge),S=S.slice(ge.length),ie}}function Te(){te(n)}function Se(ue){var ie;for(ue=ue||[];ie=H();)ie!==!1&&ue.push(ie);return ue}function H(){var ue=G();if(!(h!=S.charAt(0)||m!=S.charAt(1))){for(var ie=2;E!=S.charAt(ie)&&(m!=S.charAt(ie)||h!=S.charAt(ie+1));)++ie;if(ie+=2,E===S.charAt(ie-1))return B("End of comment missing");var ge=S.slice(2,ie-2);return M+=2,D(ge),S=S.slice(ie),M+=2,ue({type:b,comment:ge})}}function fe(){var ue=G(),ie=te(r);if(ie){if(H(),!te(o))return B("property missing ':'");var ge=te(u),we=ue({type:T,property:_(ie[0].replace(e,E)),value:ge?_(ge[0].replace(e,E)):E});return te(a),we}}function de(){var ue=[];Se(ue);for(var ie;ie=fe();)ie!==!1&&(ue.push(ie),Se(ue));return ue}return Te(),de()};function _(S){return S?S.replace(c,E):E}return Md}var yE;function a3(){if(yE)return qs;yE=1;var e=qs&&qs.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(qs,"__esModule",{value:!0}),qs.default=n;var t=e(u3());function n(r,o){var u=null;if(!r||typeof r!="string")return u;var a=(0,t.default)(r),c=typeof o=="function";return a.forEach(function(f){if(f.type==="declaration"){var h=f.property,m=f.value;c?o(h,m,f):m&&(u=u||{},u[h]=m)}}),u}return qs}var ru={},TE;function l3(){if(TE)return ru;TE=1,Object.defineProperty(ru,"__esModule",{value:!0}),ru.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,u=function(h){return!h||n.test(h)||e.test(h)},a=function(h,m){return m.toUpperCase()},c=function(h,m){return"".concat(m,"-")},f=function(h,m){return m===void 0&&(m={}),u(h)?h:(h=h.toLowerCase(),m.reactCompat?h=h.replace(o,c):h=h.replace(r,c),h.replace(t,a))};return ru.camelCase=f,ru}var iu,bE;function c3(){if(bE)return iu;bE=1;var e=iu&&iu.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(a3()),n=l3();function r(o,u){var a={};return!o||typeof o!="string"||(0,t.default)(o,function(c,f){c&&f&&(a[(0,n.camelCase)(c,u)]=f)}),a}return r.default=r,iu=r,iu}var f3=c3();const d3=Ge(f3),fl=_E("end"),Nr=_E("start");function _E(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function h3(e){const t=Nr(e),n=fl(e);if(t&&n)return{start:t,end:n}}function su(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?xE(e.position):"start"in e||"end"in e?xE(e):"line"in e||"column"in e?Bd(e):""}function Bd(e){return SE(e&&e.line)+":"+SE(e&&e.column)}function xE(e){return Bd(e&&e.start)+"-"+Bd(e&&e.end)}function SE(e){return e&&typeof e=="number"?e:1}class rn extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let o="",u={},a=!1;if(n&&("line"in n&&"column"in n?u={place:n}:"start"in n&&"end"in n?u={place:n}:"type"in n?u={ancestors:[n],place:n.position}:u=U({},n)),typeof t=="string"?o=t:!u.cause&&t&&(a=!0,o=t.message,u.cause=t),!u.ruleId&&!u.source&&typeof r=="string"){const f=r.indexOf(":");f===-1?u.ruleId=r:(u.source=r.slice(0,f),u.ruleId=r.slice(f+1))}if(!u.place&&u.ancestors&&u.ancestors){const f=u.ancestors[u.ancestors.length-1];f&&(u.place=f.position)}const c=u.place&&"start"in u.place?u.place.start:u.place;this.ancestors=u.ancestors||void 0,this.cause=u.cause||void 0,this.column=c?c.column:void 0,this.fatal=void 0,this.file,this.message=o,this.line=c?c.line:void 0,this.name=su(u.place)||"1:1",this.place=u.place||void 0,this.reason=this.message,this.ruleId=u.ruleId||void 0,this.source=u.source||void 0,this.stack=a&&u.cause&&typeof u.cause.stack=="string"?u.cause.stack:"",this.actual,this.expected,this.note,this.url}}rn.prototype.file="",rn.prototype.name="",rn.prototype.reason="",rn.prototype.message="",rn.prototype.stack="",rn.prototype.column=void 0,rn.prototype.line=void 0,rn.prototype.ancestors=void 0,rn.prototype.cause=void 0,rn.prototype.fatal=void 0,rn.prototype.place=void 0,rn.prototype.ruleId=void 0,rn.prototype.source=void 0;const Ud={}.hasOwnProperty,p3=new Map,m3=/[A-Z]/g,g3=new Set(["table","tbody","thead","tfoot","tr"]),E3=new Set(["td","th"]),wE="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function y3(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=A3(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=C3(n,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?Vs:cl,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},u=CE(o,e,void 0);return u&&typeof u!="string"?u:o.create(e,o.Fragment,{children:u||void 0},void 0)}function CE(e,t,n){if(t.type==="element")return T3(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return b3(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return x3(e,t,n);if(t.type==="mdxjsEsm")return _3(e,t);if(t.type==="root")return S3(e,t,n);if(t.type==="text")return w3(e,t)}function T3(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=Vs,e.schema=o),e.ancestors.push(t);const u=vE(e,t.tagName,!1),a=v3(e,t);let c=zd(e,t);return g3.has(t.tagName)&&(c=c.filter(function(f){return typeof f=="string"?!JN(f):!0})),AE(e,a,u,t),Hd(a,c),e.ancestors.pop(),e.schema=r,e.create(t,u,a,n)}function b3(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return r.type,e.evaluater.evaluateExpression(r.expression)}ou(e,t.position)}function _3(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);ou(e,t.position)}function x3(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=Vs,e.schema=o),e.ancestors.push(t);const u=t.name===null?e.Fragment:vE(e,t.name,!0),a=k3(e,t),c=zd(e,t);return AE(e,a,u,t),Hd(a,c),e.ancestors.pop(),e.schema=r,e.create(t,u,a,n)}function S3(e,t,n){const r={};return Hd(r,zd(e,t)),e.create(t,e.Fragment,r,n)}function w3(e,t){return t.value}function AE(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Hd(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function C3(e,t,n){return r;function r(o,u,a,c){const h=Array.isArray(a.children)?n:t;return c?h(u,a,c):h(u,a)}}function A3(e,t){return n;function n(r,o,u,a){const c=Array.isArray(u.children),f=Nr(r);return t(o,u,a,c,{columnNumber:f?f.column-1:void 0,fileName:e,lineNumber:f?f.line:void 0},void 0)}}function v3(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&Ud.call(t.properties,o)){const u=N3(e,o,t.properties[o]);if(u){const[a,c]=u;e.tableCellAlignToStyle&&a==="align"&&typeof c=="string"&&E3.has(t.tagName)?r=c:n[a]=c}}if(r){const u=n.style||(n.style={});u[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function k3(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const u=r.data.estree.body[0];u.type;const a=u.expression;a.type;const c=a.properties[0];c.type,Object.assign(n,e.evaluater.evaluateExpression(c.argument))}else ou(e,t.position);else{const o=r.name;let u;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const c=r.value.data.estree.body[0];c.type,u=e.evaluater.evaluateExpression(c.expression)}else ou(e,t.position);else u=r.value===null?!0:r.value;n[o]=u}return n}function zd(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:p3;for(;++r<t.children.length;){const u=t.children[r];let a;if(e.passKeys){const f=u.type==="element"?u.tagName:u.type==="mdxJsxFlowElement"||u.type==="mdxJsxTextElement"?u.name:void 0;if(f){const h=o.get(f)||0;a=f+"-"+h,o.set(f,h+1)}}const c=CE(e,u,a);c!==void 0&&n.push(c)}return n}function N3(e,t,n){const r=Fd(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?rE(n):gE(n)),r.property==="style"){let o=typeof n=="object"?n:O3(e,String(n));return e.stylePropertyNameCase==="css"&&(o=I3(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?n3[r.property]||r.property:r.attribute,n]}}function O3(e,t){try{return d3(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new rn("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=wE+"#cannot-parse-style-attribute",o}}function vE(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const o=t.split(".");let u=-1,a;for(;++u<o.length;){const c=iE(o[u])?{type:"Identifier",name:o[u]}:{type:"Literal",value:o[u]};a=a?{type:"MemberExpression",object:a,property:c,computed:!!(u&&c.type==="Literal"),optional:!1}:c}r=a}else r=iE(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return Ud.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);ou(e)}function ou(e,t){const n=new rn("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=wE+"#cannot-handle-mdx-estrees-without-createevaluater",n}function I3(e){const t={};let n;for(n in e)Ud.call(e,n)&&(t[P3(n)]=e[n]);return t}function P3(e){let t=e.replace(m3,R3);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function R3(e){return"-"+e.toLowerCase()}const jd={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},L3={};function $d(e,t){const n=L3,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return kE(e,r,o)}function kE(e,t,n){if(D3(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return NE(e.children,t,n)}return Array.isArray(e)?NE(e,t,n):""}function NE(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=kE(e[o],t,n);return r.join("")}function D3(e){return!!(e&&typeof e=="object")}const OE=document.createElement("i");function Vd(e){const t="&"+e+";";OE.innerHTML=t;const n=OE.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function Dn(e,t,n,r){const o=e.length;let u=0,a;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)a=Array.from(r),a.unshift(t,n),e.splice(...a);else for(n&&e.splice(t,n);u<r.length;)a=r.slice(u,u+1e4),a.unshift(t,0),e.splice(...a),u+=1e4,t+=1e4}function Yn(e,t){return e.length>0?(Dn(e,e.length,0,t),e):t}const IE={}.hasOwnProperty;function PE(e){const t={};let n=-1;for(;++n<e.length;)F3(t,e[n]);return t}function F3(e,t){let n;for(n in t){const o=(IE.call(e,n)?e[n]:void 0)||(e[n]={}),u=t[n];let a;if(u)for(a in u){IE.call(o,a)||(o[a]=[]);const c=u[a];M3(o[a],Array.isArray(c)?c:c?[c]:[])}}}function M3(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Dn(e,0,0,r)}function RE(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function fr(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const pn=hi(/[A-Za-z]/),sn=hi(/[\dA-Za-z]/),B3=hi(/[#-'*+\--9=?A-Z^-~]/);function dl(e){return e!==null&&(e<32||e===127)}const qd=hi(/\d/),U3=hi(/[\dA-Fa-f]/),H3=hi(/[!-/:-@[-`{-~]/);function Re(e){return e!==null&&e<-2}function ut(e){return e!==null&&(e<0||e===32)}function Ke(e){return e===-2||e===-1||e===32}const hl=hi(new RegExp("\\p{P}|\\p{S}","u")),Gi=hi(/\s/);function hi(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Ys(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const u=e.charCodeAt(n);let a="";if(u===37&&sn(e.charCodeAt(n+1))&&sn(e.charCodeAt(n+2)))o=2;else if(u<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(u))||(a=String.fromCharCode(u));else if(u>55295&&u<57344){const c=e.charCodeAt(n+1);u<56320&&c>56319&&c<57344?(a=String.fromCharCode(u,c),o=1):a="�"}else a=String.fromCharCode(u);a&&(t.push(e.slice(r,n),encodeURIComponent(a)),r=n+o+1,a=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function Xe(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let u=0;return a;function a(f){return Ke(f)?(e.enter(n),c(f)):t(f)}function c(f){return Ke(f)&&u++<o?(e.consume(f),c):(e.exit(n),t(f))}}const z3={tokenize:j3};function j3(e){const t=e.attempt(this.parser.constructs.contentInitial,r,o);let n;return t;function r(c){if(c===null){e.consume(c);return}return e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),Xe(e,t,"linePrefix")}function o(c){return e.enter("paragraph"),u(c)}function u(c){const f=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=f),n=f,a(c)}function a(c){if(c===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(c);return}return Re(c)?(e.consume(c),e.exit("chunkText"),u):(e.consume(c),a)}}const $3={tokenize:V3},LE={tokenize:q3};function V3(e){const t=this,n=[];let r=0,o,u,a;return c;function c(D){if(r<n.length){const G=n[r];return t.containerState=G[1],e.attempt(G[0].continuation,f,h)(D)}return h(D)}function f(D){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&M();const G=t.events.length;let q=G,B;for(;q--;)if(t.events[q][0]==="exit"&&t.events[q][1].type==="chunkFlow"){B=t.events[q][1].end;break}k(r);let te=G;for(;te<t.events.length;)t.events[te][1].end=U({},B),te++;return Dn(t.events,q+1,0,t.events.slice(G)),t.events.length=te,h(D)}return c(D)}function h(D){if(r===n.length){if(!o)return b(D);if(o.currentConstruct&&o.currentConstruct.concrete)return _(D);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(LE,m,E)(D)}function m(D){return o&&M(),k(r),b(D)}function E(D){return t.parser.lazy[t.now().line]=r!==n.length,a=t.now().offset,_(D)}function b(D){return t.containerState={},e.attempt(LE,T,_)(D)}function T(D){return r++,n.push([t.currentConstruct,t.containerState]),b(D)}function _(D){if(D===null){o&&M(),k(0),e.consume(D);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:u}),S(D)}function S(D){if(D===null){C(e.exit("chunkFlow"),!0),k(0),e.consume(D);return}return Re(D)?(e.consume(D),C(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(D),S)}function C(D,G){const q=t.sliceStream(D);if(G&&q.push(null),D.previous=u,u&&(u.next=D),u=D,o.defineSkip(D.start),o.write(q),t.parser.lazy[D.start.line]){let B=o.events.length;for(;B--;)if(o.events[B][1].start.offset<a&&(!o.events[B][1].end||o.events[B][1].end.offset>a))return;const te=t.events.length;let Te=te,Se,H;for(;Te--;)if(t.events[Te][0]==="exit"&&t.events[Te][1].type==="chunkFlow"){if(Se){H=t.events[Te][1].end;break}Se=!0}for(k(r),B=te;B<t.events.length;)t.events[B][1].end=U({},H),B++;Dn(t.events,Te+1,0,t.events.slice(te)),t.events.length=B}}function k(D){let G=n.length;for(;G-- >D;){const q=n[G];t.containerState=q[1],q[0].exit.call(t,e)}n.length=D}function M(){o.write([null]),u=void 0,o=void 0,t.containerState._closeFlow=void 0}}function q3(e,t,n){return Xe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Ws(e){if(e===null||ut(e)||Gi(e))return 1;if(hl(e))return 2}function pl(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const u=e[o].resolveAll;u&&!r.includes(u)&&(t=u(t,n),r.push(u))}return t}const Yd={name:"attention",resolveAll:Y3,tokenize:W3};function Y3(e,t){let n=-1,r,o,u,a,c,f,h,m;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;f=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const E=U({},e[r][1].end),b=U({},e[n][1].start);DE(E,-f),DE(b,f),a={type:f>1?"strongSequence":"emphasisSequence",start:E,end:U({},e[r][1].end)},c={type:f>1?"strongSequence":"emphasisSequence",start:U({},e[n][1].start),end:b},u={type:f>1?"strongText":"emphasisText",start:U({},e[r][1].end),end:U({},e[n][1].start)},o={type:f>1?"strong":"emphasis",start:U({},a.start),end:U({},c.end)},e[r][1].end=U({},a.start),e[n][1].start=U({},c.end),h=[],e[r][1].end.offset-e[r][1].start.offset&&(h=Yn(h,[["enter",e[r][1],t],["exit",e[r][1],t]])),h=Yn(h,[["enter",o,t],["enter",a,t],["exit",a,t],["enter",u,t]]),h=Yn(h,pl(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),h=Yn(h,[["exit",u,t],["enter",c,t],["exit",c,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(m=2,h=Yn(h,[["enter",e[n][1],t],["exit",e[n][1],t]])):m=0,Dn(e,r-1,n-r+3,h),n=r+h.length-m-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function W3(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=Ws(r);let u;return a;function a(f){return u=f,e.enter("attentionSequence"),c(f)}function c(f){if(f===u)return e.consume(f),c;const h=e.exit("attentionSequence"),m=Ws(f),E=!m||m===2&&o||n.includes(f),b=!o||o===2&&m||n.includes(r);return h._open=!!(u===42?E:E&&(o||!b)),h._close=!!(u===42?b:b&&(m||!E)),t(f)}}function DE(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const G3={name:"autolink",tokenize:K3};function K3(e,t,n){let r=0;return o;function o(T){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),u}function u(T){return pn(T)?(e.consume(T),a):T===64?n(T):h(T)}function a(T){return T===43||T===45||T===46||sn(T)?(r=1,c(T)):h(T)}function c(T){return T===58?(e.consume(T),r=0,f):(T===43||T===45||T===46||sn(T))&&r++<32?(e.consume(T),c):(r=0,h(T))}function f(T){return T===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):T===null||T===32||T===60||dl(T)?n(T):(e.consume(T),f)}function h(T){return T===64?(e.consume(T),m):B3(T)?(e.consume(T),h):n(T)}function m(T){return sn(T)?E(T):n(T)}function E(T){return T===46?(e.consume(T),r=0,m):T===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):b(T)}function b(T){if((T===45||sn(T))&&r++<63){const _=T===45?b:E;return e.consume(T),_}return n(T)}}const uu={partial:!0,tokenize:Q3};function Q3(e,t,n){return r;function r(u){return Ke(u)?Xe(e,o,"linePrefix")(u):o(u)}function o(u){return u===null||Re(u)?t(u):n(u)}}const FE={continuation:{tokenize:J3},exit:Z3,name:"blockQuote",tokenize:X3};function X3(e,t,n){const r=this;return o;function o(a){if(a===62){const c=r.containerState;return c.open||(e.enter("blockQuote",{_container:!0}),c.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(a),e.exit("blockQuoteMarker"),u}return n(a)}function u(a){return Ke(a)?(e.enter("blockQuotePrefixWhitespace"),e.consume(a),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(a))}}function J3(e,t,n){const r=this;return o;function o(a){return Ke(a)?Xe(e,u,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a):u(a)}function u(a){return e.attempt(FE,t,n)(a)}}function Z3(e){e.exit("blockQuote")}const ME={name:"characterEscape",tokenize:eO};function eO(e,t,n){return r;function r(u){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(u),e.exit("escapeMarker"),o}function o(u){return H3(u)?(e.enter("characterEscapeValue"),e.consume(u),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(u)}}const BE={name:"characterReference",tokenize:tO};function tO(e,t,n){const r=this;let o=0,u,a;return c;function c(E){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),f}function f(E){return E===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(E),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),u=31,a=sn,m(E))}function h(E){return E===88||E===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(E),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),u=6,a=U3,m):(e.enter("characterReferenceValue"),u=7,a=qd,m(E))}function m(E){if(E===59&&o){const b=e.exit("characterReferenceValue");return a===sn&&!Vd(r.sliceSerialize(b))?n(E):(e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return a(E)&&o++<u?(e.consume(E),m):n(E)}}const UE={partial:!0,tokenize:rO},HE={concrete:!0,name:"codeFenced",tokenize:nO};function nO(e,t,n){const r=this,o={partial:!0,tokenize:q};let u=0,a=0,c;return f;function f(B){return h(B)}function h(B){const te=r.events[r.events.length-1];return u=te&&te[1].type==="linePrefix"?te[2].sliceSerialize(te[1],!0).length:0,c=B,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),m(B)}function m(B){return B===c?(a++,e.consume(B),m):a<3?n(B):(e.exit("codeFencedFenceSequence"),Ke(B)?Xe(e,E,"whitespace")(B):E(B))}function E(B){return B===null||Re(B)?(e.exit("codeFencedFence"),r.interrupt?t(B):e.check(UE,S,G)(B)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(B))}function b(B){return B===null||Re(B)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),E(B)):Ke(B)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Xe(e,T,"whitespace")(B)):B===96&&B===c?n(B):(e.consume(B),b)}function T(B){return B===null||Re(B)?E(B):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),_(B))}function _(B){return B===null||Re(B)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),E(B)):B===96&&B===c?n(B):(e.consume(B),_)}function S(B){return e.attempt(o,G,C)(B)}function C(B){return e.enter("lineEnding"),e.consume(B),e.exit("lineEnding"),k}function k(B){return u>0&&Ke(B)?Xe(e,M,"linePrefix",u+1)(B):M(B)}function M(B){return B===null||Re(B)?e.check(UE,S,G)(B):(e.enter("codeFlowValue"),D(B))}function D(B){return B===null||Re(B)?(e.exit("codeFlowValue"),M(B)):(e.consume(B),D)}function G(B){return e.exit("codeFenced"),t(B)}function q(B,te,Te){let Se=0;return H;function H(ge){return B.enter("lineEnding"),B.consume(ge),B.exit("lineEnding"),fe}function fe(ge){return B.enter("codeFencedFence"),Ke(ge)?Xe(B,de,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(ge):de(ge)}function de(ge){return ge===c?(B.enter("codeFencedFenceSequence"),ue(ge)):Te(ge)}function ue(ge){return ge===c?(Se++,B.consume(ge),ue):Se>=a?(B.exit("codeFencedFenceSequence"),Ke(ge)?Xe(B,ie,"whitespace")(ge):ie(ge)):Te(ge)}function ie(ge){return ge===null||Re(ge)?(B.exit("codeFencedFence"),te(ge)):Te(ge)}}}function rO(e,t,n){const r=this;return o;function o(a){return a===null?n(a):(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),u)}function u(a){return r.parser.lazy[r.now().line]?n(a):t(a)}}const Wd={name:"codeIndented",tokenize:sO},iO={partial:!0,tokenize:oO};function sO(e,t,n){const r=this;return o;function o(h){return e.enter("codeIndented"),Xe(e,u,"linePrefix",5)(h)}function u(h){const m=r.events[r.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?a(h):n(h)}function a(h){return h===null?f(h):Re(h)?e.attempt(iO,a,f)(h):(e.enter("codeFlowValue"),c(h))}function c(h){return h===null||Re(h)?(e.exit("codeFlowValue"),a(h)):(e.consume(h),c)}function f(h){return e.exit("codeIndented"),t(h)}}function oO(e,t,n){const r=this;return o;function o(a){return r.parser.lazy[r.now().line]?n(a):Re(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),o):Xe(e,u,"linePrefix",5)(a)}function u(a){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(a):Re(a)?o(a):n(a)}}const uO={name:"codeText",previous:lO,resolve:aO,tokenize:cO};function aO(e){let t=e.length-4,n=3,r,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)o===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(o=r):(r===t||e[r][1].type==="lineEnding")&&(e[o][1].type="codeTextData",r!==o+2&&(e[o][1].end=e[r-1][1].end,e.splice(o+2,r-o-2),t-=r-o-2,r=o+2),o=void 0);return e}function lO(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function cO(e,t,n){let r=0,o,u;return a;function a(E){return e.enter("codeText"),e.enter("codeTextSequence"),c(E)}function c(E){return E===96?(e.consume(E),r++,c):(e.exit("codeTextSequence"),f(E))}function f(E){return E===null?n(E):E===32?(e.enter("space"),e.consume(E),e.exit("space"),f):E===96?(u=e.enter("codeTextSequence"),o=0,m(E)):Re(E)?(e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),f):(e.enter("codeTextData"),h(E))}function h(E){return E===null||E===32||E===96||Re(E)?(e.exit("codeTextData"),f(E)):(e.consume(E),h)}function m(E){return E===96?(e.consume(E),o++,m):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(E)):(u.type="codeTextData",h(E))}}class fO{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n==null?Number.POSITIVE_INFINITY:n;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const o=n||0;this.setCursor(Math.trunc(t));const u=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return r&&au(this.left,r),u.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),au(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),au(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);au(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);au(this.left,n.reverse())}}}function au(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function zE(e){const t={};let n=-1,r,o,u,a,c,f,h;const m=new fO(e);for(;++n<m.length;){for(;n in t;)n=t[n];if(r=m.get(n),n&&r[1].type==="chunkFlow"&&m.get(n-1)[1].type==="listItemPrefix"&&(f=r[1]._tokenizer.events,u=0,u<f.length&&f[u][1].type==="lineEndingBlank"&&(u+=2),u<f.length&&f[u][1].type==="content"))for(;++u<f.length&&f[u][1].type!=="content";)f[u][1].type==="chunkText"&&(f[u][1]._isInFirstContentOfListItem=!0,u++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,dO(m,n)),n=t[n],h=!0);else if(r[1]._container){for(u=n,o=void 0;u--;)if(a=m.get(u),a[1].type==="lineEnding"||a[1].type==="lineEndingBlank")a[0]==="enter"&&(o&&(m.get(o)[1].type="lineEndingBlank"),a[1].type="lineEnding",o=u);else if(!(a[1].type==="linePrefix"||a[1].type==="listItemIndent"))break;o&&(r[1].end=U({},m.get(o)[1].start),c=m.slice(o,n),c.unshift(r),m.splice(o,n-o+1,c))}}return Dn(e,0,Number.POSITIVE_INFINITY,m.slice(0)),!h}function dO(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const u=[];let a=n._tokenizer;a||(a=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(a._contentTypeTextTrailing=!0));const c=a.events,f=[],h={};let m,E,b=-1,T=n,_=0,S=0;const C=[S];for(;T;){for(;e.get(++o)[1]!==T;);u.push(o),T._tokenizer||(m=r.sliceStream(T),T.next||m.push(null),E&&a.defineSkip(T.start),T._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(m),T._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),E=T,T=T.next}for(T=n;++b<c.length;)c[b][0]==="exit"&&c[b-1][0]==="enter"&&c[b][1].type===c[b-1][1].type&&c[b][1].start.line!==c[b][1].end.line&&(S=b+1,C.push(S),T._tokenizer=void 0,T.previous=void 0,T=T.next);for(a.events=[],T?(T._tokenizer=void 0,T.previous=void 0):C.pop(),b=C.length;b--;){const k=c.slice(C[b],C[b+1]),M=u.pop();f.push([M,M+k.length-1]),e.splice(M,2,k)}for(f.reverse(),b=-1;++b<f.length;)h[_+f[b][0]]=_+f[b][1],_+=f[b][1]-f[b][0]-1;return h}const hO={resolve:mO,tokenize:gO},pO={partial:!0,tokenize:EO};function mO(e){return zE(e),e}function gO(e,t){let n;return r;function r(c){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),o(c)}function o(c){return c===null?u(c):Re(c)?e.check(pO,a,u)(c):(e.consume(c),o)}function u(c){return e.exit("chunkContent"),e.exit("content"),t(c)}function a(c){return e.consume(c),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,o}}function EO(e,t,n){const r=this;return o;function o(a){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),Xe(e,u,"linePrefix")}function u(a){if(a===null||Re(a))return n(a);const c=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(a):e.interrupt(r.parser.constructs.flow,n,t)(a)}}function jE(e,t,n,r,o,u,a,c,f){const h=f||Number.POSITIVE_INFINITY;let m=0;return E;function E(k){return k===60?(e.enter(r),e.enter(o),e.enter(u),e.consume(k),e.exit(u),b):k===null||k===32||k===41||dl(k)?n(k):(e.enter(r),e.enter(a),e.enter(c),e.enter("chunkString",{contentType:"string"}),S(k))}function b(k){return k===62?(e.enter(u),e.consume(k),e.exit(u),e.exit(o),e.exit(r),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),T(k))}function T(k){return k===62?(e.exit("chunkString"),e.exit(c),b(k)):k===null||k===60||Re(k)?n(k):(e.consume(k),k===92?_:T)}function _(k){return k===60||k===62||k===92?(e.consume(k),T):T(k)}function S(k){return!m&&(k===null||k===41||ut(k))?(e.exit("chunkString"),e.exit(c),e.exit(a),e.exit(r),t(k)):m<h&&k===40?(e.consume(k),m++,S):k===41?(e.consume(k),m--,S):k===null||k===32||k===40||dl(k)?n(k):(e.consume(k),k===92?C:S)}function C(k){return k===40||k===41||k===92?(e.consume(k),S):S(k)}}function $E(e,t,n,r,o,u){const a=this;let c=0,f;return h;function h(T){return e.enter(r),e.enter(o),e.consume(T),e.exit(o),e.enter(u),m}function m(T){return c>999||T===null||T===91||T===93&&!f||T===94&&!c&&"_hiddenFootnoteSupport"in a.parser.constructs?n(T):T===93?(e.exit(u),e.enter(o),e.consume(T),e.exit(o),e.exit(r),t):Re(T)?(e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),E(T))}function E(T){return T===null||T===91||T===93||Re(T)||c++>999?(e.exit("chunkString"),m(T)):(e.consume(T),f||(f=!Ke(T)),T===92?b:E)}function b(T){return T===91||T===92||T===93?(e.consume(T),c++,E):E(T)}}function VE(e,t,n,r,o,u){let a;return c;function c(b){return b===34||b===39||b===40?(e.enter(r),e.enter(o),e.consume(b),e.exit(o),a=b===40?41:b,f):n(b)}function f(b){return b===a?(e.enter(o),e.consume(b),e.exit(o),e.exit(r),t):(e.enter(u),h(b))}function h(b){return b===a?(e.exit(u),f(a)):b===null?n(b):Re(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Xe(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(b))}function m(b){return b===a||b===null||Re(b)?(e.exit("chunkString"),h(b)):(e.consume(b),b===92?E:m)}function E(b){return b===a||b===92?(e.consume(b),m):m(b)}}function lu(e,t){let n;return r;function r(o){return Re(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):Ke(o)?Xe(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}const yO={name:"definition",tokenize:bO},TO={partial:!0,tokenize:_O};function bO(e,t,n){const r=this;let o;return u;function u(T){return e.enter("definition"),a(T)}function a(T){return $E.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(T)}function c(T){return o=fr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),T===58?(e.enter("definitionMarker"),e.consume(T),e.exit("definitionMarker"),f):n(T)}function f(T){return ut(T)?lu(e,h)(T):h(T)}function h(T){return jE(e,m,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(T)}function m(T){return e.attempt(TO,E,E)(T)}function E(T){return Ke(T)?Xe(e,b,"whitespace")(T):b(T)}function b(T){return T===null||Re(T)?(e.exit("definition"),r.parser.defined.push(o),t(T)):n(T)}}function _O(e,t,n){return r;function r(c){return ut(c)?lu(e,o)(c):n(c)}function o(c){return VE(e,u,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function u(c){return Ke(c)?Xe(e,a,"whitespace")(c):a(c)}function a(c){return c===null||Re(c)?t(c):n(c)}}const xO={name:"hardBreakEscape",tokenize:SO};function SO(e,t,n){return r;function r(u){return e.enter("hardBreakEscape"),e.consume(u),o}function o(u){return Re(u)?(e.exit("hardBreakEscape"),t(u)):n(u)}}const wO={name:"headingAtx",resolve:CO,tokenize:AO};function CO(e,t){let n=e.length-2,r=3,o,u;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(o={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},u={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Dn(e,r,n-r+1,[["enter",o,t],["enter",u,t],["exit",u,t],["exit",o,t]])),e}function AO(e,t,n){let r=0;return o;function o(m){return e.enter("atxHeading"),u(m)}function u(m){return e.enter("atxHeadingSequence"),a(m)}function a(m){return m===35&&r++<6?(e.consume(m),a):m===null||ut(m)?(e.exit("atxHeadingSequence"),c(m)):n(m)}function c(m){return m===35?(e.enter("atxHeadingSequence"),f(m)):m===null||Re(m)?(e.exit("atxHeading"),t(m)):Ke(m)?Xe(e,c,"whitespace")(m):(e.enter("atxHeadingText"),h(m))}function f(m){return m===35?(e.consume(m),f):(e.exit("atxHeadingSequence"),c(m))}function h(m){return m===null||m===35||ut(m)?(e.exit("atxHeadingText"),c(m)):(e.consume(m),h)}}const vO=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],qE=["pre","script","style","textarea"],kO={concrete:!0,name:"htmlFlow",resolveTo:IO,tokenize:PO},NO={partial:!0,tokenize:LO},OO={partial:!0,tokenize:RO};function IO(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function PO(e,t,n){const r=this;let o,u,a,c,f;return h;function h(N){return m(N)}function m(N){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(N),E}function E(N){return N===33?(e.consume(N),b):N===47?(e.consume(N),u=!0,S):N===63?(e.consume(N),o=3,r.interrupt?t:w):pn(N)?(e.consume(N),a=String.fromCharCode(N),C):n(N)}function b(N){return N===45?(e.consume(N),o=2,T):N===91?(e.consume(N),o=5,c=0,_):pn(N)?(e.consume(N),o=4,r.interrupt?t:w):n(N)}function T(N){return N===45?(e.consume(N),r.interrupt?t:w):n(N)}function _(N){const _e="CDATA[";return N===_e.charCodeAt(c++)?(e.consume(N),c===_e.length?r.interrupt?t:de:_):n(N)}function S(N){return pn(N)?(e.consume(N),a=String.fromCharCode(N),C):n(N)}function C(N){if(N===null||N===47||N===62||ut(N)){const _e=N===47,Me=a.toLowerCase();return!_e&&!u&&qE.includes(Me)?(o=1,r.interrupt?t(N):de(N)):vO.includes(a.toLowerCase())?(o=6,_e?(e.consume(N),k):r.interrupt?t(N):de(N)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(N):u?M(N):D(N))}return N===45||sn(N)?(e.consume(N),a+=String.fromCharCode(N),C):n(N)}function k(N){return N===62?(e.consume(N),r.interrupt?t:de):n(N)}function M(N){return Ke(N)?(e.consume(N),M):H(N)}function D(N){return N===47?(e.consume(N),H):N===58||N===95||pn(N)?(e.consume(N),G):Ke(N)?(e.consume(N),D):H(N)}function G(N){return N===45||N===46||N===58||N===95||sn(N)?(e.consume(N),G):q(N)}function q(N){return N===61?(e.consume(N),B):Ke(N)?(e.consume(N),q):D(N)}function B(N){return N===null||N===60||N===61||N===62||N===96?n(N):N===34||N===39?(e.consume(N),f=N,te):Ke(N)?(e.consume(N),B):Te(N)}function te(N){return N===f?(e.consume(N),f=null,Se):N===null||Re(N)?n(N):(e.consume(N),te)}function Te(N){return N===null||N===34||N===39||N===47||N===60||N===61||N===62||N===96||ut(N)?q(N):(e.consume(N),Te)}function Se(N){return N===47||N===62||Ke(N)?D(N):n(N)}function H(N){return N===62?(e.consume(N),fe):n(N)}function fe(N){return N===null||Re(N)?de(N):Ke(N)?(e.consume(N),fe):n(N)}function de(N){return N===45&&o===2?(e.consume(N),we):N===60&&o===1?(e.consume(N),ae):N===62&&o===4?(e.consume(N),R):N===63&&o===3?(e.consume(N),w):N===93&&o===5?(e.consume(N),ee):Re(N)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(NO,Q,ue)(N)):N===null||Re(N)?(e.exit("htmlFlowData"),ue(N)):(e.consume(N),de)}function ue(N){return e.check(OO,ie,Q)(N)}function ie(N){return e.enter("lineEnding"),e.consume(N),e.exit("lineEnding"),ge}function ge(N){return N===null||Re(N)?ue(N):(e.enter("htmlFlowData"),de(N))}function we(N){return N===45?(e.consume(N),w):de(N)}function ae(N){return N===47?(e.consume(N),a="",V):de(N)}function V(N){if(N===62){const _e=a.toLowerCase();return qE.includes(_e)?(e.consume(N),R):de(N)}return pn(N)&&a.length<8?(e.consume(N),a+=String.fromCharCode(N),V):de(N)}function ee(N){return N===93?(e.consume(N),w):de(N)}function w(N){return N===62?(e.consume(N),R):N===45&&o===2?(e.consume(N),w):de(N)}function R(N){return N===null||Re(N)?(e.exit("htmlFlowData"),Q(N)):(e.consume(N),R)}function Q(N){return e.exit("htmlFlow"),t(N)}}function RO(e,t,n){const r=this;return o;function o(a){return Re(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),u):n(a)}function u(a){return r.parser.lazy[r.now().line]?n(a):t(a)}}function LO(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(uu,t,n)}}const DO={name:"htmlText",tokenize:FO};function FO(e,t,n){const r=this;let o,u,a;return c;function c(w){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(w),f}function f(w){return w===33?(e.consume(w),h):w===47?(e.consume(w),q):w===63?(e.consume(w),D):pn(w)?(e.consume(w),Te):n(w)}function h(w){return w===45?(e.consume(w),m):w===91?(e.consume(w),u=0,_):pn(w)?(e.consume(w),M):n(w)}function m(w){return w===45?(e.consume(w),T):n(w)}function E(w){return w===null?n(w):w===45?(e.consume(w),b):Re(w)?(a=E,ae(w)):(e.consume(w),E)}function b(w){return w===45?(e.consume(w),T):E(w)}function T(w){return w===62?we(w):w===45?b(w):E(w)}function _(w){const R="CDATA[";return w===R.charCodeAt(u++)?(e.consume(w),u===R.length?S:_):n(w)}function S(w){return w===null?n(w):w===93?(e.consume(w),C):Re(w)?(a=S,ae(w)):(e.consume(w),S)}function C(w){return w===93?(e.consume(w),k):S(w)}function k(w){return w===62?we(w):w===93?(e.consume(w),k):S(w)}function M(w){return w===null||w===62?we(w):Re(w)?(a=M,ae(w)):(e.consume(w),M)}function D(w){return w===null?n(w):w===63?(e.consume(w),G):Re(w)?(a=D,ae(w)):(e.consume(w),D)}function G(w){return w===62?we(w):D(w)}function q(w){return pn(w)?(e.consume(w),B):n(w)}function B(w){return w===45||sn(w)?(e.consume(w),B):te(w)}function te(w){return Re(w)?(a=te,ae(w)):Ke(w)?(e.consume(w),te):we(w)}function Te(w){return w===45||sn(w)?(e.consume(w),Te):w===47||w===62||ut(w)?Se(w):n(w)}function Se(w){return w===47?(e.consume(w),we):w===58||w===95||pn(w)?(e.consume(w),H):Re(w)?(a=Se,ae(w)):Ke(w)?(e.consume(w),Se):we(w)}function H(w){return w===45||w===46||w===58||w===95||sn(w)?(e.consume(w),H):fe(w)}function fe(w){return w===61?(e.consume(w),de):Re(w)?(a=fe,ae(w)):Ke(w)?(e.consume(w),fe):Se(w)}function de(w){return w===null||w===60||w===61||w===62||w===96?n(w):w===34||w===39?(e.consume(w),o=w,ue):Re(w)?(a=de,ae(w)):Ke(w)?(e.consume(w),de):(e.consume(w),ie)}function ue(w){return w===o?(e.consume(w),o=void 0,ge):w===null?n(w):Re(w)?(a=ue,ae(w)):(e.consume(w),ue)}function ie(w){return w===null||w===34||w===39||w===60||w===61||w===96?n(w):w===47||w===62||ut(w)?Se(w):(e.consume(w),ie)}function ge(w){return w===47||w===62||ut(w)?Se(w):n(w)}function we(w){return w===62?(e.consume(w),e.exit("htmlTextData"),e.exit("htmlText"),t):n(w)}function ae(w){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),V}function V(w){return Ke(w)?Xe(e,ee,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(w):ee(w)}function ee(w){return e.enter("htmlTextData"),a(w)}}const Gd={name:"labelEnd",resolveAll:HO,resolveTo:zO,tokenize:jO},MO={tokenize:$O},BO={tokenize:VO},UO={tokenize:qO};function HO(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const o=r.type==="labelImage"?4:2;r.type="data",t+=o}}return e.length!==n.length&&Dn(e,0,e.length,n),e}function zO(e,t){let n=e.length,r=0,o,u,a,c;for(;n--;)if(o=e[n][1],u){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[n][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(a){if(e[n][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(u=n,o.type!=="labelLink")){r=2;break}}else o.type==="labelEnd"&&(a=n);const f={type:e[u][1].type==="labelLink"?"link":"image",start:U({},e[u][1].start),end:U({},e[e.length-1][1].end)},h={type:"label",start:U({},e[u][1].start),end:U({},e[a][1].end)},m={type:"labelText",start:U({},e[u+r+2][1].end),end:U({},e[a-2][1].start)};return c=[["enter",f,t],["enter",h,t]],c=Yn(c,e.slice(u+1,u+r+3)),c=Yn(c,[["enter",m,t]]),c=Yn(c,pl(t.parser.constructs.insideSpan.null,e.slice(u+r+4,a-3),t)),c=Yn(c,[["exit",m,t],e[a-2],e[a-1],["exit",h,t]]),c=Yn(c,e.slice(a+1)),c=Yn(c,[["exit",f,t]]),Dn(e,u,e.length,c),e}function jO(e,t,n){const r=this;let o=r.events.length,u,a;for(;o--;)if((r.events[o][1].type==="labelImage"||r.events[o][1].type==="labelLink")&&!r.events[o][1]._balanced){u=r.events[o][1];break}return c;function c(b){return u?u._inactive?E(b):(a=r.parser.defined.includes(fr(r.sliceSerialize({start:u.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),f):n(b)}function f(b){return b===40?e.attempt(MO,m,a?m:E)(b):b===91?e.attempt(BO,m,a?h:E)(b):a?m(b):E(b)}function h(b){return e.attempt(UO,m,E)(b)}function m(b){return t(b)}function E(b){return u._balanced=!0,n(b)}}function $O(e,t,n){return r;function r(E){return e.enter("resource"),e.enter("resourceMarker"),e.consume(E),e.exit("resourceMarker"),o}function o(E){return ut(E)?lu(e,u)(E):u(E)}function u(E){return E===41?m(E):jE(e,a,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function a(E){return ut(E)?lu(e,f)(E):m(E)}function c(E){return n(E)}function f(E){return E===34||E===39||E===40?VE(e,h,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(E):m(E)}function h(E){return ut(E)?lu(e,m)(E):m(E)}function m(E){return E===41?(e.enter("resourceMarker"),e.consume(E),e.exit("resourceMarker"),e.exit("resource"),t):n(E)}}function VO(e,t,n){const r=this;return o;function o(c){return $E.call(r,e,u,a,"reference","referenceMarker","referenceString")(c)}function u(c){return r.parser.defined.includes(fr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(c):n(c)}function a(c){return n(c)}}function qO(e,t,n){return r;function r(u){return e.enter("reference"),e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),o}function o(u){return u===93?(e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),e.exit("reference"),t):n(u)}}const YO={name:"labelStartImage",resolveAll:Gd.resolveAll,tokenize:WO};function WO(e,t,n){const r=this;return o;function o(c){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(c),e.exit("labelImageMarker"),u}function u(c){return c===91?(e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelImage"),a):n(c)}function a(c){return c===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(c):t(c)}}const GO={name:"labelStartLink",resolveAll:Gd.resolveAll,tokenize:KO};function KO(e,t,n){const r=this;return o;function o(a){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(a),e.exit("labelMarker"),e.exit("labelLink"),u}function u(a){return a===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(a):t(a)}}const Kd={name:"lineEnding",tokenize:QO};function QO(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Xe(e,t,"linePrefix")}}const ml={name:"thematicBreak",tokenize:XO};function XO(e,t,n){let r=0,o;return u;function u(h){return e.enter("thematicBreak"),a(h)}function a(h){return o=h,c(h)}function c(h){return h===o?(e.enter("thematicBreakSequence"),f(h)):r>=3&&(h===null||Re(h))?(e.exit("thematicBreak"),t(h)):n(h)}function f(h){return h===o?(e.consume(h),r++,f):(e.exit("thematicBreakSequence"),Ke(h)?Xe(e,c,"whitespace")(h):c(h))}}const wn={continuation:{tokenize:tI},exit:rI,name:"list",tokenize:eI},JO={partial:!0,tokenize:iI},ZO={partial:!0,tokenize:nI};function eI(e,t,n){const r=this,o=r.events[r.events.length-1];let u=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,a=0;return c;function c(T){const _=r.containerState.type||(T===42||T===43||T===45?"listUnordered":"listOrdered");if(_==="listUnordered"?!r.containerState.marker||T===r.containerState.marker:qd(T)){if(r.containerState.type||(r.containerState.type=_,e.enter(_,{_container:!0})),_==="listUnordered")return e.enter("listItemPrefix"),T===42||T===45?e.check(ml,n,h)(T):h(T);if(!r.interrupt||T===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),f(T)}return n(T)}function f(T){return qd(T)&&++a<10?(e.consume(T),f):(!r.interrupt||a<2)&&(r.containerState.marker?T===r.containerState.marker:T===41||T===46)?(e.exit("listItemValue"),h(T)):n(T)}function h(T){return e.enter("listItemMarker"),e.consume(T),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||T,e.check(uu,r.interrupt?n:m,e.attempt(JO,b,E))}function m(T){return r.containerState.initialBlankLine=!0,u++,b(T)}function E(T){return Ke(T)?(e.enter("listItemPrefixWhitespace"),e.consume(T),e.exit("listItemPrefixWhitespace"),b):n(T)}function b(T){return r.containerState.size=u+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(T)}}function tI(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(uu,o,u);function o(c){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Xe(e,t,"listItemIndent",r.containerState.size+1)(c)}function u(c){return r.containerState.furtherBlankLines||!Ke(c)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,a(c)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(ZO,t,a)(c))}function a(c){return r.containerState._closeFlow=!0,r.interrupt=void 0,Xe(e,e.attempt(wn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function nI(e,t,n){const r=this;return Xe(e,o,"listItemIndent",r.containerState.size+1);function o(u){const a=r.events[r.events.length-1];return a&&a[1].type==="listItemIndent"&&a[2].sliceSerialize(a[1],!0).length===r.containerState.size?t(u):n(u)}}function rI(e){e.exit(this.containerState.type)}function iI(e,t,n){const r=this;return Xe(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(u){const a=r.events[r.events.length-1];return!Ke(u)&&a&&a[1].type==="listItemPrefixWhitespace"?t(u):n(u)}}const YE={name:"setextUnderline",resolveTo:sI,tokenize:oI};function sI(e,t){let n=e.length,r,o,u;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!u&&e[n][1].type==="definition"&&(u=n);const a={type:"setextHeading",start:U({},e[r][1].start),end:U({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",u?(e.splice(o,0,["enter",a,t]),e.splice(u+1,0,["exit",e[r][1],t]),e[r][1].end=U({},e[u][1].end)):e[r][1]=a,e.push(["exit",a,t]),e}function oI(e,t,n){const r=this;let o;return u;function u(h){let m=r.events.length,E;for(;m--;)if(r.events[m][1].type!=="lineEnding"&&r.events[m][1].type!=="linePrefix"&&r.events[m][1].type!=="content"){E=r.events[m][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||E)?(e.enter("setextHeadingLine"),o=h,a(h)):n(h)}function a(h){return e.enter("setextHeadingLineSequence"),c(h)}function c(h){return h===o?(e.consume(h),c):(e.exit("setextHeadingLineSequence"),Ke(h)?Xe(e,f,"lineSuffix")(h):f(h))}function f(h){return h===null||Re(h)?(e.exit("setextHeadingLine"),t(h)):n(h)}}const uI={tokenize:aI};function aI(e){const t=this,n=e.attempt(uu,r,e.attempt(this.parser.constructs.flowInitial,o,Xe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(hO,o)),"linePrefix")));return n;function r(u){if(u===null){e.consume(u);return}return e.enter("lineEndingBlank"),e.consume(u),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(u){if(u===null){e.consume(u);return}return e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const lI={resolveAll:GE()},cI=WE("string"),fI=WE("text");function WE(e){return{resolveAll:GE(e==="text"?dI:void 0),tokenize:t};function t(n){const r=this,o=this.parser.constructs[e],u=n.attempt(o,a,c);return a;function a(m){return h(m)?u(m):c(m)}function c(m){if(m===null){n.consume(m);return}return n.enter("data"),n.consume(m),f}function f(m){return h(m)?(n.exit("data"),u(m)):(n.consume(m),f)}function h(m){if(m===null)return!0;const E=o[m];let b=-1;if(E)for(;++b<E.length;){const T=E[b];if(!T.previous||T.previous.call(r,r.previous))return!0}return!1}}}function GE(e){return t;function t(n,r){let o=-1,u;for(;++o<=n.length;)u===void 0?n[o]&&n[o][1].type==="data"&&(u=o,o++):(!n[o]||n[o][1].type!=="data")&&(o!==u+2&&(n[u][1].end=n[o-1][1].end,n.splice(u+2,o-u-2),o=u+2),u=void 0);return e?e(n,r):n}}function dI(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],o=t.sliceStream(r);let u=o.length,a=-1,c=0,f;for(;u--;){const h=o[u];if(typeof h=="string"){for(a=h.length;h.charCodeAt(a-1)===32;)c++,a--;if(a)break;a=-1}else if(h===-2)f=!0,c++;else if(h!==-1){u++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(c=0),c){const h={type:n===e.length||f||c<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:u?a:r.start._bufferIndex+a,_index:r.start._index+u,line:r.end.line,column:r.end.column-c,offset:r.end.offset-c},end:U({},r.end)};r.end=U({},h.start),r.start.offset===r.end.offset?Object.assign(r,h):(e.splice(n,0,["enter",h,t],["exit",h,t]),n+=2)}n++}return e}const hI=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:yO},disable:{null:[]},document:{42:wn,43:wn,45:wn,48:wn,49:wn,50:wn,51:wn,52:wn,53:wn,54:wn,55:wn,56:wn,57:wn,62:FE},flow:{35:wO,42:ml,45:[YE,ml],60:kO,61:YE,95:ml,96:HE,126:HE},flowInitial:{[-2]:Wd,[-1]:Wd,32:Wd},insideSpan:{null:[Yd,lI]},string:{38:BE,92:ME},text:{[-5]:Kd,[-4]:Kd,[-3]:Kd,33:YO,38:BE,42:Yd,60:[G3,DO],91:GO,92:[xO,ME],93:Gd,95:Yd,96:uO}},Symbol.toStringTag,{value:"Module"}));function pI(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const o={},u=[];let a=[],c=[];const f={attempt:te(q),check:te(B),consume:M,enter:D,exit:G,interrupt:te(B,{interrupt:!0})},h={code:null,containerState:{},defineSkip:S,events:[],now:_,parser:e,previous:null,sliceSerialize:b,sliceStream:T,write:E};let m=t.tokenize.call(h,f);return t.resolveAll&&u.push(t),h;function E(fe){return a=Yn(a,fe),C(),a[a.length-1]!==null?[]:(Te(t,0),h.events=pl(u,h.events,h),h.events)}function b(fe,de){return gI(T(fe),de)}function T(fe){return mI(a,fe)}function _(){const{_bufferIndex:fe,_index:de,line:ue,column:ie,offset:ge}=r;return{_bufferIndex:fe,_index:de,line:ue,column:ie,offset:ge}}function S(fe){o[fe.line]=fe.column,H()}function C(){let fe;for(;r._index<a.length;){const de=a[r._index];if(typeof de=="string")for(fe=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===fe&&r._bufferIndex<de.length;)k(de.charCodeAt(r._bufferIndex));else k(de)}}function k(fe){m=m(fe)}function M(fe){Re(fe)?(r.line++,r.column=1,r.offset+=fe===-3?2:1,H()):fe!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++)),h.previous=fe}function D(fe,de){const ue=de||{};return ue.type=fe,ue.start=_(),h.events.push(["enter",ue,h]),c.push(ue),ue}function G(fe){const de=c.pop();return de.end=_(),h.events.push(["exit",de,h]),de}function q(fe,de){Te(fe,de.from)}function B(fe,de){de.restore()}function te(fe,de){return ue;function ue(ie,ge,we){let ae,V,ee,w;return Array.isArray(ie)?Q(ie):"tokenize"in ie?Q([ie]):R(ie);function R(Ie){return Ye;function Ye(Ve){const Je=Ve!==null&&Ie[Ve],xt=Ve!==null&&Ie.null,be=[...Array.isArray(Je)?Je:Je?[Je]:[],...Array.isArray(xt)?xt:xt?[xt]:[]];return Q(be)(Ve)}}function Q(Ie){return ae=Ie,V=0,Ie.length===0?we:N(Ie[V])}function N(Ie){return Ye;function Ye(Ve){return w=Se(),ee=Ie,Ie.partial||(h.currentConstruct=Ie),Ie.name&&h.parser.constructs.disable.null.includes(Ie.name)?Me():Ie.tokenize.call(de?Object.assign(Object.create(h),de):h,f,_e,Me)(Ve)}}function _e(Ie){return fe(ee,w),ge}function Me(Ie){return w.restore(),++V<ae.length?N(ae[V]):we}}}function Te(fe,de){fe.resolveAll&&!u.includes(fe)&&u.push(fe),fe.resolve&&Dn(h.events,de,h.events.length-de,fe.resolve(h.events.slice(de),h)),fe.resolveTo&&(h.events=fe.resolveTo(h.events,h))}function Se(){const fe=_(),de=h.previous,ue=h.currentConstruct,ie=h.events.length,ge=Array.from(c);return{from:ie,restore:we};function we(){r=fe,h.previous=de,h.currentConstruct=ue,h.events.length=ie,c=ge,H()}}function H(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function mI(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,u=t.end._bufferIndex;let a;if(n===o)a=[e[n].slice(r,u)];else{if(a=e.slice(n,o),r>-1){const c=a[0];typeof c=="string"?a[0]=c.slice(r):a.shift()}u>0&&a.push(e[o].slice(0,u))}return a}function gI(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const u=e[n];let a;if(typeof u=="string")a=u;else switch(u){case-5:{a="\r";break}case-4:{a=`
14
+ `+y.stack}return{value:i,source:s,stack:g,digest:null}}function Jp(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function Zp(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var FF=typeof WeakMap=="function"?WeakMap:Map;function _2(i,s,l){l=si(-1,l),l.tag=3,l.payload={element:null};var d=s.value;return l.callback=function(){Lc||(Lc=!0,pm=d),Zp(i,s)},l}function x2(i,s,l){l=si(-1,l),l.tag=3;var d=i.type.getDerivedStateFromError;if(typeof d=="function"){var g=s.value;l.payload=function(){return d(g)},l.callback=function(){Zp(i,s)}}var y=i.stateNode;return y!==null&&typeof y.componentDidCatch=="function"&&(l.callback=function(){Zp(i,s),typeof d!="function"&&(Pi===null?Pi=new Set([this]):Pi.add(this));var x=s.stack;this.componentDidCatch(s.value,{componentStack:x!==null?x:""})}),l}function S2(i,s,l){var d=i.pingCache;if(d===null){d=i.pingCache=new FF;var g=new Set;d.set(s,g)}else g=d.get(s),g===void 0&&(g=new Set,d.set(s,g));g.has(l)||(g.add(l),i=QF.bind(null,i,s,l),s.then(i,i))}function w2(i){do{var s;if((s=i.tag===13)&&(s=i.memoizedState,s=s!==null?s.dehydrated!==null:!0),s)return i;i=i.return}while(i!==null);return null}function C2(i,s,l,d,g){return(i.mode&1)===0?(i===s?i.flags|=65536:(i.flags|=128,l.flags|=131072,l.flags&=-52805,l.tag===1&&(l.alternate===null?l.tag=17:(s=si(-1,1),s.tag=2,Oi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var MF=G.ReactCurrentOwner,An=!1;function hn(i,s,l,d){s.child=i===null?q_(s,null,l,d):yo(s,i.child,l,d)}function A2(i,s,l,d,g){l=l.render;var y=s.ref;return bo(s,g),d=Vp(i,s,l,d,y,g),l=qp(),i!==null&&!An?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,oi(i,s,g)):(bt&&l&&vp(s),s.flags|=1,hn(i,s,d,g),s.child)}function v2(i,s,l,d,g){if(i===null){var y=l.type;return typeof y=="function"&&!_m(y)&&y.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=y,k2(i,s,y,d,g)):(i=Hc(l.type,null,d,s,s.mode,g),i.ref=s.ref,i.return=s,s.child=i)}if(y=i.child,(i.lanes&g)===0){var x=y.memoizedProps;if(l=l.compare,l=l!==null?l:zu,l(x,d)&&i.ref===s.ref)return oi(i,s,g)}return s.flags|=1,i=Fi(y,d),i.ref=s.ref,i.return=s,s.child=i}function k2(i,s,l,d,g){if(i!==null){var y=i.memoizedProps;if(zu(y,d)&&i.ref===s.ref)if(An=!1,s.pendingProps=d=y,(i.lanes&g)!==0)(i.flags&131072)!==0&&(An=!0);else return s.lanes=i.lanes,oi(i,s,g)}return em(i,s,l,d,g)}function N2(i,s,l){var d=s.pendingProps,g=d.children,y=i!==null?i.memoizedState:null;if(d.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},ht(wo,Hn),Hn|=l;else{if((l&1073741824)===0)return i=y!==null?y.baseLanes|l:l,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,ht(wo,Hn),Hn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},d=y!==null?y.baseLanes:l,ht(wo,Hn),Hn|=d}else y!==null?(d=y.baseLanes|l,s.memoizedState=null):d=l,ht(wo,Hn),Hn|=d;return hn(i,s,g,l),s.child}function O2(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function em(i,s,l,d,g){var y=Cn(l)?is:un.current;return y=po(s,y),bo(s,g),l=Vp(i,s,l,d,y,g),d=qp(),i!==null&&!An?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,oi(i,s,g)):(bt&&d&&vp(s),s.flags|=1,hn(i,s,l,g),s.child)}function I2(i,s,l,d,g){if(Cn(l)){var y=!0;fc(s)}else y=!1;if(bo(s,g),s.stateNode===null)Nc(i,s),T2(s,l,d),Xp(s,l,d,g),d=!0;else if(i===null){var x=s.stateNode,O=s.memoizedProps;x.props=O;var L=x.context,Y=l.contextType;typeof Y=="object"&&Y!==null?Y=Xn(Y):(Y=Cn(l)?is:un.current,Y=po(s,Y));var se=l.getDerivedStateFromProps,ce=typeof se=="function"||typeof x.getSnapshotBeforeUpdate=="function";ce||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(O!==d||L!==Y)&&b2(s,x,d,Y),Ni=!1;var ne=s.memoizedState;x.state=ne,bc(s,d,x,g),L=s.memoizedState,O!==d||ne!==L||wn.current||Ni?(typeof se=="function"&&(Qp(s,l,se,d),L=s.memoizedState),(O=Ni||y2(s,l,O,d,ne,L,Y))?(ce||typeof x.UNSAFE_componentWillMount!="function"&&typeof x.componentWillMount!="function"||(typeof x.componentWillMount=="function"&&x.componentWillMount(),typeof x.UNSAFE_componentWillMount=="function"&&x.UNSAFE_componentWillMount()),typeof x.componentDidMount=="function"&&(s.flags|=4194308)):(typeof x.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=d,s.memoizedState=L),x.props=d,x.state=L,x.context=Y,d=O):(typeof x.componentDidMount=="function"&&(s.flags|=4194308),d=!1)}else{x=s.stateNode,W_(i,s),O=s.memoizedProps,Y=s.type===s.elementType?O:gr(s.type,O),x.props=Y,ce=s.pendingProps,ne=x.context,L=l.contextType,typeof L=="object"&&L!==null?L=Xn(L):(L=Cn(l)?is:un.current,L=po(s,L));var xe=l.getDerivedStateFromProps;(se=typeof xe=="function"||typeof x.getSnapshotBeforeUpdate=="function")||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(O!==ce||ne!==L)&&b2(s,x,d,L),Ni=!1,ne=s.memoizedState,x.state=ne,bc(s,d,x,g);var Ae=s.memoizedState;O!==ce||ne!==Ae||wn.current||Ni?(typeof xe=="function"&&(Qp(s,l,xe,d),Ae=s.memoizedState),(Y=Ni||y2(s,l,Y,d,ne,Ae,L)||!1)?(se||typeof x.UNSAFE_componentWillUpdate!="function"&&typeof x.componentWillUpdate!="function"||(typeof x.componentWillUpdate=="function"&&x.componentWillUpdate(d,Ae,L),typeof x.UNSAFE_componentWillUpdate=="function"&&x.UNSAFE_componentWillUpdate(d,Ae,L)),typeof x.componentDidUpdate=="function"&&(s.flags|=4),typeof x.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof x.componentDidUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=1024),s.memoizedProps=d,s.memoizedState=Ae),x.props=d,x.state=Ae,x.context=L,d=Y):(typeof x.componentDidUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||O===i.memoizedProps&&ne===i.memoizedState||(s.flags|=1024),d=!1)}return tm(i,s,l,d,y,g)}function tm(i,s,l,d,g,y){O2(i,s);var x=(s.flags&128)!==0;if(!d&&!x)return g&&F_(s,l,!1),oi(i,s,y);d=s.stateNode,MF.current=s;var O=x&&typeof l.getDerivedStateFromError!="function"?null:d.render();return s.flags|=1,i!==null&&x?(s.child=yo(s,i.child,null,y),s.child=yo(s,null,O,y)):hn(i,s,O,y),s.memoizedState=d.state,g&&F_(s,l,!0),s.child}function P2(i){var s=i.stateNode;s.pendingContext?L_(i,s.pendingContext,s.pendingContext!==s.context):s.context&&L_(i,s.context,!1),Bp(i,s.containerInfo)}function R2(i,s,l,d,g){return Eo(),Ip(g),s.flags|=256,hn(i,s,l,d),s.child}var nm={dehydrated:null,treeContext:null,retryLane:0};function rm(i){return{baseLanes:i,cachePool:null,transitions:null}}function L2(i,s,l){var d=s.pendingProps,g=wt.current,y=!1,x=(s.flags&128)!==0,O;if((O=x)||(O=i!==null&&i.memoizedState===null?!1:(g&2)!==0),O?(y=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(g|=1),ht(wt,g&1),i===null)return Op(s),i=s.memoizedState,i!==null&&(i=i.dehydrated,i!==null)?((s.mode&1)===0?s.lanes=1:i.data==="$!"?s.lanes=8:s.lanes=1073741824,null):(x=d.children,i=d.fallback,y?(d=s.mode,y=s.child,x={mode:"hidden",children:x},(d&1)===0&&y!==null?(y.childLanes=0,y.pendingProps=x):y=zc(x,d,0,null),i=ps(i,d,l,null),y.return=s,i.return=s,y.sibling=i,s.child=y,s.child.memoizedState=rm(l),s.memoizedState=nm,i):im(s,x));if(g=i.memoizedState,g!==null&&(O=g.dehydrated,O!==null))return BF(i,s,x,d,O,g,l);if(y){y=d.fallback,x=s.mode,g=i.child,O=g.sibling;var L={mode:"hidden",children:d.children};return(x&1)===0&&s.child!==g?(d=s.child,d.childLanes=0,d.pendingProps=L,s.deletions=null):(d=Fi(g,L),d.subtreeFlags=g.subtreeFlags&14680064),O!==null?y=Fi(O,y):(y=ps(y,x,l,null),y.flags|=2),y.return=s,d.return=s,d.sibling=y,s.child=d,d=y,y=s.child,x=i.child.memoizedState,x=x===null?rm(l):{baseLanes:x.baseLanes|l,cachePool:null,transitions:x.transitions},y.memoizedState=x,y.childLanes=i.childLanes&~l,s.memoizedState=nm,d}return y=i.child,i=y.sibling,d=Fi(y,{mode:"visible",children:d.children}),(s.mode&1)===0&&(d.lanes=l),d.return=s,d.sibling=null,i!==null&&(l=s.deletions,l===null?(s.deletions=[i],s.flags|=16):l.push(i)),s.child=d,s.memoizedState=null,d}function im(i,s){return s=zc({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function kc(i,s,l,d){return d!==null&&Ip(d),yo(s,i.child,null,l),i=im(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function BF(i,s,l,d,g,y,x){if(l)return s.flags&256?(s.flags&=-257,d=Jp(Error(n(422))),kc(i,s,x,d)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(y=d.fallback,g=s.mode,d=zc({mode:"visible",children:d.children},g,0,null),y=ps(y,g,x,null),y.flags|=2,d.return=s,y.return=s,d.sibling=y,s.child=d,(s.mode&1)!==0&&yo(s,i.child,null,x),s.child.memoizedState=rm(x),s.memoizedState=nm,y);if((s.mode&1)===0)return kc(i,s,x,null);if(g.data==="$!"){if(d=g.nextSibling&&g.nextSibling.dataset,d)var O=d.dgst;return d=O,y=Error(n(419)),d=Jp(y,d,void 0),kc(i,s,x,d)}if(O=(x&i.childLanes)!==0,An||O){if(d=Gt,d!==null){switch(x&-x){case 4:g=2;break;case 16:g=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:g=32;break;case 536870912:g=268435456;break;default:g=0}g=(g&(d.suspendedLanes|x))!==0?0:g,g!==0&&g!==y.retryLane&&(y.retryLane=g,ii(i,g),Tr(d,i,g,-1))}return bm(),d=Jp(Error(n(421))),kc(i,s,x,d)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=XF.bind(null,i),g._reactRetry=s,null):(i=y.treeContext,Un=Ci(g.nextSibling),Bn=s,bt=!0,mr=null,i!==null&&(Kn[Qn++]=ni,Kn[Qn++]=ri,Kn[Qn++]=ss,ni=i.id,ri=i.overflow,ss=s),s=im(s,d.children),s.flags|=4096,s)}function D2(i,s,l){i.lanes|=s;var d=i.alternate;d!==null&&(d.lanes|=s),Dp(i.return,s,l)}function sm(i,s,l,d,g){var y=i.memoizedState;y===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:d,tail:l,tailMode:g}:(y.isBackwards=s,y.rendering=null,y.renderingStartTime=0,y.last=d,y.tail=l,y.tailMode=g)}function F2(i,s,l){var d=s.pendingProps,g=d.revealOrder,y=d.tail;if(hn(i,s,d.children,l),d=wt.current,(d&2)!==0)d=d&1|2,s.flags|=128;else{if(i!==null&&(i.flags&128)!==0)e:for(i=s.child;i!==null;){if(i.tag===13)i.memoizedState!==null&&D2(i,l,s);else if(i.tag===19)D2(i,l,s);else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===s)break e;for(;i.sibling===null;){if(i.return===null||i.return===s)break e;i=i.return}i.sibling.return=i.return,i=i.sibling}d&=1}if(ht(wt,d),(s.mode&1)===0)s.memoizedState=null;else switch(g){case"forwards":for(l=s.child,g=null;l!==null;)i=l.alternate,i!==null&&_c(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),sm(s,!1,g,l,y);break;case"backwards":for(l=null,g=s.child,s.child=null;g!==null;){if(i=g.alternate,i!==null&&_c(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}sm(s,!0,l,null,y);break;case"together":sm(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function Nc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function oi(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),cs|=s.lanes,(l&s.childLanes)===0)return null;if(i!==null&&s.child!==i.child)throw Error(n(153));if(s.child!==null){for(i=s.child,l=Fi(i,i.pendingProps),s.child=l,l.return=s;i.sibling!==null;)i=i.sibling,l=l.sibling=Fi(i,i.pendingProps),l.return=s;l.sibling=null}return s.child}function UF(i,s,l){switch(s.tag){case 3:P2(s),Eo();break;case 5:Q_(s);break;case 1:Cn(s.type)&&fc(s);break;case 4:Bp(s,s.stateNode.containerInfo);break;case 10:var d=s.type._context,g=s.memoizedProps.value;ht(Ec,d._currentValue),d._currentValue=g;break;case 13:if(d=s.memoizedState,d!==null)return d.dehydrated!==null?(ht(wt,wt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?L2(i,s,l):(ht(wt,wt.current&1),i=oi(i,s,l),i!==null?i.sibling:null);ht(wt,wt.current&1);break;case 19:if(d=(l&s.childLanes)!==0,(i.flags&128)!==0){if(d)return F2(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),ht(wt,wt.current),d)break;return null;case 22:case 23:return s.lanes=0,N2(i,s,l)}return oi(i,s,l)}var M2,om,B2,U2;M2=function(i,s){for(var l=s.child;l!==null;){if(l.tag===5||l.tag===6)i.appendChild(l.stateNode);else if(l.tag!==4&&l.child!==null){l.child.return=l,l=l.child;continue}if(l===s)break;for(;l.sibling===null;){if(l.return===null||l.return===s)return;l=l.return}l.sibling.return=l.return,l=l.sibling}},om=function(){},B2=function(i,s,l,d){var g=i.memoizedProps;if(g!==d){i=s.stateNode,as(Mr.current);var y=null;switch(l){case"input":g=Tt(i,g),d=Tt(i,d),y=[];break;case"select":g=w({},g,{value:void 0}),d=w({},d,{value:void 0}),y=[];break;case"textarea":g=Cu(i,g),d=Cu(i,d),y=[];break;default:typeof g.onClick!="function"&&typeof d.onClick=="function"&&(i.onclick=ac)}Xt(l,d);var x;l=null;for(Y in g)if(!d.hasOwnProperty(Y)&&g.hasOwnProperty(Y)&&g[Y]!=null)if(Y==="style"){var O=g[Y];for(x in O)O.hasOwnProperty(x)&&(l||(l={}),l[x]="")}else Y!=="dangerouslySetInnerHTML"&&Y!=="children"&&Y!=="suppressContentEditableWarning"&&Y!=="suppressHydrationWarning"&&Y!=="autoFocus"&&(o.hasOwnProperty(Y)?y||(y=[]):(y=y||[]).push(Y,null));for(Y in d){var L=d[Y];if(O=g!=null?g[Y]:void 0,d.hasOwnProperty(Y)&&L!==O&&(L!=null||O!=null))if(Y==="style")if(O){for(x in O)!O.hasOwnProperty(x)||L&&L.hasOwnProperty(x)||(l||(l={}),l[x]="");for(x in L)L.hasOwnProperty(x)&&O[x]!==L[x]&&(l||(l={}),l[x]=L[x])}else l||(y||(y=[]),y.push(Y,l)),l=L;else Y==="dangerouslySetInnerHTML"?(L=L?L.__html:void 0,O=O?O.__html:void 0,L!=null&&O!==L&&(y=y||[]).push(Y,L)):Y==="children"?typeof L!="string"&&typeof L!="number"||(y=y||[]).push(Y,""+L):Y!=="suppressContentEditableWarning"&&Y!=="suppressHydrationWarning"&&(o.hasOwnProperty(Y)?(L!=null&&Y==="onScroll"&&pt("scroll",i),y||O===L||(y=[])):(y=y||[]).push(Y,L))}l&&(y=y||[]).push("style",l);var Y=y;(s.updateQueue=Y)&&(s.flags|=4)}},U2=function(i,s,l,d){l!==d&&(s.flags|=4)};function na(i,s){if(!bt)switch(i.tailMode){case"hidden":s=i.tail;for(var l=null;s!==null;)s.alternate!==null&&(l=s),s=s.sibling;l===null?i.tail=null:l.sibling=null;break;case"collapsed":l=i.tail;for(var d=null;l!==null;)l.alternate!==null&&(d=l),l=l.sibling;d===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:d.sibling=null}}function ln(i){var s=i.alternate!==null&&i.alternate.child===i.child,l=0,d=0;if(s)for(var g=i.child;g!==null;)l|=g.lanes|g.childLanes,d|=g.subtreeFlags&14680064,d|=g.flags&14680064,g.return=i,g=g.sibling;else for(g=i.child;g!==null;)l|=g.lanes|g.childLanes,d|=g.subtreeFlags,d|=g.flags,g.return=i,g=g.sibling;return i.subtreeFlags|=d,i.childLanes=l,s}function HF(i,s,l){var d=s.pendingProps;switch(kp(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ln(s),null;case 1:return Cn(s.type)&&cc(),ln(s),null;case 3:return d=s.stateNode,_o(),mt(wn),mt(un),zp(),d.pendingContext&&(d.context=d.pendingContext,d.pendingContext=null),(i===null||i.child===null)&&(mc(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,mr!==null&&(Em(mr),mr=null))),om(i,s),ln(s),null;case 5:Up(s);var g=as(Xu.current);if(l=s.type,i!==null&&s.stateNode!=null)B2(i,s,l,d,g),i.ref!==s.ref&&(s.flags|=512,s.flags|=2097152);else{if(!d){if(s.stateNode===null)throw Error(n(166));return ln(s),null}if(i=as(Mr.current),mc(s)){d=s.stateNode,l=s.type;var y=s.memoizedProps;switch(d[Fr]=s,d[Yu]=y,i=(s.mode&1)!==0,l){case"dialog":pt("cancel",d),pt("close",d);break;case"iframe":case"object":case"embed":pt("load",d);break;case"video":case"audio":for(g=0;g<$u.length;g++)pt($u[g],d);break;case"source":pt("error",d);break;case"img":case"image":case"link":pt("error",d),pt("load",d);break;case"details":pt("toggle",d);break;case"input":St(d,y),pt("invalid",d);break;case"select":d._wrapperState={wasMultiple:!!y.multiple},pt("invalid",d);break;case"textarea":Bl(d,y),pt("invalid",d)}Xt(l,y),g=null;for(var x in y)if(y.hasOwnProperty(x)){var O=y[x];x==="children"?typeof O=="string"?d.textContent!==O&&(y.suppressHydrationWarning!==!0&&uc(d.textContent,O,i),g=["children",O]):typeof O=="number"&&d.textContent!==""+O&&(y.suppressHydrationWarning!==!0&&uc(d.textContent,O,i),g=["children",""+O]):o.hasOwnProperty(x)&&O!=null&&x==="onScroll"&&pt("scroll",d)}switch(l){case"input":be(d),rt(d,y,!0);break;case"textarea":be(d),Hl(d);break;case"select":case"option":break;default:typeof y.onClick=="function"&&(d.onclick=ac)}d=g,s.updateQueue=d,d!==null&&(s.flags|=4)}else{x=g.nodeType===9?g:g.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=J(l)),i==="http://www.w3.org/1999/xhtml"?l==="script"?(i=x.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof d.is=="string"?i=x.createElement(l,{is:d.is}):(i=x.createElement(l),l==="select"&&(x=i,d.multiple?x.multiple=!0:d.size&&(x.size=d.size))):i=x.createElementNS(i,l),i[Fr]=s,i[Yu]=d,M2(i,s,!1,!1),s.stateNode=i;e:{switch(x=Lr(l,d),l){case"dialog":pt("cancel",i),pt("close",i),g=d;break;case"iframe":case"object":case"embed":pt("load",i),g=d;break;case"video":case"audio":for(g=0;g<$u.length;g++)pt($u[g],i);g=d;break;case"source":pt("error",i),g=d;break;case"img":case"image":case"link":pt("error",i),pt("load",i),g=d;break;case"details":pt("toggle",i),g=d;break;case"input":St(i,d),g=Tt(i,d),pt("invalid",i);break;case"option":g=d;break;case"select":i._wrapperState={wasMultiple:!!d.multiple},g=w({},d,{value:void 0}),pt("invalid",i);break;case"textarea":Bl(i,d),g=Cu(i,d),pt("invalid",i);break;default:g=d}Xt(l,g),O=g;for(y in O)if(O.hasOwnProperty(y)){var L=O[y];y==="style"?yi(i,L):y==="dangerouslySetInnerHTML"?(L=L?L.__html:void 0,L!=null&&We(i,L)):y==="children"?typeof L=="string"?(l!=="textarea"||L!=="")&&Ze(i,L):typeof L=="number"&&Ze(i,""+L):y!=="suppressContentEditableWarning"&&y!=="suppressHydrationWarning"&&y!=="autoFocus"&&(o.hasOwnProperty(y)?L!=null&&y==="onScroll"&&pt("scroll",i):L!=null&&D(i,y,L,x))}switch(l){case"input":be(i),rt(i,d,!1);break;case"textarea":be(i),Hl(i);break;case"option":d.value!=null&&i.setAttribute("value",""+Ve(d.value));break;case"select":i.multiple=!!d.multiple,y=d.value,y!=null?Yt(i,!!d.multiple,y,!1):d.defaultValue!=null&&Yt(i,!!d.multiple,d.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=ac)}switch(l){case"button":case"input":case"select":case"textarea":d=!!d.autoFocus;break e;case"img":d=!0;break e;default:d=!1}}d&&(s.flags|=4)}s.ref!==null&&(s.flags|=512,s.flags|=2097152)}return ln(s),null;case 6:if(i&&s.stateNode!=null)U2(i,s,i.memoizedProps,d);else{if(typeof d!="string"&&s.stateNode===null)throw Error(n(166));if(l=as(Xu.current),as(Mr.current),mc(s)){if(d=s.stateNode,l=s.memoizedProps,d[Fr]=s,(y=d.nodeValue!==l)&&(i=Bn,i!==null))switch(i.tag){case 3:uc(d.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&uc(d.nodeValue,l,(i.mode&1)!==0)}y&&(s.flags|=4)}else d=(l.nodeType===9?l:l.ownerDocument).createTextNode(d),d[Fr]=s,s.stateNode=d}return ln(s),null;case 13:if(mt(wt),d=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(bt&&Un!==null&&(s.mode&1)!==0&&(s.flags&128)===0)j_(),Eo(),s.flags|=98560,y=!1;else if(y=mc(s),d!==null&&d.dehydrated!==null){if(i===null){if(!y)throw Error(n(318));if(y=s.memoizedState,y=y!==null?y.dehydrated:null,!y)throw Error(n(317));y[Fr]=s}else Eo(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;ln(s),y=!1}else mr!==null&&(Em(mr),mr=null),y=!0;if(!y)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=l,s):(d=d!==null,d!==(i!==null&&i.memoizedState!==null)&&d&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(wt.current&1)!==0?Ut===0&&(Ut=3):bm())),s.updateQueue!==null&&(s.flags|=4),ln(s),null);case 4:return _o(),om(i,s),i===null&&Vu(s.stateNode.containerInfo),ln(s),null;case 10:return Lp(s.type._context),ln(s),null;case 17:return Cn(s.type)&&cc(),ln(s),null;case 19:if(mt(wt),y=s.memoizedState,y===null)return ln(s),null;if(d=(s.flags&128)!==0,x=y.rendering,x===null)if(d)na(y,!1);else{if(Ut!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(x=_c(i),x!==null){for(s.flags|=128,na(y,!1),d=x.updateQueue,d!==null&&(s.updateQueue=d,s.flags|=4),s.subtreeFlags=0,d=l,l=s.child;l!==null;)y=l,i=d,y.flags&=14680066,x=y.alternate,x===null?(y.childLanes=0,y.lanes=i,y.child=null,y.subtreeFlags=0,y.memoizedProps=null,y.memoizedState=null,y.updateQueue=null,y.dependencies=null,y.stateNode=null):(y.childLanes=x.childLanes,y.lanes=x.lanes,y.child=x.child,y.subtreeFlags=0,y.deletions=null,y.memoizedProps=x.memoizedProps,y.memoizedState=x.memoizedState,y.updateQueue=x.updateQueue,y.type=x.type,i=x.dependencies,y.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return ht(wt,wt.current&1|2),s.child}i=i.sibling}y.tail!==null&&Pt()>Co&&(s.flags|=128,d=!0,na(y,!1),s.lanes=4194304)}else{if(!d)if(i=_c(x),i!==null){if(s.flags|=128,d=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),na(y,!0),y.tail===null&&y.tailMode==="hidden"&&!x.alternate&&!bt)return ln(s),null}else 2*Pt()-y.renderingStartTime>Co&&l!==1073741824&&(s.flags|=128,d=!0,na(y,!1),s.lanes=4194304);y.isBackwards?(x.sibling=s.child,s.child=x):(l=y.last,l!==null?l.sibling=x:s.child=x,y.last=x)}return y.tail!==null?(s=y.tail,y.rendering=s,y.tail=s.sibling,y.renderingStartTime=Pt(),s.sibling=null,l=wt.current,ht(wt,d?l&1|2:l&1),s):(ln(s),null);case 22:case 23:return Tm(),d=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==d&&(s.flags|=8192),d&&(s.mode&1)!==0?(Hn&1073741824)!==0&&(ln(s),s.subtreeFlags&6&&(s.flags|=8192)):ln(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function zF(i,s){switch(kp(s),s.tag){case 1:return Cn(s.type)&&cc(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return _o(),mt(wn),mt(un),zp(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return Up(s),null;case 13:if(mt(wt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));Eo()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return mt(wt),null;case 4:return _o(),null;case 10:return Lp(s.type._context),null;case 22:case 23:return Tm(),null;case 24:return null;default:return null}}var Oc=!1,cn=!1,jF=typeof WeakSet=="function"?WeakSet:Set,Ce=null;function So(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(d){vt(i,s,d)}else l.current=null}function um(i,s,l){try{l()}catch(d){vt(i,s,d)}}var H2=!1;function $F(i,s){if(Tp=Ql,i=y_(),fp(i)){if("selectionStart"in i)var l={start:i.selectionStart,end:i.selectionEnd};else e:{l=(l=i.ownerDocument)&&l.defaultView||window;var d=l.getSelection&&l.getSelection();if(d&&d.rangeCount!==0){l=d.anchorNode;var g=d.anchorOffset,y=d.focusNode;d=d.focusOffset;try{l.nodeType,y.nodeType}catch(me){l=null;break e}var x=0,O=-1,L=-1,Y=0,se=0,ce=i,ne=null;t:for(;;){for(var xe;ce!==l||g!==0&&ce.nodeType!==3||(O=x+g),ce!==y||d!==0&&ce.nodeType!==3||(L=x+d),ce.nodeType===3&&(x+=ce.nodeValue.length),(xe=ce.firstChild)!==null;)ne=ce,ce=xe;for(;;){if(ce===i)break t;if(ne===l&&++Y===g&&(O=x),ne===y&&++se===d&&(L=x),(xe=ce.nextSibling)!==null)break;ce=ne,ne=ce.parentNode}ce=xe}l=O===-1||L===-1?null:{start:O,end:L}}else l=null}l=l||{start:0,end:0}}else l=null;for(bp={focusedElem:i,selectionRange:l},Ql=!1,Ce=s;Ce!==null;)if(s=Ce,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,Ce=i;else for(;Ce!==null;){s=Ce;try{var Ae=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(Ae!==null){var ve=Ae.memoizedProps,Rt=Ae.memoizedState,z=s.stateNode,F=z.getSnapshotBeforeUpdate(s.elementType===s.type?ve:gr(s.type,ve),Rt);z.__reactInternalSnapshotBeforeUpdate=F}break;case 3:var $=s.stateNode.containerInfo;$.nodeType===1?$.textContent="":$.nodeType===9&&$.documentElement&&$.removeChild($.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(me){vt(s,s.return,me)}if(i=s.sibling,i!==null){i.return=s.return,Ce=i;break}Ce=s.return}return Ae=H2,H2=!1,Ae}function ra(i,s,l){var d=s.updateQueue;if(d=d!==null?d.lastEffect:null,d!==null){var g=d=d.next;do{if((g.tag&i)===i){var y=g.destroy;g.destroy=void 0,y!==void 0&&um(s,l,y)}g=g.next}while(g!==d)}}function Ic(i,s){if(s=s.updateQueue,s=s!==null?s.lastEffect:null,s!==null){var l=s=s.next;do{if((l.tag&i)===i){var d=l.create;l.destroy=d()}l=l.next}while(l!==s)}}function am(i){var s=i.ref;if(s!==null){var l=i.stateNode;switch(i.tag){case 5:i=l;break;default:i=l}typeof s=="function"?s(i):s.current=i}}function z2(i){var s=i.alternate;s!==null&&(i.alternate=null,z2(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[Fr],delete s[Yu],delete s[wp],delete s[CF],delete s[AF])),i.stateNode=null,i.return=null,i.dependencies=null,i.memoizedProps=null,i.memoizedState=null,i.pendingProps=null,i.stateNode=null,i.updateQueue=null}function j2(i){return i.tag===5||i.tag===3||i.tag===4}function $2(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||j2(i.return))return null;i=i.return}for(i.sibling.return=i.return,i=i.sibling;i.tag!==5&&i.tag!==6&&i.tag!==18;){if(i.flags&2||i.child===null||i.tag===4)continue e;i.child.return=i,i=i.child}if(!(i.flags&2))return i.stateNode}}function lm(i,s,l){var d=i.tag;if(d===5||d===6)i=i.stateNode,s?l.nodeType===8?l.parentNode.insertBefore(i,s):l.insertBefore(i,s):(l.nodeType===8?(s=l.parentNode,s.insertBefore(i,l)):(s=l,s.appendChild(i)),l=l._reactRootContainer,l!=null||s.onclick!==null||(s.onclick=ac));else if(d!==4&&(i=i.child,i!==null))for(lm(i,s,l),i=i.sibling;i!==null;)lm(i,s,l),i=i.sibling}function cm(i,s,l){var d=i.tag;if(d===5||d===6)i=i.stateNode,s?l.insertBefore(i,s):l.appendChild(i);else if(d!==4&&(i=i.child,i!==null))for(cm(i,s,l),i=i.sibling;i!==null;)cm(i,s,l),i=i.sibling}var Jt=null,Er=!1;function Ii(i,s,l){for(l=l.child;l!==null;)V2(i,s,l),l=l.sibling}function V2(i,s,l){if(Dr&&typeof Dr.onCommitFiberUnmount=="function")try{Dr.onCommitFiberUnmount(Vl,l)}catch(O){}switch(l.tag){case 5:cn||So(l,s);case 6:var d=Jt,g=Er;Jt=null,Ii(i,s,l),Jt=d,Er=g,Jt!==null&&(Er?(i=Jt,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):Jt.removeChild(l.stateNode));break;case 18:Jt!==null&&(Er?(i=Jt,l=l.stateNode,i.nodeType===8?Sp(i.parentNode,l):i.nodeType===1&&Sp(i,l),Du(i)):Sp(Jt,l.stateNode));break;case 4:d=Jt,g=Er,Jt=l.stateNode.containerInfo,Er=!0,Ii(i,s,l),Jt=d,Er=g;break;case 0:case 11:case 14:case 15:if(!cn&&(d=l.updateQueue,d!==null&&(d=d.lastEffect,d!==null))){g=d=d.next;do{var y=g,x=y.destroy;y=y.tag,x!==void 0&&((y&2)!==0||(y&4)!==0)&&um(l,s,x),g=g.next}while(g!==d)}Ii(i,s,l);break;case 1:if(!cn&&(So(l,s),d=l.stateNode,typeof d.componentWillUnmount=="function"))try{d.props=l.memoizedProps,d.state=l.memoizedState,d.componentWillUnmount()}catch(O){vt(l,s,O)}Ii(i,s,l);break;case 21:Ii(i,s,l);break;case 22:l.mode&1?(cn=(d=cn)||l.memoizedState!==null,Ii(i,s,l),cn=d):Ii(i,s,l);break;default:Ii(i,s,l)}}function q2(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new jF),s.forEach(function(d){var g=JF.bind(null,i,d);l.has(d)||(l.add(d),d.then(g,g))})}}function yr(i,s){var l=s.deletions;if(l!==null)for(var d=0;d<l.length;d++){var g=l[d];try{var y=i,x=s,O=x;e:for(;O!==null;){switch(O.tag){case 5:Jt=O.stateNode,Er=!1;break e;case 3:Jt=O.stateNode.containerInfo,Er=!0;break e;case 4:Jt=O.stateNode.containerInfo,Er=!0;break e}O=O.return}if(Jt===null)throw Error(n(160));V2(y,x,g),Jt=null,Er=!1;var L=g.alternate;L!==null&&(L.return=null),g.return=null}catch(Y){vt(g,s,Y)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)Y2(s,i),s=s.sibling}function Y2(i,s){var l=i.alternate,d=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(yr(s,i),Ur(i),d&4){try{ra(3,i,i.return),Ic(3,i)}catch(ve){vt(i,i.return,ve)}try{ra(5,i,i.return)}catch(ve){vt(i,i.return,ve)}}break;case 1:yr(s,i),Ur(i),d&512&&l!==null&&So(l,l.return);break;case 5:if(yr(s,i),Ur(i),d&512&&l!==null&&So(l,l.return),i.flags&32){var g=i.stateNode;try{Ze(g,"")}catch(ve){vt(i,i.return,ve)}}if(d&4&&(g=i.stateNode,g!=null)){var y=i.memoizedProps,x=l!==null?l.memoizedProps:y,O=i.type,L=i.updateQueue;if(i.updateQueue=null,L!==null)try{O==="input"&&y.type==="radio"&&y.name!=null&&on(g,y),Lr(O,x);var Y=Lr(O,y);for(x=0;x<L.length;x+=2){var se=L[x],ce=L[x+1];se==="style"?yi(g,ce):se==="dangerouslySetInnerHTML"?We(g,ce):se==="children"?Ze(g,ce):D(g,se,ce,Y)}switch(O){case"input":qt(g,y);break;case"textarea":Ul(g,y);break;case"select":var ne=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!y.multiple;var xe=y.value;xe!=null?Yt(g,!!y.multiple,xe,!1):ne!==!!y.multiple&&(y.defaultValue!=null?Yt(g,!!y.multiple,y.defaultValue,!0):Yt(g,!!y.multiple,y.multiple?[]:"",!1))}g[Yu]=y}catch(ve){vt(i,i.return,ve)}}break;case 6:if(yr(s,i),Ur(i),d&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,y=i.memoizedProps;try{g.nodeValue=y}catch(ve){vt(i,i.return,ve)}}break;case 3:if(yr(s,i),Ur(i),d&4&&l!==null&&l.memoizedState.isDehydrated)try{Du(s.containerInfo)}catch(ve){vt(i,i.return,ve)}break;case 4:yr(s,i),Ur(i);break;case 13:yr(s,i),Ur(i),g=i.child,g.flags&8192&&(y=g.memoizedState!==null,g.stateNode.isHidden=y,!y||g.alternate!==null&&g.alternate.memoizedState!==null||(hm=Pt())),d&4&&q2(i);break;case 22:if(se=l!==null&&l.memoizedState!==null,i.mode&1?(cn=(Y=cn)||se,yr(s,i),cn=Y):yr(s,i),Ur(i),d&8192){if(Y=i.memoizedState!==null,(i.stateNode.isHidden=Y)&&!se&&(i.mode&1)!==0)for(Ce=i,se=i.child;se!==null;){for(ce=Ce=se;Ce!==null;){switch(ne=Ce,xe=ne.child,ne.tag){case 0:case 11:case 14:case 15:ra(4,ne,ne.return);break;case 1:So(ne,ne.return);var Ae=ne.stateNode;if(typeof Ae.componentWillUnmount=="function"){d=ne,l=ne.return;try{s=d,Ae.props=s.memoizedProps,Ae.state=s.memoizedState,Ae.componentWillUnmount()}catch(ve){vt(d,l,ve)}}break;case 5:So(ne,ne.return);break;case 22:if(ne.memoizedState!==null){K2(ce);continue}}xe!==null?(xe.return=ne,Ce=xe):K2(ce)}se=se.sibling}e:for(se=null,ce=i;;){if(ce.tag===5){if(se===null){se=ce;try{g=ce.stateNode,Y?(y=g.style,typeof y.setProperty=="function"?y.setProperty("display","none","important"):y.display="none"):(O=ce.stateNode,L=ce.memoizedProps.style,x=L!=null&&L.hasOwnProperty("display")?L.display:null,O.style.display=Gn("display",x))}catch(ve){vt(i,i.return,ve)}}}else if(ce.tag===6){if(se===null)try{ce.stateNode.nodeValue=Y?"":ce.memoizedProps}catch(ve){vt(i,i.return,ve)}}else if((ce.tag!==22&&ce.tag!==23||ce.memoizedState===null||ce===i)&&ce.child!==null){ce.child.return=ce,ce=ce.child;continue}if(ce===i)break e;for(;ce.sibling===null;){if(ce.return===null||ce.return===i)break e;se===ce&&(se=null),ce=ce.return}se===ce&&(se=null),ce.sibling.return=ce.return,ce=ce.sibling}}break;case 19:yr(s,i),Ur(i),d&4&&q2(i);break;case 21:break;default:yr(s,i),Ur(i)}}function Ur(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(j2(l)){var d=l;break e}l=l.return}throw Error(n(160))}switch(d.tag){case 5:var g=d.stateNode;d.flags&32&&(Ze(g,""),d.flags&=-33);var y=$2(i);cm(i,y,g);break;case 3:case 4:var x=d.stateNode.containerInfo,O=$2(i);lm(i,O,x);break;default:throw Error(n(161))}}catch(L){vt(i,i.return,L)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function VF(i,s,l){Ce=i,W2(i)}function W2(i,s,l){for(var d=(i.mode&1)!==0;Ce!==null;){var g=Ce,y=g.child;if(g.tag===22&&d){var x=g.memoizedState!==null||Oc;if(!x){var O=g.alternate,L=O!==null&&O.memoizedState!==null||cn;O=Oc;var Y=cn;if(Oc=x,(cn=L)&&!Y)for(Ce=g;Ce!==null;)x=Ce,L=x.child,x.tag===22&&x.memoizedState!==null?Q2(g):L!==null?(L.return=x,Ce=L):Q2(g);for(;y!==null;)Ce=y,W2(y),y=y.sibling;Ce=g,Oc=O,cn=Y}G2(i)}else(g.subtreeFlags&8772)!==0&&y!==null?(y.return=g,Ce=y):G2(i)}}function G2(i){for(;Ce!==null;){var s=Ce;if((s.flags&8772)!==0){var l=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:cn||Ic(5,s);break;case 1:var d=s.stateNode;if(s.flags&4&&!cn)if(l===null)d.componentDidMount();else{var g=s.elementType===s.type?l.memoizedProps:gr(s.type,l.memoizedProps);d.componentDidUpdate(g,l.memoizedState,d.__reactInternalSnapshotBeforeUpdate)}var y=s.updateQueue;y!==null&&K_(s,y,d);break;case 3:var x=s.updateQueue;if(x!==null){if(l=null,s.child!==null)switch(s.child.tag){case 5:l=s.child.stateNode;break;case 1:l=s.child.stateNode}K_(s,x,l)}break;case 5:var O=s.stateNode;if(l===null&&s.flags&4){l=O;var L=s.memoizedProps;switch(s.type){case"button":case"input":case"select":case"textarea":L.autoFocus&&l.focus();break;case"img":L.src&&(l.src=L.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(s.memoizedState===null){var Y=s.alternate;if(Y!==null){var se=Y.memoizedState;if(se!==null){var ce=se.dehydrated;ce!==null&&Du(ce)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}cn||s.flags&512&&am(s)}catch(ne){vt(s,s.return,ne)}}if(s===i){Ce=null;break}if(l=s.sibling,l!==null){l.return=s.return,Ce=l;break}Ce=s.return}}function K2(i){for(;Ce!==null;){var s=Ce;if(s===i){Ce=null;break}var l=s.sibling;if(l!==null){l.return=s.return,Ce=l;break}Ce=s.return}}function Q2(i){for(;Ce!==null;){var s=Ce;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{Ic(4,s)}catch(L){vt(s,l,L)}break;case 1:var d=s.stateNode;if(typeof d.componentDidMount=="function"){var g=s.return;try{d.componentDidMount()}catch(L){vt(s,g,L)}}var y=s.return;try{am(s)}catch(L){vt(s,y,L)}break;case 5:var x=s.return;try{am(s)}catch(L){vt(s,x,L)}}}catch(L){vt(s,s.return,L)}if(s===i){Ce=null;break}var O=s.sibling;if(O!==null){O.return=s.return,Ce=O;break}Ce=s.return}}var qF=Math.ceil,Pc=G.ReactCurrentDispatcher,fm=G.ReactCurrentOwner,Zn=G.ReactCurrentBatchConfig,et=0,Gt=null,Mt=null,Zt=0,Hn=0,wo=Ai(0),Ut=0,ia=null,cs=0,Rc=0,dm=0,sa=null,vn=null,hm=0,Co=1/0,ui=null,Lc=!1,pm=null,Pi=null,Dc=!1,Ri=null,Fc=0,oa=0,mm=null,Mc=-1,Bc=0;function pn(){return(et&6)!==0?Pt():Mc!==-1?Mc:Mc=Pt()}function Li(i){return(i.mode&1)===0?1:(et&2)!==0&&Zt!==0?Zt&-Zt:kF.transition!==null?(Bc===0&&(Bc=$b()),Bc):(i=ot,i!==0||(i=window.event,i=i===void 0?16:Jb(i.type)),i)}function Tr(i,s,l,d){if(50<oa)throw oa=0,mm=null,Error(n(185));Ou(i,l,d),((et&2)===0||i!==Gt)&&(i===Gt&&((et&2)===0&&(Rc|=l),Ut===4&&Di(i,Zt)),kn(i,d),l===1&&et===0&&(s.mode&1)===0&&(Co=Pt()+500,dc&&ki()))}function kn(i,s){var l=i.callbackNode;k8(i,s);var d=Wl(i,i===Gt?Zt:0);if(d===0)l!==null&&Hb(l),i.callbackNode=null,i.callbackPriority=0;else if(s=d&-d,i.callbackPriority!==s){if(l!=null&&Hb(l),s===1)i.tag===0?vF(J2.bind(null,i)):M_(J2.bind(null,i)),SF(function(){(et&6)===0&&ki()}),l=null;else{switch(Vb(d)){case 1:l=Gh;break;case 4:l=zb;break;case 16:l=$l;break;case 536870912:l=jb;break;default:l=$l}l=ox(l,X2.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function X2(i,s){if(Mc=-1,Bc=0,(et&6)!==0)throw Error(n(327));var l=i.callbackNode;if(Ao()&&i.callbackNode!==l)return null;var d=Wl(i,i===Gt?Zt:0);if(d===0)return null;if((d&30)!==0||(d&i.expiredLanes)!==0||s)s=Uc(i,d);else{s=d;var g=et;et|=2;var y=ex();(Gt!==i||Zt!==s)&&(ui=null,Co=Pt()+500,ds(i,s));do try{GF();break}catch(O){Z2(i,O)}while(!0);Rp(),Pc.current=y,et=g,Mt!==null?s=0:(Gt=null,Zt=0,s=Ut)}if(s!==0){if(s===2&&(g=Kh(i),g!==0&&(d=g,s=gm(i,g))),s===1)throw l=ia,ds(i,0),Di(i,d),kn(i,Pt()),l;if(s===6)Di(i,d);else{if(g=i.current.alternate,(d&30)===0&&!YF(g)&&(s=Uc(i,d),s===2&&(y=Kh(i),y!==0&&(d=y,s=gm(i,y))),s===1))throw l=ia,ds(i,0),Di(i,d),kn(i,Pt()),l;switch(i.finishedWork=g,i.finishedLanes=d,s){case 0:case 1:throw Error(n(345));case 2:hs(i,vn,ui);break;case 3:if(Di(i,d),(d&130023424)===d&&(s=hm+500-Pt(),10<s)){if(Wl(i,0)!==0)break;if(g=i.suspendedLanes,(g&d)!==d){pn(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=xp(hs.bind(null,i,vn,ui),s);break}hs(i,vn,ui);break;case 4:if(Di(i,d),(d&4194240)===d)break;for(s=i.eventTimes,g=-1;0<d;){var x=31-hr(d);y=1<<x,x=s[x],x>g&&(g=x),d&=~y}if(d=g,d=Pt()-d,d=(120>d?120:480>d?480:1080>d?1080:1920>d?1920:3e3>d?3e3:4320>d?4320:1960*qF(d/1960))-d,10<d){i.timeoutHandle=xp(hs.bind(null,i,vn,ui),d);break}hs(i,vn,ui);break;case 5:hs(i,vn,ui);break;default:throw Error(n(329))}}}return kn(i,Pt()),i.callbackNode===l?X2.bind(null,i):null}function gm(i,s){var l=sa;return i.current.memoizedState.isDehydrated&&(ds(i,s).flags|=256),i=Uc(i,s),i!==2&&(s=vn,vn=l,s!==null&&Em(s)),i}function Em(i){vn===null?vn=i:vn.push.apply(vn,i)}function YF(i){for(var s=i;;){if(s.flags&16384){var l=s.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var d=0;d<l.length;d++){var g=l[d],y=g.getSnapshot;g=g.value;try{if(!pr(y(),g))return!1}catch(x){return!1}}}if(l=s.child,s.subtreeFlags&16384&&l!==null)l.return=s,s=l;else{if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return!0;s=s.return}s.sibling.return=s.return,s=s.sibling}}return!0}function Di(i,s){for(s&=~dm,s&=~Rc,i.suspendedLanes|=s,i.pingedLanes&=~s,i=i.expirationTimes;0<s;){var l=31-hr(s),d=1<<l;i[l]=-1,s&=~d}}function J2(i){if((et&6)!==0)throw Error(n(327));Ao();var s=Wl(i,0);if((s&1)===0)return kn(i,Pt()),null;var l=Uc(i,s);if(i.tag!==0&&l===2){var d=Kh(i);d!==0&&(s=d,l=gm(i,d))}if(l===1)throw l=ia,ds(i,0),Di(i,s),kn(i,Pt()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,hs(i,vn,ui),kn(i,Pt()),null}function ym(i,s){var l=et;et|=1;try{return i(s)}finally{et=l,et===0&&(Co=Pt()+500,dc&&ki())}}function fs(i){Ri!==null&&Ri.tag===0&&(et&6)===0&&Ao();var s=et;et|=1;var l=Zn.transition,d=ot;try{if(Zn.transition=null,ot=1,i)return i()}finally{ot=d,Zn.transition=l,et=s,(et&6)===0&&ki()}}function Tm(){Hn=wo.current,mt(wo)}function ds(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,xF(l)),Mt!==null)for(l=Mt.return;l!==null;){var d=l;switch(kp(d),d.tag){case 1:d=d.type.childContextTypes,d!=null&&cc();break;case 3:_o(),mt(wn),mt(un),zp();break;case 5:Up(d);break;case 4:_o();break;case 13:mt(wt);break;case 19:mt(wt);break;case 10:Lp(d.type._context);break;case 22:case 23:Tm()}l=l.return}if(Gt=i,Mt=i=Fi(i.current,null),Zt=Hn=s,Ut=0,ia=null,dm=Rc=cs=0,vn=sa=null,us!==null){for(s=0;s<us.length;s++)if(l=us[s],d=l.interleaved,d!==null){l.interleaved=null;var g=d.next,y=l.pending;if(y!==null){var x=y.next;y.next=g,d.next=x}l.pending=d}us=null}return i}function Z2(i,s){do{var l=Mt;try{if(Rp(),xc.current=Ac,Sc){for(var d=Ct.memoizedState;d!==null;){var g=d.queue;g!==null&&(g.pending=null),d=d.next}Sc=!1}if(ls=0,Wt=Bt=Ct=null,Ju=!1,Zu=0,fm.current=null,l===null||l.return===null){Ut=1,ia=s,Mt=null;break}e:{var y=i,x=l.return,O=l,L=s;if(s=Zt,O.flags|=32768,L!==null&&typeof L=="object"&&typeof L.then=="function"){var Y=L,se=O,ce=se.tag;if((se.mode&1)===0&&(ce===0||ce===11||ce===15)){var ne=se.alternate;ne?(se.updateQueue=ne.updateQueue,se.memoizedState=ne.memoizedState,se.lanes=ne.lanes):(se.updateQueue=null,se.memoizedState=null)}var xe=w2(x);if(xe!==null){xe.flags&=-257,C2(xe,x,O,y,s),xe.mode&1&&S2(y,Y,s),s=xe,L=Y;var Ae=s.updateQueue;if(Ae===null){var ve=new Set;ve.add(L),s.updateQueue=ve}else Ae.add(L);break e}else{if((s&1)===0){S2(y,Y,s),bm();break e}L=Error(n(426))}}else if(bt&&O.mode&1){var Rt=w2(x);if(Rt!==null){(Rt.flags&65536)===0&&(Rt.flags|=256),C2(Rt,x,O,y,s),Ip(xo(L,O));break e}}y=L=xo(L,O),Ut!==4&&(Ut=2),sa===null?sa=[y]:sa.push(y),y=x;do{switch(y.tag){case 3:y.flags|=65536,s&=-s,y.lanes|=s;var z=_2(y,L,s);G_(y,z);break e;case 1:O=L;var F=y.type,$=y.stateNode;if((y.flags&128)===0&&(typeof F.getDerivedStateFromError=="function"||$!==null&&typeof $.componentDidCatch=="function"&&(Pi===null||!Pi.has($)))){y.flags|=65536,s&=-s,y.lanes|=s;var me=x2(y,O,s);G_(y,me);break e}}y=y.return}while(y!==null)}nx(l)}catch(Ne){s=Ne,Mt===l&&l!==null&&(Mt=l=l.return);continue}break}while(!0)}function ex(){var i=Pc.current;return Pc.current=Ac,i===null?Ac:i}function bm(){(Ut===0||Ut===3||Ut===2)&&(Ut=4),Gt===null||(cs&268435455)===0&&(Rc&268435455)===0||Di(Gt,Zt)}function Uc(i,s){var l=et;et|=2;var d=ex();(Gt!==i||Zt!==s)&&(ui=null,ds(i,s));do try{WF();break}catch(g){Z2(i,g)}while(!0);if(Rp(),et=l,Pc.current=d,Mt!==null)throw Error(n(261));return Gt=null,Zt=0,Ut}function WF(){for(;Mt!==null;)tx(Mt)}function GF(){for(;Mt!==null&&!T8();)tx(Mt)}function tx(i){var s=sx(i.alternate,i,Hn);i.memoizedProps=i.pendingProps,s===null?nx(i):Mt=s,fm.current=null}function nx(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=HF(l,s,Hn),l!==null){Mt=l;return}}else{if(l=zF(l,s),l!==null){l.flags&=32767,Mt=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{Ut=6,Mt=null;return}}if(s=s.sibling,s!==null){Mt=s;return}Mt=s=i}while(s!==null);Ut===0&&(Ut=5)}function hs(i,s,l){var d=ot,g=Zn.transition;try{Zn.transition=null,ot=1,KF(i,s,l,d)}finally{Zn.transition=g,ot=d}return null}function KF(i,s,l,d){do Ao();while(Ri!==null);if((et&6)!==0)throw Error(n(327));l=i.finishedWork;var g=i.finishedLanes;if(l===null)return null;if(i.finishedWork=null,i.finishedLanes=0,l===i.current)throw Error(n(177));i.callbackNode=null,i.callbackPriority=0;var y=l.lanes|l.childLanes;if(N8(i,y),i===Gt&&(Mt=Gt=null,Zt=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||Dc||(Dc=!0,ox($l,function(){return Ao(),null})),y=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||y){y=Zn.transition,Zn.transition=null;var x=ot;ot=1;var O=et;et|=4,fm.current=null,$F(i,l),Y2(l,i),mF(bp),Ql=!!Tp,bp=Tp=null,i.current=l,VF(l),b8(),et=O,ot=x,Zn.transition=y}else i.current=l;if(Dc&&(Dc=!1,Ri=i,Fc=g),y=i.pendingLanes,y===0&&(Pi=null),S8(l.stateNode),kn(i,Pt()),s!==null)for(d=i.onRecoverableError,l=0;l<s.length;l++)g=s[l],d(g.value,{componentStack:g.stack,digest:g.digest});if(Lc)throw Lc=!1,i=pm,pm=null,i;return(Fc&1)!==0&&i.tag!==0&&Ao(),y=i.pendingLanes,(y&1)!==0?i===mm?oa++:(oa=0,mm=i):oa=0,ki(),null}function Ao(){if(Ri!==null){var i=Vb(Fc),s=Zn.transition,l=ot;try{if(Zn.transition=null,ot=16>i?16:i,Ri===null)var d=!1;else{if(i=Ri,Ri=null,Fc=0,(et&6)!==0)throw Error(n(331));var g=et;for(et|=4,Ce=i.current;Ce!==null;){var y=Ce,x=y.child;if((Ce.flags&16)!==0){var O=y.deletions;if(O!==null){for(var L=0;L<O.length;L++){var Y=O[L];for(Ce=Y;Ce!==null;){var se=Ce;switch(se.tag){case 0:case 11:case 15:ra(8,se,y)}var ce=se.child;if(ce!==null)ce.return=se,Ce=ce;else for(;Ce!==null;){se=Ce;var ne=se.sibling,xe=se.return;if(z2(se),se===Y){Ce=null;break}if(ne!==null){ne.return=xe,Ce=ne;break}Ce=xe}}}var Ae=y.alternate;if(Ae!==null){var ve=Ae.child;if(ve!==null){Ae.child=null;do{var Rt=ve.sibling;ve.sibling=null,ve=Rt}while(ve!==null)}}Ce=y}}if((y.subtreeFlags&2064)!==0&&x!==null)x.return=y,Ce=x;else e:for(;Ce!==null;){if(y=Ce,(y.flags&2048)!==0)switch(y.tag){case 0:case 11:case 15:ra(9,y,y.return)}var z=y.sibling;if(z!==null){z.return=y.return,Ce=z;break e}Ce=y.return}}var F=i.current;for(Ce=F;Ce!==null;){x=Ce;var $=x.child;if((x.subtreeFlags&2064)!==0&&$!==null)$.return=x,Ce=$;else e:for(x=F;Ce!==null;){if(O=Ce,(O.flags&2048)!==0)try{switch(O.tag){case 0:case 11:case 15:Ic(9,O)}}catch(Ne){vt(O,O.return,Ne)}if(O===x){Ce=null;break e}var me=O.sibling;if(me!==null){me.return=O.return,Ce=me;break e}Ce=O.return}}if(et=g,ki(),Dr&&typeof Dr.onPostCommitFiberRoot=="function")try{Dr.onPostCommitFiberRoot(Vl,i)}catch(Ne){}d=!0}return d}finally{ot=l,Zn.transition=s}}return!1}function rx(i,s,l){s=xo(l,s),s=_2(i,s,1),i=Oi(i,s,1),s=pn(),i!==null&&(Ou(i,1,s),kn(i,s))}function vt(i,s,l){if(i.tag===3)rx(i,i,l);else for(;s!==null;){if(s.tag===3){rx(s,i,l);break}else if(s.tag===1){var d=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof d.componentDidCatch=="function"&&(Pi===null||!Pi.has(d))){i=xo(l,i),i=x2(s,i,1),s=Oi(s,i,1),i=pn(),s!==null&&(Ou(s,1,i),kn(s,i));break}}s=s.return}}function QF(i,s,l){var d=i.pingCache;d!==null&&d.delete(s),s=pn(),i.pingedLanes|=i.suspendedLanes&l,Gt===i&&(Zt&l)===l&&(Ut===4||Ut===3&&(Zt&130023424)===Zt&&500>Pt()-hm?ds(i,0):dm|=l),kn(i,s)}function ix(i,s){s===0&&((i.mode&1)===0?s=1:(s=Yl,Yl<<=1,(Yl&130023424)===0&&(Yl=4194304)));var l=pn();i=ii(i,s),i!==null&&(Ou(i,s,l),kn(i,l))}function XF(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),ix(i,l)}function JF(i,s){var l=0;switch(i.tag){case 13:var d=i.stateNode,g=i.memoizedState;g!==null&&(l=g.retryLane);break;case 19:d=i.stateNode;break;default:throw Error(n(314))}d!==null&&d.delete(s),ix(i,l)}var sx;sx=function(i,s,l){if(i!==null)if(i.memoizedProps!==s.pendingProps||wn.current)An=!0;else{if((i.lanes&l)===0&&(s.flags&128)===0)return An=!1,UF(i,s,l);An=(i.flags&131072)!==0}else An=!1,bt&&(s.flags&1048576)!==0&&B_(s,pc,s.index);switch(s.lanes=0,s.tag){case 2:var d=s.type;Nc(i,s),i=s.pendingProps;var g=po(s,un.current);bo(s,l),g=Vp(null,s,d,i,g,l);var y=qp();return s.flags|=1,typeof g=="object"&&g!==null&&typeof g.render=="function"&&g.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,Cn(d)?(y=!0,fc(s)):y=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,Mp(s),g.updater=vc,s.stateNode=g,g._reactInternals=s,Xp(s,d,i,l),s=tm(null,s,d,!0,y,l)):(s.tag=0,bt&&y&&vp(s),hn(null,s,g,l),s=s.child),s;case 16:d=s.elementType;e:{switch(Nc(i,s),i=s.pendingProps,g=d._init,d=g(d._payload),s.type=d,g=s.tag=eM(d),i=gr(d,i),g){case 0:s=em(null,s,d,i,l);break e;case 1:s=I2(null,s,d,i,l);break e;case 11:s=A2(null,s,d,i,l);break e;case 14:s=v2(null,s,d,gr(d.type,i),l);break e}throw Error(n(306,d,""))}return s;case 0:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),em(i,s,d,g,l);case 1:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),I2(i,s,d,g,l);case 3:e:{if(P2(s),i===null)throw Error(n(387));d=s.pendingProps,y=s.memoizedState,g=y.element,W_(i,s),bc(s,d,null,l);var x=s.memoizedState;if(d=x.element,y.isDehydrated)if(y={element:d,isDehydrated:!1,cache:x.cache,pendingSuspenseBoundaries:x.pendingSuspenseBoundaries,transitions:x.transitions},s.updateQueue.baseState=y,s.memoizedState=y,s.flags&256){g=xo(Error(n(423)),s),s=R2(i,s,d,l,g);break e}else if(d!==g){g=xo(Error(n(424)),s),s=R2(i,s,d,l,g);break e}else for(Un=Ci(s.stateNode.containerInfo.firstChild),Bn=s,bt=!0,mr=null,l=q_(s,null,d,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(Eo(),d===g){s=oi(i,s,l);break e}hn(i,s,d,l)}s=s.child}return s;case 5:return Q_(s),i===null&&Op(s),d=s.type,g=s.pendingProps,y=i!==null?i.memoizedProps:null,x=g.children,_p(d,g)?x=null:y!==null&&_p(d,y)&&(s.flags|=32),O2(i,s),hn(i,s,x,l),s.child;case 6:return i===null&&Op(s),null;case 13:return L2(i,s,l);case 4:return Bp(s,s.stateNode.containerInfo),d=s.pendingProps,i===null?s.child=yo(s,null,d,l):hn(i,s,d,l),s.child;case 11:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),A2(i,s,d,g,l);case 7:return hn(i,s,s.pendingProps,l),s.child;case 8:return hn(i,s,s.pendingProps.children,l),s.child;case 12:return hn(i,s,s.pendingProps.children,l),s.child;case 10:e:{if(d=s.type._context,g=s.pendingProps,y=s.memoizedProps,x=g.value,ht(Ec,d._currentValue),d._currentValue=x,y!==null)if(pr(y.value,x)){if(y.children===g.children&&!wn.current){s=oi(i,s,l);break e}}else for(y=s.child,y!==null&&(y.return=s);y!==null;){var O=y.dependencies;if(O!==null){x=y.child;for(var L=O.firstContext;L!==null;){if(L.context===d){if(y.tag===1){L=si(-1,l&-l),L.tag=2;var Y=y.updateQueue;if(Y!==null){Y=Y.shared;var se=Y.pending;se===null?L.next=L:(L.next=se.next,se.next=L),Y.pending=L}}y.lanes|=l,L=y.alternate,L!==null&&(L.lanes|=l),Dp(y.return,l,s),O.lanes|=l;break}L=L.next}}else if(y.tag===10)x=y.type===s.type?null:y.child;else if(y.tag===18){if(x=y.return,x===null)throw Error(n(341));x.lanes|=l,O=x.alternate,O!==null&&(O.lanes|=l),Dp(x,l,s),x=y.sibling}else x=y.child;if(x!==null)x.return=y;else for(x=y;x!==null;){if(x===s){x=null;break}if(y=x.sibling,y!==null){y.return=x.return,x=y;break}x=x.return}y=x}hn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,d=s.pendingProps.children,bo(s,l),g=Xn(g),d=d(g),s.flags|=1,hn(i,s,d,l),s.child;case 14:return d=s.type,g=gr(d,s.pendingProps),g=gr(d.type,g),v2(i,s,d,g,l);case 15:return k2(i,s,s.type,s.pendingProps,l);case 17:return d=s.type,g=s.pendingProps,g=s.elementType===d?g:gr(d,g),Nc(i,s),s.tag=1,Cn(d)?(i=!0,fc(s)):i=!1,bo(s,l),T2(s,d,g),Xp(s,d,g,l),tm(null,s,d,!0,i,l);case 19:return F2(i,s,l);case 22:return N2(i,s,l)}throw Error(n(156,s.tag))};function ox(i,s){return Ub(i,s)}function ZF(i,s,l,d){this.tag=i,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=s,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=d,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function er(i,s,l,d){return new ZF(i,s,l,d)}function _m(i){return i=i.prototype,!(!i||!i.isReactComponent)}function eM(i){if(typeof i=="function")return _m(i)?1:0;if(i!=null){if(i=i.$$typeof,i===de)return 11;if(i===ge)return 14}return 2}function Fi(i,s){var l=i.alternate;return l===null?(l=er(i.tag,s,i.key,i.mode),l.elementType=i.elementType,l.type=i.type,l.stateNode=i.stateNode,l.alternate=i,i.alternate=l):(l.pendingProps=s,l.type=i.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=i.flags&14680064,l.childLanes=i.childLanes,l.lanes=i.lanes,l.child=i.child,l.memoizedProps=i.memoizedProps,l.memoizedState=i.memoizedState,l.updateQueue=i.updateQueue,s=i.dependencies,l.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext},l.sibling=i.sibling,l.index=i.index,l.ref=i.ref,l}function Hc(i,s,l,d,g,y){var x=2;if(d=i,typeof i=="function")_m(i)&&(x=1);else if(typeof i=="string")x=5;else e:switch(i){case te:return ps(l.children,g,y,s);case Te:x=8,g|=8;break;case Se:return i=er(12,l,s,g|2),i.elementType=Se,i.lanes=y,i;case ue:return i=er(13,l,s,g),i.elementType=ue,i.lanes=y,i;case ie:return i=er(19,l,s,g),i.elementType=ie,i.lanes=y,i;case ae:return zc(l,g,y,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case H:x=10;break e;case fe:x=9;break e;case de:x=11;break e;case ge:x=14;break e;case we:x=16,d=null;break e}throw Error(n(130,i==null?i:typeof i,""))}return s=er(x,l,s,g),s.elementType=i,s.type=d,s.lanes=y,s}function ps(i,s,l,d){return i=er(7,i,d,s),i.lanes=l,i}function zc(i,s,l,d){return i=er(22,i,d,s),i.elementType=ae,i.lanes=l,i.stateNode={isHidden:!1},i}function xm(i,s,l){return i=er(6,i,null,s),i.lanes=l,i}function Sm(i,s,l){return s=er(4,i.children!==null?i.children:[],i.key,s),s.lanes=l,s.stateNode={containerInfo:i.containerInfo,pendingChildren:null,implementation:i.implementation},s}function tM(i,s,l,d,g){this.tag=s,this.containerInfo=i,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Qh(0),this.expirationTimes=Qh(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Qh(0),this.identifierPrefix=d,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function wm(i,s,l,d,g,y,x,O,L){return i=new tM(i,s,l,O,L),s===1?(s=1,y===!0&&(s|=8)):s=0,y=er(3,null,null,s),i.current=y,y.stateNode=i,y.memoizedState={element:d,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},Mp(y),i}function nM(i,s,l){var d=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:B,key:d==null?null:""+d,children:i,containerInfo:s,implementation:l}}function ux(i){if(!i)return vi;i=i._reactInternals;e:{if(ns(i)!==i||i.tag!==1)throw Error(n(170));var s=i;do{switch(s.tag){case 3:s=s.stateNode.context;break e;case 1:if(Cn(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break e}}s=s.return}while(s!==null);throw Error(n(171))}if(i.tag===1){var l=i.type;if(Cn(l))return D_(i,l,s)}return s}function ax(i,s,l,d,g,y,x,O,L){return i=wm(l,d,!0,i,g,y,x,O,L),i.context=ux(null),l=i.current,d=pn(),g=Li(l),y=si(d,g),y.callback=s!=null?s:null,Oi(l,y,g),i.current.lanes=g,Ou(i,g,d),kn(i,d),i}function jc(i,s,l,d){var g=s.current,y=pn(),x=Li(g);return l=ux(l),s.context===null?s.context=l:s.pendingContext=l,s=si(y,x),s.payload={element:i},d=d===void 0?null:d,d!==null&&(s.callback=d),i=Oi(g,s,x),i!==null&&(Tr(i,g,x,y),Tc(i,g,x)),x}function $c(i){if(i=i.current,!i.child)return null;switch(i.child.tag){case 5:return i.child.stateNode;default:return i.child.stateNode}}function lx(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function Cm(i,s){lx(i,s),(i=i.alternate)&&lx(i,s)}function rM(){return null}var cx=typeof reportError=="function"?reportError:function(i){console.error(i)};function Am(i){this._internalRoot=i}Vc.prototype.render=Am.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));jc(i,s,null,null)},Vc.prototype.unmount=Am.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;fs(function(){jc(null,i,null,null)}),s[ei]=null}};function Vc(i){this._internalRoot=i}Vc.prototype.unstable_scheduleHydration=function(i){if(i){var s=Wb();i={blockedOn:null,target:i,priority:s};for(var l=0;l<xi.length&&s!==0&&s<xi[l].priority;l++);xi.splice(l,0,i),l===0&&Qb(i)}};function vm(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function qc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function fx(){}function iM(i,s,l,d,g){if(g){if(typeof d=="function"){var y=d;d=function(){var Y=$c(x);y.call(Y)}}var x=ax(s,d,i,0,null,!1,!1,"",fx);return i._reactRootContainer=x,i[ei]=x.current,Vu(i.nodeType===8?i.parentNode:i),fs(),x}for(;g=i.lastChild;)i.removeChild(g);if(typeof d=="function"){var O=d;d=function(){var Y=$c(L);O.call(Y)}}var L=wm(i,0,!1,null,null,!1,!1,"",fx);return i._reactRootContainer=L,i[ei]=L.current,Vu(i.nodeType===8?i.parentNode:i),fs(function(){jc(s,L,l,d)}),L}function Yc(i,s,l,d,g){var y=l._reactRootContainer;if(y){var x=y;if(typeof g=="function"){var O=g;g=function(){var L=$c(x);O.call(L)}}jc(s,x,i,g)}else x=iM(l,s,i,g,d);return $c(x)}qb=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=Nu(s.pendingLanes);l!==0&&(Xh(s,l|1),kn(s,Pt()),(et&6)===0&&(Co=Pt()+500,ki()))}break;case 13:fs(function(){var d=ii(i,1);if(d!==null){var g=pn();Tr(d,i,1,g)}}),Cm(i,1)}},Jh=function(i){if(i.tag===13){var s=ii(i,134217728);if(s!==null){var l=pn();Tr(s,i,134217728,l)}Cm(i,134217728)}},Yb=function(i){if(i.tag===13){var s=Li(i),l=ii(i,s);if(l!==null){var d=pn();Tr(l,i,s,d)}Cm(i,s)}},Wb=function(){return ot},Gb=function(i,s){var l=ot;try{return ot=i,s()}finally{ot=l}},Vh=function(i,s,l){switch(s){case"input":if(qt(i,l),s=l.name,l.type==="radio"&&s!=null){for(l=i;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll("input[name="+JSON.stringify(""+s)+'][type="radio"]'),s=0;s<l.length;s++){var d=l[s];if(d!==i&&d.form===i.form){var g=lc(d);if(!g)throw Error(n(90));He(d),qt(d,g)}}}break;case"textarea":Ul(i,l);break;case"select":s=l.value,s!=null&&Yt(i,!!l.multiple,s,!1)}},Pb=ym,Rb=fs;var sM={usingClientEntryPoint:!1,Events:[Wu,fo,lc,Ob,Ib,ym]},ua={findFiberByHostInstance:rs,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},oM={bundleType:ua.bundleType,version:ua.version,rendererPackageName:ua.rendererPackageName,rendererConfig:ua.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:G.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=Mb(i),i===null?null:i.stateNode},findFiberByHostInstance:ua.findFiberByHostInstance||rM,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!="undefined"){var Wc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Wc.isDisabled&&Wc.supportsFiber)try{Vl=Wc.inject(oM),Dr=Wc}catch(i){}}return bn.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=sM,bn.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!vm(s))throw Error(n(200));return nM(i,s,null,l)},bn.createRoot=function(i,s){if(!vm(i))throw Error(n(299));var l=!1,d="",g=cx;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(d=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=wm(i,1,!1,null,null,l,!1,d,g),i[ei]=s.current,Vu(i.nodeType===8?i.parentNode:i),new Am(s)},bn.findDOMNode=function(i){if(i==null)return null;if(i.nodeType===1)return i;var s=i._reactInternals;if(s===void 0)throw typeof i.render=="function"?Error(n(188)):(i=Object.keys(i).join(","),Error(n(268,i)));return i=Mb(s),i=i===null?null:i.stateNode,i},bn.flushSync=function(i){return fs(i)},bn.hydrate=function(i,s,l){if(!qc(s))throw Error(n(200));return Yc(null,i,s,!0,l)},bn.hydrateRoot=function(i,s,l){if(!vm(i))throw Error(n(405));var d=l!=null&&l.hydratedSources||null,g=!1,y="",x=cx;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(y=l.identifierPrefix),l.onRecoverableError!==void 0&&(x=l.onRecoverableError)),s=ax(s,null,i,1,l!=null?l:null,g,!1,y,x),i[ei]=s.current,Vu(i),d)for(i=0;i<d.length;i++)l=d[i],g=l._getVersion,g=g(l._source),s.mutableSourceEagerHydrationData==null?s.mutableSourceEagerHydrationData=[l,g]:s.mutableSourceEagerHydrationData.push(l,g);return new Vc(s)},bn.render=function(i,s,l){if(!qc(s))throw Error(n(200));return Yc(null,i,s,!1,l)},bn.unmountComponentAtNode=function(i){if(!qc(i))throw Error(n(40));return i._reactRootContainer?(fs(function(){Yc(null,null,i,!1,function(){i._reactRootContainer=null,i[ei]=null})}),!0):!1},bn.unstable_batchedUpdates=ym,bn.unstable_renderSubtreeIntoContainer=function(i,s,l,d){if(!qc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Yc(i,s,l,!1,d)},bn.version="18.3.1-next-f1338f8080-20240426",bn}var Jg;function Zg(){if(Jg)return rd.exports;Jg=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__=="undefined"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),rd.exports=Bv(),rd.exports}var Ga=Zg();function Uv(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var od=()=>e=>Array.from(new Set(e)),e1=typeof globalThis.document!="undefined"?W.useLayoutEffect:W.useEffect;function Ka(e){var E,b;const t=(E=e().value)!=null?E:e().defaultValue,n=(b=e().isEqual)!=null?b:Object.is,[r]=W.useState(t),[o,u]=W.useState(r),a=e().value!==void 0,c=W.useRef(o);c.current=a?e().value:o;const f=W.useRef(c.current);e1(()=>{f.current=c.current},[o,e().value]);const h=T=>{var C,k;const _=f.current,S=As(T)?T(_):T;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:S,prev:_}),a||u(S),n(S,_)||(k=(C=e()).onChange)==null||k.call(C,S,_)};function m(){return a?e().value:o}return{initial:r,ref:c,get:m,set(T){(e().sync?Ga.flushSync:FA)(()=>h(T))},invoke(T,_){var S,C;(C=(S=e()).onChange)==null||C.call(S,T,_)},hash(T){var _,S,C;return(C=(S=(_=e()).hash)==null?void 0:S.call(_,T))!=null?C:String(T)}}}Ka.cleanup=e=>{W.useEffect(()=>e,[])},Ka.ref=e=>{const t=W.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function Hv(e){const t=W.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var zv=(e,t)=>{const n=W.useRef(!1),r=W.useRef(!1);W.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),W.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function ud(e,t={}){var fe,de,ue,ie,ge,we;const n=W.useMemo(()=>{const{id:ae,ids:V,getRootNode:ee}=t;return Dv({id:ae,ids:V,getRootNode:ee})},[t]),r=(...ae)=>{e.debug&&console.log(...ae)},o=(de=(fe=e.props)==null?void 0:fe.call(e,{props:Yf(t),scope:n}))!=null?de:t,u=jv(o),a=(ue=e.context)==null?void 0:ue.call(e,{prop:u,bindable:Ka,scope:n,flush:n1,getContext(){return f},getComputed(){return q},getRefs(){return S},getEvent(){return T()}}),c=t1(a),f={get(ae){var V;return(V=c.current)==null?void 0:V[ae].ref.current},set(ae,V){var ee;(ee=c.current)==null||ee[ae].set(V)},initial(ae){var V;return(V=c.current)==null?void 0:V[ae].initial},hash(ae){var ee,w;const V=(ee=c.current)==null?void 0:ee[ae].get();return(w=c.current)==null?void 0:w[ae].hash(V)}},h=W.useRef(new Map),m=W.useRef(null),E=W.useRef(null),b=W.useRef({type:""}),T=()=>ye(U({},b.current),{current(){return b.current},previous(){return E.current}}),_=()=>ye(U({},B),{matches(...ae){return ae.includes(B.ref.current)},hasTag(ae){var V,ee;return!!((ee=(V=e.states[B.ref.current])==null?void 0:V.tags)!=null&&ee.includes(ae))}}),S=Hv((ge=(ie=e.refs)==null?void 0:ie.call(e,{prop:u,context:f}))!=null?ge:{}),C=()=>({state:_(),context:f,event:T(),prop:u,send:H,action:k,guard:M,track:zv,refs:S,computed:q,flush:n1,scope:n,choose:G}),k=ae=>{const V=As(ae)?ae(C()):ae;if(!V)return;const ee=V.map(w=>{var Q,N;const R=(N=(Q=e.implementations)==null?void 0:Q.actions)==null?void 0:N[w];return R||Wf(`[zag-js] No implementation found for action "${JSON.stringify(w)}"`),R});for(const w of ee)w==null||w(C())},M=ae=>{var V,ee;return As(ae)?ae(C()):(ee=(V=e.implementations)==null?void 0:V.guards)==null?void 0:ee[ae](C())},D=ae=>{const V=As(ae)?ae(C()):ae;if(!V)return;const ee=V.map(R=>{var N,_e;const Q=(_e=(N=e.implementations)==null?void 0:N.effects)==null?void 0:_e[R];return Q||Wf(`[zag-js] No implementation found for effect "${JSON.stringify(R)}"`),Q}),w=[];for(const R of ee){const Q=R==null?void 0:R(C());Q&&w.push(Q)}return()=>w.forEach(R=>R==null?void 0:R())},G=ae=>AA(ae).find(V=>{let ee=!V.guard;return za(V.guard)?ee=!!M(V.guard):As(V.guard)&&(ee=V.guard(C())),ee}),q=ae=>{BA(e.computed,()=>"[zag-js] No computed object found on machine");const V=e.computed[ae];return V({context:f,event:T(),prop:u,refs:S,scope:n,computed:q})},B=Ka(()=>({defaultValue:e.initialState({prop:u}),onChange(ae,V){var w,R,Q,N;if(V){const _e=h.current.get(V);_e==null||_e(),h.current.delete(V)}V&&k((w=e.states[V])==null?void 0:w.exit),k((R=m.current)==null?void 0:R.actions);const ee=D((Q=e.states[ae])==null?void 0:Q.effects);if(ee&&h.current.set(ae,ee),V===nd){k(e.entry);const _e=D(e.effects);_e&&h.current.set(nd,_e)}k((N=e.states[ae])==null?void 0:N.entry)}})),te=W.useRef(void 0),Te=W.useRef(Ns.NotStarted);e1(()=>{queueMicrotask(()=>{var R;const ee=Te.current===Ns.Started;Te.current=Ns.Started,r(ee?"rehydrating...":"initializing...");const w=(R=te.current)!=null?R:B.initial;B.invoke(w,ee?B.get():nd)});const ae=h.current,V=B.ref.current;return()=>{r("unmounting..."),te.current=V,Te.current=Ns.Stopped,ae.forEach(ee=>ee==null?void 0:ee()),h.current=new Map,m.current=null,queueMicrotask(()=>{k(e.exit)})}},[]);const Se=()=>"ref"in B?B.ref.current:B.get(),H=ae=>{queueMicrotask(()=>{var N,_e,Me,Ie,Ye;if(Te.current!==Ns.Started)return;E.current=b.current,b.current=ae;let V=Se();const ee=(Me=(N=e.states[V].on)==null?void 0:N[ae.type])!=null?Me:(_e=e.on)==null?void 0:_e[ae.type],w=G(ee);if(!w)return;m.current=w;const R=(Ie=w.target)!=null?Ie:V;r("transition",ae.type,w.target||V,`(${w.actions})`);const Q=R!==V;Q?Ga.flushSync(()=>B.set(R)):w.reenter&&!Q?B.invoke(V,V):k((Ye=w.actions)!=null?Ye:[])})};return(we=e.watch)==null||we.call(e,C()),{state:_(),send:H,context:f,prop:u,scope:n,refs:S,computed:q,event:T(),getStatus:()=>Te.current}}function t1(e){const t=W.useRef(e);return t.current=e,t}function jv(e){const t=t1(e);return function(r){return t.current[r]}}function n1(e){queueMicrotask(()=>{Ga.flushSync(()=>e())})}var r1=Uv(e=>e);function Qa(...e){return t=>{const n=[];for(const r of e)if(typeof r=="function"){const o=r(t);typeof o=="function"&&n.push(o)}else r&&(r.current=t);if(n.length)return()=>{for(const r of n)r()}}}function $v(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const ad=e=>{const t=W.memo(W.forwardRef((n,r)=>{const h=n,{asChild:o,children:u}=h,a=en(h,["asChild","children"]);if(!o)return W.createElement(e,ye(U({},a),{ref:r}),u);if(!W.isValidElement(u))return null;const c=W.Children.only(u),f=$v(c);return W.cloneElement(c,ye(U({},ar(a,c.props)),{ref:r?Qa(r,f):f}))}));return t.displayName=e.displayName||e.name,t},ci=(()=>{const e=new Map;return new Proxy(ad,{apply(t,n,r){return ad(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,ad(r)),e.get(r)}})})();function Vv(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Os(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:u,defaultValue:a}=e,c=W.createContext(a);c.displayName=t;function f(){var m;const h=W.useContext(c);if(!h&&n){const E=new Error(u!=null?u:Vv(r,o));throw E.name="ContextError",(m=Error.captureStackTrace)==null||m.call(Error,E,f),E}return h}return[c.Provider,f,c]}const[qv,ld]=Os({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[i1,Yo]=Os({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),s1=W.forwardRef((e,t)=>{const n=ld(),r=Yo(),o=ar(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:I.jsx(ci.div,ye(U({},o),{ref:Qa(r.ref,t)}))});s1.displayName="PopoverContent";const o1=W.forwardRef((e,t)=>{const n=ld(),r=Yo(),o=ar(n.getPositionerProps(),e);return r.unmounted?null:I.jsx(ci.div,ye(U({},o),{ref:t}))});o1.displayName="PopoverPositioner";const u1=()=>(e,t)=>t.reduce((n,r)=>{const[o,u]=n,a=r;return u[a]!==void 0&&(o[a]=u[a]),delete u[a],[o,u]},[{},U({},e)]),a1=e=>u1()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function Yv(e,t){const{state:n,send:r,context:o}=e,u=n.matches("mounted","unmountSuspended");return{skip:!o.get("initial"),present:u,setNode(a){a&&r({type:"NODE.SET",node:a})},unmount(){r({type:"UNMOUNT"})}}}var Wv={props({props:e}){return ye(U({},e),{present:!!e.present})},initialState({prop:e}){return e("present")?"mounted":"unmounted"},refs(){return{node:null,styles:null}},context({bindable:e}){return{unmountAnimationName:e(()=>({defaultValue:null})),prevAnimationName:e(()=>({defaultValue:null})),present:e(()=>({defaultValue:!1})),initial:e(()=>({sync:!0,defaultValue:!1}))}},exit:["clearInitial","cleanupNode"],watch({track:e,prop:t,send:n}){e([()=>t("present")],()=>{n({type:"PRESENCE.CHANGED"})})},on:{"NODE.SET":{actions:["setupNode"]},"PRESENCE.CHANGED":{actions:["setInitial","syncPresence"]}},states:{mounted:{on:{UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]},"UNMOUNT.SUSPEND":{target:"unmountSuspended"}}},unmountSuspended:{effects:["trackAnimationEvents"],on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]},UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]}}},unmounted:{on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]}}}},implementations:{actions:{setInitial:({context:e})=>{e.get("initial")||queueMicrotask(()=>{e.set("initial",!0)})},clearInitial:({context:e})=>{e.set("initial",!1)},invokeOnExitComplete:({prop:e})=>{var t;(t=e("onExitComplete"))==null||t()},setupNode:({refs:e,event:t})=>{e.get("node")!==t.node&&(e.set("node",t.node),e.set("styles",qa(t.node)))},cleanupNode:({refs:e})=>{e.set("node",null),e.set("styles",null)},syncPresence:({context:e,refs:t,send:n,prop:r})=>{const o=r("present");if(o)return n({type:"MOUNT",src:"presence.changed"});const u=t.get("node");if(!o&&(u==null?void 0:u.ownerDocument.visibilityState)==="hidden")return n({type:"UNMOUNT",src:"visibilitychange"});Tn(()=>{var c,f;const a=Xa(t.get("styles"));e.set("unmountAnimationName",a),a==="none"||a===e.get("prevAnimationName")||((c=t.get("styles"))==null?void 0:c.display)==="none"||((f=t.get("styles"))==null?void 0:f.animationDuration)==="0s"?n({type:"UNMOUNT",src:"presence.changed"}):n({type:"UNMOUNT.SUSPEND"})})},setPrevAnimationName:({context:e,refs:t})=>{Tn(()=>{e.set("prevAnimationName",Xa(t.get("styles")))})},clearPrevAnimationName:({context:e})=>{e.set("prevAnimationName",null)}},effects:{trackAnimationEvents:({context:e,refs:t,send:n,prop:r})=>{const o=t.get("node");if(!o)return;const u=f=>{var m,E,b;((b=(E=(m=f.composedPath)==null?void 0:m.call(f))==null?void 0:E[0])!=null?b:f.target)===o&&e.set("prevAnimationName",Xa(t.get("styles")))},a=f=>{const h=Xa(t.get("styles"));Yr(f)===o&&h===e.get("unmountAnimationName")&&!r("present")&&n({type:"UNMOUNT",src:"animationend"})};o.addEventListener("animationstart",u),o.addEventListener("animationcancel",a),o.addEventListener("animationend",a);const c=Wa(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",u),o.removeEventListener("animationcancel",a),o.removeEventListener("animationend",a),Sv(()=>c())}}}}};function Xa(e){return(e==null?void 0:e.animationName)||"none"}od()(["onExitComplete","present","immediate"]);function Gv(e,t={}){const{sync:n=!1}=t,r=Kv(e);return W.useCallback((...o)=>{var u;return n?queueMicrotask(()=>{var a;return(a=r.current)==null?void 0:a.call(r,...o)}):(u=r.current)==null?void 0:u.call(r,...o)},[n,r])}function Kv(e){const t=W.useRef(e);return t.current=e,t}const cd=(e={})=>{const b=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=b,u=en(b,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),a=W.useRef(!1),c=ye(U({},u),{present:r,onExitComplete:Gv(e.onExitComplete)}),f=ud(Wv,c),h=Yv(f);h.present&&(a.current=!0);const m=!h.present&&!a.current&&t||n&&!h.present&&a.current,E=()=>({"data-state":h.skip&&o?void 0:r?"open":"closed",hidden:!h.present});return{ref:h.setNode,getPresenceProps:E,present:h.present,unmounted:m}};var Is=(e,t=[])=>({parts:(...n)=>{if(Qv(t))return Is(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>Is(e,[...t,...n]),omit:(...n)=>Is(e,t.filter(r=>!n.includes(r))),rename:n=>Is(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Ps(e)}"][data-part="${Ps(r)}"]`,`& [data-scope="${Ps(e)}"][data-part="${Ps(r)}"]`].join(", "),attrs:{"data-scope":Ps(e),"data-part":Ps(r)}}}),{})}),Ps=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),Qv=e=>e.length===0;const Xv=["top","right","bottom","left"],fi=Math.min,In=Math.max,Ja=Math.round,Za=Math.floor,wr=e=>({x:e,y:e}),Jv={left:"right",right:"left",bottom:"top",top:"bottom"},Zv={start:"end",end:"start"};function fd(e,t,n){return In(e,fi(t,n))}function Gr(e,t){return typeof e=="function"?e(t):e}function Kr(e){return e.split("-")[0]}function Rs(e){return e.split("-")[1]}function dd(e){return e==="x"?"y":"x"}function hd(e){return e==="y"?"height":"width"}const ek=new Set(["top","bottom"]);function Cr(e){return ek.has(Kr(e))?"y":"x"}function pd(e){return dd(Cr(e))}function tk(e,t,n){n===void 0&&(n=!1);const r=Rs(e),o=pd(e),u=hd(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[u]>t.floating[u]&&(a=el(a)),[a,el(a)]}function nk(e){const t=el(e);return[md(e),t,md(t)]}function md(e){return e.replace(/start|end/g,t=>Zv[t])}const l1=["left","right"],c1=["right","left"],rk=["top","bottom"],ik=["bottom","top"];function sk(e,t,n){switch(e){case"top":case"bottom":return n?t?c1:l1:t?l1:c1;case"left":case"right":return t?rk:ik;default:return[]}}function ok(e,t,n,r){const o=Rs(e);let u=sk(Kr(e),n==="start",r);return o&&(u=u.map(a=>a+"-"+o),t&&(u=u.concat(u.map(md)))),u}function el(e){return e.replace(/left|right|bottom|top/g,t=>Jv[t])}function uk(e){return U({top:0,right:0,bottom:0,left:0},e)}function f1(e){return typeof e!="number"?uk(e):{top:e,right:e,bottom:e,left:e}}function tl(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function d1(e,t,n){let{reference:r,floating:o}=e;const u=Cr(t),a=pd(t),c=hd(a),f=Kr(t),h=u==="y",m=r.x+r.width/2-o.width/2,E=r.y+r.height/2-o.height/2,b=r[c]/2-o[c]/2;let T;switch(f){case"top":T={x:m,y:r.y-o.height};break;case"bottom":T={x:m,y:r.y+r.height};break;case"right":T={x:r.x+r.width,y:E};break;case"left":T={x:r.x-o.width,y:E};break;default:T={x:r.x,y:r.y}}switch(Rs(t)){case"start":T[a]-=b*(n&&h?-1:1);break;case"end":T[a]+=b*(n&&h?-1:1);break}return T}const ak=(e,t,n)=>st(null,null,function*(){const{placement:r="bottom",strategy:o="absolute",middleware:u=[],platform:a}=n,c=u.filter(Boolean),f=yield a.isRTL==null?void 0:a.isRTL(t);let h=yield a.getElementRects({reference:e,floating:t,strategy:o}),{x:m,y:E}=d1(h,r,f),b=r,T={},_=0;for(let S=0;S<c.length;S++){const{name:C,fn:k}=c[S],{x:M,y:D,data:G,reset:q}=yield k({x:m,y:E,initialPlacement:r,placement:b,strategy:o,middlewareData:T,rects:h,platform:a,elements:{reference:e,floating:t}});m=M!=null?M:m,E=D!=null?D:E,T=ye(U({},T),{[C]:U(U({},T[C]),G)}),q&&_<=50&&(_++,typeof q=="object"&&(q.placement&&(b=q.placement),q.rects&&(h=q.rects===!0?yield a.getElementRects({reference:e,floating:t,strategy:o}):q.rects),{x:m,y:E}=d1(h,b,f)),S=-1)}return{x:m,y:E,placement:b,strategy:o,middlewareData:T}});function Wo(e,t){return st(this,null,function*(){var n;t===void 0&&(t={});const{x:r,y:o,platform:u,rects:a,elements:c,strategy:f}=e,{boundary:h="clippingAncestors",rootBoundary:m="viewport",elementContext:E="floating",altBoundary:b=!1,padding:T=0}=Gr(t,e),_=f1(T),C=c[b?E==="floating"?"reference":"floating":E],k=tl(yield u.getClippingRect({element:(n=yield u.isElement==null?void 0:u.isElement(C))==null||n?C:C.contextElement||(yield u.getDocumentElement==null?void 0:u.getDocumentElement(c.floating)),boundary:h,rootBoundary:m,strategy:f})),M=E==="floating"?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,D=yield u.getOffsetParent==null?void 0:u.getOffsetParent(c.floating),G=(yield u.isElement==null?void 0:u.isElement(D))?(yield u.getScale==null?void 0:u.getScale(D))||{x:1,y:1}:{x:1,y:1},q=tl(u.convertOffsetParentRelativeRectToViewportRelativeRect?yield u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:M,offsetParent:D,strategy:f}):M);return{top:(k.top-q.top+_.top)/G.y,bottom:(q.bottom-k.bottom+_.bottom)/G.y,left:(k.left-q.left+_.left)/G.x,right:(q.right-k.right+_.right)/G.x}})}const lk=e=>({name:"arrow",options:e,fn(n){return st(this,null,function*(){const{x:r,y:o,placement:u,rects:a,platform:c,elements:f,middlewareData:h}=n,{element:m,padding:E=0}=Gr(e,n)||{};if(m==null)return{};const b=f1(E),T={x:r,y:o},_=pd(u),S=hd(_),C=yield c.getDimensions(m),k=_==="y",M=k?"top":"left",D=k?"bottom":"right",G=k?"clientHeight":"clientWidth",q=a.reference[S]+a.reference[_]-T[_]-a.floating[S],B=T[_]-a.reference[_],te=yield c.getOffsetParent==null?void 0:c.getOffsetParent(m);let Te=te?te[G]:0;(!Te||!(yield c.isElement==null?void 0:c.isElement(te)))&&(Te=f.floating[G]||a.floating[S]);const Se=q/2-B/2,H=Te/2-C[S]/2-1,fe=fi(b[M],H),de=fi(b[D],H),ue=fe,ie=Te-C[S]-de,ge=Te/2-C[S]/2+Se,we=fd(ue,ge,ie),ae=!h.arrow&&Rs(u)!=null&&ge!==we&&a.reference[S]/2-(ge<ue?fe:de)-C[S]/2<0,V=ae?ge<ue?ge-ue:ge-ie:0;return{[_]:T[_]+V,data:U({[_]:we,centerOffset:ge-we-V},ae&&{alignmentOffset:V}),reset:ae}})}}),ck=function(e){return e===void 0&&(e={}),{name:"flip",options:e,fn(n){return st(this,null,function*(){var r,o;const{placement:u,middlewareData:a,rects:c,initialPlacement:f,platform:h,elements:m}=n,ge=Gr(e,n),{mainAxis:E=!0,crossAxis:b=!0,fallbackPlacements:T,fallbackStrategy:_="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:C=!0}=ge,k=en(ge,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=a.arrow)!=null&&r.alignmentOffset)return{};const M=Kr(u),D=Cr(f),G=Kr(f)===f,q=yield h.isRTL==null?void 0:h.isRTL(m.floating),B=T||(G||!C?[el(f)]:nk(f)),te=S!=="none";!T&&te&&B.push(...ok(f,C,S,q));const Te=[f,...B],Se=yield Wo(n,k),H=[];let fe=((o=a.flip)==null?void 0:o.overflows)||[];if(E&&H.push(Se[M]),b){const we=tk(u,c,q);H.push(Se[we[0]],Se[we[1]])}if(fe=[...fe,{placement:u,overflows:H}],!H.every(we=>we<=0)){var de,ue;const we=(((de=a.flip)==null?void 0:de.index)||0)+1,ae=Te[we];if(ae&&(!(b==="alignment"?D!==Cr(ae):!1)||fe.every(w=>Cr(w.placement)===D?w.overflows[0]>0:!0)))return{data:{index:we,overflows:fe},reset:{placement:ae}};let V=(ue=fe.filter(ee=>ee.overflows[0]<=0).sort((ee,w)=>ee.overflows[1]-w.overflows[1])[0])==null?void 0:ue.placement;if(!V)switch(_){case"bestFit":{var ie;const ee=(ie=fe.filter(w=>{if(te){const R=Cr(w.placement);return R===D||R==="y"}return!0}).map(w=>[w.placement,w.overflows.filter(R=>R>0).reduce((R,Q)=>R+Q,0)]).sort((w,R)=>w[1]-R[1])[0])==null?void 0:ie[0];ee&&(V=ee);break}case"initialPlacement":V=f;break}if(u!==V)return{reset:{placement:V}}}return{}})}}};function h1(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function p1(e){return Xv.some(t=>e[t]>=0)}const fk=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return st(this,null,function*(){const{rects:r}=n,a=Gr(e,n),{strategy:o="referenceHidden"}=a,u=en(a,["strategy"]);switch(o){case"referenceHidden":{const c=yield Wo(n,ye(U({},u),{elementContext:"reference"})),f=h1(c,r.reference);return{data:{referenceHiddenOffsets:f,referenceHidden:p1(f)}}}case"escaped":{const c=yield Wo(n,ye(U({},u),{altBoundary:!0})),f=h1(c,r.floating);return{data:{escapedOffsets:f,escaped:p1(f)}}}default:return{}}})}}},m1=new Set(["left","top"]);function dk(e,t){return st(this,null,function*(){const{placement:n,platform:r,elements:o}=e,u=yield r.isRTL==null?void 0:r.isRTL(o.floating),a=Kr(n),c=Rs(n),f=Cr(n)==="y",h=m1.has(a)?-1:1,m=u&&f?-1:1,E=Gr(t,e);let{mainAxis:b,crossAxis:T,alignmentAxis:_}=typeof E=="number"?{mainAxis:E,crossAxis:0,alignmentAxis:null}:{mainAxis:E.mainAxis||0,crossAxis:E.crossAxis||0,alignmentAxis:E.alignmentAxis};return c&&typeof _=="number"&&(T=c==="end"?_*-1:_),f?{x:T*m,y:b*h}:{x:b*h,y:T*m}})}const hk=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(n){return st(this,null,function*(){var r,o;const{x:u,y:a,placement:c,middlewareData:f}=n,h=yield dk(n,e);return c===((r=f.offset)==null?void 0:r.placement)&&(o=f.arrow)!=null&&o.alignmentOffset?{}:{x:u+h.x,y:a+h.y,data:ye(U({},h),{placement:c})}})}}},pk=function(e){return e===void 0&&(e={}),{name:"shift",options:e,fn(n){return st(this,null,function*(){const{x:r,y:o,placement:u}=n,k=Gr(e,n),{mainAxis:a=!0,crossAxis:c=!1,limiter:f={fn:M=>{let{x:D,y:G}=M;return{x:D,y:G}}}}=k,h=en(k,["mainAxis","crossAxis","limiter"]),m={x:r,y:o},E=yield Wo(n,h),b=Cr(Kr(u)),T=dd(b);let _=m[T],S=m[b];if(a){const M=T==="y"?"top":"left",D=T==="y"?"bottom":"right",G=_+E[M],q=_-E[D];_=fd(G,_,q)}if(c){const M=b==="y"?"top":"left",D=b==="y"?"bottom":"right",G=S+E[M],q=S-E[D];S=fd(G,S,q)}const C=f.fn(ye(U({},n),{[T]:_,[b]:S}));return ye(U({},C),{data:{x:C.x-r,y:C.y-o,enabled:{[T]:a,[b]:c}}})})}}},mk=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:u,middlewareData:a}=t,{offset:c=0,mainAxis:f=!0,crossAxis:h=!0}=Gr(e,t),m={x:n,y:r},E=Cr(o),b=dd(E);let T=m[b],_=m[E];const S=Gr(c,t),C=typeof S=="number"?{mainAxis:S,crossAxis:0}:U({mainAxis:0,crossAxis:0},S);if(f){const D=b==="y"?"height":"width",G=u.reference[b]-u.floating[D]+C.mainAxis,q=u.reference[b]+u.reference[D]-C.mainAxis;T<G?T=G:T>q&&(T=q)}if(h){var k,M;const D=b==="y"?"width":"height",G=m1.has(Kr(o)),q=u.reference[E]-u.floating[D]+(G&&((k=a.offset)==null?void 0:k[E])||0)+(G?0:C.crossAxis),B=u.reference[E]+u.reference[D]+(G?0:((M=a.offset)==null?void 0:M[E])||0)-(G?C.crossAxis:0);_<q?_=q:_>B&&(_=B)}return{[b]:T,[E]:_}}}},gk=function(e){return e===void 0&&(e={}),{name:"size",options:e,fn(n){return st(this,null,function*(){var r,o;const{placement:u,rects:a,platform:c,elements:f}=n,fe=Gr(e,n),{apply:h=()=>{}}=fe,m=en(fe,["apply"]),E=yield Wo(n,m),b=Kr(u),T=Rs(u),_=Cr(u)==="y",{width:S,height:C}=a.floating;let k,M;b==="top"||b==="bottom"?(k=b,M=T===((yield c.isRTL==null?void 0:c.isRTL(f.floating))?"start":"end")?"left":"right"):(M=b,k=T==="end"?"top":"bottom");const D=C-E.top-E.bottom,G=S-E.left-E.right,q=fi(C-E[k],D),B=fi(S-E[M],G),te=!n.middlewareData.shift;let Te=q,Se=B;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(Se=G),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(Te=D),te&&!T){const de=In(E.left,0),ue=In(E.right,0),ie=In(E.top,0),ge=In(E.bottom,0);_?Se=S-2*(de!==0||ue!==0?de+ue:In(E.left,E.right)):Te=C-2*(ie!==0||ge!==0?ie+ge:In(E.top,E.bottom))}yield h(ye(U({},n),{availableWidth:Se,availableHeight:Te}));const H=yield c.getDimensions(f.floating);return S!==H.width||C!==H.height?{reset:{rects:!0}}:{}})}}};function nl(){return typeof window!="undefined"}function Ls(e){return g1(e)?(e.nodeName||"").toLowerCase():"#document"}function Pn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ar(e){var t;return(t=(g1(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function g1(e){return nl()?e instanceof Node||e instanceof Pn(e).Node:!1}function lr(e){return nl()?e instanceof Element||e instanceof Pn(e).Element:!1}function vr(e){return nl()?e instanceof HTMLElement||e instanceof Pn(e).HTMLElement:!1}function E1(e){return!nl()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof Pn(e).ShadowRoot}const Ek=new Set(["inline","contents"]);function Go(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=cr(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Ek.has(o)}const yk=new Set(["table","td","th"]);function Tk(e){return yk.has(Ls(e))}const bk=[":popover-open",":modal"];function rl(e){return bk.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const _k=["transform","translate","scale","rotate","perspective"],xk=["transform","translate","scale","rotate","perspective","filter"],Sk=["paint","layout","strict","content"];function gd(e){const t=Ed(),n=lr(e)?cr(e):e;return _k.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||xk.some(r=>(n.willChange||"").includes(r))||Sk.some(r=>(n.contain||"").includes(r))}function wk(e){let t=di(e);for(;vr(t)&&!Ds(t);){if(gd(t))return t;if(rl(t))return null;t=di(t)}return null}function Ed(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Ck=new Set(["html","body","#document"]);function Ds(e){return Ck.has(Ls(e))}function cr(e){return Pn(e).getComputedStyle(e)}function il(e){return lr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function di(e){if(Ls(e)==="html")return e;const t=e.assignedSlot||e.parentNode||E1(e)&&e.host||Ar(e);return E1(t)?t.host:t}function y1(e){const t=di(e);return Ds(t)?e.ownerDocument?e.ownerDocument.body:e.body:vr(t)&&Go(t)?t:y1(t)}function Ko(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=y1(e),u=o===((r=e.ownerDocument)==null?void 0:r.body),a=Pn(o);if(u){const c=yd(a);return t.concat(a,a.visualViewport||[],Go(o)?o:[],c&&n?Ko(c):[])}return t.concat(o,Ko(o,[],n))}function yd(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function T1(e){const t=cr(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=vr(e),u=o?e.offsetWidth:n,a=o?e.offsetHeight:r,c=Ja(n)!==u||Ja(r)!==a;return c&&(n=u,r=a),{width:n,height:r,$:c}}function Td(e){return lr(e)?e:e.contextElement}function Fs(e){const t=Td(e);if(!vr(t))return wr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:u}=T1(t);let a=(u?Ja(n.width):n.width)/r,c=(u?Ja(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!c||!Number.isFinite(c))&&(c=1),{x:a,y:c}}const Ak=wr(0);function b1(e){const t=Pn(e);return!Ed()||!t.visualViewport?Ak:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function vk(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Pn(e)?!1:t}function Yi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),u=Td(e);let a=wr(1);t&&(r?lr(r)&&(a=Fs(r)):a=Fs(e));const c=vk(u,n,r)?b1(u):wr(0);let f=(o.left+c.x)/a.x,h=(o.top+c.y)/a.y,m=o.width/a.x,E=o.height/a.y;if(u){const b=Pn(u),T=r&&lr(r)?Pn(r):r;let _=b,S=yd(_);for(;S&&r&&T!==_;){const C=Fs(S),k=S.getBoundingClientRect(),M=cr(S),D=k.left+(S.clientLeft+parseFloat(M.paddingLeft))*C.x,G=k.top+(S.clientTop+parseFloat(M.paddingTop))*C.y;f*=C.x,h*=C.y,m*=C.x,E*=C.y,f+=D,h+=G,_=Pn(S),S=yd(_)}}return tl({width:m,height:E,x:f,y:h})}function sl(e,t){const n=il(e).scrollLeft;return t?t.left+n:Yi(Ar(e)).left+n}function _1(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-sl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function kk(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const u=o==="fixed",a=Ar(r),c=t?rl(t.floating):!1;if(r===a||c&&u)return n;let f={scrollLeft:0,scrollTop:0},h=wr(1);const m=wr(0),E=vr(r);if((E||!E&&!u)&&((Ls(r)!=="body"||Go(a))&&(f=il(r)),vr(r))){const T=Yi(r);h=Fs(r),m.x=T.x+r.clientLeft,m.y=T.y+r.clientTop}const b=a&&!E&&!u?_1(a,f):wr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-f.scrollLeft*h.x+m.x+b.x,y:n.y*h.y-f.scrollTop*h.y+m.y+b.y}}function Nk(e){return Array.from(e.getClientRects())}function Ok(e){const t=Ar(e),n=il(e),r=e.ownerDocument.body,o=In(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),u=In(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+sl(e);const c=-n.scrollTop;return cr(r).direction==="rtl"&&(a+=In(t.clientWidth,r.clientWidth)-o),{width:o,height:u,x:a,y:c}}const x1=25;function Ik(e,t){const n=Pn(e),r=Ar(e),o=n.visualViewport;let u=r.clientWidth,a=r.clientHeight,c=0,f=0;if(o){u=o.width,a=o.height;const m=Ed();(!m||m&&t==="fixed")&&(c=o.offsetLeft,f=o.offsetTop)}const h=sl(r);if(h<=0){const m=r.ownerDocument,E=m.body,b=getComputedStyle(E),T=m.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,_=Math.abs(r.clientWidth-E.clientWidth-T);_<=x1&&(u-=_)}else h<=x1&&(u+=h);return{width:u,height:a,x:c,y:f}}const Pk=new Set(["absolute","fixed"]);function Rk(e,t){const n=Yi(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,u=vr(e)?Fs(e):wr(1),a=e.clientWidth*u.x,c=e.clientHeight*u.y,f=o*u.x,h=r*u.y;return{width:a,height:c,x:f,y:h}}function S1(e,t,n){let r;if(t==="viewport")r=Ik(e,n);else if(t==="document")r=Ok(Ar(e));else if(lr(t))r=Rk(t,n);else{const o=b1(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return tl(r)}function w1(e,t){const n=di(e);return n===t||!lr(n)||Ds(n)?!1:cr(n).position==="fixed"||w1(n,t)}function Lk(e,t){const n=t.get(e);if(n)return n;let r=Ko(e,[],!1).filter(c=>lr(c)&&Ls(c)!=="body"),o=null;const u=cr(e).position==="fixed";let a=u?di(e):e;for(;lr(a)&&!Ds(a);){const c=cr(a),f=gd(a);!f&&c.position==="fixed"&&(o=null),(u?!f&&!o:!f&&c.position==="static"&&!!o&&Pk.has(o.position)||Go(a)&&!f&&w1(e,a))?r=r.filter(m=>m!==a):o=c,a=di(a)}return t.set(e,r),r}function Dk(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?rl(t)?[]:Lk(t,this._c):[].concat(n),r],c=a[0],f=a.reduce((h,m)=>{const E=S1(t,m,o);return h.top=In(E.top,h.top),h.right=fi(E.right,h.right),h.bottom=fi(E.bottom,h.bottom),h.left=In(E.left,h.left),h},S1(t,c,o));return{width:f.right-f.left,height:f.bottom-f.top,x:f.left,y:f.top}}function Fk(e){const{width:t,height:n}=T1(e);return{width:t,height:n}}function Mk(e,t,n){const r=vr(t),o=Ar(t),u=n==="fixed",a=Yi(e,!0,u,t);let c={scrollLeft:0,scrollTop:0};const f=wr(0);function h(){f.x=sl(o)}if(r||!r&&!u)if((Ls(t)!=="body"||Go(o))&&(c=il(t)),r){const T=Yi(t,!0,u,t);f.x=T.x+t.clientLeft,f.y=T.y+t.clientTop}else o&&h();u&&!r&&o&&h();const m=o&&!r&&!u?_1(o,c):wr(0),E=a.left+c.scrollLeft-f.x-m.x,b=a.top+c.scrollTop-f.y-m.y;return{x:E,y:b,width:a.width,height:a.height}}function bd(e){return cr(e).position==="static"}function C1(e,t){if(!vr(e)||cr(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ar(e)===n&&(n=n.ownerDocument.body),n}function A1(e,t){const n=Pn(e);if(rl(e))return n;if(!vr(e)){let o=di(e);for(;o&&!Ds(o);){if(lr(o)&&!bd(o))return o;o=di(o)}return n}let r=C1(e,t);for(;r&&Tk(r)&&bd(r);)r=C1(r,t);return r&&Ds(r)&&bd(r)&&!gd(r)?n:r||wk(e)||n}const Bk=function(e){return st(this,null,function*(){const t=this.getOffsetParent||A1,n=this.getDimensions,r=yield n(e.floating);return{reference:Mk(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function Uk(e){return cr(e).direction==="rtl"}const Hk={convertOffsetParentRelativeRectToViewportRelativeRect:kk,getDocumentElement:Ar,getClippingRect:Dk,getOffsetParent:A1,getElementRects:Bk,getClientRects:Nk,getDimensions:Fk,getScale:Fs,isElement:lr,isRTL:Uk};function v1(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function zk(e,t){let n=null,r;const o=Ar(e);function u(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function a(c,f){c===void 0&&(c=!1),f===void 0&&(f=1),u();const h=e.getBoundingClientRect(),{left:m,top:E,width:b,height:T}=h;if(c||t(),!b||!T)return;const _=Za(E),S=Za(o.clientWidth-(m+b)),C=Za(o.clientHeight-(E+T)),k=Za(m),D={rootMargin:-_+"px "+-S+"px "+-C+"px "+-k+"px",threshold:In(0,fi(1,f))||1};let G=!0;function q(B){const te=B[0].intersectionRatio;if(te!==f){if(!G)return a();te?a(!1,te):r=setTimeout(()=>{a(!1,1e-7)},1e3)}te===1&&!v1(h,e.getBoundingClientRect())&&a(),G=!1}try{n=new IntersectionObserver(q,ye(U({},D),{root:o.ownerDocument}))}catch(B){n=new IntersectionObserver(q,D)}n.observe(e)}return a(!0),u}function jk(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:u=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:f=!1}=r,h=Td(e),m=o||u?[...h?Ko(h):[],...Ko(t)]:[];m.forEach(k=>{o&&k.addEventListener("scroll",n,{passive:!0}),u&&k.addEventListener("resize",n)});const E=h&&c?zk(h,n):null;let b=-1,T=null;a&&(T=new ResizeObserver(k=>{let[M]=k;M&&M.target===h&&T&&(T.unobserve(t),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var D;(D=T)==null||D.observe(t)})),n()}),h&&!f&&T.observe(h),T.observe(t));let _,S=f?Yi(e):null;f&&C();function C(){const k=Yi(e);S&&!v1(S,k)&&n(),S=k,_=requestAnimationFrame(C)}return n(),()=>{var k;m.forEach(M=>{o&&M.removeEventListener("scroll",n),u&&M.removeEventListener("resize",n)}),E==null||E(),(k=T)==null||k.disconnect(),T=null,f&&cancelAnimationFrame(_)}}const $k=hk,Vk=pk,qk=ck,Yk=gk,Wk=fk,Gk=lk,Kk=mk,Qk=(e,t,n)=>{const r=new Map,o=U({platform:Hk},n),u=ye(U({},o.platform),{_c:r});return ak(e,t,ye(U({},o),{platform:u}))};function k1(e=0,t=0,n=0,r=0){if(typeof DOMRect=="function")return new DOMRect(e,t,n,r);const o={x:e,y:t,width:n,height:r,top:t,right:e+n,bottom:t+r,left:e};return ye(U({},o),{toJSON:()=>o})}function Xk(e){if(!e)return k1();const{x:t,y:n,width:r,height:o}=e;return k1(t,n,r,o)}function Jk(e,t){return{contextElement:jt(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?Xk(r):n.getBoundingClientRect()}}}var Qo=e=>({variable:e,reference:`var(${e})`}),Qr={arrowSize:Qo("--arrow-size"),arrowSizeHalf:Qo("--arrow-size-half"),arrowBg:Qo("--arrow-background"),transformOrigin:Qo("--transform-origin"),arrowOffset:Qo("--arrow-offset")},Zk=e=>e==="top"||e==="bottom"?"y":"x";function eN(e,t){return{name:"transformOrigin",fn(n){var Se,H,fe,de,ue;const{elements:r,middlewareData:o,placement:u,rects:a,y:c}=n,f=u.split("-")[0],h=Zk(f),m=((Se=o.arrow)==null?void 0:Se.x)||0,E=((H=o.arrow)==null?void 0:H.y)||0,b=(t==null?void 0:t.clientWidth)||0,T=(t==null?void 0:t.clientHeight)||0,_=m+b/2,S=E+T/2,C=Math.abs(((fe=o.shift)==null?void 0:fe.y)||0),k=a.reference.height/2,M=T/2,D=(ue=(de=e.offset)==null?void 0:de.mainAxis)!=null?ue:e.gutter,G=typeof D=="number"?D+M:D!=null?D:M,q=C>G,B={top:`${_}px calc(100% + ${G}px)`,bottom:`${_}px ${-G}px`,left:`calc(100% + ${G}px) ${S}px`,right:`${-G}px ${S}px`}[f],te=`${_}px ${a.reference.y+k-c}px`,Te=!!e.overlap&&h==="y"&&q;return r.floating.style.setProperty(Qr.transformOrigin.variable,Te?te:B),{data:{transformOrigin:Te?te:B}}}}}var tN={name:"rects",fn({rects:e}){return{data:e}}},nN=e=>{if(e)return{name:"shiftArrow",fn({placement:t,middlewareData:n}){if(!n.arrow)return{};const{x:r,y:o}=n.arrow,u=t.split("-")[0];return Object.assign(e.style,{left:r!=null?`${r}px`:"",top:o!=null?`${o}px`:"",[u]:`calc(100% + ${Qr.arrowOffset.reference})`}),{}}}};function rN(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var iN={strategy:"absolute",placement:"bottom",listeners:!0,gutter:8,flip:!0,slide:!0,overlap:!1,sameWidth:!1,fitViewport:!1,overflowPadding:8,arrowPadding:4};function N1(e,t){const n=e.devicePixelRatio||1;return Math.round(t*n)/n}function _d(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function sN(e,t,n){const r=e||t.createElement("div");return Gk({element:r,padding:n.arrowPadding})}function oN(e,t){var n;if(!kA((n=t.offset)!=null?n:t.gutter))return $k(({placement:r})=>{var m,E,b,T;const o=((e==null?void 0:e.clientHeight)||0)/2,u=(E=(m=t.offset)==null?void 0:m.mainAxis)!=null?E:t.gutter,a=typeof u=="number"?u+o:u!=null?u:o,{hasAlign:c}=rN(r),f=c?void 0:t.shift,h=(T=(b=t.offset)==null?void 0:b.crossAxis)!=null?T:f;return Yf({crossAxis:h,mainAxis:a,alignmentAxis:t.shift})})}function uN(e){if(!e.flip)return;const t=_d(e.boundary);return qk(ye(U({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function aN(e){if(!e.slide&&!e.overlap)return;const t=_d(e.boundary);return Vk(ye(U({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:Kk()}))}function lN(e){return Yk({padding:e.overflowPadding,apply({elements:t,rects:n,availableHeight:r,availableWidth:o}){const u=t.floating,a=Math.round(n.reference.width),c=Math.round(n.reference.height);o=Math.floor(o),r=Math.floor(r),u.style.setProperty("--reference-width",`${a}px`),u.style.setProperty("--reference-height",`${c}px`),u.style.setProperty("--available-width",`${o}px`),u.style.setProperty("--available-height",`${r}px`)}})}function cN(e){var t;if(e.hideWhenDetached)return Wk({strategy:"referenceHidden",boundary:(t=_d(e.boundary))!=null?t:"clippingAncestors"})}function fN(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function dN(e,t,n={}){const r=Jk(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},iN,n),u=t.querySelector("[data-part=arrow]"),a=[oN(u,o),uN(o),aN(o),sN(u,t.ownerDocument,o),nN(u),eN({gutter:o.gutter,offset:o.offset,overlap:o.overlap},u),lN(o),cN(o),tN],{placement:c,strategy:f,onComplete:h,onPositioned:m}=o,E=()=>st(null,null,function*(){var G;if(!r||!t)return;const S=yield Qk(r,t,{placement:c,middleware:a,strategy:f});h==null||h(S),m==null||m({placed:!0});const C=vs(t),k=N1(C,S.x),M=N1(C,S.y);t.style.setProperty("--x",`${k}px`),t.style.setProperty("--y",`${M}px`),o.hideWhenDetached&&(((G=S.middlewareData.hide)==null?void 0:G.referenceHidden)?(t.style.setProperty("visibility","hidden"),t.style.setProperty("pointer-events","none")):(t.style.removeProperty("visibility"),t.style.removeProperty("pointer-events")));const D=t.firstElementChild;if(D){const q=qa(D);t.style.setProperty("--z-index",q.zIndex)}}),b=()=>st(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),m==null||m({placed:!0})):yield E()}),T=fN(o.listeners),_=o.listeners?jk(r,t,b,T):MA;return b(),()=>{_==null||_(),m==null||m({placed:!1})}}function O1(e,t,n={}){const c=n,{defer:r}=c,o=en(c,["defer"]),u=r?Tn:f=>f(),a=[];return a.push(u(()=>{const f=typeof e=="function"?e():e,h=typeof t=="function"?t():t;a.push(dN(f,h,o))})),()=>{a.forEach(f=>f==null?void 0:f())}}var hN={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function pN(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:Qr.arrowSize.reference,height:Qr.arrowSize.reference,[Qr.arrowSizeHalf.variable]:`calc(${Qr.arrowSize.reference} / 2)`,[Qr.arrowOffset.variable]:`calc(${Qr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?hN[t.split("-")[0]]:void 0,background:Qr.arrowBg.reference,top:"0",left:"0",width:"100%",height:"100%",position:"absolute",zIndex:"inherit"},floating:{position:o,isolation:"isolate",minWidth:n?void 0:"max-content",width:n?"var(--reference-width)":void 0,maxWidth:r?"var(--available-width)":void 0,maxHeight:r?"var(--available-height)":void 0,pointerEvents:t?void 0:"none",top:"0px",left:"0px",transform:t?"translate3d(var(--x), var(--y), 0)":"translate3d(0, -100vh, 0)",zIndex:"var(--z-index)"}}}var Ms=new WeakMap,ol=new WeakMap,ul={},xd=0,I1=e=>e&&(e.host||I1(e.parentNode)),mN=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=I1(n);return r&&e.contains(r)?r:(console.error("[zag-js > ariaHidden] target",n,"in not contained inside",e,". Doing nothing"),null)}).filter(n=>!!n),gN=new Set(["script","output","status","next-route-announcer"]),EN=e=>gN.has(e.localName)||e.role==="status"||e.hasAttribute("aria-live")?!0:e.matches("[data-live-announcer]"),yN=(e,t)=>{const{parentNode:n,markerName:r,controlAttribute:o,followControlledElements:u=!0}=t,a=mN(n,Array.isArray(e)?e:[e]);ul[r]||(ul[r]=new WeakMap);const c=ul[r],f=[],h=new Set,m=new Set(a),E=T=>{!T||h.has(T)||(h.add(T),E(T.parentNode))};a.forEach(T=>{E(T),u&&jt(T)&&Hg(T,_=>{E(_)})});const b=T=>{!T||m.has(T)||Array.prototype.forEach.call(T.children,_=>{if(h.has(_))b(_);else try{if(EN(_))return;const C=_.getAttribute(o)==="true",k=(Ms.get(_)||0)+1,M=(c.get(_)||0)+1;Ms.set(_,k),c.set(_,M),f.push(_),k===1&&C&&ol.set(_,!0),M===1&&_.setAttribute(r,""),C||_.setAttribute(o,"true")}catch(S){console.error("[zag-js > ariaHidden] cannot operate on ",_,S)}})};return b(n),h.clear(),xd++,()=>{f.forEach(T=>{const _=Ms.get(T)-1,S=c.get(T)-1;Ms.set(T,_),c.set(T,S),_||(ol.has(T)||T.removeAttribute(o),ol.delete(T)),S||T.removeAttribute(r)}),xd--,xd||(Ms=new WeakMap,Ms=new WeakMap,ol=new WeakMap,ul={})}},TN=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,bN=(e,t=TN(e),n="data-aria-hidden",r=!0)=>{if(t)return yN(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},_N=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function P1(e,t={}){const{defer:n=!0}=t,r=n?_N:u=>u(),o=[];return o.push(r(()=>{const a=(typeof e=="function"?e():e).filter(Boolean);a.length!==0&&o.push(bN(a))})),()=>{o.forEach(u=>u==null?void 0:u())}}function xN(e){const t={each(n){var r;for(let o=0;o<((r=e.frames)==null?void 0:r.length);o+=1){const u=e.frames[o];u&&n(u)}},addEventListener(n,r,o){return t.each(u=>{try{u.document.addEventListener(n,r,o)}catch(a){}}),()=>{try{t.removeEventListener(n,r,o)}catch(u){}}},removeEventListener(n,r,o){t.each(u=>{try{u.document.removeEventListener(n,r,o)}catch(a){}})}};return t}function SN(e){const t=e.frameElement!=null?e.parent:null;return{addEventListener:(n,r,o)=>{try{t==null||t.addEventListener(n,r,o)}catch(u){}return()=>{try{t==null||t.removeEventListener(n,r,o)}catch(u){}}},removeEventListener:(n,r,o)=>{try{t==null||t.removeEventListener(n,r,o)}catch(u){}}}}var R1="pointerdown.outside",L1="focus.outside";function wN(e){for(const t of e)if(jt(t)&&Wr(t))return!0;return!1}var D1=e=>"clientY"in e;function CN(e,t){if(!D1(t)||!e)return!1;const n=e.getBoundingClientRect();return n.width===0||n.height===0?!1:n.top<=t.clientY&&t.clientY<=n.top+n.height&&n.left<=t.clientX&&t.clientX<=n.left+n.width}function AN(e,t){return e.y<=t.y&&t.y<=e.y+e.height&&e.x<=t.x&&t.x<=e.x+e.width}function F1(e,t){if(!t||!D1(e))return!1;const n=t.scrollHeight>t.clientHeight,r=n&&e.clientX>t.offsetLeft+t.clientWidth,o=t.scrollWidth>t.clientWidth,u=o&&e.clientY>t.offsetTop+t.clientHeight,a={x:t.offsetLeft,y:t.offsetTop,width:t.clientWidth+(n?16:0),height:t.clientHeight+(o?16:0)},c={x:e.clientX,y:e.clientY};return AN(a,c)?r||u:!1}function vN(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:u,defer:a,followControlledElements:c=!0}=t;if(!e)return;const f=Sr(e),h=vs(e),m=xN(h),E=SN(h);function b(D,G){if(!jt(G)||!G.isConnected||Va(e,G)||CN(e,D)||c&&Ug(e,G))return!1;const q=f.querySelector(`[aria-controls="${e.id}"]`);if(q){const te=td(q);if(F1(D,te))return!1}const B=td(e);return F1(D,B)?!1:!(n!=null&&n(G))}const T=new Set,_=Vi(e==null?void 0:e.getRootNode());function S(D){function G(q){var Se,H;const B=a&&!zg()?Tn:fe=>fe(),te=q!=null?q:D,Te=(H=(Se=te==null?void 0:te.composedPath)==null?void 0:Se.call(te))!=null?H:[te==null?void 0:te.target];B(()=>{const fe=_?Te[0]:Yr(D);if(!(!e||!b(D,fe))){if(o||u){const de=qf(o,u);e.addEventListener(R1,de,{once:!0})}M1(e,R1,{bubbles:!1,cancelable:!0,detail:{originalEvent:te,contextmenu:mv(te),focusable:wN(Te),target:fe}})}})}D.pointerType==="touch"?(T.forEach(q=>q()),T.add(ur(f,"click",G,{once:!0})),T.add(E.addEventListener("click",G,{once:!0})),T.add(m.addEventListener("click",G,{once:!0}))):G()}const C=new Set,k=setTimeout(()=>{C.add(ur(f,"pointerdown",S,!0)),C.add(E.addEventListener("pointerdown",S,!0)),C.add(m.addEventListener("pointerdown",S,!0))},0);function M(D){(a?Tn:q=>q())(()=>{var te,Te;const q=(Te=(te=D==null?void 0:D.composedPath)==null?void 0:te.call(D))!=null?Te:[D==null?void 0:D.target],B=_?q[0]:Yr(D);if(!(!e||!b(D,B))){if(r||u){const Se=qf(r,u);e.addEventListener(L1,Se,{once:!0})}M1(e,L1,{bubbles:!1,cancelable:!0,detail:{originalEvent:D,contextmenu:!1,focusable:Wr(B),target:B}})}})}return zg()||(C.add(ur(f,"focusin",M,!0)),C.add(E.addEventListener("focusin",M,!0)),C.add(m.addEventListener("focusin",M,!0))),()=>{clearTimeout(k),T.forEach(D=>D()),C.forEach(D=>D())}}function kN(e,t){const{defer:n}=t,r=n?Tn:u=>u(),o=[];return o.push(r(()=>{const u=typeof e=="function"?e():e;o.push(vN(u,t))})),()=>{o.forEach(u=>u==null?void 0:u())}}function M1(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function NN(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return ur(Sr(e),"keydown",n,{capture:!0})}var B1="layer:request-dismiss",$n={layers:[],branches:[],count(){return this.layers.length},pointerBlockingLayers(){return this.layers.filter(e=>e.pointerBlocking)},topMostPointerBlockingLayer(){return[...this.pointerBlockingLayers()].slice(-1)[0]},hasPointerBlockingLayer(){return this.pointerBlockingLayers().length>0},isBelowPointerBlockingLayer(e){var r;const t=this.indexOf(e),n=this.topMostPointerBlockingLayer()?this.indexOf((r=this.topMostPointerBlockingLayer())==null?void 0:r.node):-1;return t<n},isTopMost(e){const t=this.layers[this.count()-1];return(t==null?void 0:t.node)===e},getNestedLayers(e){return Array.from(this.layers).slice(this.indexOf(e)+1)},getLayersByType(e){return this.layers.filter(t=>t.type===e)},getNestedLayersByType(e,t){const n=this.indexOf(e);return n===-1?[]:this.layers.slice(n+1).filter(r=>r.type===t)},getParentLayerOfType(e,t){const n=this.indexOf(e);if(!(n<=0))return this.layers.slice(0,n).reverse().find(r=>r.type===t)},countNestedLayersOfType(e,t){return this.getNestedLayersByType(e,t).length},isInNestedLayer(e,t){return this.getNestedLayers(e).some(n=>Va(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>Va(t,e))},add(e){this.layers.push(e),this.syncLayers()},addBranch(e){this.branches.push(e)},remove(e){const t=this.indexOf(e);t<0||(t<this.count()-1&&this.getNestedLayers(e).forEach(r=>$n.dismiss(r.node,e)),this.layers.splice(t,1),this.syncLayers())},removeBranch(e){const t=this.branches.indexOf(e);t>=0&&this.branches.splice(t,1)},syncLayers(){this.layers.forEach((e,t)=>{e.node.style.setProperty("--layer-index",`${t}`),e.node.removeAttribute("data-nested"),e.node.removeAttribute("data-has-nested"),this.getParentLayerOfType(e.node,e.type)&&e.node.setAttribute("data-nested",e.type);const r=this.countNestedLayersOfType(e.node,e.type);r>0&&e.node.setAttribute("data-has-nested",e.type),e.node.style.setProperty("--nested-layer-count",`${r}`)})},indexOf(e){return this.layers.findIndex(t=>t.node===e)},dismiss(e,t){const n=this.indexOf(e);if(n===-1)return;const r=this.layers[n];IN(e,B1,o=>{var u;(u=r.requestDismiss)==null||u.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),ON(e,B1,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function ON(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,{cancelable:!0,bubbles:!0,detail:n});return e.dispatchEvent(o)}function IN(e,t,n){e.addEventListener(t,n,{once:!0})}var U1;function H1(){$n.layers.forEach(({node:e})=>{e.style.pointerEvents=$n.isBelowPointerBlockingLayer(e)?"none":"auto"})}function PN(e){e.style.pointerEvents=""}function RN(e,t){const n=Sr(e),r=[];return $n.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(U1=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[u,a]=Iv(()=>{const c=o();return jt(c)?c:null},{timeout:1e3});u.then(c=>r.push(Wa(c,{pointerEvents:"auto"}))),r.push(a)}),()=>{$n.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=U1,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function LN(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Wf("[@zag-js/dismissable] node is `null` or `undefined`");return}if(!e)return;const{onDismiss:r,onRequestDismiss:o,pointerBlocking:u,exclude:a,debug:c,type:f="dialog"}=t,h={dismiss:r,node:e,type:f,pointerBlocking:u,requestDismiss:o};$n.add(h),H1();function m(S){var k,M;const C=Yr(S.detail.originalEvent);$n.isBelowPointerBlockingLayer(e)||$n.isInBranch(C)||((k=t.onPointerDownOutside)==null||k.call(t,S),(M=t.onInteractOutside)==null||M.call(t,S),!S.defaultPrevented&&(c&&console.log("onPointerDownOutside:",S.detail.originalEvent),r==null||r()))}function E(S){var k,M;const C=Yr(S.detail.originalEvent);$n.isInBranch(C)||((k=t.onFocusOutside)==null||k.call(t,S),(M=t.onInteractOutside)==null||M.call(t,S),!S.defaultPrevented&&(c&&console.log("onFocusOutside:",S.detail.originalEvent),r==null||r()))}function b(S){var C;$n.isTopMost(e)&&((C=t.onEscapeKeyDown)==null||C.call(t,S),!S.defaultPrevented&&r&&(S.preventDefault(),r()))}function T(S){var D;if(!e)return!1;const C=typeof a=="function"?a():a,k=Array.isArray(C)?C:[C],M=(D=t.persistentElements)==null?void 0:D.map(G=>G()).filter(jt);return M&&k.push(...M),k.some(G=>Va(G,S))||$n.isInNestedLayer(e,S)}const _=[u?RN(e,t.persistentElements):void 0,NN(e,b),kN(e,{exclude:T,onFocusOutside:E,onPointerDownOutside:m,defer:t.defer})];return()=>{$n.remove(e),H1(),PN(e),_.forEach(S=>S==null?void 0:S())}}function z1(e,t){const{defer:n}=t,r=n?Tn:u=>u(),o=[];return o.push(r(()=>{const u=As(e)?e():e;o.push(LN(u,t))})),()=>{o.forEach(u=>u==null?void 0:u())}}var DN=Object.defineProperty,FN=(e,t,n)=>t in e?DN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Et=(e,t,n)=>FN(e,typeof t!="symbol"?t+"":t,n),j1={activateTrap(e,t){if(e.length>0){const r=e[e.length-1];r!==t&&r.pause()}const n=e.indexOf(t);n===-1||e.splice(n,1),e.push(t)},deactivateTrap(e,t){const n=e.indexOf(t);n!==-1&&e.splice(n,1),e.length>0&&e[e.length-1].unpause()}},MN=[],BN=class{constructor(e,t){Et(this,"trapStack"),Et(this,"config"),Et(this,"doc"),Et(this,"state",{containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0}),Et(this,"portalContainers",new Set),Et(this,"listenerCleanups",[]),Et(this,"handleFocus",r=>{const o=Yr(r),u=this.findContainerIndex(o,r)>=0;if(u||$a(o))u&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let a,c=!0;if(this.state.mostRecentlyFocusedNode)if(qo(this.state.mostRecentlyFocusedNode)>0){const f=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:h}=this.state.containerGroups[f];if(h.length>0){const m=h.findIndex(E=>E===this.state.mostRecentlyFocusedNode);m>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?m+1<h.length&&(a=h[m+1],c=!1):m-1>=0&&(a=h[m-1],c=!1))}}else this.state.containerGroups.some(f=>f.tabbableNodes.some(h=>qo(h)>0))||(c=!1);else c=!1;c&&(a=this.findNextNavNode({target:this.state.mostRecentlyFocusedNode,isBackward:this.config.isKeyBackward(this.state.recentNavEvent)})),a?this.tryFocus(a):this.tryFocus(this.state.mostRecentlyFocusedNode||this.getInitialFocusNode())}this.state.recentNavEvent=void 0}),Et(this,"handlePointerDown",r=>{const o=Yr(r);if(!(this.findContainerIndex(o,r)>=0)){if(Jo(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}Jo(this.config.allowOutsideClick,r)||r.preventDefault()}}),Et(this,"handleClick",r=>{const o=Yr(r);this.findContainerIndex(o,r)>=0||Jo(this.config.clickOutsideDeactivates,r)||Jo(this.config.allowOutsideClick,r)||(r.preventDefault(),r.stopImmediatePropagation())}),Et(this,"handleTabKey",r=>{if(this.config.isKeyForward(r)||this.config.isKeyBackward(r)){this.state.recentNavEvent=r;const o=this.config.isKeyBackward(r),u=this.findNextNavNode({event:r,isBackward:o});if(!u)return;Xo(r)&&r.preventDefault(),this.tryFocus(u)}}),Et(this,"handleEscapeKey",r=>{UN(r)&&Jo(this.config.escapeDeactivates,r)!==!1&&(r.preventDefault(),this.deactivate())}),Et(this,"_mutationObserver"),Et(this,"setupMutationObserver",()=>{const r=this.doc.defaultView||window;this._mutationObserver=new r.MutationObserver(o=>{o.some(c=>Array.from(c.removedNodes).some(h=>h===this.state.mostRecentlyFocusedNode))&&this.tryFocus(this.getInitialFocusNode()),o.some(c=>c.type==="attributes"&&(c.attributeName==="aria-controls"||c.attributeName==="aria-expanded")?!0:c.type==="childList"&&c.addedNodes.length>0?Array.from(c.addedNodes).some(f=>{if(f.nodeType!==Node.ELEMENT_NODE)return!1;const h=f;return sv(h)?!0:h.id&&!this.state.containers.some(m=>m.contains(h))?ov(h):!1}):!1)&&this.state.active&&!this.state.paused&&(this.updateTabbableNodes(),this.updatePortalContainers())})}),Et(this,"updateObservedNodes",()=>{var r;(r=this._mutationObserver)==null||r.disconnect(),this.state.active&&!this.state.paused&&(this.state.containers.map(o=>{var u;(u=this._mutationObserver)==null||u.observe(o,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}),this.portalContainers.forEach(o=>{this.observePortalContainer(o)}))}),Et(this,"getInitialFocusNode",()=>{let r=this.getNodeForOption("initialFocus",{hasFallback:!0});if(r===!1)return!1;if(r===void 0||r&&!Wr(r)){const o=ks(this.doc);if(o&&this.findContainerIndex(o)>=0)r=o;else{const u=this.state.tabbableGroups[0];r=u&&u.firstTabbableNode||this.getNodeForOption("fallbackFocus")}}else r===null&&(r=this.getNodeForOption("fallbackFocus"));if(!r)throw new Error("Your focus-trap needs to have at least one focusable element");return r.isConnected||(r=this.getNodeForOption("fallbackFocus")),r}),Et(this,"tryFocus",r=>{if(r!==!1&&r!==ks(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,HN(r)&&r.select()}}),Et(this,"deactivate",r=>{if(!this.state.active)return this;const o=U({onDeactivate:this.config.onDeactivate,onPostDeactivate:this.config.onPostDeactivate,checkCanReturnFocus:this.config.checkCanReturnFocus},r);clearTimeout(this.state.delayInitialFocusTimer),this.state.delayInitialFocusTimer=void 0,this.removeListeners(),this.state.active=!1,this.state.paused=!1,this.updateObservedNodes(),j1.deactivateTrap(this.trapStack,this),this.portalContainers.clear();const u=this.getOption(o,"onDeactivate"),a=this.getOption(o,"onPostDeactivate"),c=this.getOption(o,"checkCanReturnFocus"),f=this.getOption(o,"returnFocus","returnFocusOnDeactivate");u==null||u();const h=()=>{$1(()=>{if(f){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(m)}a==null||a()})};if(f&&c){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);return c(m).then(h,h),this}return h(),this}),Et(this,"pause",r=>{if(this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onPause"),u=this.getOption(r,"onPostPause");return this.state.paused=!0,o==null||o(),this.removeListeners(),this.updateObservedNodes(),u==null||u(),this}),Et(this,"unpause",r=>{if(!this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onUnpause"),u=this.getOption(r,"onPostUnpause");return this.state.paused=!1,o==null||o(),this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),u==null||u(),this}),Et(this,"updateContainerElements",r=>(this.state.containers=Array.isArray(r)?r.filter(Boolean):[r].filter(Boolean),this.state.active&&this.updateTabbableNodes(),this.updateObservedNodes(),this)),Et(this,"getReturnFocusNode",r=>{const o=this.getNodeForOption("setReturnFocus",{params:[r]});return o||(o===!1?!1:r)}),Et(this,"getOption",(r,o,u)=>r&&r[o]!==void 0?r[o]:this.config[u||o]),Et(this,"getNodeForOption",(r,{hasFallback:o=!1,params:u=[]}={})=>{let a=this.config[r];if(typeof a=="function"&&(a=a(...u)),a===!0&&(a=void 0),!a){if(a===void 0||a===!1)return a;throw new Error(`\`${r}\` was specified but was not a node, or did not return a node`)}let c=a;if(typeof a=="string"){try{c=this.doc.querySelector(a)}catch(f){throw new Error(`\`${r}\` appears to be an invalid selector; error="${f.message}"`)}if(!c&&!o)throw new Error(`\`${r}\` as selector refers to no known node`)}return c}),Et(this,"findNextNavNode",r=>{const{event:o,isBackward:u=!1}=r,a=r.target||Yr(o);this.updateTabbableNodes();let c=null;if(this.state.tabbableGroups.length>0){const f=this.findContainerIndex(a,o),h=f>=0?this.state.containerGroups[f]:void 0;if(f<0)u?c=this.state.tabbableGroups[this.state.tabbableGroups.length-1].lastTabbableNode:c=this.state.tabbableGroups[0].firstTabbableNode;else if(u){let m=this.state.tabbableGroups.findIndex(({firstTabbableNode:E})=>a===E);if(m<0&&((h==null?void 0:h.container)===a||Wr(a)&&!qi(a)&&!(h!=null&&h.nextTabbableNode(a,!1)))&&(m=f),m>=0){const E=m===0?this.state.tabbableGroups.length-1:m-1,b=this.state.tabbableGroups[E];c=qo(a)>=0?b.lastTabbableNode:b.lastDomTabbableNode}else Xo(o)||(c=h==null?void 0:h.nextTabbableNode(a,!1))}else{let m=this.state.tabbableGroups.findIndex(({lastTabbableNode:E})=>a===E);if(m<0&&((h==null?void 0:h.container)===a||Wr(a)&&!qi(a)&&!(h!=null&&h.nextTabbableNode(a)))&&(m=f),m>=0){const E=m===this.state.tabbableGroups.length-1?0:m+1,b=this.state.tabbableGroups[E];c=qo(a)>=0?b.firstTabbableNode:b.firstDomTabbableNode}else Xo(o)||(c=h==null?void 0:h.nextTabbableNode(a))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||MN;const n=U({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return Xo(r)&&!r.shiftKey},isKeyBackward(r){return Xo(r)&&r.shiftKey}},t);this.doc=n.document||Sr(Array.isArray(e)?e[0]:e),this.config=n,this.updateContainerElements(e),this.setupMutationObserver()}addPortalContainer(e){const t=e.parentElement;t&&!this.portalContainers.has(t)&&(this.portalContainers.add(t),this.state.active&&!this.state.paused&&this.observePortalContainer(t))}observePortalContainer(e){var t;(t=this._mutationObserver)==null||t.observe(e,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}updatePortalContainers(){this.config.followControlledElements&&this.state.containers.forEach(e=>{nv(e).forEach(n=>{this.addPortalContainer(n)})})}get active(){return this.state.active}get paused(){return this.state.paused}findContainerIndex(e,t){const n=typeof(t==null?void 0:t.composedPath)=="function"?t.composedPath():void 0;return this.state.containerGroups.findIndex(({container:r,tabbableNodes:o})=>r.contains(e)||(n==null?void 0:n.includes(r))||o.find(u=>u===e)||this.isControlledElement(r,e))}isControlledElement(e,t){return this.config.followControlledElements?Ug(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Vo(e,{getShadowRoot:this.config.getShadowRoot}),n=Yg(e,{getShadowRoot:this.config.getShadowRoot}),r=t[0],o=t[t.length-1],u=r,a=o;let c=!1;for(let h=0;h<t.length;h++)if(qo(t[h])>0){c=!0;break}function f(h,m=!0){const E=t.indexOf(h);if(E>=0)return t[E+(m?1:-1)];const b=n.indexOf(h);if(!(b<0)){if(m){for(let T=b+1;T<n.length;T++)if(qi(n[T]))return n[T]}else for(let T=b-1;T>=0;T--)if(qi(n[T]))return n[T]}}return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:c,firstTabbableNode:r,lastTabbableNode:o,firstDomTabbableNode:u,lastDomTabbableNode:a,nextTabbableNode:f}}),this.state.tabbableGroups=this.state.containerGroups.filter(e=>e.tabbableNodes.length>0),this.state.tabbableGroups.length<=0&&!this.getNodeForOption("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(this.state.containerGroups.find(e=>e.posTabIndexesFound)&&this.state.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")}addListeners(){if(this.state.active)return j1.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?$1(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(ur(this.doc,"focusin",this.handleFocus,!0),ur(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),ur(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),ur(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),ur(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),ur(this.doc,"keydown",this.handleEscapeKey)),this}removeListeners(){if(this.state.active)return this.listenerCleanups.forEach(e=>e()),this.listenerCleanups=[],this}activate(e){if(this.state.active)return this;const t=this.getOption(e,"onActivate"),n=this.getOption(e,"onPostActivate"),r=this.getOption(e,"checkCanFocusTrap");r||this.updateTabbableNodes(),this.state.active=!0,this.state.paused=!1,this.state.nodeFocusedBeforeActivation=ks(this.doc),t==null||t();const o=()=>{r&&this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),n==null||n()};return r?(r(this.state.containers.concat()).then(o,o),this):(o(),this)}},Xo=e=>e.key==="Tab",Jo=(e,...t)=>typeof e=="function"?e(...t):e,UN=e=>!e.isComposing&&e.key==="Escape",$1=e=>setTimeout(e,0),HN=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function V1(e,t={}){let n;const r=Tn(()=>{const o=typeof e=="function"?e():e;if(o){n=new BN(o,ye(U({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:Sr(o)}));try{n.activate()}catch(u){}}});return function(){n==null||n.deactivate(),r()}}var Sd="data-scroll-lock";function zN(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function q1(e){const t=qa(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function Y1(e){var T;const t=e!=null?e:document,n=(T=t.defaultView)!=null?T:window,{documentElement:r,body:o}=t;if(o.hasAttribute(Sd))return;const a=q1(r)||q1(o),c=n.innerWidth-r.clientWidth;o.setAttribute(Sd,"");const f=()=>Nv(r,"--scrollbar-width",`${c}px`),h=zN(r),m=()=>{const _={overflow:"hidden"};return!a&&c>0&&(_[h]=`${c}px`),Wa(o,_)},E=()=>{var q,B;const{scrollX:_,scrollY:S,visualViewport:C}=n,k=(q=C==null?void 0:C.offsetLeft)!=null?q:0,M=(B=C==null?void 0:C.offsetTop)!=null?B:0,D={position:"fixed",overflow:"hidden",top:`${-(S-Math.floor(M))}px`,left:`${-(_-Math.floor(k))}px`,right:"0"};!a&&c>0&&(D[h]=`${c}px`);const G=Wa(o,D);return()=>{G==null||G(),n.scrollTo({left:_,top:S,behavior:"instant"})}},b=[f(),jg()?E():m()];return()=>{b.forEach(_=>_==null?void 0:_()),o.removeAttribute(Sd)}}var jN=Is("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),kr=jN.build(),W1=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},G1=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},wd=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},K1=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},$N=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},Cd=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},Ad=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},VN=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},Q1=e=>e.getById(W1(e)),Bs=e=>e.getById(G1(e)),Us=e=>e.getById(wd(e)),X1=e=>e.getById(K1(e)),qN=e=>e.getById(Cd(e)),YN=e=>e.getById(Ad(e));function WN(e,t){const{state:n,context:r,send:o,computed:u,prop:a,scope:c}=e,f=n.matches("open"),h=r.get("currentPlacement"),m=u("currentPortalled"),E=r.get("renderedElements"),b=pN(ye(U({},a("positioning")),{placement:h}));return{portalled:m,open:f,setOpen(T){n.matches("open")!==T&&o({type:T?"OPEN":"CLOSE"})},reposition(T={}){o({type:"POSITIONING.SET",options:T})},getArrowProps(){return t.element(ye(U({id:$N(c)},kr.arrow.attrs),{dir:a("dir"),style:b.arrow}))},getArrowTipProps(){return t.element(ye(U({},kr.arrowTip.attrs),{dir:a("dir"),style:b.arrowTip}))},getAnchorProps(){return t.element(ye(U({},kr.anchor.attrs),{dir:a("dir"),id:W1(c)}))},getTriggerProps(){return t.button(ye(U({},kr.trigger.attrs),{dir:a("dir"),type:"button","data-placement":h,id:G1(c),"aria-haspopup":"dialog","aria-expanded":f,"data-state":f?"open":"closed","aria-controls":wd(c),onPointerDown(T){pv(T)&&dv()&&T.currentTarget.focus()},onClick(T){T.defaultPrevented||o({type:"TOGGLE"})},onBlur(T){o({type:"TRIGGER_BLUR",target:T.relatedTarget})}}))},getIndicatorProps(){return t.element(ye(U({},kr.indicator.attrs),{dir:a("dir"),"data-state":f?"open":"closed"}))},getPositionerProps(){return t.element(ye(U({id:K1(c)},kr.positioner.attrs),{dir:a("dir"),style:b.floating}))},getContentProps(){return t.element(ye(U({},kr.content.attrs),{dir:a("dir"),id:wd(c),tabIndex:-1,role:"dialog","aria-modal":jA(a("modal")),hidden:!f,"data-state":f?"open":"closed","data-expanded":zA(f),"aria-labelledby":E.title?Cd(c):void 0,"aria-describedby":E.description?Ad(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(ye(U({},kr.title.attrs),{id:Cd(c),dir:a("dir")}))},getDescriptionProps(){return t.element(ye(U({},kr.description.attrs),{id:Ad(c),dir:a("dir")}))},getCloseTriggerProps(){return t.button(ye(U({},kr.closeTrigger.attrs),{dir:a("dir"),id:VN(c),type:"button","aria-label":"close",onClick(T){T.defaultPrevented||(T.stopPropagation(),o({type:"CLOSE"}))}}))}}}var GN={props({props:e}){return ye(U({closeOnInteractOutside:!0,closeOnEscape:!0,autoFocus:!0,modal:!1,portalled:!0},e),{positioning:U({placement:"bottom"},e.positioning)})},initialState({prop:e}){return e("open")||e("defaultOpen")?"open":"closed"},context({bindable:e}){return{currentPlacement:e(()=>({defaultValue:void 0})),renderedElements:e(()=>({defaultValue:{title:!0,description:!0}}))}},computed:{currentPortalled:({prop:e})=>!!e("modal")||!!e("portalled")},watch({track:e,prop:t,action:n}){e([()=>t("open")],()=>{n(["toggleVisibility"])})},entry:["checkRenderedElements"],states:{closed:{on:{"CONTROLLED.OPEN":{target:"open",actions:["setInitialFocus"]},TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen","setInitialFocus"]}],OPEN:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen","setInitialFocus"]}]}},open:{effects:["trapFocus","preventScroll","hideContentBelow","trackPositioning","trackDismissableElement","proxyTabFocus"],on:{"CONTROLLED.CLOSE":{target:"closed",actions:["setFinalFocus"]},CLOSE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose","setFinalFocus"]}],TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose"]}],"POSITIONING.SET":{actions:["reposition"]}}}},implementations:{guards:{isOpenControlled:({prop:e})=>e("open")!=null},effects:{trackPositioning({context:e,prop:t,scope:n}){var u;e.set("currentPlacement",t("positioning").placement);const r=(u=Q1(n))!=null?u:Bs(n);return O1(r,()=>X1(n),ye(U({},t("positioning")),{defer:!0,onComplete(a){e.set("currentPlacement",a.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Us(n);let o=!0;return z1(r,{type:"popover",pointerBlocking:t("modal"),exclude:Bs(n),defer:!0,onEscapeKeyDown(u){var a;(a=t("onEscapeKeyDown"))==null||a(u),!t("closeOnEscape")&&u.preventDefault()},onInteractOutside(u){var a;(a=t("onInteractOutside"))==null||a(u),!u.defaultPrevented&&(o=!(u.detail.focusable||u.detail.contextmenu),t("closeOnInteractOutside")||u.preventDefault())},onPointerDownOutside:t("onPointerDownOutside"),onFocusOutside:t("onFocusOutside"),persistentElements:t("persistentElements"),onRequestDismiss:t("onRequestDismiss"),onDismiss(){e({type:"CLOSE",src:"interact-outside",restoreFocus:o})}})},proxyTabFocus({prop:e,scope:t}){return e("modal")||!e("portalled")?void 0:kv(()=>Us(t),{triggerElement:Bs(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?P1(()=>[Us(t),Bs(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return Y1(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?V1(()=>Us(t),{initialFocus:()=>Wg({root:Us(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")}),getShadowRoot:!0}):void 0}},actions:{reposition({event:e,prop:t,scope:n,context:r}){var a;const o=(a=Q1(n))!=null?a:Bs(n);O1(o,()=>X1(n),ye(U(U({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){Tn(()=>{Object.assign(e.get("renderedElements"),{title:!!qN(t),description:!!YN(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||Tn(()=>{const n=Wg({root:Us(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")});n==null||n.focus({preventScroll:!0})})},setFinalFocus({event:e,scope:t}){var r,o;const n=(o=e.restoreFocus)!=null?o:(r=e.previousEvent)==null?void 0:r.restoreFocus;n!=null&&!n||Tn(()=>{const u=Bs(t);u==null||u.focus({preventScroll:!0})})},invokeOnOpen({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!0})})},invokeOnClose({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!1})})},toggleVisibility({event:e,send:t,prop:n}){t({type:n("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:e})}}}};od()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[$M,vd]=Os({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[VM,J1]=Os({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),KN=e=>{const t=W.useId(),{getRootNode:n}=vd(),{dir:r}=J1(),o=U({id:t,dir:r,getRootNode:n},e),u=ud(GN,o);return WN(u,r1)},QN=e=>{const[t,a]=a1(e),c=a,{children:n}=c,r=en(c,["children"]),o=KN(r),u=cd(ar({present:o.open},t));return I.jsx(qv,{value:o,children:I.jsx(i1,{value:u,children:n})})},Z1=W.forwardRef((e,t)=>{const n=ld(),r=Yo(),o=ar(ye(U({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return I.jsx(ci.button,ye(U({},o),{ref:t}))});Z1.displayName="PopoverTrigger";function XN(e){return On({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M3 9.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"},child:[]}]})(e)}function eE(e){return On({attr:{version:"1.1",viewBox:"0 0 17 17"},child:[{tag:"g",attr:{},child:[]},{tag:"path",attr:{d:"M6 8h-6v-6h1v4.109c1.013-3.193 4.036-5.484 7.5-5.484 3.506 0 6.621 2.36 7.574 5.739l-0.963 0.271c-0.832-2.95-3.551-5.011-6.611-5.011-3.226 0.001-6.016 2.276-6.708 5.376h4.208v1zM11 9v1h4.208c-0.693 3.101-3.479 5.375-6.708 5.375-3.062 0-5.78-2.061-6.611-5.011l-0.963 0.271c0.952 3.379 4.067 5.739 7.574 5.739 3.459 0 6.475-2.28 7.5-5.482v4.108h1v-6h-6z"},child:[]}]})(e)}const JN=({onClearChat:e,componentType:t})=>{const{resetConversation:n}=qr(),r=()=>{n(),e()};return I.jsxs("button",{className:oe(`${Z}-overflow-menu-button`,"clear-chat-button",t),onClick:r,children:[I.jsx(eE,{}),"Clear chat"]})},ZN=({className:e,componentType:t,children:n})=>{const[r,o]=W.useState(!1),{globalClassName:u}=ir(),a=()=>{o(!1)},c=f=>{o(f.open)};return I.jsxs(QN,{open:r,onOpenChange:c,positioning:{placement:"bottom-end"},children:[I.jsx(Z1,{"aria-label":`Overflow menu for ${t}`,className:oe(`${Z}-overflow-menu-button-trigger`,u,e,t),children:I.jsx(XN,{})}),I.jsx(o1,{children:I.jsxs(s1,{className:oe(`${Z}-overflow-menu-list`,u,t),children:[n,I.jsx(JN,{componentType:t,onClearChat:a})]})})]})};function e3(e){return On({attr:{viewBox:"0 0 24 24",fill:"currentColor"},child:[{tag:"path",attr:{d:"M15 4.00008H13V11.0001H20V9.00008H16.4142L20.7071 4.70718L19.2929 3.29297L15 7.58586V4.00008ZM4.00008 15H7.58586L3.29297 19.2929L4.70718 20.7071L9.00008 16.4142V20H11.0001V13H4.00008V15Z"},child:[]}]})(e)}function tE(e){return On({attr:{viewBox:"0 0 24 24",fill:"currentColor"},child:[{tag:"path",attr:{d:"M17.5858 5H14V3H21V10H19V6.41421L14.7071 10.7071L13.2929 9.29289L17.5858 5ZM3 14H5V17.5858L9.29289 13.2929L10.7071 14.7071L6.41421 19H10V21H3V14Z"},child:[]}]})(e)}const nE=({className:e,onClick:t,disabled:n=!1})=>I.jsx("button",{"aria-label":"Close",className:oe(e,`${Z}-close-button`),disabled:n,onClick:t,children:I.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:I.jsx("path",{d:"M18.3 5.7a1 1 0 0 0-1.4-1.4L12 9.6 7.1 4.7a1 1 0 1 0-1.4 1.4l4.9 4.9-4.9 4.9a1 1 0 1 0 1.4 1.4l4.9-4.9 4.9 4.9a1 1 0 0 0 1.4-1.4l-4.9-4.9 4.9-4.9z"})})}),rE=r=>{var o=r,{onClearChat:e,componentType:t}=o,n=en(o,["onClearChat","componentType"]);const{resetConversation:u}=qr(),a=()=>{u(),e==null||e()};return I.jsx(jo,U({icon:I.jsx(eE,{size:"0.875rem"}),ariaLabel:"Clear Chat",className:oe(`${Z}-clear-chat-icon-button`,t),onClick:a},n))},iE=({componentType:e,isIcon:t})=>{const n=()=>{jf("modal")};return t?I.jsx(jo,{className:oe("toggle-modal-button",e),ariaLabel:"Toggle Modal",onClick:n,icon:I.jsx(tE,{})}):I.jsxs("button",{className:oe(`${Z}-overflow-menu-button`,e,"toggle-modal-button"),onClick:n,children:[I.jsx(tE,{}),"Show modal"]})},t3=({isWidgetStandalone:e,product:t})=>{const{configModule:n,globalClassName:r}=ir();if(!n)return null;const o=n.getName(t),u=n.getBrand(t),a=n.getPriceDisplay(t),c=n.getRelativePdp(t),f=n.getPdp(t),h=n.getImage(t),m=c&&typeof c=="string"?new URL(c,window.location.origin).href:f;return I.jsxs("div",{className:oe(r,`${Z}-product-tile`,{embedded:!e,standalone:e}),children:[I.jsx("img",{className:oe(r,`${Z}-product-tile-image`,{embedded:!e,standalone:e}),src:`${h}`,alt:`${o}`,loading:"lazy"}),I.jsxs("div",{className:oe(r,`${Z}-product-tile-details`,{embedded:!e,standalone:e}),children:[I.jsxs("div",{className:oe(r,`${Z}-product-tile-content`),children:[u&&I.jsx("p",{className:`${Z}-product-tile-brand`,children:u}),m?I.jsxs("a",{"aria-label":`Go to product page for ${o}`,className:oe(r,`${Z}-product-tile-pdp`),href:`${m}`,target:"_blank",rel:"noopener noreferrer",children:[o," ",I.jsx("span",{className:oe(r,`${Z}-product-tile-pdp-arrow`),children:"→"})]}):I.jsx("p",{className:oe(r,`${Z}-product-tile-name`),title:o,children:o})]}),I.jsx("div",{className:oe(r,`${Z}-product-tile-footer`),children:I.jsx("p",{className:oe(r,`${Z}-product-tile-price`),children:a})})]})]})},n3=({isWidgetStandalone:e,message:t})=>{const{configModule:n,globalClassName:r}=ir(),o=t;return n?I.jsxs("div",{className:oe(r,`${Z}-display-products widget-message`),children:[I.jsx("p",{children:o.message}),o.products&&o.products.length>0&&I.jsx("div",{className:oe(r,`${Z}-product-list`,{embedded:!e,standalone:e}),children:o.products.map(u=>{const a=n.getPid(u);return I.jsx(t3,{isWidgetStandalone:e,product:u},`${a}`)})})]}):null},r3=({globalClassName:e,message:t,isWidgetStandalone:n})=>I.jsx("div",{className:oe(e,`${Z}-error-message`,{standalone:n,embedded:!n}),children:I.jsxs("p",{className:oe(e,`${Z}-error-message-text`,{standalone:n,embedded:!n}),children:[I.jsx(bA,{})," ",t.message||"An error occurred while processing your request."]})});function i3(e){return On({attr:{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{d:"M10.75 6.75a.75.75 0 0 0-1.5 0v2.5h-2.5a.75.75 0 0 0 0 1.5h2.5v2.5a.75.75 0 0 0 1.5 0v-2.5h2.5a.75.75 0 0 0 0-1.5h-2.5v-2.5Z"},child:[]}]})(e)}const s3=({globalClassName:e,messageId:t,messageEventSourceId:n,isLoading:r,suggestions:o,handleSuggestionClick:u})=>I.jsx("div",{className:oe(e,`${Z}-suggestion-container standalone`),children:o.map(a=>I.jsxs($f,{disabled:r,className:oe(e,`${Z}-suggestion-button standalone`),onClick:()=>u(a,n||t),children:[I.jsx(i3,{size:"1.5rem",style:{minHeight:"1.5rem",minWidth:"1.5rem"}})," ",a.displayText]},a.displayText))}),o3=({globalClassName:e,message:t,isWidgetStandalone:n,handleSuggestionClick:r})=>{const{isLoading:o}=qr();return I.jsxs("div",{className:oe(e,`${Z}-follow-up`),children:[I.jsx("p",{className:oe(e,`${Z}-text`),children:t.message}),n&&I.jsx(s3,{globalClassName:e,isLoading:o,messageId:t.id,messageEventSourceId:t.eventSourceId,suggestions:t.suggestions,handleSuggestionClick:r}),!n&&I.jsx("div",{className:oe(e,`${Z}-suggestion-container embedded`),children:t.suggestions.map(u=>I.jsx("button",{disabled:o,className:oe(e,`${Z}-suggestion-button embedded`),onClick:()=>r(u,t.eventSourceId||t.id),children:u.displayText},u.displayText))})]})};function qM(){}function YM(){}function sE(e){const t=[],n=String(e||"");let r=n.indexOf(","),o=0,u=!1;for(;!u;){r===-1&&(r=n.length,u=!0);const a=n.slice(o,r).trim();(a||!u)&&t.push(a),o=r+1,r=n.indexOf(",",o)}return t}function oE(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const u3=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,a3=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,l3={};function uE(e,t){return(l3.jsx?a3:u3).test(e)}const c3=/[ \t\n\f\r]/g;function f3(e){return typeof e=="object"?e.type==="text"?aE(e.value):!1:aE(e)}function aE(e){return e.replace(c3,"")===""}let Zo=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Zo.prototype.normal={},Zo.prototype.property={},Zo.prototype.space=void 0;function lE(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Zo(n,r,t)}function eu(e){return e.toLowerCase()}let _n=class{constructor(t,n){this.attribute=n,this.property=t}};_n.prototype.attribute="",_n.prototype.booleanish=!1,_n.prototype.boolean=!1,_n.prototype.commaOrSpaceSeparated=!1,_n.prototype.commaSeparated=!1,_n.prototype.defined=!1,_n.prototype.mustUseProperty=!1,_n.prototype.number=!1,_n.prototype.overloadedBoolean=!1,_n.prototype.property="",_n.prototype.spaceSeparated=!1,_n.prototype.space=void 0;let d3=0;const $e=Wi(),Dt=Wi(),kd=Wi(),he=Wi(),ft=Wi(),Hs=Wi(),Rn=Wi();function Wi(){return Kc(2,++d3)}const Nd=Object.freeze(Object.defineProperty({__proto__:null,boolean:$e,booleanish:Dt,commaOrSpaceSeparated:Rn,commaSeparated:Hs,number:he,overloadedBoolean:kd,spaceSeparated:ft},Symbol.toStringTag,{value:"Module"})),Od=Object.keys(Nd);let Id=class extends _n{constructor(t,n,r,o){let u=-1;if(super(t,n),cE(this,"space",o),typeof r=="number")for(;++u<Od.length;){const a=Od[u];cE(this,Od[u],(r&Nd[a])===Nd[a])}}};Id.prototype.defined=!0;function cE(e,t,n){n&&(e[t]=n)}function zs(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const u=new Id(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(u.mustUseProperty=!0),t[r]=u,n[eu(r)]=r,n[eu(u.attribute)]=r}return new Zo(t,n,e.space)}const fE=zs({properties:{ariaActiveDescendant:null,ariaAtomic:Dt,ariaAutoComplete:null,ariaBusy:Dt,ariaChecked:Dt,ariaColCount:he,ariaColIndex:he,ariaColSpan:he,ariaControls:ft,ariaCurrent:null,ariaDescribedBy:ft,ariaDetails:null,ariaDisabled:Dt,ariaDropEffect:ft,ariaErrorMessage:null,ariaExpanded:Dt,ariaFlowTo:ft,ariaGrabbed:Dt,ariaHasPopup:null,ariaHidden:Dt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ft,ariaLevel:he,ariaLive:null,ariaModal:Dt,ariaMultiLine:Dt,ariaMultiSelectable:Dt,ariaOrientation:null,ariaOwns:ft,ariaPlaceholder:null,ariaPosInSet:he,ariaPressed:Dt,ariaReadOnly:Dt,ariaRelevant:null,ariaRequired:Dt,ariaRoleDescription:ft,ariaRowCount:he,ariaRowIndex:he,ariaRowSpan:he,ariaSelected:Dt,ariaSetSize:he,ariaSort:null,ariaValueMax:he,ariaValueMin:he,ariaValueNow:he,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function dE(e,t){return t in e?e[t]:t}function hE(e,t){return dE(e,t.toLowerCase())}const h3=zs({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Hs,acceptCharset:ft,accessKey:ft,action:null,allow:null,allowFullScreen:$e,allowPaymentRequest:$e,allowUserMedia:$e,alt:null,as:null,async:$e,autoCapitalize:null,autoComplete:ft,autoFocus:$e,autoPlay:$e,blocking:ft,capture:null,charSet:null,checked:$e,cite:null,className:ft,cols:he,colSpan:null,content:null,contentEditable:Dt,controls:$e,controlsList:ft,coords:he|Hs,crossOrigin:null,data:null,dateTime:null,decoding:null,default:$e,defer:$e,dir:null,dirName:null,disabled:$e,download:kd,draggable:Dt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:$e,formTarget:null,headers:ft,height:he,hidden:kd,high:he,href:null,hrefLang:null,htmlFor:ft,httpEquiv:ft,id:null,imageSizes:null,imageSrcSet:null,inert:$e,inputMode:null,integrity:null,is:null,isMap:$e,itemId:null,itemProp:ft,itemRef:ft,itemScope:$e,itemType:ft,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:$e,low:he,manifest:null,max:null,maxLength:he,media:null,method:null,min:null,minLength:he,multiple:$e,muted:$e,name:null,nonce:null,noModule:$e,noValidate:$e,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:$e,optimum:he,pattern:null,ping:ft,placeholder:null,playsInline:$e,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:$e,referrerPolicy:null,rel:ft,required:$e,reversed:$e,rows:he,rowSpan:he,sandbox:ft,scope:null,scoped:$e,seamless:$e,selected:$e,shadowRootClonable:$e,shadowRootDelegatesFocus:$e,shadowRootMode:null,shape:null,size:he,sizes:null,slot:null,span:he,spellCheck:Dt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:he,step:null,style:null,tabIndex:he,target:null,title:null,translate:null,type:null,typeMustMatch:$e,useMap:null,value:Dt,width:he,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ft,axis:null,background:null,bgColor:null,border:he,borderColor:null,bottomMargin:he,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:$e,declare:$e,event:null,face:null,frame:null,frameBorder:null,hSpace:he,leftMargin:he,link:null,longDesc:null,lowSrc:null,marginHeight:he,marginWidth:he,noResize:$e,noHref:$e,noShade:$e,noWrap:$e,object:null,profile:null,prompt:null,rev:null,rightMargin:he,rules:null,scheme:null,scrolling:Dt,standby:null,summary:null,text:null,topMargin:he,valueType:null,version:null,vAlign:null,vLink:null,vSpace:he,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:$e,disableRemotePlayback:$e,prefix:null,property:null,results:he,security:null,unselectable:null},space:"html",transform:hE}),p3=zs({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:Rn,accentHeight:he,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:he,amplitude:he,arabicForm:null,ascent:he,attributeName:null,attributeType:null,azimuth:he,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:he,by:null,calcMode:null,capHeight:he,className:ft,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:he,diffuseConstant:he,direction:null,display:null,dur:null,divisor:he,dominantBaseline:null,download:$e,dx:null,dy:null,edgeMode:null,editable:null,elevation:he,enableBackground:null,end:null,event:null,exponent:he,externalResourcesRequired:null,fill:null,fillOpacity:he,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Hs,g2:Hs,glyphName:Hs,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:he,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:he,horizOriginX:he,horizOriginY:he,id:null,ideographic:he,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:he,k:he,k1:he,k2:he,k3:he,k4:he,kernelMatrix:Rn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:he,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:he,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:he,overlineThickness:he,paintOrder:null,panose1:null,path:null,pathLength:he,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ft,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:he,pointsAtY:he,pointsAtZ:he,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Rn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Rn,rev:Rn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Rn,requiredFeatures:Rn,requiredFonts:Rn,requiredFormats:Rn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:he,specularExponent:he,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:he,strikethroughThickness:he,string:null,stroke:null,strokeDashArray:Rn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:he,strokeOpacity:he,strokeWidth:null,style:null,surfaceScale:he,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Rn,tabIndex:he,tableValues:null,target:null,targetX:he,targetY:he,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Rn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:he,underlineThickness:he,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:he,values:null,vAlphabetic:he,vMathematical:he,vectorEffect:null,vHanging:he,vIdeographic:he,version:null,vertAdvY:he,vertOriginX:he,vertOriginY:he,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:he,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:dE}),pE=zs({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),mE=zs({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:hE}),gE=zs({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),m3={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},g3=/[A-Z]/g,EE=/-[a-z]/g,E3=/^data[-\w.:]+$/i;function Pd(e,t){const n=eu(t);let r=t,o=_n;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&E3.test(t)){if(t.charAt(4)==="-"){const u=t.slice(5).replace(EE,T3);r="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=t.slice(4);if(!EE.test(u)){let a=u.replace(g3,y3);a.charAt(0)!=="-"&&(a="-"+a),t="data"+a}}o=Id}return new o(r,t)}function y3(e){return"-"+e.toLowerCase()}function T3(e){return e.charAt(1).toUpperCase()}const al=lE([fE,h3,pE,mE,gE],"html"),js=lE([fE,p3,pE,mE,gE],"svg");function yE(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function TE(e){return e.join(" ").trim()}var $s={},Rd,bE;function b3(){if(bE)return Rd;bE=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,u=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,c=/^\s+|\s+$/g,f=`
15
+ `,h="/",m="*",E="",b="comment",T="declaration";Rd=function(S,C){if(typeof S!="string")throw new TypeError("First argument must be a string");if(!S)return[];C=C||{};var k=1,M=1;function D(ue){var ie=ue.match(t);ie&&(k+=ie.length);var ge=ue.lastIndexOf(f);M=~ge?ue.length-ge:M+ue.length}function G(){var ue={line:k,column:M};return function(ie){return ie.position=new q(ue),Te(),ie}}function q(ue){this.start=ue,this.end={line:k,column:M},this.source=C.source}q.prototype.content=S;function B(ue){var ie=new Error(C.source+":"+k+":"+M+": "+ue);if(ie.reason=ue,ie.filename=C.source,ie.line=k,ie.column=M,ie.source=S,!C.silent)throw ie}function te(ue){var ie=ue.exec(S);if(ie){var ge=ie[0];return D(ge),S=S.slice(ge.length),ie}}function Te(){te(n)}function Se(ue){var ie;for(ue=ue||[];ie=H();)ie!==!1&&ue.push(ie);return ue}function H(){var ue=G();if(!(h!=S.charAt(0)||m!=S.charAt(1))){for(var ie=2;E!=S.charAt(ie)&&(m!=S.charAt(ie)||h!=S.charAt(ie+1));)++ie;if(ie+=2,E===S.charAt(ie-1))return B("End of comment missing");var ge=S.slice(2,ie-2);return M+=2,D(ge),S=S.slice(ie),M+=2,ue({type:b,comment:ge})}}function fe(){var ue=G(),ie=te(r);if(ie){if(H(),!te(o))return B("property missing ':'");var ge=te(u),we=ue({type:T,property:_(ie[0].replace(e,E)),value:ge?_(ge[0].replace(e,E)):E});return te(a),we}}function de(){var ue=[];Se(ue);for(var ie;ie=fe();)ie!==!1&&(ue.push(ie),Se(ue));return ue}return Te(),de()};function _(S){return S?S.replace(c,E):E}return Rd}var _E;function _3(){if(_E)return $s;_E=1;var e=$s&&$s.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty($s,"__esModule",{value:!0}),$s.default=n;var t=e(b3());function n(r,o){var u=null;if(!r||typeof r!="string")return u;var a=(0,t.default)(r),c=typeof o=="function";return a.forEach(function(f){if(f.type==="declaration"){var h=f.property,m=f.value;c?o(h,m,f):m&&(u=u||{},u[h]=m)}}),u}return $s}var tu={},xE;function x3(){if(xE)return tu;xE=1,Object.defineProperty(tu,"__esModule",{value:!0}),tu.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,u=function(h){return!h||n.test(h)||e.test(h)},a=function(h,m){return m.toUpperCase()},c=function(h,m){return"".concat(m,"-")},f=function(h,m){return m===void 0&&(m={}),u(h)?h:(h=h.toLowerCase(),m.reactCompat?h=h.replace(o,c):h=h.replace(r,c),h.replace(t,a))};return tu.camelCase=f,tu}var nu,SE;function S3(){if(SE)return nu;SE=1;var e=nu&&nu.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(_3()),n=x3();function r(o,u){var a={};return!o||typeof o!="string"||(0,t.default)(o,function(c,f){c&&f&&(a[(0,n.camelCase)(c,u)]=f)}),a}return r.default=r,nu=r,nu}var w3=S3();const C3=Ge(w3),ll=wE("end"),Nr=wE("start");function wE(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function A3(e){const t=Nr(e),n=ll(e);if(t&&n)return{start:t,end:n}}function ru(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?CE(e.position):"start"in e||"end"in e?CE(e):"line"in e||"column"in e?Ld(e):""}function Ld(e){return AE(e&&e.line)+":"+AE(e&&e.column)}function CE(e){return Ld(e&&e.start)+"-"+Ld(e&&e.end)}function AE(e){return e&&typeof e=="number"?e:1}class nn extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let o="",u={},a=!1;if(n&&("line"in n&&"column"in n?u={place:n}:"start"in n&&"end"in n?u={place:n}:"type"in n?u={ancestors:[n],place:n.position}:u=U({},n)),typeof t=="string"?o=t:!u.cause&&t&&(a=!0,o=t.message,u.cause=t),!u.ruleId&&!u.source&&typeof r=="string"){const f=r.indexOf(":");f===-1?u.ruleId=r:(u.source=r.slice(0,f),u.ruleId=r.slice(f+1))}if(!u.place&&u.ancestors&&u.ancestors){const f=u.ancestors[u.ancestors.length-1];f&&(u.place=f.position)}const c=u.place&&"start"in u.place?u.place.start:u.place;this.ancestors=u.ancestors||void 0,this.cause=u.cause||void 0,this.column=c?c.column:void 0,this.fatal=void 0,this.file,this.message=o,this.line=c?c.line:void 0,this.name=ru(u.place)||"1:1",this.place=u.place||void 0,this.reason=this.message,this.ruleId=u.ruleId||void 0,this.source=u.source||void 0,this.stack=a&&u.cause&&typeof u.cause.stack=="string"?u.cause.stack:"",this.actual,this.expected,this.note,this.url}}nn.prototype.file="",nn.prototype.name="",nn.prototype.reason="",nn.prototype.message="",nn.prototype.stack="",nn.prototype.column=void 0,nn.prototype.line=void 0,nn.prototype.ancestors=void 0,nn.prototype.cause=void 0,nn.prototype.fatal=void 0,nn.prototype.place=void 0,nn.prototype.ruleId=void 0,nn.prototype.source=void 0;const Dd={}.hasOwnProperty,v3=new Map,k3=/[A-Z]/g,N3=new Set(["table","tbody","thead","tfoot","tr"]),O3=new Set(["td","th"]),vE="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function I3(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=U3(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=B3(n,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?js:al,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},u=kE(o,e,void 0);return u&&typeof u!="string"?u:o.create(e,o.Fragment,{children:u||void 0},void 0)}function kE(e,t,n){if(t.type==="element")return P3(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return R3(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return D3(e,t,n);if(t.type==="mdxjsEsm")return L3(e,t);if(t.type==="root")return F3(e,t,n);if(t.type==="text")return M3(e,t)}function P3(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=js,e.schema=o),e.ancestors.push(t);const u=OE(e,t.tagName,!1),a=H3(e,t);let c=Md(e,t);return N3.has(t.tagName)&&(c=c.filter(function(f){return typeof f=="string"?!f3(f):!0})),NE(e,a,u,t),Fd(a,c),e.ancestors.pop(),e.schema=r,e.create(t,u,a,n)}function R3(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return r.type,e.evaluater.evaluateExpression(r.expression)}iu(e,t.position)}function L3(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);iu(e,t.position)}function D3(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=js,e.schema=o),e.ancestors.push(t);const u=t.name===null?e.Fragment:OE(e,t.name,!0),a=z3(e,t),c=Md(e,t);return NE(e,a,u,t),Fd(a,c),e.ancestors.pop(),e.schema=r,e.create(t,u,a,n)}function F3(e,t,n){const r={};return Fd(r,Md(e,t)),e.create(t,e.Fragment,r,n)}function M3(e,t){return t.value}function NE(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Fd(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function B3(e,t,n){return r;function r(o,u,a,c){const h=Array.isArray(a.children)?n:t;return c?h(u,a,c):h(u,a)}}function U3(e,t){return n;function n(r,o,u,a){const c=Array.isArray(u.children),f=Nr(r);return t(o,u,a,c,{columnNumber:f?f.column-1:void 0,fileName:e,lineNumber:f?f.line:void 0},void 0)}}function H3(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&Dd.call(t.properties,o)){const u=j3(e,o,t.properties[o]);if(u){const[a,c]=u;e.tableCellAlignToStyle&&a==="align"&&typeof c=="string"&&O3.has(t.tagName)?r=c:n[a]=c}}if(r){const u=n.style||(n.style={});u[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function z3(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const u=r.data.estree.body[0];u.type;const a=u.expression;a.type;const c=a.properties[0];c.type,Object.assign(n,e.evaluater.evaluateExpression(c.argument))}else iu(e,t.position);else{const o=r.name;let u;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const c=r.value.data.estree.body[0];c.type,u=e.evaluater.evaluateExpression(c.expression)}else iu(e,t.position);else u=r.value===null?!0:r.value;n[o]=u}return n}function Md(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:v3;for(;++r<t.children.length;){const u=t.children[r];let a;if(e.passKeys){const f=u.type==="element"?u.tagName:u.type==="mdxJsxFlowElement"||u.type==="mdxJsxTextElement"?u.name:void 0;if(f){const h=o.get(f)||0;a=f+"-"+h,o.set(f,h+1)}}const c=kE(e,u,a);c!==void 0&&n.push(c)}return n}function j3(e,t,n){const r=Pd(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?oE(n):TE(n)),r.property==="style"){let o=typeof n=="object"?n:$3(e,String(n));return e.stylePropertyNameCase==="css"&&(o=V3(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?m3[r.property]||r.property:r.attribute,n]}}function $3(e,t){try{return C3(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new nn("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=vE+"#cannot-parse-style-attribute",o}}function OE(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const o=t.split(".");let u=-1,a;for(;++u<o.length;){const c=uE(o[u])?{type:"Identifier",name:o[u]}:{type:"Literal",value:o[u]};a=a?{type:"MemberExpression",object:a,property:c,computed:!!(u&&c.type==="Literal"),optional:!1}:c}r=a}else r=uE(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return Dd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);iu(e)}function iu(e,t){const n=new nn("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=vE+"#cannot-handle-mdx-estrees-without-createevaluater",n}function V3(e){const t={};let n;for(n in e)Dd.call(e,n)&&(t[q3(n)]=e[n]);return t}function q3(e){let t=e.replace(k3,Y3);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function Y3(e){return"-"+e.toLowerCase()}const Bd={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},W3={};function Ud(e,t){const n=W3,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return IE(e,r,o)}function IE(e,t,n){if(G3(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return PE(e.children,t,n)}return Array.isArray(e)?PE(e,t,n):""}function PE(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=IE(e[o],t,n);return r.join("")}function G3(e){return!!(e&&typeof e=="object")}const RE=document.createElement("i");function Hd(e){const t="&"+e+";";RE.innerHTML=t;const n=RE.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function Ln(e,t,n,r){const o=e.length;let u=0,a;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)a=Array.from(r),a.unshift(t,n),e.splice(...a);else for(n&&e.splice(t,n);u<r.length;)a=r.slice(u,u+1e4),a.unshift(t,0),e.splice(...a),u+=1e4,t+=1e4}function Vn(e,t){return e.length>0?(Ln(e,e.length,0,t),e):t}const LE={}.hasOwnProperty;function DE(e){const t={};let n=-1;for(;++n<e.length;)K3(t,e[n]);return t}function K3(e,t){let n;for(n in t){const o=(LE.call(e,n)?e[n]:void 0)||(e[n]={}),u=t[n];let a;if(u)for(a in u){LE.call(o,a)||(o[a]=[]);const c=u[a];Q3(o[a],Array.isArray(c)?c:c?[c]:[])}}}function Q3(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Ln(e,0,0,r)}function FE(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function fr(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const dn=hi(/[A-Za-z]/),rn=hi(/[\dA-Za-z]/),X3=hi(/[#-'*+\--9=?A-Z^-~]/);function cl(e){return e!==null&&(e<32||e===127)}const zd=hi(/\d/),J3=hi(/[\dA-Fa-f]/),Z3=hi(/[!-/:-@[-`{-~]/);function Re(e){return e!==null&&e<-2}function at(e){return e!==null&&(e<0||e===32)}function Ke(e){return e===-2||e===-1||e===32}const fl=hi(new RegExp("\\p{P}|\\p{S}","u")),Gi=hi(/\s/);function hi(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Vs(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const u=e.charCodeAt(n);let a="";if(u===37&&rn(e.charCodeAt(n+1))&&rn(e.charCodeAt(n+2)))o=2;else if(u<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(u))||(a=String.fromCharCode(u));else if(u>55295&&u<57344){const c=e.charCodeAt(n+1);u<56320&&c>56319&&c<57344?(a=String.fromCharCode(u,c),o=1):a="�"}else a=String.fromCharCode(u);a&&(t.push(e.slice(r,n),encodeURIComponent(a)),r=n+o+1,a=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function Xe(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let u=0;return a;function a(f){return Ke(f)?(e.enter(n),c(f)):t(f)}function c(f){return Ke(f)&&u++<o?(e.consume(f),c):(e.exit(n),t(f))}}const eO={tokenize:tO};function tO(e){const t=e.attempt(this.parser.constructs.contentInitial,r,o);let n;return t;function r(c){if(c===null){e.consume(c);return}return e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),Xe(e,t,"linePrefix")}function o(c){return e.enter("paragraph"),u(c)}function u(c){const f=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=f),n=f,a(c)}function a(c){if(c===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(c);return}return Re(c)?(e.consume(c),e.exit("chunkText"),u):(e.consume(c),a)}}const nO={tokenize:rO},ME={tokenize:iO};function rO(e){const t=this,n=[];let r=0,o,u,a;return c;function c(D){if(r<n.length){const G=n[r];return t.containerState=G[1],e.attempt(G[0].continuation,f,h)(D)}return h(D)}function f(D){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&M();const G=t.events.length;let q=G,B;for(;q--;)if(t.events[q][0]==="exit"&&t.events[q][1].type==="chunkFlow"){B=t.events[q][1].end;break}k(r);let te=G;for(;te<t.events.length;)t.events[te][1].end=U({},B),te++;return Ln(t.events,q+1,0,t.events.slice(G)),t.events.length=te,h(D)}return c(D)}function h(D){if(r===n.length){if(!o)return b(D);if(o.currentConstruct&&o.currentConstruct.concrete)return _(D);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(ME,m,E)(D)}function m(D){return o&&M(),k(r),b(D)}function E(D){return t.parser.lazy[t.now().line]=r!==n.length,a=t.now().offset,_(D)}function b(D){return t.containerState={},e.attempt(ME,T,_)(D)}function T(D){return r++,n.push([t.currentConstruct,t.containerState]),b(D)}function _(D){if(D===null){o&&M(),k(0),e.consume(D);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:u}),S(D)}function S(D){if(D===null){C(e.exit("chunkFlow"),!0),k(0),e.consume(D);return}return Re(D)?(e.consume(D),C(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(D),S)}function C(D,G){const q=t.sliceStream(D);if(G&&q.push(null),D.previous=u,u&&(u.next=D),u=D,o.defineSkip(D.start),o.write(q),t.parser.lazy[D.start.line]){let B=o.events.length;for(;B--;)if(o.events[B][1].start.offset<a&&(!o.events[B][1].end||o.events[B][1].end.offset>a))return;const te=t.events.length;let Te=te,Se,H;for(;Te--;)if(t.events[Te][0]==="exit"&&t.events[Te][1].type==="chunkFlow"){if(Se){H=t.events[Te][1].end;break}Se=!0}for(k(r),B=te;B<t.events.length;)t.events[B][1].end=U({},H),B++;Ln(t.events,Te+1,0,t.events.slice(te)),t.events.length=B}}function k(D){let G=n.length;for(;G-- >D;){const q=n[G];t.containerState=q[1],q[0].exit.call(t,e)}n.length=D}function M(){o.write([null]),u=void 0,o=void 0,t.containerState._closeFlow=void 0}}function iO(e,t,n){return Xe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function qs(e){if(e===null||at(e)||Gi(e))return 1;if(fl(e))return 2}function dl(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const u=e[o].resolveAll;u&&!r.includes(u)&&(t=u(t,n),r.push(u))}return t}const jd={name:"attention",resolveAll:sO,tokenize:oO};function sO(e,t){let n=-1,r,o,u,a,c,f,h,m;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;f=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const E=U({},e[r][1].end),b=U({},e[n][1].start);BE(E,-f),BE(b,f),a={type:f>1?"strongSequence":"emphasisSequence",start:E,end:U({},e[r][1].end)},c={type:f>1?"strongSequence":"emphasisSequence",start:U({},e[n][1].start),end:b},u={type:f>1?"strongText":"emphasisText",start:U({},e[r][1].end),end:U({},e[n][1].start)},o={type:f>1?"strong":"emphasis",start:U({},a.start),end:U({},c.end)},e[r][1].end=U({},a.start),e[n][1].start=U({},c.end),h=[],e[r][1].end.offset-e[r][1].start.offset&&(h=Vn(h,[["enter",e[r][1],t],["exit",e[r][1],t]])),h=Vn(h,[["enter",o,t],["enter",a,t],["exit",a,t],["enter",u,t]]),h=Vn(h,dl(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),h=Vn(h,[["exit",u,t],["enter",c,t],["exit",c,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(m=2,h=Vn(h,[["enter",e[n][1],t],["exit",e[n][1],t]])):m=0,Ln(e,r-1,n-r+3,h),n=r+h.length-m-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function oO(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=qs(r);let u;return a;function a(f){return u=f,e.enter("attentionSequence"),c(f)}function c(f){if(f===u)return e.consume(f),c;const h=e.exit("attentionSequence"),m=qs(f),E=!m||m===2&&o||n.includes(f),b=!o||o===2&&m||n.includes(r);return h._open=!!(u===42?E:E&&(o||!b)),h._close=!!(u===42?b:b&&(m||!E)),t(f)}}function BE(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const uO={name:"autolink",tokenize:aO};function aO(e,t,n){let r=0;return o;function o(T){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),u}function u(T){return dn(T)?(e.consume(T),a):T===64?n(T):h(T)}function a(T){return T===43||T===45||T===46||rn(T)?(r=1,c(T)):h(T)}function c(T){return T===58?(e.consume(T),r=0,f):(T===43||T===45||T===46||rn(T))&&r++<32?(e.consume(T),c):(r=0,h(T))}function f(T){return T===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):T===null||T===32||T===60||cl(T)?n(T):(e.consume(T),f)}function h(T){return T===64?(e.consume(T),m):X3(T)?(e.consume(T),h):n(T)}function m(T){return rn(T)?E(T):n(T)}function E(T){return T===46?(e.consume(T),r=0,m):T===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):b(T)}function b(T){if((T===45||rn(T))&&r++<63){const _=T===45?b:E;return e.consume(T),_}return n(T)}}const su={partial:!0,tokenize:lO};function lO(e,t,n){return r;function r(u){return Ke(u)?Xe(e,o,"linePrefix")(u):o(u)}function o(u){return u===null||Re(u)?t(u):n(u)}}const UE={continuation:{tokenize:fO},exit:dO,name:"blockQuote",tokenize:cO};function cO(e,t,n){const r=this;return o;function o(a){if(a===62){const c=r.containerState;return c.open||(e.enter("blockQuote",{_container:!0}),c.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(a),e.exit("blockQuoteMarker"),u}return n(a)}function u(a){return Ke(a)?(e.enter("blockQuotePrefixWhitespace"),e.consume(a),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(a))}}function fO(e,t,n){const r=this;return o;function o(a){return Ke(a)?Xe(e,u,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a):u(a)}function u(a){return e.attempt(UE,t,n)(a)}}function dO(e){e.exit("blockQuote")}const HE={name:"characterEscape",tokenize:hO};function hO(e,t,n){return r;function r(u){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(u),e.exit("escapeMarker"),o}function o(u){return Z3(u)?(e.enter("characterEscapeValue"),e.consume(u),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(u)}}const zE={name:"characterReference",tokenize:pO};function pO(e,t,n){const r=this;let o=0,u,a;return c;function c(E){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),f}function f(E){return E===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(E),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),u=31,a=rn,m(E))}function h(E){return E===88||E===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(E),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),u=6,a=J3,m):(e.enter("characterReferenceValue"),u=7,a=zd,m(E))}function m(E){if(E===59&&o){const b=e.exit("characterReferenceValue");return a===rn&&!Hd(r.sliceSerialize(b))?n(E):(e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return a(E)&&o++<u?(e.consume(E),m):n(E)}}const jE={partial:!0,tokenize:gO},$E={concrete:!0,name:"codeFenced",tokenize:mO};function mO(e,t,n){const r=this,o={partial:!0,tokenize:q};let u=0,a=0,c;return f;function f(B){return h(B)}function h(B){const te=r.events[r.events.length-1];return u=te&&te[1].type==="linePrefix"?te[2].sliceSerialize(te[1],!0).length:0,c=B,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),m(B)}function m(B){return B===c?(a++,e.consume(B),m):a<3?n(B):(e.exit("codeFencedFenceSequence"),Ke(B)?Xe(e,E,"whitespace")(B):E(B))}function E(B){return B===null||Re(B)?(e.exit("codeFencedFence"),r.interrupt?t(B):e.check(jE,S,G)(B)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(B))}function b(B){return B===null||Re(B)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),E(B)):Ke(B)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Xe(e,T,"whitespace")(B)):B===96&&B===c?n(B):(e.consume(B),b)}function T(B){return B===null||Re(B)?E(B):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),_(B))}function _(B){return B===null||Re(B)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),E(B)):B===96&&B===c?n(B):(e.consume(B),_)}function S(B){return e.attempt(o,G,C)(B)}function C(B){return e.enter("lineEnding"),e.consume(B),e.exit("lineEnding"),k}function k(B){return u>0&&Ke(B)?Xe(e,M,"linePrefix",u+1)(B):M(B)}function M(B){return B===null||Re(B)?e.check(jE,S,G)(B):(e.enter("codeFlowValue"),D(B))}function D(B){return B===null||Re(B)?(e.exit("codeFlowValue"),M(B)):(e.consume(B),D)}function G(B){return e.exit("codeFenced"),t(B)}function q(B,te,Te){let Se=0;return H;function H(ge){return B.enter("lineEnding"),B.consume(ge),B.exit("lineEnding"),fe}function fe(ge){return B.enter("codeFencedFence"),Ke(ge)?Xe(B,de,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(ge):de(ge)}function de(ge){return ge===c?(B.enter("codeFencedFenceSequence"),ue(ge)):Te(ge)}function ue(ge){return ge===c?(Se++,B.consume(ge),ue):Se>=a?(B.exit("codeFencedFenceSequence"),Ke(ge)?Xe(B,ie,"whitespace")(ge):ie(ge)):Te(ge)}function ie(ge){return ge===null||Re(ge)?(B.exit("codeFencedFence"),te(ge)):Te(ge)}}}function gO(e,t,n){const r=this;return o;function o(a){return a===null?n(a):(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),u)}function u(a){return r.parser.lazy[r.now().line]?n(a):t(a)}}const $d={name:"codeIndented",tokenize:yO},EO={partial:!0,tokenize:TO};function yO(e,t,n){const r=this;return o;function o(h){return e.enter("codeIndented"),Xe(e,u,"linePrefix",5)(h)}function u(h){const m=r.events[r.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?a(h):n(h)}function a(h){return h===null?f(h):Re(h)?e.attempt(EO,a,f)(h):(e.enter("codeFlowValue"),c(h))}function c(h){return h===null||Re(h)?(e.exit("codeFlowValue"),a(h)):(e.consume(h),c)}function f(h){return e.exit("codeIndented"),t(h)}}function TO(e,t,n){const r=this;return o;function o(a){return r.parser.lazy[r.now().line]?n(a):Re(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),o):Xe(e,u,"linePrefix",5)(a)}function u(a){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(a):Re(a)?o(a):n(a)}}const bO={name:"codeText",previous:xO,resolve:_O,tokenize:SO};function _O(e){let t=e.length-4,n=3,r,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)o===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(o=r):(r===t||e[r][1].type==="lineEnding")&&(e[o][1].type="codeTextData",r!==o+2&&(e[o][1].end=e[r-1][1].end,e.splice(o+2,r-o-2),t-=r-o-2,r=o+2),o=void 0);return e}function xO(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function SO(e,t,n){let r=0,o,u;return a;function a(E){return e.enter("codeText"),e.enter("codeTextSequence"),c(E)}function c(E){return E===96?(e.consume(E),r++,c):(e.exit("codeTextSequence"),f(E))}function f(E){return E===null?n(E):E===32?(e.enter("space"),e.consume(E),e.exit("space"),f):E===96?(u=e.enter("codeTextSequence"),o=0,m(E)):Re(E)?(e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),f):(e.enter("codeTextData"),h(E))}function h(E){return E===null||E===32||E===96||Re(E)?(e.exit("codeTextData"),f(E)):(e.consume(E),h)}function m(E){return E===96?(e.consume(E),o++,m):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(E)):(u.type="codeTextData",h(E))}}class wO{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n==null?Number.POSITIVE_INFINITY:n;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const o=n||0;this.setCursor(Math.trunc(t));const u=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return r&&ou(this.left,r),u.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),ou(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),ou(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);ou(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);ou(this.left,n.reverse())}}}function ou(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function VE(e){const t={};let n=-1,r,o,u,a,c,f,h;const m=new wO(e);for(;++n<m.length;){for(;n in t;)n=t[n];if(r=m.get(n),n&&r[1].type==="chunkFlow"&&m.get(n-1)[1].type==="listItemPrefix"&&(f=r[1]._tokenizer.events,u=0,u<f.length&&f[u][1].type==="lineEndingBlank"&&(u+=2),u<f.length&&f[u][1].type==="content"))for(;++u<f.length&&f[u][1].type!=="content";)f[u][1].type==="chunkText"&&(f[u][1]._isInFirstContentOfListItem=!0,u++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,CO(m,n)),n=t[n],h=!0);else if(r[1]._container){for(u=n,o=void 0;u--;)if(a=m.get(u),a[1].type==="lineEnding"||a[1].type==="lineEndingBlank")a[0]==="enter"&&(o&&(m.get(o)[1].type="lineEndingBlank"),a[1].type="lineEnding",o=u);else if(!(a[1].type==="linePrefix"||a[1].type==="listItemIndent"))break;o&&(r[1].end=U({},m.get(o)[1].start),c=m.slice(o,n),c.unshift(r),m.splice(o,n-o+1,c))}}return Ln(e,0,Number.POSITIVE_INFINITY,m.slice(0)),!h}function CO(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const u=[];let a=n._tokenizer;a||(a=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(a._contentTypeTextTrailing=!0));const c=a.events,f=[],h={};let m,E,b=-1,T=n,_=0,S=0;const C=[S];for(;T;){for(;e.get(++o)[1]!==T;);u.push(o),T._tokenizer||(m=r.sliceStream(T),T.next||m.push(null),E&&a.defineSkip(T.start),T._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(m),T._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),E=T,T=T.next}for(T=n;++b<c.length;)c[b][0]==="exit"&&c[b-1][0]==="enter"&&c[b][1].type===c[b-1][1].type&&c[b][1].start.line!==c[b][1].end.line&&(S=b+1,C.push(S),T._tokenizer=void 0,T.previous=void 0,T=T.next);for(a.events=[],T?(T._tokenizer=void 0,T.previous=void 0):C.pop(),b=C.length;b--;){const k=c.slice(C[b],C[b+1]),M=u.pop();f.push([M,M+k.length-1]),e.splice(M,2,k)}for(f.reverse(),b=-1;++b<f.length;)h[_+f[b][0]]=_+f[b][1],_+=f[b][1]-f[b][0]-1;return h}const AO={resolve:kO,tokenize:NO},vO={partial:!0,tokenize:OO};function kO(e){return VE(e),e}function NO(e,t){let n;return r;function r(c){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),o(c)}function o(c){return c===null?u(c):Re(c)?e.check(vO,a,u)(c):(e.consume(c),o)}function u(c){return e.exit("chunkContent"),e.exit("content"),t(c)}function a(c){return e.consume(c),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,o}}function OO(e,t,n){const r=this;return o;function o(a){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),Xe(e,u,"linePrefix")}function u(a){if(a===null||Re(a))return n(a);const c=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(a):e.interrupt(r.parser.constructs.flow,n,t)(a)}}function qE(e,t,n,r,o,u,a,c,f){const h=f||Number.POSITIVE_INFINITY;let m=0;return E;function E(k){return k===60?(e.enter(r),e.enter(o),e.enter(u),e.consume(k),e.exit(u),b):k===null||k===32||k===41||cl(k)?n(k):(e.enter(r),e.enter(a),e.enter(c),e.enter("chunkString",{contentType:"string"}),S(k))}function b(k){return k===62?(e.enter(u),e.consume(k),e.exit(u),e.exit(o),e.exit(r),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),T(k))}function T(k){return k===62?(e.exit("chunkString"),e.exit(c),b(k)):k===null||k===60||Re(k)?n(k):(e.consume(k),k===92?_:T)}function _(k){return k===60||k===62||k===92?(e.consume(k),T):T(k)}function S(k){return!m&&(k===null||k===41||at(k))?(e.exit("chunkString"),e.exit(c),e.exit(a),e.exit(r),t(k)):m<h&&k===40?(e.consume(k),m++,S):k===41?(e.consume(k),m--,S):k===null||k===32||k===40||cl(k)?n(k):(e.consume(k),k===92?C:S)}function C(k){return k===40||k===41||k===92?(e.consume(k),S):S(k)}}function YE(e,t,n,r,o,u){const a=this;let c=0,f;return h;function h(T){return e.enter(r),e.enter(o),e.consume(T),e.exit(o),e.enter(u),m}function m(T){return c>999||T===null||T===91||T===93&&!f||T===94&&!c&&"_hiddenFootnoteSupport"in a.parser.constructs?n(T):T===93?(e.exit(u),e.enter(o),e.consume(T),e.exit(o),e.exit(r),t):Re(T)?(e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),E(T))}function E(T){return T===null||T===91||T===93||Re(T)||c++>999?(e.exit("chunkString"),m(T)):(e.consume(T),f||(f=!Ke(T)),T===92?b:E)}function b(T){return T===91||T===92||T===93?(e.consume(T),c++,E):E(T)}}function WE(e,t,n,r,o,u){let a;return c;function c(b){return b===34||b===39||b===40?(e.enter(r),e.enter(o),e.consume(b),e.exit(o),a=b===40?41:b,f):n(b)}function f(b){return b===a?(e.enter(o),e.consume(b),e.exit(o),e.exit(r),t):(e.enter(u),h(b))}function h(b){return b===a?(e.exit(u),f(a)):b===null?n(b):Re(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Xe(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(b))}function m(b){return b===a||b===null||Re(b)?(e.exit("chunkString"),h(b)):(e.consume(b),b===92?E:m)}function E(b){return b===a||b===92?(e.consume(b),m):m(b)}}function uu(e,t){let n;return r;function r(o){return Re(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):Ke(o)?Xe(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}const IO={name:"definition",tokenize:RO},PO={partial:!0,tokenize:LO};function RO(e,t,n){const r=this;let o;return u;function u(T){return e.enter("definition"),a(T)}function a(T){return YE.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(T)}function c(T){return o=fr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),T===58?(e.enter("definitionMarker"),e.consume(T),e.exit("definitionMarker"),f):n(T)}function f(T){return at(T)?uu(e,h)(T):h(T)}function h(T){return qE(e,m,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(T)}function m(T){return e.attempt(PO,E,E)(T)}function E(T){return Ke(T)?Xe(e,b,"whitespace")(T):b(T)}function b(T){return T===null||Re(T)?(e.exit("definition"),r.parser.defined.push(o),t(T)):n(T)}}function LO(e,t,n){return r;function r(c){return at(c)?uu(e,o)(c):n(c)}function o(c){return WE(e,u,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function u(c){return Ke(c)?Xe(e,a,"whitespace")(c):a(c)}function a(c){return c===null||Re(c)?t(c):n(c)}}const DO={name:"hardBreakEscape",tokenize:FO};function FO(e,t,n){return r;function r(u){return e.enter("hardBreakEscape"),e.consume(u),o}function o(u){return Re(u)?(e.exit("hardBreakEscape"),t(u)):n(u)}}const MO={name:"headingAtx",resolve:BO,tokenize:UO};function BO(e,t){let n=e.length-2,r=3,o,u;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(o={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},u={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Ln(e,r,n-r+1,[["enter",o,t],["enter",u,t],["exit",u,t],["exit",o,t]])),e}function UO(e,t,n){let r=0;return o;function o(m){return e.enter("atxHeading"),u(m)}function u(m){return e.enter("atxHeadingSequence"),a(m)}function a(m){return m===35&&r++<6?(e.consume(m),a):m===null||at(m)?(e.exit("atxHeadingSequence"),c(m)):n(m)}function c(m){return m===35?(e.enter("atxHeadingSequence"),f(m)):m===null||Re(m)?(e.exit("atxHeading"),t(m)):Ke(m)?Xe(e,c,"whitespace")(m):(e.enter("atxHeadingText"),h(m))}function f(m){return m===35?(e.consume(m),f):(e.exit("atxHeadingSequence"),c(m))}function h(m){return m===null||m===35||at(m)?(e.exit("atxHeadingText"),c(m)):(e.consume(m),h)}}const HO=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],GE=["pre","script","style","textarea"],zO={concrete:!0,name:"htmlFlow",resolveTo:VO,tokenize:qO},jO={partial:!0,tokenize:WO},$O={partial:!0,tokenize:YO};function VO(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function qO(e,t,n){const r=this;let o,u,a,c,f;return h;function h(N){return m(N)}function m(N){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(N),E}function E(N){return N===33?(e.consume(N),b):N===47?(e.consume(N),u=!0,S):N===63?(e.consume(N),o=3,r.interrupt?t:w):dn(N)?(e.consume(N),a=String.fromCharCode(N),C):n(N)}function b(N){return N===45?(e.consume(N),o=2,T):N===91?(e.consume(N),o=5,c=0,_):dn(N)?(e.consume(N),o=4,r.interrupt?t:w):n(N)}function T(N){return N===45?(e.consume(N),r.interrupt?t:w):n(N)}function _(N){const _e="CDATA[";return N===_e.charCodeAt(c++)?(e.consume(N),c===_e.length?r.interrupt?t:de:_):n(N)}function S(N){return dn(N)?(e.consume(N),a=String.fromCharCode(N),C):n(N)}function C(N){if(N===null||N===47||N===62||at(N)){const _e=N===47,Me=a.toLowerCase();return!_e&&!u&&GE.includes(Me)?(o=1,r.interrupt?t(N):de(N)):HO.includes(a.toLowerCase())?(o=6,_e?(e.consume(N),k):r.interrupt?t(N):de(N)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(N):u?M(N):D(N))}return N===45||rn(N)?(e.consume(N),a+=String.fromCharCode(N),C):n(N)}function k(N){return N===62?(e.consume(N),r.interrupt?t:de):n(N)}function M(N){return Ke(N)?(e.consume(N),M):H(N)}function D(N){return N===47?(e.consume(N),H):N===58||N===95||dn(N)?(e.consume(N),G):Ke(N)?(e.consume(N),D):H(N)}function G(N){return N===45||N===46||N===58||N===95||rn(N)?(e.consume(N),G):q(N)}function q(N){return N===61?(e.consume(N),B):Ke(N)?(e.consume(N),q):D(N)}function B(N){return N===null||N===60||N===61||N===62||N===96?n(N):N===34||N===39?(e.consume(N),f=N,te):Ke(N)?(e.consume(N),B):Te(N)}function te(N){return N===f?(e.consume(N),f=null,Se):N===null||Re(N)?n(N):(e.consume(N),te)}function Te(N){return N===null||N===34||N===39||N===47||N===60||N===61||N===62||N===96||at(N)?q(N):(e.consume(N),Te)}function Se(N){return N===47||N===62||Ke(N)?D(N):n(N)}function H(N){return N===62?(e.consume(N),fe):n(N)}function fe(N){return N===null||Re(N)?de(N):Ke(N)?(e.consume(N),fe):n(N)}function de(N){return N===45&&o===2?(e.consume(N),we):N===60&&o===1?(e.consume(N),ae):N===62&&o===4?(e.consume(N),R):N===63&&o===3?(e.consume(N),w):N===93&&o===5?(e.consume(N),ee):Re(N)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(jO,Q,ue)(N)):N===null||Re(N)?(e.exit("htmlFlowData"),ue(N)):(e.consume(N),de)}function ue(N){return e.check($O,ie,Q)(N)}function ie(N){return e.enter("lineEnding"),e.consume(N),e.exit("lineEnding"),ge}function ge(N){return N===null||Re(N)?ue(N):(e.enter("htmlFlowData"),de(N))}function we(N){return N===45?(e.consume(N),w):de(N)}function ae(N){return N===47?(e.consume(N),a="",V):de(N)}function V(N){if(N===62){const _e=a.toLowerCase();return GE.includes(_e)?(e.consume(N),R):de(N)}return dn(N)&&a.length<8?(e.consume(N),a+=String.fromCharCode(N),V):de(N)}function ee(N){return N===93?(e.consume(N),w):de(N)}function w(N){return N===62?(e.consume(N),R):N===45&&o===2?(e.consume(N),w):de(N)}function R(N){return N===null||Re(N)?(e.exit("htmlFlowData"),Q(N)):(e.consume(N),R)}function Q(N){return e.exit("htmlFlow"),t(N)}}function YO(e,t,n){const r=this;return o;function o(a){return Re(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),u):n(a)}function u(a){return r.parser.lazy[r.now().line]?n(a):t(a)}}function WO(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(su,t,n)}}const GO={name:"htmlText",tokenize:KO};function KO(e,t,n){const r=this;let o,u,a;return c;function c(w){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(w),f}function f(w){return w===33?(e.consume(w),h):w===47?(e.consume(w),q):w===63?(e.consume(w),D):dn(w)?(e.consume(w),Te):n(w)}function h(w){return w===45?(e.consume(w),m):w===91?(e.consume(w),u=0,_):dn(w)?(e.consume(w),M):n(w)}function m(w){return w===45?(e.consume(w),T):n(w)}function E(w){return w===null?n(w):w===45?(e.consume(w),b):Re(w)?(a=E,ae(w)):(e.consume(w),E)}function b(w){return w===45?(e.consume(w),T):E(w)}function T(w){return w===62?we(w):w===45?b(w):E(w)}function _(w){const R="CDATA[";return w===R.charCodeAt(u++)?(e.consume(w),u===R.length?S:_):n(w)}function S(w){return w===null?n(w):w===93?(e.consume(w),C):Re(w)?(a=S,ae(w)):(e.consume(w),S)}function C(w){return w===93?(e.consume(w),k):S(w)}function k(w){return w===62?we(w):w===93?(e.consume(w),k):S(w)}function M(w){return w===null||w===62?we(w):Re(w)?(a=M,ae(w)):(e.consume(w),M)}function D(w){return w===null?n(w):w===63?(e.consume(w),G):Re(w)?(a=D,ae(w)):(e.consume(w),D)}function G(w){return w===62?we(w):D(w)}function q(w){return dn(w)?(e.consume(w),B):n(w)}function B(w){return w===45||rn(w)?(e.consume(w),B):te(w)}function te(w){return Re(w)?(a=te,ae(w)):Ke(w)?(e.consume(w),te):we(w)}function Te(w){return w===45||rn(w)?(e.consume(w),Te):w===47||w===62||at(w)?Se(w):n(w)}function Se(w){return w===47?(e.consume(w),we):w===58||w===95||dn(w)?(e.consume(w),H):Re(w)?(a=Se,ae(w)):Ke(w)?(e.consume(w),Se):we(w)}function H(w){return w===45||w===46||w===58||w===95||rn(w)?(e.consume(w),H):fe(w)}function fe(w){return w===61?(e.consume(w),de):Re(w)?(a=fe,ae(w)):Ke(w)?(e.consume(w),fe):Se(w)}function de(w){return w===null||w===60||w===61||w===62||w===96?n(w):w===34||w===39?(e.consume(w),o=w,ue):Re(w)?(a=de,ae(w)):Ke(w)?(e.consume(w),de):(e.consume(w),ie)}function ue(w){return w===o?(e.consume(w),o=void 0,ge):w===null?n(w):Re(w)?(a=ue,ae(w)):(e.consume(w),ue)}function ie(w){return w===null||w===34||w===39||w===60||w===61||w===96?n(w):w===47||w===62||at(w)?Se(w):(e.consume(w),ie)}function ge(w){return w===47||w===62||at(w)?Se(w):n(w)}function we(w){return w===62?(e.consume(w),e.exit("htmlTextData"),e.exit("htmlText"),t):n(w)}function ae(w){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),V}function V(w){return Ke(w)?Xe(e,ee,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(w):ee(w)}function ee(w){return e.enter("htmlTextData"),a(w)}}const Vd={name:"labelEnd",resolveAll:ZO,resolveTo:eI,tokenize:tI},QO={tokenize:nI},XO={tokenize:rI},JO={tokenize:iI};function ZO(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const o=r.type==="labelImage"?4:2;r.type="data",t+=o}}return e.length!==n.length&&Ln(e,0,e.length,n),e}function eI(e,t){let n=e.length,r=0,o,u,a,c;for(;n--;)if(o=e[n][1],u){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[n][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(a){if(e[n][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(u=n,o.type!=="labelLink")){r=2;break}}else o.type==="labelEnd"&&(a=n);const f={type:e[u][1].type==="labelLink"?"link":"image",start:U({},e[u][1].start),end:U({},e[e.length-1][1].end)},h={type:"label",start:U({},e[u][1].start),end:U({},e[a][1].end)},m={type:"labelText",start:U({},e[u+r+2][1].end),end:U({},e[a-2][1].start)};return c=[["enter",f,t],["enter",h,t]],c=Vn(c,e.slice(u+1,u+r+3)),c=Vn(c,[["enter",m,t]]),c=Vn(c,dl(t.parser.constructs.insideSpan.null,e.slice(u+r+4,a-3),t)),c=Vn(c,[["exit",m,t],e[a-2],e[a-1],["exit",h,t]]),c=Vn(c,e.slice(a+1)),c=Vn(c,[["exit",f,t]]),Ln(e,u,e.length,c),e}function tI(e,t,n){const r=this;let o=r.events.length,u,a;for(;o--;)if((r.events[o][1].type==="labelImage"||r.events[o][1].type==="labelLink")&&!r.events[o][1]._balanced){u=r.events[o][1];break}return c;function c(b){return u?u._inactive?E(b):(a=r.parser.defined.includes(fr(r.sliceSerialize({start:u.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),f):n(b)}function f(b){return b===40?e.attempt(QO,m,a?m:E)(b):b===91?e.attempt(XO,m,a?h:E)(b):a?m(b):E(b)}function h(b){return e.attempt(JO,m,E)(b)}function m(b){return t(b)}function E(b){return u._balanced=!0,n(b)}}function nI(e,t,n){return r;function r(E){return e.enter("resource"),e.enter("resourceMarker"),e.consume(E),e.exit("resourceMarker"),o}function o(E){return at(E)?uu(e,u)(E):u(E)}function u(E){return E===41?m(E):qE(e,a,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function a(E){return at(E)?uu(e,f)(E):m(E)}function c(E){return n(E)}function f(E){return E===34||E===39||E===40?WE(e,h,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(E):m(E)}function h(E){return at(E)?uu(e,m)(E):m(E)}function m(E){return E===41?(e.enter("resourceMarker"),e.consume(E),e.exit("resourceMarker"),e.exit("resource"),t):n(E)}}function rI(e,t,n){const r=this;return o;function o(c){return YE.call(r,e,u,a,"reference","referenceMarker","referenceString")(c)}function u(c){return r.parser.defined.includes(fr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(c):n(c)}function a(c){return n(c)}}function iI(e,t,n){return r;function r(u){return e.enter("reference"),e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),o}function o(u){return u===93?(e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),e.exit("reference"),t):n(u)}}const sI={name:"labelStartImage",resolveAll:Vd.resolveAll,tokenize:oI};function oI(e,t,n){const r=this;return o;function o(c){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(c),e.exit("labelImageMarker"),u}function u(c){return c===91?(e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelImage"),a):n(c)}function a(c){return c===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(c):t(c)}}const uI={name:"labelStartLink",resolveAll:Vd.resolveAll,tokenize:aI};function aI(e,t,n){const r=this;return o;function o(a){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(a),e.exit("labelMarker"),e.exit("labelLink"),u}function u(a){return a===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(a):t(a)}}const qd={name:"lineEnding",tokenize:lI};function lI(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Xe(e,t,"linePrefix")}}const hl={name:"thematicBreak",tokenize:cI};function cI(e,t,n){let r=0,o;return u;function u(h){return e.enter("thematicBreak"),a(h)}function a(h){return o=h,c(h)}function c(h){return h===o?(e.enter("thematicBreakSequence"),f(h)):r>=3&&(h===null||Re(h))?(e.exit("thematicBreak"),t(h)):n(h)}function f(h){return h===o?(e.consume(h),r++,f):(e.exit("thematicBreakSequence"),Ke(h)?Xe(e,c,"whitespace")(h):c(h))}}const xn={continuation:{tokenize:pI},exit:gI,name:"list",tokenize:hI},fI={partial:!0,tokenize:EI},dI={partial:!0,tokenize:mI};function hI(e,t,n){const r=this,o=r.events[r.events.length-1];let u=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,a=0;return c;function c(T){const _=r.containerState.type||(T===42||T===43||T===45?"listUnordered":"listOrdered");if(_==="listUnordered"?!r.containerState.marker||T===r.containerState.marker:zd(T)){if(r.containerState.type||(r.containerState.type=_,e.enter(_,{_container:!0})),_==="listUnordered")return e.enter("listItemPrefix"),T===42||T===45?e.check(hl,n,h)(T):h(T);if(!r.interrupt||T===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),f(T)}return n(T)}function f(T){return zd(T)&&++a<10?(e.consume(T),f):(!r.interrupt||a<2)&&(r.containerState.marker?T===r.containerState.marker:T===41||T===46)?(e.exit("listItemValue"),h(T)):n(T)}function h(T){return e.enter("listItemMarker"),e.consume(T),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||T,e.check(su,r.interrupt?n:m,e.attempt(fI,b,E))}function m(T){return r.containerState.initialBlankLine=!0,u++,b(T)}function E(T){return Ke(T)?(e.enter("listItemPrefixWhitespace"),e.consume(T),e.exit("listItemPrefixWhitespace"),b):n(T)}function b(T){return r.containerState.size=u+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(T)}}function pI(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(su,o,u);function o(c){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Xe(e,t,"listItemIndent",r.containerState.size+1)(c)}function u(c){return r.containerState.furtherBlankLines||!Ke(c)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,a(c)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(dI,t,a)(c))}function a(c){return r.containerState._closeFlow=!0,r.interrupt=void 0,Xe(e,e.attempt(xn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function mI(e,t,n){const r=this;return Xe(e,o,"listItemIndent",r.containerState.size+1);function o(u){const a=r.events[r.events.length-1];return a&&a[1].type==="listItemIndent"&&a[2].sliceSerialize(a[1],!0).length===r.containerState.size?t(u):n(u)}}function gI(e){e.exit(this.containerState.type)}function EI(e,t,n){const r=this;return Xe(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(u){const a=r.events[r.events.length-1];return!Ke(u)&&a&&a[1].type==="listItemPrefixWhitespace"?t(u):n(u)}}const KE={name:"setextUnderline",resolveTo:yI,tokenize:TI};function yI(e,t){let n=e.length,r,o,u;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!u&&e[n][1].type==="definition"&&(u=n);const a={type:"setextHeading",start:U({},e[r][1].start),end:U({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",u?(e.splice(o,0,["enter",a,t]),e.splice(u+1,0,["exit",e[r][1],t]),e[r][1].end=U({},e[u][1].end)):e[r][1]=a,e.push(["exit",a,t]),e}function TI(e,t,n){const r=this;let o;return u;function u(h){let m=r.events.length,E;for(;m--;)if(r.events[m][1].type!=="lineEnding"&&r.events[m][1].type!=="linePrefix"&&r.events[m][1].type!=="content"){E=r.events[m][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||E)?(e.enter("setextHeadingLine"),o=h,a(h)):n(h)}function a(h){return e.enter("setextHeadingLineSequence"),c(h)}function c(h){return h===o?(e.consume(h),c):(e.exit("setextHeadingLineSequence"),Ke(h)?Xe(e,f,"lineSuffix")(h):f(h))}function f(h){return h===null||Re(h)?(e.exit("setextHeadingLine"),t(h)):n(h)}}const bI={tokenize:_I};function _I(e){const t=this,n=e.attempt(su,r,e.attempt(this.parser.constructs.flowInitial,o,Xe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(AO,o)),"linePrefix")));return n;function r(u){if(u===null){e.consume(u);return}return e.enter("lineEndingBlank"),e.consume(u),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(u){if(u===null){e.consume(u);return}return e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const xI={resolveAll:XE()},SI=QE("string"),wI=QE("text");function QE(e){return{resolveAll:XE(e==="text"?CI:void 0),tokenize:t};function t(n){const r=this,o=this.parser.constructs[e],u=n.attempt(o,a,c);return a;function a(m){return h(m)?u(m):c(m)}function c(m){if(m===null){n.consume(m);return}return n.enter("data"),n.consume(m),f}function f(m){return h(m)?(n.exit("data"),u(m)):(n.consume(m),f)}function h(m){if(m===null)return!0;const E=o[m];let b=-1;if(E)for(;++b<E.length;){const T=E[b];if(!T.previous||T.previous.call(r,r.previous))return!0}return!1}}}function XE(e){return t;function t(n,r){let o=-1,u;for(;++o<=n.length;)u===void 0?n[o]&&n[o][1].type==="data"&&(u=o,o++):(!n[o]||n[o][1].type!=="data")&&(o!==u+2&&(n[u][1].end=n[o-1][1].end,n.splice(u+2,o-u-2),o=u+2),u=void 0);return e?e(n,r):n}}function CI(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],o=t.sliceStream(r);let u=o.length,a=-1,c=0,f;for(;u--;){const h=o[u];if(typeof h=="string"){for(a=h.length;h.charCodeAt(a-1)===32;)c++,a--;if(a)break;a=-1}else if(h===-2)f=!0,c++;else if(h!==-1){u++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(c=0),c){const h={type:n===e.length||f||c<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:u?a:r.start._bufferIndex+a,_index:r.start._index+u,line:r.end.line,column:r.end.column-c,offset:r.end.offset-c},end:U({},r.end)};r.end=U({},h.start),r.start.offset===r.end.offset?Object.assign(r,h):(e.splice(n,0,["enter",h,t],["exit",h,t]),n+=2)}n++}return e}const AI=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:IO},disable:{null:[]},document:{42:xn,43:xn,45:xn,48:xn,49:xn,50:xn,51:xn,52:xn,53:xn,54:xn,55:xn,56:xn,57:xn,62:UE},flow:{35:MO,42:hl,45:[KE,hl],60:zO,61:KE,95:hl,96:$E,126:$E},flowInitial:{[-2]:$d,[-1]:$d,32:$d},insideSpan:{null:[jd,xI]},string:{38:zE,92:HE},text:{[-5]:qd,[-4]:qd,[-3]:qd,33:sI,38:zE,42:jd,60:[uO,GO],91:uI,92:[DO,HE],93:Vd,95:jd,96:bO}},Symbol.toStringTag,{value:"Module"}));function vI(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const o={},u=[];let a=[],c=[];const f={attempt:te(q),check:te(B),consume:M,enter:D,exit:G,interrupt:te(B,{interrupt:!0})},h={code:null,containerState:{},defineSkip:S,events:[],now:_,parser:e,previous:null,sliceSerialize:b,sliceStream:T,write:E};let m=t.tokenize.call(h,f);return t.resolveAll&&u.push(t),h;function E(fe){return a=Vn(a,fe),C(),a[a.length-1]!==null?[]:(Te(t,0),h.events=dl(u,h.events,h),h.events)}function b(fe,de){return NI(T(fe),de)}function T(fe){return kI(a,fe)}function _(){const{_bufferIndex:fe,_index:de,line:ue,column:ie,offset:ge}=r;return{_bufferIndex:fe,_index:de,line:ue,column:ie,offset:ge}}function S(fe){o[fe.line]=fe.column,H()}function C(){let fe;for(;r._index<a.length;){const de=a[r._index];if(typeof de=="string")for(fe=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===fe&&r._bufferIndex<de.length;)k(de.charCodeAt(r._bufferIndex));else k(de)}}function k(fe){m=m(fe)}function M(fe){Re(fe)?(r.line++,r.column=1,r.offset+=fe===-3?2:1,H()):fe!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++)),h.previous=fe}function D(fe,de){const ue=de||{};return ue.type=fe,ue.start=_(),h.events.push(["enter",ue,h]),c.push(ue),ue}function G(fe){const de=c.pop();return de.end=_(),h.events.push(["exit",de,h]),de}function q(fe,de){Te(fe,de.from)}function B(fe,de){de.restore()}function te(fe,de){return ue;function ue(ie,ge,we){let ae,V,ee,w;return Array.isArray(ie)?Q(ie):"tokenize"in ie?Q([ie]):R(ie);function R(Ie){return Ye;function Ye(Ve){const Je=Ve!==null&&Ie[Ve],xt=Ve!==null&&Ie.null,be=[...Array.isArray(Je)?Je:Je?[Je]:[],...Array.isArray(xt)?xt:xt?[xt]:[]];return Q(be)(Ve)}}function Q(Ie){return ae=Ie,V=0,Ie.length===0?we:N(Ie[V])}function N(Ie){return Ye;function Ye(Ve){return w=Se(),ee=Ie,Ie.partial||(h.currentConstruct=Ie),Ie.name&&h.parser.constructs.disable.null.includes(Ie.name)?Me():Ie.tokenize.call(de?Object.assign(Object.create(h),de):h,f,_e,Me)(Ve)}}function _e(Ie){return fe(ee,w),ge}function Me(Ie){return w.restore(),++V<ae.length?N(ae[V]):we}}}function Te(fe,de){fe.resolveAll&&!u.includes(fe)&&u.push(fe),fe.resolve&&Ln(h.events,de,h.events.length-de,fe.resolve(h.events.slice(de),h)),fe.resolveTo&&(h.events=fe.resolveTo(h.events,h))}function Se(){const fe=_(),de=h.previous,ue=h.currentConstruct,ie=h.events.length,ge=Array.from(c);return{from:ie,restore:we};function we(){r=fe,h.previous=de,h.currentConstruct=ue,h.events.length=ie,c=ge,H()}}function H(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function kI(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,u=t.end._bufferIndex;let a;if(n===o)a=[e[n].slice(r,u)];else{if(a=e.slice(n,o),r>-1){const c=a[0];typeof c=="string"?a[0]=c.slice(r):a.shift()}u>0&&a.push(e[o].slice(0,u))}return a}function NI(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const u=e[n];let a;if(typeof u=="string")a=u;else switch(u){case-5:{a="\r";break}case-4:{a=`
16
16
  `;break}case-3:{a=`\r
17
- `;break}case-2:{a=t?" ":" ";break}case-1:{if(!t&&o)continue;a=" ";break}default:a=String.fromCharCode(u)}o=u===-2,r.push(a)}return r.join("")}function EI(e){const r={constructs:PE([hI,...(e||{}).extensions||[]]),content:o(z3),defined:[],document:o($3),flow:o(uI),lazy:{},string:o(cI),text:o(fI)};return r;function o(u){return a;function a(c){return pI(r,u,c)}}}function yI(e){for(;!zE(e););return e}const KE=/[\0\t\n\r]/g;function TI(){let e=1,t="",n=!0,r;return o;function o(u,a,c){const f=[];let h,m,E,b,T;for(u=t+(typeof u=="string"?u.toString():new TextDecoder(a||void 0).decode(u)),E=0,t="",n&&(u.charCodeAt(0)===65279&&E++,n=void 0);E<u.length;){if(KE.lastIndex=E,h=KE.exec(u),b=h&&h.index!==void 0?h.index:u.length,T=u.charCodeAt(b),!h){t=u.slice(E);break}if(T===10&&E===b&&r)f.push(-3),r=void 0;else switch(r&&(f.push(-5),r=void 0),E<b&&(f.push(u.slice(E,b)),e+=b-E),T){case 0:{f.push(65533),e++;break}case 9:{for(m=Math.ceil(e/4)*4,f.push(-2);e++<m;)f.push(-1);break}case 10:{f.push(-4),e=1;break}default:r=!0,e=1}E=b+1}return c&&(r&&f.push(-5),t&&f.push(t),f.push(null)),f}}const bI=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function _I(e){return e.replace(bI,xI)}function xI(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),u=o===120||o===88;return RE(n.slice(u?2:1),u?16:10)}return Vd(n)||e}const QE={}.hasOwnProperty;function SI(e,t,n){return typeof t!="string"&&(n=t,t=void 0),wI(n)(yI(EI(n).document().write(TI()(e,t,!0))))}function wI(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:u(Mn),autolinkProtocol:Se,autolinkEmail:Se,atxHeading:u(St),blockQuote:u(xt),characterEscape:Se,characterReference:Se,codeFenced:u(be),codeFencedFenceInfo:a,codeFencedFenceMeta:a,codeIndented:u(be,a),codeText:u(He,a),codeTextData:Se,data:Se,codeFlowValue:Se,definition:u(tt),definitionDestinationString:a,definitionLabelString:a,definitionTitleString:a,emphasis:u(Tt),hardBreakEscape:u(un),hardBreakTrailing:u(un),htmlFlow:u(Wt,a),htmlFlowData:Se,htmlText:u(Wt,a),htmlTextData:Se,image:u(Rt),label:a,link:u(Mn),listItem:u(vt),listItemValue:b,listOrdered:u(ft,E),listUnordered:u(ft),paragraph:u(vu),reference:N,referenceString:a,resourceDestinationString:a,resourceTitleString:a,setextHeading:u(St),strong:u(Hl),thematicBreak:u(jl)},exit:{atxHeading:f(),atxHeadingSequence:q,autolink:f(),autolinkEmail:Je,autolinkProtocol:Ve,blockQuote:f(),characterEscapeValue:H,characterReferenceMarkerHexadecimal:Me,characterReferenceMarkerNumeric:Me,characterReferenceValue:Ie,characterReference:Ye,codeFenced:f(C),codeFencedFence:S,codeFencedFenceInfo:T,codeFencedFenceMeta:_,codeFlowValue:H,codeIndented:f(k),codeText:f(ge),codeTextData:H,data:H,definition:f(),definitionDestinationString:G,definitionLabelString:M,definitionTitleString:D,emphasis:f(),hardBreakEscape:f(de),hardBreakTrailing:f(de),htmlFlow:f(ue),htmlFlowData:H,htmlText:f(ie),htmlTextData:H,image:f(ae),label:ee,labelText:V,lineEnding:fe,link:f(we),listItem:f(),listOrdered:f(),listUnordered:f(),paragraph:f(),referenceString:_e,resourceDestinationString:w,resourceTitleString:R,resource:Q,setextHeading:f(Te),setextHeadingLineSequence:te,setextHeadingText:B,strong:f(),thematicBreak:f()}};XE(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(J){let Ee={type:"root",children:[]};const Be={stack:[Ee],tokenStack:[],config:t,enter:c,exit:h,buffer:a,resume:m,data:n},We=[];let Ze=-1;for(;++Ze<J.length;)if(J[Ze][1].type==="listOrdered"||J[Ze][1].type==="listUnordered")if(J[Ze][0]==="enter")We.push(Ze);else{const Jt=We.pop();Ze=o(J,Jt,Ze)}for(Ze=-1;++Ze<J.length;){const Jt=t[J[Ze][0]];QE.call(Jt,J[Ze][1].type)&&Jt[J[Ze][1].type].call(Object.assign({sliceSerialize:J[Ze][2].sliceSerialize},Be),J[Ze][1])}if(Be.tokenStack.length>0){const Jt=Be.tokenStack[Be.tokenStack.length-1];(Jt[1]||JE).call(Be,void 0,Jt[0])}for(Ee.position={start:pi(J.length>0?J[0][1].start:{line:1,column:1,offset:0}),end:pi(J.length>0?J[J.length-2][1].end:{line:1,column:1,offset:0})},Ze=-1;++Ze<t.transforms.length;)Ee=t.transforms[Ze](Ee)||Ee;return Ee}function o(J,Ee,Be){let We=Ee-1,Ze=-1,Jt=!1,Jr,Kn,yi,ts;for(;++We<=Be;){const Zt=J[We];switch(Zt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Zt[0]==="enter"?Ze++:Ze--,ts=void 0;break}case"lineEndingBlank":{Zt[0]==="enter"&&(Jr&&!ts&&!Ze&&!yi&&(yi=We),ts=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:ts=void 0}if(!Ze&&Zt[0]==="enter"&&Zt[1].type==="listItemPrefix"||Ze===-1&&Zt[0]==="exit"&&(Zt[1].type==="listUnordered"||Zt[1].type==="listOrdered")){if(Jr){let Rr=We;for(Kn=void 0;Rr--;){const Bn=J[Rr];if(Bn[1].type==="lineEnding"||Bn[1].type==="lineEndingBlank"){if(Bn[0]==="exit")continue;Kn&&(J[Kn][1].type="lineEndingBlank",Jt=!0),Bn[1].type="lineEnding",Kn=Rr}else if(!(Bn[1].type==="linePrefix"||Bn[1].type==="blockQuotePrefix"||Bn[1].type==="blockQuotePrefixWhitespace"||Bn[1].type==="blockQuoteMarker"||Bn[1].type==="listItemIndent"))break}yi&&(!Kn||yi<Kn)&&(Jr._spread=!0),Jr.end=Object.assign({},Kn?J[Kn][1].start:Zt[1].end),J.splice(Kn||We,0,["exit",Jr,Zt[2]]),We++,Be++}if(Zt[1].type==="listItemPrefix"){const Rr={type:"listItem",_spread:!1,start:Object.assign({},Zt[1].start),end:void 0};Jr=Rr,J.splice(We,0,["enter",Rr,Zt[2]]),We++,Be++,yi=void 0,ts=!0}}}return J[Ee][1]._spread=Jt,Be}function u(J,Ee){return Be;function Be(We){c.call(this,J(We),We),Ee&&Ee.call(this,We)}}function a(){this.stack.push({type:"fragment",children:[]})}function c(J,Ee,Be){this.stack[this.stack.length-1].children.push(J),this.stack.push(J),this.tokenStack.push([Ee,Be||void 0]),J.position={start:pi(Ee.start),end:void 0}}function f(J){return Ee;function Ee(Be){J&&J.call(this,Be),h.call(this,Be)}}function h(J,Ee){const Be=this.stack.pop(),We=this.tokenStack.pop();if(We)We[0].type!==J.type&&(Ee?Ee.call(this,J,We[0]):(We[1]||JE).call(this,J,We[0]));else throw new Error("Cannot close `"+J.type+"` ("+su({start:J.start,end:J.end})+"): it’s not open");Be.position.end=pi(J.end)}function m(){return $d(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function b(J){if(this.data.expectingFirstListItemValue){const Ee=this.stack[this.stack.length-2];Ee.start=Number.parseInt(this.sliceSerialize(J),10),this.data.expectingFirstListItemValue=void 0}}function T(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.lang=J}function _(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.meta=J}function S(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function C(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function k(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J.replace(/(\r?\n|\r)$/g,"")}function M(J){const Ee=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Ee,Be.identifier=fr(this.sliceSerialize(J)).toLowerCase()}function D(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.title=J}function G(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.url=J}function q(J){const Ee=this.stack[this.stack.length-1];if(!Ee.depth){const Be=this.sliceSerialize(J).length;Ee.depth=Be}}function B(){this.data.setextHeadingSlurpLineEnding=!0}function te(J){const Ee=this.stack[this.stack.length-1];Ee.depth=this.sliceSerialize(J).codePointAt(0)===61?1:2}function Te(){this.data.setextHeadingSlurpLineEnding=void 0}function Se(J){const Be=this.stack[this.stack.length-1].children;let We=Be[Be.length-1];(!We||We.type!=="text")&&(We=zl(),We.position={start:pi(J.start),end:void 0},Be.push(We)),this.stack.push(We)}function H(J){const Ee=this.stack.pop();Ee.value+=this.sliceSerialize(J),Ee.position.end=pi(J.end)}function fe(J){const Ee=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=Ee.children[Ee.children.length-1];Be.position.end=pi(J.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(Ee.type)&&(Se.call(this,J),H.call(this,J))}function de(){this.data.atHardBreak=!0}function ue(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J}function ie(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J}function ge(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J}function we(){const J=this.stack[this.stack.length-1];if(this.data.inReference){const Ee=this.data.referenceType||"shortcut";J.type+="Reference",J.referenceType=Ee,delete J.url,delete J.title}else delete J.identifier,delete J.label;this.data.referenceType=void 0}function ae(){const J=this.stack[this.stack.length-1];if(this.data.inReference){const Ee=this.data.referenceType||"shortcut";J.type+="Reference",J.referenceType=Ee,delete J.url,delete J.title}else delete J.identifier,delete J.label;this.data.referenceType=void 0}function V(J){const Ee=this.sliceSerialize(J),Be=this.stack[this.stack.length-2];Be.label=_I(Ee),Be.identifier=fr(Ee).toLowerCase()}function ee(){const J=this.stack[this.stack.length-1],Ee=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const We=J.children;Be.children=We}else Be.alt=Ee}function w(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.url=J}function R(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.title=J}function Q(){this.data.inReference=void 0}function N(){this.data.referenceType="collapsed"}function _e(J){const Ee=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Ee,Be.identifier=fr(this.sliceSerialize(J)).toLowerCase(),this.data.referenceType="full"}function Me(J){this.data.characterReferenceType=J.type}function Ie(J){const Ee=this.sliceSerialize(J),Be=this.data.characterReferenceType;let We;Be?(We=RE(Ee,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):We=Vd(Ee);const Ze=this.stack[this.stack.length-1];Ze.value+=We}function Ye(J){const Ee=this.stack.pop();Ee.position.end=pi(J.end)}function Ve(J){H.call(this,J);const Ee=this.stack[this.stack.length-1];Ee.url=this.sliceSerialize(J)}function Je(J){H.call(this,J);const Ee=this.stack[this.stack.length-1];Ee.url="mailto:"+this.sliceSerialize(J)}function xt(){return{type:"blockquote",children:[]}}function be(){return{type:"code",lang:null,meta:null,value:""}}function He(){return{type:"inlineCode",value:""}}function tt(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Tt(){return{type:"emphasis",children:[]}}function St(){return{type:"heading",depth:0,children:[]}}function un(){return{type:"break"}}function Wt(){return{type:"html",value:""}}function Rt(){return{type:"image",title:null,url:"",alt:null}}function Mn(){return{type:"link",title:null,url:"",children:[]}}function ft(J){return{type:"list",ordered:J.type==="listOrdered",start:null,spread:J._spread,children:[]}}function vt(J){return{type:"listItem",spread:J._spread,checked:null,children:[]}}function vu(){return{type:"paragraph",children:[]}}function Hl(){return{type:"strong",children:[]}}function zl(){return{type:"text",value:""}}function jl(){return{type:"thematicBreak"}}}function pi(e){return{line:e.line,column:e.column,offset:e.offset}}function XE(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?XE(e,r):CI(e,r)}}function CI(e,t){let n;for(n in t)if(QE.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function JE(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+su({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+su({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+su({start:t.start,end:t.end})+") is still open")}function AI(e){const t=this;t.parser=n;function n(r){return SI(r,ye(U(U({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function vI(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function kI(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
18
- `}]}function NI(e,t){const n=t.value?t.value+`
19
- `:"",r={};t.lang&&(r.className=["language-"+t.lang]);let o={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(o.data={meta:t.meta}),e.patch(t,o),o=e.applyData(t,o),o={type:"element",tagName:"pre",properties:{},children:[o]},e.patch(t,o),o}function OI(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function II(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function PI(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),o=Ys(r.toLowerCase()),u=e.footnoteOrder.indexOf(r);let a,c=e.footnoteCounts.get(r);c===void 0?(c=0,e.footnoteOrder.push(r),a=e.footnoteOrder.length):a=u+1,c+=1,e.footnoteCounts.set(r,c);const f={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(c>1?"-"+c:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(a)}]};e.patch(t,f);const h={type:"element",tagName:"sup",properties:{},children:[f]};return e.patch(t,h),e.applyData(t,h)}function RI(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function LI(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function ZE(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+r}];const o=e.all(t),u=o[0];u&&u.type==="text"?u.value="["+u.value:o.unshift({type:"text",value:"["});const a=o[o.length-1];return a&&a.type==="text"?a.value+=r:o.push({type:"text",value:r}),o}function DI(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return ZE(e,t);const o={src:Ys(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(o.title=r.title);const u={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,u),e.applyData(t,u)}function FI(e,t){const n={src:Ys(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function MI(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function BI(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return ZE(e,t);const o={href:Ys(r.url||"")};r.title!==null&&r.title!==void 0&&(o.title=r.title);const u={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,u),e.applyData(t,u)}function UI(e,t){const n={href:Ys(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function HI(e,t,n){const r=e.all(t),o=n?zI(n):ey(t),u={},a=[];if(typeof t.checked=="boolean"){const m=r[0];let E;m&&m.type==="element"&&m.tagName==="p"?E=m:(E={type:"element",tagName:"p",properties:{},children:[]},r.unshift(E)),E.children.length>0&&E.children.unshift({type:"text",value:" "}),E.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),u.className=["task-list-item"]}let c=-1;for(;++c<r.length;){const m=r[c];(o||c!==0||m.type!=="element"||m.tagName!=="p")&&a.push({type:"text",value:`
17
+ `;break}case-2:{a=t?" ":" ";break}case-1:{if(!t&&o)continue;a=" ";break}default:a=String.fromCharCode(u)}o=u===-2,r.push(a)}return r.join("")}function OI(e){const r={constructs:DE([AI,...(e||{}).extensions||[]]),content:o(eO),defined:[],document:o(nO),flow:o(bI),lazy:{},string:o(SI),text:o(wI)};return r;function o(u){return a;function a(c){return vI(r,u,c)}}}function II(e){for(;!VE(e););return e}const JE=/[\0\t\n\r]/g;function PI(){let e=1,t="",n=!0,r;return o;function o(u,a,c){const f=[];let h,m,E,b,T;for(u=t+(typeof u=="string"?u.toString():new TextDecoder(a||void 0).decode(u)),E=0,t="",n&&(u.charCodeAt(0)===65279&&E++,n=void 0);E<u.length;){if(JE.lastIndex=E,h=JE.exec(u),b=h&&h.index!==void 0?h.index:u.length,T=u.charCodeAt(b),!h){t=u.slice(E);break}if(T===10&&E===b&&r)f.push(-3),r=void 0;else switch(r&&(f.push(-5),r=void 0),E<b&&(f.push(u.slice(E,b)),e+=b-E),T){case 0:{f.push(65533),e++;break}case 9:{for(m=Math.ceil(e/4)*4,f.push(-2);e++<m;)f.push(-1);break}case 10:{f.push(-4),e=1;break}default:r=!0,e=1}E=b+1}return c&&(r&&f.push(-5),t&&f.push(t),f.push(null)),f}}const RI=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function LI(e){return e.replace(RI,DI)}function DI(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),u=o===120||o===88;return FE(n.slice(u?2:1),u?16:10)}return Hd(n)||e}const ZE={}.hasOwnProperty;function FI(e,t,n){return typeof t!="string"&&(n=t,t=void 0),MI(n)(II(OI(n).document().write(PI()(e,t,!0))))}function MI(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:u(Rr),autolinkProtocol:Se,autolinkEmail:Se,atxHeading:u(St),blockQuote:u(xt),characterEscape:Se,characterReference:Se,codeFenced:u(be),codeFencedFenceInfo:a,codeFencedFenceMeta:a,codeIndented:u(be,a),codeText:u(He,a),codeTextData:Se,data:Se,codeFlowValue:Se,definition:u(tt),definitionDestinationString:a,definitionLabelString:a,definitionTitleString:a,emphasis:u(Tt),hardBreakEscape:u(on),hardBreakTrailing:u(on),htmlFlow:u(qt,a),htmlFlowData:Se,htmlText:u(qt,a),htmlTextData:Se,image:u(rt),label:a,link:u(Rr),listItem:u(Yt),listItemValue:b,listOrdered:u(Wn,E),listUnordered:u(Wn),paragraph:u(Cu),reference:N,referenceString:a,resourceDestinationString:a,resourceTitleString:a,setextHeading:u(St),strong:u(Bl),thematicBreak:u(Hl)},exit:{atxHeading:f(),atxHeadingSequence:q,autolink:f(),autolinkEmail:Je,autolinkProtocol:Ve,blockQuote:f(),characterEscapeValue:H,characterReferenceMarkerHexadecimal:Me,characterReferenceMarkerNumeric:Me,characterReferenceValue:Ie,characterReference:Ye,codeFenced:f(C),codeFencedFence:S,codeFencedFenceInfo:T,codeFencedFenceMeta:_,codeFlowValue:H,codeIndented:f(k),codeText:f(ge),codeTextData:H,data:H,definition:f(),definitionDestinationString:G,definitionLabelString:M,definitionTitleString:D,emphasis:f(),hardBreakEscape:f(de),hardBreakTrailing:f(de),htmlFlow:f(ue),htmlFlowData:H,htmlText:f(ie),htmlTextData:H,image:f(ae),label:ee,labelText:V,lineEnding:fe,link:f(we),listItem:f(),listOrdered:f(),listUnordered:f(),paragraph:f(),referenceString:_e,resourceDestinationString:w,resourceTitleString:R,resource:Q,setextHeading:f(Te),setextHeadingLineSequence:te,setextHeadingText:B,strong:f(),thematicBreak:f()}};ey(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(J){let Ee={type:"root",children:[]};const Be={stack:[Ee],tokenStack:[],config:t,enter:c,exit:h,buffer:a,resume:m,data:n},We=[];let Ze=-1;for(;++Ze<J.length;)if(J[Ze][1].type==="listOrdered"||J[Ze][1].type==="listUnordered")if(J[Ze][0]==="enter")We.push(Ze);else{const Qt=We.pop();Ze=o(J,Qt,Ze)}for(Ze=-1;++Ze<J.length;){const Qt=t[J[Ze][0]];ZE.call(Qt,J[Ze][1].type)&&Qt[J[Ze][1].type].call(Object.assign({sliceSerialize:J[Ze][2].sliceSerialize},Be),J[Ze][1])}if(Be.tokenStack.length>0){const Qt=Be.tokenStack[Be.tokenStack.length-1];(Qt[1]||ty).call(Be,void 0,Qt[0])}for(Ee.position={start:pi(J.length>0?J[0][1].start:{line:1,column:1,offset:0}),end:pi(J.length>0?J[J.length-2][1].end:{line:1,column:1,offset:0})},Ze=-1;++Ze<t.transforms.length;)Ee=t.transforms[Ze](Ee)||Ee;return Ee}function o(J,Ee,Be){let We=Ee-1,Ze=-1,Qt=!1,Zr,Gn,yi,ts;for(;++We<=Be;){const Xt=J[We];switch(Xt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Xt[0]==="enter"?Ze++:Ze--,ts=void 0;break}case"lineEndingBlank":{Xt[0]==="enter"&&(Zr&&!ts&&!Ze&&!yi&&(yi=We),ts=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:ts=void 0}if(!Ze&&Xt[0]==="enter"&&Xt[1].type==="listItemPrefix"||Ze===-1&&Xt[0]==="exit"&&(Xt[1].type==="listUnordered"||Xt[1].type==="listOrdered")){if(Zr){let Lr=We;for(Gn=void 0;Lr--;){const Fn=J[Lr];if(Fn[1].type==="lineEnding"||Fn[1].type==="lineEndingBlank"){if(Fn[0]==="exit")continue;Gn&&(J[Gn][1].type="lineEndingBlank",Qt=!0),Fn[1].type="lineEnding",Gn=Lr}else if(!(Fn[1].type==="linePrefix"||Fn[1].type==="blockQuotePrefix"||Fn[1].type==="blockQuotePrefixWhitespace"||Fn[1].type==="blockQuoteMarker"||Fn[1].type==="listItemIndent"))break}yi&&(!Gn||yi<Gn)&&(Zr._spread=!0),Zr.end=Object.assign({},Gn?J[Gn][1].start:Xt[1].end),J.splice(Gn||We,0,["exit",Zr,Xt[2]]),We++,Be++}if(Xt[1].type==="listItemPrefix"){const Lr={type:"listItem",_spread:!1,start:Object.assign({},Xt[1].start),end:void 0};Zr=Lr,J.splice(We,0,["enter",Lr,Xt[2]]),We++,Be++,yi=void 0,ts=!0}}}return J[Ee][1]._spread=Qt,Be}function u(J,Ee){return Be;function Be(We){c.call(this,J(We),We),Ee&&Ee.call(this,We)}}function a(){this.stack.push({type:"fragment",children:[]})}function c(J,Ee,Be){this.stack[this.stack.length-1].children.push(J),this.stack.push(J),this.tokenStack.push([Ee,Be||void 0]),J.position={start:pi(Ee.start),end:void 0}}function f(J){return Ee;function Ee(Be){J&&J.call(this,Be),h.call(this,Be)}}function h(J,Ee){const Be=this.stack.pop(),We=this.tokenStack.pop();if(We)We[0].type!==J.type&&(Ee?Ee.call(this,J,We[0]):(We[1]||ty).call(this,J,We[0]));else throw new Error("Cannot close `"+J.type+"` ("+ru({start:J.start,end:J.end})+"): it’s not open");Be.position.end=pi(J.end)}function m(){return Ud(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function b(J){if(this.data.expectingFirstListItemValue){const Ee=this.stack[this.stack.length-2];Ee.start=Number.parseInt(this.sliceSerialize(J),10),this.data.expectingFirstListItemValue=void 0}}function T(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.lang=J}function _(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.meta=J}function S(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function C(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function k(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J.replace(/(\r?\n|\r)$/g,"")}function M(J){const Ee=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Ee,Be.identifier=fr(this.sliceSerialize(J)).toLowerCase()}function D(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.title=J}function G(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.url=J}function q(J){const Ee=this.stack[this.stack.length-1];if(!Ee.depth){const Be=this.sliceSerialize(J).length;Ee.depth=Be}}function B(){this.data.setextHeadingSlurpLineEnding=!0}function te(J){const Ee=this.stack[this.stack.length-1];Ee.depth=this.sliceSerialize(J).codePointAt(0)===61?1:2}function Te(){this.data.setextHeadingSlurpLineEnding=void 0}function Se(J){const Be=this.stack[this.stack.length-1].children;let We=Be[Be.length-1];(!We||We.type!=="text")&&(We=Ul(),We.position={start:pi(J.start),end:void 0},Be.push(We)),this.stack.push(We)}function H(J){const Ee=this.stack.pop();Ee.value+=this.sliceSerialize(J),Ee.position.end=pi(J.end)}function fe(J){const Ee=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=Ee.children[Ee.children.length-1];Be.position.end=pi(J.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(Ee.type)&&(Se.call(this,J),H.call(this,J))}function de(){this.data.atHardBreak=!0}function ue(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J}function ie(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J}function ge(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.value=J}function we(){const J=this.stack[this.stack.length-1];if(this.data.inReference){const Ee=this.data.referenceType||"shortcut";J.type+="Reference",J.referenceType=Ee,delete J.url,delete J.title}else delete J.identifier,delete J.label;this.data.referenceType=void 0}function ae(){const J=this.stack[this.stack.length-1];if(this.data.inReference){const Ee=this.data.referenceType||"shortcut";J.type+="Reference",J.referenceType=Ee,delete J.url,delete J.title}else delete J.identifier,delete J.label;this.data.referenceType=void 0}function V(J){const Ee=this.sliceSerialize(J),Be=this.stack[this.stack.length-2];Be.label=LI(Ee),Be.identifier=fr(Ee).toLowerCase()}function ee(){const J=this.stack[this.stack.length-1],Ee=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const We=J.children;Be.children=We}else Be.alt=Ee}function w(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.url=J}function R(){const J=this.resume(),Ee=this.stack[this.stack.length-1];Ee.title=J}function Q(){this.data.inReference=void 0}function N(){this.data.referenceType="collapsed"}function _e(J){const Ee=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Ee,Be.identifier=fr(this.sliceSerialize(J)).toLowerCase(),this.data.referenceType="full"}function Me(J){this.data.characterReferenceType=J.type}function Ie(J){const Ee=this.sliceSerialize(J),Be=this.data.characterReferenceType;let We;Be?(We=FE(Ee,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):We=Hd(Ee);const Ze=this.stack[this.stack.length-1];Ze.value+=We}function Ye(J){const Ee=this.stack.pop();Ee.position.end=pi(J.end)}function Ve(J){H.call(this,J);const Ee=this.stack[this.stack.length-1];Ee.url=this.sliceSerialize(J)}function Je(J){H.call(this,J);const Ee=this.stack[this.stack.length-1];Ee.url="mailto:"+this.sliceSerialize(J)}function xt(){return{type:"blockquote",children:[]}}function be(){return{type:"code",lang:null,meta:null,value:""}}function He(){return{type:"inlineCode",value:""}}function tt(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Tt(){return{type:"emphasis",children:[]}}function St(){return{type:"heading",depth:0,children:[]}}function on(){return{type:"break"}}function qt(){return{type:"html",value:""}}function rt(){return{type:"image",title:null,url:"",alt:null}}function Rr(){return{type:"link",title:null,url:"",children:[]}}function Wn(J){return{type:"list",ordered:J.type==="listOrdered",start:null,spread:J._spread,children:[]}}function Yt(J){return{type:"listItem",spread:J._spread,checked:null,children:[]}}function Cu(){return{type:"paragraph",children:[]}}function Bl(){return{type:"strong",children:[]}}function Ul(){return{type:"text",value:""}}function Hl(){return{type:"thematicBreak"}}}function pi(e){return{line:e.line,column:e.column,offset:e.offset}}function ey(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?ey(e,r):BI(e,r)}}function BI(e,t){let n;for(n in t)if(ZE.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function ty(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+ru({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+ru({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+ru({start:t.start,end:t.end})+") is still open")}function UI(e){const t=this;t.parser=n;function n(r){return FI(r,ye(U(U({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function HI(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function zI(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
18
+ `}]}function jI(e,t){const n=t.value?t.value+`
19
+ `:"",r={};t.lang&&(r.className=["language-"+t.lang]);let o={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(o.data={meta:t.meta}),e.patch(t,o),o=e.applyData(t,o),o={type:"element",tagName:"pre",properties:{},children:[o]},e.patch(t,o),o}function $I(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function VI(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function qI(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),o=Vs(r.toLowerCase()),u=e.footnoteOrder.indexOf(r);let a,c=e.footnoteCounts.get(r);c===void 0?(c=0,e.footnoteOrder.push(r),a=e.footnoteOrder.length):a=u+1,c+=1,e.footnoteCounts.set(r,c);const f={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(c>1?"-"+c:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(a)}]};e.patch(t,f);const h={type:"element",tagName:"sup",properties:{},children:[f]};return e.patch(t,h),e.applyData(t,h)}function YI(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function WI(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function ny(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+r}];const o=e.all(t),u=o[0];u&&u.type==="text"?u.value="["+u.value:o.unshift({type:"text",value:"["});const a=o[o.length-1];return a&&a.type==="text"?a.value+=r:o.push({type:"text",value:r}),o}function GI(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return ny(e,t);const o={src:Vs(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(o.title=r.title);const u={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,u),e.applyData(t,u)}function KI(e,t){const n={src:Vs(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function QI(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function XI(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return ny(e,t);const o={href:Vs(r.url||"")};r.title!==null&&r.title!==void 0&&(o.title=r.title);const u={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,u),e.applyData(t,u)}function JI(e,t){const n={href:Vs(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function ZI(e,t,n){const r=e.all(t),o=n?eP(n):ry(t),u={},a=[];if(typeof t.checked=="boolean"){const m=r[0];let E;m&&m.type==="element"&&m.tagName==="p"?E=m:(E={type:"element",tagName:"p",properties:{},children:[]},r.unshift(E)),E.children.length>0&&E.children.unshift({type:"text",value:" "}),E.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),u.className=["task-list-item"]}let c=-1;for(;++c<r.length;){const m=r[c];(o||c!==0||m.type!=="element"||m.tagName!=="p")&&a.push({type:"text",value:`
20
20
  `}),m.type==="element"&&m.tagName==="p"&&!o?a.push(...m.children):a.push(m)}const f=r[r.length-1];f&&(o||f.type!=="element"||f.tagName!=="p")&&a.push({type:"text",value:`
21
- `});const h={type:"element",tagName:"li",properties:u,children:a};return e.patch(t,h),e.applyData(t,h)}function zI(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=ey(n[r])}return t}function ey(e){const t=e.spread;return t==null?e.children.length>1:t}function jI(e,t){const n={},r=e.all(t);let o=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++o<r.length;){const a=r[o];if(a.type==="element"&&a.tagName==="li"&&a.properties&&Array.isArray(a.properties.className)&&a.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const u={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,u),e.applyData(t,u)}function $I(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function VI(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function qI(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function YI(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const a={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],a),o.push(a)}if(n.length>0){const a={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},c=Nr(t.children[1]),f=fl(t.children[t.children.length-1]);c&&f&&(a.position={start:c,end:f}),o.push(a)}const u={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,u),e.applyData(t,u)}function WI(e,t,n){const r=n?n.children:void 0,u=(r?r.indexOf(t):1)===0?"th":"td",a=n&&n.type==="table"?n.align:void 0,c=a?a.length:t.children.length;let f=-1;const h=[];for(;++f<c;){const E=t.children[f],b={},T=a?a[f]:void 0;T&&(b.align=T);let _={type:"element",tagName:u,properties:b,children:[]};E&&(_.children=e.all(E),e.patch(E,_),_=e.applyData(E,_)),h.push(_)}const m={type:"element",tagName:"tr",properties:{},children:e.wrap(h,!0)};return e.patch(t,m),e.applyData(t,m)}function GI(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const ty=9,ny=32;function KI(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const u=[];for(;r;)u.push(ry(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return u.push(ry(t.slice(o),o>0,!1)),u.join("")}function ry(e,t,n){let r=0,o=e.length;if(t){let u=e.codePointAt(r);for(;u===ty||u===ny;)r++,u=e.codePointAt(r)}if(n){let u=e.codePointAt(o-1);for(;u===ty||u===ny;)o--,u=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function QI(e,t){const n={type:"text",value:KI(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function XI(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const JI={blockquote:vI,break:kI,code:NI,delete:OI,emphasis:II,footnoteReference:PI,heading:RI,html:LI,imageReference:DI,image:FI,inlineCode:MI,linkReference:BI,link:UI,listItem:HI,list:jI,paragraph:$I,root:VI,strong:qI,table:YI,tableCell:GI,tableRow:WI,text:QI,thematicBreak:XI,toml:gl,yaml:gl,definition:gl,footnoteDefinition:gl};function gl(){}const iy=-1,El=0,cu=1,yl=2,Qd=3,Xd=4,Jd=5,Zd=6,sy=7,oy=8,uy=typeof self=="object"?self:globalThis,ZI=(e,t)=>{const n=(o,u)=>(e.set(u,o),o),r=o=>{if(e.has(o))return e.get(o);const[u,a]=t[o];switch(u){case El:case iy:return n(a,o);case cu:{const c=n([],o);for(const f of a)c.push(r(f));return c}case yl:{const c=n({},o);for(const[f,h]of a)c[r(f)]=r(h);return c}case Qd:return n(new Date(a),o);case Xd:{const{source:c,flags:f}=a;return n(new RegExp(c,f),o)}case Jd:{const c=n(new Map,o);for(const[f,h]of a)c.set(r(f),r(h));return c}case Zd:{const c=n(new Set,o);for(const f of a)c.add(r(f));return c}case sy:{const{name:c,message:f}=a;return n(new uy[c](f),o)}case oy:return n(BigInt(a),o);case"BigInt":return n(Object(BigInt(a)),o);case"ArrayBuffer":return n(new Uint8Array(a).buffer,a);case"DataView":{const{buffer:c}=new Uint8Array(a);return n(new DataView(c),a)}}return n(new uy[u](a),o)};return r},ay=e=>ZI(new Map,e)(0),Gs="",{toString:eP}={},{keys:tP}=Object,fu=e=>{const t=typeof e;if(t!=="object"||!e)return[El,t];const n=eP.call(e).slice(8,-1);switch(n){case"Array":return[cu,Gs];case"Object":return[yl,Gs];case"Date":return[Qd,Gs];case"RegExp":return[Xd,Gs];case"Map":return[Jd,Gs];case"Set":return[Zd,Gs];case"DataView":return[cu,n]}return n.includes("Array")?[cu,n]:n.includes("Error")?[sy,n]:[yl,n]},Tl=([e,t])=>e===El&&(t==="function"||t==="symbol"),nP=(e,t,n,r)=>{const o=(a,c)=>{const f=r.push(a)-1;return n.set(c,f),f},u=a=>{if(n.has(a))return n.get(a);let[c,f]=fu(a);switch(c){case El:{let m=a;switch(f){case"bigint":c=oy,m=a.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+f);m=null;break;case"undefined":return o([iy],a)}return o([c,m],a)}case cu:{if(f){let b=a;return f==="DataView"?b=new Uint8Array(a.buffer):f==="ArrayBuffer"&&(b=new Uint8Array(a)),o([f,[...b]],a)}const m=[],E=o([c,m],a);for(const b of a)m.push(u(b));return E}case yl:{if(f)switch(f){case"BigInt":return o([f,a.toString()],a);case"Boolean":case"Number":case"String":return o([f,a.valueOf()],a)}if(t&&"toJSON"in a)return u(a.toJSON());const m=[],E=o([c,m],a);for(const b of tP(a))(e||!Tl(fu(a[b])))&&m.push([u(b),u(a[b])]);return E}case Qd:return o([c,a.toISOString()],a);case Xd:{const{source:m,flags:E}=a;return o([c,{source:m,flags:E}],a)}case Jd:{const m=[],E=o([c,m],a);for(const[b,T]of a)(e||!(Tl(fu(b))||Tl(fu(T))))&&m.push([u(b),u(T)]);return E}case Zd:{const m=[],E=o([c,m],a);for(const b of a)(e||!Tl(fu(b)))&&m.push(u(b));return E}}const{message:h}=a;return o([c,{name:f,message:h}],a)};return u},ly=(e,{json:t,lossy:n}={})=>{const r=[];return nP(!(t||n),!!t,new Map,r)(e),r},Ks=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?ay(ly(e,t)):structuredClone(e):(e,t)=>ay(ly(e,t));function rP(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function iP(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function sP(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||rP,r=e.options.footnoteBackLabel||iP,o=e.options.footnoteLabel||"Footnotes",u=e.options.footnoteLabelTagName||"h2",a=e.options.footnoteLabelProperties||{className:["sr-only"]},c=[];let f=-1;for(;++f<e.footnoteOrder.length;){const h=e.footnoteById.get(e.footnoteOrder[f]);if(!h)continue;const m=e.all(h),E=String(h.identifier).toUpperCase(),b=Ys(E.toLowerCase());let T=0;const _=[],S=e.footnoteCounts.get(E);for(;S!==void 0&&++T<=S;){_.length>0&&_.push({type:"text",value:" "});let M=typeof n=="string"?n:n(f,T);typeof M=="string"&&(M={type:"text",value:M}),_.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+b+(T>1?"-"+T:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(f,T),className:["data-footnote-backref"]},children:Array.isArray(M)?M:[M]})}const C=m[m.length-1];if(C&&C.type==="element"&&C.tagName==="p"){const M=C.children[C.children.length-1];M&&M.type==="text"?M.value+=" ":C.children.push({type:"text",value:" "}),C.children.push(..._)}else m.push(..._);const k={type:"element",tagName:"li",properties:{id:t+"fn-"+b},children:e.wrap(m,!0)};e.patch(h,k),c.push(k)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:u,properties:ye(U({},Ks(a)),{id:"footnote-label"}),children:[{type:"text",value:o}]},{type:"text",value:`
21
+ `});const h={type:"element",tagName:"li",properties:u,children:a};return e.patch(t,h),e.applyData(t,h)}function eP(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=ry(n[r])}return t}function ry(e){const t=e.spread;return t==null?e.children.length>1:t}function tP(e,t){const n={},r=e.all(t);let o=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++o<r.length;){const a=r[o];if(a.type==="element"&&a.tagName==="li"&&a.properties&&Array.isArray(a.properties.className)&&a.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const u={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,u),e.applyData(t,u)}function nP(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function rP(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function iP(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function sP(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const a={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],a),o.push(a)}if(n.length>0){const a={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},c=Nr(t.children[1]),f=ll(t.children[t.children.length-1]);c&&f&&(a.position={start:c,end:f}),o.push(a)}const u={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,u),e.applyData(t,u)}function oP(e,t,n){const r=n?n.children:void 0,u=(r?r.indexOf(t):1)===0?"th":"td",a=n&&n.type==="table"?n.align:void 0,c=a?a.length:t.children.length;let f=-1;const h=[];for(;++f<c;){const E=t.children[f],b={},T=a?a[f]:void 0;T&&(b.align=T);let _={type:"element",tagName:u,properties:b,children:[]};E&&(_.children=e.all(E),e.patch(E,_),_=e.applyData(E,_)),h.push(_)}const m={type:"element",tagName:"tr",properties:{},children:e.wrap(h,!0)};return e.patch(t,m),e.applyData(t,m)}function uP(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const iy=9,sy=32;function aP(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const u=[];for(;r;)u.push(oy(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return u.push(oy(t.slice(o),o>0,!1)),u.join("")}function oy(e,t,n){let r=0,o=e.length;if(t){let u=e.codePointAt(r);for(;u===iy||u===sy;)r++,u=e.codePointAt(r)}if(n){let u=e.codePointAt(o-1);for(;u===iy||u===sy;)o--,u=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function lP(e,t){const n={type:"text",value:aP(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function cP(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const fP={blockquote:HI,break:zI,code:jI,delete:$I,emphasis:VI,footnoteReference:qI,heading:YI,html:WI,imageReference:GI,image:KI,inlineCode:QI,linkReference:XI,link:JI,listItem:ZI,list:tP,paragraph:nP,root:rP,strong:iP,table:sP,tableCell:uP,tableRow:oP,text:lP,thematicBreak:cP,toml:pl,yaml:pl,definition:pl,footnoteDefinition:pl};function pl(){}const uy=-1,ml=0,au=1,gl=2,Yd=3,Wd=4,Gd=5,Kd=6,ay=7,ly=8,cy=typeof self=="object"?self:globalThis,dP=(e,t)=>{const n=(o,u)=>(e.set(u,o),o),r=o=>{if(e.has(o))return e.get(o);const[u,a]=t[o];switch(u){case ml:case uy:return n(a,o);case au:{const c=n([],o);for(const f of a)c.push(r(f));return c}case gl:{const c=n({},o);for(const[f,h]of a)c[r(f)]=r(h);return c}case Yd:return n(new Date(a),o);case Wd:{const{source:c,flags:f}=a;return n(new RegExp(c,f),o)}case Gd:{const c=n(new Map,o);for(const[f,h]of a)c.set(r(f),r(h));return c}case Kd:{const c=n(new Set,o);for(const f of a)c.add(r(f));return c}case ay:{const{name:c,message:f}=a;return n(new cy[c](f),o)}case ly:return n(BigInt(a),o);case"BigInt":return n(Object(BigInt(a)),o);case"ArrayBuffer":return n(new Uint8Array(a).buffer,a);case"DataView":{const{buffer:c}=new Uint8Array(a);return n(new DataView(c),a)}}return n(new cy[u](a),o)};return r},fy=e=>dP(new Map,e)(0),Ys="",{toString:hP}={},{keys:pP}=Object,lu=e=>{const t=typeof e;if(t!=="object"||!e)return[ml,t];const n=hP.call(e).slice(8,-1);switch(n){case"Array":return[au,Ys];case"Object":return[gl,Ys];case"Date":return[Yd,Ys];case"RegExp":return[Wd,Ys];case"Map":return[Gd,Ys];case"Set":return[Kd,Ys];case"DataView":return[au,n]}return n.includes("Array")?[au,n]:n.includes("Error")?[ay,n]:[gl,n]},El=([e,t])=>e===ml&&(t==="function"||t==="symbol"),mP=(e,t,n,r)=>{const o=(a,c)=>{const f=r.push(a)-1;return n.set(c,f),f},u=a=>{if(n.has(a))return n.get(a);let[c,f]=lu(a);switch(c){case ml:{let m=a;switch(f){case"bigint":c=ly,m=a.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+f);m=null;break;case"undefined":return o([uy],a)}return o([c,m],a)}case au:{if(f){let b=a;return f==="DataView"?b=new Uint8Array(a.buffer):f==="ArrayBuffer"&&(b=new Uint8Array(a)),o([f,[...b]],a)}const m=[],E=o([c,m],a);for(const b of a)m.push(u(b));return E}case gl:{if(f)switch(f){case"BigInt":return o([f,a.toString()],a);case"Boolean":case"Number":case"String":return o([f,a.valueOf()],a)}if(t&&"toJSON"in a)return u(a.toJSON());const m=[],E=o([c,m],a);for(const b of pP(a))(e||!El(lu(a[b])))&&m.push([u(b),u(a[b])]);return E}case Yd:return o([c,a.toISOString()],a);case Wd:{const{source:m,flags:E}=a;return o([c,{source:m,flags:E}],a)}case Gd:{const m=[],E=o([c,m],a);for(const[b,T]of a)(e||!(El(lu(b))||El(lu(T))))&&m.push([u(b),u(T)]);return E}case Kd:{const m=[],E=o([c,m],a);for(const b of a)(e||!El(lu(b)))&&m.push(u(b));return E}}const{message:h}=a;return o([c,{name:f,message:h}],a)};return u},dy=(e,{json:t,lossy:n}={})=>{const r=[];return mP(!(t||n),!!t,new Map,r)(e),r},Ws=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?fy(dy(e,t)):structuredClone(e):(e,t)=>fy(dy(e,t));function gP(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function EP(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function yP(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||gP,r=e.options.footnoteBackLabel||EP,o=e.options.footnoteLabel||"Footnotes",u=e.options.footnoteLabelTagName||"h2",a=e.options.footnoteLabelProperties||{className:["sr-only"]},c=[];let f=-1;for(;++f<e.footnoteOrder.length;){const h=e.footnoteById.get(e.footnoteOrder[f]);if(!h)continue;const m=e.all(h),E=String(h.identifier).toUpperCase(),b=Vs(E.toLowerCase());let T=0;const _=[],S=e.footnoteCounts.get(E);for(;S!==void 0&&++T<=S;){_.length>0&&_.push({type:"text",value:" "});let M=typeof n=="string"?n:n(f,T);typeof M=="string"&&(M={type:"text",value:M}),_.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+b+(T>1?"-"+T:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(f,T),className:["data-footnote-backref"]},children:Array.isArray(M)?M:[M]})}const C=m[m.length-1];if(C&&C.type==="element"&&C.tagName==="p"){const M=C.children[C.children.length-1];M&&M.type==="text"?M.value+=" ":C.children.push({type:"text",value:" "}),C.children.push(..._)}else m.push(..._);const k={type:"element",tagName:"li",properties:{id:t+"fn-"+b},children:e.wrap(m,!0)};e.patch(h,k),c.push(k)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:u,properties:ye(U({},Ws(a)),{id:"footnote-label"}),children:[{type:"text",value:o}]},{type:"text",value:`
22
22
  `},{type:"element",tagName:"ol",properties:{},children:e.wrap(c,!0)},{type:"text",value:`
23
- `}]}}const bl=function(e){if(e==null)return lP;if(typeof e=="function")return _l(e);if(typeof e=="object")return Array.isArray(e)?oP(e):uP(e);if(typeof e=="string")return aP(e);throw new Error("Expected function, string, or object as test")};function oP(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=bl(e[n]);return _l(r);function r(...o){let u=-1;for(;++u<t.length;)if(t[u].apply(this,o))return!0;return!1}}function uP(e){const t=e;return _l(n);function n(r){const o=r;let u;for(u in e)if(o[u]!==t[u])return!1;return!0}}function aP(e){return _l(t);function t(n){return n&&n.type===e}}function _l(e){return t;function t(n,r,o){return!!(cP(n)&&e.call(this,n,typeof r=="number"?r:void 0,o||void 0))}}function lP(){return!0}function cP(e){return e!==null&&typeof e=="object"&&"type"in e}function iB(e){return e}const cy=[],fP=!0,eh=!1,dP="skip";function fy(e,t,n,r){let o;typeof t=="function"&&typeof n!="function"?(r=n,n=t):o=t;const u=bl(o),a=r?-1:1;c(e,void 0,[])();function c(f,h,m){const E=f&&typeof f=="object"?f:{};if(typeof E.type=="string"){const T=typeof E.tagName=="string"?E.tagName:typeof E.name=="string"?E.name:void 0;Object.defineProperty(b,"name",{value:"node ("+(f.type+(T?"<"+T+">":""))+")"})}return b;function b(){let T=cy,_,S,C;if((!t||u(f,h,m[m.length-1]||void 0))&&(T=hP(n(f,m)),T[0]===eh))return T;if("children"in f&&f.children){const k=f;if(k.children&&T[0]!==dP)for(S=(r?k.children.length:-1)+a,C=m.concat(k);S>-1&&S<k.children.length;){const M=k.children[S];if(_=c(M,S,C)(),_[0]===eh)return _;S=typeof _[1]=="number"?_[1]:S+a}}return T}}}function hP(e){return Array.isArray(e)?e:typeof e=="number"?[fP,e]:e==null?cy:[e]}function xl(e,t,n,r){let o,u,a;typeof t=="function"&&typeof n!="function"?(u=void 0,a=t,o=n):(u=t,a=n,o=r),fy(e,u,c,o);function c(f,h){const m=h[h.length-1],E=m?m.children.indexOf(f):void 0;return a(f,E,m)}}const th={}.hasOwnProperty,pP={};function mP(e,t){const n=t||pP,r=new Map,o=new Map,u=new Map,a=U(U({},JI),n.handlers),c={all:h,applyData:EP,definitionById:r,footnoteById:o,footnoteCounts:u,footnoteOrder:[],handlers:a,one:f,options:n,patch:gP,wrap:TP};return xl(e,function(m){if(m.type==="definition"||m.type==="footnoteDefinition"){const E=m.type==="definition"?r:o,b=String(m.identifier).toUpperCase();E.has(b)||E.set(b,m)}}),c;function f(m,E){const b=m.type,T=c.handlers[b];if(th.call(c.handlers,b)&&T)return T(c,m,E);if(c.options.passThrough&&c.options.passThrough.includes(b)){if("children"in m){const S=m,{children:C}=S,k=Xt(S,["children"]),M=Ks(k);return M.children=c.all(m),M}return Ks(m)}return(c.options.unknownHandler||yP)(c,m,E)}function h(m){const E=[];if("children"in m){const b=m.children;let T=-1;for(;++T<b.length;){const _=c.one(b[T],m);if(_){if(T&&b[T-1].type==="break"&&(!Array.isArray(_)&&_.type==="text"&&(_.value=dy(_.value)),!Array.isArray(_)&&_.type==="element")){const S=_.children[0];S&&S.type==="text"&&(S.value=dy(S.value))}Array.isArray(_)?E.push(..._):E.push(_)}}}return E}}function gP(e,t){e.position&&(t.position=h3(e))}function EP(e,t){let n=t;if(e&&e.data){const r=e.data.hName,o=e.data.hChildren,u=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const a="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:a}}n.type==="element"&&u&&Object.assign(n.properties,Ks(u)),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function yP(e,t){const n=t.data||{},r="value"in t&&!(th.call(n,"hProperties")||th.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function TP(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
23
+ `}]}}const yl=function(e){if(e==null)return xP;if(typeof e=="function")return Tl(e);if(typeof e=="object")return Array.isArray(e)?TP(e):bP(e);if(typeof e=="string")return _P(e);throw new Error("Expected function, string, or object as test")};function TP(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=yl(e[n]);return Tl(r);function r(...o){let u=-1;for(;++u<t.length;)if(t[u].apply(this,o))return!0;return!1}}function bP(e){const t=e;return Tl(n);function n(r){const o=r;let u;for(u in e)if(o[u]!==t[u])return!1;return!0}}function _P(e){return Tl(t);function t(n){return n&&n.type===e}}function Tl(e){return t;function t(n,r,o){return!!(SP(n)&&e.call(this,n,typeof r=="number"?r:void 0,o||void 0))}}function xP(){return!0}function SP(e){return e!==null&&typeof e=="object"&&"type"in e}function nB(e){return e}const hy=[],wP=!0,Qd=!1,CP="skip";function py(e,t,n,r){let o;typeof t=="function"&&typeof n!="function"?(r=n,n=t):o=t;const u=yl(o),a=r?-1:1;c(e,void 0,[])();function c(f,h,m){const E=f&&typeof f=="object"?f:{};if(typeof E.type=="string"){const T=typeof E.tagName=="string"?E.tagName:typeof E.name=="string"?E.name:void 0;Object.defineProperty(b,"name",{value:"node ("+(f.type+(T?"<"+T+">":""))+")"})}return b;function b(){let T=hy,_,S,C;if((!t||u(f,h,m[m.length-1]||void 0))&&(T=AP(n(f,m)),T[0]===Qd))return T;if("children"in f&&f.children){const k=f;if(k.children&&T[0]!==CP)for(S=(r?k.children.length:-1)+a,C=m.concat(k);S>-1&&S<k.children.length;){const M=k.children[S];if(_=c(M,S,C)(),_[0]===Qd)return _;S=typeof _[1]=="number"?_[1]:S+a}}return T}}}function AP(e){return Array.isArray(e)?e:typeof e=="number"?[wP,e]:e==null?hy:[e]}function bl(e,t,n,r){let o,u,a;typeof t=="function"&&typeof n!="function"?(u=void 0,a=t,o=n):(u=t,a=n,o=r),py(e,u,c,o);function c(f,h){const m=h[h.length-1],E=m?m.children.indexOf(f):void 0;return a(f,E,m)}}const Xd={}.hasOwnProperty,vP={};function kP(e,t){const n=t||vP,r=new Map,o=new Map,u=new Map,a=U(U({},fP),n.handlers),c={all:h,applyData:OP,definitionById:r,footnoteById:o,footnoteCounts:u,footnoteOrder:[],handlers:a,one:f,options:n,patch:NP,wrap:PP};return bl(e,function(m){if(m.type==="definition"||m.type==="footnoteDefinition"){const E=m.type==="definition"?r:o,b=String(m.identifier).toUpperCase();E.has(b)||E.set(b,m)}}),c;function f(m,E){const b=m.type,T=c.handlers[b];if(Xd.call(c.handlers,b)&&T)return T(c,m,E);if(c.options.passThrough&&c.options.passThrough.includes(b)){if("children"in m){const S=m,{children:C}=S,k=en(S,["children"]),M=Ws(k);return M.children=c.all(m),M}return Ws(m)}return(c.options.unknownHandler||IP)(c,m,E)}function h(m){const E=[];if("children"in m){const b=m.children;let T=-1;for(;++T<b.length;){const _=c.one(b[T],m);if(_){if(T&&b[T-1].type==="break"&&(!Array.isArray(_)&&_.type==="text"&&(_.value=my(_.value)),!Array.isArray(_)&&_.type==="element")){const S=_.children[0];S&&S.type==="text"&&(S.value=my(S.value))}Array.isArray(_)?E.push(..._):E.push(_)}}}return E}}function NP(e,t){e.position&&(t.position=A3(e))}function OP(e,t){let n=t;if(e&&e.data){const r=e.data.hName,o=e.data.hChildren,u=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const a="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:a}}n.type==="element"&&u&&Object.assign(n.properties,Ws(u)),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function IP(e,t){const n=t.data||{},r="value"in t&&!(Xd.call(n,"hProperties")||Xd.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function PP(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
24
24
  `});++r<e.length;)r&&n.push({type:"text",value:`
25
25
  `}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
26
- `}),n}function dy(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function hy(e,t){const n=mP(e,t),r=n.one(e,void 0),o=sP(n),u=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&u.children.push({type:"text",value:`
27
- `},o),u}function bP(e,t){return e&&"run"in e?function(n,r){return it(this,null,function*(){const o=hy(n,U({file:r},t));yield e.run(o,r)})}:function(n,r){return hy(n,U({file:r},e||t))}}function py(e){if(e)throw e}var nh,my;function _P(){if(my)return nh;my=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=function(h){return typeof Array.isArray=="function"?Array.isArray(h):t.call(h)==="[object Array]"},u=function(h){if(!h||t.call(h)!=="[object Object]")return!1;var m=e.call(h,"constructor"),E=h.constructor&&h.constructor.prototype&&e.call(h.constructor.prototype,"isPrototypeOf");if(h.constructor&&!m&&!E)return!1;var b;for(b in h);return typeof b=="undefined"||e.call(h,b)},a=function(h,m){n&&m.name==="__proto__"?n(h,m.name,{enumerable:!0,configurable:!0,value:m.newValue,writable:!0}):h[m.name]=m.newValue},c=function(h,m){if(m==="__proto__")if(e.call(h,m)){if(r)return r(h,m).value}else return;return h[m]};return nh=function f(){var h,m,E,b,T,_,S=arguments[0],C=1,k=arguments.length,M=!1;for(typeof S=="boolean"&&(M=S,S=arguments[1]||{},C=2),(S==null||typeof S!="object"&&typeof S!="function")&&(S={});C<k;++C)if(h=arguments[C],h!=null)for(m in h)E=c(S,m),b=c(h,m),S!==b&&(M&&b&&(u(b)||(T=o(b)))?(T?(T=!1,_=E&&o(E)?E:[]):_=E&&u(E)?E:{},a(S,{name:m,newValue:f(M,_,b)})):typeof b!="undefined"&&a(S,{name:m,newValue:b}));return S},nh}var xP=_P();const rh=Ge(xP);function ih(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function SP(){const e=[],t={run:n,use:r};return t;function n(...o){let u=-1;const a=o.pop();if(typeof a!="function")throw new TypeError("Expected function as last argument, not "+a);c(null,...o);function c(f,...h){const m=e[++u];let E=-1;if(f){a(f);return}for(;++E<o.length;)(h[E]===null||h[E]===void 0)&&(h[E]=o[E]);o=h,m?wP(m,c)(...h):a(null,...h)}}function r(o){if(typeof o!="function")throw new TypeError("Expected `middelware` to be a function, not "+o);return e.push(o),t}}function wP(e,t){let n;return r;function r(...a){const c=e.length>a.length;let f;c&&a.push(o);try{f=e.apply(this,a)}catch(h){const m=h;if(c&&n)throw m;return o(m)}c||(f&&f.then&&typeof f.then=="function"?f.then(u,o):f instanceof Error?o(f):u(f))}function o(a,...c){n||(n=!0,t(a,...c))}function u(a){o(null,a)}}const Or={basename:CP,dirname:AP,extname:vP,join:kP,sep:"/"};function CP(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');du(e);let n=0,r=-1,o=e.length,u;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(u){n=o+1;break}}else r<0&&(u=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let a=-1,c=t.length-1;for(;o--;)if(e.codePointAt(o)===47){if(u){n=o+1;break}}else a<0&&(u=!0,a=o+1),c>-1&&(e.codePointAt(o)===t.codePointAt(c--)?c<0&&(r=o):(c=-1,r=a));return n===r?r=a:r<0&&(r=e.length),e.slice(n,r)}function AP(e){if(du(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function vP(e){du(e);let t=e.length,n=-1,r=0,o=-1,u=0,a;for(;t--;){const c=e.codePointAt(t);if(c===47){if(a){r=t+1;break}continue}n<0&&(a=!0,n=t+1),c===46?o<0?o=t:u!==1&&(u=1):o>-1&&(u=-1)}return o<0||n<0||u===0||u===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function kP(...e){let t=-1,n;for(;++t<e.length;)du(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":NP(n)}function NP(e){du(e);const t=e.codePointAt(0)===47;let n=OP(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function OP(e,t){let n="",r=0,o=-1,u=0,a=-1,c,f;for(;++a<=e.length;){if(a<e.length)c=e.codePointAt(a);else{if(c===47)break;c=47}if(c===47){if(!(o===a-1||u===1))if(o!==a-1&&u===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(f=n.lastIndexOf("/"),f!==n.length-1){f<0?(n="",r=0):(n=n.slice(0,f),r=n.length-1-n.lastIndexOf("/")),o=a,u=0;continue}}else if(n.length>0){n="",r=0,o=a,u=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,a):n=e.slice(o+1,a),r=a-o-1;o=a,u=0}else c===46&&u>-1?u++:u=-1}return n}function du(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const IP={cwd:PP};function PP(){return"/"}function sh(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function RP(e){if(typeof e=="string")e=new URL(e);else if(!sh(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return LP(e)}function LP(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const o=new TypeError("File URL path must not include encoded / characters");throw o.code="ERR_INVALID_FILE_URL_PATH",o}}return decodeURIComponent(t)}const oh=["history","path","basename","stem","extname","dirname"];class gy{constructor(t){let n;t?sh(t)?n={path:t}:typeof t=="string"||DP(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":IP.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<oh.length;){const u=oh[r];u in n&&n[u]!==void 0&&n[u]!==null&&(this[u]=u==="history"?[...n[u]]:n[u])}let o;for(o in n)oh.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?Or.basename(this.path):void 0}set basename(t){ah(t,"basename"),uh(t,"basename"),this.path=Or.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Or.dirname(this.path):void 0}set dirname(t){Ey(this.basename,"dirname"),this.path=Or.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Or.extname(this.path):void 0}set extname(t){if(uh(t,"extname"),Ey(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Or.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){sh(t)&&(t=RP(t)),ah(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Or.basename(this.path,this.extname):void 0}set stem(t){ah(t,"stem"),uh(t,"stem"),this.path=Or.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const o=this.message(t,n,r);throw o.fatal=!0,o}info(t,n,r){const o=this.message(t,n,r);return o.fatal=void 0,o}message(t,n,r){const o=new rn(t,n,r);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function uh(e,t){if(e&&e.includes(Or.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Or.sep+"`")}function ah(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Ey(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function DP(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const FP=function(e){const r=this.constructor.prototype,o=r[e],u=function(){return o.apply(u,arguments)};return Object.setPrototypeOf(u,r),u},MP={}.hasOwnProperty;class lh extends FP{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=SP()}copy(){const t=new lh;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(rh(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(dh("data",this.frozen),this.namespace[t]=n,this):MP.call(this.namespace,t)&&this.namespace[t]||void 0:t?(dh("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const o=n.call(t,...r);typeof o=="function"&&this.transformers.use(o)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=Sl(t),r=this.parser||this.Parser;return ch("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),ch("process",this.parser||this.Parser),fh("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(u,a){const c=Sl(t),f=r.parse(c);r.run(f,c,function(m,E,b){if(m||!E||!b)return h(m);const T=E,_=r.stringify(T,b);HP(_)?b.value=_:b.result=_,h(m,b)});function h(m,E){m||!E?a(m):u?u(E):n(void 0,E)}}}processSync(t){let n=!1,r;return this.freeze(),ch("processSync",this.parser||this.Parser),fh("processSync",this.compiler||this.Compiler),this.process(t,o),Ty("processSync","process",n),r;function o(u,a){n=!0,py(u),r=a}}run(t,n,r){yy(t),this.freeze();const o=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?u(void 0,r):new Promise(u);function u(a,c){const f=Sl(n);o.run(t,f,h);function h(m,E,b){const T=E||t;m?c(m):a?a(T):r(void 0,T,b)}}}runSync(t,n){let r=!1,o;return this.run(t,n,u),Ty("runSync","run",r),o;function u(a,c){py(a),o=c,r=!0}}stringify(t,n){this.freeze();const r=Sl(n),o=this.compiler||this.Compiler;return fh("stringify",o),yy(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(dh("use",this.frozen),t!=null)if(typeof t=="function")f(t,n);else if(typeof t=="object")Array.isArray(t)?c(t):a(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function u(h){if(typeof h=="function")f(h,[]);else if(typeof h=="object")if(Array.isArray(h)){const[m,...E]=h;f(m,E)}else a(h);else throw new TypeError("Expected usable value, not `"+h+"`")}function a(h){if(!("plugins"in h)&&!("settings"in h))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");c(h.plugins),h.settings&&(o.settings=rh(!0,o.settings,h.settings))}function c(h){let m=-1;if(h!=null)if(Array.isArray(h))for(;++m<h.length;){const E=h[m];u(E)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function f(h,m){let E=-1,b=-1;for(;++E<r.length;)if(r[E][0]===h){b=E;break}if(b===-1)r.push([h,...m]);else if(m.length>0){let[T,..._]=m;const S=r[b][1];ih(S)&&ih(T)&&(T=rh(!0,S,T)),r[b]=[h,T,..._]}}}}const BP=new lh().freeze();function ch(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function fh(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function dh(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function yy(e){if(!ih(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Ty(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Sl(e){return UP(e)?e:new gy(e)}function UP(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function HP(e){return typeof e=="string"||zP(e)}function zP(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const jP="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",by=[],_y={allowDangerousHtml:!0},$P=/^(https?|ircs?|mailto|xmpp)$/i,VP=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function qP(e){const t=YP(e),n=WP(e);return GP(t.runSync(t.parse(n),n),e)}function YP(e){const t=e.rehypePlugins||by,n=e.remarkPlugins||by,r=e.remarkRehypeOptions?U(U({},e.remarkRehypeOptions),_y):_y;return BP().use(AI).use(n).use(bP,r).use(t)}function WP(e){const t=e.children||"",n=new gy;return typeof t=="string"&&(n.value=t),n}function GP(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,u=t.disallowedElements,a=t.skipHtml,c=t.unwrapDisallowed,f=t.urlTransform||KP;for(const m of VP)Object.hasOwn(t,m.from)&&(""+m.from+(m.to?"use `"+m.to+"` instead":"remove it")+jP+m.id,void 0);return xl(e,h),y3(e,{Fragment:I.Fragment,components:o,ignoreInvalidStyle:!0,jsx:I.jsx,jsxs:I.jsxs,passKeys:!0,passNode:!0});function h(m,E,b){if(m.type==="raw"&&b&&typeof E=="number")return a?b.children.splice(E,1):b.children[E]={type:"text",value:m.value},E;if(m.type==="element"){let T;for(T in jd)if(Object.hasOwn(jd,T)&&Object.hasOwn(m.properties,T)){const _=m.properties[T],S=jd[T];(S===null||S.includes(m.tagName))&&(m.properties[T]=f(String(_||""),T,m))}}if(m.type==="element"){let T=n?!n.includes(m.tagName):u?u.includes(m.tagName):!1;if(!T&&r&&typeof E=="number"&&(T=!r(m,E,b)),T&&b&&typeof E=="number")return c&&m.children?b.children.splice(E,1,...m.children):b.children.splice(E,1),E}}}function KP(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),o=e.indexOf("/");return t===-1||o!==-1&&t>o||n!==-1&&t>n||r!==-1&&t>r||$P.test(e.slice(0,t))?e:""}const xy=/[#.]/g;function QP(e,t){const n=e||"",r={};let o=0,u,a;for(;o<n.length;){xy.lastIndex=o;const c=xy.exec(n),f=n.slice(o,c?c.index:n.length);f&&(u?u==="#"?r.id=f:Array.isArray(r.className)?r.className.push(f):r.className=[f]:a=f,o+=f.length),c&&(u=c[0],o++)}return{type:"element",tagName:a||t||"div",properties:r,children:[]}}function Sy(e,t,n){const r=n?eR(n):void 0;function o(u,a,...c){let f;if(u==null){f={type:"root",children:[]};const h=a;c.unshift(h)}else{f=QP(u,t);const h=f.tagName.toLowerCase(),m=r?r.get(h):void 0;if(f.tagName=m||h,XP(a))c.unshift(a);else for(const[E,b]of Object.entries(a))JP(e,f.properties,E,b)}for(const h of c)hh(f.children,h);return f.type==="element"&&f.tagName==="template"&&(f.content={type:"root",children:f.children},f.children=[]),f}return o}function XP(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const o=t[r];if(o&&typeof o=="object"){if(!Array.isArray(o))return!0;const u=o;for(const a of u)if(typeof a!="number"&&typeof a!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function JP(e,t,n,r){const o=Fd(e,n);let u;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;u=r}else typeof r=="boolean"?u=r:typeof r=="string"?o.spaceSeparated?u=mE(r):o.commaSeparated?u=nE(r):o.commaOrSpaceSeparated?u=mE(nE(r).join(" ")):u=wy(o,o.property,r):Array.isArray(r)?u=[...r]:u=o.property==="style"?ZP(r):String(r);if(Array.isArray(u)){const a=[];for(const c of u)a.push(wy(o,o.property,c));u=a}o.property==="className"&&Array.isArray(t.className)&&(u=t.className.concat(u)),t[o.property]=u}}function hh(e,t){if(t!=null)if(typeof t=="number"||typeof t=="string")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(const n of t)hh(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?hh(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function wy(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||nu(n)===nu(t)))return!0}return n}function ZP(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function eR(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const tR=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],nR=Sy(cl,"div"),rR=Sy(Vs,"g",tR);function iR(e){const t=String(e),n=[];return{toOffset:o,toPoint:r};function r(u){if(typeof u=="number"&&u>-1&&u<=t.length){let a=0;for(;;){let c=n[a];if(c===void 0){const f=Cy(t,n[a-1]);c=f===-1?t.length+1:f+1,n[a]=c}if(c>u)return{line:a+1,column:u-(a>0?n[a-1]:0)+1,offset:u};a++}}}function o(u){if(u&&typeof u.line=="number"&&typeof u.column=="number"&&!Number.isNaN(u.line)&&!Number.isNaN(u.column)){for(;n.length<u.line;){const c=n[n.length-1],f=Cy(t,c),h=f===-1?t.length+1:f+1;if(c===h)break;n.push(h)}const a=(u.line>1?n[u.line-2]:0)+u.column-1;if(a<n[u.line-1])return a}}}function Cy(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
28
- `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ki={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Ay={}.hasOwnProperty,sR=Object.prototype;function oR(e,t){const n=t||{};return ph({file:n.file||void 0,location:!1,schema:n.space==="svg"?Vs:cl,verbose:n.verbose||!1},e)}function ph(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},wl(e,r,n),n}case"#document":case"#document-fragment":{const r=t,o="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:vy(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const u=String(e.file),a=iR(u),c=a.toPoint(0),f=a.toPoint(u.length);n.position={start:c,end:f}}return n}case"#documentType":{const r=t;return n={type:"doctype"},wl(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},wl(e,r,n),n}default:return n=uR(e,t),n}}function vy(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=ph(e,t[n]);r.push(o)}return r}function uR(e,t){const n=e.schema;e.schema=t.namespaceURI===Ki.svg?Vs:cl;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],f=(c.prefix?c.prefix+":":"")+c.name;Ay.call(sR,f)||(o[f]=c.value)}const a=(e.schema.space==="svg"?rR:nR)(t.tagName,o,vy(e,t.childNodes));if(wl(e,t,a),a.tagName==="template"){const c=t,f=c.sourceCodeLocation,h=f&&f.startTag&&Qs(f.startTag),m=f&&f.endTag&&Qs(f.endTag),E=ph(e,c.content);h&&m&&e.file&&(E.position={start:h.end,end:m.start}),a.content=E}return e.schema=n,a}function wl(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=aR(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function aR(e,t,n){const r=Qs(n);if(t.type==="element"){const o=t.children[t.children.length-1];if(r&&!n.endTag&&o&&o.position&&o.position.end&&(r.end=Object.assign({},o.position.end)),e.verbose){const u={};let a;if(n.attrs)for(a in n.attrs)Ay.call(n.attrs,a)&&(u[Fd(e.schema,a).property]=Qs(n.attrs[a]));n.startTag;const c=Qs(n.startTag),f=n.endTag?Qs(n.endTag):void 0,h={opening:c};f&&(h.closing=f),h.properties=u,t.data={position:h}}}return r}function Qs(e){const t=ky({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=ky({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function ky(e){return e.line&&e.column?e:void 0}class hu{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}hu.prototype.property={},hu.prototype.normal={},hu.prototype.space=null;function Ny(e,t){const n={},r={};let o=-1;for(;++o<e.length;)Object.assign(n,e[o].property),Object.assign(r,e[o].normal);return new hu(n,r,t)}function mh(e){return e.toLowerCase()}class Wn{constructor(t,n){this.property=t,this.attribute=n}}Wn.prototype.space=null,Wn.prototype.boolean=!1,Wn.prototype.booleanish=!1,Wn.prototype.overloadedBoolean=!1,Wn.prototype.number=!1,Wn.prototype.commaSeparated=!1,Wn.prototype.spaceSeparated=!1,Wn.prototype.commaOrSpaceSeparated=!1,Wn.prototype.mustUseProperty=!1,Wn.prototype.defined=!1;let lR=0;const je=Qi(),Bt=Qi(),Oy=Qi(),pe=Qi(),lt=Qi(),Xs=Qi(),Fn=Qi();function Qi(){return Xc(2,++lR)}const gh=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:Bt,commaOrSpaceSeparated:Fn,commaSeparated:Xs,number:pe,overloadedBoolean:Oy,spaceSeparated:lt},Symbol.toStringTag,{value:"Module"})),Eh=Object.keys(gh);class yh extends Wn{constructor(t,n,r,o){let u=-1;if(super(t,n),Iy(this,"space",o),typeof r=="number")for(;++u<Eh.length;){const a=Eh[u];Iy(this,Eh[u],(r&gh[a])===gh[a])}}}yh.prototype.defined=!0;function Iy(e,t,n){n&&(e[t]=n)}const cR={}.hasOwnProperty;function Js(e){const t={},n={};let r;for(r in e.properties)if(cR.call(e.properties,r)){const o=e.properties[r],u=new yh(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(u.mustUseProperty=!0),t[r]=u,n[mh(r)]=r,n[mh(u.attribute)]=r}return new hu(t,n,e.space)}const Py=Js({space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),Ry=Js({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function Ly(e,t){return t in e?e[t]:t}function Dy(e,t){return Ly(e,t.toLowerCase())}const Fy=Js({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:Dy,properties:{xmlns:null,xmlnsXLink:null}}),My=Js({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:Bt,ariaAutoComplete:null,ariaBusy:Bt,ariaChecked:Bt,ariaColCount:pe,ariaColIndex:pe,ariaColSpan:pe,ariaControls:lt,ariaCurrent:null,ariaDescribedBy:lt,ariaDetails:null,ariaDisabled:Bt,ariaDropEffect:lt,ariaErrorMessage:null,ariaExpanded:Bt,ariaFlowTo:lt,ariaGrabbed:Bt,ariaHasPopup:null,ariaHidden:Bt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:lt,ariaLevel:pe,ariaLive:null,ariaModal:Bt,ariaMultiLine:Bt,ariaMultiSelectable:Bt,ariaOrientation:null,ariaOwns:lt,ariaPlaceholder:null,ariaPosInSet:pe,ariaPressed:Bt,ariaReadOnly:Bt,ariaRelevant:null,ariaRequired:Bt,ariaRoleDescription:lt,ariaRowCount:pe,ariaRowIndex:pe,ariaRowSpan:pe,ariaSelected:Bt,ariaSetSize:pe,ariaSort:null,ariaValueMax:pe,ariaValueMin:pe,ariaValueNow:pe,ariaValueText:null,role:null}}),fR=Js({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:Dy,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Xs,acceptCharset:lt,accessKey:lt,action:null,allow:null,allowFullScreen:je,allowPaymentRequest:je,allowUserMedia:je,alt:null,as:null,async:je,autoCapitalize:null,autoComplete:lt,autoFocus:je,autoPlay:je,blocking:lt,capture:null,charSet:null,checked:je,cite:null,className:lt,cols:pe,colSpan:null,content:null,contentEditable:Bt,controls:je,controlsList:lt,coords:pe|Xs,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:Oy,draggable:Bt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:lt,height:pe,hidden:je,high:pe,href:null,hrefLang:null,htmlFor:lt,httpEquiv:lt,id:null,imageSizes:null,imageSrcSet:null,inert:je,inputMode:null,integrity:null,is:null,isMap:je,itemId:null,itemProp:lt,itemRef:lt,itemScope:je,itemType:lt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:je,low:pe,manifest:null,max:null,maxLength:pe,media:null,method:null,min:null,minLength:pe,multiple:je,muted:je,name:null,nonce:null,noModule:je,noValidate:je,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:je,optimum:pe,pattern:null,ping:lt,placeholder:null,playsInline:je,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:je,referrerPolicy:null,rel:lt,required:je,reversed:je,rows:pe,rowSpan:pe,sandbox:lt,scope:null,scoped:je,seamless:je,selected:je,shadowRootClonable:je,shadowRootDelegatesFocus:je,shadowRootMode:null,shape:null,size:pe,sizes:null,slot:null,span:pe,spellCheck:Bt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:pe,step:null,style:null,tabIndex:pe,target:null,title:null,translate:null,type:null,typeMustMatch:je,useMap:null,value:Bt,width:pe,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:lt,axis:null,background:null,bgColor:null,border:pe,borderColor:null,bottomMargin:pe,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:je,declare:je,event:null,face:null,frame:null,frameBorder:null,hSpace:pe,leftMargin:pe,link:null,longDesc:null,lowSrc:null,marginHeight:pe,marginWidth:pe,noResize:je,noHref:je,noShade:je,noWrap:je,object:null,profile:null,prompt:null,rev:null,rightMargin:pe,rules:null,scheme:null,scrolling:Bt,standby:null,summary:null,text:null,topMargin:pe,valueType:null,version:null,vAlign:null,vLink:null,vSpace:pe,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:je,disableRemotePlayback:je,prefix:null,property:null,results:pe,security:null,unselectable:null}}),dR=Js({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:Ly,properties:{about:Fn,accentHeight:pe,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:pe,amplitude:pe,arabicForm:null,ascent:pe,attributeName:null,attributeType:null,azimuth:pe,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:pe,by:null,calcMode:null,capHeight:pe,className:lt,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:pe,diffuseConstant:pe,direction:null,display:null,dur:null,divisor:pe,dominantBaseline:null,download:je,dx:null,dy:null,edgeMode:null,editable:null,elevation:pe,enableBackground:null,end:null,event:null,exponent:pe,externalResourcesRequired:null,fill:null,fillOpacity:pe,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Xs,g2:Xs,glyphName:Xs,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:pe,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:pe,horizOriginX:pe,horizOriginY:pe,id:null,ideographic:pe,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:pe,k:pe,k1:pe,k2:pe,k3:pe,k4:pe,kernelMatrix:Fn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:pe,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:pe,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:pe,overlineThickness:pe,paintOrder:null,panose1:null,path:null,pathLength:pe,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:lt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:pe,pointsAtY:pe,pointsAtZ:pe,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Fn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Fn,rev:Fn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Fn,requiredFeatures:Fn,requiredFonts:Fn,requiredFormats:Fn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:pe,specularExponent:pe,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:pe,strikethroughThickness:pe,string:null,stroke:null,strokeDashArray:Fn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:pe,strokeOpacity:pe,strokeWidth:null,style:null,surfaceScale:pe,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Fn,tabIndex:pe,tableValues:null,target:null,targetX:pe,targetY:pe,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Fn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:pe,underlineThickness:pe,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:pe,values:null,vAlphabetic:pe,vMathematical:pe,vectorEffect:null,vHanging:pe,vIdeographic:pe,version:null,vertAdvY:pe,vertOriginX:pe,vertOriginY:pe,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:pe,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),hR=/^data[-\w.:]+$/i,By=/-[a-z]/g,pR=/[A-Z]/g;function mR(e,t){const n=mh(t);let r=t,o=Wn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&hR.test(t)){if(t.charAt(4)==="-"){const u=t.slice(5).replace(By,ER);r="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=t.slice(4);if(!By.test(u)){let a=u.replace(pR,gR);a.charAt(0)!=="-"&&(a="-"+a),t="data"+a}}o=yh}return new o(r,t)}function gR(e){return"-"+e.toLowerCase()}function ER(e){return e.charAt(1).toUpperCase()}const yR=Ny([Ry,Py,Fy,My,fR],"html"),Uy=Ny([Ry,Py,Fy,My,dR],"svg"),Hy={}.hasOwnProperty;function zy(e,t){const n=t||{};function r(o,...u){let a=r.invalid;const c=r.handlers;if(o&&Hy.call(o,e)){const f=String(o[e]);a=Hy.call(c,f)?c[f]:r.unknown}if(a)return a.call(this,o,...u)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const TR={},bR={}.hasOwnProperty,jy=zy("type",{handlers:{root:xR,element:vR,text:CR,comment:AR,doctype:wR}});function _R(e,t){const r=(t||TR).space;return jy(e,r==="svg"?Uy:yR)}function xR(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Th(e.children,n,t),Zs(e,n),n}function SR(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Th(e.children,n,t),Zs(e,n),n}function wR(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return Zs(e,t),t}function CR(e){const t={nodeName:"#text",value:e.value,parentNode:null};return Zs(e,t),t}function AR(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return Zs(e,t),t}function vR(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=Uy);const o=[];let u;if(e.properties){for(u in e.properties)if(u!=="children"&&bR.call(e.properties,u)){const f=kR(r,u,e.properties[u]);f&&o.push(f)}}const a=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Ki[a],childNodes:[],parentNode:null};return c.childNodes=Th(e.children,c,r),Zs(e,c),e.tagName==="template"&&e.content&&(c.content=SR(e.content,r)),c}function kR(e,t,n){const r=mR(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?rE(n):gE(n));const o={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const u=o.name.indexOf(":");u<0?o.prefix="":(o.name=o.name.slice(u+1),o.prefix=r.attribute.slice(0,u)),o.namespace=Ki[r.space]}return o}function Th(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const u=jy(e[r],n);u.parentNode=t,o.push(u)}return o}function Zs(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const NR=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],OR=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),yt="�";var A;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(A||(A={}));const Cn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function $y(e){return e>=55296&&e<=57343}function IR(e){return e>=56320&&e<=57343}function PR(e,t){return(e-55296)*1024+9216+t}function Vy(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function qy(e){return e>=64976&&e<=65007||OR.has(e)}var X;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(X||(X={}));const RR=65536;class LR{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=RR,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:o,offset:u}=this,a=o+n,c=u+n;return{code:t,startLine:r,endLine:r,startCol:a,endCol:a,startOffset:c,endOffset:c}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(IR(n))return this.pos++,this._addGap(),PR(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,A.EOF;return this._err(X.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,A.EOF;const r=this.html.charCodeAt(n);return r===A.CARRIAGE_RETURN?A.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,A.EOF;let t=this.html.charCodeAt(this.pos);return t===A.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,A.LINE_FEED):t===A.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,$y(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===A.LINE_FEED||t===A.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Vy(t)?this._err(X.controlCharacterInInputStream):qy(t)&&this._err(X.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var qe;(function(e){e[e.CHARACTER=0]="CHARACTER",e[e.NULL_CHARACTER=1]="NULL_CHARACTER",e[e.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",e[e.START_TAG=3]="START_TAG",e[e.END_TAG=4]="END_TAG",e[e.COMMENT=5]="COMMENT",e[e.DOCTYPE=6]="DOCTYPE",e[e.EOF=7]="EOF",e[e.HIBERNATION=8]="HIBERNATION"})(qe||(qe={}));function Yy(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const DR=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),FR=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function MR(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=FR.get(e))!==null&&t!==void 0?t:e}var qt;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(qt||(qt={}));const BR=32;var mi;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(mi||(mi={}));function bh(e){return e>=qt.ZERO&&e<=qt.NINE}function UR(e){return e>=qt.UPPER_A&&e<=qt.UPPER_F||e>=qt.LOWER_A&&e<=qt.LOWER_F}function HR(e){return e>=qt.UPPER_A&&e<=qt.UPPER_Z||e>=qt.LOWER_A&&e<=qt.LOWER_Z||bh(e)}function zR(e){return e===qt.EQUALS||HR(e)}var Yt;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(Yt||(Yt={}));var Qr;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Qr||(Qr={}));class jR{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Yt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Qr.Strict}startEntity(t){this.decodeMode=t,this.state=Yt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Yt.EntityStart:return t.charCodeAt(n)===qt.NUM?(this.state=Yt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Yt.NamedEntity,this.stateNamedEntity(t,n));case Yt.NumericStart:return this.stateNumericStart(t,n);case Yt.NumericDecimal:return this.stateNumericDecimal(t,n);case Yt.NumericHex:return this.stateNumericHex(t,n);case Yt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|BR)===qt.LOWER_X?(this.state=Yt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Yt.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,o){if(n!==r){const u=r-n;this.result=this.result*Math.pow(o,u)+Number.parseInt(t.substr(n,u),o),this.consumed+=u}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const o=t.charCodeAt(n);if(bh(o)||UR(o))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(o,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const o=t.charCodeAt(n);if(bh(o))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(o,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===qt.SEMI)this.consumed+=1;else if(this.decodeMode===Qr.Strict)return 0;return this.emitCodePoint(MR(this.result),this.consumed),this.errors&&(t!==qt.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let o=r[this.treeIndex],u=(o&mi.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const a=t.charCodeAt(n);if(this.treeIndex=$R(r,o,this.treeIndex+Math.max(1,u),a),this.treeIndex<0)return this.result===0||this.decodeMode===Qr.Attribute&&(u===0||zR(a))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],u=(o&mi.VALUE_LENGTH)>>14,u!==0){if(a===qt.SEMI)return this.emitNamedEntityData(this.treeIndex,u,this.consumed+this.excess);this.decodeMode!==Qr.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,o=(r[n]&mi.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,o,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:o}=this;return this.emitCodePoint(n===1?o[t]&~mi.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Yt.NamedEntity:return this.result!==0&&(this.decodeMode!==Qr.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Yt.NumericDecimal:return this.emitNumericEntity(0,2);case Yt.NumericHex:return this.emitNumericEntity(0,3);case Yt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Yt.EntityStart:return 0}}}function $R(e,t,n,r){const o=(t&mi.BRANCH_LENGTH)>>7,u=t&mi.JUMP_TABLE;if(o===0)return u!==0&&r===u?n:-1;if(u){const f=r-u;return f<0||f>=o?-1:e[n+f]-1}let a=n,c=a+o-1;for(;a<=c;){const f=a+c>>>1,h=e[f];if(h<r)a=f+1;else if(h>r)c=f-1;else return e[f+o]}return-1}var re;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(re||(re={}));var Xi;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Xi||(Xi={}));var Gn;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Gn||(Gn={}));var j;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SEARCH="search",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(j||(j={}));var p;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SEARCH=94]="SEARCH",e[e.SECTION=95]="SECTION",e[e.SELECT=96]="SELECT",e[e.SOURCE=97]="SOURCE",e[e.SMALL=98]="SMALL",e[e.SPAN=99]="SPAN",e[e.STRIKE=100]="STRIKE",e[e.STRONG=101]="STRONG",e[e.STYLE=102]="STYLE",e[e.SUB=103]="SUB",e[e.SUMMARY=104]="SUMMARY",e[e.SUP=105]="SUP",e[e.TABLE=106]="TABLE",e[e.TBODY=107]="TBODY",e[e.TEMPLATE=108]="TEMPLATE",e[e.TEXTAREA=109]="TEXTAREA",e[e.TFOOT=110]="TFOOT",e[e.TD=111]="TD",e[e.TH=112]="TH",e[e.THEAD=113]="THEAD",e[e.TITLE=114]="TITLE",e[e.TR=115]="TR",e[e.TRACK=116]="TRACK",e[e.TT=117]="TT",e[e.U=118]="U",e[e.UL=119]="UL",e[e.SVG=120]="SVG",e[e.VAR=121]="VAR",e[e.WBR=122]="WBR",e[e.XMP=123]="XMP"})(p||(p={}));const VR=new Map([[j.A,p.A],[j.ADDRESS,p.ADDRESS],[j.ANNOTATION_XML,p.ANNOTATION_XML],[j.APPLET,p.APPLET],[j.AREA,p.AREA],[j.ARTICLE,p.ARTICLE],[j.ASIDE,p.ASIDE],[j.B,p.B],[j.BASE,p.BASE],[j.BASEFONT,p.BASEFONT],[j.BGSOUND,p.BGSOUND],[j.BIG,p.BIG],[j.BLOCKQUOTE,p.BLOCKQUOTE],[j.BODY,p.BODY],[j.BR,p.BR],[j.BUTTON,p.BUTTON],[j.CAPTION,p.CAPTION],[j.CENTER,p.CENTER],[j.CODE,p.CODE],[j.COL,p.COL],[j.COLGROUP,p.COLGROUP],[j.DD,p.DD],[j.DESC,p.DESC],[j.DETAILS,p.DETAILS],[j.DIALOG,p.DIALOG],[j.DIR,p.DIR],[j.DIV,p.DIV],[j.DL,p.DL],[j.DT,p.DT],[j.EM,p.EM],[j.EMBED,p.EMBED],[j.FIELDSET,p.FIELDSET],[j.FIGCAPTION,p.FIGCAPTION],[j.FIGURE,p.FIGURE],[j.FONT,p.FONT],[j.FOOTER,p.FOOTER],[j.FOREIGN_OBJECT,p.FOREIGN_OBJECT],[j.FORM,p.FORM],[j.FRAME,p.FRAME],[j.FRAMESET,p.FRAMESET],[j.H1,p.H1],[j.H2,p.H2],[j.H3,p.H3],[j.H4,p.H4],[j.H5,p.H5],[j.H6,p.H6],[j.HEAD,p.HEAD],[j.HEADER,p.HEADER],[j.HGROUP,p.HGROUP],[j.HR,p.HR],[j.HTML,p.HTML],[j.I,p.I],[j.IMG,p.IMG],[j.IMAGE,p.IMAGE],[j.INPUT,p.INPUT],[j.IFRAME,p.IFRAME],[j.KEYGEN,p.KEYGEN],[j.LABEL,p.LABEL],[j.LI,p.LI],[j.LINK,p.LINK],[j.LISTING,p.LISTING],[j.MAIN,p.MAIN],[j.MALIGNMARK,p.MALIGNMARK],[j.MARQUEE,p.MARQUEE],[j.MATH,p.MATH],[j.MENU,p.MENU],[j.META,p.META],[j.MGLYPH,p.MGLYPH],[j.MI,p.MI],[j.MO,p.MO],[j.MN,p.MN],[j.MS,p.MS],[j.MTEXT,p.MTEXT],[j.NAV,p.NAV],[j.NOBR,p.NOBR],[j.NOFRAMES,p.NOFRAMES],[j.NOEMBED,p.NOEMBED],[j.NOSCRIPT,p.NOSCRIPT],[j.OBJECT,p.OBJECT],[j.OL,p.OL],[j.OPTGROUP,p.OPTGROUP],[j.OPTION,p.OPTION],[j.P,p.P],[j.PARAM,p.PARAM],[j.PLAINTEXT,p.PLAINTEXT],[j.PRE,p.PRE],[j.RB,p.RB],[j.RP,p.RP],[j.RT,p.RT],[j.RTC,p.RTC],[j.RUBY,p.RUBY],[j.S,p.S],[j.SCRIPT,p.SCRIPT],[j.SEARCH,p.SEARCH],[j.SECTION,p.SECTION],[j.SELECT,p.SELECT],[j.SOURCE,p.SOURCE],[j.SMALL,p.SMALL],[j.SPAN,p.SPAN],[j.STRIKE,p.STRIKE],[j.STRONG,p.STRONG],[j.STYLE,p.STYLE],[j.SUB,p.SUB],[j.SUMMARY,p.SUMMARY],[j.SUP,p.SUP],[j.TABLE,p.TABLE],[j.TBODY,p.TBODY],[j.TEMPLATE,p.TEMPLATE],[j.TEXTAREA,p.TEXTAREA],[j.TFOOT,p.TFOOT],[j.TD,p.TD],[j.TH,p.TH],[j.THEAD,p.THEAD],[j.TITLE,p.TITLE],[j.TR,p.TR],[j.TRACK,p.TRACK],[j.TT,p.TT],[j.U,p.U],[j.UL,p.UL],[j.SVG,p.SVG],[j.VAR,p.VAR],[j.WBR,p.WBR],[j.XMP,p.XMP]]);function eo(e){var t;return(t=VR.get(e))!==null&&t!==void 0?t:p.UNKNOWN}const le=p,qR={[re.HTML]:new Set([le.ADDRESS,le.APPLET,le.AREA,le.ARTICLE,le.ASIDE,le.BASE,le.BASEFONT,le.BGSOUND,le.BLOCKQUOTE,le.BODY,le.BR,le.BUTTON,le.CAPTION,le.CENTER,le.COL,le.COLGROUP,le.DD,le.DETAILS,le.DIR,le.DIV,le.DL,le.DT,le.EMBED,le.FIELDSET,le.FIGCAPTION,le.FIGURE,le.FOOTER,le.FORM,le.FRAME,le.FRAMESET,le.H1,le.H2,le.H3,le.H4,le.H5,le.H6,le.HEAD,le.HEADER,le.HGROUP,le.HR,le.HTML,le.IFRAME,le.IMG,le.INPUT,le.LI,le.LINK,le.LISTING,le.MAIN,le.MARQUEE,le.MENU,le.META,le.NAV,le.NOEMBED,le.NOFRAMES,le.NOSCRIPT,le.OBJECT,le.OL,le.P,le.PARAM,le.PLAINTEXT,le.PRE,le.SCRIPT,le.SECTION,le.SELECT,le.SOURCE,le.STYLE,le.SUMMARY,le.TABLE,le.TBODY,le.TD,le.TEMPLATE,le.TEXTAREA,le.TFOOT,le.TH,le.THEAD,le.TITLE,le.TR,le.TRACK,le.UL,le.WBR,le.XMP]),[re.MATHML]:new Set([le.MI,le.MO,le.MN,le.MS,le.MTEXT,le.ANNOTATION_XML]),[re.SVG]:new Set([le.TITLE,le.FOREIGN_OBJECT,le.DESC]),[re.XLINK]:new Set,[re.XML]:new Set,[re.XMLNS]:new Set},_h=new Set([le.H1,le.H2,le.H3,le.H4,le.H5,le.H6]);j.STYLE,j.SCRIPT,j.XMP,j.IFRAME,j.NOEMBED,j.NOFRAMES,j.PLAINTEXT;var v;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(v||(v={}));const Pt={DATA:v.DATA,RCDATA:v.RCDATA,RAWTEXT:v.RAWTEXT,SCRIPT_DATA:v.SCRIPT_DATA,PLAINTEXT:v.PLAINTEXT,CDATA_SECTION:v.CDATA_SECTION};function YR(e){return e>=A.DIGIT_0&&e<=A.DIGIT_9}function pu(e){return e>=A.LATIN_CAPITAL_A&&e<=A.LATIN_CAPITAL_Z}function WR(e){return e>=A.LATIN_SMALL_A&&e<=A.LATIN_SMALL_Z}function gi(e){return WR(e)||pu(e)}function Wy(e){return gi(e)||YR(e)}function Cl(e){return e+32}function Gy(e){return e===A.SPACE||e===A.LINE_FEED||e===A.TABULATION||e===A.FORM_FEED}function Ky(e){return Gy(e)||e===A.SOLIDUS||e===A.GREATER_THAN_SIGN}function GR(e){return e===A.NULL?X.nullCharacterReference:e>1114111?X.characterReferenceOutsideUnicodeRange:$y(e)?X.surrogateCharacterReference:qy(e)?X.noncharacterCharacterReference:Vy(e)||e===A.CARRIAGE_RETURN?X.controlCharacterReference:null}class KR{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=v.DATA,this.returnState=v.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new LR(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new jR(DR,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(X.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(X.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=GR(r);o&&this._err(o,1)}}:void 0)}_err(t,n=0){var r,o;(o=(r=this.handler).onParseError)===null||o===void 0||o.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:qe.START_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:qe.END_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:qe.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:qe.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(Yy(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const o=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);o[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(X.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=eo(t.tagName),t.type===qe.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(X.endTagWithAttributes),t.selfClosing&&this._err(X.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case qe.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case qe.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case qe.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:qe.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=Gy(t)?qe.WHITESPACE_CHARACTER:t===A.NULL?qe.NULL_CHARACTER:qe.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(qe.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=v.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Qr.Attribute:Qr.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===v.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===v.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===v.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case v.DATA:{this._stateData(t);break}case v.RCDATA:{this._stateRcdata(t);break}case v.RAWTEXT:{this._stateRawtext(t);break}case v.SCRIPT_DATA:{this._stateScriptData(t);break}case v.PLAINTEXT:{this._statePlaintext(t);break}case v.TAG_OPEN:{this._stateTagOpen(t);break}case v.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case v.TAG_NAME:{this._stateTagName(t);break}case v.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case v.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case v.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case v.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case v.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case v.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case v.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case v.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case v.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case v.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case v.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case v.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case v.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case v.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case v.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case v.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case v.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case v.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case v.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case v.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case v.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case v.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case v.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case v.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case v.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case v.BOGUS_COMMENT:{this._stateBogusComment(t);break}case v.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case v.COMMENT_START:{this._stateCommentStart(t);break}case v.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case v.COMMENT:{this._stateComment(t);break}case v.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case v.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case v.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case v.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case v.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case v.COMMENT_END:{this._stateCommentEnd(t);break}case v.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case v.DOCTYPE:{this._stateDoctype(t);break}case v.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case v.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case v.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case v.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case v.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case v.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case v.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case v.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case v.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case v.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case v.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case v.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case v.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case v.CDATA_SECTION:{this._stateCdataSection(t);break}case v.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case v.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case v.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case v.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case A.LESS_THAN_SIGN:{this.state=v.TAG_OPEN;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitCodePoint(t);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case A.AMPERSAND:{this._startCharacterReference();break}case A.LESS_THAN_SIGN:{this.state=v.RCDATA_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case A.LESS_THAN_SIGN:{this.state=v.RAWTEXT_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(gi(t))this._createStartTagToken(),this.state=v.TAG_NAME,this._stateTagName(t);else switch(t){case A.EXCLAMATION_MARK:{this.state=v.MARKUP_DECLARATION_OPEN;break}case A.SOLIDUS:{this.state=v.END_TAG_OPEN;break}case A.QUESTION_MARK:{this._err(X.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=v.BOGUS_COMMENT,this._stateBogusComment(t);break}case A.EOF:{this._err(X.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(X.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=v.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(gi(t))this._createEndTagToken(),this.state=v.TAG_NAME,this._stateTagName(t);else switch(t){case A.GREATER_THAN_SIGN:{this._err(X.missingEndTagName),this.state=v.DATA;break}case A.EOF:{this._err(X.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(X.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=v.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_ATTRIBUTE_NAME;break}case A.SOLIDUS:{this.state=v.SELF_CLOSING_START_TAG;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentTagToken();break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.tagName+=yt;break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(pu(t)?Cl(t):t)}}_stateRcdataLessThanSign(t){t===A.SOLIDUS?this.state=v.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=v.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){gi(t)?(this.state=v.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=v.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=v.BEFORE_ATTRIBUTE_NAME,!1;case A.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=v.SELF_CLOSING_START_TAG,!1;case A.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=v.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===A.SOLIDUS?this.state=v.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=v.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){gi(t)?(this.state=v.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=v.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case A.SOLIDUS:{this.state=v.SCRIPT_DATA_END_TAG_OPEN;break}case A.EXCLAMATION_MARK:{this.state=v.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=v.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){gi(t)?(this.state=v.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===A.HYPHEN_MINUS?(this.state=v.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===A.HYPHEN_MINUS?(this.state=v.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case A.HYPHEN_MINUS:{this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case A.GREATER_THAN_SIGN:{this.state=v.SCRIPT_DATA,this._emitChars(">");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===A.SOLIDUS?this.state=v.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:gi(t)?(this._emitChars("<"),this.state=v.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){gi(t)?(this.state=v.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(Cn.SCRIPT,!1)&&Ky(this.preprocessor.peek(Cn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Cn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case A.HYPHEN_MINUS:{this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case A.GREATER_THAN_SIGN:{this.state=v.SCRIPT_DATA,this._emitChars(">");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===A.SOLIDUS?(this.state=v.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(Cn.SCRIPT,!1)&&Ky(this.preprocessor.peek(Cn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Cn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=v.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.SOLIDUS:case A.GREATER_THAN_SIGN:case A.EOF:{this.state=v.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case A.EQUALS_SIGN:{this._err(X.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=v.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=v.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:case A.SOLIDUS:case A.GREATER_THAN_SIGN:case A.EOF:{this._leaveAttrName(),this.state=v.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case A.EQUALS_SIGN:{this._leaveAttrName(),this.state=v.BEFORE_ATTRIBUTE_VALUE;break}case A.QUOTATION_MARK:case A.APOSTROPHE:case A.LESS_THAN_SIGN:{this._err(X.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.name+=yt;break}default:this.currentAttr.name+=String.fromCodePoint(pu(t)?Cl(t):t)}}_stateAfterAttributeName(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.SOLIDUS:{this.state=v.SELF_CLOSING_START_TAG;break}case A.EQUALS_SIGN:{this.state=v.BEFORE_ATTRIBUTE_VALUE;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentTagToken();break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=v.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.QUOTATION_MARK:{this.state=v.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this.state=v.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingAttributeValue),this.state=v.DATA,this.emitCurrentTagToken();break}default:this.state=v.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case A.QUOTATION_MARK:{this.state=v.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.value+=yt;break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case A.APOSTROPHE:{this.state=v.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.value+=yt;break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this._leaveAttrValue(),this.state=v.BEFORE_ATTRIBUTE_NAME;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=v.DATA,this.emitCurrentTagToken();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.value+=yt;break}case A.QUOTATION_MARK:case A.APOSTROPHE:case A.LESS_THAN_SIGN:case A.EQUALS_SIGN:case A.GRAVE_ACCENT:{this._err(X.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this._leaveAttrValue(),this.state=v.BEFORE_ATTRIBUTE_NAME;break}case A.SOLIDUS:{this._leaveAttrValue(),this.state=v.SELF_CLOSING_START_TAG;break}case A.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=v.DATA,this.emitCurrentTagToken();break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this._err(X.missingWhitespaceBetweenAttributes),this.state=v.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case A.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=v.DATA,this.emitCurrentTagToken();break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this._err(X.unexpectedSolidusInTag),this.state=v.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentComment(n);break}case A.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.data+=yt;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(Cn.DASH_DASH,!0)?(this._createCommentToken(Cn.DASH_DASH.length+1),this.state=v.COMMENT_START):this._consumeSequenceIfMatch(Cn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Cn.DOCTYPE.length+1),this.state=v.DOCTYPE):this._consumeSequenceIfMatch(Cn.CDATA_START,!0)?this.inForeignNode?this.state=v.CDATA_SECTION:(this._err(X.cdataInHtmlContent),this._createCommentToken(Cn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=v.BOGUS_COMMENT):this._ensureHibernation()||(this._err(X.incorrectlyOpenedComment),this._createCommentToken(2),this.state=v.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_START_DASH;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptClosingOfEmptyComment),this.state=v.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=v.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_END;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptClosingOfEmptyComment),this.state=v.DATA,this.emitCurrentComment(n);break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=v.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_END_DASH;break}case A.LESS_THAN_SIGN:{n.data+="<",this.state=v.COMMENT_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.data+=yt;break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case A.EXCLAMATION_MARK:{n.data+="!",this.state=v.COMMENT_LESS_THAN_SIGN_BANG;break}case A.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=v.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===A.HYPHEN_MINUS?this.state=v.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=v.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===A.HYPHEN_MINUS?this.state=v.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=v.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==A.GREATER_THAN_SIGN&&t!==A.EOF&&this._err(X.nestedComment),this.state=v.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_END;break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=v.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentComment(n);break}case A.EXCLAMATION_MARK:{this.state=v.COMMENT_END_BANG;break}case A.HYPHEN_MINUS:{n.data+="-";break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=v.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{n.data+="--!",this.state=v.COMMENT_END_DASH;break}case A.GREATER_THAN_SIGN:{this._err(X.incorrectlyClosedComment),this.state=v.DATA,this.emitCurrentComment(n);break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=v.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_DOCTYPE_NAME;break}case A.GREATER_THAN_SIGN:{this.state=v.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case A.EOF:{this._err(X.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingWhitespaceBeforeDoctypeName),this.state=v.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(pu(t))this._createDoctypeToken(String.fromCharCode(Cl(t))),this.state=v.DOCTYPE_NAME;else switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.NULL:{this._err(X.unexpectedNullCharacter),this._createDoctypeToken(yt),this.state=v.DOCTYPE_NAME;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=v.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.AFTER_DOCTYPE_NAME;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.name+=yt;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(pu(t)?Cl(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(Cn.PUBLIC,!1)?this.state=v.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Cn.SYSTEM,!1)?this.state=v.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(X.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case A.QUOTATION_MARK:{this._err(X.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this._err(X.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.QUOTATION_MARK:{n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case A.QUOTATION_MARK:{this.state=v.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.publicId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case A.APOSTROPHE:{this.state=v.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.publicId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.QUOTATION_MARK:{this._err(X.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this._err(X.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.QUOTATION_MARK:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case A.QUOTATION_MARK:{this._err(X.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this._err(X.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.QUOTATION_MARK:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case A.QUOTATION_MARK:{this.state=v.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.systemId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case A.APOSTROPHE:{this.state=v.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.systemId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case A.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.NULL:{this._err(X.unexpectedNullCharacter);break}case A.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case A.RIGHT_SQUARE_BRACKET:{this.state=v.CDATA_SECTION_BRACKET;break}case A.EOF:{this._err(X.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===A.RIGHT_SQUARE_BRACKET?this.state=v.CDATA_SECTION_END:(this._emitChars("]"),this.state=v.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case A.GREATER_THAN_SIGN:{this.state=v.DATA;break}case A.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=v.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(A.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&Wy(this.preprocessor.peek(1))?v.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){Wy(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===A.SEMICOLON&&this._err(X.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const Qy=new Set([p.DD,p.DT,p.LI,p.OPTGROUP,p.OPTION,p.P,p.RB,p.RP,p.RT,p.RTC]),Xy=new Set([...Qy,p.CAPTION,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]),Al=new Set([p.APPLET,p.CAPTION,p.HTML,p.MARQUEE,p.OBJECT,p.TABLE,p.TD,p.TEMPLATE,p.TH]),QR=new Set([...Al,p.OL,p.UL]),XR=new Set([...Al,p.BUTTON]),Jy=new Set([p.ANNOTATION_XML,p.MI,p.MN,p.MO,p.MS,p.MTEXT]),Zy=new Set([p.DESC,p.FOREIGN_OBJECT,p.TITLE]),JR=new Set([p.TR,p.TEMPLATE,p.HTML]),ZR=new Set([p.TBODY,p.TFOOT,p.THEAD,p.TEMPLATE,p.HTML]),eL=new Set([p.TABLE,p.TEMPLATE,p.HTML]),tL=new Set([p.TD,p.TH]);class nL{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=p.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===p.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===re.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const o=this._indexOf(t)+1;this.items.splice(o,0,n),this.tagIDs.splice(o,0,r),this.stackTop++,o===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,o===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==re.HTML);this.shortenToLength(Math.max(n,0))}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(Math.max(n,0))}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(Math.max(r,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(_h,re.HTML)}popUntilTableCellPopped(){this.popUntilPopped(tL,re.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(eL,re.HTML)}clearBackToTableBodyContext(){this.clearBackTo(ZR,re.HTML)}clearBackToTableRowContext(){this.clearBackTo(JR,re.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===p.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===p.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const o=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case re.HTML:{if(o===t)return!0;if(n.has(o))return!1;break}case re.SVG:{if(Zy.has(o))return!1;break}case re.MATHML:{if(Jy.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Al)}hasInListItemScope(t){return this.hasInDynamicScope(t,QR)}hasInButtonScope(t){return this.hasInDynamicScope(t,XR)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case re.HTML:{if(_h.has(n))return!0;if(Al.has(n))return!1;break}case re.SVG:{if(Zy.has(n))return!1;break}case re.MATHML:{if(Jy.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===re.HTML)switch(this.tagIDs[n]){case t:return!0;case p.TABLE:case p.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===re.HTML)switch(this.tagIDs[t]){case p.TBODY:case p.THEAD:case p.TFOOT:return!0;case p.TABLE:case p.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===re.HTML)switch(this.tagIDs[n]){case t:return!0;case p.OPTION:case p.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&Qy.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&Xy.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&Xy.has(this.currentTagId);)this.pop()}}const xh=3;var Ir;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(Ir||(Ir={}));const eT={type:Ir.Marker};class rL{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],o=n.length,u=this.treeAdapter.getTagName(t),a=this.treeAdapter.getNamespaceURI(t);for(let c=0;c<this.entries.length;c++){const f=this.entries[c];if(f.type===Ir.Marker)break;const{element:h}=f;if(this.treeAdapter.getTagName(h)===u&&this.treeAdapter.getNamespaceURI(h)===a){const m=this.treeAdapter.getAttrList(h);m.length===o&&r.push({idx:c,attrs:m})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<xh)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<xh)return;const o=new Map(n.map(a=>[a.name,a.value]));let u=0;for(let a=0;a<r.length;a++){const c=r[a];c.attrs.every(f=>o.get(f.name)===f.value)&&(u+=1,u>=xh&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(eT)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:Ir.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:Ir.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(eT);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===Ir.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===Ir.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===Ir.Element&&n.element===t)}}const Ei={createDocument(){return{nodeName:"#document",mode:Gn.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const o=e.childNodes.find(u=>u.nodeName==="#documentType");if(o)o.name=t,o.publicId=n,o.systemId=r;else{const u={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};Ei.appendChild(e,u)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(Ei.isTextNode(n)){n.value+=t;return}}Ei.appendChild(e,Ei.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Ei.isTextNode(r)?r.value+=t:Ei.insertBefore(e,Ei.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation=U(U({},e.sourceCodeLocation),t)}},tT="html",iL="about:legacy-compat",sL="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",nT=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],oL=[...nT,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],uL=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),rT=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],aL=[...rT,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function iT(e,t){return t.some(n=>e.startsWith(n))}function lL(e){return e.name===tT&&e.publicId===null&&(e.systemId===null||e.systemId===iL)}function cL(e){if(e.name!==tT)return Gn.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===sL)return Gn.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),uL.has(n))return Gn.QUIRKS;let r=t===null?oL:nT;if(iT(n,r))return Gn.QUIRKS;if(r=t===null?rT:aL,iT(n,r))return Gn.LIMITED_QUIRKS}return Gn.NO_QUIRKS}const sT={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},fL="definitionurl",dL="definitionURL",hL=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),pL=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:re.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:re.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:re.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:re.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:re.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:re.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:re.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:re.XML}],["xml:space",{prefix:"xml",name:"space",namespace:re.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:re.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:re.XMLNS}]]),mL=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),gL=new Set([p.B,p.BIG,p.BLOCKQUOTE,p.BODY,p.BR,p.CENTER,p.CODE,p.DD,p.DIV,p.DL,p.DT,p.EM,p.EMBED,p.H1,p.H2,p.H3,p.H4,p.H5,p.H6,p.HEAD,p.HR,p.I,p.IMG,p.LI,p.LISTING,p.MENU,p.META,p.NOBR,p.OL,p.P,p.PRE,p.RUBY,p.S,p.SMALL,p.SPAN,p.STRONG,p.STRIKE,p.SUB,p.SUP,p.TABLE,p.TT,p.U,p.UL,p.VAR]);function EL(e){const t=e.tagID;return t===p.FONT&&e.attrs.some(({name:r})=>r===Xi.COLOR||r===Xi.SIZE||r===Xi.FACE)||gL.has(t)}function oT(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===fL){e.attrs[t].name=dL;break}}function uT(e){for(let t=0;t<e.attrs.length;t++){const n=hL.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Sh(e){for(let t=0;t<e.attrs.length;t++){const n=pL.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function yL(e){const t=mL.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=eo(e.tagName))}function TL(e,t){return t===re.MATHML&&(e===p.MI||e===p.MO||e===p.MN||e===p.MS||e===p.MTEXT)}function bL(e,t,n){if(t===re.MATHML&&e===p.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Xi.ENCODING){const o=n[r].value.toLowerCase();return o===sT.TEXT_HTML||o===sT.APPLICATION_XML}}return t===re.SVG&&(e===p.FOREIGN_OBJECT||e===p.DESC||e===p.TITLE)}function _L(e,t,n,r){return(!r||r===re.HTML)&&bL(e,t,n)||(!r||r===re.MATHML)&&TL(e,t)}const xL="hidden",SL=8,wL=3;var P;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(P||(P={}));const CL={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},aT=new Set([p.TABLE,p.TBODY,p.TFOOT,p.THEAD,p.TR]),lT={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Ei,onParseError:null};class cT{constructor(t,n,r=null,o=null){this.fragmentContext=r,this.scriptHandler=o,this.currentToken=null,this.stopped=!1,this.insertionMode=P.INITIAL,this.originalInsertionMode=P.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options=U(U({},lT),t),this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n!=null?n:this.treeAdapter.createDocument(),this.tokenizer=new KR(this.options,this),this.activeFormattingElements=new rL(this.treeAdapter),this.fragmentContextID=r?eo(this.treeAdapter.getTagName(r)):p.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new nL(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r=U(U({},lT),n);t!=null||(t=r.treeAdapter.createElement(j.TEMPLATE,re.HTML,[]));const o=r.treeAdapter.createElement("documentmock",re.HTML,[]),u=new this(r,o,t);return u.fragmentContextID===p.TEMPLATE&&u.tmplInsertionModeStack.unshift(P.IN_TEMPLATE),u._initTokenizerForFragmentParsing(),u._insertFakeRootElement(),u._resetInsertionMode(),u._findFormInFragmentContext(),u}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var o;if(!this.onParseError)return;const u=(o=t.location)!==null&&o!==void 0?o:CL,a={code:n,startLine:u.startLine,startCol:u.startCol,startOffset:u.startOffset,endLine:r?u.startLine:u.endLine,endCol:r?u.startCol:u.endCol,endOffset:r?u.startOffset:u.endOffset};this.onParseError(a)}onItemPush(t,n,r){var o,u;(u=(o=this.treeAdapter).onItemPush)===null||u===void 0||u.call(o,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,o;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(o=(r=this.treeAdapter).onItemPop)===null||o===void 0||o.call(r,t,this.openElements.current),n){let u,a;this.openElements.stackTop===0&&this.fragmentContext?(u=this.fragmentContext,a=this.fragmentContextID):{current:u,currentTagId:a}=this.openElements,this._setContextModes(u,a)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===re.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,re.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=P.TEXT}switchToPlaintextParsing(){this.insertionMode=P.TEXT,this.originalInsertionMode=P.IN_BODY,this.tokenizer.state=Pt.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===j.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==re.HTML))switch(this.fragmentContextID){case p.TITLE:case p.TEXTAREA:{this.tokenizer.state=Pt.RCDATA;break}case p.STYLE:case p.XMP:case p.IFRAME:case p.NOEMBED:case p.NOFRAMES:case p.NOSCRIPT:{this.tokenizer.state=Pt.RAWTEXT;break}case p.SCRIPT:{this.tokenizer.state=Pt.SCRIPT_DATA;break}case p.PLAINTEXT:{this.tokenizer.state=Pt.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",o=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,o),t.location){const a=this.treeAdapter.getChildNodes(this.document).find(c=>this.treeAdapter.isDocumentTypeNode(c));a&&this.treeAdapter.setNodeSourceCodeLocation(a,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&ye(U({},n),{startTag:n});this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r!=null?r:this.document,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,re.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,re.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(j.HTML,re.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,p.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const o=this.treeAdapter.getChildNodes(n),u=r?o.lastIndexOf(r):o.length,a=o[u-1];if(this.treeAdapter.getNodeSourceCodeLocation(a)){const{endLine:f,endCol:h,endOffset:m}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(a,{endLine:f,endCol:h,endOffset:m})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(a,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,o=this.treeAdapter.getTagName(t),u=n.type===qe.END_TAG&&o===n.tagName?{endTag:U({},r),endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,u)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===p.SVG&&this.treeAdapter.getTagName(n)===j.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===re.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===p.MGLYPH||t.tagID===p.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,re.HTML)}_processToken(t){switch(t.type){case qe.CHARACTER:{this.onCharacter(t);break}case qe.NULL_CHARACTER:{this.onNullCharacter(t);break}case qe.COMMENT:{this.onComment(t);break}case qe.DOCTYPE:{this.onDoctype(t);break}case qe.START_TAG:{this._processStartTag(t);break}case qe.END_TAG:{this.onEndTag(t);break}case qe.EOF:{this.onEof(t);break}case qe.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const o=this.treeAdapter.getNamespaceURI(n),u=this.treeAdapter.getAttrList(n);return _L(t,o,u,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===Ir.Marker||this.openElements.contains(o.element)),r=n===-1?t-1:n-1;for(let o=r;o>=0;o--){const u=this.activeFormattingElements.entries[o];this._insertElement(u.token,this.treeAdapter.getNamespaceURI(u.element)),u.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=P.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(p.P),this.openElements.popUntilTagNamePopped(p.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case p.TR:{this.insertionMode=P.IN_ROW;return}case p.TBODY:case p.THEAD:case p.TFOOT:{this.insertionMode=P.IN_TABLE_BODY;return}case p.CAPTION:{this.insertionMode=P.IN_CAPTION;return}case p.COLGROUP:{this.insertionMode=P.IN_COLUMN_GROUP;return}case p.TABLE:{this.insertionMode=P.IN_TABLE;return}case p.BODY:{this.insertionMode=P.IN_BODY;return}case p.FRAMESET:{this.insertionMode=P.IN_FRAMESET;return}case p.SELECT:{this._resetInsertionModeForSelect(t);return}case p.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case p.HTML:{this.insertionMode=this.headElement?P.AFTER_HEAD:P.BEFORE_HEAD;return}case p.TD:case p.TH:{if(t>0){this.insertionMode=P.IN_CELL;return}break}case p.HEAD:{if(t>0){this.insertionMode=P.IN_HEAD;return}break}}this.insertionMode=P.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===p.TEMPLATE)break;if(r===p.TABLE){this.insertionMode=P.IN_SELECT_IN_TABLE;return}}this.insertionMode=P.IN_SELECT}_isElementCausesFosterParenting(t){return aT.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case p.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===re.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case p.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return qR[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){t4(this,t);return}switch(this.insertionMode){case P.INITIAL:{mu(this,t);break}case P.BEFORE_HTML:{gu(this,t);break}case P.BEFORE_HEAD:{Eu(this,t);break}case P.IN_HEAD:{yu(this,t);break}case P.IN_HEAD_NO_SCRIPT:{Tu(this,t);break}case P.AFTER_HEAD:{bu(this,t);break}case P.IN_BODY:case P.IN_CAPTION:case P.IN_CELL:case P.IN_TEMPLATE:{dT(this,t);break}case P.TEXT:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{vh(this,t);break}case P.IN_TABLE_TEXT:{bT(this,t);break}case P.IN_COLUMN_GROUP:{Nl(this,t);break}case P.AFTER_BODY:{Pl(this,t);break}case P.AFTER_AFTER_BODY:{Rl(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){e4(this,t);return}switch(this.insertionMode){case P.INITIAL:{mu(this,t);break}case P.BEFORE_HTML:{gu(this,t);break}case P.BEFORE_HEAD:{Eu(this,t);break}case P.IN_HEAD:{yu(this,t);break}case P.IN_HEAD_NO_SCRIPT:{Tu(this,t);break}case P.AFTER_HEAD:{bu(this,t);break}case P.TEXT:{this._insertCharacters(t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{vh(this,t);break}case P.IN_COLUMN_GROUP:{Nl(this,t);break}case P.AFTER_BODY:{Pl(this,t);break}case P.AFTER_AFTER_BODY:{Rl(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){Ch(this,t);return}switch(this.insertionMode){case P.INITIAL:case P.BEFORE_HTML:case P.BEFORE_HEAD:case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:case P.IN_BODY:case P.IN_TABLE:case P.IN_CAPTION:case P.IN_COLUMN_GROUP:case P.IN_TABLE_BODY:case P.IN_ROW:case P.IN_CELL:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:case P.IN_TEMPLATE:case P.IN_FRAMESET:case P.AFTER_FRAMESET:{Ch(this,t);break}case P.IN_TABLE_TEXT:{Su(this,t);break}case P.AFTER_BODY:{PL(this,t);break}case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{RL(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case P.INITIAL:{LL(this,t);break}case P.BEFORE_HEAD:case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:{this._err(t,X.misplacedDoctype);break}case P.IN_TABLE_TEXT:{Su(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,X.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?n4(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case P.INITIAL:{mu(this,t);break}case P.BEFORE_HTML:{DL(this,t);break}case P.BEFORE_HEAD:{ML(this,t);break}case P.IN_HEAD:{dr(this,t);break}case P.IN_HEAD_NO_SCRIPT:{HL(this,t);break}case P.AFTER_HEAD:{jL(this,t);break}case P.IN_BODY:{on(this,t);break}case P.IN_TABLE:{to(this,t);break}case P.IN_TABLE_TEXT:{Su(this,t);break}case P.IN_CAPTION:{B6(this,t);break}case P.IN_COLUMN_GROUP:{kh(this,t);break}case P.IN_TABLE_BODY:{Ol(this,t);break}case P.IN_ROW:{Il(this,t);break}case P.IN_CELL:{z6(this,t);break}case P.IN_SELECT:{ST(this,t);break}case P.IN_SELECT_IN_TABLE:{$6(this,t);break}case P.IN_TEMPLATE:{q6(this,t);break}case P.AFTER_BODY:{W6(this,t);break}case P.IN_FRAMESET:{G6(this,t);break}case P.AFTER_FRAMESET:{Q6(this,t);break}case P.AFTER_AFTER_BODY:{J6(this,t);break}case P.AFTER_AFTER_FRAMESET:{Z6(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?r4(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case P.INITIAL:{mu(this,t);break}case P.BEFORE_HTML:{FL(this,t);break}case P.BEFORE_HEAD:{BL(this,t);break}case P.IN_HEAD:{UL(this,t);break}case P.IN_HEAD_NO_SCRIPT:{zL(this,t);break}case P.AFTER_HEAD:{$L(this,t);break}case P.IN_BODY:{kl(this,t);break}case P.TEXT:{k6(this,t);break}case P.IN_TABLE:{_u(this,t);break}case P.IN_TABLE_TEXT:{Su(this,t);break}case P.IN_CAPTION:{U6(this,t);break}case P.IN_COLUMN_GROUP:{H6(this,t);break}case P.IN_TABLE_BODY:{Nh(this,t);break}case P.IN_ROW:{xT(this,t);break}case P.IN_CELL:{j6(this,t);break}case P.IN_SELECT:{wT(this,t);break}case P.IN_SELECT_IN_TABLE:{V6(this,t);break}case P.IN_TEMPLATE:{Y6(this,t);break}case P.AFTER_BODY:{AT(this,t);break}case P.IN_FRAMESET:{K6(this,t);break}case P.AFTER_FRAMESET:{X6(this,t);break}case P.AFTER_AFTER_BODY:{Rl(this,t);break}}}onEof(t){switch(this.insertionMode){case P.INITIAL:{mu(this,t);break}case P.BEFORE_HTML:{gu(this,t);break}case P.BEFORE_HEAD:{Eu(this,t);break}case P.IN_HEAD:{yu(this,t);break}case P.IN_HEAD_NO_SCRIPT:{Tu(this,t);break}case P.AFTER_HEAD:{bu(this,t);break}case P.IN_BODY:case P.IN_TABLE:case P.IN_CAPTION:case P.IN_COLUMN_GROUP:case P.IN_TABLE_BODY:case P.IN_ROW:case P.IN_CELL:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:{yT(this,t);break}case P.TEXT:{N6(this,t);break}case P.IN_TABLE_TEXT:{Su(this,t);break}case P.IN_TEMPLATE:{CT(this,t);break}case P.AFTER_BODY:case P.IN_FRAMESET:case P.AFTER_FRAMESET:case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{Ah(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===A.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:case P.TEXT:case P.IN_COLUMN_GROUP:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:case P.IN_FRAMESET:case P.AFTER_FRAMESET:{this._insertCharacters(t);break}case P.IN_BODY:case P.IN_CAPTION:case P.IN_CELL:case P.IN_TEMPLATE:case P.AFTER_BODY:case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{fT(this,t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{vh(this,t);break}case P.IN_TABLE_TEXT:{TT(this,t);break}}}}function AL(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):ET(e,t),n}function vL(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const o=e.openElements.items[r];if(o===t.element)break;e._isSpecialElement(o,e.openElements.tagIDs[r])&&(n=o)}return n||(e.openElements.shortenToLength(Math.max(r,0)),e.activeFormattingElements.removeEntry(t)),n}function kL(e,t,n){let r=t,o=e.openElements.getCommonAncestor(t);for(let u=0,a=o;a!==n;u++,a=o){o=e.openElements.getCommonAncestor(a);const c=e.activeFormattingElements.getElementEntry(a),f=c&&u>=wL;!c||f?(f&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(a)):(a=NL(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(a,r),r=a)}return r}function NL(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function OL(e,t,n){const r=e.treeAdapter.getTagName(t),o=eo(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const u=e.treeAdapter.getNamespaceURI(t);o===p.TEMPLATE&&u===re.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function IL(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:o}=n,u=e.treeAdapter.createElement(o.tagName,r,o.attrs);e._adoptNodes(t,u),e.treeAdapter.appendChild(t,u),e.activeFormattingElements.insertElementAfterBookmark(u,o),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,u,o.tagID)}function wh(e,t){for(let n=0;n<SL;n++){const r=AL(e,t);if(!r)break;const o=vL(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const u=kL(e,o,r.element),a=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(u),a&&OL(e,a,u),IL(e,o,r)}}function Ch(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function PL(e,t){e._appendCommentNode(t,e.openElements.items[0])}function RL(e,t){e._appendCommentNode(t,e.document)}function Ah(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],o=e.treeAdapter.getNodeSourceCodeLocation(r);if(o&&!o.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const u=e.openElements.items[1],a=e.treeAdapter.getNodeSourceCodeLocation(u);a&&!a.endTag&&e._setEndLocation(u,t)}}}}function LL(e,t){e._setDocumentType(t);const n=t.forceQuirks?Gn.QUIRKS:cL(t);lL(t)||e._err(t,X.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=P.BEFORE_HTML}function mu(e,t){e._err(t,X.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Gn.QUIRKS),e.insertionMode=P.BEFORE_HTML,e._processToken(t)}function DL(e,t){t.tagID===p.HTML?(e._insertElement(t,re.HTML),e.insertionMode=P.BEFORE_HEAD):gu(e,t)}function FL(e,t){const n=t.tagID;(n===p.HTML||n===p.HEAD||n===p.BODY||n===p.BR)&&gu(e,t)}function gu(e,t){e._insertFakeRootElement(),e.insertionMode=P.BEFORE_HEAD,e._processToken(t)}function ML(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.HEAD:{e._insertElement(t,re.HTML),e.headElement=e.openElements.current,e.insertionMode=P.IN_HEAD;break}default:Eu(e,t)}}function BL(e,t){const n=t.tagID;n===p.HEAD||n===p.BODY||n===p.HTML||n===p.BR?Eu(e,t):e._err(t,X.endTagWithoutMatchingOpenElement)}function Eu(e,t){e._insertFakeElement(j.HEAD,p.HEAD),e.headElement=e.openElements.current,e.insertionMode=P.IN_HEAD,e._processToken(t)}function dr(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:{e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.TITLE:{e._switchToTextParsing(t,Pt.RCDATA);break}case p.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Pt.RAWTEXT):(e._insertElement(t,re.HTML),e.insertionMode=P.IN_HEAD_NO_SCRIPT);break}case p.NOFRAMES:case p.STYLE:{e._switchToTextParsing(t,Pt.RAWTEXT);break}case p.SCRIPT:{e._switchToTextParsing(t,Pt.SCRIPT_DATA);break}case p.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=P.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(P.IN_TEMPLATE);break}case p.HEAD:{e._err(t,X.misplacedStartTagForHeadElement);break}default:yu(e,t)}}function UL(e,t){switch(t.tagID){case p.HEAD:{e.openElements.pop(),e.insertionMode=P.AFTER_HEAD;break}case p.BODY:case p.BR:case p.HTML:{yu(e,t);break}case p.TEMPLATE:{Ji(e,t);break}default:e._err(t,X.endTagWithoutMatchingOpenElement)}}function Ji(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==p.TEMPLATE&&e._err(t,X.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,X.endTagWithoutMatchingOpenElement)}function yu(e,t){e.openElements.pop(),e.insertionMode=P.AFTER_HEAD,e._processToken(t)}function HL(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.BASEFONT:case p.BGSOUND:case p.HEAD:case p.LINK:case p.META:case p.NOFRAMES:case p.STYLE:{dr(e,t);break}case p.NOSCRIPT:{e._err(t,X.nestedNoscriptInHead);break}default:Tu(e,t)}}function zL(e,t){switch(t.tagID){case p.NOSCRIPT:{e.openElements.pop(),e.insertionMode=P.IN_HEAD;break}case p.BR:{Tu(e,t);break}default:e._err(t,X.endTagWithoutMatchingOpenElement)}}function Tu(e,t){const n=t.type===qe.EOF?X.openElementsLeftAfterEof:X.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=P.IN_HEAD,e._processToken(t)}function jL(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.BODY:{e._insertElement(t,re.HTML),e.framesetOk=!1,e.insertionMode=P.IN_BODY;break}case p.FRAMESET:{e._insertElement(t,re.HTML),e.insertionMode=P.IN_FRAMESET;break}case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:case p.NOFRAMES:case p.SCRIPT:case p.STYLE:case p.TEMPLATE:case p.TITLE:{e._err(t,X.abandonedHeadElementChild),e.openElements.push(e.headElement,p.HEAD),dr(e,t),e.openElements.remove(e.headElement);break}case p.HEAD:{e._err(t,X.misplacedStartTagForHeadElement);break}default:bu(e,t)}}function $L(e,t){switch(t.tagID){case p.BODY:case p.HTML:case p.BR:{bu(e,t);break}case p.TEMPLATE:{Ji(e,t);break}default:e._err(t,X.endTagWithoutMatchingOpenElement)}}function bu(e,t){e._insertFakeElement(j.BODY,p.BODY),e.insertionMode=P.IN_BODY,vl(e,t)}function vl(e,t){switch(t.type){case qe.CHARACTER:{dT(e,t);break}case qe.WHITESPACE_CHARACTER:{fT(e,t);break}case qe.COMMENT:{Ch(e,t);break}case qe.START_TAG:{on(e,t);break}case qe.END_TAG:{kl(e,t);break}case qe.EOF:{yT(e,t);break}}}function fT(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function dT(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function VL(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function qL(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function YL(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_FRAMESET)}function WL(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML)}function GL(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&_h.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,re.HTML)}function KL(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function QL(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),n||(e.formElement=e.openElements.current))}function XL(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const o=e.openElements.tagIDs[r];if(n===p.LI&&o===p.LI||(n===p.DD||n===p.DT)&&(o===p.DD||o===p.DT)){e.openElements.generateImpliedEndTagsWithExclusion(o),e.openElements.popUntilTagNamePopped(o);break}if(o!==p.ADDRESS&&o!==p.DIV&&o!==p.P&&e._isSpecialElement(e.openElements.items[r],o))break}e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML)}function JL(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),e.tokenizer.state=Pt.PLAINTEXT}function ZL(e,t){e.openElements.hasInScope(p.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.framesetOk=!1}function e6(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(j.A);n&&(wh(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function t6(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function n6(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(p.NOBR)&&(wh(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,re.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function r6(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function i6(e,t){e.treeAdapter.getDocumentMode(e.document)!==Gn.QUIRKS&&e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),e.framesetOk=!1,e.insertionMode=P.IN_TABLE}function hT(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,re.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function pT(e){const t=Yy(e,Xi.TYPE);return t!=null&&t.toLowerCase()===xL}function s6(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,re.HTML),pT(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function o6(e,t){e._appendElement(t,re.HTML),t.ackSelfClosing=!0}function u6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._appendElement(t,re.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function a6(e,t){t.tagName=j.IMG,t.tagID=p.IMG,hT(e,t)}function l6(e,t){e._insertElement(t,re.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Pt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=P.TEXT}function c6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Pt.RAWTEXT)}function f6(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Pt.RAWTEXT)}function mT(e,t){e._switchToTextParsing(t,Pt.RAWTEXT)}function d6(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===P.IN_TABLE||e.insertionMode===P.IN_CAPTION||e.insertionMode===P.IN_TABLE_BODY||e.insertionMode===P.IN_ROW||e.insertionMode===P.IN_CELL?P.IN_SELECT_IN_TABLE:P.IN_SELECT}function h6(e,t){e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML)}function p6(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,re.HTML)}function m6(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(p.RTC),e._insertElement(t,re.HTML)}function g6(e,t){e._reconstructActiveFormattingElements(),oT(t),Sh(t),t.selfClosing?e._appendElement(t,re.MATHML):e._insertElement(t,re.MATHML),t.ackSelfClosing=!0}function E6(e,t){e._reconstructActiveFormattingElements(),uT(t),Sh(t),t.selfClosing?e._appendElement(t,re.SVG):e._insertElement(t,re.SVG),t.ackSelfClosing=!0}function gT(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML)}function on(e,t){switch(t.tagID){case p.I:case p.S:case p.B:case p.U:case p.EM:case p.TT:case p.BIG:case p.CODE:case p.FONT:case p.SMALL:case p.STRIKE:case p.STRONG:{t6(e,t);break}case p.A:{e6(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{GL(e,t);break}case p.P:case p.DL:case p.OL:case p.UL:case p.DIV:case p.DIR:case p.NAV:case p.MAIN:case p.MENU:case p.ASIDE:case p.CENTER:case p.FIGURE:case p.FOOTER:case p.HEADER:case p.HGROUP:case p.DIALOG:case p.DETAILS:case p.ADDRESS:case p.ARTICLE:case p.SEARCH:case p.SECTION:case p.SUMMARY:case p.FIELDSET:case p.BLOCKQUOTE:case p.FIGCAPTION:{WL(e,t);break}case p.LI:case p.DD:case p.DT:{XL(e,t);break}case p.BR:case p.IMG:case p.WBR:case p.AREA:case p.EMBED:case p.KEYGEN:{hT(e,t);break}case p.HR:{u6(e,t);break}case p.RB:case p.RTC:{p6(e,t);break}case p.RT:case p.RP:{m6(e,t);break}case p.PRE:case p.LISTING:{KL(e,t);break}case p.XMP:{c6(e,t);break}case p.SVG:{E6(e,t);break}case p.HTML:{VL(e,t);break}case p.BASE:case p.LINK:case p.META:case p.STYLE:case p.TITLE:case p.SCRIPT:case p.BGSOUND:case p.BASEFONT:case p.TEMPLATE:{dr(e,t);break}case p.BODY:{qL(e,t);break}case p.FORM:{QL(e,t);break}case p.NOBR:{n6(e,t);break}case p.MATH:{g6(e,t);break}case p.TABLE:{i6(e,t);break}case p.INPUT:{s6(e,t);break}case p.PARAM:case p.TRACK:case p.SOURCE:{o6(e,t);break}case p.IMAGE:{a6(e,t);break}case p.BUTTON:{ZL(e,t);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{r6(e,t);break}case p.IFRAME:{f6(e,t);break}case p.SELECT:{d6(e,t);break}case p.OPTION:case p.OPTGROUP:{h6(e,t);break}case p.NOEMBED:case p.NOFRAMES:{mT(e,t);break}case p.FRAMESET:{YL(e,t);break}case p.TEXTAREA:{l6(e,t);break}case p.NOSCRIPT:{e.options.scriptingEnabled?mT(e,t):gT(e,t);break}case p.PLAINTEXT:{JL(e,t);break}case p.COL:case p.TH:case p.TD:case p.TR:case p.HEAD:case p.FRAME:case p.TBODY:case p.TFOOT:case p.THEAD:case p.CAPTION:case p.COLGROUP:break;default:gT(e,t)}}function y6(e,t){if(e.openElements.hasInScope(p.BODY)&&(e.insertionMode=P.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function T6(e,t){e.openElements.hasInScope(p.BODY)&&(e.insertionMode=P.AFTER_BODY,AT(e,t))}function b6(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function _6(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(p.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(p.FORM):n&&e.openElements.remove(n))}function x6(e){e.openElements.hasInButtonScope(p.P)||e._insertFakeElement(j.P,p.P),e._closePElement()}function S6(e){e.openElements.hasInListItemScope(p.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(p.LI),e.openElements.popUntilTagNamePopped(p.LI))}function w6(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function C6(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function A6(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function v6(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(j.BR,p.BR),e.openElements.pop(),e.framesetOk=!1}function ET(e,t){const n=t.tagName,r=t.tagID;for(let o=e.openElements.stackTop;o>0;o--){const u=e.openElements.items[o],a=e.openElements.tagIDs[o];if(r===a&&(r!==p.UNKNOWN||e.treeAdapter.getTagName(u)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=o&&e.openElements.shortenToLength(o);break}if(e._isSpecialElement(u,a))break}}function kl(e,t){switch(t.tagID){case p.A:case p.B:case p.I:case p.S:case p.U:case p.EM:case p.TT:case p.BIG:case p.CODE:case p.FONT:case p.NOBR:case p.SMALL:case p.STRIKE:case p.STRONG:{wh(e,t);break}case p.P:{x6(e);break}case p.DL:case p.UL:case p.OL:case p.DIR:case p.DIV:case p.NAV:case p.PRE:case p.MAIN:case p.MENU:case p.ASIDE:case p.BUTTON:case p.CENTER:case p.FIGURE:case p.FOOTER:case p.HEADER:case p.HGROUP:case p.DIALOG:case p.ADDRESS:case p.ARTICLE:case p.DETAILS:case p.SEARCH:case p.SECTION:case p.SUMMARY:case p.LISTING:case p.FIELDSET:case p.BLOCKQUOTE:case p.FIGCAPTION:{b6(e,t);break}case p.LI:{S6(e);break}case p.DD:case p.DT:{w6(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{C6(e);break}case p.BR:{v6(e);break}case p.BODY:{y6(e,t);break}case p.HTML:{T6(e,t);break}case p.FORM:{_6(e);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{A6(e,t);break}case p.TEMPLATE:{Ji(e,t);break}default:ET(e,t)}}function yT(e,t){e.tmplInsertionModeStack.length>0?CT(e,t):Ah(e,t)}function k6(e,t){var n;t.tagID===p.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function N6(e,t){e._err(t,X.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function vh(e,t){if(e.openElements.currentTagId!==void 0&&aT.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=P.IN_TABLE_TEXT,t.type){case qe.CHARACTER:{bT(e,t);break}case qe.WHITESPACE_CHARACTER:{TT(e,t);break}}else xu(e,t)}function O6(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_CAPTION}function I6(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_COLUMN_GROUP}function P6(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(j.COLGROUP,p.COLGROUP),e.insertionMode=P.IN_COLUMN_GROUP,kh(e,t)}function R6(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_TABLE_BODY}function L6(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(j.TBODY,p.TBODY),e.insertionMode=P.IN_TABLE_BODY,Ol(e,t)}function D6(e,t){e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function F6(e,t){pT(t)?e._appendElement(t,re.HTML):xu(e,t),t.ackSelfClosing=!0}function M6(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,re.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function to(e,t){switch(t.tagID){case p.TD:case p.TH:case p.TR:{L6(e,t);break}case p.STYLE:case p.SCRIPT:case p.TEMPLATE:{dr(e,t);break}case p.COL:{P6(e,t);break}case p.FORM:{M6(e,t);break}case p.TABLE:{D6(e,t);break}case p.TBODY:case p.TFOOT:case p.THEAD:{R6(e,t);break}case p.INPUT:{F6(e,t);break}case p.CAPTION:{O6(e,t);break}case p.COLGROUP:{I6(e,t);break}default:xu(e,t)}}function _u(e,t){switch(t.tagID){case p.TABLE:{e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode());break}case p.TEMPLATE:{Ji(e,t);break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:case p.TBODY:case p.TD:case p.TFOOT:case p.TH:case p.THEAD:case p.TR:break;default:xu(e,t)}}function xu(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,vl(e,t),e.fosterParentingEnabled=n}function TT(e,t){e.pendingCharacterTokens.push(t)}function bT(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Su(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)xu(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const _T=new Set([p.CAPTION,p.COL,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]);function B6(e,t){const n=t.tagID;_T.has(n)?e.openElements.hasInTableScope(p.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_TABLE,to(e,t)):on(e,t)}function U6(e,t){const n=t.tagID;switch(n){case p.CAPTION:case p.TABLE:{e.openElements.hasInTableScope(p.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_TABLE,n===p.TABLE&&_u(e,t));break}case p.BODY:case p.COL:case p.COLGROUP:case p.HTML:case p.TBODY:case p.TD:case p.TFOOT:case p.TH:case p.THEAD:case p.TR:break;default:kl(e,t)}}function kh(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.COL:{e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.TEMPLATE:{dr(e,t);break}default:Nl(e,t)}}function H6(e,t){switch(t.tagID){case p.COLGROUP:{e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=P.IN_TABLE);break}case p.TEMPLATE:{Ji(e,t);break}case p.COL:break;default:Nl(e,t)}}function Nl(e,t){e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=P.IN_TABLE,e._processToken(t))}function Ol(e,t){switch(t.tagID){case p.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_ROW;break}case p.TH:case p.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(j.TR,p.TR),e.insertionMode=P.IN_ROW,Il(e,t);break}case p.CAPTION:case p.COL:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE,to(e,t));break}default:to(e,t)}}function Nh(e,t){const n=t.tagID;switch(t.tagID){case p.TBODY:case p.TFOOT:case p.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE);break}case p.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE,_u(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:case p.TD:case p.TH:case p.TR:break;default:_u(e,t)}}function Il(e,t){switch(t.tagID){case p.TH:case p.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_CELL,e.activeFormattingElements.insertMarker();break}case p.CAPTION:case p.COL:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:case p.TR:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY,Ol(e,t));break}default:to(e,t)}}function xT(e,t){switch(t.tagID){case p.TR:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY);break}case p.TABLE:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY,Nh(e,t));break}case p.TBODY:case p.TFOOT:case p.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(p.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY,Nh(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:case p.TD:case p.TH:break;default:_u(e,t)}}function z6(e,t){const n=t.tagID;_T.has(n)?(e.openElements.hasInTableScope(p.TD)||e.openElements.hasInTableScope(p.TH))&&(e._closeTableCell(),Il(e,t)):on(e,t)}function j6(e,t){const n=t.tagID;switch(n){case p.TD:case p.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_ROW);break}case p.TABLE:case p.TBODY:case p.TFOOT:case p.THEAD:case p.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),xT(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:break;default:kl(e,t)}}function ST(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.OPTION:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._insertElement(t,re.HTML);break}case p.OPTGROUP:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._insertElement(t,re.HTML);break}case p.HR:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.INPUT:case p.KEYGEN:case p.TEXTAREA:case p.SELECT:{e.openElements.hasInSelectScope(p.SELECT)&&(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode(),t.tagID!==p.SELECT&&e._processStartTag(t));break}case p.SCRIPT:case p.TEMPLATE:{dr(e,t);break}}}function wT(e,t){switch(t.tagID){case p.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===p.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===p.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop();break}case p.OPTION:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop();break}case p.SELECT:{e.openElements.hasInSelectScope(p.SELECT)&&(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode());break}case p.TEMPLATE:{Ji(e,t);break}}}function $6(e,t){const n=t.tagID;n===p.CAPTION||n===p.TABLE||n===p.TBODY||n===p.TFOOT||n===p.THEAD||n===p.TR||n===p.TD||n===p.TH?(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode(),e._processStartTag(t)):ST(e,t)}function V6(e,t){const n=t.tagID;n===p.CAPTION||n===p.TABLE||n===p.TBODY||n===p.TFOOT||n===p.THEAD||n===p.TR||n===p.TD||n===p.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode(),e.onEndTag(t)):wT(e,t)}function q6(e,t){switch(t.tagID){case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:case p.NOFRAMES:case p.SCRIPT:case p.STYLE:case p.TEMPLATE:case p.TITLE:{dr(e,t);break}case p.CAPTION:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:{e.tmplInsertionModeStack[0]=P.IN_TABLE,e.insertionMode=P.IN_TABLE,to(e,t);break}case p.COL:{e.tmplInsertionModeStack[0]=P.IN_COLUMN_GROUP,e.insertionMode=P.IN_COLUMN_GROUP,kh(e,t);break}case p.TR:{e.tmplInsertionModeStack[0]=P.IN_TABLE_BODY,e.insertionMode=P.IN_TABLE_BODY,Ol(e,t);break}case p.TD:case p.TH:{e.tmplInsertionModeStack[0]=P.IN_ROW,e.insertionMode=P.IN_ROW,Il(e,t);break}default:e.tmplInsertionModeStack[0]=P.IN_BODY,e.insertionMode=P.IN_BODY,on(e,t)}}function Y6(e,t){t.tagID===p.TEMPLATE&&Ji(e,t)}function CT(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):Ah(e,t)}function W6(e,t){t.tagID===p.HTML?on(e,t):Pl(e,t)}function AT(e,t){var n;if(t.tagID===p.HTML){if(e.fragmentContext||(e.insertionMode=P.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===p.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Pl(e,t)}function Pl(e,t){e.insertionMode=P.IN_BODY,vl(e,t)}function G6(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.FRAMESET:{e._insertElement(t,re.HTML);break}case p.FRAME:{e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.NOFRAMES:{dr(e,t);break}}}function K6(e,t){t.tagID===p.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==p.FRAMESET&&(e.insertionMode=P.AFTER_FRAMESET))}function Q6(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.NOFRAMES:{dr(e,t);break}}}function X6(e,t){t.tagID===p.HTML&&(e.insertionMode=P.AFTER_AFTER_FRAMESET)}function J6(e,t){t.tagID===p.HTML?on(e,t):Rl(e,t)}function Rl(e,t){e.insertionMode=P.IN_BODY,vl(e,t)}function Z6(e,t){switch(t.tagID){case p.HTML:{on(e,t);break}case p.NOFRAMES:{dr(e,t);break}}}function e4(e,t){t.chars=yt,e._insertCharacters(t)}function t4(e,t){e._insertCharacters(t),e.framesetOk=!1}function vT(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==re.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function n4(e,t){if(EL(t))vT(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===re.MATHML?oT(t):r===re.SVG&&(yL(t),uT(t)),Sh(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function r4(e,t){if(t.tagID===p.P||t.tagID===p.BR){vT(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===re.HTML){e._endTagOutsideForeignContent(t);break}const o=e.treeAdapter.getTagName(r);if(o.toLowerCase()===t.tagName){t.tagName=o,e.openElements.shortenToLength(n);break}}}j.AREA,j.BASE,j.BASEFONT,j.BGSOUND,j.BR,j.COL,j.EMBED,j.FRAME,j.HR,j.IMG,j.INPUT,j.KEYGEN,j.LINK,j.META,j.PARAM,j.SOURCE,j.TRACK,j.WBR;const i4=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,s4=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),kT={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function NT(e,t){const n=m4(e),r=zy("type",{handlers:{root:o4,element:u4,text:a4,comment:IT,doctype:l4,raw:f4},unknown:d4}),o={parser:n?new cT(kT):cT.getFragmentParser(void 0,kT),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),no(o,Nr());const u=n?o.parser.document:o.parser.getFragment(),a=oR(u,{file:o.options.file});return o.stitches&&xl(a,"comment",function(c,f,h){const m=c;if(m.value.stitch&&h&&f!==void 0){const E=h.children;return E[f]=m.value.stitch,f}}),a.type==="root"&&a.children.length===1&&a.children[0].type===e.type?a.children[0]:a}function OT(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function o4(e,t){OT(e.children,t)}function u4(e,t){h4(e,t),OT(e.children,t),p4(e,t)}function a4(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:qe.CHARACTER,chars:e.value,location:wu(e)};no(t,Nr(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function l4(e,t){const n={type:qe.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:wu(e)};no(t,Nr(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function c4(e,t){t.stitches=!0;const n=g4(e);if("children"in e&&"children"in n){const r=NT({type:"root",children:e.children},t.options);n.children=r.children}IT({type:"comment",value:{stitch:n}},t)}function IT(e,t){const n=e.value,r={type:qe.COMMENT,data:n,location:wu(e)};no(t,Nr(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function f4(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,PT(t,Nr(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(i4,"&lt;$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function d4(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))c4(n,t);else{let r="";throw s4.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function no(e,t){PT(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=Pt.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function PT(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function h4(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===Pt.PLAINTEXT)return;no(t,Nr(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Ki.html;o===Ki.html&&n==="svg"&&(o=Ki.svg);const u=_R(ye(U({},e),{children:[]}),{space:o===Ki.svg?"svg":"html"}),a={type:qe.START_TAG,tagName:n,tagID:eo(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in u?u.attrs:[],location:wu(e)};t.parser.currentToken=a,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function p4(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&NR.includes(n)||t.parser.tokenizer.state===Pt.PLAINTEXT)return;no(t,fl(e));const r={type:qe.END_TAG,tagName:n,tagID:eo(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:wu(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===Pt.RCDATA||t.parser.tokenizer.state===Pt.RAWTEXT||t.parser.tokenizer.state===Pt.SCRIPT_DATA)&&(t.parser.tokenizer.state=Pt.DATA)}function m4(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function wu(e){const t=Nr(e)||{line:void 0,column:void 0,offset:void 0},n=fl(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function g4(e){return"children"in e?Ks(ye(U({},e),{children:[]})):Ks(e)}function E4(e){return function(t,n){return NT(t,ye(U({},e),{file:n}))}}function RT(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,o=n.indexOf(t);for(;o!==-1;)r++,o=n.indexOf(t,o+t.length);return r}function y4(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function T4(e,t,n){const o=bl((n||{}).ignore||[]),u=b4(t);let a=-1;for(;++a<u.length;)fy(e,"text",c);function c(h,m){let E=-1,b;for(;++E<m.length;){const T=m[E],_=b?b.children:void 0;if(o(T,_?_.indexOf(T):void 0,b))return;b=T}if(b)return f(h,m)}function f(h,m){const E=m[m.length-1],b=u[a][0],T=u[a][1];let _=0;const C=E.children.indexOf(h);let k=!1,M=[];b.lastIndex=0;let D=b.exec(h.value);for(;D;){const G=D.index,q={index:D.index,input:D.input,stack:[...m,h]};let B=T(...D,q);if(typeof B=="string"&&(B=B.length>0?{type:"text",value:B}:void 0),B===!1?b.lastIndex=G+1:(_!==G&&M.push({type:"text",value:h.value.slice(_,G)}),Array.isArray(B)?M.push(...B):B&&M.push(B),_=G+D[0].length,k=!0),!b.global)break;D=b.exec(h.value)}return k?(_<h.value.length&&M.push({type:"text",value:h.value.slice(_)}),E.children.splice(C,1,...M)):M=[h],C+M.length}}function b4(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const o=n[r];t.push([_4(o[0]),x4(o[1])])}return t}function _4(e){return typeof e=="string"?new RegExp(y4(e),"g"):e}function x4(e){return typeof e=="function"?e:function(){return e}}const Oh="phrasing",Ih=["autolink","link","image","label"];function S4(){return{transforms:[O4],enter:{literalAutolink:C4,literalAutolinkEmail:Ph,literalAutolinkHttp:Ph,literalAutolinkWww:Ph},exit:{literalAutolink:N4,literalAutolinkEmail:k4,literalAutolinkHttp:A4,literalAutolinkWww:v4}}}function w4(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Oh,notInConstruct:Ih},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Oh,notInConstruct:Ih},{character:":",before:"[ps]",after:"\\/",inConstruct:Oh,notInConstruct:Ih}]}}function C4(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Ph(e){this.config.enter.autolinkProtocol.call(this,e)}function A4(e){this.config.exit.autolinkProtocol.call(this,e)}function v4(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function k4(e){this.config.exit.autolinkEmail.call(this,e)}function N4(e){this.exit(e)}function O4(e){T4(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,I4],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),P4]],{ignore:["link","linkReference"]})}function I4(e,t,n,r,o){let u="";if(!LT(o)||(/^w/i.test(t)&&(n=t+n,t="",u="http://"),!R4(n)))return!1;const a=L4(n+r);if(!a[0])return!1;const c={type:"link",title:null,url:u+t+a[0],children:[{type:"text",value:t+a[0]}]};return a[1]?[c,{type:"text",value:a[1]}]:c}function P4(e,t,n,r){return!LT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function R4(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function L4(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const o=RT(e,"(");let u=RT(e,")");for(;r!==-1&&o>u;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),u++;return[e,n]}function LT(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Gi(n)||hl(n))&&(!t||n!==47)}DT.peek=$4;function D4(){this.buffer()}function F4(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function M4(){this.buffer()}function B4(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function U4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=fr(this.sliceSerialize(e)).toLowerCase(),n.label=t}function H4(e){this.exit(e)}function z4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=fr(this.sliceSerialize(e)).toLowerCase(),n.label=t}function j4(e){this.exit(e)}function $4(){return"["}function DT(e,t,n,r){const o=n.createTracker(r);let u=o.move("[^");const a=n.enter("footnoteReference"),c=n.enter("reference");return u+=o.move(n.safe(n.associationId(e),{after:"]",before:u})),c(),a(),u+=o.move("]"),u}function V4(){return{enter:{gfmFootnoteCallString:D4,gfmFootnoteCall:F4,gfmFootnoteDefinitionLabelString:M4,gfmFootnoteDefinition:B4},exit:{gfmFootnoteCallString:U4,gfmFootnoteCall:H4,gfmFootnoteDefinitionLabelString:z4,gfmFootnoteDefinition:j4}}}function q4(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:DT},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,o,u,a){const c=u.createTracker(a);let f=c.move("[^");const h=u.enter("footnoteDefinition"),m=u.enter("label");return f+=c.move(u.safe(u.associationId(r),{before:f,after:"]"})),m(),f+=c.move("]:"),r.children&&r.children.length>0&&(c.shift(4),f+=c.move((t?`
29
- `:" ")+u.indentLines(u.containerFlow(r,c.current()),t?FT:Y4))),h(),f}}function Y4(e,t,n){return t===0?e:FT(e,t,n)}function FT(e,t,n){return(n?"":" ")+e}const W4=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];MT.peek=J4;function G4(){return{canContainEols:["delete"],enter:{strikethrough:Q4},exit:{strikethrough:X4}}}function K4(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:W4}],handlers:{delete:MT}}}function Q4(e){this.enter({type:"delete",children:[]},e)}function X4(e){this.exit(e)}function MT(e,t,n,r){const o=n.createTracker(r),u=n.enter("strikethrough");let a=o.move("~~");return a+=n.containerPhrasing(e,ye(U({},o.current()),{before:a,after:"~"})),a+=o.move("~~"),u(),a}function J4(){return"~"}function Z4(e){return e.length}function eD(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||Z4,u=[],a=[],c=[],f=[];let h=0,m=-1;for(;++m<e.length;){const S=[],C=[];let k=-1;for(e[m].length>h&&(h=e[m].length);++k<e[m].length;){const M=tD(e[m][k]);if(n.alignDelimiters!==!1){const D=o(M);C[k]=D,(f[k]===void 0||D>f[k])&&(f[k]=D)}S.push(M)}a[m]=S,c[m]=C}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)u[E]=BT(r[E]);else{const S=BT(r);for(;++E<h;)u[E]=S}E=-1;const b=[],T=[];for(;++E<h;){const S=u[E];let C="",k="";S===99?(C=":",k=":"):S===108?C=":":S===114&&(k=":");let M=n.alignDelimiters===!1?1:Math.max(1,f[E]-C.length-k.length);const D=C+"-".repeat(M)+k;n.alignDelimiters!==!1&&(M=C.length+M+k.length,M>f[E]&&(f[E]=M),T[E]=M),b[E]=D}a.splice(1,0,b),c.splice(1,0,T),m=-1;const _=[];for(;++m<a.length;){const S=a[m],C=c[m];E=-1;const k=[];for(;++E<h;){const M=S[E]||"";let D="",G="";if(n.alignDelimiters!==!1){const q=f[E]-(C[E]||0),B=u[E];B===114?D=" ".repeat(q):B===99?q%2?(D=" ".repeat(q/2+.5),G=" ".repeat(q/2-.5)):(D=" ".repeat(q/2),G=D):G=" ".repeat(q)}n.delimiterStart!==!1&&!E&&k.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&M==="")&&(n.delimiterStart!==!1||E)&&k.push(" "),n.alignDelimiters!==!1&&k.push(D),k.push(M),n.alignDelimiters!==!1&&k.push(G),n.padding!==!1&&k.push(" "),(n.delimiterEnd!==!1||E!==h-1)&&k.push("|")}_.push(n.delimiterEnd===!1?k.join("").replace(/ +$/,""):k.join(""))}return _.join(`
30
- `)}function tD(e){return e==null?"":String(e)}function BT(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function nD(e,t,n,r){const o=n.enter("blockquote"),u=n.createTracker(r);u.move("> "),u.shift(2);const a=n.indentLines(n.containerFlow(e,u.current()),rD);return o(),a}function rD(e,t,n){return">"+(n?"":" ")+e}function iD(e,t){return UT(e,t.inConstruct,!0)&&!UT(e,t.notInConstruct,!1)}function UT(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function HT(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if(n.unsafe[o].character===`
31
- `&&iD(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return`\\
32
- `}function sD(e,t){const n=String(e);let r=n.indexOf(t),o=r,u=0,a=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===o?++u>a&&(a=u):u=1,o=r+t.length,r=n.indexOf(t,o);return a}function oD(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function uD(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function aD(e,t,n,r){const o=uD(n),u=e.value||"",a=o==="`"?"GraveAccent":"Tilde";if(oD(e,n)){const E=n.enter("codeIndented"),b=n.indentLines(u,lD);return E(),b}const c=n.createTracker(r),f=o.repeat(Math.max(sD(u,o)+1,3)),h=n.enter("codeFenced");let m=c.move(f);if(e.lang){const E=n.enter(`codeFencedLang${a}`);m+=c.move(n.safe(e.lang,U({before:m,after:" ",encode:["`"]},c.current()))),E()}if(e.lang&&e.meta){const E=n.enter(`codeFencedMeta${a}`);m+=c.move(" "),m+=c.move(n.safe(e.meta,U({before:m,after:`
26
+ `}),n}function my(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function gy(e,t){const n=kP(e,t),r=n.one(e,void 0),o=yP(n),u=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&u.children.push({type:"text",value:`
27
+ `},o),u}function RP(e,t){return e&&"run"in e?function(n,r){return st(this,null,function*(){const o=gy(n,U({file:r},t));yield e.run(o,r)})}:function(n,r){return gy(n,U({file:r},e||t))}}function Ey(e){if(e)throw e}var Jd,yy;function LP(){if(yy)return Jd;yy=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=function(h){return typeof Array.isArray=="function"?Array.isArray(h):t.call(h)==="[object Array]"},u=function(h){if(!h||t.call(h)!=="[object Object]")return!1;var m=e.call(h,"constructor"),E=h.constructor&&h.constructor.prototype&&e.call(h.constructor.prototype,"isPrototypeOf");if(h.constructor&&!m&&!E)return!1;var b;for(b in h);return typeof b=="undefined"||e.call(h,b)},a=function(h,m){n&&m.name==="__proto__"?n(h,m.name,{enumerable:!0,configurable:!0,value:m.newValue,writable:!0}):h[m.name]=m.newValue},c=function(h,m){if(m==="__proto__")if(e.call(h,m)){if(r)return r(h,m).value}else return;return h[m]};return Jd=function f(){var h,m,E,b,T,_,S=arguments[0],C=1,k=arguments.length,M=!1;for(typeof S=="boolean"&&(M=S,S=arguments[1]||{},C=2),(S==null||typeof S!="object"&&typeof S!="function")&&(S={});C<k;++C)if(h=arguments[C],h!=null)for(m in h)E=c(S,m),b=c(h,m),S!==b&&(M&&b&&(u(b)||(T=o(b)))?(T?(T=!1,_=E&&o(E)?E:[]):_=E&&u(E)?E:{},a(S,{name:m,newValue:f(M,_,b)})):typeof b!="undefined"&&a(S,{name:m,newValue:b}));return S},Jd}var DP=LP();const Zd=Ge(DP);function eh(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function FP(){const e=[],t={run:n,use:r};return t;function n(...o){let u=-1;const a=o.pop();if(typeof a!="function")throw new TypeError("Expected function as last argument, not "+a);c(null,...o);function c(f,...h){const m=e[++u];let E=-1;if(f){a(f);return}for(;++E<o.length;)(h[E]===null||h[E]===void 0)&&(h[E]=o[E]);o=h,m?MP(m,c)(...h):a(null,...h)}}function r(o){if(typeof o!="function")throw new TypeError("Expected `middelware` to be a function, not "+o);return e.push(o),t}}function MP(e,t){let n;return r;function r(...a){const c=e.length>a.length;let f;c&&a.push(o);try{f=e.apply(this,a)}catch(h){const m=h;if(c&&n)throw m;return o(m)}c||(f&&f.then&&typeof f.then=="function"?f.then(u,o):f instanceof Error?o(f):u(f))}function o(a,...c){n||(n=!0,t(a,...c))}function u(a){o(null,a)}}const Or={basename:BP,dirname:UP,extname:HP,join:zP,sep:"/"};function BP(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');cu(e);let n=0,r=-1,o=e.length,u;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(u){n=o+1;break}}else r<0&&(u=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let a=-1,c=t.length-1;for(;o--;)if(e.codePointAt(o)===47){if(u){n=o+1;break}}else a<0&&(u=!0,a=o+1),c>-1&&(e.codePointAt(o)===t.codePointAt(c--)?c<0&&(r=o):(c=-1,r=a));return n===r?r=a:r<0&&(r=e.length),e.slice(n,r)}function UP(e){if(cu(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function HP(e){cu(e);let t=e.length,n=-1,r=0,o=-1,u=0,a;for(;t--;){const c=e.codePointAt(t);if(c===47){if(a){r=t+1;break}continue}n<0&&(a=!0,n=t+1),c===46?o<0?o=t:u!==1&&(u=1):o>-1&&(u=-1)}return o<0||n<0||u===0||u===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function zP(...e){let t=-1,n;for(;++t<e.length;)cu(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":jP(n)}function jP(e){cu(e);const t=e.codePointAt(0)===47;let n=$P(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function $P(e,t){let n="",r=0,o=-1,u=0,a=-1,c,f;for(;++a<=e.length;){if(a<e.length)c=e.codePointAt(a);else{if(c===47)break;c=47}if(c===47){if(!(o===a-1||u===1))if(o!==a-1&&u===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(f=n.lastIndexOf("/"),f!==n.length-1){f<0?(n="",r=0):(n=n.slice(0,f),r=n.length-1-n.lastIndexOf("/")),o=a,u=0;continue}}else if(n.length>0){n="",r=0,o=a,u=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,a):n=e.slice(o+1,a),r=a-o-1;o=a,u=0}else c===46&&u>-1?u++:u=-1}return n}function cu(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const VP={cwd:qP};function qP(){return"/"}function th(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function YP(e){if(typeof e=="string")e=new URL(e);else if(!th(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return WP(e)}function WP(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const o=new TypeError("File URL path must not include encoded / characters");throw o.code="ERR_INVALID_FILE_URL_PATH",o}}return decodeURIComponent(t)}const nh=["history","path","basename","stem","extname","dirname"];class Ty{constructor(t){let n;t?th(t)?n={path:t}:typeof t=="string"||GP(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":VP.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<nh.length;){const u=nh[r];u in n&&n[u]!==void 0&&n[u]!==null&&(this[u]=u==="history"?[...n[u]]:n[u])}let o;for(o in n)nh.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?Or.basename(this.path):void 0}set basename(t){ih(t,"basename"),rh(t,"basename"),this.path=Or.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Or.dirname(this.path):void 0}set dirname(t){by(this.basename,"dirname"),this.path=Or.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Or.extname(this.path):void 0}set extname(t){if(rh(t,"extname"),by(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Or.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){th(t)&&(t=YP(t)),ih(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Or.basename(this.path,this.extname):void 0}set stem(t){ih(t,"stem"),rh(t,"stem"),this.path=Or.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const o=this.message(t,n,r);throw o.fatal=!0,o}info(t,n,r){const o=this.message(t,n,r);return o.fatal=void 0,o}message(t,n,r){const o=new nn(t,n,r);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function rh(e,t){if(e&&e.includes(Or.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Or.sep+"`")}function ih(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function by(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function GP(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const KP=function(e){const r=this.constructor.prototype,o=r[e],u=function(){return o.apply(u,arguments)};return Object.setPrototypeOf(u,r),u},QP={}.hasOwnProperty;class sh extends KP{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=FP()}copy(){const t=new sh;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Zd(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(ah("data",this.frozen),this.namespace[t]=n,this):QP.call(this.namespace,t)&&this.namespace[t]||void 0:t?(ah("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const o=n.call(t,...r);typeof o=="function"&&this.transformers.use(o)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=_l(t),r=this.parser||this.Parser;return oh("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),oh("process",this.parser||this.Parser),uh("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(u,a){const c=_l(t),f=r.parse(c);r.run(f,c,function(m,E,b){if(m||!E||!b)return h(m);const T=E,_=r.stringify(T,b);ZP(_)?b.value=_:b.result=_,h(m,b)});function h(m,E){m||!E?a(m):u?u(E):n(void 0,E)}}}processSync(t){let n=!1,r;return this.freeze(),oh("processSync",this.parser||this.Parser),uh("processSync",this.compiler||this.Compiler),this.process(t,o),xy("processSync","process",n),r;function o(u,a){n=!0,Ey(u),r=a}}run(t,n,r){_y(t),this.freeze();const o=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?u(void 0,r):new Promise(u);function u(a,c){const f=_l(n);o.run(t,f,h);function h(m,E,b){const T=E||t;m?c(m):a?a(T):r(void 0,T,b)}}}runSync(t,n){let r=!1,o;return this.run(t,n,u),xy("runSync","run",r),o;function u(a,c){Ey(a),o=c,r=!0}}stringify(t,n){this.freeze();const r=_l(n),o=this.compiler||this.Compiler;return uh("stringify",o),_y(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(ah("use",this.frozen),t!=null)if(typeof t=="function")f(t,n);else if(typeof t=="object")Array.isArray(t)?c(t):a(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function u(h){if(typeof h=="function")f(h,[]);else if(typeof h=="object")if(Array.isArray(h)){const[m,...E]=h;f(m,E)}else a(h);else throw new TypeError("Expected usable value, not `"+h+"`")}function a(h){if(!("plugins"in h)&&!("settings"in h))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");c(h.plugins),h.settings&&(o.settings=Zd(!0,o.settings,h.settings))}function c(h){let m=-1;if(h!=null)if(Array.isArray(h))for(;++m<h.length;){const E=h[m];u(E)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function f(h,m){let E=-1,b=-1;for(;++E<r.length;)if(r[E][0]===h){b=E;break}if(b===-1)r.push([h,...m]);else if(m.length>0){let[T,..._]=m;const S=r[b][1];eh(S)&&eh(T)&&(T=Zd(!0,S,T)),r[b]=[h,T,..._]}}}}const XP=new sh().freeze();function oh(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function uh(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function ah(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function _y(e){if(!eh(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function xy(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function _l(e){return JP(e)?e:new Ty(e)}function JP(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function ZP(e){return typeof e=="string"||eR(e)}function eR(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const tR="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",Sy=[],wy={allowDangerousHtml:!0},nR=/^(https?|ircs?|mailto|xmpp)$/i,rR=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function iR(e){const t=sR(e),n=oR(e);return uR(t.runSync(t.parse(n),n),e)}function sR(e){const t=e.rehypePlugins||Sy,n=e.remarkPlugins||Sy,r=e.remarkRehypeOptions?U(U({},e.remarkRehypeOptions),wy):wy;return XP().use(UI).use(n).use(RP,r).use(t)}function oR(e){const t=e.children||"",n=new Ty;return typeof t=="string"&&(n.value=t),n}function uR(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,u=t.disallowedElements,a=t.skipHtml,c=t.unwrapDisallowed,f=t.urlTransform||aR;for(const m of rR)Object.hasOwn(t,m.from)&&(""+m.from+(m.to?"use `"+m.to+"` instead":"remove it")+tR+m.id,void 0);return bl(e,h),I3(e,{Fragment:I.Fragment,components:o,ignoreInvalidStyle:!0,jsx:I.jsx,jsxs:I.jsxs,passKeys:!0,passNode:!0});function h(m,E,b){if(m.type==="raw"&&b&&typeof E=="number")return a?b.children.splice(E,1):b.children[E]={type:"text",value:m.value},E;if(m.type==="element"){let T;for(T in Bd)if(Object.hasOwn(Bd,T)&&Object.hasOwn(m.properties,T)){const _=m.properties[T],S=Bd[T];(S===null||S.includes(m.tagName))&&(m.properties[T]=f(String(_||""),T,m))}}if(m.type==="element"){let T=n?!n.includes(m.tagName):u?u.includes(m.tagName):!1;if(!T&&r&&typeof E=="number"&&(T=!r(m,E,b)),T&&b&&typeof E=="number")return c&&m.children?b.children.splice(E,1,...m.children):b.children.splice(E,1),E}}}function aR(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),o=e.indexOf("/");return t===-1||o!==-1&&t>o||n!==-1&&t>n||r!==-1&&t>r||nR.test(e.slice(0,t))?e:""}const Cy=/[#.]/g;function lR(e,t){const n=e||"",r={};let o=0,u,a;for(;o<n.length;){Cy.lastIndex=o;const c=Cy.exec(n),f=n.slice(o,c?c.index:n.length);f&&(u?u==="#"?r.id=f:Array.isArray(r.className)?r.className.push(f):r.className=[f]:a=f,o+=f.length),c&&(u=c[0],o++)}return{type:"element",tagName:a||t||"div",properties:r,children:[]}}function Ay(e,t,n){const r=n?hR(n):void 0;function o(u,a,...c){let f;if(u==null){f={type:"root",children:[]};const h=a;c.unshift(h)}else{f=lR(u,t);const h=f.tagName.toLowerCase(),m=r?r.get(h):void 0;if(f.tagName=m||h,cR(a))c.unshift(a);else for(const[E,b]of Object.entries(a))fR(e,f.properties,E,b)}for(const h of c)lh(f.children,h);return f.type==="element"&&f.tagName==="template"&&(f.content={type:"root",children:f.children},f.children=[]),f}return o}function cR(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const o=t[r];if(o&&typeof o=="object"){if(!Array.isArray(o))return!0;const u=o;for(const a of u)if(typeof a!="number"&&typeof a!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function fR(e,t,n,r){const o=Pd(e,n);let u;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;u=r}else typeof r=="boolean"?u=r:typeof r=="string"?o.spaceSeparated?u=yE(r):o.commaSeparated?u=sE(r):o.commaOrSpaceSeparated?u=yE(sE(r).join(" ")):u=vy(o,o.property,r):Array.isArray(r)?u=[...r]:u=o.property==="style"?dR(r):String(r);if(Array.isArray(u)){const a=[];for(const c of u)a.push(vy(o,o.property,c));u=a}o.property==="className"&&Array.isArray(t.className)&&(u=t.className.concat(u)),t[o.property]=u}}function lh(e,t){if(t!=null)if(typeof t=="number"||typeof t=="string")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(const n of t)lh(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?lh(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function vy(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||eu(n)===eu(t)))return!0}return n}function dR(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function hR(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const pR=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],mR=Ay(al,"div"),gR=Ay(js,"g",pR);function ER(e){const t=String(e),n=[];return{toOffset:o,toPoint:r};function r(u){if(typeof u=="number"&&u>-1&&u<=t.length){let a=0;for(;;){let c=n[a];if(c===void 0){const f=ky(t,n[a-1]);c=f===-1?t.length+1:f+1,n[a]=c}if(c>u)return{line:a+1,column:u-(a>0?n[a-1]:0)+1,offset:u};a++}}}function o(u){if(u&&typeof u.line=="number"&&typeof u.column=="number"&&!Number.isNaN(u.line)&&!Number.isNaN(u.column)){for(;n.length<u.line;){const c=n[n.length-1],f=ky(t,c),h=f===-1?t.length+1:f+1;if(c===h)break;n.push(h)}const a=(u.line>1?n[u.line-2]:0)+u.column-1;if(a<n[u.line-1])return a}}}function ky(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
28
+ `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ki={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Ny={}.hasOwnProperty,yR=Object.prototype;function TR(e,t){const n=t||{};return ch({file:n.file||void 0,location:!1,schema:n.space==="svg"?js:al,verbose:n.verbose||!1},e)}function ch(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},xl(e,r,n),n}case"#document":case"#document-fragment":{const r=t,o="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:Oy(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const u=String(e.file),a=ER(u),c=a.toPoint(0),f=a.toPoint(u.length);n.position={start:c,end:f}}return n}case"#documentType":{const r=t;return n={type:"doctype"},xl(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},xl(e,r,n),n}default:return n=bR(e,t),n}}function Oy(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=ch(e,t[n]);r.push(o)}return r}function bR(e,t){const n=e.schema;e.schema=t.namespaceURI===Ki.svg?js:al;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],f=(c.prefix?c.prefix+":":"")+c.name;Ny.call(yR,f)||(o[f]=c.value)}const a=(e.schema.space==="svg"?gR:mR)(t.tagName,o,Oy(e,t.childNodes));if(xl(e,t,a),a.tagName==="template"){const c=t,f=c.sourceCodeLocation,h=f&&f.startTag&&Gs(f.startTag),m=f&&f.endTag&&Gs(f.endTag),E=ch(e,c.content);h&&m&&e.file&&(E.position={start:h.end,end:m.start}),a.content=E}return e.schema=n,a}function xl(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=_R(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function _R(e,t,n){const r=Gs(n);if(t.type==="element"){const o=t.children[t.children.length-1];if(r&&!n.endTag&&o&&o.position&&o.position.end&&(r.end=Object.assign({},o.position.end)),e.verbose){const u={};let a;if(n.attrs)for(a in n.attrs)Ny.call(n.attrs,a)&&(u[Pd(e.schema,a).property]=Gs(n.attrs[a]));n.startTag;const c=Gs(n.startTag),f=n.endTag?Gs(n.endTag):void 0,h={opening:c};f&&(h.closing=f),h.properties=u,t.data={position:h}}}return r}function Gs(e){const t=Iy({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=Iy({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function Iy(e){return e.line&&e.column?e:void 0}class fu{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}fu.prototype.property={},fu.prototype.normal={},fu.prototype.space=null;function Py(e,t){const n={},r={};let o=-1;for(;++o<e.length;)Object.assign(n,e[o].property),Object.assign(r,e[o].normal);return new fu(n,r,t)}function fh(e){return e.toLowerCase()}class qn{constructor(t,n){this.property=t,this.attribute=n}}qn.prototype.space=null,qn.prototype.boolean=!1,qn.prototype.booleanish=!1,qn.prototype.overloadedBoolean=!1,qn.prototype.number=!1,qn.prototype.commaSeparated=!1,qn.prototype.spaceSeparated=!1,qn.prototype.commaOrSpaceSeparated=!1,qn.prototype.mustUseProperty=!1,qn.prototype.defined=!1;let xR=0;const je=Qi(),Ft=Qi(),Ry=Qi(),pe=Qi(),dt=Qi(),Ks=Qi(),Dn=Qi();function Qi(){return Kc(2,++xR)}const dh=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:Ft,commaOrSpaceSeparated:Dn,commaSeparated:Ks,number:pe,overloadedBoolean:Ry,spaceSeparated:dt},Symbol.toStringTag,{value:"Module"})),hh=Object.keys(dh);class ph extends qn{constructor(t,n,r,o){let u=-1;if(super(t,n),Ly(this,"space",o),typeof r=="number")for(;++u<hh.length;){const a=hh[u];Ly(this,hh[u],(r&dh[a])===dh[a])}}}ph.prototype.defined=!0;function Ly(e,t,n){n&&(e[t]=n)}const SR={}.hasOwnProperty;function Qs(e){const t={},n={};let r;for(r in e.properties)if(SR.call(e.properties,r)){const o=e.properties[r],u=new ph(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(u.mustUseProperty=!0),t[r]=u,n[fh(r)]=r,n[fh(u.attribute)]=r}return new fu(t,n,e.space)}const Dy=Qs({space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),Fy=Qs({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function My(e,t){return t in e?e[t]:t}function By(e,t){return My(e,t.toLowerCase())}const Uy=Qs({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:By,properties:{xmlns:null,xmlnsXLink:null}}),Hy=Qs({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:Ft,ariaAutoComplete:null,ariaBusy:Ft,ariaChecked:Ft,ariaColCount:pe,ariaColIndex:pe,ariaColSpan:pe,ariaControls:dt,ariaCurrent:null,ariaDescribedBy:dt,ariaDetails:null,ariaDisabled:Ft,ariaDropEffect:dt,ariaErrorMessage:null,ariaExpanded:Ft,ariaFlowTo:dt,ariaGrabbed:Ft,ariaHasPopup:null,ariaHidden:Ft,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:dt,ariaLevel:pe,ariaLive:null,ariaModal:Ft,ariaMultiLine:Ft,ariaMultiSelectable:Ft,ariaOrientation:null,ariaOwns:dt,ariaPlaceholder:null,ariaPosInSet:pe,ariaPressed:Ft,ariaReadOnly:Ft,ariaRelevant:null,ariaRequired:Ft,ariaRoleDescription:dt,ariaRowCount:pe,ariaRowIndex:pe,ariaRowSpan:pe,ariaSelected:Ft,ariaSetSize:pe,ariaSort:null,ariaValueMax:pe,ariaValueMin:pe,ariaValueNow:pe,ariaValueText:null,role:null}}),wR=Qs({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:By,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Ks,acceptCharset:dt,accessKey:dt,action:null,allow:null,allowFullScreen:je,allowPaymentRequest:je,allowUserMedia:je,alt:null,as:null,async:je,autoCapitalize:null,autoComplete:dt,autoFocus:je,autoPlay:je,blocking:dt,capture:null,charSet:null,checked:je,cite:null,className:dt,cols:pe,colSpan:null,content:null,contentEditable:Ft,controls:je,controlsList:dt,coords:pe|Ks,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:Ry,draggable:Ft,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:dt,height:pe,hidden:je,high:pe,href:null,hrefLang:null,htmlFor:dt,httpEquiv:dt,id:null,imageSizes:null,imageSrcSet:null,inert:je,inputMode:null,integrity:null,is:null,isMap:je,itemId:null,itemProp:dt,itemRef:dt,itemScope:je,itemType:dt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:je,low:pe,manifest:null,max:null,maxLength:pe,media:null,method:null,min:null,minLength:pe,multiple:je,muted:je,name:null,nonce:null,noModule:je,noValidate:je,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:je,optimum:pe,pattern:null,ping:dt,placeholder:null,playsInline:je,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:je,referrerPolicy:null,rel:dt,required:je,reversed:je,rows:pe,rowSpan:pe,sandbox:dt,scope:null,scoped:je,seamless:je,selected:je,shadowRootClonable:je,shadowRootDelegatesFocus:je,shadowRootMode:null,shape:null,size:pe,sizes:null,slot:null,span:pe,spellCheck:Ft,src:null,srcDoc:null,srcLang:null,srcSet:null,start:pe,step:null,style:null,tabIndex:pe,target:null,title:null,translate:null,type:null,typeMustMatch:je,useMap:null,value:Ft,width:pe,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:dt,axis:null,background:null,bgColor:null,border:pe,borderColor:null,bottomMargin:pe,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:je,declare:je,event:null,face:null,frame:null,frameBorder:null,hSpace:pe,leftMargin:pe,link:null,longDesc:null,lowSrc:null,marginHeight:pe,marginWidth:pe,noResize:je,noHref:je,noShade:je,noWrap:je,object:null,profile:null,prompt:null,rev:null,rightMargin:pe,rules:null,scheme:null,scrolling:Ft,standby:null,summary:null,text:null,topMargin:pe,valueType:null,version:null,vAlign:null,vLink:null,vSpace:pe,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:je,disableRemotePlayback:je,prefix:null,property:null,results:pe,security:null,unselectable:null}}),CR=Qs({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:My,properties:{about:Dn,accentHeight:pe,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:pe,amplitude:pe,arabicForm:null,ascent:pe,attributeName:null,attributeType:null,azimuth:pe,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:pe,by:null,calcMode:null,capHeight:pe,className:dt,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:pe,diffuseConstant:pe,direction:null,display:null,dur:null,divisor:pe,dominantBaseline:null,download:je,dx:null,dy:null,edgeMode:null,editable:null,elevation:pe,enableBackground:null,end:null,event:null,exponent:pe,externalResourcesRequired:null,fill:null,fillOpacity:pe,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Ks,g2:Ks,glyphName:Ks,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:pe,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:pe,horizOriginX:pe,horizOriginY:pe,id:null,ideographic:pe,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:pe,k:pe,k1:pe,k2:pe,k3:pe,k4:pe,kernelMatrix:Dn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:pe,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:pe,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:pe,overlineThickness:pe,paintOrder:null,panose1:null,path:null,pathLength:pe,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:dt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:pe,pointsAtY:pe,pointsAtZ:pe,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Dn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Dn,rev:Dn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Dn,requiredFeatures:Dn,requiredFonts:Dn,requiredFormats:Dn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:pe,specularExponent:pe,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:pe,strikethroughThickness:pe,string:null,stroke:null,strokeDashArray:Dn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:pe,strokeOpacity:pe,strokeWidth:null,style:null,surfaceScale:pe,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Dn,tabIndex:pe,tableValues:null,target:null,targetX:pe,targetY:pe,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Dn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:pe,underlineThickness:pe,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:pe,values:null,vAlphabetic:pe,vMathematical:pe,vectorEffect:null,vHanging:pe,vIdeographic:pe,version:null,vertAdvY:pe,vertOriginX:pe,vertOriginY:pe,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:pe,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),AR=/^data[-\w.:]+$/i,zy=/-[a-z]/g,vR=/[A-Z]/g;function kR(e,t){const n=fh(t);let r=t,o=qn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&AR.test(t)){if(t.charAt(4)==="-"){const u=t.slice(5).replace(zy,OR);r="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=t.slice(4);if(!zy.test(u)){let a=u.replace(vR,NR);a.charAt(0)!=="-"&&(a="-"+a),t="data"+a}}o=ph}return new o(r,t)}function NR(e){return"-"+e.toLowerCase()}function OR(e){return e.charAt(1).toUpperCase()}const IR=Py([Fy,Dy,Uy,Hy,wR],"html"),jy=Py([Fy,Dy,Uy,Hy,CR],"svg"),$y={}.hasOwnProperty;function Vy(e,t){const n=t||{};function r(o,...u){let a=r.invalid;const c=r.handlers;if(o&&$y.call(o,e)){const f=String(o[e]);a=$y.call(c,f)?c[f]:r.unknown}if(a)return a.call(this,o,...u)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const PR={},RR={}.hasOwnProperty,qy=Vy("type",{handlers:{root:DR,element:HR,text:BR,comment:UR,doctype:MR}});function LR(e,t){const r=(t||PR).space;return qy(e,r==="svg"?jy:IR)}function DR(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=mh(e.children,n,t),Xs(e,n),n}function FR(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=mh(e.children,n,t),Xs(e,n),n}function MR(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return Xs(e,t),t}function BR(e){const t={nodeName:"#text",value:e.value,parentNode:null};return Xs(e,t),t}function UR(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return Xs(e,t),t}function HR(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=jy);const o=[];let u;if(e.properties){for(u in e.properties)if(u!=="children"&&RR.call(e.properties,u)){const f=zR(r,u,e.properties[u]);f&&o.push(f)}}const a=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Ki[a],childNodes:[],parentNode:null};return c.childNodes=mh(e.children,c,r),Xs(e,c),e.tagName==="template"&&e.content&&(c.content=FR(e.content,r)),c}function zR(e,t,n){const r=kR(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?oE(n):TE(n));const o={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const u=o.name.indexOf(":");u<0?o.prefix="":(o.name=o.name.slice(u+1),o.prefix=r.attribute.slice(0,u)),o.namespace=Ki[r.space]}return o}function mh(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const u=qy(e[r],n);u.parentNode=t,o.push(u)}return o}function Xs(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const jR=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],$R=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),yt="�";var A;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(A||(A={}));const Sn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function Yy(e){return e>=55296&&e<=57343}function VR(e){return e>=56320&&e<=57343}function qR(e,t){return(e-55296)*1024+9216+t}function Wy(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function Gy(e){return e>=64976&&e<=65007||$R.has(e)}var X;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(X||(X={}));const YR=65536;class WR{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=YR,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:o,offset:u}=this,a=o+n,c=u+n;return{code:t,startLine:r,endLine:r,startCol:a,endCol:a,startOffset:c,endOffset:c}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(VR(n))return this.pos++,this._addGap(),qR(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,A.EOF;return this._err(X.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,A.EOF;const r=this.html.charCodeAt(n);return r===A.CARRIAGE_RETURN?A.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,A.EOF;let t=this.html.charCodeAt(this.pos);return t===A.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,A.LINE_FEED):t===A.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,Yy(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===A.LINE_FEED||t===A.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Wy(t)?this._err(X.controlCharacterInInputStream):Gy(t)&&this._err(X.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var qe;(function(e){e[e.CHARACTER=0]="CHARACTER",e[e.NULL_CHARACTER=1]="NULL_CHARACTER",e[e.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",e[e.START_TAG=3]="START_TAG",e[e.END_TAG=4]="END_TAG",e[e.COMMENT=5]="COMMENT",e[e.DOCTYPE=6]="DOCTYPE",e[e.EOF=7]="EOF",e[e.HIBERNATION=8]="HIBERNATION"})(qe||(qe={}));function Ky(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const GR=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),KR=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function QR(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=KR.get(e))!==null&&t!==void 0?t:e}var $t;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})($t||($t={}));const XR=32;var mi;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(mi||(mi={}));function gh(e){return e>=$t.ZERO&&e<=$t.NINE}function JR(e){return e>=$t.UPPER_A&&e<=$t.UPPER_F||e>=$t.LOWER_A&&e<=$t.LOWER_F}function ZR(e){return e>=$t.UPPER_A&&e<=$t.UPPER_Z||e>=$t.LOWER_A&&e<=$t.LOWER_Z||gh(e)}function eL(e){return e===$t.EQUALS||ZR(e)}var Vt;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(Vt||(Vt={}));var Xr;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Xr||(Xr={}));class tL{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Vt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Xr.Strict}startEntity(t){this.decodeMode=t,this.state=Vt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Vt.EntityStart:return t.charCodeAt(n)===$t.NUM?(this.state=Vt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Vt.NamedEntity,this.stateNamedEntity(t,n));case Vt.NumericStart:return this.stateNumericStart(t,n);case Vt.NumericDecimal:return this.stateNumericDecimal(t,n);case Vt.NumericHex:return this.stateNumericHex(t,n);case Vt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|XR)===$t.LOWER_X?(this.state=Vt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Vt.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,o){if(n!==r){const u=r-n;this.result=this.result*Math.pow(o,u)+Number.parseInt(t.substr(n,u),o),this.consumed+=u}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const o=t.charCodeAt(n);if(gh(o)||JR(o))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(o,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const o=t.charCodeAt(n);if(gh(o))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(o,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===$t.SEMI)this.consumed+=1;else if(this.decodeMode===Xr.Strict)return 0;return this.emitCodePoint(QR(this.result),this.consumed),this.errors&&(t!==$t.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let o=r[this.treeIndex],u=(o&mi.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const a=t.charCodeAt(n);if(this.treeIndex=nL(r,o,this.treeIndex+Math.max(1,u),a),this.treeIndex<0)return this.result===0||this.decodeMode===Xr.Attribute&&(u===0||eL(a))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],u=(o&mi.VALUE_LENGTH)>>14,u!==0){if(a===$t.SEMI)return this.emitNamedEntityData(this.treeIndex,u,this.consumed+this.excess);this.decodeMode!==Xr.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,o=(r[n]&mi.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,o,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:o}=this;return this.emitCodePoint(n===1?o[t]&~mi.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Vt.NamedEntity:return this.result!==0&&(this.decodeMode!==Xr.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Vt.NumericDecimal:return this.emitNumericEntity(0,2);case Vt.NumericHex:return this.emitNumericEntity(0,3);case Vt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Vt.EntityStart:return 0}}}function nL(e,t,n,r){const o=(t&mi.BRANCH_LENGTH)>>7,u=t&mi.JUMP_TABLE;if(o===0)return u!==0&&r===u?n:-1;if(u){const f=r-u;return f<0||f>=o?-1:e[n+f]-1}let a=n,c=a+o-1;for(;a<=c;){const f=a+c>>>1,h=e[f];if(h<r)a=f+1;else if(h>r)c=f-1;else return e[f+o]}return-1}var re;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(re||(re={}));var Xi;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Xi||(Xi={}));var Yn;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Yn||(Yn={}));var j;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SEARCH="search",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(j||(j={}));var p;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SEARCH=94]="SEARCH",e[e.SECTION=95]="SECTION",e[e.SELECT=96]="SELECT",e[e.SOURCE=97]="SOURCE",e[e.SMALL=98]="SMALL",e[e.SPAN=99]="SPAN",e[e.STRIKE=100]="STRIKE",e[e.STRONG=101]="STRONG",e[e.STYLE=102]="STYLE",e[e.SUB=103]="SUB",e[e.SUMMARY=104]="SUMMARY",e[e.SUP=105]="SUP",e[e.TABLE=106]="TABLE",e[e.TBODY=107]="TBODY",e[e.TEMPLATE=108]="TEMPLATE",e[e.TEXTAREA=109]="TEXTAREA",e[e.TFOOT=110]="TFOOT",e[e.TD=111]="TD",e[e.TH=112]="TH",e[e.THEAD=113]="THEAD",e[e.TITLE=114]="TITLE",e[e.TR=115]="TR",e[e.TRACK=116]="TRACK",e[e.TT=117]="TT",e[e.U=118]="U",e[e.UL=119]="UL",e[e.SVG=120]="SVG",e[e.VAR=121]="VAR",e[e.WBR=122]="WBR",e[e.XMP=123]="XMP"})(p||(p={}));const rL=new Map([[j.A,p.A],[j.ADDRESS,p.ADDRESS],[j.ANNOTATION_XML,p.ANNOTATION_XML],[j.APPLET,p.APPLET],[j.AREA,p.AREA],[j.ARTICLE,p.ARTICLE],[j.ASIDE,p.ASIDE],[j.B,p.B],[j.BASE,p.BASE],[j.BASEFONT,p.BASEFONT],[j.BGSOUND,p.BGSOUND],[j.BIG,p.BIG],[j.BLOCKQUOTE,p.BLOCKQUOTE],[j.BODY,p.BODY],[j.BR,p.BR],[j.BUTTON,p.BUTTON],[j.CAPTION,p.CAPTION],[j.CENTER,p.CENTER],[j.CODE,p.CODE],[j.COL,p.COL],[j.COLGROUP,p.COLGROUP],[j.DD,p.DD],[j.DESC,p.DESC],[j.DETAILS,p.DETAILS],[j.DIALOG,p.DIALOG],[j.DIR,p.DIR],[j.DIV,p.DIV],[j.DL,p.DL],[j.DT,p.DT],[j.EM,p.EM],[j.EMBED,p.EMBED],[j.FIELDSET,p.FIELDSET],[j.FIGCAPTION,p.FIGCAPTION],[j.FIGURE,p.FIGURE],[j.FONT,p.FONT],[j.FOOTER,p.FOOTER],[j.FOREIGN_OBJECT,p.FOREIGN_OBJECT],[j.FORM,p.FORM],[j.FRAME,p.FRAME],[j.FRAMESET,p.FRAMESET],[j.H1,p.H1],[j.H2,p.H2],[j.H3,p.H3],[j.H4,p.H4],[j.H5,p.H5],[j.H6,p.H6],[j.HEAD,p.HEAD],[j.HEADER,p.HEADER],[j.HGROUP,p.HGROUP],[j.HR,p.HR],[j.HTML,p.HTML],[j.I,p.I],[j.IMG,p.IMG],[j.IMAGE,p.IMAGE],[j.INPUT,p.INPUT],[j.IFRAME,p.IFRAME],[j.KEYGEN,p.KEYGEN],[j.LABEL,p.LABEL],[j.LI,p.LI],[j.LINK,p.LINK],[j.LISTING,p.LISTING],[j.MAIN,p.MAIN],[j.MALIGNMARK,p.MALIGNMARK],[j.MARQUEE,p.MARQUEE],[j.MATH,p.MATH],[j.MENU,p.MENU],[j.META,p.META],[j.MGLYPH,p.MGLYPH],[j.MI,p.MI],[j.MO,p.MO],[j.MN,p.MN],[j.MS,p.MS],[j.MTEXT,p.MTEXT],[j.NAV,p.NAV],[j.NOBR,p.NOBR],[j.NOFRAMES,p.NOFRAMES],[j.NOEMBED,p.NOEMBED],[j.NOSCRIPT,p.NOSCRIPT],[j.OBJECT,p.OBJECT],[j.OL,p.OL],[j.OPTGROUP,p.OPTGROUP],[j.OPTION,p.OPTION],[j.P,p.P],[j.PARAM,p.PARAM],[j.PLAINTEXT,p.PLAINTEXT],[j.PRE,p.PRE],[j.RB,p.RB],[j.RP,p.RP],[j.RT,p.RT],[j.RTC,p.RTC],[j.RUBY,p.RUBY],[j.S,p.S],[j.SCRIPT,p.SCRIPT],[j.SEARCH,p.SEARCH],[j.SECTION,p.SECTION],[j.SELECT,p.SELECT],[j.SOURCE,p.SOURCE],[j.SMALL,p.SMALL],[j.SPAN,p.SPAN],[j.STRIKE,p.STRIKE],[j.STRONG,p.STRONG],[j.STYLE,p.STYLE],[j.SUB,p.SUB],[j.SUMMARY,p.SUMMARY],[j.SUP,p.SUP],[j.TABLE,p.TABLE],[j.TBODY,p.TBODY],[j.TEMPLATE,p.TEMPLATE],[j.TEXTAREA,p.TEXTAREA],[j.TFOOT,p.TFOOT],[j.TD,p.TD],[j.TH,p.TH],[j.THEAD,p.THEAD],[j.TITLE,p.TITLE],[j.TR,p.TR],[j.TRACK,p.TRACK],[j.TT,p.TT],[j.U,p.U],[j.UL,p.UL],[j.SVG,p.SVG],[j.VAR,p.VAR],[j.WBR,p.WBR],[j.XMP,p.XMP]]);function Js(e){var t;return(t=rL.get(e))!==null&&t!==void 0?t:p.UNKNOWN}const le=p,iL={[re.HTML]:new Set([le.ADDRESS,le.APPLET,le.AREA,le.ARTICLE,le.ASIDE,le.BASE,le.BASEFONT,le.BGSOUND,le.BLOCKQUOTE,le.BODY,le.BR,le.BUTTON,le.CAPTION,le.CENTER,le.COL,le.COLGROUP,le.DD,le.DETAILS,le.DIR,le.DIV,le.DL,le.DT,le.EMBED,le.FIELDSET,le.FIGCAPTION,le.FIGURE,le.FOOTER,le.FORM,le.FRAME,le.FRAMESET,le.H1,le.H2,le.H3,le.H4,le.H5,le.H6,le.HEAD,le.HEADER,le.HGROUP,le.HR,le.HTML,le.IFRAME,le.IMG,le.INPUT,le.LI,le.LINK,le.LISTING,le.MAIN,le.MARQUEE,le.MENU,le.META,le.NAV,le.NOEMBED,le.NOFRAMES,le.NOSCRIPT,le.OBJECT,le.OL,le.P,le.PARAM,le.PLAINTEXT,le.PRE,le.SCRIPT,le.SECTION,le.SELECT,le.SOURCE,le.STYLE,le.SUMMARY,le.TABLE,le.TBODY,le.TD,le.TEMPLATE,le.TEXTAREA,le.TFOOT,le.TH,le.THEAD,le.TITLE,le.TR,le.TRACK,le.UL,le.WBR,le.XMP]),[re.MATHML]:new Set([le.MI,le.MO,le.MN,le.MS,le.MTEXT,le.ANNOTATION_XML]),[re.SVG]:new Set([le.TITLE,le.FOREIGN_OBJECT,le.DESC]),[re.XLINK]:new Set,[re.XML]:new Set,[re.XMLNS]:new Set},Eh=new Set([le.H1,le.H2,le.H3,le.H4,le.H5,le.H6]);j.STYLE,j.SCRIPT,j.XMP,j.IFRAME,j.NOEMBED,j.NOFRAMES,j.PLAINTEXT;var v;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(v||(v={}));const It={DATA:v.DATA,RCDATA:v.RCDATA,RAWTEXT:v.RAWTEXT,SCRIPT_DATA:v.SCRIPT_DATA,PLAINTEXT:v.PLAINTEXT,CDATA_SECTION:v.CDATA_SECTION};function sL(e){return e>=A.DIGIT_0&&e<=A.DIGIT_9}function du(e){return e>=A.LATIN_CAPITAL_A&&e<=A.LATIN_CAPITAL_Z}function oL(e){return e>=A.LATIN_SMALL_A&&e<=A.LATIN_SMALL_Z}function gi(e){return oL(e)||du(e)}function Qy(e){return gi(e)||sL(e)}function Sl(e){return e+32}function Xy(e){return e===A.SPACE||e===A.LINE_FEED||e===A.TABULATION||e===A.FORM_FEED}function Jy(e){return Xy(e)||e===A.SOLIDUS||e===A.GREATER_THAN_SIGN}function uL(e){return e===A.NULL?X.nullCharacterReference:e>1114111?X.characterReferenceOutsideUnicodeRange:Yy(e)?X.surrogateCharacterReference:Gy(e)?X.noncharacterCharacterReference:Wy(e)||e===A.CARRIAGE_RETURN?X.controlCharacterReference:null}class aL{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=v.DATA,this.returnState=v.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new WR(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new tL(GR,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(X.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(X.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=uL(r);o&&this._err(o,1)}}:void 0)}_err(t,n=0){var r,o;(o=(r=this.handler).onParseError)===null||o===void 0||o.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:qe.START_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:qe.END_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:qe.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:qe.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(Ky(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const o=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);o[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(X.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=Js(t.tagName),t.type===qe.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(X.endTagWithAttributes),t.selfClosing&&this._err(X.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case qe.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case qe.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case qe.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:qe.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=Xy(t)?qe.WHITESPACE_CHARACTER:t===A.NULL?qe.NULL_CHARACTER:qe.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(qe.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=v.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Xr.Attribute:Xr.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===v.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===v.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===v.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case v.DATA:{this._stateData(t);break}case v.RCDATA:{this._stateRcdata(t);break}case v.RAWTEXT:{this._stateRawtext(t);break}case v.SCRIPT_DATA:{this._stateScriptData(t);break}case v.PLAINTEXT:{this._statePlaintext(t);break}case v.TAG_OPEN:{this._stateTagOpen(t);break}case v.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case v.TAG_NAME:{this._stateTagName(t);break}case v.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case v.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case v.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case v.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case v.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case v.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case v.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case v.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case v.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case v.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case v.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case v.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case v.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case v.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case v.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case v.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case v.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case v.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case v.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case v.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case v.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case v.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case v.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case v.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case v.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case v.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case v.BOGUS_COMMENT:{this._stateBogusComment(t);break}case v.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case v.COMMENT_START:{this._stateCommentStart(t);break}case v.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case v.COMMENT:{this._stateComment(t);break}case v.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case v.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case v.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case v.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case v.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case v.COMMENT_END:{this._stateCommentEnd(t);break}case v.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case v.DOCTYPE:{this._stateDoctype(t);break}case v.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case v.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case v.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case v.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case v.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case v.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case v.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case v.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case v.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case v.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case v.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case v.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case v.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case v.CDATA_SECTION:{this._stateCdataSection(t);break}case v.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case v.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case v.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case v.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case A.LESS_THAN_SIGN:{this.state=v.TAG_OPEN;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitCodePoint(t);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case A.AMPERSAND:{this._startCharacterReference();break}case A.LESS_THAN_SIGN:{this.state=v.RCDATA_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case A.LESS_THAN_SIGN:{this.state=v.RAWTEXT_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(gi(t))this._createStartTagToken(),this.state=v.TAG_NAME,this._stateTagName(t);else switch(t){case A.EXCLAMATION_MARK:{this.state=v.MARKUP_DECLARATION_OPEN;break}case A.SOLIDUS:{this.state=v.END_TAG_OPEN;break}case A.QUESTION_MARK:{this._err(X.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=v.BOGUS_COMMENT,this._stateBogusComment(t);break}case A.EOF:{this._err(X.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(X.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=v.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(gi(t))this._createEndTagToken(),this.state=v.TAG_NAME,this._stateTagName(t);else switch(t){case A.GREATER_THAN_SIGN:{this._err(X.missingEndTagName),this.state=v.DATA;break}case A.EOF:{this._err(X.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(X.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=v.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_ATTRIBUTE_NAME;break}case A.SOLIDUS:{this.state=v.SELF_CLOSING_START_TAG;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentTagToken();break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.tagName+=yt;break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(du(t)?Sl(t):t)}}_stateRcdataLessThanSign(t){t===A.SOLIDUS?this.state=v.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=v.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){gi(t)?(this.state=v.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=v.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=v.BEFORE_ATTRIBUTE_NAME,!1;case A.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=v.SELF_CLOSING_START_TAG,!1;case A.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=v.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===A.SOLIDUS?this.state=v.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=v.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){gi(t)?(this.state=v.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=v.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case A.SOLIDUS:{this.state=v.SCRIPT_DATA_END_TAG_OPEN;break}case A.EXCLAMATION_MARK:{this.state=v.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=v.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){gi(t)?(this.state=v.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===A.HYPHEN_MINUS?(this.state=v.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===A.HYPHEN_MINUS?(this.state=v.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=v.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case A.HYPHEN_MINUS:{this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case A.GREATER_THAN_SIGN:{this.state=v.SCRIPT_DATA,this._emitChars(">");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===A.SOLIDUS?this.state=v.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:gi(t)?(this._emitChars("<"),this.state=v.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){gi(t)?(this.state=v.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(Sn.SCRIPT,!1)&&Jy(this.preprocessor.peek(Sn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Sn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=v.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case A.HYPHEN_MINUS:{this._emitChars("-");break}case A.LESS_THAN_SIGN:{this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case A.GREATER_THAN_SIGN:{this.state=v.SCRIPT_DATA,this._emitChars(">");break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(yt);break}case A.EOF:{this._err(X.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===A.SOLIDUS?(this.state=v.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(Sn.SCRIPT,!1)&&Jy(this.preprocessor.peek(Sn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Sn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=v.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=v.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.SOLIDUS:case A.GREATER_THAN_SIGN:case A.EOF:{this.state=v.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case A.EQUALS_SIGN:{this._err(X.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=v.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=v.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:case A.SOLIDUS:case A.GREATER_THAN_SIGN:case A.EOF:{this._leaveAttrName(),this.state=v.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case A.EQUALS_SIGN:{this._leaveAttrName(),this.state=v.BEFORE_ATTRIBUTE_VALUE;break}case A.QUOTATION_MARK:case A.APOSTROPHE:case A.LESS_THAN_SIGN:{this._err(X.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.name+=yt;break}default:this.currentAttr.name+=String.fromCodePoint(du(t)?Sl(t):t)}}_stateAfterAttributeName(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.SOLIDUS:{this.state=v.SELF_CLOSING_START_TAG;break}case A.EQUALS_SIGN:{this.state=v.BEFORE_ATTRIBUTE_VALUE;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentTagToken();break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=v.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.QUOTATION_MARK:{this.state=v.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this.state=v.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingAttributeValue),this.state=v.DATA,this.emitCurrentTagToken();break}default:this.state=v.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case A.QUOTATION_MARK:{this.state=v.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.value+=yt;break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case A.APOSTROPHE:{this.state=v.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.value+=yt;break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this._leaveAttrValue(),this.state=v.BEFORE_ATTRIBUTE_NAME;break}case A.AMPERSAND:{this._startCharacterReference();break}case A.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=v.DATA,this.emitCurrentTagToken();break}case A.NULL:{this._err(X.unexpectedNullCharacter),this.currentAttr.value+=yt;break}case A.QUOTATION_MARK:case A.APOSTROPHE:case A.LESS_THAN_SIGN:case A.EQUALS_SIGN:case A.GRAVE_ACCENT:{this._err(X.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this._leaveAttrValue(),this.state=v.BEFORE_ATTRIBUTE_NAME;break}case A.SOLIDUS:{this._leaveAttrValue(),this.state=v.SELF_CLOSING_START_TAG;break}case A.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=v.DATA,this.emitCurrentTagToken();break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this._err(X.missingWhitespaceBetweenAttributes),this.state=v.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case A.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=v.DATA,this.emitCurrentTagToken();break}case A.EOF:{this._err(X.eofInTag),this._emitEOFToken();break}default:this._err(X.unexpectedSolidusInTag),this.state=v.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentComment(n);break}case A.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.data+=yt;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(Sn.DASH_DASH,!0)?(this._createCommentToken(Sn.DASH_DASH.length+1),this.state=v.COMMENT_START):this._consumeSequenceIfMatch(Sn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Sn.DOCTYPE.length+1),this.state=v.DOCTYPE):this._consumeSequenceIfMatch(Sn.CDATA_START,!0)?this.inForeignNode?this.state=v.CDATA_SECTION:(this._err(X.cdataInHtmlContent),this._createCommentToken(Sn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=v.BOGUS_COMMENT):this._ensureHibernation()||(this._err(X.incorrectlyOpenedComment),this._createCommentToken(2),this.state=v.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_START_DASH;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptClosingOfEmptyComment),this.state=v.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=v.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_END;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptClosingOfEmptyComment),this.state=v.DATA,this.emitCurrentComment(n);break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=v.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_END_DASH;break}case A.LESS_THAN_SIGN:{n.data+="<",this.state=v.COMMENT_LESS_THAN_SIGN;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.data+=yt;break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case A.EXCLAMATION_MARK:{n.data+="!",this.state=v.COMMENT_LESS_THAN_SIGN_BANG;break}case A.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=v.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===A.HYPHEN_MINUS?this.state=v.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=v.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===A.HYPHEN_MINUS?this.state=v.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=v.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==A.GREATER_THAN_SIGN&&t!==A.EOF&&this._err(X.nestedComment),this.state=v.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{this.state=v.COMMENT_END;break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=v.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentComment(n);break}case A.EXCLAMATION_MARK:{this.state=v.COMMENT_END_BANG;break}case A.HYPHEN_MINUS:{n.data+="-";break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=v.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case A.HYPHEN_MINUS:{n.data+="--!",this.state=v.COMMENT_END_DASH;break}case A.GREATER_THAN_SIGN:{this._err(X.incorrectlyClosedComment),this.state=v.DATA,this.emitCurrentComment(n);break}case A.EOF:{this._err(X.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=v.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_DOCTYPE_NAME;break}case A.GREATER_THAN_SIGN:{this.state=v.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case A.EOF:{this._err(X.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingWhitespaceBeforeDoctypeName),this.state=v.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(du(t))this._createDoctypeToken(String.fromCharCode(Sl(t))),this.state=v.DOCTYPE_NAME;else switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.NULL:{this._err(X.unexpectedNullCharacter),this._createDoctypeToken(yt),this.state=v.DOCTYPE_NAME;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=v.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.AFTER_DOCTYPE_NAME;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.name+=yt;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(du(t)?Sl(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(Sn.PUBLIC,!1)?this.state=v.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Sn.SYSTEM,!1)?this.state=v.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(X.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case A.QUOTATION_MARK:{this._err(X.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this._err(X.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.QUOTATION_MARK:{n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{n.publicId="",this.state=v.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case A.QUOTATION_MARK:{this.state=v.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.publicId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case A.APOSTROPHE:{this.state=v.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.publicId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case A.GREATER_THAN_SIGN:{this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.QUOTATION_MARK:{this._err(X.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this._err(X.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.QUOTATION_MARK:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:{this.state=v.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case A.QUOTATION_MARK:{this._err(X.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{this._err(X.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.QUOTATION_MARK:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case A.APOSTROPHE:{n.systemId="",this.state=v.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case A.GREATER_THAN_SIGN:{this._err(X.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.DATA,this.emitCurrentDoctype(n);break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case A.QUOTATION_MARK:{this.state=v.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.systemId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case A.APOSTROPHE:{this.state=v.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case A.NULL:{this._err(X.unexpectedNullCharacter),n.systemId+=yt;break}case A.GREATER_THAN_SIGN:{this._err(X.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case A.SPACE:case A.LINE_FEED:case A.TABULATION:case A.FORM_FEED:break;case A.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.EOF:{this._err(X.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(X.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=v.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case A.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=v.DATA;break}case A.NULL:{this._err(X.unexpectedNullCharacter);break}case A.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case A.RIGHT_SQUARE_BRACKET:{this.state=v.CDATA_SECTION_BRACKET;break}case A.EOF:{this._err(X.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===A.RIGHT_SQUARE_BRACKET?this.state=v.CDATA_SECTION_END:(this._emitChars("]"),this.state=v.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case A.GREATER_THAN_SIGN:{this.state=v.DATA;break}case A.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=v.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(A.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&Qy(this.preprocessor.peek(1))?v.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){Qy(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===A.SEMICOLON&&this._err(X.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const Zy=new Set([p.DD,p.DT,p.LI,p.OPTGROUP,p.OPTION,p.P,p.RB,p.RP,p.RT,p.RTC]),eT=new Set([...Zy,p.CAPTION,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]),wl=new Set([p.APPLET,p.CAPTION,p.HTML,p.MARQUEE,p.OBJECT,p.TABLE,p.TD,p.TEMPLATE,p.TH]),lL=new Set([...wl,p.OL,p.UL]),cL=new Set([...wl,p.BUTTON]),tT=new Set([p.ANNOTATION_XML,p.MI,p.MN,p.MO,p.MS,p.MTEXT]),nT=new Set([p.DESC,p.FOREIGN_OBJECT,p.TITLE]),fL=new Set([p.TR,p.TEMPLATE,p.HTML]),dL=new Set([p.TBODY,p.TFOOT,p.THEAD,p.TEMPLATE,p.HTML]),hL=new Set([p.TABLE,p.TEMPLATE,p.HTML]),pL=new Set([p.TD,p.TH]);class mL{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=p.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===p.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===re.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const o=this._indexOf(t)+1;this.items.splice(o,0,n),this.tagIDs.splice(o,0,r),this.stackTop++,o===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,o===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==re.HTML);this.shortenToLength(Math.max(n,0))}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(Math.max(n,0))}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(Math.max(r,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(Eh,re.HTML)}popUntilTableCellPopped(){this.popUntilPopped(pL,re.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(hL,re.HTML)}clearBackToTableBodyContext(){this.clearBackTo(dL,re.HTML)}clearBackToTableRowContext(){this.clearBackTo(fL,re.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===p.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===p.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const o=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case re.HTML:{if(o===t)return!0;if(n.has(o))return!1;break}case re.SVG:{if(nT.has(o))return!1;break}case re.MATHML:{if(tT.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,wl)}hasInListItemScope(t){return this.hasInDynamicScope(t,lL)}hasInButtonScope(t){return this.hasInDynamicScope(t,cL)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case re.HTML:{if(Eh.has(n))return!0;if(wl.has(n))return!1;break}case re.SVG:{if(nT.has(n))return!1;break}case re.MATHML:{if(tT.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===re.HTML)switch(this.tagIDs[n]){case t:return!0;case p.TABLE:case p.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===re.HTML)switch(this.tagIDs[t]){case p.TBODY:case p.THEAD:case p.TFOOT:return!0;case p.TABLE:case p.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===re.HTML)switch(this.tagIDs[n]){case t:return!0;case p.OPTION:case p.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&Zy.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&eT.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&eT.has(this.currentTagId);)this.pop()}}const yh=3;var Ir;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(Ir||(Ir={}));const rT={type:Ir.Marker};class gL{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],o=n.length,u=this.treeAdapter.getTagName(t),a=this.treeAdapter.getNamespaceURI(t);for(let c=0;c<this.entries.length;c++){const f=this.entries[c];if(f.type===Ir.Marker)break;const{element:h}=f;if(this.treeAdapter.getTagName(h)===u&&this.treeAdapter.getNamespaceURI(h)===a){const m=this.treeAdapter.getAttrList(h);m.length===o&&r.push({idx:c,attrs:m})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<yh)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<yh)return;const o=new Map(n.map(a=>[a.name,a.value]));let u=0;for(let a=0;a<r.length;a++){const c=r[a];c.attrs.every(f=>o.get(f.name)===f.value)&&(u+=1,u>=yh&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(rT)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:Ir.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:Ir.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(rT);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===Ir.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===Ir.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===Ir.Element&&n.element===t)}}const Ei={createDocument(){return{nodeName:"#document",mode:Yn.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const o=e.childNodes.find(u=>u.nodeName==="#documentType");if(o)o.name=t,o.publicId=n,o.systemId=r;else{const u={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};Ei.appendChild(e,u)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(Ei.isTextNode(n)){n.value+=t;return}}Ei.appendChild(e,Ei.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Ei.isTextNode(r)?r.value+=t:Ei.insertBefore(e,Ei.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation=U(U({},e.sourceCodeLocation),t)}},iT="html",EL="about:legacy-compat",yL="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",sT=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],TL=[...sT,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],bL=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),oT=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],_L=[...oT,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function uT(e,t){return t.some(n=>e.startsWith(n))}function xL(e){return e.name===iT&&e.publicId===null&&(e.systemId===null||e.systemId===EL)}function SL(e){if(e.name!==iT)return Yn.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===yL)return Yn.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),bL.has(n))return Yn.QUIRKS;let r=t===null?TL:sT;if(uT(n,r))return Yn.QUIRKS;if(r=t===null?oT:_L,uT(n,r))return Yn.LIMITED_QUIRKS}return Yn.NO_QUIRKS}const aT={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},wL="definitionurl",CL="definitionURL",AL=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),vL=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:re.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:re.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:re.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:re.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:re.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:re.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:re.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:re.XML}],["xml:space",{prefix:"xml",name:"space",namespace:re.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:re.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:re.XMLNS}]]),kL=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),NL=new Set([p.B,p.BIG,p.BLOCKQUOTE,p.BODY,p.BR,p.CENTER,p.CODE,p.DD,p.DIV,p.DL,p.DT,p.EM,p.EMBED,p.H1,p.H2,p.H3,p.H4,p.H5,p.H6,p.HEAD,p.HR,p.I,p.IMG,p.LI,p.LISTING,p.MENU,p.META,p.NOBR,p.OL,p.P,p.PRE,p.RUBY,p.S,p.SMALL,p.SPAN,p.STRONG,p.STRIKE,p.SUB,p.SUP,p.TABLE,p.TT,p.U,p.UL,p.VAR]);function OL(e){const t=e.tagID;return t===p.FONT&&e.attrs.some(({name:r})=>r===Xi.COLOR||r===Xi.SIZE||r===Xi.FACE)||NL.has(t)}function lT(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===wL){e.attrs[t].name=CL;break}}function cT(e){for(let t=0;t<e.attrs.length;t++){const n=AL.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Th(e){for(let t=0;t<e.attrs.length;t++){const n=vL.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function IL(e){const t=kL.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Js(e.tagName))}function PL(e,t){return t===re.MATHML&&(e===p.MI||e===p.MO||e===p.MN||e===p.MS||e===p.MTEXT)}function RL(e,t,n){if(t===re.MATHML&&e===p.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Xi.ENCODING){const o=n[r].value.toLowerCase();return o===aT.TEXT_HTML||o===aT.APPLICATION_XML}}return t===re.SVG&&(e===p.FOREIGN_OBJECT||e===p.DESC||e===p.TITLE)}function LL(e,t,n,r){return(!r||r===re.HTML)&&RL(e,t,n)||(!r||r===re.MATHML)&&PL(e,t)}const DL="hidden",FL=8,ML=3;var P;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(P||(P={}));const BL={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},fT=new Set([p.TABLE,p.TBODY,p.TFOOT,p.THEAD,p.TR]),dT={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Ei,onParseError:null};class hT{constructor(t,n,r=null,o=null){this.fragmentContext=r,this.scriptHandler=o,this.currentToken=null,this.stopped=!1,this.insertionMode=P.INITIAL,this.originalInsertionMode=P.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options=U(U({},dT),t),this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n!=null?n:this.treeAdapter.createDocument(),this.tokenizer=new aL(this.options,this),this.activeFormattingElements=new gL(this.treeAdapter),this.fragmentContextID=r?Js(this.treeAdapter.getTagName(r)):p.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new mL(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r=U(U({},dT),n);t!=null||(t=r.treeAdapter.createElement(j.TEMPLATE,re.HTML,[]));const o=r.treeAdapter.createElement("documentmock",re.HTML,[]),u=new this(r,o,t);return u.fragmentContextID===p.TEMPLATE&&u.tmplInsertionModeStack.unshift(P.IN_TEMPLATE),u._initTokenizerForFragmentParsing(),u._insertFakeRootElement(),u._resetInsertionMode(),u._findFormInFragmentContext(),u}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var o;if(!this.onParseError)return;const u=(o=t.location)!==null&&o!==void 0?o:BL,a={code:n,startLine:u.startLine,startCol:u.startCol,startOffset:u.startOffset,endLine:r?u.startLine:u.endLine,endCol:r?u.startCol:u.endCol,endOffset:r?u.startOffset:u.endOffset};this.onParseError(a)}onItemPush(t,n,r){var o,u;(u=(o=this.treeAdapter).onItemPush)===null||u===void 0||u.call(o,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,o;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(o=(r=this.treeAdapter).onItemPop)===null||o===void 0||o.call(r,t,this.openElements.current),n){let u,a;this.openElements.stackTop===0&&this.fragmentContext?(u=this.fragmentContext,a=this.fragmentContextID):{current:u,currentTagId:a}=this.openElements,this._setContextModes(u,a)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===re.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,re.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=P.TEXT}switchToPlaintextParsing(){this.insertionMode=P.TEXT,this.originalInsertionMode=P.IN_BODY,this.tokenizer.state=It.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===j.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==re.HTML))switch(this.fragmentContextID){case p.TITLE:case p.TEXTAREA:{this.tokenizer.state=It.RCDATA;break}case p.STYLE:case p.XMP:case p.IFRAME:case p.NOEMBED:case p.NOFRAMES:case p.NOSCRIPT:{this.tokenizer.state=It.RAWTEXT;break}case p.SCRIPT:{this.tokenizer.state=It.SCRIPT_DATA;break}case p.PLAINTEXT:{this.tokenizer.state=It.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",o=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,o),t.location){const a=this.treeAdapter.getChildNodes(this.document).find(c=>this.treeAdapter.isDocumentTypeNode(c));a&&this.treeAdapter.setNodeSourceCodeLocation(a,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&ye(U({},n),{startTag:n});this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r!=null?r:this.document,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,re.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,re.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(j.HTML,re.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,p.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const o=this.treeAdapter.getChildNodes(n),u=r?o.lastIndexOf(r):o.length,a=o[u-1];if(this.treeAdapter.getNodeSourceCodeLocation(a)){const{endLine:f,endCol:h,endOffset:m}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(a,{endLine:f,endCol:h,endOffset:m})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(a,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,o=this.treeAdapter.getTagName(t),u=n.type===qe.END_TAG&&o===n.tagName?{endTag:U({},r),endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,u)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===p.SVG&&this.treeAdapter.getTagName(n)===j.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===re.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===p.MGLYPH||t.tagID===p.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,re.HTML)}_processToken(t){switch(t.type){case qe.CHARACTER:{this.onCharacter(t);break}case qe.NULL_CHARACTER:{this.onNullCharacter(t);break}case qe.COMMENT:{this.onComment(t);break}case qe.DOCTYPE:{this.onDoctype(t);break}case qe.START_TAG:{this._processStartTag(t);break}case qe.END_TAG:{this.onEndTag(t);break}case qe.EOF:{this.onEof(t);break}case qe.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const o=this.treeAdapter.getNamespaceURI(n),u=this.treeAdapter.getAttrList(n);return LL(t,o,u,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===Ir.Marker||this.openElements.contains(o.element)),r=n===-1?t-1:n-1;for(let o=r;o>=0;o--){const u=this.activeFormattingElements.entries[o];this._insertElement(u.token,this.treeAdapter.getNamespaceURI(u.element)),u.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=P.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(p.P),this.openElements.popUntilTagNamePopped(p.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case p.TR:{this.insertionMode=P.IN_ROW;return}case p.TBODY:case p.THEAD:case p.TFOOT:{this.insertionMode=P.IN_TABLE_BODY;return}case p.CAPTION:{this.insertionMode=P.IN_CAPTION;return}case p.COLGROUP:{this.insertionMode=P.IN_COLUMN_GROUP;return}case p.TABLE:{this.insertionMode=P.IN_TABLE;return}case p.BODY:{this.insertionMode=P.IN_BODY;return}case p.FRAMESET:{this.insertionMode=P.IN_FRAMESET;return}case p.SELECT:{this._resetInsertionModeForSelect(t);return}case p.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case p.HTML:{this.insertionMode=this.headElement?P.AFTER_HEAD:P.BEFORE_HEAD;return}case p.TD:case p.TH:{if(t>0){this.insertionMode=P.IN_CELL;return}break}case p.HEAD:{if(t>0){this.insertionMode=P.IN_HEAD;return}break}}this.insertionMode=P.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===p.TEMPLATE)break;if(r===p.TABLE){this.insertionMode=P.IN_SELECT_IN_TABLE;return}}this.insertionMode=P.IN_SELECT}_isElementCausesFosterParenting(t){return fT.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case p.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===re.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case p.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return iL[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){pD(this,t);return}switch(this.insertionMode){case P.INITIAL:{hu(this,t);break}case P.BEFORE_HTML:{pu(this,t);break}case P.BEFORE_HEAD:{mu(this,t);break}case P.IN_HEAD:{gu(this,t);break}case P.IN_HEAD_NO_SCRIPT:{Eu(this,t);break}case P.AFTER_HEAD:{yu(this,t);break}case P.IN_BODY:case P.IN_CAPTION:case P.IN_CELL:case P.IN_TEMPLATE:{mT(this,t);break}case P.TEXT:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{Sh(this,t);break}case P.IN_TABLE_TEXT:{ST(this,t);break}case P.IN_COLUMN_GROUP:{vl(this,t);break}case P.AFTER_BODY:{Ol(this,t);break}case P.AFTER_AFTER_BODY:{Il(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){hD(this,t);return}switch(this.insertionMode){case P.INITIAL:{hu(this,t);break}case P.BEFORE_HTML:{pu(this,t);break}case P.BEFORE_HEAD:{mu(this,t);break}case P.IN_HEAD:{gu(this,t);break}case P.IN_HEAD_NO_SCRIPT:{Eu(this,t);break}case P.AFTER_HEAD:{yu(this,t);break}case P.TEXT:{this._insertCharacters(t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{Sh(this,t);break}case P.IN_COLUMN_GROUP:{vl(this,t);break}case P.AFTER_BODY:{Ol(this,t);break}case P.AFTER_AFTER_BODY:{Il(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){_h(this,t);return}switch(this.insertionMode){case P.INITIAL:case P.BEFORE_HTML:case P.BEFORE_HEAD:case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:case P.IN_BODY:case P.IN_TABLE:case P.IN_CAPTION:case P.IN_COLUMN_GROUP:case P.IN_TABLE_BODY:case P.IN_ROW:case P.IN_CELL:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:case P.IN_TEMPLATE:case P.IN_FRAMESET:case P.AFTER_FRAMESET:{_h(this,t);break}case P.IN_TABLE_TEXT:{_u(this,t);break}case P.AFTER_BODY:{qL(this,t);break}case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{YL(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case P.INITIAL:{WL(this,t);break}case P.BEFORE_HEAD:case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:{this._err(t,X.misplacedDoctype);break}case P.IN_TABLE_TEXT:{_u(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,X.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?mD(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case P.INITIAL:{hu(this,t);break}case P.BEFORE_HTML:{GL(this,t);break}case P.BEFORE_HEAD:{QL(this,t);break}case P.IN_HEAD:{dr(this,t);break}case P.IN_HEAD_NO_SCRIPT:{ZL(this,t);break}case P.AFTER_HEAD:{t6(this,t);break}case P.IN_BODY:{sn(this,t);break}case P.IN_TABLE:{Zs(this,t);break}case P.IN_TABLE_TEXT:{_u(this,t);break}case P.IN_CAPTION:{X6(this,t);break}case P.IN_COLUMN_GROUP:{wh(this,t);break}case P.IN_TABLE_BODY:{kl(this,t);break}case P.IN_ROW:{Nl(this,t);break}case P.IN_CELL:{eD(this,t);break}case P.IN_SELECT:{AT(this,t);break}case P.IN_SELECT_IN_TABLE:{nD(this,t);break}case P.IN_TEMPLATE:{iD(this,t);break}case P.AFTER_BODY:{oD(this,t);break}case P.IN_FRAMESET:{uD(this,t);break}case P.AFTER_FRAMESET:{lD(this,t);break}case P.AFTER_AFTER_BODY:{fD(this,t);break}case P.AFTER_AFTER_FRAMESET:{dD(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?gD(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case P.INITIAL:{hu(this,t);break}case P.BEFORE_HTML:{KL(this,t);break}case P.BEFORE_HEAD:{XL(this,t);break}case P.IN_HEAD:{JL(this,t);break}case P.IN_HEAD_NO_SCRIPT:{e6(this,t);break}case P.AFTER_HEAD:{n6(this,t);break}case P.IN_BODY:{Al(this,t);break}case P.TEXT:{z6(this,t);break}case P.IN_TABLE:{Tu(this,t);break}case P.IN_TABLE_TEXT:{_u(this,t);break}case P.IN_CAPTION:{J6(this,t);break}case P.IN_COLUMN_GROUP:{Z6(this,t);break}case P.IN_TABLE_BODY:{Ch(this,t);break}case P.IN_ROW:{CT(this,t);break}case P.IN_CELL:{tD(this,t);break}case P.IN_SELECT:{vT(this,t);break}case P.IN_SELECT_IN_TABLE:{rD(this,t);break}case P.IN_TEMPLATE:{sD(this,t);break}case P.AFTER_BODY:{NT(this,t);break}case P.IN_FRAMESET:{aD(this,t);break}case P.AFTER_FRAMESET:{cD(this,t);break}case P.AFTER_AFTER_BODY:{Il(this,t);break}}}onEof(t){switch(this.insertionMode){case P.INITIAL:{hu(this,t);break}case P.BEFORE_HTML:{pu(this,t);break}case P.BEFORE_HEAD:{mu(this,t);break}case P.IN_HEAD:{gu(this,t);break}case P.IN_HEAD_NO_SCRIPT:{Eu(this,t);break}case P.AFTER_HEAD:{yu(this,t);break}case P.IN_BODY:case P.IN_TABLE:case P.IN_CAPTION:case P.IN_COLUMN_GROUP:case P.IN_TABLE_BODY:case P.IN_ROW:case P.IN_CELL:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:{_T(this,t);break}case P.TEXT:{j6(this,t);break}case P.IN_TABLE_TEXT:{_u(this,t);break}case P.IN_TEMPLATE:{kT(this,t);break}case P.AFTER_BODY:case P.IN_FRAMESET:case P.AFTER_FRAMESET:case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{xh(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===A.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:case P.TEXT:case P.IN_COLUMN_GROUP:case P.IN_SELECT:case P.IN_SELECT_IN_TABLE:case P.IN_FRAMESET:case P.AFTER_FRAMESET:{this._insertCharacters(t);break}case P.IN_BODY:case P.IN_CAPTION:case P.IN_CELL:case P.IN_TEMPLATE:case P.AFTER_BODY:case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{pT(this,t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{Sh(this,t);break}case P.IN_TABLE_TEXT:{xT(this,t);break}}}}function UL(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):bT(e,t),n}function HL(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const o=e.openElements.items[r];if(o===t.element)break;e._isSpecialElement(o,e.openElements.tagIDs[r])&&(n=o)}return n||(e.openElements.shortenToLength(Math.max(r,0)),e.activeFormattingElements.removeEntry(t)),n}function zL(e,t,n){let r=t,o=e.openElements.getCommonAncestor(t);for(let u=0,a=o;a!==n;u++,a=o){o=e.openElements.getCommonAncestor(a);const c=e.activeFormattingElements.getElementEntry(a),f=c&&u>=ML;!c||f?(f&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(a)):(a=jL(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(a,r),r=a)}return r}function jL(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function $L(e,t,n){const r=e.treeAdapter.getTagName(t),o=Js(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const u=e.treeAdapter.getNamespaceURI(t);o===p.TEMPLATE&&u===re.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function VL(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:o}=n,u=e.treeAdapter.createElement(o.tagName,r,o.attrs);e._adoptNodes(t,u),e.treeAdapter.appendChild(t,u),e.activeFormattingElements.insertElementAfterBookmark(u,o),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,u,o.tagID)}function bh(e,t){for(let n=0;n<FL;n++){const r=UL(e,t);if(!r)break;const o=HL(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const u=zL(e,o,r.element),a=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(u),a&&$L(e,a,u),VL(e,o,r)}}function _h(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function qL(e,t){e._appendCommentNode(t,e.openElements.items[0])}function YL(e,t){e._appendCommentNode(t,e.document)}function xh(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],o=e.treeAdapter.getNodeSourceCodeLocation(r);if(o&&!o.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const u=e.openElements.items[1],a=e.treeAdapter.getNodeSourceCodeLocation(u);a&&!a.endTag&&e._setEndLocation(u,t)}}}}function WL(e,t){e._setDocumentType(t);const n=t.forceQuirks?Yn.QUIRKS:SL(t);xL(t)||e._err(t,X.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=P.BEFORE_HTML}function hu(e,t){e._err(t,X.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Yn.QUIRKS),e.insertionMode=P.BEFORE_HTML,e._processToken(t)}function GL(e,t){t.tagID===p.HTML?(e._insertElement(t,re.HTML),e.insertionMode=P.BEFORE_HEAD):pu(e,t)}function KL(e,t){const n=t.tagID;(n===p.HTML||n===p.HEAD||n===p.BODY||n===p.BR)&&pu(e,t)}function pu(e,t){e._insertFakeRootElement(),e.insertionMode=P.BEFORE_HEAD,e._processToken(t)}function QL(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.HEAD:{e._insertElement(t,re.HTML),e.headElement=e.openElements.current,e.insertionMode=P.IN_HEAD;break}default:mu(e,t)}}function XL(e,t){const n=t.tagID;n===p.HEAD||n===p.BODY||n===p.HTML||n===p.BR?mu(e,t):e._err(t,X.endTagWithoutMatchingOpenElement)}function mu(e,t){e._insertFakeElement(j.HEAD,p.HEAD),e.headElement=e.openElements.current,e.insertionMode=P.IN_HEAD,e._processToken(t)}function dr(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:{e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.TITLE:{e._switchToTextParsing(t,It.RCDATA);break}case p.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,It.RAWTEXT):(e._insertElement(t,re.HTML),e.insertionMode=P.IN_HEAD_NO_SCRIPT);break}case p.NOFRAMES:case p.STYLE:{e._switchToTextParsing(t,It.RAWTEXT);break}case p.SCRIPT:{e._switchToTextParsing(t,It.SCRIPT_DATA);break}case p.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=P.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(P.IN_TEMPLATE);break}case p.HEAD:{e._err(t,X.misplacedStartTagForHeadElement);break}default:gu(e,t)}}function JL(e,t){switch(t.tagID){case p.HEAD:{e.openElements.pop(),e.insertionMode=P.AFTER_HEAD;break}case p.BODY:case p.BR:case p.HTML:{gu(e,t);break}case p.TEMPLATE:{Ji(e,t);break}default:e._err(t,X.endTagWithoutMatchingOpenElement)}}function Ji(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==p.TEMPLATE&&e._err(t,X.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,X.endTagWithoutMatchingOpenElement)}function gu(e,t){e.openElements.pop(),e.insertionMode=P.AFTER_HEAD,e._processToken(t)}function ZL(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.BASEFONT:case p.BGSOUND:case p.HEAD:case p.LINK:case p.META:case p.NOFRAMES:case p.STYLE:{dr(e,t);break}case p.NOSCRIPT:{e._err(t,X.nestedNoscriptInHead);break}default:Eu(e,t)}}function e6(e,t){switch(t.tagID){case p.NOSCRIPT:{e.openElements.pop(),e.insertionMode=P.IN_HEAD;break}case p.BR:{Eu(e,t);break}default:e._err(t,X.endTagWithoutMatchingOpenElement)}}function Eu(e,t){const n=t.type===qe.EOF?X.openElementsLeftAfterEof:X.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=P.IN_HEAD,e._processToken(t)}function t6(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.BODY:{e._insertElement(t,re.HTML),e.framesetOk=!1,e.insertionMode=P.IN_BODY;break}case p.FRAMESET:{e._insertElement(t,re.HTML),e.insertionMode=P.IN_FRAMESET;break}case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:case p.NOFRAMES:case p.SCRIPT:case p.STYLE:case p.TEMPLATE:case p.TITLE:{e._err(t,X.abandonedHeadElementChild),e.openElements.push(e.headElement,p.HEAD),dr(e,t),e.openElements.remove(e.headElement);break}case p.HEAD:{e._err(t,X.misplacedStartTagForHeadElement);break}default:yu(e,t)}}function n6(e,t){switch(t.tagID){case p.BODY:case p.HTML:case p.BR:{yu(e,t);break}case p.TEMPLATE:{Ji(e,t);break}default:e._err(t,X.endTagWithoutMatchingOpenElement)}}function yu(e,t){e._insertFakeElement(j.BODY,p.BODY),e.insertionMode=P.IN_BODY,Cl(e,t)}function Cl(e,t){switch(t.type){case qe.CHARACTER:{mT(e,t);break}case qe.WHITESPACE_CHARACTER:{pT(e,t);break}case qe.COMMENT:{_h(e,t);break}case qe.START_TAG:{sn(e,t);break}case qe.END_TAG:{Al(e,t);break}case qe.EOF:{_T(e,t);break}}}function pT(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function mT(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function r6(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function i6(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function s6(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_FRAMESET)}function o6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML)}function u6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&Eh.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,re.HTML)}function a6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function l6(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),n||(e.formElement=e.openElements.current))}function c6(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const o=e.openElements.tagIDs[r];if(n===p.LI&&o===p.LI||(n===p.DD||n===p.DT)&&(o===p.DD||o===p.DT)){e.openElements.generateImpliedEndTagsWithExclusion(o),e.openElements.popUntilTagNamePopped(o);break}if(o!==p.ADDRESS&&o!==p.DIV&&o!==p.P&&e._isSpecialElement(e.openElements.items[r],o))break}e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML)}function f6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),e.tokenizer.state=It.PLAINTEXT}function d6(e,t){e.openElements.hasInScope(p.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.framesetOk=!1}function h6(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(j.A);n&&(bh(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function p6(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function m6(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(p.NOBR)&&(bh(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,re.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function g6(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function E6(e,t){e.treeAdapter.getDocumentMode(e.document)!==Yn.QUIRKS&&e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,re.HTML),e.framesetOk=!1,e.insertionMode=P.IN_TABLE}function gT(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,re.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function ET(e){const t=Ky(e,Xi.TYPE);return t!=null&&t.toLowerCase()===DL}function y6(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,re.HTML),ET(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function T6(e,t){e._appendElement(t,re.HTML),t.ackSelfClosing=!0}function b6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._appendElement(t,re.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function _6(e,t){t.tagName=j.IMG,t.tagID=p.IMG,gT(e,t)}function x6(e,t){e._insertElement(t,re.HTML),e.skipNextNewLine=!0,e.tokenizer.state=It.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=P.TEXT}function S6(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,It.RAWTEXT)}function w6(e,t){e.framesetOk=!1,e._switchToTextParsing(t,It.RAWTEXT)}function yT(e,t){e._switchToTextParsing(t,It.RAWTEXT)}function C6(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===P.IN_TABLE||e.insertionMode===P.IN_CAPTION||e.insertionMode===P.IN_TABLE_BODY||e.insertionMode===P.IN_ROW||e.insertionMode===P.IN_CELL?P.IN_SELECT_IN_TABLE:P.IN_SELECT}function A6(e,t){e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML)}function v6(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,re.HTML)}function k6(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(p.RTC),e._insertElement(t,re.HTML)}function N6(e,t){e._reconstructActiveFormattingElements(),lT(t),Th(t),t.selfClosing?e._appendElement(t,re.MATHML):e._insertElement(t,re.MATHML),t.ackSelfClosing=!0}function O6(e,t){e._reconstructActiveFormattingElements(),cT(t),Th(t),t.selfClosing?e._appendElement(t,re.SVG):e._insertElement(t,re.SVG),t.ackSelfClosing=!0}function TT(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,re.HTML)}function sn(e,t){switch(t.tagID){case p.I:case p.S:case p.B:case p.U:case p.EM:case p.TT:case p.BIG:case p.CODE:case p.FONT:case p.SMALL:case p.STRIKE:case p.STRONG:{p6(e,t);break}case p.A:{h6(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{u6(e,t);break}case p.P:case p.DL:case p.OL:case p.UL:case p.DIV:case p.DIR:case p.NAV:case p.MAIN:case p.MENU:case p.ASIDE:case p.CENTER:case p.FIGURE:case p.FOOTER:case p.HEADER:case p.HGROUP:case p.DIALOG:case p.DETAILS:case p.ADDRESS:case p.ARTICLE:case p.SEARCH:case p.SECTION:case p.SUMMARY:case p.FIELDSET:case p.BLOCKQUOTE:case p.FIGCAPTION:{o6(e,t);break}case p.LI:case p.DD:case p.DT:{c6(e,t);break}case p.BR:case p.IMG:case p.WBR:case p.AREA:case p.EMBED:case p.KEYGEN:{gT(e,t);break}case p.HR:{b6(e,t);break}case p.RB:case p.RTC:{v6(e,t);break}case p.RT:case p.RP:{k6(e,t);break}case p.PRE:case p.LISTING:{a6(e,t);break}case p.XMP:{S6(e,t);break}case p.SVG:{O6(e,t);break}case p.HTML:{r6(e,t);break}case p.BASE:case p.LINK:case p.META:case p.STYLE:case p.TITLE:case p.SCRIPT:case p.BGSOUND:case p.BASEFONT:case p.TEMPLATE:{dr(e,t);break}case p.BODY:{i6(e,t);break}case p.FORM:{l6(e,t);break}case p.NOBR:{m6(e,t);break}case p.MATH:{N6(e,t);break}case p.TABLE:{E6(e,t);break}case p.INPUT:{y6(e,t);break}case p.PARAM:case p.TRACK:case p.SOURCE:{T6(e,t);break}case p.IMAGE:{_6(e,t);break}case p.BUTTON:{d6(e,t);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{g6(e,t);break}case p.IFRAME:{w6(e,t);break}case p.SELECT:{C6(e,t);break}case p.OPTION:case p.OPTGROUP:{A6(e,t);break}case p.NOEMBED:case p.NOFRAMES:{yT(e,t);break}case p.FRAMESET:{s6(e,t);break}case p.TEXTAREA:{x6(e,t);break}case p.NOSCRIPT:{e.options.scriptingEnabled?yT(e,t):TT(e,t);break}case p.PLAINTEXT:{f6(e,t);break}case p.COL:case p.TH:case p.TD:case p.TR:case p.HEAD:case p.FRAME:case p.TBODY:case p.TFOOT:case p.THEAD:case p.CAPTION:case p.COLGROUP:break;default:TT(e,t)}}function I6(e,t){if(e.openElements.hasInScope(p.BODY)&&(e.insertionMode=P.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function P6(e,t){e.openElements.hasInScope(p.BODY)&&(e.insertionMode=P.AFTER_BODY,NT(e,t))}function R6(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function L6(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(p.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(p.FORM):n&&e.openElements.remove(n))}function D6(e){e.openElements.hasInButtonScope(p.P)||e._insertFakeElement(j.P,p.P),e._closePElement()}function F6(e){e.openElements.hasInListItemScope(p.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(p.LI),e.openElements.popUntilTagNamePopped(p.LI))}function M6(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function B6(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function U6(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function H6(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(j.BR,p.BR),e.openElements.pop(),e.framesetOk=!1}function bT(e,t){const n=t.tagName,r=t.tagID;for(let o=e.openElements.stackTop;o>0;o--){const u=e.openElements.items[o],a=e.openElements.tagIDs[o];if(r===a&&(r!==p.UNKNOWN||e.treeAdapter.getTagName(u)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=o&&e.openElements.shortenToLength(o);break}if(e._isSpecialElement(u,a))break}}function Al(e,t){switch(t.tagID){case p.A:case p.B:case p.I:case p.S:case p.U:case p.EM:case p.TT:case p.BIG:case p.CODE:case p.FONT:case p.NOBR:case p.SMALL:case p.STRIKE:case p.STRONG:{bh(e,t);break}case p.P:{D6(e);break}case p.DL:case p.UL:case p.OL:case p.DIR:case p.DIV:case p.NAV:case p.PRE:case p.MAIN:case p.MENU:case p.ASIDE:case p.BUTTON:case p.CENTER:case p.FIGURE:case p.FOOTER:case p.HEADER:case p.HGROUP:case p.DIALOG:case p.ADDRESS:case p.ARTICLE:case p.DETAILS:case p.SEARCH:case p.SECTION:case p.SUMMARY:case p.LISTING:case p.FIELDSET:case p.BLOCKQUOTE:case p.FIGCAPTION:{R6(e,t);break}case p.LI:{F6(e);break}case p.DD:case p.DT:{M6(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{B6(e);break}case p.BR:{H6(e);break}case p.BODY:{I6(e,t);break}case p.HTML:{P6(e,t);break}case p.FORM:{L6(e);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{U6(e,t);break}case p.TEMPLATE:{Ji(e,t);break}default:bT(e,t)}}function _T(e,t){e.tmplInsertionModeStack.length>0?kT(e,t):xh(e,t)}function z6(e,t){var n;t.tagID===p.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function j6(e,t){e._err(t,X.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Sh(e,t){if(e.openElements.currentTagId!==void 0&&fT.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=P.IN_TABLE_TEXT,t.type){case qe.CHARACTER:{ST(e,t);break}case qe.WHITESPACE_CHARACTER:{xT(e,t);break}}else bu(e,t)}function $6(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_CAPTION}function V6(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_COLUMN_GROUP}function q6(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(j.COLGROUP,p.COLGROUP),e.insertionMode=P.IN_COLUMN_GROUP,wh(e,t)}function Y6(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_TABLE_BODY}function W6(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(j.TBODY,p.TBODY),e.insertionMode=P.IN_TABLE_BODY,kl(e,t)}function G6(e,t){e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function K6(e,t){ET(t)?e._appendElement(t,re.HTML):bu(e,t),t.ackSelfClosing=!0}function Q6(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,re.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Zs(e,t){switch(t.tagID){case p.TD:case p.TH:case p.TR:{W6(e,t);break}case p.STYLE:case p.SCRIPT:case p.TEMPLATE:{dr(e,t);break}case p.COL:{q6(e,t);break}case p.FORM:{Q6(e,t);break}case p.TABLE:{G6(e,t);break}case p.TBODY:case p.TFOOT:case p.THEAD:{Y6(e,t);break}case p.INPUT:{K6(e,t);break}case p.CAPTION:{$6(e,t);break}case p.COLGROUP:{V6(e,t);break}default:bu(e,t)}}function Tu(e,t){switch(t.tagID){case p.TABLE:{e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode());break}case p.TEMPLATE:{Ji(e,t);break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:case p.TBODY:case p.TD:case p.TFOOT:case p.TH:case p.THEAD:case p.TR:break;default:bu(e,t)}}function bu(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,Cl(e,t),e.fosterParentingEnabled=n}function xT(e,t){e.pendingCharacterTokens.push(t)}function ST(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function _u(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)bu(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const wT=new Set([p.CAPTION,p.COL,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]);function X6(e,t){const n=t.tagID;wT.has(n)?e.openElements.hasInTableScope(p.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_TABLE,Zs(e,t)):sn(e,t)}function J6(e,t){const n=t.tagID;switch(n){case p.CAPTION:case p.TABLE:{e.openElements.hasInTableScope(p.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_TABLE,n===p.TABLE&&Tu(e,t));break}case p.BODY:case p.COL:case p.COLGROUP:case p.HTML:case p.TBODY:case p.TD:case p.TFOOT:case p.TH:case p.THEAD:case p.TR:break;default:Al(e,t)}}function wh(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.COL:{e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.TEMPLATE:{dr(e,t);break}default:vl(e,t)}}function Z6(e,t){switch(t.tagID){case p.COLGROUP:{e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=P.IN_TABLE);break}case p.TEMPLATE:{Ji(e,t);break}case p.COL:break;default:vl(e,t)}}function vl(e,t){e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=P.IN_TABLE,e._processToken(t))}function kl(e,t){switch(t.tagID){case p.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_ROW;break}case p.TH:case p.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(j.TR,p.TR),e.insertionMode=P.IN_ROW,Nl(e,t);break}case p.CAPTION:case p.COL:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE,Zs(e,t));break}default:Zs(e,t)}}function Ch(e,t){const n=t.tagID;switch(t.tagID){case p.TBODY:case p.TFOOT:case p.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE);break}case p.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE,Tu(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:case p.TD:case p.TH:case p.TR:break;default:Tu(e,t)}}function Nl(e,t){switch(t.tagID){case p.TH:case p.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,re.HTML),e.insertionMode=P.IN_CELL,e.activeFormattingElements.insertMarker();break}case p.CAPTION:case p.COL:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:case p.TR:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY,kl(e,t));break}default:Zs(e,t)}}function CT(e,t){switch(t.tagID){case p.TR:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY);break}case p.TABLE:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY,Ch(e,t));break}case p.TBODY:case p.TFOOT:case p.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(p.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=P.IN_TABLE_BODY,Ch(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:case p.TD:case p.TH:break;default:Tu(e,t)}}function eD(e,t){const n=t.tagID;wT.has(n)?(e.openElements.hasInTableScope(p.TD)||e.openElements.hasInTableScope(p.TH))&&(e._closeTableCell(),Nl(e,t)):sn(e,t)}function tD(e,t){const n=t.tagID;switch(n){case p.TD:case p.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_ROW);break}case p.TABLE:case p.TBODY:case p.TFOOT:case p.THEAD:case p.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),CT(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:break;default:Al(e,t)}}function AT(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.OPTION:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._insertElement(t,re.HTML);break}case p.OPTGROUP:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._insertElement(t,re.HTML);break}case p.HR:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.INPUT:case p.KEYGEN:case p.TEXTAREA:case p.SELECT:{e.openElements.hasInSelectScope(p.SELECT)&&(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode(),t.tagID!==p.SELECT&&e._processStartTag(t));break}case p.SCRIPT:case p.TEMPLATE:{dr(e,t);break}}}function vT(e,t){switch(t.tagID){case p.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===p.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===p.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop();break}case p.OPTION:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop();break}case p.SELECT:{e.openElements.hasInSelectScope(p.SELECT)&&(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode());break}case p.TEMPLATE:{Ji(e,t);break}}}function nD(e,t){const n=t.tagID;n===p.CAPTION||n===p.TABLE||n===p.TBODY||n===p.TFOOT||n===p.THEAD||n===p.TR||n===p.TD||n===p.TH?(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode(),e._processStartTag(t)):AT(e,t)}function rD(e,t){const n=t.tagID;n===p.CAPTION||n===p.TABLE||n===p.TBODY||n===p.TFOOT||n===p.THEAD||n===p.TR||n===p.TD||n===p.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(p.SELECT),e._resetInsertionMode(),e.onEndTag(t)):vT(e,t)}function iD(e,t){switch(t.tagID){case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:case p.NOFRAMES:case p.SCRIPT:case p.STYLE:case p.TEMPLATE:case p.TITLE:{dr(e,t);break}case p.CAPTION:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:{e.tmplInsertionModeStack[0]=P.IN_TABLE,e.insertionMode=P.IN_TABLE,Zs(e,t);break}case p.COL:{e.tmplInsertionModeStack[0]=P.IN_COLUMN_GROUP,e.insertionMode=P.IN_COLUMN_GROUP,wh(e,t);break}case p.TR:{e.tmplInsertionModeStack[0]=P.IN_TABLE_BODY,e.insertionMode=P.IN_TABLE_BODY,kl(e,t);break}case p.TD:case p.TH:{e.tmplInsertionModeStack[0]=P.IN_ROW,e.insertionMode=P.IN_ROW,Nl(e,t);break}default:e.tmplInsertionModeStack[0]=P.IN_BODY,e.insertionMode=P.IN_BODY,sn(e,t)}}function sD(e,t){t.tagID===p.TEMPLATE&&Ji(e,t)}function kT(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):xh(e,t)}function oD(e,t){t.tagID===p.HTML?sn(e,t):Ol(e,t)}function NT(e,t){var n;if(t.tagID===p.HTML){if(e.fragmentContext||(e.insertionMode=P.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===p.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Ol(e,t)}function Ol(e,t){e.insertionMode=P.IN_BODY,Cl(e,t)}function uD(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.FRAMESET:{e._insertElement(t,re.HTML);break}case p.FRAME:{e._appendElement(t,re.HTML),t.ackSelfClosing=!0;break}case p.NOFRAMES:{dr(e,t);break}}}function aD(e,t){t.tagID===p.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==p.FRAMESET&&(e.insertionMode=P.AFTER_FRAMESET))}function lD(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.NOFRAMES:{dr(e,t);break}}}function cD(e,t){t.tagID===p.HTML&&(e.insertionMode=P.AFTER_AFTER_FRAMESET)}function fD(e,t){t.tagID===p.HTML?sn(e,t):Il(e,t)}function Il(e,t){e.insertionMode=P.IN_BODY,Cl(e,t)}function dD(e,t){switch(t.tagID){case p.HTML:{sn(e,t);break}case p.NOFRAMES:{dr(e,t);break}}}function hD(e,t){t.chars=yt,e._insertCharacters(t)}function pD(e,t){e._insertCharacters(t),e.framesetOk=!1}function OT(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==re.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function mD(e,t){if(OL(t))OT(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===re.MATHML?lT(t):r===re.SVG&&(IL(t),cT(t)),Th(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function gD(e,t){if(t.tagID===p.P||t.tagID===p.BR){OT(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===re.HTML){e._endTagOutsideForeignContent(t);break}const o=e.treeAdapter.getTagName(r);if(o.toLowerCase()===t.tagName){t.tagName=o,e.openElements.shortenToLength(n);break}}}j.AREA,j.BASE,j.BASEFONT,j.BGSOUND,j.BR,j.COL,j.EMBED,j.FRAME,j.HR,j.IMG,j.INPUT,j.KEYGEN,j.LINK,j.META,j.PARAM,j.SOURCE,j.TRACK,j.WBR;const ED=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,yD=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),IT={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function PT(e,t){const n=kD(e),r=Vy("type",{handlers:{root:TD,element:bD,text:_D,comment:LT,doctype:xD,raw:wD},unknown:CD}),o={parser:n?new hT(IT):hT.getFragmentParser(void 0,IT),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),eo(o,Nr());const u=n?o.parser.document:o.parser.getFragment(),a=TR(u,{file:o.options.file});return o.stitches&&bl(a,"comment",function(c,f,h){const m=c;if(m.value.stitch&&h&&f!==void 0){const E=h.children;return E[f]=m.value.stitch,f}}),a.type==="root"&&a.children.length===1&&a.children[0].type===e.type?a.children[0]:a}function RT(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function TD(e,t){RT(e.children,t)}function bD(e,t){AD(e,t),RT(e.children,t),vD(e,t)}function _D(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:qe.CHARACTER,chars:e.value,location:xu(e)};eo(t,Nr(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function xD(e,t){const n={type:qe.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:xu(e)};eo(t,Nr(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function SD(e,t){t.stitches=!0;const n=ND(e);if("children"in e&&"children"in n){const r=PT({type:"root",children:e.children},t.options);n.children=r.children}LT({type:"comment",value:{stitch:n}},t)}function LT(e,t){const n=e.value,r={type:qe.COMMENT,data:n,location:xu(e)};eo(t,Nr(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function wD(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,DT(t,Nr(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(ED,"&lt;$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function CD(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))SD(n,t);else{let r="";throw yD.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function eo(e,t){DT(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=It.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function DT(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function AD(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===It.PLAINTEXT)return;eo(t,Nr(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Ki.html;o===Ki.html&&n==="svg"&&(o=Ki.svg);const u=LR(ye(U({},e),{children:[]}),{space:o===Ki.svg?"svg":"html"}),a={type:qe.START_TAG,tagName:n,tagID:Js(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in u?u.attrs:[],location:xu(e)};t.parser.currentToken=a,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function vD(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&jR.includes(n)||t.parser.tokenizer.state===It.PLAINTEXT)return;eo(t,ll(e));const r={type:qe.END_TAG,tagName:n,tagID:Js(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:xu(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===It.RCDATA||t.parser.tokenizer.state===It.RAWTEXT||t.parser.tokenizer.state===It.SCRIPT_DATA)&&(t.parser.tokenizer.state=It.DATA)}function kD(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function xu(e){const t=Nr(e)||{line:void 0,column:void 0,offset:void 0},n=ll(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function ND(e){return"children"in e?Ws(ye(U({},e),{children:[]})):Ws(e)}function OD(e){return function(t,n){return PT(t,ye(U({},e),{file:n}))}}function FT(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,o=n.indexOf(t);for(;o!==-1;)r++,o=n.indexOf(t,o+t.length);return r}function ID(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function PD(e,t,n){const o=yl((n||{}).ignore||[]),u=RD(t);let a=-1;for(;++a<u.length;)py(e,"text",c);function c(h,m){let E=-1,b;for(;++E<m.length;){const T=m[E],_=b?b.children:void 0;if(o(T,_?_.indexOf(T):void 0,b))return;b=T}if(b)return f(h,m)}function f(h,m){const E=m[m.length-1],b=u[a][0],T=u[a][1];let _=0;const C=E.children.indexOf(h);let k=!1,M=[];b.lastIndex=0;let D=b.exec(h.value);for(;D;){const G=D.index,q={index:D.index,input:D.input,stack:[...m,h]};let B=T(...D,q);if(typeof B=="string"&&(B=B.length>0?{type:"text",value:B}:void 0),B===!1?b.lastIndex=G+1:(_!==G&&M.push({type:"text",value:h.value.slice(_,G)}),Array.isArray(B)?M.push(...B):B&&M.push(B),_=G+D[0].length,k=!0),!b.global)break;D=b.exec(h.value)}return k?(_<h.value.length&&M.push({type:"text",value:h.value.slice(_)}),E.children.splice(C,1,...M)):M=[h],C+M.length}}function RD(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const o=n[r];t.push([LD(o[0]),DD(o[1])])}return t}function LD(e){return typeof e=="string"?new RegExp(ID(e),"g"):e}function DD(e){return typeof e=="function"?e:function(){return e}}const Ah="phrasing",vh=["autolink","link","image","label"];function FD(){return{transforms:[$D],enter:{literalAutolink:BD,literalAutolinkEmail:kh,literalAutolinkHttp:kh,literalAutolinkWww:kh},exit:{literalAutolink:jD,literalAutolinkEmail:zD,literalAutolinkHttp:UD,literalAutolinkWww:HD}}}function MD(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Ah,notInConstruct:vh},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Ah,notInConstruct:vh},{character:":",before:"[ps]",after:"\\/",inConstruct:Ah,notInConstruct:vh}]}}function BD(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function kh(e){this.config.enter.autolinkProtocol.call(this,e)}function UD(e){this.config.exit.autolinkProtocol.call(this,e)}function HD(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function zD(e){this.config.exit.autolinkEmail.call(this,e)}function jD(e){this.exit(e)}function $D(e){PD(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,VD],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),qD]],{ignore:["link","linkReference"]})}function VD(e,t,n,r,o){let u="";if(!MT(o)||(/^w/i.test(t)&&(n=t+n,t="",u="http://"),!YD(n)))return!1;const a=WD(n+r);if(!a[0])return!1;const c={type:"link",title:null,url:u+t+a[0],children:[{type:"text",value:t+a[0]}]};return a[1]?[c,{type:"text",value:a[1]}]:c}function qD(e,t,n,r){return!MT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function YD(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function WD(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const o=FT(e,"(");let u=FT(e,")");for(;r!==-1&&o>u;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),u++;return[e,n]}function MT(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Gi(n)||fl(n))&&(!t||n!==47)}BT.peek=n4;function GD(){this.buffer()}function KD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function QD(){this.buffer()}function XD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function JD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=fr(this.sliceSerialize(e)).toLowerCase(),n.label=t}function ZD(e){this.exit(e)}function e4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=fr(this.sliceSerialize(e)).toLowerCase(),n.label=t}function t4(e){this.exit(e)}function n4(){return"["}function BT(e,t,n,r){const o=n.createTracker(r);let u=o.move("[^");const a=n.enter("footnoteReference"),c=n.enter("reference");return u+=o.move(n.safe(n.associationId(e),{after:"]",before:u})),c(),a(),u+=o.move("]"),u}function r4(){return{enter:{gfmFootnoteCallString:GD,gfmFootnoteCall:KD,gfmFootnoteDefinitionLabelString:QD,gfmFootnoteDefinition:XD},exit:{gfmFootnoteCallString:JD,gfmFootnoteCall:ZD,gfmFootnoteDefinitionLabelString:e4,gfmFootnoteDefinition:t4}}}function i4(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:BT},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,o,u,a){const c=u.createTracker(a);let f=c.move("[^");const h=u.enter("footnoteDefinition"),m=u.enter("label");return f+=c.move(u.safe(u.associationId(r),{before:f,after:"]"})),m(),f+=c.move("]:"),r.children&&r.children.length>0&&(c.shift(4),f+=c.move((t?`
29
+ `:" ")+u.indentLines(u.containerFlow(r,c.current()),t?UT:s4))),h(),f}}function s4(e,t,n){return t===0?e:UT(e,t,n)}function UT(e,t,n){return(n?"":" ")+e}const o4=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];HT.peek=f4;function u4(){return{canContainEols:["delete"],enter:{strikethrough:l4},exit:{strikethrough:c4}}}function a4(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:o4}],handlers:{delete:HT}}}function l4(e){this.enter({type:"delete",children:[]},e)}function c4(e){this.exit(e)}function HT(e,t,n,r){const o=n.createTracker(r),u=n.enter("strikethrough");let a=o.move("~~");return a+=n.containerPhrasing(e,ye(U({},o.current()),{before:a,after:"~"})),a+=o.move("~~"),u(),a}function f4(){return"~"}function d4(e){return e.length}function h4(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||d4,u=[],a=[],c=[],f=[];let h=0,m=-1;for(;++m<e.length;){const S=[],C=[];let k=-1;for(e[m].length>h&&(h=e[m].length);++k<e[m].length;){const M=p4(e[m][k]);if(n.alignDelimiters!==!1){const D=o(M);C[k]=D,(f[k]===void 0||D>f[k])&&(f[k]=D)}S.push(M)}a[m]=S,c[m]=C}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)u[E]=zT(r[E]);else{const S=zT(r);for(;++E<h;)u[E]=S}E=-1;const b=[],T=[];for(;++E<h;){const S=u[E];let C="",k="";S===99?(C=":",k=":"):S===108?C=":":S===114&&(k=":");let M=n.alignDelimiters===!1?1:Math.max(1,f[E]-C.length-k.length);const D=C+"-".repeat(M)+k;n.alignDelimiters!==!1&&(M=C.length+M+k.length,M>f[E]&&(f[E]=M),T[E]=M),b[E]=D}a.splice(1,0,b),c.splice(1,0,T),m=-1;const _=[];for(;++m<a.length;){const S=a[m],C=c[m];E=-1;const k=[];for(;++E<h;){const M=S[E]||"";let D="",G="";if(n.alignDelimiters!==!1){const q=f[E]-(C[E]||0),B=u[E];B===114?D=" ".repeat(q):B===99?q%2?(D=" ".repeat(q/2+.5),G=" ".repeat(q/2-.5)):(D=" ".repeat(q/2),G=D):G=" ".repeat(q)}n.delimiterStart!==!1&&!E&&k.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&M==="")&&(n.delimiterStart!==!1||E)&&k.push(" "),n.alignDelimiters!==!1&&k.push(D),k.push(M),n.alignDelimiters!==!1&&k.push(G),n.padding!==!1&&k.push(" "),(n.delimiterEnd!==!1||E!==h-1)&&k.push("|")}_.push(n.delimiterEnd===!1?k.join("").replace(/ +$/,""):k.join(""))}return _.join(`
30
+ `)}function p4(e){return e==null?"":String(e)}function zT(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function m4(e,t,n,r){const o=n.enter("blockquote"),u=n.createTracker(r);u.move("> "),u.shift(2);const a=n.indentLines(n.containerFlow(e,u.current()),g4);return o(),a}function g4(e,t,n){return">"+(n?"":" ")+e}function E4(e,t){return jT(e,t.inConstruct,!0)&&!jT(e,t.notInConstruct,!1)}function jT(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function $T(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if(n.unsafe[o].character===`
31
+ `&&E4(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return`\\
32
+ `}function y4(e,t){const n=String(e);let r=n.indexOf(t),o=r,u=0,a=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===o?++u>a&&(a=u):u=1,o=r+t.length,r=n.indexOf(t,o);return a}function T4(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function b4(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function _4(e,t,n,r){const o=b4(n),u=e.value||"",a=o==="`"?"GraveAccent":"Tilde";if(T4(e,n)){const E=n.enter("codeIndented"),b=n.indentLines(u,x4);return E(),b}const c=n.createTracker(r),f=o.repeat(Math.max(y4(u,o)+1,3)),h=n.enter("codeFenced");let m=c.move(f);if(e.lang){const E=n.enter(`codeFencedLang${a}`);m+=c.move(n.safe(e.lang,U({before:m,after:" ",encode:["`"]},c.current()))),E()}if(e.lang&&e.meta){const E=n.enter(`codeFencedMeta${a}`);m+=c.move(" "),m+=c.move(n.safe(e.meta,U({before:m,after:`
33
33
  `,encode:["`"]},c.current()))),E()}return m+=c.move(`
34
34
  `),u&&(m+=c.move(u+`
35
- `)),m+=c.move(f),h(),m}function lD(e,t,n){return(n?"":" ")+e}function Rh(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function cD(e,t,n,r){const o=Rh(n),u=o==='"'?"Quote":"Apostrophe",a=n.enter("definition");let c=n.enter("label");const f=n.createTracker(r);let h=f.move("[");return h+=f.move(n.safe(n.associationId(e),U({before:h,after:"]"},f.current()))),h+=f.move("]: "),c(),!e.url||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=f.move("<"),h+=f.move(n.safe(e.url,U({before:h,after:">"},f.current()))),h+=f.move(">")):(c=n.enter("destinationRaw"),h+=f.move(n.safe(e.url,U({before:h,after:e.title?" ":`
36
- `},f.current())))),c(),e.title&&(c=n.enter(`title${u}`),h+=f.move(" "+o),h+=f.move(n.safe(e.title,U({before:h,after:o},f.current()))),h+=f.move(o),c()),a(),h}function fD(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function Cu(e){return"&#x"+e.toString(16).toUpperCase()+";"}function Ll(e,t,n){const r=Ws(e),o=Ws(t);return r===void 0?o===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}zT.peek=dD;function zT(e,t,n,r){const o=fD(n),u=n.enter("emphasis"),a=n.createTracker(r),c=a.move(o);let f=a.move(n.containerPhrasing(e,U({after:o,before:c},a.current())));const h=f.charCodeAt(0),m=Ll(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(f=Cu(h)+f.slice(1));const E=f.charCodeAt(f.length-1),b=Ll(r.after.charCodeAt(0),E,o);b.inside&&(f=f.slice(0,-1)+Cu(E));const T=a.move(o);return u(),n.attentionEncodeSurroundingInfo={after:b.outside,before:m.outside},c+f+T}function dD(e,t,n){return n.options.emphasis||"*"}function hD(e,t){let n=!1;return xl(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,eh}),!!((!e.depth||e.depth<3)&&$d(e)&&(t.options.setext||n))}function pD(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),u=n.createTracker(r);if(hD(e,n)){const m=n.enter("headingSetext"),E=n.enter("phrasing"),b=n.containerPhrasing(e,ye(U({},u.current()),{before:`
35
+ `)),m+=c.move(f),h(),m}function x4(e,t,n){return(n?"":" ")+e}function Nh(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function S4(e,t,n,r){const o=Nh(n),u=o==='"'?"Quote":"Apostrophe",a=n.enter("definition");let c=n.enter("label");const f=n.createTracker(r);let h=f.move("[");return h+=f.move(n.safe(n.associationId(e),U({before:h,after:"]"},f.current()))),h+=f.move("]: "),c(),!e.url||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=f.move("<"),h+=f.move(n.safe(e.url,U({before:h,after:">"},f.current()))),h+=f.move(">")):(c=n.enter("destinationRaw"),h+=f.move(n.safe(e.url,U({before:h,after:e.title?" ":`
36
+ `},f.current())))),c(),e.title&&(c=n.enter(`title${u}`),h+=f.move(" "+o),h+=f.move(n.safe(e.title,U({before:h,after:o},f.current()))),h+=f.move(o),c()),a(),h}function w4(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function Su(e){return"&#x"+e.toString(16).toUpperCase()+";"}function Pl(e,t,n){const r=qs(e),o=qs(t);return r===void 0?o===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}VT.peek=C4;function VT(e,t,n,r){const o=w4(n),u=n.enter("emphasis"),a=n.createTracker(r),c=a.move(o);let f=a.move(n.containerPhrasing(e,U({after:o,before:c},a.current())));const h=f.charCodeAt(0),m=Pl(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(f=Su(h)+f.slice(1));const E=f.charCodeAt(f.length-1),b=Pl(r.after.charCodeAt(0),E,o);b.inside&&(f=f.slice(0,-1)+Su(E));const T=a.move(o);return u(),n.attentionEncodeSurroundingInfo={after:b.outside,before:m.outside},c+f+T}function C4(e,t,n){return n.options.emphasis||"*"}function A4(e,t){let n=!1;return bl(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Qd}),!!((!e.depth||e.depth<3)&&Ud(e)&&(t.options.setext||n))}function v4(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),u=n.createTracker(r);if(A4(e,n)){const m=n.enter("headingSetext"),E=n.enter("phrasing"),b=n.containerPhrasing(e,ye(U({},u.current()),{before:`
37
37
  `,after:`
38
38
  `}));return E(),m(),b+`
39
39
  `+(o===1?"=":"-").repeat(b.length-(Math.max(b.lastIndexOf("\r"),b.lastIndexOf(`
40
40
  `))+1))}const a="#".repeat(o),c=n.enter("headingAtx"),f=n.enter("phrasing");u.move(a+" ");let h=n.containerPhrasing(e,U({before:"# ",after:`
41
- `},u.current()));return/^[\t ]/.test(h)&&(h=Cu(h.charCodeAt(0))+h.slice(1)),h=h?a+" "+h:a,n.options.closeAtx&&(h+=" "+a),f(),c(),h}jT.peek=mD;function jT(e){return e.value||""}function mD(){return"<"}$T.peek=gD;function $T(e,t,n,r){const o=Rh(n),u=o==='"'?"Quote":"Apostrophe",a=n.enter("image");let c=n.enter("label");const f=n.createTracker(r);let h=f.move("![");return h+=f.move(n.safe(e.alt,U({before:h,after:"]"},f.current()))),h+=f.move("]("),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=f.move("<"),h+=f.move(n.safe(e.url,U({before:h,after:">"},f.current()))),h+=f.move(">")):(c=n.enter("destinationRaw"),h+=f.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},f.current())))),c(),e.title&&(c=n.enter(`title${u}`),h+=f.move(" "+o),h+=f.move(n.safe(e.title,U({before:h,after:o},f.current()))),h+=f.move(o),c()),h+=f.move(")"),a(),h}function gD(){return"!"}VT.peek=ED;function VT(e,t,n,r){const o=e.referenceType,u=n.enter("imageReference");let a=n.enter("label");const c=n.createTracker(r);let f=c.move("![");const h=n.safe(e.alt,U({before:f,after:"]"},c.current()));f+=c.move(h+"]["),a();const m=n.stack;n.stack=[],a=n.enter("reference");const E=n.safe(n.associationId(e),U({before:f,after:"]"},c.current()));return a(),n.stack=m,u(),o==="full"||!h||h!==E?f+=c.move(E+"]"):o==="shortcut"?f=f.slice(0,-1):f+=c.move("]"),f}function ED(){return"!"}qT.peek=yD;function qT(e,t,n){let r=e.value||"",o="`",u=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(r);)o+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++u<n.unsafe.length;){const a=n.unsafe[u],c=n.compilePattern(a);let f;if(a.atBreak)for(;f=c.exec(r);){let h=f.index;r.charCodeAt(h)===10&&r.charCodeAt(h-1)===13&&h--,r=r.slice(0,h)+" "+r.slice(f.index+1)}}return o+r+o}function yD(){return"`"}function YT(e,t){const n=$d(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}WT.peek=TD;function WT(e,t,n,r){const o=Rh(n),u=o==='"'?"Quote":"Apostrophe",a=n.createTracker(r);let c,f;if(YT(e,n)){const m=n.stack;n.stack=[],c=n.enter("autolink");let E=a.move("<");return E+=a.move(n.containerPhrasing(e,U({before:E,after:">"},a.current()))),E+=a.move(">"),c(),n.stack=m,E}c=n.enter("link"),f=n.enter("label");let h=a.move("[");return h+=a.move(n.containerPhrasing(e,U({before:h,after:"]("},a.current()))),h+=a.move("]("),f(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(f=n.enter("destinationLiteral"),h+=a.move("<"),h+=a.move(n.safe(e.url,U({before:h,after:">"},a.current()))),h+=a.move(">")):(f=n.enter("destinationRaw"),h+=a.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},a.current())))),f(),e.title&&(f=n.enter(`title${u}`),h+=a.move(" "+o),h+=a.move(n.safe(e.title,U({before:h,after:o},a.current()))),h+=a.move(o),f()),h+=a.move(")"),c(),h}function TD(e,t,n){return YT(e,n)?"<":"["}GT.peek=bD;function GT(e,t,n,r){const o=e.referenceType,u=n.enter("linkReference");let a=n.enter("label");const c=n.createTracker(r);let f=c.move("[");const h=n.containerPhrasing(e,U({before:f,after:"]"},c.current()));f+=c.move(h+"]["),a();const m=n.stack;n.stack=[],a=n.enter("reference");const E=n.safe(n.associationId(e),U({before:f,after:"]"},c.current()));return a(),n.stack=m,u(),o==="full"||!h||h!==E?f+=c.move(E+"]"):o==="shortcut"?f=f.slice(0,-1):f+=c.move("]"),f}function bD(){return"["}function Lh(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function _D(e){const t=Lh(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function xD(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function KT(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function SD(e,t,n,r){const o=n.enter("list"),u=n.bulletCurrent;let a=e.ordered?xD(n):Lh(n);const c=e.ordered?a==="."?")":".":_D(n);let f=t&&n.bulletLastUsed?a===n.bulletLastUsed:!1;if(!e.ordered){const m=e.children?e.children[0]:void 0;if((a==="*"||a==="-")&&m&&(!m.children||!m.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(f=!0),KT(n)===a&&m){let E=-1;for(;++E<e.children.length;){const b=e.children[E];if(b&&b.type==="listItem"&&b.children&&b.children[0]&&b.children[0].type==="thematicBreak"){f=!0;break}}}}f&&(a=c),n.bulletCurrent=a;const h=n.containerFlow(e,r);return n.bulletLastUsed=a,n.bulletCurrent=u,o(),h}function wD(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function CD(e,t,n,r){const o=wD(n);let u=n.bulletCurrent||Lh(n);t&&t.type==="list"&&t.ordered&&(u=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+u);let a=u.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(a=Math.ceil(a/4)*4);const c=n.createTracker(r);c.move(u+" ".repeat(a-u.length)),c.shift(a);const f=n.enter("listItem"),h=n.indentLines(n.containerFlow(e,c.current()),m);return f(),h;function m(E,b,T){return b?(T?"":" ".repeat(a))+E:(T?u:u+" ".repeat(a-u.length))+E}}function AD(e,t,n,r){const o=n.enter("paragraph"),u=n.enter("phrasing"),a=n.containerPhrasing(e,r);return u(),o(),a}const vD=bl(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function kD(e,t,n,r){return(e.children.some(function(a){return vD(a)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function ND(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}QT.peek=OD;function QT(e,t,n,r){const o=ND(n),u=n.enter("strong"),a=n.createTracker(r),c=a.move(o+o);let f=a.move(n.containerPhrasing(e,U({after:o,before:c},a.current())));const h=f.charCodeAt(0),m=Ll(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(f=Cu(h)+f.slice(1));const E=f.charCodeAt(f.length-1),b=Ll(r.after.charCodeAt(0),E,o);b.inside&&(f=f.slice(0,-1)+Cu(E));const T=a.move(o+o);return u(),n.attentionEncodeSurroundingInfo={after:b.outside,before:m.outside},c+f+T}function OD(e,t,n){return n.options.strong||"*"}function ID(e,t,n,r){return n.safe(e.value,r)}function PD(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function RD(e,t,n){const r=(KT(n)+(n.options.ruleSpaces?" ":"")).repeat(PD(n));return n.options.ruleSpaces?r.slice(0,-1):r}const XT={blockquote:nD,break:HT,code:aD,definition:cD,emphasis:zT,hardBreak:HT,heading:pD,html:jT,image:$T,imageReference:VT,inlineCode:qT,link:WT,linkReference:GT,list:SD,listItem:CD,paragraph:AD,root:kD,strong:QT,text:ID,thematicBreak:RD};function LD(){return{enter:{table:DD,tableData:JT,tableHeader:JT,tableRow:MD},exit:{codeText:BD,table:FD,tableData:Dh,tableHeader:Dh,tableRow:Dh}}}function DD(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function FD(e){this.exit(e),this.data.inTable=void 0}function MD(e){this.enter({type:"tableRow",children:[]},e)}function Dh(e){this.exit(e)}function JT(e){this.enter({type:"tableCell",children:[]},e)}function BD(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,UD));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function UD(e,t){return t==="|"?t:e}function HD(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,u=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
41
+ `},u.current()));return/^[\t ]/.test(h)&&(h=Su(h.charCodeAt(0))+h.slice(1)),h=h?a+" "+h:a,n.options.closeAtx&&(h+=" "+a),f(),c(),h}qT.peek=k4;function qT(e){return e.value||""}function k4(){return"<"}YT.peek=N4;function YT(e,t,n,r){const o=Nh(n),u=o==='"'?"Quote":"Apostrophe",a=n.enter("image");let c=n.enter("label");const f=n.createTracker(r);let h=f.move("![");return h+=f.move(n.safe(e.alt,U({before:h,after:"]"},f.current()))),h+=f.move("]("),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=f.move("<"),h+=f.move(n.safe(e.url,U({before:h,after:">"},f.current()))),h+=f.move(">")):(c=n.enter("destinationRaw"),h+=f.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},f.current())))),c(),e.title&&(c=n.enter(`title${u}`),h+=f.move(" "+o),h+=f.move(n.safe(e.title,U({before:h,after:o},f.current()))),h+=f.move(o),c()),h+=f.move(")"),a(),h}function N4(){return"!"}WT.peek=O4;function WT(e,t,n,r){const o=e.referenceType,u=n.enter("imageReference");let a=n.enter("label");const c=n.createTracker(r);let f=c.move("![");const h=n.safe(e.alt,U({before:f,after:"]"},c.current()));f+=c.move(h+"]["),a();const m=n.stack;n.stack=[],a=n.enter("reference");const E=n.safe(n.associationId(e),U({before:f,after:"]"},c.current()));return a(),n.stack=m,u(),o==="full"||!h||h!==E?f+=c.move(E+"]"):o==="shortcut"?f=f.slice(0,-1):f+=c.move("]"),f}function O4(){return"!"}GT.peek=I4;function GT(e,t,n){let r=e.value||"",o="`",u=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(r);)o+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++u<n.unsafe.length;){const a=n.unsafe[u],c=n.compilePattern(a);let f;if(a.atBreak)for(;f=c.exec(r);){let h=f.index;r.charCodeAt(h)===10&&r.charCodeAt(h-1)===13&&h--,r=r.slice(0,h)+" "+r.slice(f.index+1)}}return o+r+o}function I4(){return"`"}function KT(e,t){const n=Ud(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}QT.peek=P4;function QT(e,t,n,r){const o=Nh(n),u=o==='"'?"Quote":"Apostrophe",a=n.createTracker(r);let c,f;if(KT(e,n)){const m=n.stack;n.stack=[],c=n.enter("autolink");let E=a.move("<");return E+=a.move(n.containerPhrasing(e,U({before:E,after:">"},a.current()))),E+=a.move(">"),c(),n.stack=m,E}c=n.enter("link"),f=n.enter("label");let h=a.move("[");return h+=a.move(n.containerPhrasing(e,U({before:h,after:"]("},a.current()))),h+=a.move("]("),f(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(f=n.enter("destinationLiteral"),h+=a.move("<"),h+=a.move(n.safe(e.url,U({before:h,after:">"},a.current()))),h+=a.move(">")):(f=n.enter("destinationRaw"),h+=a.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},a.current())))),f(),e.title&&(f=n.enter(`title${u}`),h+=a.move(" "+o),h+=a.move(n.safe(e.title,U({before:h,after:o},a.current()))),h+=a.move(o),f()),h+=a.move(")"),c(),h}function P4(e,t,n){return KT(e,n)?"<":"["}XT.peek=R4;function XT(e,t,n,r){const o=e.referenceType,u=n.enter("linkReference");let a=n.enter("label");const c=n.createTracker(r);let f=c.move("[");const h=n.containerPhrasing(e,U({before:f,after:"]"},c.current()));f+=c.move(h+"]["),a();const m=n.stack;n.stack=[],a=n.enter("reference");const E=n.safe(n.associationId(e),U({before:f,after:"]"},c.current()));return a(),n.stack=m,u(),o==="full"||!h||h!==E?f+=c.move(E+"]"):o==="shortcut"?f=f.slice(0,-1):f+=c.move("]"),f}function R4(){return"["}function Oh(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function L4(e){const t=Oh(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function D4(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function JT(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function F4(e,t,n,r){const o=n.enter("list"),u=n.bulletCurrent;let a=e.ordered?D4(n):Oh(n);const c=e.ordered?a==="."?")":".":L4(n);let f=t&&n.bulletLastUsed?a===n.bulletLastUsed:!1;if(!e.ordered){const m=e.children?e.children[0]:void 0;if((a==="*"||a==="-")&&m&&(!m.children||!m.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(f=!0),JT(n)===a&&m){let E=-1;for(;++E<e.children.length;){const b=e.children[E];if(b&&b.type==="listItem"&&b.children&&b.children[0]&&b.children[0].type==="thematicBreak"){f=!0;break}}}}f&&(a=c),n.bulletCurrent=a;const h=n.containerFlow(e,r);return n.bulletLastUsed=a,n.bulletCurrent=u,o(),h}function M4(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function B4(e,t,n,r){const o=M4(n);let u=n.bulletCurrent||Oh(n);t&&t.type==="list"&&t.ordered&&(u=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+u);let a=u.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(a=Math.ceil(a/4)*4);const c=n.createTracker(r);c.move(u+" ".repeat(a-u.length)),c.shift(a);const f=n.enter("listItem"),h=n.indentLines(n.containerFlow(e,c.current()),m);return f(),h;function m(E,b,T){return b?(T?"":" ".repeat(a))+E:(T?u:u+" ".repeat(a-u.length))+E}}function U4(e,t,n,r){const o=n.enter("paragraph"),u=n.enter("phrasing"),a=n.containerPhrasing(e,r);return u(),o(),a}const H4=yl(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function z4(e,t,n,r){return(e.children.some(function(a){return H4(a)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function j4(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}ZT.peek=$4;function ZT(e,t,n,r){const o=j4(n),u=n.enter("strong"),a=n.createTracker(r),c=a.move(o+o);let f=a.move(n.containerPhrasing(e,U({after:o,before:c},a.current())));const h=f.charCodeAt(0),m=Pl(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(f=Su(h)+f.slice(1));const E=f.charCodeAt(f.length-1),b=Pl(r.after.charCodeAt(0),E,o);b.inside&&(f=f.slice(0,-1)+Su(E));const T=a.move(o+o);return u(),n.attentionEncodeSurroundingInfo={after:b.outside,before:m.outside},c+f+T}function $4(e,t,n){return n.options.strong||"*"}function V4(e,t,n,r){return n.safe(e.value,r)}function q4(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function Y4(e,t,n){const r=(JT(n)+(n.options.ruleSpaces?" ":"")).repeat(q4(n));return n.options.ruleSpaces?r.slice(0,-1):r}const eb={blockquote:m4,break:$T,code:_4,definition:S4,emphasis:VT,hardBreak:$T,heading:v4,html:qT,image:YT,imageReference:WT,inlineCode:GT,link:QT,linkReference:XT,list:F4,listItem:B4,paragraph:U4,root:z4,strong:ZT,text:V4,thematicBreak:Y4};function W4(){return{enter:{table:G4,tableData:tb,tableHeader:tb,tableRow:Q4},exit:{codeText:X4,table:K4,tableData:Ih,tableHeader:Ih,tableRow:Ih}}}function G4(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function K4(e){this.exit(e),this.data.inTable=void 0}function Q4(e){this.enter({type:"tableRow",children:[]},e)}function Ih(e){this.exit(e)}function tb(e){this.enter({type:"tableCell",children:[]},e)}function X4(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,J4));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function J4(e,t){return t==="|"?t:e}function Z4(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,u=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
42
42
  `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:b,table:a,tableCell:f,tableRow:c}};function a(T,_,S,C){return h(m(T,S,C),T.align)}function c(T,_,S,C){const k=E(T,S,C),M=h([k]);return M.slice(0,M.indexOf(`
43
- `))}function f(T,_,S,C){const k=S.enter("tableCell"),M=S.enter("phrasing"),D=S.containerPhrasing(T,ye(U({},C),{before:u,after:u}));return M(),k(),D}function h(T,_){return eD(T,{align:_,alignDelimiters:r,padding:n,stringLength:o})}function m(T,_,S){const C=T.children;let k=-1;const M=[],D=_.enter("table");for(;++k<C.length;)M[k]=E(C[k],_,S);return D(),M}function E(T,_,S){const C=T.children;let k=-1;const M=[],D=_.enter("tableRow");for(;++k<C.length;)M[k]=f(C[k],T,_,S);return D(),M}function b(T,_,S){let C=XT.inlineCode(T,_,S);return S.stack.includes("tableCell")&&(C=C.replace(/\|/g,"\\$&")),C}}function zD(){return{exit:{taskListCheckValueChecked:ZT,taskListCheckValueUnchecked:ZT,paragraph:$D}}}function jD(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:VD}}}function ZT(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function $D(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1];n.type;const r=n.children[0];if(r&&r.type==="text"){const o=t.children;let u=-1,a;for(;++u<o.length;){const c=o[u];if(c.type==="paragraph"){a=c;break}}a===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(e)}function VD(e,t,n,r){const o=e.children[0],u=typeof e.checked=="boolean"&&o&&o.type==="paragraph",a="["+(e.checked?"x":" ")+"] ",c=n.createTracker(r);u&&c.move(a);let f=XT.listItem(e,t,n,U(U({},r),c.current()));return u&&(f=f.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),f;function h(m){return m+a}}function qD(){return[S4(),V4(),G4(),LD(),zD()]}function YD(e){return{extensions:[w4(),q4(e),K4(),HD(e),jD()]}}const WD={tokenize:ZD,partial:!0},eb={tokenize:e5,partial:!0},tb={tokenize:t5,partial:!0},nb={tokenize:n5,partial:!0},GD={tokenize:r5,partial:!0},rb={name:"wwwAutolink",tokenize:XD,previous:sb},ib={name:"protocolAutolink",tokenize:JD,previous:ob},Xr={name:"emailAutolink",tokenize:QD,previous:ub},Pr={};function KD(){return{text:Pr}}let Zi=48;for(;Zi<123;)Pr[Zi]=Xr,Zi++,Zi===58?Zi=65:Zi===91&&(Zi=97);Pr[43]=Xr,Pr[45]=Xr,Pr[46]=Xr,Pr[95]=Xr,Pr[72]=[Xr,ib],Pr[104]=[Xr,ib],Pr[87]=[Xr,rb],Pr[119]=[Xr,rb];function QD(e,t,n){const r=this;let o,u;return a;function a(E){return!Fh(E)||!ub.call(r,r.previous)||Mh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return Fh(E)?(e.consume(E),c):E===64?(e.consume(E),f):n(E)}function f(E){return E===46?e.check(GD,m,h)(E):E===45||E===95||sn(E)?(u=!0,e.consume(E),f):m(E)}function h(E){return e.consume(E),o=!0,f}function m(E){return u&&o&&pn(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(E)):n(E)}}function XD(e,t,n){const r=this;return o;function o(a){return a!==87&&a!==119||!sb.call(r,r.previous)||Mh(r.events)?n(a):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(WD,e.attempt(eb,e.attempt(tb,u),n),n)(a))}function u(a){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(a)}}function JD(e,t,n){const r=this;let o="",u=!1;return a;function a(E){return(E===72||E===104)&&ob.call(r,r.previous)&&!Mh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(pn(E)&&o.length<5)return o+=String.fromCodePoint(E),e.consume(E),c;if(E===58){const b=o.toLowerCase();if(b==="http"||b==="https")return e.consume(E),f}return n(E)}function f(E){return E===47?(e.consume(E),u?h:(u=!0,f)):n(E)}function h(E){return E===null||dl(E)||ut(E)||Gi(E)||hl(E)?n(E):e.attempt(eb,e.attempt(tb,m),n)(E)}function m(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function ZD(e,t,n){let r=0;return o;function o(a){return(a===87||a===119)&&r<3?(r++,e.consume(a),o):a===46&&r===3?(e.consume(a),u):n(a)}function u(a){return a===null?n(a):t(a)}}function e5(e,t,n){let r,o,u;return a;function a(h){return h===46||h===95?e.check(nb,f,c)(h):h===null||ut(h)||Gi(h)||h!==45&&hl(h)?f(h):(u=!0,e.consume(h),a)}function c(h){return h===95?r=!0:(o=r,r=void 0),e.consume(h),a}function f(h){return o||r||!u?n(h):t(h)}}function t5(e,t){let n=0,r=0;return o;function o(a){return a===40?(n++,e.consume(a),o):a===41&&r<n?u(a):a===33||a===34||a===38||a===39||a===41||a===42||a===44||a===46||a===58||a===59||a===60||a===63||a===93||a===95||a===126?e.check(nb,t,u)(a):a===null||ut(a)||Gi(a)?t(a):(e.consume(a),o)}function u(a){return a===41&&r++,e.consume(a),o}}function n5(e,t,n){return r;function r(c){return c===33||c===34||c===39||c===41||c===42||c===44||c===46||c===58||c===59||c===63||c===95||c===126?(e.consume(c),r):c===38?(e.consume(c),u):c===93?(e.consume(c),o):c===60||c===null||ut(c)||Gi(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||ut(c)||Gi(c)?t(c):r(c)}function u(c){return pn(c)?a(c):n(c)}function a(c){return c===59?(e.consume(c),r):pn(c)?(e.consume(c),a):n(c)}}function r5(e,t,n){return r;function r(u){return e.consume(u),o}function o(u){return sn(u)?n(u):t(u)}}function sb(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||ut(e)}function ob(e){return!pn(e)}function ub(e){return!(e===47||Fh(e))}function Fh(e){return e===43||e===45||e===46||e===95||sn(e)}function Mh(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const i5={tokenize:d5,partial:!0};function s5(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:l5,continuation:{tokenize:c5},exit:f5}},text:{91:{name:"gfmFootnoteCall",tokenize:a5},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:o5,resolveTo:u5}}}}function o5(e,t,n){const r=this;let o=r.events.length;const u=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a;for(;o--;){const f=r.events[o][1];if(f.type==="labelImage"){a=f;break}if(f.type==="gfmFootnoteCall"||f.type==="labelLink"||f.type==="label"||f.type==="image"||f.type==="link")break}return c;function c(f){if(!a||!a._balanced)return n(f);const h=fr(r.sliceSerialize({start:a.end,end:r.now()}));return h.codePointAt(0)!==94||!u.includes(h.slice(1))?n(f):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(f),e.exit("gfmFootnoteCallLabelMarker"),t(f))}}function u5(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const u={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},a={type:"chunkString",contentType:"string",start:Object.assign({},u.start),end:Object.assign({},u.end)},c=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",u,t],["enter",a,t],["exit",a,t],["exit",u,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...c),e}function a5(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u=0,a;return c;function c(E){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(E),e.exit("gfmFootnoteCallLabelMarker"),f}function f(E){return E!==94?n(E):(e.enter("gfmFootnoteCallMarker"),e.consume(E),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",h)}function h(E){if(u>999||E===93&&!a||E===null||E===91||ut(E))return n(E);if(E===93){e.exit("chunkString");const b=e.exit("gfmFootnoteCallString");return o.includes(fr(r.sliceSerialize(b)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(E),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(E)}return ut(E)||(a=!0),u++,e.consume(E),E===92?m:h}function m(E){return E===91||E===92||E===93?(e.consume(E),u++,h):h(E)}}function l5(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u,a=0,c;return f;function f(_){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionLabelMarker"),h}function h(_){return _===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",m):n(_)}function m(_){if(a>999||_===93&&!c||_===null||_===91||ut(_))return n(_);if(_===93){e.exit("chunkString");const S=e.exit("gfmFootnoteDefinitionLabelString");return u=fr(r.sliceSerialize(S)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),b}return ut(_)||(c=!0),a++,e.consume(_),_===92?E:m}function E(_){return _===91||_===92||_===93?(e.consume(_),a++,m):m(_)}function b(_){return _===58?(e.enter("definitionMarker"),e.consume(_),e.exit("definitionMarker"),o.includes(u)||o.push(u),Xe(e,T,"gfmFootnoteDefinitionWhitespace")):n(_)}function T(_){return t(_)}}function c5(e,t,n){return e.check(uu,t,e.attempt(i5,t,n))}function f5(e){e.exit("gfmFootnoteDefinition")}function d5(e,t,n){const r=this;return Xe(e,o,"gfmFootnoteDefinitionIndent",5);function o(u){const a=r.events[r.events.length-1];return a&&a[1].type==="gfmFootnoteDefinitionIndent"&&a[2].sliceSerialize(a[1],!0).length===4?t(u):n(u)}}function h5(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:u,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function o(a,c){let f=-1;for(;++f<a.length;)if(a[f][0]==="enter"&&a[f][1].type==="strikethroughSequenceTemporary"&&a[f][1]._close){let h=f;for(;h--;)if(a[h][0]==="exit"&&a[h][1].type==="strikethroughSequenceTemporary"&&a[h][1]._open&&a[f][1].end.offset-a[f][1].start.offset===a[h][1].end.offset-a[h][1].start.offset){a[f][1].type="strikethroughSequence",a[h][1].type="strikethroughSequence";const m={type:"strikethrough",start:Object.assign({},a[h][1].start),end:Object.assign({},a[f][1].end)},E={type:"strikethroughText",start:Object.assign({},a[h][1].end),end:Object.assign({},a[f][1].start)},b=[["enter",m,c],["enter",a[h][1],c],["exit",a[h][1],c],["enter",E,c]],T=c.parser.constructs.insideSpan.null;T&&Dn(b,b.length,0,pl(T,a.slice(h+1,f),c)),Dn(b,b.length,0,[["exit",E,c],["enter",a[f][1],c],["exit",a[f][1],c],["exit",m,c]]),Dn(a,h-1,f-h+3,b),f=h+b.length-2;break}}for(f=-1;++f<a.length;)a[f][1].type==="strikethroughSequenceTemporary"&&(a[f][1].type="data");return a}function u(a,c,f){const h=this.previous,m=this.events;let E=0;return b;function b(_){return h===126&&m[m.length-1][1].type!=="characterEscape"?f(_):(a.enter("strikethroughSequenceTemporary"),T(_))}function T(_){const S=Ws(h);if(_===126)return E>1?f(_):(a.consume(_),E++,T);if(E<2&&!n)return f(_);const C=a.exit("strikethroughSequenceTemporary"),k=Ws(_);return C._open=!k||k===2&&!!S,C._close=!S||S===2&&!!k,c(_)}}}class p5{constructor(){this.map=[]}add(t,n,r){m5(this,t,n,r)}consume(t){if(this.map.sort(function(u,a){return u[0]-a[0]}),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];r.push(t.slice()),t.length=0;let o=r.pop();for(;o;){for(const u of o)t.push(u);o=r.pop()}this.map.length=0}}function m5(e,t,n,r){let o=0;if(!(n===0&&r.length===0)){for(;o<e.map.length;){if(e.map[o][0]===t){e.map[o][1]+=n,e.map[o][2].push(...r);return}o+=1}e.map.push([t,n,r])}}function g5(e,t){let n=!1;const r=[];for(;t<e.length;){const o=e[t];if(n){if(o[0]==="enter")o[1].type==="tableContent"&&r.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(o[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const u=r.length-1;r[u]=r[u]==="left"?"center":"right"}}else if(o[1].type==="tableDelimiterRow")break}else o[0]==="enter"&&o[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return r}function E5(){return{flow:{null:{name:"table",tokenize:y5,resolveAll:T5}}}}function y5(e,t,n){const r=this;let o=0,u=0,a;return c;function c(H){let fe=r.events.length-1;for(;fe>-1;){const ie=r.events[fe][1].type;if(ie==="lineEnding"||ie==="linePrefix")fe--;else break}const de=fe>-1?r.events[fe][1].type:null,ue=de==="tableHead"||de==="tableRow"?B:f;return ue===B&&r.parser.lazy[r.now().line]?n(H):ue(H)}function f(H){return e.enter("tableHead"),e.enter("tableRow"),h(H)}function h(H){return H===124||(a=!0,u+=1),m(H)}function m(H){return H===null?n(H):Re(H)?u>1?(u=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(H),e.exit("lineEnding"),T):n(H):Ke(H)?Xe(e,m,"whitespace")(H):(u+=1,a&&(a=!1,o+=1),H===124?(e.enter("tableCellDivider"),e.consume(H),e.exit("tableCellDivider"),a=!0,m):(e.enter("data"),E(H)))}function E(H){return H===null||H===124||ut(H)?(e.exit("data"),m(H)):(e.consume(H),H===92?b:E)}function b(H){return H===92||H===124?(e.consume(H),E):E(H)}function T(H){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(H):(e.enter("tableDelimiterRow"),a=!1,Ke(H)?Xe(e,_,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(H):_(H))}function _(H){return H===45||H===58?C(H):H===124?(a=!0,e.enter("tableCellDivider"),e.consume(H),e.exit("tableCellDivider"),S):q(H)}function S(H){return Ke(H)?Xe(e,C,"whitespace")(H):C(H)}function C(H){return H===58?(u+=1,a=!0,e.enter("tableDelimiterMarker"),e.consume(H),e.exit("tableDelimiterMarker"),k):H===45?(u+=1,k(H)):H===null||Re(H)?G(H):q(H)}function k(H){return H===45?(e.enter("tableDelimiterFiller"),M(H)):q(H)}function M(H){return H===45?(e.consume(H),M):H===58?(a=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(H),e.exit("tableDelimiterMarker"),D):(e.exit("tableDelimiterFiller"),D(H))}function D(H){return Ke(H)?Xe(e,G,"whitespace")(H):G(H)}function G(H){return H===124?_(H):H===null||Re(H)?!a||o!==u?q(H):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(H)):q(H)}function q(H){return n(H)}function B(H){return e.enter("tableRow"),te(H)}function te(H){return H===124?(e.enter("tableCellDivider"),e.consume(H),e.exit("tableCellDivider"),te):H===null||Re(H)?(e.exit("tableRow"),t(H)):Ke(H)?Xe(e,te,"whitespace")(H):(e.enter("data"),Te(H))}function Te(H){return H===null||H===124||ut(H)?(e.exit("data"),te(H)):(e.consume(H),H===92?Se:Te)}function Se(H){return H===92||H===124?(e.consume(H),Te):Te(H)}}function T5(e,t){let n=-1,r=!0,o=0,u=[0,0,0,0],a=[0,0,0,0],c=!1,f=0,h,m,E;const b=new p5;for(;++n<e.length;){const T=e[n],_=T[1];T[0]==="enter"?_.type==="tableHead"?(c=!1,f!==0&&(ab(b,t,f,h,m),m=void 0,f=0),h={type:"table",start:Object.assign({},_.start),end:Object.assign({},_.end)},b.add(n,0,[["enter",h,t]])):_.type==="tableRow"||_.type==="tableDelimiterRow"?(r=!0,E=void 0,u=[0,0,0,0],a=[0,n+1,0,0],c&&(c=!1,m={type:"tableBody",start:Object.assign({},_.start),end:Object.assign({},_.end)},b.add(n,0,[["enter",m,t]])),o=_.type==="tableDelimiterRow"?2:m?3:1):o&&(_.type==="data"||_.type==="tableDelimiterMarker"||_.type==="tableDelimiterFiller")?(r=!1,a[2]===0&&(u[1]!==0&&(a[0]=a[1],E=Dl(b,t,u,o,void 0,E),u=[0,0,0,0]),a[2]=n)):_.type==="tableCellDivider"&&(r?r=!1:(u[1]!==0&&(a[0]=a[1],E=Dl(b,t,u,o,void 0,E)),u=a,a=[u[1],n,0,0])):_.type==="tableHead"?(c=!0,f=n):_.type==="tableRow"||_.type==="tableDelimiterRow"?(f=n,u[1]!==0?(a[0]=a[1],E=Dl(b,t,u,o,n,E)):a[1]!==0&&(E=Dl(b,t,a,o,n,E)),o=0):o&&(_.type==="data"||_.type==="tableDelimiterMarker"||_.type==="tableDelimiterFiller")&&(a[3]=n)}for(f!==0&&ab(b,t,f,h,m),b.consume(t.events),n=-1;++n<t.events.length;){const T=t.events[n];T[0]==="enter"&&T[1].type==="table"&&(T[1]._align=g5(t.events,n))}return e}function Dl(e,t,n,r,o,u){const a=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(u.end=Object.assign({},ro(t.events,n[0])),e.add(n[0],0,[["exit",u,t]]));const f=ro(t.events,n[1]);if(u={type:a,start:Object.assign({},f),end:Object.assign({},f)},e.add(n[1],0,[["enter",u,t]]),n[2]!==0){const h=ro(t.events,n[2]),m=ro(t.events,n[3]),E={type:c,start:Object.assign({},h),end:Object.assign({},m)};if(e.add(n[2],0,[["enter",E,t]]),r!==2){const b=t.events[n[2]],T=t.events[n[3]];if(b[1].end=Object.assign({},T[1].end),b[1].type="chunkText",b[1].contentType="text",n[3]>n[2]+1){const _=n[2]+1,S=n[3]-n[2]-1;e.add(_,S,[])}}e.add(n[3]+1,0,[["exit",E,t]])}return o!==void 0&&(u.end=Object.assign({},ro(t.events,o)),e.add(o,0,[["exit",u,t]]),u=void 0),u}function ab(e,t,n,r,o){const u=[],a=ro(t.events,n);o&&(o.end=Object.assign({},a),u.push(["exit",o,t])),r.end=Object.assign({},a),u.push(["exit",r,t]),e.add(n+1,0,u)}function ro(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const b5={name:"tasklistCheck",tokenize:x5};function _5(){return{text:{91:b5}}}function x5(e,t,n){const r=this;return o;function o(f){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(f):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(f),e.exit("taskListCheckMarker"),u)}function u(f){return ut(f)?(e.enter("taskListCheckValueUnchecked"),e.consume(f),e.exit("taskListCheckValueUnchecked"),a):f===88||f===120?(e.enter("taskListCheckValueChecked"),e.consume(f),e.exit("taskListCheckValueChecked"),a):n(f)}function a(f){return f===93?(e.enter("taskListCheckMarker"),e.consume(f),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),c):n(f)}function c(f){return Re(f)?t(f):Ke(f)?e.check({tokenize:S5},t,n)(f):n(f)}}function S5(e,t,n){return Xe(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function w5(e){return PE([KD(),s5(),h5(e),E5(),_5()])}const C5={};function A5(e){const t=this,n=e||C5,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),u=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),a=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push(w5(n)),u.push(qD()),a.push(YD(n))}const Fl=()=>I.jsx("span",{className:`${Z}-blinking-cursor`,children:I.jsx("svg",{height:"1rem",width:"1rem",xmlns:"http://www.w3.org/2000/svg",children:I.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),lb=({globalClassName:e,message:t})=>{const{isLoading:n,isResponseLoading:r}=li(),o=n&&r((t==null?void 0:t.eventSourceId)||"")&&t.name==="partial_inquiry";return I.jsx(qP,{remarkPlugins:[A5],rehypePlugins:[E4],components:{h1:({children:u})=>I.jsx("h1",{className:oe(e,`${Z}-header h1`),children:u}),h2:({children:u})=>I.jsx("h2",{className:oe(e,`${Z}-header h2`),children:u}),h3:({children:u})=>I.jsx("h3",{className:oe(e,`${Z}-header h3`),children:u}),ul:({children:u})=>I.jsx("ul",{className:oe(e,`${Z}-ul`),children:u}),ol:({children:u})=>I.jsx("ol",{className:oe(e,`${Z}-ol`),children:u}),li:({children:u})=>I.jsx("li",{className:oe(e,`${Z}-li`),children:u}),a:({href:u,children:a})=>I.jsx("a",ye(U({className:oe(e,`${Z}-link`)},u?{href:u,target:"_blank"}:{}),{rel:"noopener noreferrer",children:a})),table:({children:u})=>I.jsx("table",{className:oe(e,`${Z}-table`),children:u}),thead:({children:u})=>I.jsx("thead",{className:oe(e,`${Z}-thead`),children:u}),tbody:({children:u})=>I.jsx("tbody",{className:oe(e,`${Z}-tbody`),children:u}),tr:({children:u})=>I.jsx("tr",{className:oe(e,`${Z}-tr`),children:u}),th:({children:u})=>I.jsx("th",{className:oe(e,`${Z}-th`),children:u}),td:({children:u})=>I.jsx("td",{className:oe(e,`${Z}-td`),children:u}),span:({className:u,children:a})=>u===`${Z}-blinking-cursor`?I.jsx(Fl,{}):I.jsx("span",{children:a})},children:t.message+(o?`<span className='${Z}-blinking-cursor'></span>`:"")})},v5=({globalClassName:e,message:t})=>{const[n,r]=W.useState(!1),o=t.tool_name||t.toolName,u=!!t.thought,a=!!o,c=()=>{r(f=>!f)};return I.jsxs("div",{children:[I.jsxs("div",{className:oe(e,`${Z}-progress-message`,"standalone"),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon`,"progress-icon","standalone"),children:I.jsx(Pg,{})}),I.jsx("p",{className:oe(e,`${Z}-progress-text`,"standalone"),children:t.message})]}),(u||a)&&I.jsxs(I.Fragment,{children:[I.jsx(Yf,{className:oe(e,`${Z}-thought-context-button`),onClick:c,children:n?I.jsxs(I.Fragment,{children:["Hide ",I.jsx(oA,{})]}):I.jsxs(I.Fragment,{children:["Context ",I.jsx(uA,{})]})}),n&&I.jsx("div",{className:oe(e,`${Z}-thought-container`),children:u&&I.jsx("p",{className:oe(e,`${Z}-progress-thought`),children:t.thought})})]})]})},k5=({globalClassName:e,message:t,isWidgetStandalone:n})=>n?I.jsx(v5,{globalClassName:e,message:t}):I.jsxs("div",{className:oe(e,`${Z}-progress-message`,"embedded"),title:t.message,children:[I.jsx("span",{className:oe(e,`${Z}-message-icon`,"progress-icon","embedded"),children:I.jsx(Pg,{})}),I.jsx("i",{className:oe(e,`${Z}-progress-text`,"embedded"),children:t.message})]}),N5=({globalClassName:e,message:t,isWidgetStandalone:n})=>{var o,u;const r=((o=t.searchParams)==null?void 0:o.query)||((u=t.browseParams)==null?void 0:u.categoryId);return I.jsxs("div",{className:oe(e,`${Z}-refined-event`,{embedded:!n,standalone:n}),children:[I.jsxs("div",{className:oe(e,`${Z}-refined-event-query`,{embedded:!n,standalone:n}),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon`,`${Z}-refined-event-icon`,{embedded:!n,standalone:n}),children:I.jsx(za,{})}),I.jsx("p",{className:oe(e,`${Z}-text`,"bold"),children:r})]}),I.jsx(lb,{message:t})]})},cb=e=>{var f,h;const{configModule:t}=sr(),n=((f=e.request)==null?void 0:f.searchParams)||((h=e.request)==null?void 0:h.browseParams),r=(t==null?void 0:t.getProductHiddenFields())||[],{facetFilters:o={}}=n||{facetFilters:{}},u=Object.fromEntries(Object.entries(o).filter(([m])=>!r.includes(m))),a=Object.keys(u),c=Object.values(u).reduce((m,E)=>m+E.length,0);return{facetFiltersList:a,filterCount:c}},Ml=({isWidgetStandalone:e,globalClassName:t,filterCount:n})=>I.jsx("span",{className:oe(t,`${Z}-facet-pill`,{standalone:e,embedded:!e}),children:`${n} filters`}),fb=({globalClassName:e,message:t,facetFiltersList:n})=>{var u,a;if(!n.length)return null;const r=((u=t.request)==null?void 0:u.searchParams)||((a=t.request)==null?void 0:a.browseParams),o=(r==null?void 0:r.facetFilters)||{};return n.map(c=>{var h;const f=((h=o[c])==null?void 0:h.join(", "))||"";return I.jsxs("div",{className:oe(e,`${Z}-facets`),children:[I.jsx("p",{className:oe(e,`${Z}-facet-category`),children:c}),I.jsx("p",{className:oe(e,`${Z}-facet-values`),children:f})]},c)})},O5=({globalClassName:e,message:t,isWidgetStandalone:n})=>{var u,a;const{facetFiltersList:r,filterCount:o}=cb(t);return n?I.jsxs("div",{children:[I.jsxs("div",{className:oe(e,`${Z}-user-message standalone`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-message-icon standalone`),children:I.jsx(Rg,{})}),I.jsx("p",{className:oe(e,`${Z}-user-message-text`),children:(u=t.request)==null?void 0:u.userPrompt}),r.length>0&&I.jsx(Ml,{isWidgetStandalone:!0,globalClassName:e,filterCount:o})]}),I.jsx(fb,{globalClassName:e,facetFiltersList:r,message:t})]}):I.jsxs("div",{className:oe(e,`${Z}-user-message embedded`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-message-icon embedded`),children:I.jsx(Rg,{})}),I.jsx("p",{children:(a=t.request)==null?void 0:a.userPrompt}),r.length>0&&I.jsx(Ml,{isWidgetStandalone:!1,filterCount:o})]})},I5=({globalClassName:e,actionLabel:t,query:n,message:r,facetFiltersList:o,filterCount:u})=>I.jsxs("div",{className:oe(e,`${Z}-user-search standalone`),children:[I.jsxs("div",{className:oe(e,`${Z}-user-search-query`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-search-icon standalone`),children:I.jsx(za,{})}),I.jsx("p",{className:oe(e,`${Z}-text bold`),children:`${t}: ${n}`}),o.length>0&&I.jsx(Ml,{isWidgetStandalone:!0,globalClassName:e,filterCount:u})]}),I.jsx(fb,{globalClassName:e,facetFiltersList:o,message:r})]}),P5=({globalClassName:e,message:t,isWidgetStandalone:n})=>{const{facetFiltersList:r,filterCount:o}=cb(t),{actionLabel:u,query:a}=W.useMemo(()=>{var f,h,m,E;switch(t.name){case"copilot_search":return{actionLabel:"Your search",query:(f=t.request)==null?void 0:f.searchParams.query};case"copilot_browse":return{actionLabel:"Browsing category",query:(m=(h=t.request)==null?void 0:h.browseParams)==null?void 0:m.categoryId};case"product_view":return{actionLabel:"Viewing product",query:(E=t.request)==null?void 0:E.productId};default:return{actionLabel:"",query:""}}},[t]);return!t.isUserAction||!a?null:n?I.jsx(I5,{globalClassName:e,message:t,actionLabel:u,query:a,facetFiltersList:r,filterCount:o}):I.jsxs("div",{className:oe(e,`${Z}-user-search embedded`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-search-icon embedded`),children:I.jsx(za,{})}),I.jsx("p",{children:a}),r.length>0&&I.jsx(Ml,{isWidgetStandalone:!1,filterCount:o})]})},db=["copilot_search","copilot_browse","product_view"],hb=({message:e,globalClassName:t,resetConversationMessage:n,isWidgetStandalone:r,handleSuggestionClick:o})=>{var a;if(!e)return null;let u=e.name;if(db.includes(u)&&(e.isInitial||e.isUserAction)&&(u="faceted_navigation"),db.includes(u)&&!((a=e.request)!=null&&a.userPrompt))return null;switch(u){case"copilot_search":case"copilot_browse":case"product_view":return I.jsx(O5,{globalClassName:t,isWidgetStandalone:r,message:e});case"faceted_navigation":return I.jsx(P5,{globalClassName:t,message:e,isWidgetStandalone:r});case"refined_search":case"refined_browse":return I.jsx(N5,{globalClassName:t,message:e,isWidgetStandalone:r});case"follow_up":return I.jsx(WN,{globalClassName:t,isWidgetStandalone:r,message:e,handleSuggestionClick:o});case"inquiry":case"partial_inquiry":return I.jsx(lb,{globalClassName:t,message:e});case"error":return I.jsx(VN,{message:e,isWidgetStandalone:r});case"display_products":return I.jsx($N,{message:e,isWidgetStandalone:r});case"progress":return I.jsx(k5,{globalClassName:t,isWidgetStandalone:r,message:e});case"conversation_reset":return I.jsxs(I.Fragment,{children:[I.jsx("p",{className:oe(t,`${Z}-reset-message`),children:"This conversation has been reset."}),I.jsx("p",{className:oe(t,`${Z}-start-search-message`),children:n})]});default:return null}},Bh=({isWidgetStandalone:e,messages:t,handleSuggestionClick:n})=>{const{globalClassName:r,resetConversationMessage:o}=sr();return t.map(u=>u.messages&&u.type==="group"?I.jsx("div",{className:oe(r,`${Z}-message-group`,e?"standalone":"embedded"),children:u.messages.length>0&&u.messages.map(a=>I.jsx("div",{className:`${Z}-message-group-child`,children:I.jsx(hb,{id:a.id,globalClassName:r,isWidgetStandalone:e,message:a,resetConversationMessage:o,handleSuggestionClick:n})},a.id))},`group-${u.eventSourceId}`):u.type==="individual"&&u.message?I.jsx("div",{className:oe(r,`${Z}-message`,e?"standalone":"embedded",{error:u.message.name.includes("error")}),children:I.jsx(hb,{id:u.message.id,globalClassName:r,isWidgetStandalone:e,message:u.message,resetConversationMessage:o,handleSuggestionClick:n})},u.message.id):null)},pb=()=>{const{globalClassName:e,themeVariables:t}=sr(),{status:n}=Vo(),{copilot:r,messages:o,groupedMessages:u,isLoading:a,handleUserInput:c,handleSuggestion:f}=li(),{isOpen:h}=n||{},m=W.useRef(null);return W.useEffect(()=>{m.current&&m.current.scrollIntoView({behavior:"smooth",block:"end"})},[o]),r?!h||u.length===0?null:I.jsxs("div",{className:oe(e,`${Z}-container`,`${Z}-embedded-chat`),style:t,children:[I.jsxs("div",{className:oe(e,`${Z}-message-container`,"embedded"),children:[I.jsx(Bh,{isWidgetStandalone:!1,messages:u,handleSuggestionClick:f}),a&&I.jsx("div",{style:{display:"flex",justifyContent:"flex-start",paddingBottom:"1rem"},children:I.jsx(Fl,{})}),I.jsx("div",{ref:m})]}),I.jsx(Wf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:c}),I.jsx("div",{className:oe(`${Z}-embedded-chat-menu`),children:I.jsx(Id,{componentType:"chat",children:I.jsx(tE,{componentType:"chat"})})})]}):I.jsx("div",{children:"Loading Copilot..."})},[R5,L5]=Ps({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),D5=e=>o1()(e,["lazyMount","unmountOnExit"]),[F5,Au]=Ps({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),mb=W.forwardRef((e,t)=>{const n=Au(),r=L5(),o=hd(ye(U({},r),{present:n.open})),u=ar(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:I.jsx(ci.div,ye(U({},u),{ref:Ja(o.ref,t)}))});mb.displayName="DialogBackdrop";const Uh=W.forwardRef((e,t)=>{const n=Au(),r=Go(),o=ar(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:I.jsx(ci.div,ye(U({},o),{ref:Ja(r.ref,t)}))});Uh.displayName="DialogContent";const Hh=W.forwardRef((e,t)=>{const n=Au(),r=ar(n.getDescriptionProps(),e);return I.jsx(ci.div,ye(U({},r),{ref:t}))});Hh.displayName="DialogDescription";const zh=W.forwardRef((e,t)=>{const n=Au(),r=ar(n.getPositionerProps(),e);return Go().unmounted?null:I.jsx(ci.div,ye(U({},r),{ref:t}))});zh.displayName="DialogPositioner";var M5=Rs("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),es=M5.build(),gb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},Eb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},jh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},yb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},$h=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`dialog:${e.id}:title`},Vh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`dialog:${e.id}:description`},Tb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},Bl=e=>e.getById(jh(e)),B5=e=>e.getById(gb(e)),U5=e=>e.getById(Eb(e)),H5=e=>e.getById(yb(e)),z5=e=>e.getById($h(e)),j5=e=>e.getById(Vh(e)),$5=e=>e.getById(Tb(e));function V5(e,t){const{state:n,send:r,context:o,prop:u,scope:a}=e,c=u("aria-label"),f=n.matches("open");return{open:f,setOpen(h){n.matches("open")!==h&&r({type:h?"OPEN":"CLOSE"})},getTriggerProps(){return t.button(ye(U({},es.trigger.attrs),{dir:u("dir"),id:yb(a),"aria-haspopup":"dialog",type:"button","aria-expanded":f,"data-state":f?"open":"closed","aria-controls":jh(a),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(ye(U({},es.backdrop.attrs),{dir:u("dir"),hidden:!f,id:Eb(a),"data-state":f?"open":"closed"}))},getPositionerProps(){return t.element(ye(U({},es.positioner.attrs),{dir:u("dir"),id:gb(a),style:{pointerEvents:f?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(ye(U({},es.content.attrs),{dir:u("dir"),role:u("role"),hidden:!f,id:jh(a),tabIndex:-1,"data-state":f?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:$h(a),"aria-describedby":h.description?Vh(a):void 0}))},getTitleProps(){return t.element(ye(U({},es.title.attrs),{dir:u("dir"),id:$h(a)}))},getDescriptionProps(){return t.element(ye(U({},es.description.attrs),{dir:u("dir"),id:Vh(a)}))},getCloseTriggerProps(){return t.button(ye(U({},es.closeTrigger.attrs),{dir:u("dir"),id:Tb(a),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var q5={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>$5(t):void 0,o=typeof e.modal=="boolean"?e.modal:!0;return U({role:"dialog",modal:o,trapFocus:o,preventScroll:o,closeOnInteractOutside:!n,closeOnEscape:!0,restoreFocus:!0,initialFocusEl:r},e)},initialState({prop:e}){return e("open")||e("defaultOpen")?"open":"closed"},context({bindable:e}){return{rendered:e(()=>({defaultValue:{title:!0,description:!0}}))}},watch({track:e,action:t,prop:n}){e([()=>n("open")],()=>{t(["toggleVisibility"])})},states:{open:{entry:["checkRenderedElements","syncZIndex"],effects:["trackDismissableElement","trapFocus","preventScroll","hideContentBelow"],on:{"CONTROLLED.CLOSE":{target:"closed"},CLOSE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose"]}],TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose"]}]}},closed:{on:{"CONTROLLED.OPEN":{target:"open"},OPEN:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen"]}],TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen"]}]}}},implementations:{guards:{isOpenControlled:({prop:e})=>e("open")!=null},effects:{trackDismissableElement({scope:e,send:t,prop:n}){return H1(()=>Bl(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[H5(e)],onInteractOutside(o){var u;(u=n("onInteractOutside"))==null||u(o),n("closeOnInteractOutside")||o.preventDefault()},persistentElements:n("persistentElements"),onFocusOutside:n("onFocusOutside"),onPointerDownOutside:n("onPointerDownOutside"),onRequestDismiss:n("onRequestDismiss"),onEscapeKeyDown(o){var u;(u=n("onEscapeKeyDown"))==null||u(o),n("closeOnEscape")||o.preventDefault()},onDismiss(){t({type:"CLOSE",src:"interact-outside"})}})},preventScroll({scope:e,prop:t}){if(t("preventScroll"))return q1(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?$1(()=>Bl(e),{preventScroll:!0,returnFocusOnDeactivate:!!t("restoreFocus"),initialFocus:t("initialFocusEl"),setReturnFocus:r=>{var o,u;return(u=(o=t("finalFocusEl"))==null?void 0:o())!=null?u:r},getShadowRoot:!0}):void 0},hideContentBelow({scope:e,prop:t}){return t("modal")?I1(()=>[Bl(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){_n(()=>{e.set("rendered",{title:!!z5(t),description:!!j5(t)})})},syncZIndex({scope:e}){_n(()=>{const t=Bl(e);if(!t)return;const n=Wa(t);[B5(e),U5(e)].forEach(o=>{o==null||o.style.setProperty("--z-index",n.zIndex),o==null||o.style.setProperty("--layer-index",n.getPropertyValue("--layer-index"))})})},invokeOnClose({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!1})},invokeOnOpen({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!0})},toggleVisibility({prop:e,send:t,event:n}){t({type:e("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:n})}}}};ld()(["aria-label","closeOnEscape","closeOnInteractOutside","dir","finalFocusEl","getRootNode","getRootNode","id","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","preventScroll","restoreFocus","role","trapFocus"]);const Y5=e=>{const t=W.useId(),{getRootNode:n}=Od(),{dir:r}=X1(),o=U({id:t,getRootNode:n,dir:r},e),u=cd(q5,o);return V5(u,n1)},bb=e=>{const[t,c]=u1(e),f=c,{children:n}=f,r=Xt(f,["children"]),[o]=D5(t),u=Y5(r),a=hd(ar({present:u.open},t));return I.jsx(F5,{value:u,children:I.jsx(R5,{value:o,children:I.jsx(r1,{value:a,children:n})})})},qh=W.forwardRef((e,t)=>{const n=Au(),r=ar(n.getTitleProps(),e);return I.jsx(ci.h2,ye(U({},r),{ref:t}))});qh.displayName="DialogTitle";const _b=e=>{var f;const{children:t,disabled:n}=e,[r,o]=W.useState((f=e.container)==null?void 0:f.current),u=W.useSyncExternalStore(G5,()=>!1,()=>!0),{getRootNode:a}=Od();if(W.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),u||n)return I.jsx(I.Fragment,{children:t});const c=r!=null?r:W5(a);return I.jsx(I.Fragment,{children:W.Children.map(t,h=>Qa.createPortal(h,c))})},W5=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Vi(n)?n:Sr(t).body},G5=()=>()=>{},K5=()=>{const{dialogPosition:e}=Vo(),t=e==="bottom-left",n=()=>{og(t?"bottom-right":"bottom-left")},r=t?MN:FN,o=t?"Move right":"Move left";return I.jsxs("button",{className:oe(`${Z}-overflow-menu-button`,"left-right-toggle-button","dialog"),onClick:n,children:[I.jsx(r,{}),o]})},xb=()=>{const{logoUrl:e,headerText:t,globalClassName:n,themeVariables:r}=sr(),{mode:o,status:u,dialogPosition:a}=Vo(),{copilot:c,messages:f,groupedMessages:h,isLoading:m,handleUserInput:E,handleSuggestion:b}=li(),T=W.useRef(null),{isOpen:_}=u||{},S=o==="standalone";W.useEffect(()=>{T.current&&T.current.scrollIntoView({behavior:"smooth",block:"end"})},[f]);const C=()=>{Ma(!1)};return!_||h.length===0?null:c?I.jsx(bb,{lazyMount:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:_,children:I.jsx(_b,{children:I.jsx(zh,{className:oe(n,`${Z}-container`,`${Z}-dialog`,a),style:r,children:I.jsxs(Uh,{className:oe(n,`${Z}-dialog-content`,{standalone:S,embedded:!S}),children:[I.jsxs("div",{className:oe(n,`${Z}-dialog-header`,{standalone:S,embedded:!S}),children:[e&&I.jsx("img",{alt:"",role:"img",className:oe(n,`${Z}-dialog-logo`,{standalone:S,embedded:!S}),src:e}),I.jsx(qh,{className:oe(n,`${Z}-dialog-title`,{standalone:S,embedded:!S}),children:t}),I.jsxs("div",{className:oe(n,`${Z}-dialog-controls`),children:[I.jsx(tE,{componentType:"dialog",isIcon:!0}),I.jsx(Id,{componentType:"dialog",children:I.jsx(K5,{})}),I.jsx(eE,{className:`dialog ${n}`,onClick:C})]})]}),I.jsxs(Hh,{className:oe(n,`${Z}-message-container`,{standalone:S,embedded:!S}),children:[I.jsx(Bh,{isWidgetStandalone:S,messages:h,handleSuggestionClick:b}),m&&I.jsx("div",{style:{display:"flex",justifyContent:"flex-start",paddingBottom:"1rem"},children:I.jsx(Fl,{})}),I.jsx("div",{ref:T})]}),I.jsx(Wf,{componentType:"dialog",isLoading:m,onSubmit:E})]})})})}):I.jsx("div",{children:"Loading Copilot..."})},Sb=()=>{const{logoUrl:e,headerText:t,globalClassName:n,themeVariables:r}=sr(),{mode:o,status:u,isModalFullscreen:a,previousComponentType:c}=Vo(),{copilot:f,messages:h,groupedMessages:m,isLoading:E,handleUserInput:b,handleSuggestion:T}=li(),_=W.useRef(null),{isOpen:S}=u||{},C=o==="standalone";W.useEffect(()=>{_.current&&_.current.scrollIntoView({behavior:"smooth",block:"end"})},[h]);const k=({open:q})=>{Ma(q)},M=()=>{sg(!a)},D=()=>{Vf(c||"dialog")},G=()=>{Ma(!1)};return!S||m.length===0?null:f?I.jsx(bb,{lazyMount:!0,open:S,onOpenChange:k,children:I.jsx(_b,{children:I.jsxs("div",{className:oe(n,`${Z}-modal-container`),style:r,children:[I.jsx(mb,{className:oe(n,`${Z}-modal-backdrop`)}),I.jsx(zh,{className:oe(n,`${Z}-container`,`${Z}-modal`,{fullscreen:a,standalone:C,embedded:!C}),children:I.jsxs(Uh,{className:oe(n,`${Z}-modal-content`,{standalone:C,embedded:!C}),children:[I.jsxs("div",{className:oe(n,`${Z}-modal-header`,{standalone:C,embedded:!C}),children:[e&&I.jsx("img",{alt:"",role:"img",className:oe(n,`${Z}-modal-logo`,{standalone:C,embedded:!C}),src:e}),I.jsx(qh,{className:oe(n,`${Z}-modal-title`,{standalone:C,embedded:!C}),children:t}),I.jsxs("div",{className:oe(n,`${Z}-modal-controls`),children:[I.jsx(ja,{ariaLabel:"Toggle Fullscreen",className:oe(n,`${Z}-modal-fullscreen-button`),icon:a?I.jsx(aA,{}):I.jsx(lA,{}),onClick:M}),I.jsx(ja,{ariaLabel:"Toggle Dialog",className:oe(n,`${Z}-modal-toggle-dialog-button`),onClick:D,icon:I.jsx(zN,{})}),I.jsx(Id,{componentType:"modal"}),I.jsx(eE,{className:`modal ${n}`,onClick:G})]})]}),I.jsxs(Hh,{className:oe(n,`${Z}-message-container`,{standalone:C,embedded:!C}),children:[I.jsx(Bh,{isWidgetStandalone:C,messages:m,handleSuggestionClick:T}),E&&I.jsx("div",{style:{display:"flex",justifyContent:"flex-start",paddingLeft:"1rem",paddingBottom:"1rem"},children:I.jsx(Fl,{})}),I.jsx("div",{ref:_})]}),I.jsx(Wf,{componentType:"modal",isLoading:E,onSubmit:b})]})})]})})}):I.jsx("div",{children:"Loading Copilot..."})},Q5=()=>{const e=Vo(),{status:{type:t}}=e||{status:{}};return t==="dialog"?I.jsx(xb,{}):t==="modal"?I.jsx(Sb,{}):I.jsx(pb,{})},Yh=e=>I.jsx(Ag,ye(U({},e),{children:I.jsx(Q5,{})}));var Ul={},wb;function X5(){if(wb)return Ul;wb=1;var e=Jg();return Ul.createRoot=e.createRoot,Ul.hydrateRoot=e.hydrateRoot,Ul}var Cb=X5();const J5=r=>{var o=r,{elementId:e,timeout:t=5e3}=o,n=Xt(o,["elementId","timeout"]);let u;const a=(f,h)=>{var m;for(const E of f)if(E.type==="childList"&&E.addedNodes.length)for(const b of E.addedNodes)b.nodeType===Node.ELEMENT_NODE&&b.id===e&&(ws(!0,"log","Target element found, rendering Copilot Widget"),h.disconnect(),clearTimeout(u),(m=Cb.createRoot(b))==null||m.render(I.jsx(Yh,U({},n))))},c=new MutationObserver(a);return c.observe(document.body,{childList:!0,subtree:!0}),u=setTimeout(()=>{c.disconnect(),ws(!0,"error",`Element with id: ${e} not found within ${t} milliseconds, stopping observation`)},t),c},Z5=r=>{var o=r,{timeout:e,elementId:t}=o,n=Xt(o,["timeout","elementId"]);if(!n.apiKey&&!n.apiToken){ws(!0,"error","Copilot Widget requires either apiKey or apiToken");return}const u=document.getElementById(t);if(!u){ws(!0,"warn","Container element not found for id:",t),ws(!0,"warn","Beginning observation for element"),J5(U({elementId:t,timeout:e},n));return}Cb.createRoot(u).render(I.jsx(Yh,U({},n)))},e8={search:FC,browse:MC,pdp:{setPdpContext:UC,updatePdpProductId:HC,updatePdpLink:zC},components:{toggleWidgetOpen:Ma,toggleModalFullscreen:sg,setWidgetType:Vf,setWidgetDialogPosition:og},session:jC},t8={search:gt.state,browse:mt.state,pdp:Vr.state,isConnected:It.state.connected};Oe.CopilotDialog=xb,Oe.CopilotEmbed=pb,Oe.CopilotModal=Sb,Oe.CopilotWidget=Yh,Oe.WidgetProvider=Ag,Oe.eventHandlers=e8,Oe.injectCopilotWidget=Z5,Oe.state=t8,Oe.useCopilot=li,Object.defineProperty(Oe,Symbol.toStringTag,{value:"Module"})});
43
+ `))}function f(T,_,S,C){const k=S.enter("tableCell"),M=S.enter("phrasing"),D=S.containerPhrasing(T,ye(U({},C),{before:u,after:u}));return M(),k(),D}function h(T,_){return h4(T,{align:_,alignDelimiters:r,padding:n,stringLength:o})}function m(T,_,S){const C=T.children;let k=-1;const M=[],D=_.enter("table");for(;++k<C.length;)M[k]=E(C[k],_,S);return D(),M}function E(T,_,S){const C=T.children;let k=-1;const M=[],D=_.enter("tableRow");for(;++k<C.length;)M[k]=f(C[k],T,_,S);return D(),M}function b(T,_,S){let C=eb.inlineCode(T,_,S);return S.stack.includes("tableCell")&&(C=C.replace(/\|/g,"\\$&")),C}}function e5(){return{exit:{taskListCheckValueChecked:nb,taskListCheckValueUnchecked:nb,paragraph:n5}}}function t5(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:r5}}}function nb(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function n5(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1];n.type;const r=n.children[0];if(r&&r.type==="text"){const o=t.children;let u=-1,a;for(;++u<o.length;){const c=o[u];if(c.type==="paragraph"){a=c;break}}a===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(e)}function r5(e,t,n,r){const o=e.children[0],u=typeof e.checked=="boolean"&&o&&o.type==="paragraph",a="["+(e.checked?"x":" ")+"] ",c=n.createTracker(r);u&&c.move(a);let f=eb.listItem(e,t,n,U(U({},r),c.current()));return u&&(f=f.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),f;function h(m){return m+a}}function i5(){return[FD(),r4(),u4(),W4(),e5()]}function s5(e){return{extensions:[MD(),i4(e),a4(),Z4(e),t5()]}}const o5={tokenize:d5,partial:!0},rb={tokenize:h5,partial:!0},ib={tokenize:p5,partial:!0},sb={tokenize:m5,partial:!0},u5={tokenize:g5,partial:!0},ob={name:"wwwAutolink",tokenize:c5,previous:ab},ub={name:"protocolAutolink",tokenize:f5,previous:lb},Jr={name:"emailAutolink",tokenize:l5,previous:cb},Pr={};function a5(){return{text:Pr}}let Zi=48;for(;Zi<123;)Pr[Zi]=Jr,Zi++,Zi===58?Zi=65:Zi===91&&(Zi=97);Pr[43]=Jr,Pr[45]=Jr,Pr[46]=Jr,Pr[95]=Jr,Pr[72]=[Jr,ub],Pr[104]=[Jr,ub],Pr[87]=[Jr,ob],Pr[119]=[Jr,ob];function l5(e,t,n){const r=this;let o,u;return a;function a(E){return!Ph(E)||!cb.call(r,r.previous)||Rh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return Ph(E)?(e.consume(E),c):E===64?(e.consume(E),f):n(E)}function f(E){return E===46?e.check(u5,m,h)(E):E===45||E===95||rn(E)?(u=!0,e.consume(E),f):m(E)}function h(E){return e.consume(E),o=!0,f}function m(E){return u&&o&&dn(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(E)):n(E)}}function c5(e,t,n){const r=this;return o;function o(a){return a!==87&&a!==119||!ab.call(r,r.previous)||Rh(r.events)?n(a):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(o5,e.attempt(rb,e.attempt(ib,u),n),n)(a))}function u(a){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(a)}}function f5(e,t,n){const r=this;let o="",u=!1;return a;function a(E){return(E===72||E===104)&&lb.call(r,r.previous)&&!Rh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(dn(E)&&o.length<5)return o+=String.fromCodePoint(E),e.consume(E),c;if(E===58){const b=o.toLowerCase();if(b==="http"||b==="https")return e.consume(E),f}return n(E)}function f(E){return E===47?(e.consume(E),u?h:(u=!0,f)):n(E)}function h(E){return E===null||cl(E)||at(E)||Gi(E)||fl(E)?n(E):e.attempt(rb,e.attempt(ib,m),n)(E)}function m(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function d5(e,t,n){let r=0;return o;function o(a){return(a===87||a===119)&&r<3?(r++,e.consume(a),o):a===46&&r===3?(e.consume(a),u):n(a)}function u(a){return a===null?n(a):t(a)}}function h5(e,t,n){let r,o,u;return a;function a(h){return h===46||h===95?e.check(sb,f,c)(h):h===null||at(h)||Gi(h)||h!==45&&fl(h)?f(h):(u=!0,e.consume(h),a)}function c(h){return h===95?r=!0:(o=r,r=void 0),e.consume(h),a}function f(h){return o||r||!u?n(h):t(h)}}function p5(e,t){let n=0,r=0;return o;function o(a){return a===40?(n++,e.consume(a),o):a===41&&r<n?u(a):a===33||a===34||a===38||a===39||a===41||a===42||a===44||a===46||a===58||a===59||a===60||a===63||a===93||a===95||a===126?e.check(sb,t,u)(a):a===null||at(a)||Gi(a)?t(a):(e.consume(a),o)}function u(a){return a===41&&r++,e.consume(a),o}}function m5(e,t,n){return r;function r(c){return c===33||c===34||c===39||c===41||c===42||c===44||c===46||c===58||c===59||c===63||c===95||c===126?(e.consume(c),r):c===38?(e.consume(c),u):c===93?(e.consume(c),o):c===60||c===null||at(c)||Gi(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||at(c)||Gi(c)?t(c):r(c)}function u(c){return dn(c)?a(c):n(c)}function a(c){return c===59?(e.consume(c),r):dn(c)?(e.consume(c),a):n(c)}}function g5(e,t,n){return r;function r(u){return e.consume(u),o}function o(u){return rn(u)?n(u):t(u)}}function ab(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||at(e)}function lb(e){return!dn(e)}function cb(e){return!(e===47||Ph(e))}function Ph(e){return e===43||e===45||e===46||e===95||rn(e)}function Rh(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const E5={tokenize:C5,partial:!0};function y5(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:x5,continuation:{tokenize:S5},exit:w5}},text:{91:{name:"gfmFootnoteCall",tokenize:_5},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:T5,resolveTo:b5}}}}function T5(e,t,n){const r=this;let o=r.events.length;const u=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a;for(;o--;){const f=r.events[o][1];if(f.type==="labelImage"){a=f;break}if(f.type==="gfmFootnoteCall"||f.type==="labelLink"||f.type==="label"||f.type==="image"||f.type==="link")break}return c;function c(f){if(!a||!a._balanced)return n(f);const h=fr(r.sliceSerialize({start:a.end,end:r.now()}));return h.codePointAt(0)!==94||!u.includes(h.slice(1))?n(f):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(f),e.exit("gfmFootnoteCallLabelMarker"),t(f))}}function b5(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const u={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},a={type:"chunkString",contentType:"string",start:Object.assign({},u.start),end:Object.assign({},u.end)},c=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",u,t],["enter",a,t],["exit",a,t],["exit",u,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...c),e}function _5(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u=0,a;return c;function c(E){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(E),e.exit("gfmFootnoteCallLabelMarker"),f}function f(E){return E!==94?n(E):(e.enter("gfmFootnoteCallMarker"),e.consume(E),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",h)}function h(E){if(u>999||E===93&&!a||E===null||E===91||at(E))return n(E);if(E===93){e.exit("chunkString");const b=e.exit("gfmFootnoteCallString");return o.includes(fr(r.sliceSerialize(b)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(E),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(E)}return at(E)||(a=!0),u++,e.consume(E),E===92?m:h}function m(E){return E===91||E===92||E===93?(e.consume(E),u++,h):h(E)}}function x5(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u,a=0,c;return f;function f(_){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionLabelMarker"),h}function h(_){return _===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",m):n(_)}function m(_){if(a>999||_===93&&!c||_===null||_===91||at(_))return n(_);if(_===93){e.exit("chunkString");const S=e.exit("gfmFootnoteDefinitionLabelString");return u=fr(r.sliceSerialize(S)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),b}return at(_)||(c=!0),a++,e.consume(_),_===92?E:m}function E(_){return _===91||_===92||_===93?(e.consume(_),a++,m):m(_)}function b(_){return _===58?(e.enter("definitionMarker"),e.consume(_),e.exit("definitionMarker"),o.includes(u)||o.push(u),Xe(e,T,"gfmFootnoteDefinitionWhitespace")):n(_)}function T(_){return t(_)}}function S5(e,t,n){return e.check(su,t,e.attempt(E5,t,n))}function w5(e){e.exit("gfmFootnoteDefinition")}function C5(e,t,n){const r=this;return Xe(e,o,"gfmFootnoteDefinitionIndent",5);function o(u){const a=r.events[r.events.length-1];return a&&a[1].type==="gfmFootnoteDefinitionIndent"&&a[2].sliceSerialize(a[1],!0).length===4?t(u):n(u)}}function A5(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:u,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function o(a,c){let f=-1;for(;++f<a.length;)if(a[f][0]==="enter"&&a[f][1].type==="strikethroughSequenceTemporary"&&a[f][1]._close){let h=f;for(;h--;)if(a[h][0]==="exit"&&a[h][1].type==="strikethroughSequenceTemporary"&&a[h][1]._open&&a[f][1].end.offset-a[f][1].start.offset===a[h][1].end.offset-a[h][1].start.offset){a[f][1].type="strikethroughSequence",a[h][1].type="strikethroughSequence";const m={type:"strikethrough",start:Object.assign({},a[h][1].start),end:Object.assign({},a[f][1].end)},E={type:"strikethroughText",start:Object.assign({},a[h][1].end),end:Object.assign({},a[f][1].start)},b=[["enter",m,c],["enter",a[h][1],c],["exit",a[h][1],c],["enter",E,c]],T=c.parser.constructs.insideSpan.null;T&&Ln(b,b.length,0,dl(T,a.slice(h+1,f),c)),Ln(b,b.length,0,[["exit",E,c],["enter",a[f][1],c],["exit",a[f][1],c],["exit",m,c]]),Ln(a,h-1,f-h+3,b),f=h+b.length-2;break}}for(f=-1;++f<a.length;)a[f][1].type==="strikethroughSequenceTemporary"&&(a[f][1].type="data");return a}function u(a,c,f){const h=this.previous,m=this.events;let E=0;return b;function b(_){return h===126&&m[m.length-1][1].type!=="characterEscape"?f(_):(a.enter("strikethroughSequenceTemporary"),T(_))}function T(_){const S=qs(h);if(_===126)return E>1?f(_):(a.consume(_),E++,T);if(E<2&&!n)return f(_);const C=a.exit("strikethroughSequenceTemporary"),k=qs(_);return C._open=!k||k===2&&!!S,C._close=!S||S===2&&!!k,c(_)}}}class v5{constructor(){this.map=[]}add(t,n,r){k5(this,t,n,r)}consume(t){if(this.map.sort(function(u,a){return u[0]-a[0]}),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];r.push(t.slice()),t.length=0;let o=r.pop();for(;o;){for(const u of o)t.push(u);o=r.pop()}this.map.length=0}}function k5(e,t,n,r){let o=0;if(!(n===0&&r.length===0)){for(;o<e.map.length;){if(e.map[o][0]===t){e.map[o][1]+=n,e.map[o][2].push(...r);return}o+=1}e.map.push([t,n,r])}}function N5(e,t){let n=!1;const r=[];for(;t<e.length;){const o=e[t];if(n){if(o[0]==="enter")o[1].type==="tableContent"&&r.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(o[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const u=r.length-1;r[u]=r[u]==="left"?"center":"right"}}else if(o[1].type==="tableDelimiterRow")break}else o[0]==="enter"&&o[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return r}function O5(){return{flow:{null:{name:"table",tokenize:I5,resolveAll:P5}}}}function I5(e,t,n){const r=this;let o=0,u=0,a;return c;function c(H){let fe=r.events.length-1;for(;fe>-1;){const ie=r.events[fe][1].type;if(ie==="lineEnding"||ie==="linePrefix")fe--;else break}const de=fe>-1?r.events[fe][1].type:null,ue=de==="tableHead"||de==="tableRow"?B:f;return ue===B&&r.parser.lazy[r.now().line]?n(H):ue(H)}function f(H){return e.enter("tableHead"),e.enter("tableRow"),h(H)}function h(H){return H===124||(a=!0,u+=1),m(H)}function m(H){return H===null?n(H):Re(H)?u>1?(u=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(H),e.exit("lineEnding"),T):n(H):Ke(H)?Xe(e,m,"whitespace")(H):(u+=1,a&&(a=!1,o+=1),H===124?(e.enter("tableCellDivider"),e.consume(H),e.exit("tableCellDivider"),a=!0,m):(e.enter("data"),E(H)))}function E(H){return H===null||H===124||at(H)?(e.exit("data"),m(H)):(e.consume(H),H===92?b:E)}function b(H){return H===92||H===124?(e.consume(H),E):E(H)}function T(H){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(H):(e.enter("tableDelimiterRow"),a=!1,Ke(H)?Xe(e,_,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(H):_(H))}function _(H){return H===45||H===58?C(H):H===124?(a=!0,e.enter("tableCellDivider"),e.consume(H),e.exit("tableCellDivider"),S):q(H)}function S(H){return Ke(H)?Xe(e,C,"whitespace")(H):C(H)}function C(H){return H===58?(u+=1,a=!0,e.enter("tableDelimiterMarker"),e.consume(H),e.exit("tableDelimiterMarker"),k):H===45?(u+=1,k(H)):H===null||Re(H)?G(H):q(H)}function k(H){return H===45?(e.enter("tableDelimiterFiller"),M(H)):q(H)}function M(H){return H===45?(e.consume(H),M):H===58?(a=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(H),e.exit("tableDelimiterMarker"),D):(e.exit("tableDelimiterFiller"),D(H))}function D(H){return Ke(H)?Xe(e,G,"whitespace")(H):G(H)}function G(H){return H===124?_(H):H===null||Re(H)?!a||o!==u?q(H):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(H)):q(H)}function q(H){return n(H)}function B(H){return e.enter("tableRow"),te(H)}function te(H){return H===124?(e.enter("tableCellDivider"),e.consume(H),e.exit("tableCellDivider"),te):H===null||Re(H)?(e.exit("tableRow"),t(H)):Ke(H)?Xe(e,te,"whitespace")(H):(e.enter("data"),Te(H))}function Te(H){return H===null||H===124||at(H)?(e.exit("data"),te(H)):(e.consume(H),H===92?Se:Te)}function Se(H){return H===92||H===124?(e.consume(H),Te):Te(H)}}function P5(e,t){let n=-1,r=!0,o=0,u=[0,0,0,0],a=[0,0,0,0],c=!1,f=0,h,m,E;const b=new v5;for(;++n<e.length;){const T=e[n],_=T[1];T[0]==="enter"?_.type==="tableHead"?(c=!1,f!==0&&(fb(b,t,f,h,m),m=void 0,f=0),h={type:"table",start:Object.assign({},_.start),end:Object.assign({},_.end)},b.add(n,0,[["enter",h,t]])):_.type==="tableRow"||_.type==="tableDelimiterRow"?(r=!0,E=void 0,u=[0,0,0,0],a=[0,n+1,0,0],c&&(c=!1,m={type:"tableBody",start:Object.assign({},_.start),end:Object.assign({},_.end)},b.add(n,0,[["enter",m,t]])),o=_.type==="tableDelimiterRow"?2:m?3:1):o&&(_.type==="data"||_.type==="tableDelimiterMarker"||_.type==="tableDelimiterFiller")?(r=!1,a[2]===0&&(u[1]!==0&&(a[0]=a[1],E=Rl(b,t,u,o,void 0,E),u=[0,0,0,0]),a[2]=n)):_.type==="tableCellDivider"&&(r?r=!1:(u[1]!==0&&(a[0]=a[1],E=Rl(b,t,u,o,void 0,E)),u=a,a=[u[1],n,0,0])):_.type==="tableHead"?(c=!0,f=n):_.type==="tableRow"||_.type==="tableDelimiterRow"?(f=n,u[1]!==0?(a[0]=a[1],E=Rl(b,t,u,o,n,E)):a[1]!==0&&(E=Rl(b,t,a,o,n,E)),o=0):o&&(_.type==="data"||_.type==="tableDelimiterMarker"||_.type==="tableDelimiterFiller")&&(a[3]=n)}for(f!==0&&fb(b,t,f,h,m),b.consume(t.events),n=-1;++n<t.events.length;){const T=t.events[n];T[0]==="enter"&&T[1].type==="table"&&(T[1]._align=N5(t.events,n))}return e}function Rl(e,t,n,r,o,u){const a=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(u.end=Object.assign({},to(t.events,n[0])),e.add(n[0],0,[["exit",u,t]]));const f=to(t.events,n[1]);if(u={type:a,start:Object.assign({},f),end:Object.assign({},f)},e.add(n[1],0,[["enter",u,t]]),n[2]!==0){const h=to(t.events,n[2]),m=to(t.events,n[3]),E={type:c,start:Object.assign({},h),end:Object.assign({},m)};if(e.add(n[2],0,[["enter",E,t]]),r!==2){const b=t.events[n[2]],T=t.events[n[3]];if(b[1].end=Object.assign({},T[1].end),b[1].type="chunkText",b[1].contentType="text",n[3]>n[2]+1){const _=n[2]+1,S=n[3]-n[2]-1;e.add(_,S,[])}}e.add(n[3]+1,0,[["exit",E,t]])}return o!==void 0&&(u.end=Object.assign({},to(t.events,o)),e.add(o,0,[["exit",u,t]]),u=void 0),u}function fb(e,t,n,r,o){const u=[],a=to(t.events,n);o&&(o.end=Object.assign({},a),u.push(["exit",o,t])),r.end=Object.assign({},a),u.push(["exit",r,t]),e.add(n+1,0,u)}function to(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const R5={name:"tasklistCheck",tokenize:D5};function L5(){return{text:{91:R5}}}function D5(e,t,n){const r=this;return o;function o(f){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(f):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(f),e.exit("taskListCheckMarker"),u)}function u(f){return at(f)?(e.enter("taskListCheckValueUnchecked"),e.consume(f),e.exit("taskListCheckValueUnchecked"),a):f===88||f===120?(e.enter("taskListCheckValueChecked"),e.consume(f),e.exit("taskListCheckValueChecked"),a):n(f)}function a(f){return f===93?(e.enter("taskListCheckMarker"),e.consume(f),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),c):n(f)}function c(f){return Re(f)?t(f):Ke(f)?e.check({tokenize:F5},t,n)(f):n(f)}}function F5(e,t,n){return Xe(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function M5(e){return DE([a5(),y5(),A5(e),O5(),L5()])}const B5={};function U5(e){const t=this,n=e||B5,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),u=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),a=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push(M5(n)),u.push(i5()),a.push(s5(n))}const Ll=()=>I.jsx("span",{className:`${Z}-blinking-cursor`,children:I.jsx("svg",{height:"1rem",width:"1rem",xmlns:"http://www.w3.org/2000/svg",children:I.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),db=({globalClassName:e,message:t})=>{const{isLoading:n,isResponseLoading:r}=qr(),o=n&&r((t==null?void 0:t.eventSourceId)||"")&&t.name==="partial_inquiry";return I.jsx(iR,{remarkPlugins:[U5],rehypePlugins:[OD],components:{h1:({children:u})=>I.jsx("h1",{className:oe(e,`${Z}-header h1`),children:u}),h2:({children:u})=>I.jsx("h2",{className:oe(e,`${Z}-header h2`),children:u}),h3:({children:u})=>I.jsx("h3",{className:oe(e,`${Z}-header h3`),children:u}),ul:({children:u})=>I.jsx("ul",{className:oe(e,`${Z}-ul`),children:u}),ol:({children:u})=>I.jsx("ol",{className:oe(e,`${Z}-ol`),children:u}),li:({children:u})=>I.jsx("li",{className:oe(e,`${Z}-li`),children:u}),a:({href:u,children:a})=>I.jsx("a",ye(U({className:oe(e,`${Z}-link`)},u?{href:u,target:"_blank"}:{}),{rel:"noopener noreferrer",children:a})),table:({children:u})=>I.jsx("table",{className:oe(e,`${Z}-table`),children:u}),thead:({children:u})=>I.jsx("thead",{className:oe(e,`${Z}-thead`),children:u}),tbody:({children:u})=>I.jsx("tbody",{className:oe(e,`${Z}-tbody`),children:u}),tr:({children:u})=>I.jsx("tr",{className:oe(e,`${Z}-tr`),children:u}),th:({children:u})=>I.jsx("th",{className:oe(e,`${Z}-th`),children:u}),td:({children:u})=>I.jsx("td",{className:oe(e,`${Z}-td`),children:u}),span:({className:u,children:a})=>u===`${Z}-blinking-cursor`?I.jsx(Ll,{}):I.jsx("span",{children:a})},children:t.message+(o?`<span className='${Z}-blinking-cursor'></span>`:"")})},H5=({globalClassName:e,message:t})=>{const[n,r]=W.useState(!1),o=t.tool_name||t.toolName,u=!!t.thought,a=!!o,c=()=>{r(f=>!f)};return I.jsxs("div",{children:[I.jsxs("div",{className:oe(e,`${Z}-progress-message`,"standalone"),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon`,"progress-icon","standalone"),children:I.jsx(Rg,{})}),I.jsx("p",{className:oe(e,`${Z}-progress-text`,"standalone"),children:t.message})]}),(u||a)&&I.jsxs(I.Fragment,{children:[I.jsx($f,{className:oe(e,`${Z}-thought-context-button`),onClick:c,children:n?I.jsxs(I.Fragment,{children:["Hide ",I.jsx(_A,{})]}):I.jsxs(I.Fragment,{children:["Context ",I.jsx(xA,{})]})}),n&&I.jsx("div",{className:oe(e,`${Z}-thought-container`),children:u&&I.jsx("p",{className:oe(e,`${Z}-progress-thought`),children:t.thought})})]})]})},z5=({globalClassName:e,message:t,isWidgetStandalone:n})=>n?I.jsx(H5,{globalClassName:e,message:t}):I.jsxs("div",{className:oe(e,`${Z}-progress-message`,"embedded"),title:t.message,children:[I.jsx("span",{className:oe(e,`${Z}-message-icon`,"progress-icon","embedded"),children:I.jsx(Rg,{})}),I.jsx("i",{className:oe(e,`${Z}-progress-text`,"embedded"),children:t.message})]}),j5=({globalClassName:e,message:t,isWidgetStandalone:n})=>{var o,u;const r=((o=t.searchParams)==null?void 0:o.query)||((u=t.browseParams)==null?void 0:u.categoryId);return I.jsxs("div",{className:oe(e,`${Z}-refined-event`,{embedded:!n,standalone:n}),children:[I.jsxs("div",{className:oe(e,`${Z}-refined-event-query`,{embedded:!n,standalone:n}),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon`,`${Z}-refined-event-icon`,{embedded:!n,standalone:n}),children:I.jsx(Ha,{})}),I.jsx("p",{className:oe(e,`${Z}-text`,"bold"),children:r})]}),I.jsx(db,{message:t})]})},hb=e=>{var f,h;const{configModule:t}=ir(),n=((f=e.request)==null?void 0:f.searchParams)||((h=e.request)==null?void 0:h.browseParams),r=(t==null?void 0:t.getProductHiddenFields())||[],{facetFilters:o={}}=n||{facetFilters:{}},u=Object.fromEntries(Object.entries(o).filter(([m])=>!r.includes(m))),a=Object.keys(u),c=Object.values(u).reduce((m,E)=>m+E.length,0);return{facetFiltersList:a,filterCount:c}},Dl=({isWidgetStandalone:e,globalClassName:t,filterCount:n})=>I.jsx("span",{className:oe(t,`${Z}-facet-pill`,{standalone:e,embedded:!e}),children:`${n} filters`}),pb=({globalClassName:e,message:t,facetFiltersList:n})=>{var u,a;if(!n.length)return null;const r=((u=t.request)==null?void 0:u.searchParams)||((a=t.request)==null?void 0:a.browseParams),o=(r==null?void 0:r.facetFilters)||{};return n.map(c=>{var h;const f=((h=o[c])==null?void 0:h.join(", "))||"";return I.jsxs("div",{className:oe(e,`${Z}-facets`),children:[I.jsx("p",{className:oe(e,`${Z}-facet-category`),children:c}),I.jsx("p",{className:oe(e,`${Z}-facet-values`),children:f})]},c)})},$5=({globalClassName:e,message:t,isWidgetStandalone:n})=>{var u,a;const{facetFiltersList:r,filterCount:o}=hb(t);return n?I.jsxs("div",{children:[I.jsxs("div",{className:oe(e,`${Z}-user-message standalone`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-message-icon standalone`),children:I.jsx(Lg,{})}),I.jsx("p",{className:oe(e,`${Z}-user-message-text`),children:(u=t.request)==null?void 0:u.userPrompt}),r.length>0&&I.jsx(Dl,{isWidgetStandalone:!0,globalClassName:e,filterCount:o})]}),I.jsx(pb,{globalClassName:e,facetFiltersList:r,message:t})]}):I.jsxs("div",{className:oe(e,`${Z}-user-message embedded`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-message-icon embedded`),children:I.jsx(Lg,{})}),I.jsx("p",{children:(a=t.request)==null?void 0:a.userPrompt}),r.length>0&&I.jsx(Dl,{isWidgetStandalone:!1,filterCount:o})]})},V5=({globalClassName:e,actionLabel:t,query:n,message:r,facetFiltersList:o,filterCount:u})=>I.jsxs("div",{className:oe(e,`${Z}-user-search standalone`),children:[I.jsxs("div",{className:oe(e,`${Z}-user-search-query`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-search-icon standalone`),children:I.jsx(Ha,{})}),I.jsx("p",{className:oe(e,`${Z}-text bold`),children:`${t}: ${n}`}),o.length>0&&I.jsx(Dl,{isWidgetStandalone:!0,globalClassName:e,filterCount:u})]}),I.jsx(pb,{globalClassName:e,facetFiltersList:o,message:r})]}),q5=({globalClassName:e,message:t,isWidgetStandalone:n})=>{const{facetFiltersList:r,filterCount:o}=hb(t),{actionLabel:u,query:a}=W.useMemo(()=>{var f,h,m,E;switch(t.name){case"copilot_search":return{actionLabel:"Your search",query:(f=t.request)==null?void 0:f.searchParams.query};case"copilot_browse":return{actionLabel:"Browsing category",query:(m=(h=t.request)==null?void 0:h.browseParams)==null?void 0:m.categoryId};case"product_view":return{actionLabel:"Viewing product",query:(E=t.request)==null?void 0:E.productId};default:return{actionLabel:"",query:""}}},[t]);return!t.isUserAction||!a?null:n?I.jsx(V5,{globalClassName:e,message:t,actionLabel:u,query:a,facetFiltersList:r,filterCount:o}):I.jsxs("div",{className:oe(e,`${Z}-user-search embedded`),children:[I.jsx("span",{className:oe(e,`${Z}-message-icon user-search-icon embedded`),children:I.jsx(Ha,{})}),I.jsx("p",{children:a}),r.length>0&&I.jsx(Dl,{isWidgetStandalone:!1,filterCount:o})]})},mb=["copilot_search","copilot_browse","product_view"],gb=({message:e,globalClassName:t,resetConversationMessage:n,isWidgetStandalone:r,handleSuggestionClick:o})=>{var a;if(!e)return null;let u=e.name;if(mb.includes(u)&&(e.isInitial||e.isUserAction)&&(u="faceted_navigation"),mb.includes(u)&&!((a=e.request)!=null&&a.userPrompt))return null;switch(u){case"copilot_search":case"copilot_browse":case"product_view":return I.jsx($5,{globalClassName:t,isWidgetStandalone:r,message:e});case"faceted_navigation":return I.jsx(q5,{globalClassName:t,message:e,isWidgetStandalone:r});case"refined_search":case"refined_browse":return I.jsx(j5,{globalClassName:t,message:e,isWidgetStandalone:r});case"follow_up":return I.jsx(o3,{globalClassName:t,isWidgetStandalone:r,message:e,handleSuggestionClick:o});case"inquiry":case"partial_inquiry":return I.jsx(db,{globalClassName:t,message:e});case"error":return I.jsx(r3,{message:e,isWidgetStandalone:r});case"display_products":return I.jsx(n3,{message:e,isWidgetStandalone:r});case"progress":return I.jsx(z5,{globalClassName:t,isWidgetStandalone:r,message:e});case"conversation_reset":return I.jsxs(I.Fragment,{children:[I.jsx("p",{className:oe(t,`${Z}-reset-message`),children:"This conversation has been reset."}),I.jsx("p",{className:oe(t,`${Z}-start-search-message`),children:n})]});default:return null}},Lh=({isWidgetStandalone:e,messages:t,handleSuggestionClick:n})=>{const{globalClassName:r,resetConversationMessage:o}=ir();return t.map(u=>u.messages&&u.type==="group"?I.jsx("div",{className:oe(r,`${Z}-message-group`,e?"standalone":"embedded"),children:u.messages.length>0&&u.messages.map(a=>I.jsx("div",{className:`${Z}-message-group-child`,children:I.jsx(gb,{id:a.id,globalClassName:r,isWidgetStandalone:e,message:a,resetConversationMessage:o,handleSuggestionClick:n})},a.id))},`group-${u.eventSourceId}`):u.type==="individual"&&u.message?I.jsx("div",{className:oe(r,`${Z}-message`,e?"standalone":"embedded",{error:u.message.name.includes("error")}),children:I.jsx(gb,{id:u.message.id,globalClassName:r,isWidgetStandalone:e,message:u.message,resetConversationMessage:o,handleSuggestionClick:n})},u.message.id):null)},Eb=()=>{const{globalClassName:e,themeVariables:t}=ir(),{status:n}=Ma(),{copilot:r,messages:o,groupedMessages:u,isLoading:a,handleUserInput:c,handleSuggestion:f}=qr(),{isOpen:h}=n||{},m=W.useRef(null);return W.useEffect(()=>{m.current&&m.current.scrollIntoView({behavior:"smooth",block:"end"})},[o]),r?!h||u.length===0?null:I.jsxs("div",{className:oe(e,`${Z}-container`,`${Z}-embedded-chat`),style:t,children:[I.jsxs("div",{className:oe(e,`${Z}-message-container`,"embedded"),children:[I.jsx(Lh,{isWidgetStandalone:!1,messages:u,handleSuggestionClick:f}),a&&I.jsx("div",{style:{display:"flex",justifyContent:"flex-start",paddingBottom:"1rem"},children:I.jsx(Ll,{})}),I.jsx("div",{ref:m})]}),I.jsx(Vf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:c}),I.jsx("div",{className:oe(`${Z}-embedded-chat-menu`),children:I.jsx(ZN,{componentType:"chat",children:I.jsx(iE,{componentType:"chat"})})})]}):I.jsx("div",{children:"Loading Copilot..."})},[Y5,W5]=Os({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),G5=e=>u1()(e,["lazyMount","unmountOnExit"]),[K5,wu]=Os({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),yb=W.forwardRef((e,t)=>{const n=wu(),r=W5(),o=cd(ye(U({},r),{present:n.open})),u=ar(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:I.jsx(ci.div,ye(U({},u),{ref:Qa(o.ref,t)}))});yb.displayName="DialogBackdrop";const Dh=W.forwardRef((e,t)=>{const n=wu(),r=Yo(),o=ar(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:I.jsx(ci.div,ye(U({},o),{ref:Qa(r.ref,t)}))});Dh.displayName="DialogContent";const Fh=W.forwardRef((e,t)=>{const n=wu(),r=ar(n.getDescriptionProps(),e);return I.jsx(ci.div,ye(U({},r),{ref:t}))});Fh.displayName="DialogDescription";const Mh=W.forwardRef((e,t)=>{const n=wu(),r=ar(n.getPositionerProps(),e);return Yo().unmounted?null:I.jsx(ci.div,ye(U({},r),{ref:t}))});Mh.displayName="DialogPositioner";var Q5=Is("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),es=Q5.build(),Tb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},bb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},Bh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},_b=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},Uh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`dialog:${e.id}:title`},Hh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`dialog:${e.id}:description`},xb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},Fl=e=>e.getById(Bh(e)),X5=e=>e.getById(Tb(e)),J5=e=>e.getById(bb(e)),Z5=e=>e.getById(_b(e)),e8=e=>e.getById(Uh(e)),t8=e=>e.getById(Hh(e)),n8=e=>e.getById(xb(e));function r8(e,t){const{state:n,send:r,context:o,prop:u,scope:a}=e,c=u("aria-label"),f=n.matches("open");return{open:f,setOpen(h){n.matches("open")!==h&&r({type:h?"OPEN":"CLOSE"})},getTriggerProps(){return t.button(ye(U({},es.trigger.attrs),{dir:u("dir"),id:_b(a),"aria-haspopup":"dialog",type:"button","aria-expanded":f,"data-state":f?"open":"closed","aria-controls":Bh(a),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(ye(U({},es.backdrop.attrs),{dir:u("dir"),hidden:!f,id:bb(a),"data-state":f?"open":"closed"}))},getPositionerProps(){return t.element(ye(U({},es.positioner.attrs),{dir:u("dir"),id:Tb(a),style:{pointerEvents:f?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(ye(U({},es.content.attrs),{dir:u("dir"),role:u("role"),hidden:!f,id:Bh(a),tabIndex:-1,"data-state":f?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:Uh(a),"aria-describedby":h.description?Hh(a):void 0}))},getTitleProps(){return t.element(ye(U({},es.title.attrs),{dir:u("dir"),id:Uh(a)}))},getDescriptionProps(){return t.element(ye(U({},es.description.attrs),{dir:u("dir"),id:Hh(a)}))},getCloseTriggerProps(){return t.button(ye(U({},es.closeTrigger.attrs),{dir:u("dir"),id:xb(a),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var i8={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>n8(t):void 0,o=typeof e.modal=="boolean"?e.modal:!0;return U({role:"dialog",modal:o,trapFocus:o,preventScroll:o,closeOnInteractOutside:!n,closeOnEscape:!0,restoreFocus:!0,initialFocusEl:r},e)},initialState({prop:e}){return e("open")||e("defaultOpen")?"open":"closed"},context({bindable:e}){return{rendered:e(()=>({defaultValue:{title:!0,description:!0}}))}},watch({track:e,action:t,prop:n}){e([()=>n("open")],()=>{t(["toggleVisibility"])})},states:{open:{entry:["checkRenderedElements","syncZIndex"],effects:["trackDismissableElement","trapFocus","preventScroll","hideContentBelow"],on:{"CONTROLLED.CLOSE":{target:"closed"},CLOSE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose"]}],TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnClose"]},{target:"closed",actions:["invokeOnClose"]}]}},closed:{on:{"CONTROLLED.OPEN":{target:"open"},OPEN:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen"]}],TOGGLE:[{guard:"isOpenControlled",actions:["invokeOnOpen"]},{target:"open",actions:["invokeOnOpen"]}]}}},implementations:{guards:{isOpenControlled:({prop:e})=>e("open")!=null},effects:{trackDismissableElement({scope:e,send:t,prop:n}){return z1(()=>Fl(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[Z5(e)],onInteractOutside(o){var u;(u=n("onInteractOutside"))==null||u(o),n("closeOnInteractOutside")||o.preventDefault()},persistentElements:n("persistentElements"),onFocusOutside:n("onFocusOutside"),onPointerDownOutside:n("onPointerDownOutside"),onRequestDismiss:n("onRequestDismiss"),onEscapeKeyDown(o){var u;(u=n("onEscapeKeyDown"))==null||u(o),n("closeOnEscape")||o.preventDefault()},onDismiss(){t({type:"CLOSE",src:"interact-outside"})}})},preventScroll({scope:e,prop:t}){if(t("preventScroll"))return Y1(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?V1(()=>Fl(e),{preventScroll:!0,returnFocusOnDeactivate:!!t("restoreFocus"),initialFocus:t("initialFocusEl"),setReturnFocus:r=>{var o,u;return(u=(o=t("finalFocusEl"))==null?void 0:o())!=null?u:r},getShadowRoot:!0}):void 0},hideContentBelow({scope:e,prop:t}){return t("modal")?P1(()=>[Fl(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){Tn(()=>{e.set("rendered",{title:!!e8(t),description:!!t8(t)})})},syncZIndex({scope:e}){Tn(()=>{const t=Fl(e);if(!t)return;const n=qa(t);[X5(e),J5(e)].forEach(o=>{o==null||o.style.setProperty("--z-index",n.zIndex),o==null||o.style.setProperty("--layer-index",n.getPropertyValue("--layer-index"))})})},invokeOnClose({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!1})},invokeOnOpen({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!0})},toggleVisibility({prop:e,send:t,event:n}){t({type:e("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:n})}}}};od()(["aria-label","closeOnEscape","closeOnInteractOutside","dir","finalFocusEl","getRootNode","getRootNode","id","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","preventScroll","restoreFocus","role","trapFocus"]);const s8=e=>{const t=W.useId(),{getRootNode:n}=vd(),{dir:r}=J1(),o=U({id:t,getRootNode:n,dir:r},e),u=ud(i8,o);return r8(u,r1)},Sb=e=>{const[t,c]=a1(e),f=c,{children:n}=f,r=en(f,["children"]),[o]=G5(t),u=s8(r),a=cd(ar({present:u.open},t));return I.jsx(K5,{value:u,children:I.jsx(Y5,{value:o,children:I.jsx(i1,{value:a,children:n})})})},zh=W.forwardRef((e,t)=>{const n=wu(),r=ar(n.getTitleProps(),e);return I.jsx(ci.h2,ye(U({},r),{ref:t}))});zh.displayName="DialogTitle";const wb=e=>{var f;const{children:t,disabled:n}=e,[r,o]=W.useState((f=e.container)==null?void 0:f.current),u=W.useSyncExternalStore(u8,()=>!1,()=>!0),{getRootNode:a}=vd();if(W.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),u||n)return I.jsx(I.Fragment,{children:t});const c=r!=null?r:o8(a);return I.jsx(I.Fragment,{children:W.Children.map(t,h=>Ga.createPortal(h,c))})},o8=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Vi(n)?n:Sr(t).body},u8=()=>()=>{},Cb=()=>{const{logoUrl:e,headerText:t,globalClassName:n,themeVariables:r}=ir(),{mode:o,status:u,dialogPosition:a}=Ma(),{copilot:c,messages:f,groupedMessages:h,isLoading:m,handleUserInput:E,handleSuggestion:b}=qr(),T=W.useRef(null),{isOpen:_}=u||{},S=o==="standalone";W.useEffect(()=>{T.current&&T.current.scrollIntoView({behavior:"smooth",block:"end"})},[f]);const C=()=>{Da(!1)};return!_||h.length===0?null:c?I.jsx(Sb,{lazyMount:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:_,children:I.jsx(wb,{children:I.jsx(Mh,{className:oe(n,`${Z}-container`,`${Z}-dialog`,a),style:r,children:I.jsxs(Dh,{className:oe(n,`${Z}-dialog-content`,{standalone:S,embedded:!S}),children:[I.jsxs("div",{className:oe(n,`${Z}-dialog-header`,{standalone:S,embedded:!S}),children:[e&&I.jsx("img",{alt:"",role:"img",className:oe(n,`${Z}-dialog-logo`,{standalone:S,embedded:!S}),src:e}),I.jsx(zh,{className:oe(n,`${Z}-dialog-title`,{standalone:S,embedded:!S}),children:t}),I.jsxs("div",{className:oe(n,`${Z}-dialog-controls`),children:[I.jsx(iE,{componentType:"dialog",isIcon:!0}),I.jsx(rE,{componentType:"dialog"}),I.jsx(nE,{className:`dialog ${n}`,onClick:C})]})]}),I.jsxs(Fh,{className:oe(n,`${Z}-message-container`,{standalone:S,embedded:!S}),children:[I.jsx(Lh,{isWidgetStandalone:S,messages:h,handleSuggestionClick:b}),m&&I.jsx("div",{style:{display:"flex",justifyContent:"flex-start",paddingBottom:"1rem"},children:I.jsx(Ll,{})}),I.jsx("div",{ref:T})]}),I.jsx(Vf,{componentType:"dialog",isLoading:m,onSubmit:E})]})})})}):I.jsx("div",{children:"Loading Copilot..."})},Ab=()=>{const{logoUrl:e,headerText:t,globalClassName:n,themeVariables:r}=ir(),{mode:o,status:u,isModalFullscreen:a,previousComponentType:c}=Ma(),{copilot:f,messages:h,groupedMessages:m,isLoading:E,handleUserInput:b,handleSuggestion:T}=qr(),_=W.useRef(null),{isOpen:S}=u||{},C=o==="standalone";W.useEffect(()=>{_.current&&_.current.scrollIntoView({behavior:"smooth",block:"end"})},[h]);const k=({open:q})=>{Da(q)},M=()=>{tg(!a)},D=()=>{jf(c||"dialog")},G=()=>{Da(!1)};return!S||m.length===0?null:f?I.jsx(Sb,{lazyMount:!0,open:S,onOpenChange:k,children:I.jsx(wb,{children:I.jsxs("div",{className:oe(n,`${Z}-modal-container`),style:r,children:[I.jsx(yb,{className:oe(n,`${Z}-modal-backdrop`)}),I.jsx(Mh,{className:oe(n,`${Z}-container`,`${Z}-modal`,{fullscreen:a,standalone:C,embedded:!C}),children:I.jsxs(Dh,{className:oe(n,`${Z}-modal-content`,{standalone:C,embedded:!C}),children:[I.jsxs("div",{className:oe(n,`${Z}-modal-header`,{standalone:C,embedded:!C}),children:[e&&I.jsx("img",{alt:"",role:"img",className:oe(n,`${Z}-modal-logo`,{standalone:C,embedded:!C}),src:e}),I.jsx(zh,{className:oe(n,`${Z}-modal-title`,{standalone:C,embedded:!C}),children:t}),I.jsxs("div",{className:oe(n,`${Z}-modal-controls`),children:[I.jsx(jo,{ariaLabel:"Toggle Fullscreen",className:oe(n,`${Z}-modal-fullscreen-button`),icon:a?I.jsx(SA,{}):I.jsx(wA,{}),onClick:M}),I.jsx(jo,{ariaLabel:"Toggle Dialog",className:oe(n,`${Z}-modal-toggle-dialog-button`),onClick:D,icon:I.jsx(e3,{})}),I.jsx(rE,{componentType:"modal"}),I.jsx(nE,{className:`modal ${n}`,onClick:G})]})]}),I.jsxs(Fh,{className:oe(n,`${Z}-message-container`,{standalone:C,embedded:!C}),children:[I.jsx(Lh,{isWidgetStandalone:C,messages:m,handleSuggestionClick:T}),E&&I.jsx("div",{style:{display:"flex",justifyContent:"flex-start",paddingLeft:"1rem",paddingBottom:"1rem"},children:I.jsx(Ll,{})}),I.jsx("div",{ref:_})]}),I.jsx(Vf,{componentType:"modal",isLoading:E,onSubmit:b})]})})]})})}):I.jsx("div",{children:"Loading Copilot..."})},a8=()=>{const e=Ma(),{status:{type:t}}=e||{status:{}};return t==="dialog"?I.jsx(Cb,{}):t==="modal"?I.jsx(Ab,{}):I.jsx(Eb,{})},jh=e=>I.jsx(vg,ye(U({},e),{children:I.jsx(a8,{})}));var Ml={},vb;function l8(){if(vb)return Ml;vb=1;var e=Zg();return Ml.createRoot=e.createRoot,Ml.hydrateRoot=e.hydrateRoot,Ml}var kb=l8();const c8=r=>{var o=r,{elementId:e,timeout:t=5e3}=o,n=en(o,["elementId","timeout"]);let u;const a=(f,h)=>{var m;for(const E of f)if(E.type==="childList"&&E.addedNodes.length)for(const b of E.addedNodes)b.nodeType===Node.ELEMENT_NODE&&b.id===e&&(ws(!0,"log","Target element found, rendering Copilot Widget"),h.disconnect(),clearTimeout(u),(m=kb.createRoot(b))==null||m.render(I.jsx(jh,U({},n))))},c=new MutationObserver(a);return c.observe(document.body,{childList:!0,subtree:!0}),u=setTimeout(()=>{c.disconnect(),ws(!0,"error",`Element with id: ${e} not found within ${t} milliseconds, stopping observation`)},t),c},f8=r=>{var o=r,{timeout:e,elementId:t}=o,n=en(o,["timeout","elementId"]);if(!n.apiKey&&!n.apiToken){ws(!0,"error","Copilot Widget requires either apiKey or apiToken");return}const u=document.getElementById(t);if(!u){ws(!0,"warn","Container element not found for id:",t),ws(!0,"warn","Beginning observation for element"),c8(U({elementId:t,timeout:e},n));return}kb.createRoot(u).render(I.jsx(jh,U({},n)))},d8={search:qC,browse:QC,pdp:{setPdpContext:JC,updatePdpProductId:ZC,updatePdpLink:eA},components:{toggleWidgetOpen:Da,toggleModalFullscreen:tg,setWidgetType:jf,setWidgetDialogPosition:wC},session:tA},h8={search:ct.state,browse:lt.state,pdp:or.state,isConnected:Ot.state.connected};Oe.CopilotDialog=Cb,Oe.CopilotEmbed=Eb,Oe.CopilotModal=Ab,Oe.CopilotWidget=jh,Oe.WidgetProvider=vg,Oe.eventHandlers=d8,Oe.injectCopilotWidget=f8,Oe.state=h8,Oe.useCopilot=qr,Object.defineProperty(Oe,Symbol.toStringTag,{value:"Module"})});