@cimulate/copilot-widget 1.8.4 → 1.9.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,52 +1,52 @@
1
- (function(Ie,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Ie=typeof globalThis!="undefined"?globalThis:Ie||self,Fe(Ie.CimulateMessaging={}))})(this,(function(Ie){"use strict";var _M=Object.defineProperty,SM=Object.defineProperties;var wM=Object.getOwnPropertyDescriptors;var Ic=Object.getOwnPropertySymbols;var Ax=Object.prototype.hasOwnProperty,vx=Object.prototype.propertyIsEnumerable;var ys=(Ie,Fe)=>(Fe=Symbol[Ie])?Fe:Symbol.for("Symbol."+Ie),AM=Ie=>{throw TypeError(Ie)},Ja=Math.pow,tm=(Ie,Fe,We)=>Fe in Ie?_M(Ie,Fe,{enumerable:!0,configurable:!0,writable:!0,value:We}):Ie[Fe]=We,U=(Ie,Fe)=>{for(var We in Fe||(Fe={}))Ax.call(Fe,We)&&tm(Ie,We,Fe[We]);if(Ic)for(var We of Ic(Fe))vx.call(Fe,We)&&tm(Ie,We,Fe[We]);return Ie},ne=(Ie,Fe)=>SM(Ie,wM(Fe));var rn=(Ie,Fe)=>{var We={};for(var rt in Ie)Ax.call(Ie,rt)&&Fe.indexOf(rt)<0&&(We[rt]=Ie[rt]);if(Ie!=null&&Ic)for(var rt of Ic(Ie))Fe.indexOf(rt)<0&&vx.call(Ie,rt)&&(We[rt]=Ie[rt]);return We};var Je=(Ie,Fe,We)=>tm(Ie,typeof Fe!="symbol"?Fe+"":Fe,We);var et=(Ie,Fe,We)=>new Promise((rt,Et)=>{var dt=Tt=>{try{Rt(We.next(Tt))}catch(on){Et(on)}},Re=Tt=>{try{Rt(We.throw(Tt))}catch(on){Et(on)}},Rt=Tt=>Tt.done?rt(Tt.value):Promise.resolve(Tt.value).then(dt,Re);Rt((We=We.apply(Ie,Fe)).next())}),oo=function(Ie,Fe){this[0]=Ie,this[1]=Fe},nm=(Ie,Fe,We)=>{var rt=(Re,Rt,Tt,on)=>{try{var so=We[Re](Rt),Ts=(Rt=so.value)instanceof oo,Rc=so.done;Promise.resolve(Ts?Rt[0]:Rt).then($n=>Ts?rt(Re==="return"?Re:"next",Rt[1]?{done:$n.done,value:$n.value}:$n,Tt,on):Tt({value:$n,done:Rc})).catch($n=>rt("throw",$n,Tt,on))}catch($n){on($n)}},Et=Re=>dt[Re]=Rt=>new Promise((Tt,on)=>rt(Re,Rt,Tt,on)),dt={};return We=We.apply(Ie,Fe),dt[ys("asyncIterator")]=()=>dt,Et("next"),Et("throw"),Et("return"),dt},rm=Ie=>{var Fe=Ie[ys("asyncIterator")],We=!1,rt,Et={};return Fe==null?(Fe=Ie[ys("iterator")](),rt=dt=>Et[dt]=Re=>Fe[dt](Re)):(Fe=Fe.call(Ie),rt=dt=>Et[dt]=Re=>{if(We){if(We=!1,dt==="throw")throw Re;return Re}return We=!0,{done:!1,value:new oo(new Promise(Rt=>{var Tt=Fe[dt](Re);Tt instanceof Object||AM("Object expected"),Rt(Tt)}),1)}}),Et[ys("iterator")]=()=>Et,rt("next"),"throw"in Fe?rt("throw"):Et.throw=dt=>{throw dt},"return"in Fe&&rt("return"),Et},Cx=(Ie,Fe,We)=>(Fe=Ie[ys("asyncIterator")])?Fe.call(Ie):(Ie=Ie[ys("iterator")](),Fe={},We=(rt,Et)=>(Et=Ie[rt])&&(Fe[rt]=dt=>new Promise((Re,Rt,Tt)=>(dt=Et.call(Ie,dt),Tt=dt.done,Promise.resolve(dt.value).then(on=>Re({value:on,done:Tt}),Rt)))),We("next"),We("return"),Fe);var Fe=document.createElement("style");Fe.textContent=`.cim-widget-icon-button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:32px;background-color:transparent;border:1px solid transparent;border-radius:var(--cim-widget-border-radius);padding:0;cursor:pointer;color:#333;font-size:18px;svg{padding:6px;height:100%;width:100%}&:hover{background-color:#f0f0f0}&:disabled,&[disabled]{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-icon-image{object-fit:contain;padding:6px;width:.875em;height:.875em}.cim-widget-minimized-container{--base-color: var(--cim-widget-primary-color, #3182ce);--base-color-darken: color-mix(in srgb, var(--base-color), black 20%);position:fixed;bottom:1rem;right:1rem;display:flex;align-items:center;justify-content:center;.cim-widget-minimized-button{height:3rem;width:3rem;border-radius:2rem;padding:.5rem;color:#fff;box-shadow:0 4px 6px #00000040,0 1px 3px #00000050;background-color:var(--base-color);transition:background-color .1s ease-in-out;&:active{transform:translateY(1px);box-shadow:0 4px 6px #00000020,0 1px 3px #00000030}&:hover{background-color:var(--base-color-darken)}}.cim-widget-minimized-icon-img{object-fit:contain;width:stretch;height:stretch}}.cim-widget-button{--base-color: var(--cim-widget-primary-color, #3182ce);padding:.25rem .5rem;min-height:32px;background-color:var(--base-color);border-radius:var(--cim-widget-border-radius);border-color:var(--base-color);border-style:solid;color:#fff;font-family:var(--cim-widget-font-family, inherit);cursor:pointer;&:disabled,&[disabled]{cursor:not-allowed;opacity:.6}&:hover{background-color:color-mix(in srgb,var(--base-color),black 20%);border-color:color-mix(in srgb,var(--base-color),black 20%)}&:focus-visible{outline:2px solid color-mix(in srgb,var(--base-color),white 25%)}}.cim-widget-disclaimer{display:flex;flex-direction:column;padding:0 .5rem .5rem;gap:.5rem}.cim-widget-disclaimer-text{font-size:.75rem;color:#00000090;margin:0}.cim-widget-disclaimer-image{object-fit:contain;height:100%;width:100%}.cim-widget-search-bar-wrapper{display:flex;flex-direction:column;padding:.5rem;gap:.5rem;&.with-attachments{border-top:1px solid var(--cim-widget-border-color)}}.cim-widget-search-bar{display:flex;align-items:center;gap:4px;font-family:var(--cim-widget-font-family)}.cim-widget-image-file-preview{display:inline-flex;align-items:center;gap:8px;padding-left:.5rem}.cim-widget-image-preview{object-fit:contain;max-height:2.5rem;&.cim-modal-component{max-height:3.5rem}}.cim-widget-image-file-name{width:100%;font-size:.8rem;color:#00000090;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;line-clamp:3;overflow:hidden}.cim-widget-close-button.clear-attachment{padding:.15rem;color:#00000090}.cim-widget-search-input{width:100%;min-height:2rem;padding:0 8px;background-color:transparent;border:1px solid #00000040;border-radius:var(--cim-widget-border-radius)}.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-image-upload-button{display:inline-flex;height:100%;border-radius:4px;cursor:pointer;&:hover{background-color:#f0f0f0}&.disabled{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-image-upload-label{display:inline-flex;justify-content:center;align-items:center;padding:8px;margin-bottom:0;cursor:pointer;&.disabled{cursor:not-allowed}}.cim-widget-search-button{display:inline-flex;align-items:center;white-space:nowrap;gap:.25rem}.cim-widget-search-button-icon{--base-color: var(--cim-widget-primary-color, #3182ce);background-color:var(--base-color);border-color:var(--base-color);color:#fff;&:disabled,&[disabled]{background-color:var(--base-color);border-color:var(--base-color);opacity:.6}&:hover{background-color:color-mix(in srgb,var(--base-color),black 20%);border-color:color-mix(in srgb,var(--base-color),black 20%)}}.cim-widget-search-button-icon-image{object-fit:contain;width:1.25em;height:1.25em}.cim-widget-file-input{display:none}.cim-widget-overflow-menu{position:relative;height:auto;width:auto}.cim-widget-overflow-menu-list{width:170px;background:#fff;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color)}.cim-widget-overflow-menu-button{background-color:#fff}.cim-widget-overflow-menu-button-trigger,.cim-widget-overflow-menu-button{display:inline-flex;align-items:center;width:100%;border:1px solid transparent;border-radius:var(--cim-widget-border-radius);cursor:pointer;color:#333;&:hover{background-color:#f0f0f0}}.cim-widget-overflow-menu-button{gap:.5rem;padding:.5rem .75rem;svg{font-size:.75rem}}.cim-widget-carousel{position:relative;width:100%}.cim-widget-carousel__item-group{padding:4px 0;justify-content:flex-start;&.carousel-row-container{display:flex!important}}.cim-widget-carousel__item{flex-shrink:0;>*{height:100%}}.cim-widget-carousel__control{position:absolute;top:50%;left:0;right:0;transform:translateY(-50%);display:flex;justify-content:space-between;pointer-events:none;padding:0 4px}.cim-widget-carousel__prev-trigger,.cim-widget-carousel__next-trigger{pointer-events:auto;display:flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color, #d1d5db);background-color:var(--cim-widget-background-color, #ffffff);color:var(--cim-widget-font-color, #3f3f46);cursor:pointer;box-shadow:0 1px 3px #0000001a;transition:background-color .15s ease,box-shadow .15s ease}.cim-widget-carousel__prev-trigger:hover,.cim-widget-carousel__next-trigger:hover{background-color:#f9fafb;box-shadow:0 2px 6px #0000001f}.cim-widget-carousel__prev-trigger:disabled,.cim-widget-carousel__next-trigger:disabled{opacity:.4;cursor:not-allowed}.cim-widget-carousel__indicator-group{display:flex;justify-content:center;gap:6px;padding-top:12px}.cim-widget-carousel__indicator{width:8px;height:8px;border-radius:50%;border:none;background-color:var(--cim-widget-border-color, #d1d5db);cursor:pointer;padding:0;transition:background-color .2s ease,transform .2s ease}.cim-widget-carousel__indicator[data-current]{background-color:var(--cim-widget-font-color, #1a202c);transform:scale(1.25)}.cim-widget-carousel__indicator:hover:not([data-current]){background-color:var(--cim-widget-font-color, #1a202c);opacity:.5}.cim-widget-close-button{display:flex;align-items:center;justify-content:center;padding:.5rem;border-radius:var(--cim-widget-border-radius);border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-toggle-modal-button.cim-dialog-component{display:none}@media(min-width:576px){.cim-widget-toggle-modal-button.cim-dialog-component{display:inline-flex}}.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-container{margin-top:1rem;margin-bottom:1rem;margin-right:.5rem;overflow-x:auto}.cim-widget-table{border-radius:.5rem;border-width:1px;border-style:solid;border-color:var(--cim-widget-border-color);border-collapse:collapse;width:100%}.cim-widget-thead{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent);border-bottom-width:2px;border-color:var(--cim-widget-border-color)}.cim-widget-tbody{border-width:0px;box-sizing:border-box;background-color:#ffffff90;overflow-wrap:break-word}.cim-widget-tr{border-style:solid;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-th{padding:.5rem 1rem;text-align:left;font-weight:700;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-td{padding:.5rem 1rem;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-message-container pre{margin:0}.cim-widget-connecting-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-size: 8px;--cim-loader-speed: 1.4s;--cim-loader-gap: .5rem;display:flex;align-items:center;gap:var(--cim-loader-gap)}.cim-widget-connecting-indicator.embedded{padding:12px 4px}.cim-widget-connecting-indicator.standalone{padding:12px 1rem}.cim-widget-connecting-pulse-wrapper{position:relative;width:calc(var(--cim-loader-size) * 2);height:calc(var(--cim-loader-size) * 2);display:flex;align-items:center;justify-content:center}.cim-widget-connecting-pulse{width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;background-color:var(--cim-loader-color);animation:cim-widget-pulse var(--cim-loader-speed) ease-in-out infinite}.cim-widget-connecting-ring{position:absolute;width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;border:1.5px solid var(--cim-loader-color);animation:cim-widget-ring-expand var(--cim-loader-speed) ease-out infinite}.cim-widget-connecting-text{font-size:12px;color:var(--cim-widget-font-color);font-family:var(--cim-widget-font-family, inherit);opacity:0;transform:translateY(4px);transition:opacity .4s ease,transform .4s ease}.cim-widget-connecting-text--visible{opacity:1;transform:translateY(0)}@keyframes cim-widget-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.6);opacity:.4}}@keyframes cim-widget-ring-expand{0%{transform:scale(1);opacity:.6}to{transform:scale(2.8);opacity:0}}@media(prefers-reduced-motion:reduce){.cim-widget-connecting-pulse,.cim-widget-connecting-ring{animation:none!important}.cim-widget-connecting-pulse{opacity:.6}.cim-widget-connecting-text{animation:none!important;transition:none!important}}.cim-widget-processing-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-speed: 1.8s;display:flex;flex-direction:column;gap:8px}.cim-widget-processing-indicator.embedded{max-width:80%;min-height:2.5rem;padding:.5rem 0}.cim-widget-processing-indicator.standalone{padding:0 1rem;min-height:3rem}.cim-widget-processing-text{font-size:.875rem;font-style:italic;color:color-mix(in srgb,var(--cim-widget-secondary-color) 70%,var(--cim-loader-color));opacity:.75}.cim-widget-processing-shimmer-bar{height:10px;border-radius:4px;background:linear-gradient(90deg,var(--cim-widget-border-color) 25%,color-mix(in srgb,var(--cim-loader-color) 15%,var(--cim-widget-background-color)) 50%,var(--cim-widget-border-color) 75%);background-size:200% 100%;animation:cim-widget-shimmer var(--cim-loader-speed) ease-in-out infinite}.cim-widget-processing-shimmer-bar:nth-child(2){width:75%;animation-delay:.15s}.cim-widget-processing-shimmer-bar:nth-child(3){width:50%;animation-delay:.3s}@keyframes cim-widget-shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}@media(prefers-reduced-motion:reduce){.cim-widget-processing-shimmer-bar{animation:none!important;background:var(--cim-widget-border-color)!important}}.cim-widget-msg-product-card{display:flex;flex-direction:column;width:180px;min-width:180px;height:100%;background-color:var(--cim-widget-background-color, #ffffff);border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);overflow:hidden;transition:box-shadow .2s ease;&.card-full-width{width:100%;min-width:100%}}.cim-widget-msg-product-card:hover{box-shadow:0 2px 8px #0000001f}.cim-widget-msg-product-card__image-wrapper{position:relative;width:100%;height:100%;aspect-ratio:1 / 1;overflow:hidden}.cim-widget-msg-product-card__image{width:100%;height:100%;object-fit:contain;display:block}.cim-widget-msg-product-card__content{display:flex;flex-direction:column;justify-content:space-between;gap:1rem;padding:12px;height:40%}.cim-widget-msg-product-card__title,.cim-widget-msg-product-card__title-link{font-family:var(--cim-widget-font-family, "Inter", sans-serif);font-weight:700;font-size:1rem;line-height:1.3;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46);margin:0;display:-webkit-box;line-clamp:2;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.cim-widget-msg-product-card__title-link{text-decoration:none}.cim-widget-msg-product-card__title-link:hover{text-decoration:underline}.cim-widget-msg-product-card__price-row{display:flex;align-items:center;justify-content:space-between;gap:8px}.cim-widget-msg-product-card__prices{display:flex;align-items:baseline;gap:6px;flex-wrap:wrap}.cim-widget-msg-product-card__price{font-family:var(--cim-widget-font-family, "Inter", sans-serif);font-weight:semibold;font-size:14px;line-height:1.2;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-product-card__compare-price{font-family:var(--cim-widget-font-family, "Inter", sans-serif);font-weight:400;font-size:13px;line-height:1.2;color:var(--cim-widget-font-color, #3f3f46);opacity:.6;text-decoration:line-through}.cim-widget-msg-product-card__add-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;min-width:28px;border:none;border-radius:4px;background-color:var(--cim-widget-primary-color, #141415);color:#fff;cursor:pointer;transition:opacity .15s ease}.cim-widget-msg-product-card__add-btn:hover{opacity:.85}.cim-widget-msg-product-card__add-btn svg{width:14px;height:14px}.cim-widget-message-group,.cim-widget-message{display:flex;flex-direction:column}.cim-widget-message-group{gap:.5rem;padding:.5rem 1rem;margin-bottom:1rem;border-radius:var(--cim-widget-border-radius);&.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}.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-user-message{display:flex;flex-direction:column;gap:.5rem;.cim-widget-user-message-row{display:inline-flex;align-items:center;gap:.5rem}}.cim-widget-user-message.embedded{display:inline-flex;align-self:flex-end;padding:.5rem 1rem;border-radius:var(--cim-widget-border-radius);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:50%}.cim-widget-user-message.standalone{margin:.5rem 0}.cim-widget-user-message-image{object-fit:contain;border-radius:8px;&.embedded{max-height:2.5rem}&.standalone{max-height:3.5rem}}.cim-widget-user-message-text{font-weight:700}.cim-widget-user-message-text.standalone{font-size:1.125rem;margin:0}.cim-widget-user-message-text.embedded{margin:0}.cim-widget-message-icon.user-message-icon.embedded{color:var(--cim-widget-primary-color)}.cim-widget-message-group-child{display:flex;flex-direction:column;gap:.25rem}.cim-widget-embedded-chat{position:relative;width:100%;height:100%;margin:0 auto;border-radius:var(--cim-widget-border-radius);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.cim-chat-component{border:1px solid var(--cim-widget-border-color);border-radius:var(--cim-widget-border-radius)}.cim-widget-left-right-toggle-button{display:none}@media(min-width:576px){.cim-widget-left-right-toggle-button{display:inline-flex}}.cim-widget-dialog{position:fixed;width:35dvw;height:55dvh;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color);font-size:.875rem;z-index:9999;&.full-height{height:calc(100% - 1rem)}&.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;padding:.5rem 1rem;margin-bottom:.5rem;gap:8px;border-bottom:1px solid var(--cim-widget-border-color);background-color:var(--cim-widget-header-background-color)}.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%}}@media(max-width:576px){.cim-widget-dialog{height:100%;width:100%!important;border-radius:0;&.full-height{height:100%}&.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;z-index:9999}.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;border-radius:var(--cim-widget-border-radius);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;padding:.5rem 1rem;margin-bottom:1rem;gap:8px;border-bottom:1px solid var(--cim-widget-border-color);background-color:var(--cim-widget-header-background-color)}.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}.cim-widget-modal-fullscreen-button,.cim-widget-modal-toggle-dialog-button{display:none}@media(max-width:576px){.cim-widget-modal{height:100%;width:100%;border-radius:0}}@media(min-width:576px){.cim-widget-modal-fullscreen-button,.cim-widget-modal-toggle-dialog-button{display:inline-flex}}.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}.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)}.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:var(--cim-widget-border-radius);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);border-radius:var(--cim-widget-border-radius);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}
2
- /*$vite$:1*/`,document.head.appendChild(Fe);function We(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var rt={exports:{}},Et={},dt={exports:{}},Re={};var Rt;function Tt(){if(Rt)return Re;Rt=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"),a=Symbol.for("react.provider"),u=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.iterator;function T(M){return M===null||typeof M!="object"?null:(M=g&&M[g]||M["@@iterator"],typeof M=="function"?M:null)}var b={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,S={};function A(M,X,k){this.props=M,this.context=X,this.refs=S,this.updater=k||b}A.prototype.isReactComponent={},A.prototype.setState=function(M,X){if(typeof M!="object"&&typeof M!="function"&&M!=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,M,X,"setState")},A.prototype.forceUpdate=function(M){this.updater.enqueueForceUpdate(this,M,"forceUpdate")};function C(){}C.prototype=A.prototype;function O(M,X,k){this.props=M,this.context=X,this.refs=S,this.updater=k||b}var R=O.prototype=new C;R.constructor=O,x(R,A.prototype),R.isPureReactComponent=!0;var F=Array.isArray,z=Object.prototype.hasOwnProperty,D={current:null},q={key:!0,ref:!0,__self:!0,__source:!0};function ce(M,X,k){var xe,Pe={},Oe=null,He=null;if(X!=null)for(xe in X.ref!==void 0&&(He=X.ref),X.key!==void 0&&(Oe=""+X.key),X)z.call(X,xe)&&!q.hasOwnProperty(xe)&&(Pe[xe]=X[xe]);var we=arguments.length-2;if(we===1)Pe.children=k;else if(1<we){for(var Ve=Array(we),ut=0;ut<we;ut++)Ve[ut]=arguments[ut+2];Pe.children=Ve}if(M&&M.defaultProps)for(xe in we=M.defaultProps,we)Pe[xe]===void 0&&(Pe[xe]=we[xe]);return{$$typeof:e,type:M,key:Oe,ref:He,props:Pe,_owner:D.current}}function be(M,X){return{$$typeof:e,type:M.type,key:X,ref:M.ref,props:M.props,_owner:M._owner}}function j(M){return typeof M=="object"&&M!==null&&M.$$typeof===e}function ae(M){var X={"=":"=0",":":"=2"};return"$"+M.replace(/[=:]/g,function(k){return X[k]})}var he=/\/+/g;function ge(M,X){return typeof M=="object"&&M!==null&&M.key!=null?ae(""+M.key):X.toString(36)}function ue(M,X,k,xe,Pe){var Oe=typeof M;(Oe==="undefined"||Oe==="boolean")&&(M=null);var He=!1;if(M===null)He=!0;else switch(Oe){case"string":case"number":He=!0;break;case"object":switch(M.$$typeof){case e:case t:He=!0}}if(He)return He=M,Pe=Pe(He),M=xe===""?"."+ge(He,0):xe,F(Pe)?(k="",M!=null&&(k=M.replace(he,"$&/")+"/"),ue(Pe,X,k,"",function(ut){return ut})):Pe!=null&&(j(Pe)&&(Pe=be(Pe,k+(!Pe.key||He&&He.key===Pe.key?"":(""+Pe.key).replace(he,"$&/")+"/")+M)),X.push(Pe)),1;if(He=0,xe=xe===""?".":xe+":",F(M))for(var we=0;we<M.length;we++){Oe=M[we];var Ve=xe+ge(Oe,we);He+=ue(Oe,X,k,Ve,Pe)}else if(Ve=T(M),typeof Ve=="function")for(M=Ve.call(M),we=0;!(Oe=M.next()).done;)Oe=Oe.value,Ve=xe+ge(Oe,we++),He+=ue(Oe,X,k,Ve,Pe);else if(Oe==="object")throw X=String(M),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(M).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.");return He}function Te(M,X,k){if(M==null)return M;var xe=[],Pe=0;return ue(M,xe,"","",function(Oe){return X.call(k,Oe,Pe++)}),xe}function Ne(M){if(M._status===-1){var X=M._result;X=X(),X.then(function(k){(M._status===0||M._status===-1)&&(M._status=1,M._result=k)},function(k){(M._status===0||M._status===-1)&&(M._status=2,M._result=k)}),M._status===-1&&(M._status=0,M._result=X)}if(M._status===1)return M._result.default;throw M._result}var fe={current:null},K={transition:null},te={ReactCurrentDispatcher:fe,ReactCurrentBatchConfig:K,ReactCurrentOwner:D};function w(){throw Error("act(...) is not supported in production builds of React.")}return Re.Children={map:Te,forEach:function(M,X,k){Te(M,function(){X.apply(this,arguments)},k)},count:function(M){var X=0;return Te(M,function(){X++}),X},toArray:function(M){return Te(M,function(X){return X})||[]},only:function(M){if(!j(M))throw Error("React.Children.only expected to receive a single React element child.");return M}},Re.Component=A,Re.Fragment=n,Re.Profiler=o,Re.PureComponent=O,Re.StrictMode=r,Re.Suspense=d,Re.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=te,Re.act=w,Re.cloneElement=function(M,X,k){if(M==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+M+".");var xe=x({},M.props),Pe=M.key,Oe=M.ref,He=M._owner;if(X!=null){if(X.ref!==void 0&&(Oe=X.ref,He=D.current),X.key!==void 0&&(Pe=""+X.key),M.type&&M.type.defaultProps)var we=M.type.defaultProps;for(Ve in X)z.call(X,Ve)&&!q.hasOwnProperty(Ve)&&(xe[Ve]=X[Ve]===void 0&&we!==void 0?we[Ve]:X[Ve])}var Ve=arguments.length-2;if(Ve===1)xe.children=k;else if(1<Ve){we=Array(Ve);for(var ut=0;ut<Ve;ut++)we[ut]=arguments[ut+2];xe.children=we}return{$$typeof:e,type:M.type,key:Pe,ref:Oe,props:xe,_owner:He}},Re.createContext=function(M){return M={$$typeof:u,_currentValue:M,_currentValue2:M,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},M.Provider={$$typeof:a,_context:M},M.Consumer=M},Re.createElement=ce,Re.createFactory=function(M){var X=ce.bind(null,M);return X.type=M,X},Re.createRef=function(){return{current:null}},Re.forwardRef=function(M){return{$$typeof:c,render:M}},Re.isValidElement=j,Re.lazy=function(M){return{$$typeof:m,_payload:{_status:-1,_result:M},_init:Ne}},Re.memo=function(M,X){return{$$typeof:h,type:M,compare:X===void 0?null:X}},Re.startTransition=function(M){var X=K.transition;K.transition={};try{M()}finally{K.transition=X}},Re.unstable_act=w,Re.useCallback=function(M,X){return fe.current.useCallback(M,X)},Re.useContext=function(M){return fe.current.useContext(M)},Re.useDebugValue=function(){},Re.useDeferredValue=function(M){return fe.current.useDeferredValue(M)},Re.useEffect=function(M,X){return fe.current.useEffect(M,X)},Re.useId=function(){return fe.current.useId()},Re.useImperativeHandle=function(M,X,k){return fe.current.useImperativeHandle(M,X,k)},Re.useInsertionEffect=function(M,X){return fe.current.useInsertionEffect(M,X)},Re.useLayoutEffect=function(M,X){return fe.current.useLayoutEffect(M,X)},Re.useMemo=function(M,X){return fe.current.useMemo(M,X)},Re.useReducer=function(M,X,k){return fe.current.useReducer(M,X,k)},Re.useRef=function(M){return fe.current.useRef(M)},Re.useState=function(M){return fe.current.useState(M)},Re.useSyncExternalStore=function(M,X,k){return fe.current.useSyncExternalStore(M,X,k)},Re.useTransition=function(){return fe.current.useTransition()},Re.version="18.3.1",Re}var on;function so(){return on||(on=1,dt.exports=Tt()),dt.exports}var Ts;function Rc(){if(Ts)return Et;Ts=1;var e=so(),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,a={key:!0,ref:!0,__self:!0,__source:!0};function u(c,d,h){var m,g={},T=null,b=null;h!==void 0&&(T=""+h),d.key!==void 0&&(T=""+d.key),d.ref!==void 0&&(b=d.ref);for(m in d)r.call(d,m)&&!a.hasOwnProperty(m)&&(g[m]=d[m]);if(c&&c.defaultProps)for(m in d=c.defaultProps,d)g[m]===void 0&&(g[m]=d[m]);return{$$typeof:t,type:c,key:T,ref:b,props:g,_owner:o.current}}return Et.Fragment=n,Et.jsx=u,Et.jsxs=u,Et}var $n;function Ix(){return $n||($n=1,rt.exports=Rc()),rt.exports}var P=Ix();const or=Object.create(null);or.open="0",or.close="1",or.ping="2",or.pong="3",or.message="4",or.upgrade="5",or.noop="6";const Za=Object.create(null);Object.keys(or).forEach(e=>{Za[or[e]]=e});const Pc={type:"error",data:"parser error"},im=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",om=typeof ArrayBuffer=="function",sm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Lc=({type:e,data:t},n,r)=>im&&t instanceof Blob?n?r(t):am(t,r):om&&(t instanceof ArrayBuffer||sm(t))?n?r(t):am(new Blob([t]),r):r(or[e]+(t||"")),am=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function um(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Dc;function Rx(e,t){if(im&&e.data instanceof Blob)return e.data.arrayBuffer().then(um).then(t);if(om&&(e.data instanceof ArrayBuffer||sm(e.data)))return t(um(e.data));Lc(e,!1,n=>{Dc||(Dc=new TextEncoder),t(Dc.encode(n))})}const lm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bs=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<lm.length;e++)bs[lm.charCodeAt(e)]=e;const Px=e=>{let t=e.length*.75,n=e.length,r,o=0,a,u,c,d;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)a=bs[e.charCodeAt(r)],u=bs[e.charCodeAt(r+1)],c=bs[e.charCodeAt(r+2)],d=bs[e.charCodeAt(r+3)],m[o++]=a<<2|u>>4,m[o++]=(u&15)<<4|c>>2,m[o++]=(c&3)<<6|d&63;return h},Lx=typeof ArrayBuffer=="function",Mc=(e,t)=>{if(typeof e!="string")return{type:"message",data:cm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:Dx(e.substring(1),t)}:Za[n]?e.length>1?{type:Za[n],data:e.substring(1)}:{type:Za[n]}:Pc},Dx=(e,t)=>{if(Lx){const n=Px(e);return cm(n,t)}else return{base64:!0,data:e}},cm=(e,t)=>t==="blob"?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,dm="",Mx=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((a,u)=>{Lc(a,!1,c=>{r[u]=c,++o===n&&t(r.join(dm))})})},Fx=(e,t)=>{const n=e.split(dm),r=[];for(let o=0;o<n.length;o++){const a=Mc(n[o],t);if(r.push(a),a.type==="error")break}return r};function Bx(){return new TransformStream({transform(e,t){Rx(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 a=new DataView(o.buffer);a.setUint8(0,126),a.setUint16(1,r)}else{o=new Uint8Array(9);const a=new DataView(o.buffer);a.setUint8(0,127),a.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let Fc;function eu(e){return e.reduce((t,n)=>t+n.length,0)}function tu(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 Ux(e,t){Fc||(Fc=new TextDecoder);const n=[];let r=0,o=-1,a=!1;return new TransformStream({transform(u,c){for(n.push(u);;){if(r===0){if(eu(n)<1)break;const d=tu(n,1);a=(d[0]&128)===128,o=d[0]&127,o<126?r=3:o===126?r=1:r=2}else if(r===1){if(eu(n)<2)break;const d=tu(n,2);o=new DataView(d.buffer,d.byteOffset,d.length).getUint16(0),r=3}else if(r===2){if(eu(n)<8)break;const d=tu(n,8),h=new DataView(d.buffer,d.byteOffset,d.length),m=h.getUint32(0);if(m>Math.pow(2,21)-1){c.enqueue(Pc);break}o=m*Math.pow(2,32)+h.getUint32(4),r=3}else{if(eu(n)<o)break;const d=tu(n,o);c.enqueue(Mc(a?d:Fc.decode(d),t)),r=0}if(o===0||o>e){c.enqueue(Pc);break}}}})}const fm=4;function wt(e){if(e)return Hx(e)}function Hx(e){for(var t in wt.prototype)e[t]=wt.prototype[t];return e}wt.prototype.on=wt.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},wt.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},wt.prototype.off=wt.prototype.removeListener=wt.prototype.removeAllListeners=wt.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},wt.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},wt.prototype.emitReserved=wt.prototype.emit,wt.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},wt.prototype.hasListeners=function(e){return!!this.listeners(e).length};const nu=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),On=typeof self!="undefined"?self:typeof window!="undefined"?window:Function("return this")(),zx="arraybuffer";function vM(){}function hm(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const jx=On.setTimeout,$x=On.clearTimeout;function ru(e,t){t.useNativeTimers?(e.setTimeoutFn=jx.bind(On),e.clearTimeoutFn=$x.bind(On)):(e.setTimeoutFn=On.setTimeout.bind(On),e.clearTimeoutFn=On.clearTimeout.bind(On))}const Vx=1.33;function Yx(e){return typeof e=="string"?Wx(e):Math.ceil((e.byteLength||e.size)*Vx)}function Wx(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 pm(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function qx(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function Gx(e){let t={},n=e.split("&");for(let r=0,o=n.length;r<o;r++){let a=n[r].split("=");t[decodeURIComponent(a[0])]=decodeURIComponent(a[1])}return t}class Kx extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Bc extends wt{constructor(t){super(),this.writable=!1,ru(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 Kx(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=Mc(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&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=qx(t);return n.length?"?"+n:""}}class Qx extends Bc{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)};Fx(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,Mx(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]=pm()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let mm=!1;try{mm=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const Xx=mm;function Jx(){}class Zx extends Qx{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,a)=>{this.onError("xhr post error",o,a)})}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 sr extends wt{constructor(t,n,r){super(),this.createRequest=t,ru(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=hm(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=sr.requestsCount++,sr.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=Jx,t)try{this._xhr.abort()}catch(n){}typeof document!="undefined"&&delete sr.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(sr.requestsCount=0,sr.requests={},typeof document!="undefined"){if(typeof attachEvent=="function")attachEvent("onunload",gm);else if(typeof addEventListener=="function"){const e="onpagehide"in On?"pagehide":"unload";addEventListener(e,gm,!1)}}function gm(){for(let e in sr.requests)sr.requests.hasOwnProperty(e)&&sr.requests[e].abort()}const e_=(function(){const e=Em({xdomain:!1});return e&&e.responseType!==null})();class t_ extends Zx{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=e_&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new sr(Em,this.uri(),t)}}function Em(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||Xx))return new XMLHttpRequest}catch(n){}if(!t)try{return new On[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const ym=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class n_ extends Bc{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=ym?{}:hm(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;Lc(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch(u){}o&&nu(()=>{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]=pm()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const Uc=On.WebSocket||On.MozWebSocket;class r_ extends n_{createSocket(t,n,r){return ym?new Uc(t,n,r):n?new Uc(t,n):new Uc(t)}doWrite(t,n){this.ws.send(n)}}class i_ extends Bc{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=Ux(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=Bx();o.readable.pipeTo(t.writable),this._writer=o.writable.getWriter();const a=()=>{r.read().then(({done:c,value:d})=>{c||(this.onPacket(d),a())}).catch(c=>{})};a();const u={type:"open"};this.query.sid&&(u.data=`{"sid":"${this.query.sid}"}`),this._writer.write(u).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&&nu(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const o_={websocket:r_,webtransport:i_,polling:t_},s_=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,a_=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Hc(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=s_.exec(e||""),a={},u=14;for(;u--;)a[a_[u]]=o[u]||"";return n!=-1&&r!=-1&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a.pathNames=u_(a,a.path),a.queryKey=l_(a,a.query),a}function u_(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 l_(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,a){o&&(n[o]=a)}),n}const zc=typeof addEventListener=="function"&&typeof removeEventListener=="function",iu=[];zc&&addEventListener("offline",()=>{iu.forEach(e=>e())},!1);class Ur extends wt{constructor(t,n){if(super(),this.binaryType=zx,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=Hc(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=Hc(n.host).host);ru(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=Gx(this.opts.query)),zc&&(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"})},iu.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=fm,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&&Ur.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",Ur.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+=Yx(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,nu(()=>{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 a={type:t,data:n,options:r};this.emitReserved("packetCreate",a),this.writeBuffer.push(a),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(Ur.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(),zc&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=iu.indexOf(this._offlineEventListener);r!==-1&&iu.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Ur.protocol=fm;class c_ extends Ur{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;Ur.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",g=>{if(!r)if(g.type==="pong"&&g.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Ur.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 T=new Error("probe error");T.transport=n.name,this.emitReserved("upgradeError",T)}}))};function a(){r||(r=!0,m(),n.close(),n=null)}const u=g=>{const T=new Error("probe error: "+g);T.transport=n.name,a(),this.emitReserved("upgradeError",T)};function c(){u("transport closed")}function d(){u("socket closed")}function h(g){n&&g.name!==n.name&&a()}const m=()=>{n.removeListener("open",o),n.removeListener("error",u),n.removeListener("close",c),this.off("close",d),this.off("upgrading",h)};n.once("open",o),n.once("error",u),n.once("close",c),this.once("close",d),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 d_=class extends c_{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=>o_[o]).filter(o=>!!o)),super(t,r)}};function f_(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=Hc(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 a=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+a+":"+r.port+t,r.href=r.protocol+"://"+a+(n&&n.port===r.port?"":":"+r.port),r}const h_=typeof ArrayBuffer=="function",p_=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,Tm=Object.prototype.toString,m_=typeof Blob=="function"||typeof Blob!="undefined"&&Tm.call(Blob)==="[object BlobConstructor]",g_=typeof File=="function"||typeof File!="undefined"&&Tm.call(File)==="[object FileConstructor]";function jc(e){return h_&&(e instanceof ArrayBuffer||p_(e))||m_&&e instanceof Blob||g_&&e instanceof File}function ou(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ou(e[n]))return!0;return!1}if(jc(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ou(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ou(e[n]))return!0;return!1}function E_(e){const t=[],n=e.data,r=e;return r.data=$c(n,t),r.attachments=t.length,{packet:r,buffers:t}}function $c(e,t){if(!e)return e;if(jc(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]=$c(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]=$c(e[r],t));return n}return e}function y_(e,t){return e.data=Vc(e.data,t),delete e.attachments,e}function Vc(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]=Vc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Vc(e[n],t));return e}const T_=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var Ge;(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"})(Ge||(Ge={}));class b_{constructor(t){this.replacer=t}encode(t){return(t.type===Ge.EVENT||t.type===Ge.ACK)&&ou(t)?this.encodeAsBinary({type:t.type===Ge.EVENT?Ge.BINARY_EVENT:Ge.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Ge.BINARY_EVENT||t.type===Ge.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=E_(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class Yc extends wt{constructor(t){super(),this.opts=Object.assign({reviver:void 0,maxAttachments:10},typeof t=="function"?{reviver:t}: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===Ge.BINARY_EVENT;r||n.type===Ge.BINARY_ACK?(n.type=r?Ge.EVENT:Ge.ACK,this.reconstructor=new x_(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(jc(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(Ge[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Ge.BINARY_EVENT||r.type===Ge.BINARY_ACK){const a=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const u=t.substring(a,n);if(u!=Number(u)||t.charAt(n)!=="-")throw new Error("Illegal attachments");const c=Number(u);if(!__(c)||c<0)throw new Error("Illegal attachments");if(c>this.opts.maxAttachments)throw new Error("too many attachments");r.attachments=c}if(t.charAt(n+1)==="/"){const a=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(a,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const a=n+1;for(;++n;){const u=t.charAt(n);if(u==null||Number(u)!=u){--n;break}if(n===t.length)break}r.id=Number(t.substring(a,n+1))}if(t.charAt(++n)){const a=this.tryParse(t.substr(n));if(Yc.isPayloadValid(r.type,a))r.data=a;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.opts.reviver)}catch(n){return!1}}static isPayloadValid(t,n){switch(t){case Ge.CONNECT:return bm(n);case Ge.DISCONNECT:return n===void 0;case Ge.CONNECT_ERROR:return typeof n=="string"||bm(n);case Ge.EVENT:case Ge.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&T_.indexOf(n[0])===-1);case Ge.ACK:case Ge.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class x_{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=y_(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const __=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e};function bm(e){return Object.prototype.toString.call(e)==="[object Object]"}const S_=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Yc,Encoder:b_,get PacketType(){return Ge}},Symbol.toStringTag,{value:"Module"}));function Vn(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const w_=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class xm extends wt{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=[Vn(t,"open",this.onopen.bind(this)),Vn(t,"packet",this.onpacket.bind(this)),Vn(t,"error",this.onerror.bind(this)),Vn(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,a;if(w_.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 u={type:Ge.EVENT,data:n};if(u.options={},u.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const m=this.ids++,g=n.pop();this._registerAckCallback(m,g),u.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,d=this.connected&&!(!((a=this.io.engine)===null||a===void 0)&&a._hasPingExpired());return this.flags.volatile&&!c||(d?(this.notifyOutgoingListeners(u),this.packet(u)):this.sendBuffer.push(u)),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 a=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),u=(...c)=>{this.io.clearTimeoutFn(a),n.apply(this,c)};u.withError=!0,this.acks[t]=u}emitWithAck(t,...n){return new Promise((r,o)=>{const a=(u,c)=>u?o(u):r(c);a.withError=!0,n.push(a),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,...a)=>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,...a)),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:Ge.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 Ge.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 Ge.EVENT:case Ge.BINARY_EVENT:this.onevent(t);break;case Ge.ACK:case Ge.BINARY_ACK:this.onack(t);break;case Ge.DISCONNECT:this.ondisconnect();break;case Ge.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:Ge.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:Ge.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 ao(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}ao.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},ao.prototype.reset=function(){this.attempts=0},ao.prototype.setMin=function(e){this.ms=e},ao.prototype.setMax=function(e){this.max=e},ao.prototype.setJitter=function(e){this.jitter=e};class Wc extends wt{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,ru(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 ao({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||S_;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 d_(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=Vn(n,"open",function(){r.onopen(),t&&t()}),a=c=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",c),t?t(c):this.maybeReconnectOnOpen()},u=Vn(n,"error",a);if(this._timeout!==!1){const c=this._timeout,d=this.setTimeoutFn(()=>{o(),a(new Error("timeout")),n.close()},c);this.opts.autoUnref&&d.unref(),this.subs.push(()=>{this.clearTimeoutFn(d)})}return this.subs.push(o),this.subs.push(u),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Vn(t,"ping",this.onping.bind(this)),Vn(t,"data",this.ondata.bind(this)),Vn(t,"error",this.onerror.bind(this)),Vn(t,"close",this.onclose.bind(this)),Vn(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){nu(()=>{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 xs={};function qc(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=f_(e,t.path||"/socket.io"),r=n.source,o=n.id,a=n.path,u=xs[o]&&a in xs[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||u;let d;return c?d=new Wc(r,t):(xs[o]||(xs[o]=new Wc(r,t)),d=xs[o]),n.query&&!t.query&&(t.query=n.queryKey),d.socket(n.path,t)}Object.assign(qc,{Manager:Wc,Socket:xm,io:qc,connect:qc});const _m=Object.prototype.toString;typeof Blob=="function"||typeof Blob!="undefined"&&_m.call(Blob),typeof File=="function"||typeof File!="undefined"&&_m.call(File);var Sm;(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"})(Sm||(Sm={}));var ee=so();const bi=We(ee);class A_{constructor(){this.listeners=new Map,this.onceListeners=new Map}on(t,n){this.listeners.has(t)||this.listeners.set(t,new Set),this.listeners.get(t).add(n)}once(t,n){this.onceListeners.has(t)||this.onceListeners.set(t,new Set),this.onceListeners.get(t).add(n)}off(t,n){var r,o;return t?n?((r=this.listeners.get(t))==null||r.delete(n),void((o=this.onceListeners.get(t))==null?void 0:o.delete(n))):(this.listeners.delete(t),void this.onceListeners.delete(t)):(this.listeners.clear(),void this.onceListeners.clear())}emit(t,...n){const r=this.listeners.get(t);if(r)for(const a of r)try{a(...n)}catch(u){}const o=this.onceListeners.get(t);if(o){for(const a of o)try{a(...n)}catch(u){}this.onceListeners.delete(t)}}}class v_{constructor(t,n,r,o,a){this.url=t,this.headers=n,this.onEvent=r,this.onClose=o,this.logger=a,this.controller=null,this.reading=!1}connect(){return et(this,null,function*(){if(this.reading)return void this.logger.warn("SSE already connected, ignoring duplicate connect()");this.controller=new AbortController,this.reading=!0;const t=yield fetch(this.url,{method:"GET",headers:ne(U({},this.headers),{Accept:"text/event-stream","Cache-Control":"no-cache"}),signal:this.controller.signal});if(!t.ok){this.reading=!1;const n=yield t.text().catch(()=>t.statusText);throw new Error(`SSE connection failed (${t.status}): ${n}`)}if(!t.body)throw this.reading=!1,new Error("SSE response has no body stream");this.readStream(t.body)})}disconnect(){this.reading=!1,this.controller&&(this.controller.abort(),this.controller=null)}get isConnected(){return this.reading}readStream(t){return et(this,null,function*(){const n=t.getReader(),r=new TextDecoder;let o="";try{for(;this.reading;){const{value:a,done:u}=yield n.read();if(u)break;let c;for(o+=r.decode(a,{stream:!0}),o=o.replace(/\r\n/g,`
1
+ (function(Ie,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Ie=typeof globalThis!="undefined"?globalThis:Ie||self,Fe(Ie.CimulateMessaging={}))})(this,(function(Ie){"use strict";var AM=Object.defineProperty,vM=Object.defineProperties;var CM=Object.getOwnPropertyDescriptors;var Ic=Object.getOwnPropertySymbols;var Sx=Object.prototype.hasOwnProperty,Ax=Object.prototype.propertyIsEnumerable;var ys=(Ie,Fe)=>(Fe=Symbol[Ie])?Fe:Symbol.for("Symbol."+Ie),kM=Ie=>{throw TypeError(Ie)},Ja=Math.pow,Jp=(Ie,Fe,We)=>Fe in Ie?AM(Ie,Fe,{enumerable:!0,configurable:!0,writable:!0,value:We}):Ie[Fe]=We,U=(Ie,Fe)=>{for(var We in Fe||(Fe={}))Sx.call(Fe,We)&&Jp(Ie,We,Fe[We]);if(Ic)for(var We of Ic(Fe))Ax.call(Fe,We)&&Jp(Ie,We,Fe[We]);return Ie},ne=(Ie,Fe)=>vM(Ie,CM(Fe));var on=(Ie,Fe)=>{var We={};for(var rt in Ie)Sx.call(Ie,rt)&&Fe.indexOf(rt)<0&&(We[rt]=Ie[rt]);if(Ie!=null&&Ic)for(var rt of Ic(Ie))Fe.indexOf(rt)<0&&Ax.call(Ie,rt)&&(We[rt]=Ie[rt]);return We};var Je=(Ie,Fe,We)=>Jp(Ie,typeof Fe!="symbol"?Fe+"":Fe,We);var et=(Ie,Fe,We)=>new Promise((rt,Et)=>{var dt=Tt=>{try{Rt(We.next(Tt))}catch(sn){Et(sn)}},Re=Tt=>{try{Rt(We.throw(Tt))}catch(sn){Et(sn)}},Rt=Tt=>Tt.done?rt(Tt.value):Promise.resolve(Tt.value).then(dt,Re);Rt((We=We.apply(Ie,Fe)).next())}),so=function(Ie,Fe){this[0]=Ie,this[1]=Fe},Zp=(Ie,Fe,We)=>{var rt=(Re,Rt,Tt,sn)=>{try{var ao=We[Re](Rt),Ts=(Rt=ao.value)instanceof so,Rc=ao.done;Promise.resolve(Ts?Rt[0]:Rt).then($n=>Ts?rt(Re==="return"?Re:"next",Rt[1]?{done:$n.done,value:$n.value}:$n,Tt,sn):Tt({value:$n,done:Rc})).catch($n=>rt("throw",$n,Tt,sn))}catch($n){sn($n)}},Et=Re=>dt[Re]=Rt=>new Promise((Tt,sn)=>rt(Re,Rt,Tt,sn)),dt={};return We=We.apply(Ie,Fe),dt[ys("asyncIterator")]=()=>dt,Et("next"),Et("throw"),Et("return"),dt},em=Ie=>{var Fe=Ie[ys("asyncIterator")],We=!1,rt,Et={};return Fe==null?(Fe=Ie[ys("iterator")](),rt=dt=>Et[dt]=Re=>Fe[dt](Re)):(Fe=Fe.call(Ie),rt=dt=>Et[dt]=Re=>{if(We){if(We=!1,dt==="throw")throw Re;return Re}return We=!0,{done:!1,value:new so(new Promise(Rt=>{var Tt=Fe[dt](Re);Tt instanceof Object||kM("Object expected"),Rt(Tt)}),1)}}),Et[ys("iterator")]=()=>Et,rt("next"),"throw"in Fe?rt("throw"):Et.throw=dt=>{throw dt},"return"in Fe&&rt("return"),Et},vx=(Ie,Fe,We)=>(Fe=Ie[ys("asyncIterator")])?Fe.call(Ie):(Ie=Ie[ys("iterator")](),Fe={},We=(rt,Et)=>(Et=Ie[rt])&&(Fe[rt]=dt=>new Promise((Re,Rt,Tt)=>(dt=Et.call(Ie,dt),Tt=dt.done,Promise.resolve(dt.value).then(sn=>Re({value:sn,done:Tt}),Rt)))),We("next"),We("return"),Fe);var Fe=document.createElement("style");Fe.textContent=`.cim-widget-icon-button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:32px;background-color:transparent;border:1px solid transparent;border-radius:var(--cim-widget-border-radius);padding:0;cursor:pointer;color:#333;font-size:18px;svg{padding:6px;height:100%;width:100%}&:hover{background-color:#f0f0f0}&:disabled,&[disabled]{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-icon-image{object-fit:contain;padding:6px;width:.875em;height:.875em}.cim-widget-minimized-container{--base-color: var(--cim-widget-primary-color, #3182ce);--base-color-darken: color-mix(in srgb, var(--base-color), black 20%);position:fixed;bottom:1rem;right:1rem;display:flex;align-items:center;justify-content:center;.cim-widget-minimized-button{height:3rem;width:3rem;border-radius:2rem;padding:.5rem;color:#fff;box-shadow:0 4px 6px #00000040,0 1px 3px #00000050;background-color:var(--base-color);transition:background-color .1s ease-in-out;&:active{transform:translateY(1px);box-shadow:0 4px 6px #00000020,0 1px 3px #00000030}&:hover{background-color:var(--base-color-darken)}}.cim-widget-minimized-icon-img{object-fit:contain;width:stretch;height:stretch}}.cim-widget-button{--base-color: var(--cim-widget-primary-color, #3182ce);padding:.25rem .5rem;min-height:32px;background-color:var(--base-color);border-radius:var(--cim-widget-border-radius);border-color:var(--base-color);border-style:solid;color:#fff;font-family:var(--cim-widget-font-family, inherit);cursor:pointer;&:disabled,&[disabled]{cursor:not-allowed;opacity:.6}&:hover{background-color:color-mix(in srgb,var(--base-color),black 20%);border-color:color-mix(in srgb,var(--base-color),black 20%)}&:focus-visible{outline:2px solid color-mix(in srgb,var(--base-color),white 25%)}}.cim-widget-disclaimer{display:flex;flex-direction:column;padding:0 .5rem .5rem;gap:.5rem}.cim-widget-disclaimer-text{font-size:.75rem;color:#00000090;margin:0}.cim-widget-disclaimer-image{object-fit:contain;height:100%;width:100%}.cim-widget-search-bar-wrapper{display:flex;flex-direction:column;padding:.5rem;gap:.5rem;&.with-attachments{border-top:1px solid var(--cim-widget-border-color)}}.cim-widget-search-bar{display:flex;align-items:center;gap:4px;font-family:var(--cim-widget-font-family)}.cim-widget-image-file-preview{display:inline-flex;align-items:center;gap:8px;padding-left:.5rem}.cim-widget-image-preview{object-fit:contain;max-height:2.5rem;&.cim-modal-component{max-height:3.5rem}}.cim-widget-image-file-name{width:100%;font-size:.8rem;color:#00000090;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;line-clamp:3;overflow:hidden}.cim-widget-close-button.clear-attachment{padding:.15rem;color:#00000090}.cim-widget-search-input{width:100%;min-height:2rem;padding:0 8px;background-color:transparent;border:1px solid #00000040;border-radius:var(--cim-widget-border-radius)}.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-image-upload-button{display:inline-flex;height:100%;border-radius:4px;cursor:pointer;&:hover{background-color:#f0f0f0}&.disabled{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-image-upload-label{display:inline-flex;justify-content:center;align-items:center;padding:8px;margin-bottom:0;cursor:pointer;&.disabled{cursor:not-allowed}}.cim-widget-search-button{display:inline-flex;align-items:center;white-space:nowrap;gap:.25rem}.cim-widget-search-button-icon{--base-color: var(--cim-widget-primary-color, #3182ce);background-color:var(--base-color);border-color:var(--base-color);color:#fff;&:disabled,&[disabled]{background-color:var(--base-color);border-color:var(--base-color);opacity:.6}&:hover{background-color:color-mix(in srgb,var(--base-color),black 20%);border-color:color-mix(in srgb,var(--base-color),black 20%)}}.cim-widget-search-button-icon-image{object-fit:contain;width:1.25em;height:1.25em}.cim-widget-file-input{display:none}.cim-widget-overflow-menu{position:relative;height:auto;width:auto}.cim-widget-overflow-menu-list{width:170px;background:#fff;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color)}.cim-widget-overflow-menu-button{background-color:#fff}.cim-widget-overflow-menu-button-trigger,.cim-widget-overflow-menu-button{display:inline-flex;align-items:center;width:100%;border:1px solid transparent;border-radius:var(--cim-widget-border-radius);cursor:pointer;color:#333;&:hover{background-color:#f0f0f0}}.cim-widget-overflow-menu-button{gap:.5rem;padding:.5rem .75rem;svg{font-size:.75rem}}.cim-widget-carousel{position:relative;width:100%}.cim-widget-carousel__item-group{padding:4px 0;justify-content:flex-start;&.carousel-row-container{display:flex!important}}.cim-widget-carousel__item{flex-shrink:0;>*{height:100%}}.cim-widget-carousel__control{position:absolute;top:50%;left:0;right:0;transform:translateY(-50%);display:flex;justify-content:space-between;pointer-events:none;padding:0 4px}.cim-widget-carousel__prev-trigger,.cim-widget-carousel__next-trigger{pointer-events:auto;display:flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color, #d1d5db);background-color:var(--cim-widget-background-color, #ffffff);color:var(--cim-widget-font-color, #3f3f46);cursor:pointer;box-shadow:0 1px 3px #0000001a;transition:background-color .15s ease,box-shadow .15s ease}.cim-widget-carousel__prev-trigger:hover,.cim-widget-carousel__next-trigger:hover{background-color:#f9fafb;box-shadow:0 2px 6px #0000001f}.cim-widget-carousel__prev-trigger:disabled,.cim-widget-carousel__next-trigger:disabled{opacity:.4;cursor:not-allowed}.cim-widget-carousel__indicator-group{display:flex;justify-content:center;gap:6px;padding-top:12px}.cim-widget-carousel__indicator{width:8px;height:8px;border-radius:50%;border:none;background-color:var(--cim-widget-border-color, #d1d5db);cursor:pointer;padding:0;transition:background-color .2s ease,transform .2s ease}.cim-widget-carousel__indicator[data-current]{background-color:var(--cim-widget-font-color, #1a202c);transform:scale(1.25)}.cim-widget-carousel__indicator:hover:not([data-current]){background-color:var(--cim-widget-font-color, #1a202c);opacity:.5}.cim-widget-close-button{display:flex;align-items:center;justify-content:center;padding:.5rem;border-radius:var(--cim-widget-border-radius);border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-left-right-toggle-button{display:none}@media(min-width:576px){.cim-widget-left-right-toggle-button{display:inline-flex}}.cim-widget-toggle-modal-button.cim-dialog-component{display:none}@media(min-width:576px){.cim-widget-toggle-modal-button.cim-dialog-component{display:inline-flex}}.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-container{margin-top:1rem;margin-bottom:1rem;margin-right:.5rem;overflow-x:auto}.cim-widget-table{border-radius:.5rem;border-width:1px;border-style:solid;border-color:var(--cim-widget-border-color);border-collapse:collapse;width:100%}.cim-widget-thead{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent);border-bottom-width:2px;border-color:var(--cim-widget-border-color)}.cim-widget-tbody{border-width:0px;box-sizing:border-box;background-color:#ffffff90;overflow-wrap:break-word}.cim-widget-tr{border-style:solid;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-th{padding:.5rem 1rem;text-align:left;font-weight:700;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-td{padding:.5rem 1rem;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-message-container pre{margin:0}.cim-widget-connecting-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-size: 8px;--cim-loader-speed: 1.4s;--cim-loader-gap: .5rem;display:flex;align-items:center;gap:var(--cim-loader-gap)}.cim-widget-connecting-indicator.embedded{padding:12px 4px}.cim-widget-connecting-indicator.standalone{padding:12px 1rem}.cim-widget-connecting-pulse-wrapper{position:relative;width:calc(var(--cim-loader-size) * 2);height:calc(var(--cim-loader-size) * 2);display:flex;align-items:center;justify-content:center}.cim-widget-connecting-pulse{width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;background-color:var(--cim-loader-color);animation:cim-widget-pulse var(--cim-loader-speed) ease-in-out infinite}.cim-widget-connecting-ring{position:absolute;width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;border:1.5px solid var(--cim-loader-color);animation:cim-widget-ring-expand var(--cim-loader-speed) ease-out infinite}.cim-widget-connecting-text{font-size:12px;color:var(--cim-widget-font-color);font-family:var(--cim-widget-font-family, inherit);opacity:0;transform:translateY(4px);transition:opacity .4s ease,transform .4s ease}.cim-widget-connecting-text--visible{opacity:1;transform:translateY(0)}@keyframes cim-widget-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.6);opacity:.4}}@keyframes cim-widget-ring-expand{0%{transform:scale(1);opacity:.6}to{transform:scale(2.8);opacity:0}}@media(prefers-reduced-motion:reduce){.cim-widget-connecting-pulse,.cim-widget-connecting-ring{animation:none!important}.cim-widget-connecting-pulse{opacity:.6}.cim-widget-connecting-text{animation:none!important;transition:none!important}}.cim-widget-processing-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-speed: 1.8s;display:flex;flex-direction:column;gap:8px}.cim-widget-processing-indicator.embedded{max-width:80%;min-height:2.5rem;padding:.5rem 0}.cim-widget-processing-indicator.standalone{padding:0 1rem;min-height:3rem}.cim-widget-processing-text{font-size:.875rem;font-style:italic;color:color-mix(in srgb,var(--cim-widget-secondary-color) 70%,var(--cim-loader-color));opacity:.75}.cim-widget-processing-shimmer-bar{height:10px;border-radius:4px;background:linear-gradient(90deg,var(--cim-widget-border-color) 25%,color-mix(in srgb,var(--cim-loader-color) 15%,var(--cim-widget-background-color)) 50%,var(--cim-widget-border-color) 75%);background-size:200% 100%;animation:cim-widget-shimmer var(--cim-loader-speed) ease-in-out infinite}.cim-widget-processing-shimmer-bar:nth-child(2){width:75%;animation-delay:.15s}.cim-widget-processing-shimmer-bar:nth-child(3){width:50%;animation-delay:.3s}@keyframes cim-widget-shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}@media(prefers-reduced-motion:reduce){.cim-widget-processing-shimmer-bar{animation:none!important;background:var(--cim-widget-border-color)!important}}.cim-widget-msg-product-card{display:flex;flex-direction:column;width:180px;min-width:180px;height:100%;background-color:var(--cim-widget-background-color, #ffffff);border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);overflow:hidden;transition:box-shadow .2s ease;&.card-full-width{width:100%;min-width:100%}}.cim-widget-msg-product-card:hover{box-shadow:0 2px 8px #0000001f}.cim-widget-msg-product-card__image-wrapper{position:relative;width:100%;height:100%;aspect-ratio:1 / 1;overflow:hidden}.cim-widget-msg-product-card__image{width:100%;height:100%;object-fit:contain;display:block}.cim-widget-msg-product-card__content{display:flex;flex-direction:column;justify-content:space-between;gap:1rem;padding:12px;height:40%}.cim-widget-msg-product-card__title,.cim-widget-msg-product-card__title-link{font-family:var(--cim-widget-font-family, sans-serif);font-weight:700;font-size:1rem;line-height:1.3;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46);margin:0;display:-webkit-box;line-clamp:2;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.cim-widget-msg-product-card__title-link{text-decoration:none}.cim-widget-msg-product-card__title-link:hover{text-decoration:underline}.cim-widget-msg-product-card__price-row{display:flex;align-items:center;justify-content:space-between;gap:8px}.cim-widget-msg-product-card__prices{display:flex;align-items:baseline;gap:6px;flex-wrap:wrap}.cim-widget-msg-product-card__price{font-family:var(--cim-widget-font-family, sans-serif);font-weight:700;font-size:14px;line-height:1.2;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-product-card__compare-price{font-family:var(--cim-widget-font-family, sans-serif);font-weight:400;font-size:13px;line-height:1.2;color:var(--cim-widget-font-color, #3f3f46);opacity:.6;text-decoration:line-through}.cim-widget-msg-product-card__add-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;min-width:28px;border:none;border-radius:4px;background-color:var(--cim-widget-primary-color, #141415);color:#fff;cursor:pointer;transition:opacity .15s ease}.cim-widget-msg-product-card__add-btn:hover{opacity:.85}.cim-widget-msg-product-card__add-btn svg{width:14px;height:14px}.cim-widget-product-carousel-title{font-weight:800}.cim-widget-message-group,.cim-widget-message{display:flex;flex-direction:column}.cim-widget-message-group{gap:.5rem;padding:.5rem 1rem;margin-bottom:1rem;border-radius:var(--cim-widget-border-radius);&.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}.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-user-message{display:flex;flex-direction:column;gap:.5rem;.cim-widget-user-message-row{display:inline-flex;align-items:center;gap:.5rem}}.cim-widget-user-message.embedded{display:inline-flex;align-self:flex-end;padding:.5rem 1rem;border-radius:var(--cim-widget-border-radius);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:50%}.cim-widget-user-message.standalone{margin:.5rem 0}.cim-widget-user-message-image{object-fit:contain;border-radius:8px;&.embedded{max-height:2.5rem}&.standalone{max-height:3.5rem}}.cim-widget-user-message-text{font-weight:700}.cim-widget-user-message-text.standalone{font-size:1.125rem;margin:0}.cim-widget-user-message-text.embedded{margin:0}.cim-widget-message-icon.user-message-icon.embedded{color:var(--cim-widget-primary-color)}.cim-widget-message-group-child{display:flex;flex-direction:column;gap:.25rem}.cim-widget-embedded-chat{position:relative;width:100%;height:100%;margin:0 auto;border-radius:var(--cim-widget-border-radius);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.cim-chat-component{border:1px solid var(--cim-widget-border-color);border-radius:var(--cim-widget-border-radius)}.cim-widget-dialog{position:fixed;width:35dvw;height:55dvh;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color);font-size:.875rem;z-index:9999;&.full-height{height:100%}&.full-height.bottom-left{bottom:0;left:0}&.full-height.bottom-right{bottom:0;right:0}&.bottom-left{bottom:.5rem;left:.5rem;animation:cim-widget-dialog-slide-in-left .25s ease-out}&.bottom-right{bottom:.5rem;right:.5rem;animation:cim-widget-dialog-slide-in-right .25s ease-out}.cim-widget-message-group.embedded{max-width:100%}}.cim-widget-dialog-content{display:flex;flex-direction:column;height:100%}.cim-widget-dialog-header{display:inline-flex;align-items:center;padding:.5rem 1rem;margin-bottom:.5rem;gap:8px;border-bottom:1px solid var(--cim-widget-border-color);background-color:var(--cim-widget-header-background-color)}.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;font-size:var(--cim-widget-header-text-font-size)}@media(576px<=width<=768px){.cim-widget-dialog{width:50%}}@media(max-width:576px){.cim-widget-dialog{height:100%;width:100%!important;border-radius:0;&.full-height{height:100%}&.bottom-left{bottom:0;left:0}&.bottom-right{bottom:0;right:0}}.cim-widget-dialog.bottom-left,.cim-widget-dialog.bottom-right{animation:none}}@media(prefers-reduced-motion:reduce){.cim-widget-dialog.bottom-left,.cim-widget-dialog.bottom-right{animation:none}}@keyframes cim-widget-dialog-slide-in-right{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes cim-widget-dialog-slide-in-left{0%{transform:translate(-100%)}to{transform:translate(0)}}.cim-widget-modal-container{display:flex;align-items:center;justify-content:center;position:fixed;top:0;left:0;height:100dvh;width:100dvw;z-index:9999}.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;border-radius:var(--cim-widget-border-radius);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;padding:.5rem 1rem;margin-bottom:1rem;gap:8px;border-bottom:1px solid var(--cim-widget-border-color);background-color:var(--cim-widget-header-background-color)}.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;font-size:var(--cim-widget-header-text-font-size)}.cim-widget-modal-fullscreen-button,.cim-widget-modal-toggle-dialog-button{display:none}@media(max-width:576px){.cim-widget-modal{height:100%;width:100%;border-radius:0}}@media(min-width:576px){.cim-widget-modal-fullscreen-button,.cim-widget-modal-toggle-dialog-button{display:inline-flex}}.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}.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)}.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:var(--cim-widget-border-radius);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);border-radius:var(--cim-widget-border-radius);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}
2
+ /*$vite$:1*/`,document.head.appendChild(Fe);function We(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var rt={exports:{}},Et={},dt={exports:{}},Re={};var Rt;function Tt(){if(Rt)return Re;Rt=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"),a=Symbol.for("react.provider"),u=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),E=Symbol.iterator;function T(M){return M===null||typeof M!="object"?null:(M=E&&M[E]||M["@@iterator"],typeof M=="function"?M:null)}var b={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,w={};function A(M,X,k){this.props=M,this.context=X,this.refs=w,this.updater=k||b}A.prototype.isReactComponent={},A.prototype.setState=function(M,X){if(typeof M!="object"&&typeof M!="function"&&M!=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,M,X,"setState")},A.prototype.forceUpdate=function(M){this.updater.enqueueForceUpdate(this,M,"forceUpdate")};function C(){}C.prototype=A.prototype;function I(M,X,k){this.props=M,this.context=X,this.refs=w,this.updater=k||b}var R=I.prototype=new C;R.constructor=I,_(R,A.prototype),R.isPureReactComponent=!0;var F=Array.isArray,z=Object.prototype.hasOwnProperty,D={current:null},q={key:!0,ref:!0,__self:!0,__source:!0};function ce(M,X,k){var xe,Pe={},Oe=null,He=null;if(X!=null)for(xe in X.ref!==void 0&&(He=X.ref),X.key!==void 0&&(Oe=""+X.key),X)z.call(X,xe)&&!q.hasOwnProperty(xe)&&(Pe[xe]=X[xe]);var Se=arguments.length-2;if(Se===1)Pe.children=k;else if(1<Se){for(var Ve=Array(Se),ut=0;ut<Se;ut++)Ve[ut]=arguments[ut+2];Pe.children=Ve}if(M&&M.defaultProps)for(xe in Se=M.defaultProps,Se)Pe[xe]===void 0&&(Pe[xe]=Se[xe]);return{$$typeof:e,type:M,key:Oe,ref:He,props:Pe,_owner:D.current}}function be(M,X){return{$$typeof:e,type:M.type,key:X,ref:M.ref,props:M.props,_owner:M._owner}}function j(M){return typeof M=="object"&&M!==null&&M.$$typeof===e}function ae(M){var X={"=":"=0",":":"=2"};return"$"+M.replace(/[=:]/g,function(k){return X[k]})}var he=/\/+/g;function ge(M,X){return typeof M=="object"&&M!==null&&M.key!=null?ae(""+M.key):X.toString(36)}function ue(M,X,k,xe,Pe){var Oe=typeof M;(Oe==="undefined"||Oe==="boolean")&&(M=null);var He=!1;if(M===null)He=!0;else switch(Oe){case"string":case"number":He=!0;break;case"object":switch(M.$$typeof){case e:case t:He=!0}}if(He)return He=M,Pe=Pe(He),M=xe===""?"."+ge(He,0):xe,F(Pe)?(k="",M!=null&&(k=M.replace(he,"$&/")+"/"),ue(Pe,X,k,"",function(ut){return ut})):Pe!=null&&(j(Pe)&&(Pe=be(Pe,k+(!Pe.key||He&&He.key===Pe.key?"":(""+Pe.key).replace(he,"$&/")+"/")+M)),X.push(Pe)),1;if(He=0,xe=xe===""?".":xe+":",F(M))for(var Se=0;Se<M.length;Se++){Oe=M[Se];var Ve=xe+ge(Oe,Se);He+=ue(Oe,X,k,Ve,Pe)}else if(Ve=T(M),typeof Ve=="function")for(M=Ve.call(M),Se=0;!(Oe=M.next()).done;)Oe=Oe.value,Ve=xe+ge(Oe,Se++),He+=ue(Oe,X,k,Ve,Pe);else if(Oe==="object")throw X=String(M),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(M).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.");return He}function Te(M,X,k){if(M==null)return M;var xe=[],Pe=0;return ue(M,xe,"","",function(Oe){return X.call(k,Oe,Pe++)}),xe}function Ne(M){if(M._status===-1){var X=M._result;X=X(),X.then(function(k){(M._status===0||M._status===-1)&&(M._status=1,M._result=k)},function(k){(M._status===0||M._status===-1)&&(M._status=2,M._result=k)}),M._status===-1&&(M._status=0,M._result=X)}if(M._status===1)return M._result.default;throw M._result}var fe={current:null},K={transition:null},te={ReactCurrentDispatcher:fe,ReactCurrentBatchConfig:K,ReactCurrentOwner:D};function S(){throw Error("act(...) is not supported in production builds of React.")}return Re.Children={map:Te,forEach:function(M,X,k){Te(M,function(){X.apply(this,arguments)},k)},count:function(M){var X=0;return Te(M,function(){X++}),X},toArray:function(M){return Te(M,function(X){return X})||[]},only:function(M){if(!j(M))throw Error("React.Children.only expected to receive a single React element child.");return M}},Re.Component=A,Re.Fragment=n,Re.Profiler=o,Re.PureComponent=I,Re.StrictMode=r,Re.Suspense=d,Re.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=te,Re.act=S,Re.cloneElement=function(M,X,k){if(M==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+M+".");var xe=_({},M.props),Pe=M.key,Oe=M.ref,He=M._owner;if(X!=null){if(X.ref!==void 0&&(Oe=X.ref,He=D.current),X.key!==void 0&&(Pe=""+X.key),M.type&&M.type.defaultProps)var Se=M.type.defaultProps;for(Ve in X)z.call(X,Ve)&&!q.hasOwnProperty(Ve)&&(xe[Ve]=X[Ve]===void 0&&Se!==void 0?Se[Ve]:X[Ve])}var Ve=arguments.length-2;if(Ve===1)xe.children=k;else if(1<Ve){Se=Array(Ve);for(var ut=0;ut<Ve;ut++)Se[ut]=arguments[ut+2];xe.children=Se}return{$$typeof:e,type:M.type,key:Pe,ref:Oe,props:xe,_owner:He}},Re.createContext=function(M){return M={$$typeof:u,_currentValue:M,_currentValue2:M,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},M.Provider={$$typeof:a,_context:M},M.Consumer=M},Re.createElement=ce,Re.createFactory=function(M){var X=ce.bind(null,M);return X.type=M,X},Re.createRef=function(){return{current:null}},Re.forwardRef=function(M){return{$$typeof:c,render:M}},Re.isValidElement=j,Re.lazy=function(M){return{$$typeof:m,_payload:{_status:-1,_result:M},_init:Ne}},Re.memo=function(M,X){return{$$typeof:h,type:M,compare:X===void 0?null:X}},Re.startTransition=function(M){var X=K.transition;K.transition={};try{M()}finally{K.transition=X}},Re.unstable_act=S,Re.useCallback=function(M,X){return fe.current.useCallback(M,X)},Re.useContext=function(M){return fe.current.useContext(M)},Re.useDebugValue=function(){},Re.useDeferredValue=function(M){return fe.current.useDeferredValue(M)},Re.useEffect=function(M,X){return fe.current.useEffect(M,X)},Re.useId=function(){return fe.current.useId()},Re.useImperativeHandle=function(M,X,k){return fe.current.useImperativeHandle(M,X,k)},Re.useInsertionEffect=function(M,X){return fe.current.useInsertionEffect(M,X)},Re.useLayoutEffect=function(M,X){return fe.current.useLayoutEffect(M,X)},Re.useMemo=function(M,X){return fe.current.useMemo(M,X)},Re.useReducer=function(M,X,k){return fe.current.useReducer(M,X,k)},Re.useRef=function(M){return fe.current.useRef(M)},Re.useState=function(M){return fe.current.useState(M)},Re.useSyncExternalStore=function(M,X,k){return fe.current.useSyncExternalStore(M,X,k)},Re.useTransition=function(){return fe.current.useTransition()},Re.version="18.3.1",Re}var sn;function ao(){return sn||(sn=1,dt.exports=Tt()),dt.exports}var Ts;function Rc(){if(Ts)return Et;Ts=1;var e=ao(),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,a={key:!0,ref:!0,__self:!0,__source:!0};function u(c,d,h){var m,E={},T=null,b=null;h!==void 0&&(T=""+h),d.key!==void 0&&(T=""+d.key),d.ref!==void 0&&(b=d.ref);for(m in d)r.call(d,m)&&!a.hasOwnProperty(m)&&(E[m]=d[m]);if(c&&c.defaultProps)for(m in d=c.defaultProps,d)E[m]===void 0&&(E[m]=d[m]);return{$$typeof:t,type:c,key:T,ref:b,props:E,_owner:o.current}}return Et.Fragment=n,Et.jsx=u,Et.jsxs=u,Et}var $n;function Ox(){return $n||($n=1,rt.exports=Rc()),rt.exports}var L=Ox();const or=Object.create(null);or.open="0",or.close="1",or.ping="2",or.pong="3",or.message="4",or.upgrade="5",or.noop="6";const Za=Object.create(null);Object.keys(or).forEach(e=>{Za[or[e]]=e});const Pc={type:"error",data:"parser error"},tm=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",nm=typeof ArrayBuffer=="function",rm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Lc=({type:e,data:t},n,r)=>tm&&t instanceof Blob?n?r(t):im(t,r):nm&&(t instanceof ArrayBuffer||rm(t))?n?r(t):im(new Blob([t]),r):r(or[e]+(t||"")),im=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function om(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Dc;function Ix(e,t){if(tm&&e.data instanceof Blob)return e.data.arrayBuffer().then(om).then(t);if(nm&&(e.data instanceof ArrayBuffer||rm(e.data)))return t(om(e.data));Lc(e,!1,n=>{Dc||(Dc=new TextEncoder),t(Dc.encode(n))})}const sm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bs=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<sm.length;e++)bs[sm.charCodeAt(e)]=e;const Rx=e=>{let t=e.length*.75,n=e.length,r,o=0,a,u,c,d;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)a=bs[e.charCodeAt(r)],u=bs[e.charCodeAt(r+1)],c=bs[e.charCodeAt(r+2)],d=bs[e.charCodeAt(r+3)],m[o++]=a<<2|u>>4,m[o++]=(u&15)<<4|c>>2,m[o++]=(c&3)<<6|d&63;return h},Px=typeof ArrayBuffer=="function",Mc=(e,t)=>{if(typeof e!="string")return{type:"message",data:am(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:Lx(e.substring(1),t)}:Za[n]?e.length>1?{type:Za[n],data:e.substring(1)}:{type:Za[n]}:Pc},Lx=(e,t)=>{if(Px){const n=Rx(e);return am(n,t)}else return{base64:!0,data:e}},am=(e,t)=>t==="blob"?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,um="",Dx=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((a,u)=>{Lc(a,!1,c=>{r[u]=c,++o===n&&t(r.join(um))})})},Mx=(e,t)=>{const n=e.split(um),r=[];for(let o=0;o<n.length;o++){const a=Mc(n[o],t);if(r.push(a),a.type==="error")break}return r};function Fx(){return new TransformStream({transform(e,t){Ix(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 a=new DataView(o.buffer);a.setUint8(0,126),a.setUint16(1,r)}else{o=new Uint8Array(9);const a=new DataView(o.buffer);a.setUint8(0,127),a.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let Fc;function eu(e){return e.reduce((t,n)=>t+n.length,0)}function tu(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 Bx(e,t){Fc||(Fc=new TextDecoder);const n=[];let r=0,o=-1,a=!1;return new TransformStream({transform(u,c){for(n.push(u);;){if(r===0){if(eu(n)<1)break;const d=tu(n,1);a=(d[0]&128)===128,o=d[0]&127,o<126?r=3:o===126?r=1:r=2}else if(r===1){if(eu(n)<2)break;const d=tu(n,2);o=new DataView(d.buffer,d.byteOffset,d.length).getUint16(0),r=3}else if(r===2){if(eu(n)<8)break;const d=tu(n,8),h=new DataView(d.buffer,d.byteOffset,d.length),m=h.getUint32(0);if(m>Math.pow(2,21)-1){c.enqueue(Pc);break}o=m*Math.pow(2,32)+h.getUint32(4),r=3}else{if(eu(n)<o)break;const d=tu(n,o);c.enqueue(Mc(a?d:Fc.decode(d),t)),r=0}if(o===0||o>e){c.enqueue(Pc);break}}}})}const lm=4;function St(e){if(e)return Ux(e)}function Ux(e){for(var t in St.prototype)e[t]=St.prototype[t];return e}St.prototype.on=St.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},St.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},St.prototype.off=St.prototype.removeListener=St.prototype.removeAllListeners=St.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},St.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},St.prototype.emitReserved=St.prototype.emit,St.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},St.prototype.hasListeners=function(e){return!!this.listeners(e).length};const nu=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),On=typeof self!="undefined"?self:typeof window!="undefined"?window:Function("return this")(),Hx="arraybuffer";function NM(){}function cm(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const zx=On.setTimeout,jx=On.clearTimeout;function ru(e,t){t.useNativeTimers?(e.setTimeoutFn=zx.bind(On),e.clearTimeoutFn=jx.bind(On)):(e.setTimeoutFn=On.setTimeout.bind(On),e.clearTimeoutFn=On.clearTimeout.bind(On))}const $x=1.33;function Vx(e){return typeof e=="string"?Yx(e):Math.ceil((e.byteLength||e.size)*$x)}function Yx(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 dm(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Wx(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function qx(e){let t={},n=e.split("&");for(let r=0,o=n.length;r<o;r++){let a=n[r].split("=");t[decodeURIComponent(a[0])]=decodeURIComponent(a[1])}return t}class Gx extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Bc extends St{constructor(t){super(),this.writable=!1,ru(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 Gx(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=Mc(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&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=Wx(t);return n.length?"?"+n:""}}class Kx extends Bc{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)};Mx(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,Dx(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]=dm()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let fm=!1;try{fm=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const Qx=fm;function Xx(){}class Jx extends Kx{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,a)=>{this.onError("xhr post error",o,a)})}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 sr extends St{constructor(t,n,r){super(),this.createRequest=t,ru(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=cm(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=sr.requestsCount++,sr.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=Xx,t)try{this._xhr.abort()}catch(n){}typeof document!="undefined"&&delete sr.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(sr.requestsCount=0,sr.requests={},typeof document!="undefined"){if(typeof attachEvent=="function")attachEvent("onunload",hm);else if(typeof addEventListener=="function"){const e="onpagehide"in On?"pagehide":"unload";addEventListener(e,hm,!1)}}function hm(){for(let e in sr.requests)sr.requests.hasOwnProperty(e)&&sr.requests[e].abort()}const Zx=(function(){const e=pm({xdomain:!1});return e&&e.responseType!==null})();class e_ extends Jx{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=Zx&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new sr(pm,this.uri(),t)}}function pm(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||Qx))return new XMLHttpRequest}catch(n){}if(!t)try{return new On[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const mm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class t_ extends Bc{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=mm?{}:cm(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;Lc(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch(u){}o&&nu(()=>{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]=dm()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const Uc=On.WebSocket||On.MozWebSocket;class n_ extends t_{createSocket(t,n,r){return mm?new Uc(t,n,r):n?new Uc(t,n):new Uc(t)}doWrite(t,n){this.ws.send(n)}}class r_ extends Bc{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=Bx(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=Fx();o.readable.pipeTo(t.writable),this._writer=o.writable.getWriter();const a=()=>{r.read().then(({done:c,value:d})=>{c||(this.onPacket(d),a())}).catch(c=>{})};a();const u={type:"open"};this.query.sid&&(u.data=`{"sid":"${this.query.sid}"}`),this._writer.write(u).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&&nu(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const i_={websocket:n_,webtransport:r_,polling:e_},o_=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,s_=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Hc(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=o_.exec(e||""),a={},u=14;for(;u--;)a[s_[u]]=o[u]||"";return n!=-1&&r!=-1&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a.pathNames=a_(a,a.path),a.queryKey=u_(a,a.query),a}function a_(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 u_(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,a){o&&(n[o]=a)}),n}const zc=typeof addEventListener=="function"&&typeof removeEventListener=="function",iu=[];zc&&addEventListener("offline",()=>{iu.forEach(e=>e())},!1);class Hr extends St{constructor(t,n){if(super(),this.binaryType=Hx,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=Hc(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=Hc(n.host).host);ru(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=qx(this.opts.query)),zc&&(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"})},iu.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=lm,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&&Hr.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",Hr.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+=Vx(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,nu(()=>{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 a={type:t,data:n,options:r};this.emitReserved("packetCreate",a),this.writeBuffer.push(a),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(Hr.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(),zc&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=iu.indexOf(this._offlineEventListener);r!==-1&&iu.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Hr.protocol=lm;class l_ extends Hr{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;Hr.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;Hr.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 T=new Error("probe error");T.transport=n.name,this.emitReserved("upgradeError",T)}}))};function a(){r||(r=!0,m(),n.close(),n=null)}const u=E=>{const T=new Error("probe error: "+E);T.transport=n.name,a(),this.emitReserved("upgradeError",T)};function c(){u("transport closed")}function d(){u("socket closed")}function h(E){n&&E.name!==n.name&&a()}const m=()=>{n.removeListener("open",o),n.removeListener("error",u),n.removeListener("close",c),this.off("close",d),this.off("upgrading",h)};n.once("open",o),n.once("error",u),n.once("close",c),this.once("close",d),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 c_=class extends l_{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=>i_[o]).filter(o=>!!o)),super(t,r)}};function d_(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=Hc(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 a=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+a+":"+r.port+t,r.href=r.protocol+"://"+a+(n&&n.port===r.port?"":":"+r.port),r}const f_=typeof ArrayBuffer=="function",h_=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,gm=Object.prototype.toString,p_=typeof Blob=="function"||typeof Blob!="undefined"&&gm.call(Blob)==="[object BlobConstructor]",m_=typeof File=="function"||typeof File!="undefined"&&gm.call(File)==="[object FileConstructor]";function jc(e){return f_&&(e instanceof ArrayBuffer||h_(e))||p_&&e instanceof Blob||m_&&e instanceof File}function ou(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ou(e[n]))return!0;return!1}if(jc(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ou(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ou(e[n]))return!0;return!1}function g_(e){const t=[],n=e.data,r=e;return r.data=$c(n,t),r.attachments=t.length,{packet:r,buffers:t}}function $c(e,t){if(!e)return e;if(jc(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]=$c(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]=$c(e[r],t));return n}return e}function E_(e,t){return e.data=Vc(e.data,t),delete e.attachments,e}function Vc(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]=Vc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Vc(e[n],t));return e}const y_=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var Ge;(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"})(Ge||(Ge={}));class T_{constructor(t){this.replacer=t}encode(t){return(t.type===Ge.EVENT||t.type===Ge.ACK)&&ou(t)?this.encodeAsBinary({type:t.type===Ge.EVENT?Ge.BINARY_EVENT:Ge.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Ge.BINARY_EVENT||t.type===Ge.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=g_(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class Yc extends St{constructor(t){super(),this.opts=Object.assign({reviver:void 0,maxAttachments:10},typeof t=="function"?{reviver:t}: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===Ge.BINARY_EVENT;r||n.type===Ge.BINARY_ACK?(n.type=r?Ge.EVENT:Ge.ACK,this.reconstructor=new b_(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(jc(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(Ge[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Ge.BINARY_EVENT||r.type===Ge.BINARY_ACK){const a=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const u=t.substring(a,n);if(u!=Number(u)||t.charAt(n)!=="-")throw new Error("Illegal attachments");const c=Number(u);if(!x_(c)||c<0)throw new Error("Illegal attachments");if(c>this.opts.maxAttachments)throw new Error("too many attachments");r.attachments=c}if(t.charAt(n+1)==="/"){const a=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(a,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const a=n+1;for(;++n;){const u=t.charAt(n);if(u==null||Number(u)!=u){--n;break}if(n===t.length)break}r.id=Number(t.substring(a,n+1))}if(t.charAt(++n)){const a=this.tryParse(t.substr(n));if(Yc.isPayloadValid(r.type,a))r.data=a;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.opts.reviver)}catch(n){return!1}}static isPayloadValid(t,n){switch(t){case Ge.CONNECT:return Em(n);case Ge.DISCONNECT:return n===void 0;case Ge.CONNECT_ERROR:return typeof n=="string"||Em(n);case Ge.EVENT:case Ge.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&y_.indexOf(n[0])===-1);case Ge.ACK:case Ge.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class b_{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=E_(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const x_=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e};function Em(e){return Object.prototype.toString.call(e)==="[object Object]"}const __=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Yc,Encoder:T_,get PacketType(){return Ge}},Symbol.toStringTag,{value:"Module"}));function Vn(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const w_=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class ym extends St{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=[Vn(t,"open",this.onopen.bind(this)),Vn(t,"packet",this.onpacket.bind(this)),Vn(t,"error",this.onerror.bind(this)),Vn(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,a;if(w_.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 u={type:Ge.EVENT,data:n};if(u.options={},u.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const m=this.ids++,E=n.pop();this._registerAckCallback(m,E),u.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,d=this.connected&&!(!((a=this.io.engine)===null||a===void 0)&&a._hasPingExpired());return this.flags.volatile&&!c||(d?(this.notifyOutgoingListeners(u),this.packet(u)):this.sendBuffer.push(u)),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 a=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),u=(...c)=>{this.io.clearTimeoutFn(a),n.apply(this,c)};u.withError=!0,this.acks[t]=u}emitWithAck(t,...n){return new Promise((r,o)=>{const a=(u,c)=>u?o(u):r(c);a.withError=!0,n.push(a),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,...a)=>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,...a)),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:Ge.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 Ge.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 Ge.EVENT:case Ge.BINARY_EVENT:this.onevent(t);break;case Ge.ACK:case Ge.BINARY_ACK:this.onack(t);break;case Ge.DISCONNECT:this.ondisconnect();break;case Ge.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:Ge.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:Ge.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 uo(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}uo.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},uo.prototype.reset=function(){this.attempts=0},uo.prototype.setMin=function(e){this.ms=e},uo.prototype.setMax=function(e){this.max=e},uo.prototype.setJitter=function(e){this.jitter=e};class Wc extends St{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,ru(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 uo({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||__;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 c_(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=Vn(n,"open",function(){r.onopen(),t&&t()}),a=c=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",c),t?t(c):this.maybeReconnectOnOpen()},u=Vn(n,"error",a);if(this._timeout!==!1){const c=this._timeout,d=this.setTimeoutFn(()=>{o(),a(new Error("timeout")),n.close()},c);this.opts.autoUnref&&d.unref(),this.subs.push(()=>{this.clearTimeoutFn(d)})}return this.subs.push(o),this.subs.push(u),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Vn(t,"ping",this.onping.bind(this)),Vn(t,"data",this.ondata.bind(this)),Vn(t,"error",this.onerror.bind(this)),Vn(t,"close",this.onclose.bind(this)),Vn(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){nu(()=>{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 ym(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 xs={};function qc(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=d_(e,t.path||"/socket.io"),r=n.source,o=n.id,a=n.path,u=xs[o]&&a in xs[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||u;let d;return c?d=new Wc(r,t):(xs[o]||(xs[o]=new Wc(r,t)),d=xs[o]),n.query&&!t.query&&(t.query=n.queryKey),d.socket(n.path,t)}Object.assign(qc,{Manager:Wc,Socket:ym,io:qc,connect:qc});const Tm=Object.prototype.toString;typeof Blob=="function"||typeof Blob!="undefined"&&Tm.call(Blob),typeof File=="function"||typeof File!="undefined"&&Tm.call(File);var bm;(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"})(bm||(bm={}));var ee=ao();const bi=We(ee);class S_{constructor(){this.listeners=new Map,this.onceListeners=new Map}on(t,n){this.listeners.has(t)||this.listeners.set(t,new Set),this.listeners.get(t).add(n)}once(t,n){this.onceListeners.has(t)||this.onceListeners.set(t,new Set),this.onceListeners.get(t).add(n)}off(t,n){var r,o;return t?n?((r=this.listeners.get(t))==null||r.delete(n),void((o=this.onceListeners.get(t))==null?void 0:o.delete(n))):(this.listeners.delete(t),void this.onceListeners.delete(t)):(this.listeners.clear(),void this.onceListeners.clear())}emit(t,...n){const r=this.listeners.get(t);if(r)for(const a of r)try{a(...n)}catch(u){}const o=this.onceListeners.get(t);if(o){for(const a of o)try{a(...n)}catch(u){}this.onceListeners.delete(t)}}}class A_{constructor(t,n,r,o,a){this.url=t,this.headers=n,this.onEvent=r,this.onClose=o,this.logger=a,this.controller=null,this.reading=!1}connect(){return et(this,null,function*(){if(this.reading)return void this.logger.warn("SSE already connected, ignoring duplicate connect()");this.controller=new AbortController,this.reading=!0;const t=yield fetch(this.url,{method:"GET",headers:ne(U({},this.headers),{Accept:"text/event-stream","Cache-Control":"no-cache"}),signal:this.controller.signal});if(!t.ok){this.reading=!1;const n=yield t.text().catch(()=>t.statusText);throw new Error(`SSE connection failed (${t.status}): ${n}`)}if(!t.body)throw this.reading=!1,new Error("SSE response has no body stream");this.readStream(t.body)})}disconnect(){this.reading=!1,this.controller&&(this.controller.abort(),this.controller=null)}get isConnected(){return this.reading}readStream(t){return et(this,null,function*(){const n=t.getReader(),r=new TextDecoder;let o="";try{for(;this.reading;){const{value:a,done:u}=yield n.read();if(u)break;let c;for(o+=r.decode(a,{stream:!0}),o=o.replace(/\r\n/g,`
3
3
  `).replace(/\r/g,`
4
4
  `);(c=o.indexOf(`
5
5
 
6
6
  `))>=0;){const d=o.slice(0,c);o=o.slice(c+2),this.parseFrame(d)}}}catch(a){return a instanceof DOMException&&a.name==="AbortError"?void this.logger.debug("SSE stream aborted (intentional disconnect)"):(this.logger.error("SSE stream error:",a),this.reading=!1,void this.onClose(a instanceof Error?a.message:"Unknown stream error"))}finally{n.releaseLock()}this.reading=!1,this.logger.info("SSE stream ended"),this.onClose("stream_ended")})}parseFrame(t){let n="message";const r=[];for(const a of t.split(`
7
7
  `))if(a.startsWith("event:"))n=a.slice(6).trim();else if(a.startsWith("data:")){const u=a.slice(5);r.push(u.startsWith(" ")?u.slice(1):u)}else a.startsWith(":");if(r.length===0)return;const o=r.join(`
8
- `);this.logger.debug(`SSE event: ${n}`,o.slice(0,200)),this.onEvent(n,o)}}class xi extends Error{constructor(t,n="unknown",r){super(t,r),this.name="AgentforceClientError",this.type=n}}let C_=class extends xi{constructor(t,n,r,o){super(t,"api",o),this.name="AgentforceApiError",this.statusCode=n,this.responseBody=r}};class wm extends xi{constructor(t,n=1,r){super(t,"network",r),this.name="AgentforceNetworkError",this.attemptsMade=n}}let k_=class extends xi{constructor(t,n){super(t,"auth",n),this.name="AgentforceAuthError"}};class N_{constructor(t){this.prefix="[Agentforce]",this.enabled=t}info(t,...n){this.enabled&&console.log(`${this.prefix} ${t}`,...n)}warn(t,...n){this.enabled&&console.warn(`${this.prefix} ${t}`,...n)}error(t,...n){this.enabled&&console.error(`${this.prefix} ${t}`,...n)}debug(t,...n){this.enabled&&console.debug(`${this.prefix} ${t}`,...n)}}class O_ extends A_{constructor({baseURL:t,orgId:n,esDeveloperName:r,options:o={}}){var u,c,d,h,m,g,T;super(),this._accessToken=null,this._conversationId=null,this._isConnected=!1,this.sseReader=null,this.reconnectAttempts=0,this.reconnectTimeout=null,this.intentionalDisconnect=!1,this.baseURL=t.replace(/\/+$/,""),this.orgId=n,this.esDeveloperName=r;const a={maxRetries:(u=o.maxRetries)!=null?u:3,timeout:(c=o.timeout)!=null?c:15e3,maxReconnectAttempts:(d=o.maxReconnectAttempts)!=null?d:5,reconnectDelay:(h=o.reconnectDelay)!=null?h:2e3,enableLogging:(m=o.enableLogging)!=null?m:!1,platform:(g=o.platform)!=null?g:"Web",capabilitiesVersion:(T=o.capabilitiesVersion)!=null?T:"1"};this.maxRetries=a.maxRetries,this.timeout=a.timeout,this.maxReconnectAttempts=a.maxReconnectAttempts,this.reconnectDelay=a.reconnectDelay,this.platform=a.platform,this.capabilitiesVersion=a.capabilitiesVersion,this.logger=new N_(a.enableLogging),this.logger.info(`Client initialized for ${this.baseURL}`)}get isConnected(){return this._isConnected}get conversationId(){return this._conversationId}get accessToken(){return this._accessToken}connect(){return et(this,null,function*(){this.intentionalDisconnect=!1,this.reconnectAttempts=0,this.logger.info("Connecting..."),this._accessToken=yield this.fetchAccessToken(),this.logger.info("Access token acquired"),yield this.openSSE()})}disconnect(){this.intentionalDisconnect=!0,this.clearReconnectTimer(),this.closeSSE(),this._isConnected=!1,this.logger.info("Disconnected")}createConversation(t){return et(this,null,function*(){this.assertConnected();const n=crypto.randomUUID(),r={conversationId:n,esDeveloperName:this.esDeveloperName,routingAttributes:t!=null?t:{}};return yield this.executeRequest("POST","/iamessage/api/v2/conversation",r),this._conversationId=n,this.logger.info(`Conversation created: ${n}`),n})}sendMessage(t){return et(this,null,function*(){if(this.assertConnected(),!this._conversationId)throw new xi("No active conversation. Call createConversation() first.","unknown");const n=crypto.randomUUID(),r={message:{id:n,messageType:"StaticContentMessage",staticContent:{formatType:"Text",text:t}},esDeveloperName:this.esDeveloperName};yield this.executeRequest("POST",`/iamessage/api/v2/conversation/${this._conversationId}/message`,r),this.logger.debug(`Message sent: ${n}`)})}endConversation(){return et(this,null,function*(){if(!this._conversationId||!this._accessToken)return;const t=this._conversationId;this._conversationId=null;try{yield this.executeRequest("DELETE",`/iamessage/api/v2/conversation/${t}?esDeveloperName=${encodeURIComponent(this.esDeveloperName)}`),this.logger.info(`Conversation ended: ${t}`)}catch(n){this.logger.warn(`Failed to end conversation (best effort): ${n instanceof Error?n.message:String(n)}`)}})}openSSE(){return et(this,null,function*(){this.closeSSE();const t=`${this.baseURL}/eventrouter/v1/sse`,n={Authorization:`Bearer ${this._accessToken}`,"X-Org-Id":this.orgId};this.sseReader=new v_(t,n,(r,o)=>this.handleSSEEvent(r,o),r=>this.handleSSEClose(r),this.logger),yield this.sseReader.connect(),this._isConnected=!0,this.emit("connected"),this.logger.info("SSE stream connected")})}closeSSE(){this.sseReader&&(this.sseReader.disconnect(),this.sseReader=null)}handleSSEClose(t){this._isConnected=!1,this.emit("disconnected",{reason:t}),this.intentionalDisconnect||this.attemptReconnect()}attemptReconnect(){if(this.reconnectAttempts>=this.maxReconnectAttempts)return this.logger.error(`Max reconnect attempts (${this.maxReconnectAttempts}) reached.`),void this.emit("error",{code:"MAX_RECONNECT",message:`Failed to reconnect after ${this.maxReconnectAttempts} attempts`,recoverable:!1});this.reconnectAttempts++;const t=500*Math.random(),n=Math.min(this.reconnectDelay*Math.pow(2,this.reconnectAttempts-1)+t,3e4);this.logger.info(`Reconnecting in ${n.toFixed(0)}ms (attempt ${this.reconnectAttempts}/${this.maxReconnectAttempts})...`),this.emit("reconnecting",{attempt:this.reconnectAttempts,maxAttempts:this.maxReconnectAttempts}),this.reconnectTimeout=setTimeout(()=>et(this,null,function*(){try{if(this.intentionalDisconnect||(this._accessToken=yield this.fetchAccessToken(),this.intentionalDisconnect))return;yield this.openSSE(),this.reconnectAttempts=0,this.logger.info("Reconnected successfully")}catch(r){if(this.intentionalDisconnect)return;this.logger.error(`Reconnect attempt ${this.reconnectAttempts} failed: ${r instanceof Error?r.message:String(r)}`),this.attemptReconnect()}}),n)}clearReconnectTimer(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=null)}handleSSEEvent(t,n){if(t==="ping")return;let r;try{r=JSON.parse(n)}catch(o){return void this.logger.debug(`Non-JSON SSE event (${t}): ${n.slice(0,100)}`)}switch(t){case"CONVERSATION_ROUTING_RESULT":this.handleRoutingResult(r);break;case"CONVERSATION_MESSAGE":this.handleConversationMessage(r);break;case"CONVERSATION_STREAMING_TOKEN":this.handleStreamingToken(r);break;case"CONVERSATION_TYPING_STARTED_INDICATOR":this.handleTypingStarted(r);break;case"CONVERSATION_TYPING_STOPPED_INDICATOR":this.handleTypingStopped(r);break;case"CONVERSATION_PROGRESS_INDICATOR":this.handleProgressIndicator(r);break;case"CONVERSATION_PARTICIPANT_CHANGED":this.handleParticipantChanged(r);break;case"CONVERSATION_CLOSE_CONVERSATION":this.handleConversationClosed(r);break;default:this.logger.debug(`Unknown SSE event: ${t}`)}}handleRoutingResult(t){let n=t;t.conversationEntry&&(n=this.parseEntryPayload(t.conversationEntry));const r=n.failureType||n.routingFailureType||"",o=!r||r==="None"||r==="NO_ERROR";this.emit("routing_result",{conversationId:this._conversationId||"",isSuccessful:o,failureType:o?void 0:r,raw:n}),o||this.emit("error",{code:"ROUTING_FAILED",message:`Routing failed: ${r}`,recoverable:!1})}handleConversationMessage(t){var c;const n=t.conversationEntry;if(!n)return;const r=((c=n.sender)==null?void 0:c.role)||"";if(r==="EndUser"||r==="Customer")return;const o=this.parseEntryPayload(n),a=this.getNestedValue(o,"abstractMessage"),u=this.getNestedString(a,"staticContent","text")||this.getNestedString(a,"content","text")||"";u&&this.emit("message",{conversationId:this._conversationId||"",messageId:n.identifier||"",content:u,sender:{role:r,name:n.senderDisplayName},timestamp:n.transcriptedTimestamp||new Date().toISOString(),raw:o})}handleStreamingToken(t){const n=t.token||t.text||"";n&&this.emit("streaming_token",{conversationId:this._conversationId||"",token:String(n)})}handleTypingStarted(t){var n;this.emit("typing_started",{conversationId:this._conversationId||"",participant:(n=t.conversationEntry)!=null&&n.sender?{role:t.conversationEntry.sender.role||"",name:t.conversationEntry.senderDisplayName}:void 0})}handleTypingStopped(t){var n;this.emit("typing_stopped",{conversationId:this._conversationId||"",participant:(n=t.conversationEntry)!=null&&n.sender?{role:t.conversationEntry.sender.role||"",name:t.conversationEntry.senderDisplayName}:void 0})}handleProgressIndicator(t){const n=t.conversationEntry;if(!n)return;const r=this.parseEntryPayload(n),o=this.getNestedValue(r,"progressIndicator"),a=this.getNestedString(o,"progressMessage","text")||this.getNestedString(o,"progressMessage","content")||t.text||"";if(!a)return;const u=this.getNestedString(o,"indicatorType")||void 0;this.emit("progress_indicator",{conversationId:this._conversationId||"",message:String(a),indicatorType:u,raw:r})}handleParticipantChanged(t){var o,a,u,c,d,h,m;let n=t;t.conversationEntry&&(n=this.parseEntryPayload(t.conversationEntry));const r=n.entries;if(r&&r.length>0)for(const g of r){const T=g.participant,b=g.displayName||(T==null?void 0:T.displayName)||((o=t.conversationEntry)==null?void 0:o.senderDisplayName)||"Agent",x=(T==null?void 0:T.role)||((u=(a=t.conversationEntry)==null?void 0:a.sender)==null?void 0:u.role)||"",S=g.operation||g.event||"";this.emit("participant_changed",{conversationId:this._conversationId||"",participant:{role:x,name:b},action:this.normalizeParticipantAction(S)})}else{const g=((c=t.conversationEntry)==null?void 0:c.senderDisplayName)||n.participantName||((d=n.participant)==null?void 0:d.displayName)||"Agent",T=n.operation||n.event||"";this.emit("participant_changed",{conversationId:this._conversationId||"",participant:{role:((m=(h=t.conversationEntry)==null?void 0:h.sender)==null?void 0:m.role)||"",name:g},action:this.normalizeParticipantAction(T)})}}normalizeParticipantAction(t){const n=t.toLowerCase();return n&&n!=="add"&&n!=="join"&&n!=="joined"&&n!=="transfer"?n==="remove"||n==="left"||n==="leave"?"remove":t:"add"}handleConversationClosed(t){this.emit("conversation_closed",{conversationId:t.conversationId||this._conversationId||""}),this._conversationId=null}fetchAccessToken(){return et(this,null,function*(){const t={orgId:this.orgId,esDeveloperName:this.esDeveloperName,capabilitiesVersion:this.capabilitiesVersion,platform:this.platform},n=yield this.executeRequest("POST","/iamessage/api/v2/authorization/unauthenticated/access-token",t,{useAuth:!1});if(!n.accessToken)throw new k_("Token response missing accessToken field");return n.accessToken})}executeRequest(t,n,r,o){return et(this,null,function*(){const a=(o==null?void 0:o.useAuth)!==!1;let u=0;for(;;){let c;try{const d=new AbortController;c=setTimeout(()=>d.abort(),(o==null?void 0:o.timeout)||this.timeout);const h=U({"Content-Type":"application/json"},o==null?void 0:o.headers);a&&this._accessToken&&(h.Authorization=`Bearer ${this._accessToken}`);const m={method:t,headers:h,signal:(o==null?void 0:o.signal)||d.signal};r&&t==="POST"&&(m.body=JSON.stringify(r));const g=yield fetch(`${this.baseURL}${n}`,m);if(clearTimeout(c),!g.ok){const T=yield g.text().catch(()=>g.statusText);if(g.status===401&&a&&u===0){this.logger.info("Got 401 — refreshing token and retrying..."),this._accessToken=yield this.fetchAccessToken(),u++;continue}throw new C_(`Request ${t} ${n} failed (${g.status}): ${T}`,g.status,T)}return g.status===204||t==="DELETE"?{}:g.text().then(T=>T?JSON.parse(T):null)}catch(d){if(clearTimeout(c),d instanceof xi)throw d;if(d instanceof DOMException&&d.name==="AbortError")throw new wm("Request timeout exceeded",u+1,{cause:d});if(d instanceof TypeError){if(u<this.maxRetries){u++;const h=100*Math.random(),m=300*Math.pow(2,u-1)+h;this.logger.info(`Network error, retrying (${u}/${this.maxRetries}) in ${m.toFixed(0)}ms...`),yield new Promise(g=>setTimeout(g,m));continue}throw new wm(`Network error: ${d.message}`,u,{cause:d})}throw new xi(`Unexpected error: ${d instanceof Error?d.message:String(d)}`,"unknown",{cause:d instanceof Error?d:void 0})}}})}assertConnected(){if(!this._isConnected||!this._accessToken)throw new xi("Client is not connected. Call connect() first.","unknown")}parseEntryPayload(t){if(!t.entryPayload)return{};if(typeof t.entryPayload=="string")try{return JSON.parse(t.entryPayload)}catch(n){return{}}return t.entryPayload}getNestedValue(t,...n){let r=t;for(const o of n){if(r==null||typeof r!="object")return;r=r[o]}return r}getNestedString(t,...n){const r=this.getNestedValue(t,...n);return typeof r=="string"?r:""}}const J="cim-widget",Hr=`--${J}`,zr={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd",borderRadius:"0.25rem"},I_=(e=zr)=>({[`${Hr}-primary-color`]:e.primaryColor||zr.primaryColor,[`${Hr}-secondary-color`]:e.secondaryColor||zr.secondaryColor,[`${Hr}-font-color`]:e.fontColor||zr.fontColor,[`${Hr}-font-family`]:e.fontFamily||zr.fontFamily,[`${Hr}-background-color`]:e.backgroundColor||zr.backgroundColor,[`${Hr}-border-color`]:e.borderColor||zr.borderColor,[`${Hr}-border-radius`]:e.borderRadius||zr.borderRadius});function Am(e,t){return function(){return e.apply(t,arguments)}}const{toString:R_}=Object.prototype,{getPrototypeOf:su}=Object,{iterator:au,toStringTag:vm}=Symbol,uu=(e=>t=>{const n=R_.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Yn=e=>(e=e.toLowerCase(),t=>uu(t)===e),lu=e=>t=>typeof t===e,{isArray:uo}=Array,lo=lu("undefined");function _s(e){return e!==null&&!lo(e)&&e.constructor!==null&&!lo(e.constructor)&&sn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Cm=Yn("ArrayBuffer");function P_(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Cm(e.buffer),t}const L_=lu("string"),sn=lu("function"),km=lu("number"),Ss=e=>e!==null&&typeof e=="object",D_=e=>e===!0||e===!1,cu=e=>{if(uu(e)!=="object")return!1;const t=su(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(vm in e)&&!(au in e)},M_=e=>{if(!Ss(e)||_s(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},F_=Yn("Date"),B_=Yn("File"),U_=e=>!!(e&&typeof e.uri!="undefined"),H_=e=>e&&typeof e.getParts!="undefined",z_=Yn("Blob"),j_=Yn("FileList"),$_=e=>Ss(e)&&sn(e.pipe);function V_(){return typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:{}}const Nm=V_(),Om=typeof Nm.FormData!="undefined"?Nm.FormData:void 0,Y_=e=>{if(!e)return!1;if(Om&&e instanceof Om)return!0;const t=su(e);if(!t||t===Object.prototype||!sn(e.append))return!1;const n=uu(e);return n==="formdata"||n==="object"&&sn(e.toString)&&e.toString()==="[object FormData]"},W_=Yn("URLSearchParams"),[q_,G_,K_,Q_]=["ReadableStream","Request","Response","Headers"].map(Yn),X_=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function ws(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),uo(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(_s(e))return;const a=n?Object.getOwnPropertyNames(e):Object.keys(e),u=a.length;let c;for(r=0;r<u;r++)c=a[r],t.call(null,e[c],c,e)}}function Im(e,t){if(_s(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 _i=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,Rm=e=>!lo(e)&&e!==_i;function Gc(...e){const{caseless:t,skipUndefined:n}=Rm(this)&&this||{},r={},o=(a,u)=>{if(u==="__proto__"||u==="constructor"||u==="prototype")return;const c=t&&Im(r,u)||u,d=Kc(r,c)?r[c]:void 0;cu(d)&&cu(a)?r[c]=Gc(d,a):cu(a)?r[c]=Gc({},a):uo(a)?r[c]=a.slice():(!n||!lo(a))&&(r[c]=a)};for(let a=0,u=e.length;a<u;a++)e[a]&&ws(e[a],o);return r}const J_=(e,t,n,{allOwnKeys:r}={})=>(ws(t,(o,a)=>{n&&sn(o)?Object.defineProperty(e,a,{__proto__:null,value:Am(o,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,a,{__proto__:null,value:o,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),Z_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),eS=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),n&&Object.assign(e.prototype,n)},tS=(e,t,n,r)=>{let o,a,u;const c={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),a=o.length;a-- >0;)u=o[a],(!r||r(u,e,t))&&!c[u]&&(t[u]=e[u],c[u]=!0);e=n!==!1&&su(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},nS=(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},rS=e=>{if(!e)return null;if(uo(e))return e;let t=e.length;if(!km(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},iS=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&su(Uint8Array)),oS=(e,t)=>{const r=(e&&e[au]).call(e);let o;for(;(o=r.next())&&!o.done;){const a=o.value;t.call(e,a[0],a[1])}},sS=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},aS=Yn("HTMLFormElement"),uS=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Kc=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),lS=Yn("RegExp"),Pm=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};ws(n,(o,a)=>{let u;(u=t(o,a,e))!==!1&&(r[a]=u||o)}),Object.defineProperties(e,r)},cS=e=>{Pm(e,(t,n)=>{if(sn(e)&&["arguments","caller","callee"].includes(n))return!1;const r=e[n];if(sn(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+"'")})}})},dS=(e,t)=>{const n={},r=o=>{o.forEach(a=>{n[a]=!0})};return uo(e)?r(e):r(String(e).split(t)),n},fS=()=>{},hS=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function pS(e){return!!(e&&sn(e.append)&&e[vm]==="FormData"&&e[au])}const mS=e=>{const t=new WeakSet,n=r=>{if(Ss(r)){if(t.has(r))return;if(_s(r))return r;if(!("toJSON"in r)){t.add(r);const o=uo(r)?[]:{};return ws(r,(a,u)=>{const c=n(a);!lo(c)&&(o[u]=c)}),t.delete(r),o}}return r};return n(e)},gS=Yn("AsyncFunction"),ES=e=>e&&(Ss(e)||sn(e))&&sn(e.then)&&sn(e.catch),Lm=((e,t)=>e?setImmediate:t?((n,r)=>(_i.addEventListener("message",({source:o,data:a})=>{o===_i&&a===n&&r.length&&r.shift()()},!1),o=>{r.push(o),_i.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",sn(_i.postMessage)),yS=typeof queueMicrotask!="undefined"?queueMicrotask.bind(_i):typeof process!="undefined"&&process.nextTick||Lm,$={isArray:uo,isArrayBuffer:Cm,isBuffer:_s,isFormData:Y_,isArrayBufferView:P_,isString:L_,isNumber:km,isBoolean:D_,isObject:Ss,isPlainObject:cu,isEmptyObject:M_,isReadableStream:q_,isRequest:G_,isResponse:K_,isHeaders:Q_,isUndefined:lo,isDate:F_,isFile:B_,isReactNativeBlob:U_,isReactNative:H_,isBlob:z_,isRegExp:lS,isFunction:sn,isStream:$_,isURLSearchParams:W_,isTypedArray:iS,isFileList:j_,forEach:ws,merge:Gc,extend:J_,trim:X_,stripBOM:Z_,inherits:eS,toFlatObject:tS,kindOf:uu,kindOfTest:Yn,endsWith:nS,toArray:rS,forEachEntry:oS,matchAll:sS,isHTMLForm:aS,hasOwnProperty:Kc,hasOwnProp:Kc,reduceDescriptors:Pm,freezeMethods:cS,toObjectSet:dS,toCamelCase:uS,noop:fS,toFiniteNumber:hS,findKey:Im,global:_i,isContextDefined:Rm,isSpecCompliantForm:pS,toJSONObject:mS,isAsyncFn:gS,isThenable:ES,setImmediate:Lm,asap:yS,isIterable:e=>e!=null&&sn(e[au])},TS=$.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"]),bS=e=>{const t={};let n,r,o;return e&&e.split(`
9
- `).forEach(function(u){o=u.indexOf(":"),n=u.substring(0,o).trim().toLowerCase(),r=u.substring(o+1).trim(),!(!n||t[n]&&TS[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t};function xS(e){let t=0,n=e.length;for(;t<n;){const r=e.charCodeAt(t);if(r!==9&&r!==32)break;t+=1}for(;n>t;){const r=e.charCodeAt(n-1);if(r!==9&&r!==32)break;n-=1}return t===0&&n===e.length?e:e.slice(t,n)}const _S=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),SS=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Qc(e,t){return $.isArray(e)?e.map(n=>Qc(n,t)):xS(String(e).replace(t,""))}const wS=e=>Qc(e,_S),AS=e=>Qc(e,SS);function Dm(e){const t=Object.create(null);return $.forEach(e.toJSON(),(n,r)=>{t[r]=AS(n)}),t}const Mm=Symbol("internals");function As(e){return e&&String(e).trim().toLowerCase()}function du(e){return e===!1||e==null?e:$.isArray(e)?e.map(du):wS(String(e))}function vS(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 CS=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Xc(e,t,n,r,o){if($.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!$.isString(t)){if($.isString(r))return t.indexOf(r)!==-1;if($.isRegExp(r))return r.test(t)}}function kS(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function NS(e,t){const n=$.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{__proto__:null,value:function(o,a,u){return this[r].call(this,t,o,a,u)},configurable:!0})})}let Zt=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function a(c,d,h){const m=As(d);if(!m)throw new Error("header name must be a non-empty string");const g=$.findKey(o,m);(!g||o[g]===void 0||h===!0||h===void 0&&o[g]!==!1)&&(o[g||d]=du(c))}const u=(c,d)=>$.forEach(c,(h,m)=>a(h,m,d));if($.isPlainObject(t)||t instanceof this.constructor)u(t,n);else if($.isString(t)&&(t=t.trim())&&!CS(t))u(bS(t),n);else if($.isObject(t)&&$.isIterable(t)){let c={},d,h;for(const m of t){if(!$.isArray(m))throw TypeError("Object iterator must return a key-value pair");c[h=m[0]]=(d=c[h])?$.isArray(d)?[...d,m[1]]:[d,m[1]]:m[1]}u(c,n)}else t!=null&&a(n,t,r);return this}get(t,n){if(t=As(t),t){const r=$.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return vS(o);if($.isFunction(n))return n.call(this,o,r);if($.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=As(t),t){const r=$.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Xc(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function a(u){if(u=As(u),u){const c=$.findKey(r,u);c&&(!n||Xc(r,r[c],c,n))&&(delete r[c],o=!0)}}return $.isArray(t)?t.forEach(a):a(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const a=n[r];(!t||Xc(this,this[a],a,t,!0))&&(delete this[a],o=!0)}return o}normalize(t){const n=this,r={};return $.forEach(this,(o,a)=>{const u=$.findKey(r,a);if(u){n[u]=du(o),delete n[a];return}const c=t?kS(a):String(a).trim();c!==a&&delete n[a],n[c]=du(o),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return $.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&$.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(`
10
- `)}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[Mm]=this[Mm]={accessors:{}}).accessors,o=this.prototype;function a(u){const c=As(u);r[c]||(NS(o,u),r[c]=!0)}return $.isArray(t)?t.forEach(a):a(t),this}};Zt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),$.reduceDescriptors(Zt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),$.freezeMethods(Zt);const OS="[REDACTED ****]";function IS(e){if($.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if($.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function RS(e,t){const n=new Set(t.map(a=>String(a).toLowerCase())),r=[],o=a=>{if(a===null||typeof a!="object"||$.isBuffer(a))return a;if(r.indexOf(a)!==-1)return;a instanceof Zt&&(a=a.toJSON()),r.push(a);let u;if($.isArray(a))u=[],a.forEach((c,d)=>{const h=o(c);$.isUndefined(h)||(u[d]=h)});else{if(!$.isPlainObject(a)&&IS(a))return r.pop(),a;u=Object.create(null);for(const[c,d]of Object.entries(a)){const h=n.has(c.toLowerCase())?OS:o(d);$.isUndefined(h)||(u[c]=h)}}return r.pop(),u};return o(e)}let ve=class kx extends Error{static from(t,n,r,o,a,u){const c=new kx(t.message,n||t.code,r,o,a);return c.cause=t,c.name=t.name,t.status!=null&&c.status==null&&(c.status=t.status),u&&Object.assign(c,u),c}constructor(t,n,r,o,a){super(t),Object.defineProperty(this,"message",{__proto__:null,value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,n&&(this.code=n),r&&(this.config=r),o&&(this.request=o),a&&(this.response=a,this.status=a.status)}toJSON(){const t=this.config,n=t&&$.hasOwnProp(t,"redact")?t.redact:void 0,r=$.isArray(n)&&n.length>0?RS(t,n):$.toJSONObject(t);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:r,code:this.code,status:this.status}}};ve.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",ve.ERR_BAD_OPTION="ERR_BAD_OPTION",ve.ECONNABORTED="ECONNABORTED",ve.ETIMEDOUT="ETIMEDOUT",ve.ECONNREFUSED="ECONNREFUSED",ve.ERR_NETWORK="ERR_NETWORK",ve.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",ve.ERR_DEPRECATED="ERR_DEPRECATED",ve.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",ve.ERR_BAD_REQUEST="ERR_BAD_REQUEST",ve.ERR_CANCELED="ERR_CANCELED",ve.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",ve.ERR_INVALID_URL="ERR_INVALID_URL",ve.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const PS=null;function Jc(e){return $.isPlainObject(e)||$.isArray(e)}function Fm(e){return $.endsWith(e,"[]")?e.slice(0,-2):e}function Zc(e,t,n){return e?e.concat(t).map(function(o,a){return o=Fm(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function LS(e){return $.isArray(e)&&!e.some(Jc)}const DS=$.toFlatObject($,{},null,function(t){return/^is[A-Z]/.test(t)});function fu(e,t,n){if(!$.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=$.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(A,C){return!$.isUndefined(C[A])});const r=n.metaTokens,o=n.visitor||g,a=n.dots,u=n.indexes,c=n.Blob||typeof Blob!="undefined"&&Blob,d=n.maxDepth===void 0?100:n.maxDepth,h=c&&$.isSpecCompliantForm(t);if(!$.isFunction(o))throw new TypeError("visitor must be a function");function m(S){if(S===null)return"";if($.isDate(S))return S.toISOString();if($.isBoolean(S))return S.toString();if(!h&&$.isBlob(S))throw new ve("Blob is not supported. Use a Buffer instead.");return $.isArrayBuffer(S)||$.isTypedArray(S)?h&&typeof Blob=="function"?new Blob([S]):Buffer.from(S):S}function g(S,A,C){let O=S;if($.isReactNative(t)&&$.isReactNativeBlob(S))return t.append(Zc(C,A,a),m(S)),!1;if(S&&!C&&typeof S=="object"){if($.endsWith(A,"{}"))A=r?A:A.slice(0,-2),S=JSON.stringify(S);else if($.isArray(S)&&LS(S)||($.isFileList(S)||$.endsWith(A,"[]"))&&(O=$.toArray(S)))return A=Fm(A),O.forEach(function(F,z){!($.isUndefined(F)||F===null)&&t.append(u===!0?Zc([A],z,a):u===null?A:A+"[]",m(F))}),!1}return Jc(S)?!0:(t.append(Zc(C,A,a),m(S)),!1)}const T=[],b=Object.assign(DS,{defaultVisitor:g,convertValue:m,isVisitable:Jc});function x(S,A,C=0){if(!$.isUndefined(S)){if(C>d)throw new ve("Object is too deeply nested ("+C+" levels). Max depth: "+d,ve.ERR_FORM_DATA_DEPTH_EXCEEDED);if(T.indexOf(S)!==-1)throw Error("Circular reference detected in "+A.join("."));T.push(S),$.forEach(S,function(R,F){(!($.isUndefined(R)||R===null)&&o.call(t,R,$.isString(F)?F.trim():F,A,b))===!0&&x(R,A?A.concat(F):[F],C+1)}),T.pop()}}if(!$.isObject(e))throw new TypeError("data must be an object");return x(e),t}function Bm(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function ed(e,t){this._pairs=[],e&&fu(e,this,t)}const Um=ed.prototype;Um.append=function(t,n){this._pairs.push([t,n])},Um.toString=function(t){const n=t?function(r){return t.call(this,r,Bm)}:Bm;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function MS(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Hm(e,t,n){if(!t)return e;const r=n&&n.encode||MS,o=$.isFunction(n)?{serialize:n}:n,a=o&&o.serialize;let u;if(a?u=a(t,o):u=$.isURLSearchParams(t)?t.toString():new ed(t,o).toString(r),u){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class zm{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){$.forEach(this.handlers,function(r){r!==null&&t(r)})}}const td={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},FS={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:ed,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},nd=typeof window!="undefined"&&typeof document!="undefined",rd=typeof navigator=="object"&&navigator||void 0,BS=nd&&(!rd||["ReactNative","NativeScript","NS"].indexOf(rd.product)<0),US=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",HS=nd&&window.location.href||"http://localhost",Vt=U(U({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:nd,hasStandardBrowserEnv:BS,hasStandardBrowserWebWorkerEnv:US,navigator:rd,origin:HS},Symbol.toStringTag,{value:"Module"}))),FS);function zS(e,t){return fu(e,new Vt.classes.URLSearchParams,U({visitor:function(n,r,o,a){return Vt.isNode&&$.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function jS(e){return $.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function $S(e){const t={},n=Object.keys(e);let r;const o=n.length;let a;for(r=0;r<o;r++)a=n[r],t[a]=e[a];return t}function jm(e){function t(n,r,o,a){let u=n[a++];if(u==="__proto__")return!0;const c=Number.isFinite(+u),d=a>=n.length;return u=!u&&$.isArray(o)?o.length:u,d?($.hasOwnProp(o,u)?o[u]=$.isArray(o[u])?o[u].concat(r):[o[u],r]:o[u]=r,!c):((!$.hasOwnProp(o,u)||!$.isObject(o[u]))&&(o[u]=[]),t(n,r,o[u],a)&&$.isArray(o[u])&&(o[u]=$S(o[u])),!c)}if($.isFormData(e)&&$.isFunction(e.entries)){const n={};return $.forEachEntry(e,(r,o)=>{t(jS(r),o,n,0)}),n}return null}const co=(e,t)=>e!=null&&$.hasOwnProp(e,t)?e[t]:void 0;function VS(e,t,n){if($.isString(e))try{return(t||JSON.parse)(e),$.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const vs={transitional:td,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=$.isObject(t);if(a&&$.isHTMLForm(t)&&(t=new FormData(t)),$.isFormData(t))return o?JSON.stringify(jm(t)):t;if($.isArrayBuffer(t)||$.isBuffer(t)||$.isStream(t)||$.isFile(t)||$.isBlob(t)||$.isReadableStream(t))return t;if($.isArrayBufferView(t))return t.buffer;if($.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(a){const d=co(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return zS(t,d).toString();if((c=$.isFileList(t))||r.indexOf("multipart/form-data")>-1){const h=co(this,"env"),m=h&&h.FormData;return fu(c?{"files[]":t}:t,m&&new m,d)}}return a||o?(n.setContentType("application/json",!1),VS(t)):t}],transformResponse:[function(t){const n=co(this,"transitional")||vs.transitional,r=n&&n.forcedJSONParsing,o=co(this,"responseType"),a=o==="json";if($.isResponse(t)||$.isReadableStream(t))return t;if(t&&$.isString(t)&&(r&&!o||a)){const c=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(t,co(this,"parseReviver"))}catch(d){if(c)throw d.name==="SyntaxError"?ve.from(d,ve.ERR_BAD_RESPONSE,this,null,co(this,"response")):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Vt.classes.FormData,Blob:Vt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};$.forEach(["delete","get","head","post","put","patch","query"],e=>{vs.headers[e]={}});function id(e,t){const n=this||vs,r=t||n,o=Zt.from(r.headers);let a=r.data;return $.forEach(e,function(c){a=c.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function $m(e){return!!(e&&e.__CANCEL__)}let Cs=class extends ve{constructor(t,n,r){super(t==null?"canceled":t,ve.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function Vm(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ve("Request failed with status code "+n.status,n.status>=400&&n.status<500?ve.ERR_BAD_REQUEST:ve.ERR_BAD_RESPONSE,n.config,n.request,n))}function YS(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function WS(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,a=0,u;return t=t!==void 0?t:1e3,function(d){const h=Date.now(),m=r[a];u||(u=h),n[o]=d,r[o]=h;let g=a,T=0;for(;g!==o;)T+=n[g++],g=g%e;if(o=(o+1)%e,o===a&&(a=(a+1)%e),h-u<t)return;const b=m&&h-m;return b?Math.round(T*1e3/b):void 0}}function qS(e,t){let n=0,r=1e3/t,o,a;const u=(h,m=Date.now())=>{n=m,o=null,a&&(clearTimeout(a),a=null),e(...h)};return[(...h)=>{const m=Date.now(),g=m-n;g>=r?u(h,m):(o=h,a||(a=setTimeout(()=>{a=null,u(o)},r-g)))},()=>o&&u(o)]}const hu=(e,t,n=3)=>{let r=0;const o=WS(50,250);return qS(a=>{if(!a||typeof a.loaded!="number")return;const u=a.loaded,c=a.lengthComputable?a.total:void 0,d=c!=null?Math.min(u,c):u,h=Math.max(0,d-r),m=o(h);r=Math.max(r,d);const g={loaded:d,total:c,progress:c?d/c:void 0,bytes:h,rate:m||void 0,estimated:m&&c?(c-d)/m:void 0,event:a,lengthComputable:c!=null,[t?"download":"upload"]:!0};e(g)},n)},Ym=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Wm=e=>(...t)=>$.asap(()=>e(...t)),GS=Vt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Vt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Vt.origin),Vt.navigator&&/(msie|trident)/i.test(Vt.navigator.userAgent)):()=>!0,KS=Vt.hasStandardBrowserEnv?{write(e,t,n,r,o,a,u){if(typeof document=="undefined")return;const c=[`${e}=${encodeURIComponent(t)}`];$.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),$.isString(r)&&c.push(`path=${r}`),$.isString(o)&&c.push(`domain=${o}`),a===!0&&c.push("secure"),$.isString(u)&&c.push(`SameSite=${u}`),document.cookie=c.join("; ")},read(e){if(typeof document=="undefined")return null;const t=document.cookie.split(";");for(let n=0;n<t.length;n++){const r=t[n].replace(/^\s+/,""),o=r.indexOf("=");if(o!==-1&&r.slice(0,o)===e)return decodeURIComponent(r.slice(o+1))}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function QS(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function XS(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function qm(e,t,n){let r=!QS(t);return e&&(r||n===!1)?XS(e,t):t}const Gm=e=>e instanceof Zt?U({},e):e;function Si(e,t){t=t||{};const n=Object.create(null);Object.defineProperty(n,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(h,m,g,T){return $.isPlainObject(h)&&$.isPlainObject(m)?$.merge.call({caseless:T},h,m):$.isPlainObject(m)?$.merge({},m):$.isArray(m)?m.slice():m}function o(h,m,g,T){if($.isUndefined(m)){if(!$.isUndefined(h))return r(void 0,h,g,T)}else return r(h,m,g,T)}function a(h,m){if(!$.isUndefined(m))return r(void 0,m)}function u(h,m){if($.isUndefined(m)){if(!$.isUndefined(h))return r(void 0,h)}else return r(void 0,m)}function c(h,m,g){if($.hasOwnProp(t,g))return r(h,m);if($.hasOwnProp(e,g))return r(void 0,h)}const d={url:a,method:a,data:a,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,withXSRFToken:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,beforeRedirect:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,allowedSocketPaths:u,responseEncoding:u,validateStatus:c,headers:(h,m,g)=>o(Gm(h),Gm(m),g,!0)};return $.forEach(Object.keys(U(U({},e),t)),function(m){if(m==="__proto__"||m==="constructor"||m==="prototype")return;const g=$.hasOwnProp(d,m)?d[m]:o,T=$.hasOwnProp(e,m)?e[m]:void 0,b=$.hasOwnProp(t,m)?t[m]:void 0,x=g(T,b,m);$.isUndefined(x)&&g!==c||(n[m]=x)}),n}const JS=["content-type","content-length"];function ZS(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,o])=>{JS.includes(r.toLowerCase())&&e.set(r,o)})}const ew=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),Km=e=>{const t=Si({},e),n=T=>$.hasOwnProp(t,T)?t[T]:void 0,r=n("data");let o=n("withXSRFToken");const a=n("xsrfHeaderName"),u=n("xsrfCookieName");let c=n("headers");const d=n("auth"),h=n("baseURL"),m=n("allowAbsoluteUrls"),g=n("url");if(t.headers=c=Zt.from(c),t.url=Hm(qm(h,g,m),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?ew(d.password):""))),$.isFormData(r)&&(Vt.hasStandardBrowserEnv||Vt.hasStandardBrowserWebWorkerEnv?c.setContentType(void 0):$.isFunction(r.getHeaders)&&ZS(c,r.getHeaders(),n("formDataHeaderPolicy"))),Vt.hasStandardBrowserEnv&&($.isFunction(o)&&(o=o(t)),o===!0||o==null&&GS(t.url))){const b=a&&u&&KS.read(u);b&&c.set(a,b)}return t},tw=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=Km(e);let a=o.data;const u=Zt.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:h}=o,m,g,T,b,x;function S(){b&&b(),x&&x(),o.cancelToken&&o.cancelToken.unsubscribe(m),o.signal&&o.signal.removeEventListener("abort",m)}let A=new XMLHttpRequest;A.open(o.method.toUpperCase(),o.url,!0),A.timeout=o.timeout;function C(){if(!A)return;const R=Zt.from("getAllResponseHeaders"in A&&A.getAllResponseHeaders()),z={data:!c||c==="text"||c==="json"?A.responseText:A.response,status:A.status,statusText:A.statusText,headers:R,config:e,request:A};Vm(function(q){n(q),S()},function(q){r(q),S()},z),A=null}"onloadend"in A?A.onloadend=C:A.onreadystatechange=function(){!A||A.readyState!==4||A.status===0&&!(A.responseURL&&A.responseURL.startsWith("file:"))||setTimeout(C)},A.onabort=function(){A&&(r(new ve("Request aborted",ve.ECONNABORTED,e,A)),S(),A=null)},A.onerror=function(F){const z=F&&F.message?F.message:"Network Error",D=new ve(z,ve.ERR_NETWORK,e,A);D.event=F||null,r(D),S(),A=null},A.ontimeout=function(){let F=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const z=o.transitional||td;o.timeoutErrorMessage&&(F=o.timeoutErrorMessage),r(new ve(F,z.clarifyTimeoutError?ve.ETIMEDOUT:ve.ECONNABORTED,e,A)),S(),A=null},a===void 0&&u.setContentType(null),"setRequestHeader"in A&&$.forEach(Dm(u),function(F,z){A.setRequestHeader(z,F)}),$.isUndefined(o.withCredentials)||(A.withCredentials=!!o.withCredentials),c&&c!=="json"&&(A.responseType=o.responseType),h&&([T,x]=hu(h,!0),A.addEventListener("progress",T)),d&&A.upload&&([g,b]=hu(d),A.upload.addEventListener("progress",g),A.upload.addEventListener("loadend",b)),(o.cancelToken||o.signal)&&(m=R=>{A&&(r(!R||R.type?new Cs(null,e,A):R),A.abort(),S(),A=null)},o.cancelToken&&o.cancelToken.subscribe(m),o.signal&&(o.signal.aborted?m():o.signal.addEventListener("abort",m)));const O=YS(o.url);if(O&&!Vt.protocols.includes(O)){r(new ve("Unsupported protocol "+O+":",ve.ERR_BAD_REQUEST,e));return}A.send(a||null)})},nw=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;const n=new AbortController;let r=!1;const o=function(d){if(!r){r=!0,u();const h=d instanceof Error?d:this.reason;n.abort(h instanceof ve?h:new Cs(h instanceof Error?h.message:h))}};let a=t&&setTimeout(()=>{a=null,o(new ve(`timeout of ${t}ms exceeded`,ve.ETIMEDOUT))},t);const u=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(d=>{d.unsubscribe?d.unsubscribe(o):d.removeEventListener("abort",o)}),e=null)};e.forEach(d=>d.addEventListener("abort",o));const{signal:c}=n;return c.unsubscribe=()=>$.asap(u),c},rw=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},iw=function(e,t){return nm(this,null,function*(){try{for(var n=Cx(ow(e)),r,o,a;r=!(o=yield new oo(n.next())).done;r=!1){const u=o.value;yield*rm(rw(u,t))}}catch(o){a=[o]}finally{try{r&&(o=n.return)&&(yield new oo(o.call(n)))}finally{if(a)throw a[0]}}})},ow=function(e){return nm(this,null,function*(){if(e[Symbol.asyncIterator]){yield*rm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new oo(t.read());if(n)break;yield r}}finally{yield new oo(t.cancel())}})},Qm=(e,t,n,r)=>{const o=iw(e,t);let a=0,u,c=h=>{u||(u=!0,r&&r(h))};return new ReadableStream({pull(h){return et(this,null,function*(){try{const{done:m,value:g}=yield o.next();if(m){c(),h.close();return}let T=g.byteLength;if(n){let b=a+=T;n(b)}h.enqueue(new Uint8Array(g))}catch(m){throw c(m),m}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})};function sw(e){if(!e||typeof e!="string"||!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const n=e.slice(5,t),r=e.slice(t+1);if(/;base64/i.test(n)){let u=r.length;const c=r.length;for(let b=0;b<c;b++)if(r.charCodeAt(b)===37&&b+2<c){const x=r.charCodeAt(b+1),S=r.charCodeAt(b+2);(x>=48&&x<=57||x>=65&&x<=70||x>=97&&x<=102)&&(S>=48&&S<=57||S>=65&&S<=70||S>=97&&S<=102)&&(u-=2,b+=2)}let d=0,h=c-1;const m=b=>b>=2&&r.charCodeAt(b-2)===37&&r.charCodeAt(b-1)===51&&(r.charCodeAt(b)===68||r.charCodeAt(b)===100);h>=0&&(r.charCodeAt(h)===61?(d++,h--):m(h)&&(d++,h-=3)),d===1&&h>=0&&(r.charCodeAt(h)===61||m(h))&&d++;const T=Math.floor(u/4)*3-(d||0);return T>0?T:0}if(typeof Buffer!="undefined"&&typeof Buffer.byteLength=="function")return Buffer.byteLength(r,"utf8");let a=0;for(let u=0,c=r.length;u<c;u++){const d=r.charCodeAt(u);if(d<128)a+=1;else if(d<2048)a+=2;else if(d>=55296&&d<=56319&&u+1<c){const h=r.charCodeAt(u+1);h>=56320&&h<=57343?(a+=4,u++):a+=3}else a+=3}return a}const od="1.16.1",Xm=64*1024,{isFunction:pu}=$,Jm=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},aw=e=>{const t=$.global!==void 0&&$.global!==null?$.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=$.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:o,Request:a,Response:u}=e,c=o?pu(o):typeof fetch=="function",d=pu(a),h=pu(u);if(!c)return!1;const m=c&&pu(n),g=c&&(typeof r=="function"?(C=>O=>C.encode(O))(new r):C=>et(null,null,function*(){return new Uint8Array(yield new a(C).arrayBuffer())})),T=d&&m&&Jm(()=>{let C=!1;const O=new a(Vt.origin,{body:new n,method:"POST",get duplex(){return C=!0,"half"}}),R=O.headers.has("Content-Type");return O.body!=null&&O.body.cancel(),C&&!R}),b=h&&m&&Jm(()=>$.isReadableStream(new u("").body)),x={stream:b&&(C=>C.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(C=>{!x[C]&&(x[C]=(O,R)=>{let F=O&&O[C];if(F)return F.call(O);throw new ve(`Response type '${C}' is not supported`,ve.ERR_NOT_SUPPORT,R)})});const S=C=>et(null,null,function*(){if(C==null)return 0;if($.isBlob(C))return C.size;if($.isSpecCompliantForm(C))return(yield new a(Vt.origin,{method:"POST",body:C}).arrayBuffer()).byteLength;if($.isArrayBufferView(C)||$.isArrayBuffer(C))return C.byteLength;if($.isURLSearchParams(C)&&(C=C+""),$.isString(C))return(yield g(C)).byteLength}),A=(C,O)=>et(null,null,function*(){const R=$.toFiniteNumber(C.getContentLength());return R==null?S(O):R});return C=>et(null,null,function*(){let{url:O,method:R,data:F,signal:z,cancelToken:D,timeout:q,onDownloadProgress:ce,onUploadProgress:be,responseType:j,headers:ae,withCredentials:he="same-origin",fetchOptions:ge,maxContentLength:ue,maxBodyLength:Te}=Km(C);const Ne=$.isNumber(ue)&&ue>-1,fe=$.isNumber(Te)&&Te>-1;let K=o||fetch;j=j?(j+"").toLowerCase():"text";let te=nw([z,D&&D.toAbortSignal()],q),w=null;const M=te&&te.unsubscribe&&(()=>{te.unsubscribe()});let X;try{if(Ne&&typeof O=="string"&&O.startsWith("data:")&&sw(O)>ue)throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,w);if(fe&&R!=="get"&&R!=="head"){const we=yield A(ae,F);if(typeof we=="number"&&isFinite(we)&&we>Te)throw new ve("Request body larger than maxBodyLength limit",ve.ERR_BAD_REQUEST,C,w)}if(be&&T&&R!=="get"&&R!=="head"&&(X=yield A(ae,F))!==0){let we=new a(O,{method:"POST",body:F,duplex:"half"}),Ve;if($.isFormData(F)&&(Ve=we.headers.get("content-type"))&&ae.setContentType(Ve),we.body){const[ut,pn]=Ym(X,hu(Wm(be)));F=Qm(we.body,Xm,ut,pn)}}$.isString(he)||(he=he?"include":"omit");const k=d&&"credentials"in a.prototype;if($.isFormData(F)){const we=ae.getContentType();we&&/^multipart\/form-data/i.test(we)&&!/boundary=/i.test(we)&&ae.delete("content-type")}ae.set("User-Agent","axios/"+od,!1);const xe=ne(U({},ge),{signal:te,method:R.toUpperCase(),headers:Dm(ae.normalize()),body:F,duplex:"half",credentials:k?he:void 0});w=d&&new a(O,xe);let Pe=yield d?K(w,ge):K(O,xe);if(Ne){const we=$.toFiniteNumber(Pe.headers.get("content-length"));if(we!=null&&we>ue)throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,w)}const Oe=b&&(j==="stream"||j==="response");if(b&&Pe.body&&(ce||Ne||Oe&&M)){const we={};["status","statusText","headers"].forEach(Xn=>{we[Xn]=Pe[Xn]});const Ve=$.toFiniteNumber(Pe.headers.get("content-length")),[ut,pn]=ce&&Ym(Ve,hu(Wm(ce),!0))||[];let Vi=0;const Xr=Xn=>{if(Ne&&(Vi=Xn,Vi>ue))throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,w);ut&&ut(Xn)};Pe=new u(Qm(Pe.body,Xm,Xr,()=>{pn&&pn(),M&&M()}),we)}j=j||"text";let He=yield x[$.findKey(x,j)||"text"](Pe,C);if(Ne&&!b&&!Oe){let we;if(He!=null&&(typeof He.byteLength=="number"?we=He.byteLength:typeof He.size=="number"?we=He.size:typeof He=="string"&&(we=typeof r=="function"?new r().encode(He).byteLength:He.length)),typeof we=="number"&&we>ue)throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,w)}return!Oe&&M&&M(),yield new Promise((we,Ve)=>{Vm(we,Ve,{data:He,headers:Zt.from(Pe.headers),status:Pe.status,statusText:Pe.statusText,config:C,request:w})})}catch(k){if(M&&M(),te&&te.aborted&&te.reason instanceof ve){const xe=te.reason;throw xe.config=C,w&&(xe.request=w),k!==xe&&(xe.cause=k),xe}throw k&&k.name==="TypeError"&&/Load failed|fetch/i.test(k.message)?Object.assign(new ve("Network Error",ve.ERR_NETWORK,C,w,k&&k.response),{cause:k.cause||k}):ve.from(k,k&&k.code,C,w,k&&k.response)}})},uw=new Map,Zm=e=>{let t=e&&e.env||{};const{fetch:n,Request:r,Response:o}=t,a=[r,o,n];let u=a.length,c=u,d,h,m=uw;for(;c--;)d=a[c],h=m.get(d),h===void 0&&m.set(d,h=c?new Map:aw(t)),m=h;return h};Zm();const sd={http:PS,xhr:tw,fetch:{get:Zm}};$.forEach(sd,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(n){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const e0=e=>`- ${e}`,lw=e=>$.isFunction(e)||e===null||e===!1;function cw(e,t){e=$.isArray(e)?e:[e];const{length:n}=e;let r,o;const a={};for(let u=0;u<n;u++){r=e[u];let c;if(o=r,!lw(r)&&(o=sd[(c=String(r)).toLowerCase()],o===void 0))throw new ve(`Unknown adapter '${c}'`);if(o&&($.isFunction(o)||(o=o.get(t))))break;a[c||"#"+u]=o}if(!o){const u=Object.entries(a).map(([d,h])=>`adapter ${d} `+(h===!1?"is not supported by the environment":"is not available in the build"));let c=n?u.length>1?`since :
11
- `+u.map(e0).join(`
12
- `):" "+e0(u[0]):"as no adapter specified";throw new ve("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return o}const t0={getAdapter:cw,adapters:sd};function ad(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Cs(null,e)}function n0(e){return ad(e),e.headers=Zt.from(e.headers),e.data=id.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),t0.getAdapter(e.adapter||vs.adapter,e)(e).then(function(r){ad(e),e.response=r;try{r.data=id.call(e,e.transformResponse,r)}finally{delete e.response}return r.headers=Zt.from(r.headers),r},function(r){if(!$m(r)&&(ad(e),r&&r.response)){e.response=r.response;try{r.response.data=id.call(e,e.transformResponse,r.response)}finally{delete e.response}r.response.headers=Zt.from(r.response.headers)}return Promise.reject(r)})}const mu={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{mu[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const r0={};mu.transitional=function(t,n,r){function o(a,u){return"[Axios v"+od+"] Transitional option '"+a+"'"+u+(r?". "+r:"")}return(a,u,c)=>{if(t===!1)throw new ve(o(u," has been removed"+(n?" in "+n:"")),ve.ERR_DEPRECATED);return n&&!r0[u]&&(r0[u]=!0,console.warn(o(u," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,u,c):!0}},mu.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function dw(e,t,n){if(typeof e!="object")throw new ve("options must be an object",ve.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const a=r[o],u=Object.prototype.hasOwnProperty.call(t,a)?t[a]:void 0;if(u){const c=e[a],d=c===void 0||u(c,a,e);if(d!==!0)throw new ve("option "+a+" must be "+d,ve.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ve("Unknown option "+a,ve.ERR_BAD_OPTION)}}const gu={assertOptions:dw,validators:mu},In=gu.validators;let wi=class{constructor(t){this.defaults=t||{},this.interceptors={request:new zm,response:new zm}}request(t,n){return et(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 a=(()=>{if(!o.stack)return"";const u=o.stack.indexOf(`
8
+ `);this.logger.debug(`SSE event: ${n}`,o.slice(0,200)),this.onEvent(n,o)}}class xi extends Error{constructor(t,n="unknown",r){super(t,r),this.name="AgentforceClientError",this.type=n}}let v_=class extends xi{constructor(t,n,r,o){super(t,"api",o),this.name="AgentforceApiError",this.statusCode=n,this.responseBody=r}};class xm extends xi{constructor(t,n=1,r){super(t,"network",r),this.name="AgentforceNetworkError",this.attemptsMade=n}}let C_=class extends xi{constructor(t,n){super(t,"auth",n),this.name="AgentforceAuthError"}};class k_{constructor(t){this.prefix="[Agentforce]",this.enabled=t}info(t,...n){this.enabled&&console.log(`${this.prefix} ${t}`,...n)}warn(t,...n){this.enabled&&console.warn(`${this.prefix} ${t}`,...n)}error(t,...n){this.enabled&&console.error(`${this.prefix} ${t}`,...n)}debug(t,...n){this.enabled&&console.debug(`${this.prefix} ${t}`,...n)}}class N_ extends S_{constructor({baseURL:t,orgId:n,esDeveloperName:r,options:o={}}){var u,c,d,h,m,E,T;super(),this._accessToken=null,this._conversationId=null,this._isConnected=!1,this.sseReader=null,this.reconnectAttempts=0,this.reconnectTimeout=null,this.intentionalDisconnect=!1,this.baseURL=t.replace(/\/+$/,""),this.orgId=n,this.esDeveloperName=r;const a={maxRetries:(u=o.maxRetries)!=null?u:3,timeout:(c=o.timeout)!=null?c:15e3,maxReconnectAttempts:(d=o.maxReconnectAttempts)!=null?d:5,reconnectDelay:(h=o.reconnectDelay)!=null?h:2e3,enableLogging:(m=o.enableLogging)!=null?m:!1,platform:(E=o.platform)!=null?E:"Web",capabilitiesVersion:(T=o.capabilitiesVersion)!=null?T:"1"};this.maxRetries=a.maxRetries,this.timeout=a.timeout,this.maxReconnectAttempts=a.maxReconnectAttempts,this.reconnectDelay=a.reconnectDelay,this.platform=a.platform,this.capabilitiesVersion=a.capabilitiesVersion,this.logger=new k_(a.enableLogging),this.logger.info(`Client initialized for ${this.baseURL}`)}get isConnected(){return this._isConnected}get conversationId(){return this._conversationId}get accessToken(){return this._accessToken}connect(){return et(this,null,function*(){this.intentionalDisconnect=!1,this.reconnectAttempts=0,this.logger.info("Connecting..."),this._accessToken=yield this.fetchAccessToken(),this.logger.info("Access token acquired"),yield this.openSSE()})}disconnect(){this.intentionalDisconnect=!0,this.clearReconnectTimer(),this.closeSSE(),this._isConnected=!1,this.logger.info("Disconnected")}createConversation(t){return et(this,null,function*(){this.assertConnected();const n=crypto.randomUUID(),r={conversationId:n,esDeveloperName:this.esDeveloperName,routingAttributes:t!=null?t:{}};return yield this.executeRequest("POST","/iamessage/api/v2/conversation",r),this._conversationId=n,this.logger.info(`Conversation created: ${n}`),n})}sendMessage(t){return et(this,null,function*(){if(this.assertConnected(),!this._conversationId)throw new xi("No active conversation. Call createConversation() first.","unknown");const n=crypto.randomUUID(),r={message:{id:n,messageType:"StaticContentMessage",staticContent:{formatType:"Text",text:t}},esDeveloperName:this.esDeveloperName};yield this.executeRequest("POST",`/iamessage/api/v2/conversation/${this._conversationId}/message`,r),this.logger.debug(`Message sent: ${n}`)})}endConversation(){return et(this,null,function*(){if(!this._conversationId||!this._accessToken)return;const t=this._conversationId;this._conversationId=null;try{yield this.executeRequest("DELETE",`/iamessage/api/v2/conversation/${t}?esDeveloperName=${encodeURIComponent(this.esDeveloperName)}`),this.logger.info(`Conversation ended: ${t}`)}catch(n){this.logger.warn(`Failed to end conversation (best effort): ${n instanceof Error?n.message:String(n)}`)}})}openSSE(){return et(this,null,function*(){this.closeSSE();const t=`${this.baseURL}/eventrouter/v1/sse`,n={Authorization:`Bearer ${this._accessToken}`,"X-Org-Id":this.orgId};this.sseReader=new A_(t,n,(r,o)=>this.handleSSEEvent(r,o),r=>this.handleSSEClose(r),this.logger),yield this.sseReader.connect(),this._isConnected=!0,this.emit("connected"),this.logger.info("SSE stream connected")})}closeSSE(){this.sseReader&&(this.sseReader.disconnect(),this.sseReader=null)}handleSSEClose(t){this._isConnected=!1,this.emit("disconnected",{reason:t}),this.intentionalDisconnect||this.attemptReconnect()}attemptReconnect(){if(this.reconnectAttempts>=this.maxReconnectAttempts)return this.logger.error(`Max reconnect attempts (${this.maxReconnectAttempts}) reached.`),void this.emit("error",{code:"MAX_RECONNECT",message:`Failed to reconnect after ${this.maxReconnectAttempts} attempts`,recoverable:!1});this.reconnectAttempts++;const t=500*Math.random(),n=Math.min(this.reconnectDelay*Math.pow(2,this.reconnectAttempts-1)+t,3e4);this.logger.info(`Reconnecting in ${n.toFixed(0)}ms (attempt ${this.reconnectAttempts}/${this.maxReconnectAttempts})...`),this.emit("reconnecting",{attempt:this.reconnectAttempts,maxAttempts:this.maxReconnectAttempts}),this.reconnectTimeout=setTimeout(()=>et(this,null,function*(){try{if(this.intentionalDisconnect||(this._accessToken=yield this.fetchAccessToken(),this.intentionalDisconnect))return;yield this.openSSE(),this.reconnectAttempts=0,this.logger.info("Reconnected successfully")}catch(r){if(this.intentionalDisconnect)return;this.logger.error(`Reconnect attempt ${this.reconnectAttempts} failed: ${r instanceof Error?r.message:String(r)}`),this.attemptReconnect()}}),n)}clearReconnectTimer(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=null)}handleSSEEvent(t,n){if(t==="ping")return;let r;try{r=JSON.parse(n)}catch(o){return void this.logger.debug(`Non-JSON SSE event (${t}): ${n.slice(0,100)}`)}switch(t){case"CONVERSATION_ROUTING_RESULT":this.handleRoutingResult(r);break;case"CONVERSATION_MESSAGE":this.handleConversationMessage(r);break;case"CONVERSATION_STREAMING_TOKEN":this.handleStreamingToken(r);break;case"CONVERSATION_TYPING_STARTED_INDICATOR":this.handleTypingStarted(r);break;case"CONVERSATION_TYPING_STOPPED_INDICATOR":this.handleTypingStopped(r);break;case"CONVERSATION_PROGRESS_INDICATOR":this.handleProgressIndicator(r);break;case"CONVERSATION_PARTICIPANT_CHANGED":this.handleParticipantChanged(r);break;case"CONVERSATION_CLOSE_CONVERSATION":this.handleConversationClosed(r);break;default:this.logger.debug(`Unknown SSE event: ${t}`)}}handleRoutingResult(t){let n=t;t.conversationEntry&&(n=this.parseEntryPayload(t.conversationEntry));const r=n.failureType||n.routingFailureType||"",o=!r||r==="None"||r==="NO_ERROR";this.emit("routing_result",{conversationId:this._conversationId||"",isSuccessful:o,failureType:o?void 0:r,raw:n}),o||this.emit("error",{code:"ROUTING_FAILED",message:`Routing failed: ${r}`,recoverable:!1})}handleConversationMessage(t){var c;const n=t.conversationEntry;if(!n)return;const r=((c=n.sender)==null?void 0:c.role)||"";if(r==="EndUser"||r==="Customer")return;const o=this.parseEntryPayload(n),a=this.getNestedValue(o,"abstractMessage"),u=this.getNestedString(a,"staticContent","text")||this.getNestedString(a,"content","text")||"";u&&this.emit("message",{conversationId:this._conversationId||"",messageId:n.identifier||"",content:u,sender:{role:r,name:n.senderDisplayName},timestamp:n.transcriptedTimestamp||new Date().toISOString(),raw:o})}handleStreamingToken(t){const n=t.token||t.text||"";n&&this.emit("streaming_token",{conversationId:this._conversationId||"",token:String(n)})}handleTypingStarted(t){var n;this.emit("typing_started",{conversationId:this._conversationId||"",participant:(n=t.conversationEntry)!=null&&n.sender?{role:t.conversationEntry.sender.role||"",name:t.conversationEntry.senderDisplayName}:void 0})}handleTypingStopped(t){var n;this.emit("typing_stopped",{conversationId:this._conversationId||"",participant:(n=t.conversationEntry)!=null&&n.sender?{role:t.conversationEntry.sender.role||"",name:t.conversationEntry.senderDisplayName}:void 0})}handleProgressIndicator(t){const n=t.conversationEntry;if(!n)return;const r=this.parseEntryPayload(n),o=this.getNestedValue(r,"progressIndicator"),a=this.getNestedString(o,"progressMessage","text")||this.getNestedString(o,"progressMessage","content")||t.text||"";if(!a)return;const u=this.getNestedString(o,"indicatorType")||void 0;this.emit("progress_indicator",{conversationId:this._conversationId||"",message:String(a),indicatorType:u,raw:r})}handleParticipantChanged(t){var o,a,u,c,d,h,m;let n=t;t.conversationEntry&&(n=this.parseEntryPayload(t.conversationEntry));const r=n.entries;if(r&&r.length>0)for(const E of r){const T=E.participant,b=E.displayName||(T==null?void 0:T.displayName)||((o=t.conversationEntry)==null?void 0:o.senderDisplayName)||"Agent",_=(T==null?void 0:T.role)||((u=(a=t.conversationEntry)==null?void 0:a.sender)==null?void 0:u.role)||"",w=E.operation||E.event||"";this.emit("participant_changed",{conversationId:this._conversationId||"",participant:{role:_,name:b},action:this.normalizeParticipantAction(w)})}else{const E=((c=t.conversationEntry)==null?void 0:c.senderDisplayName)||n.participantName||((d=n.participant)==null?void 0:d.displayName)||"Agent",T=n.operation||n.event||"";this.emit("participant_changed",{conversationId:this._conversationId||"",participant:{role:((m=(h=t.conversationEntry)==null?void 0:h.sender)==null?void 0:m.role)||"",name:E},action:this.normalizeParticipantAction(T)})}}normalizeParticipantAction(t){const n=t.toLowerCase();return n&&n!=="add"&&n!=="join"&&n!=="joined"&&n!=="transfer"?n==="remove"||n==="left"||n==="leave"?"remove":t:"add"}handleConversationClosed(t){this.emit("conversation_closed",{conversationId:t.conversationId||this._conversationId||""}),this._conversationId=null}fetchAccessToken(){return et(this,null,function*(){const t={orgId:this.orgId,esDeveloperName:this.esDeveloperName,capabilitiesVersion:this.capabilitiesVersion,platform:this.platform},n=yield this.executeRequest("POST","/iamessage/api/v2/authorization/unauthenticated/access-token",t,{useAuth:!1});if(!n.accessToken)throw new C_("Token response missing accessToken field");return n.accessToken})}executeRequest(t,n,r,o){return et(this,null,function*(){const a=(o==null?void 0:o.useAuth)!==!1;let u=0;for(;;){let c;try{const d=new AbortController;c=setTimeout(()=>d.abort(),(o==null?void 0:o.timeout)||this.timeout);const h=U({"Content-Type":"application/json"},o==null?void 0:o.headers);a&&this._accessToken&&(h.Authorization=`Bearer ${this._accessToken}`);const m={method:t,headers:h,signal:(o==null?void 0:o.signal)||d.signal};r&&t==="POST"&&(m.body=JSON.stringify(r));const E=yield fetch(`${this.baseURL}${n}`,m);if(clearTimeout(c),!E.ok){const T=yield E.text().catch(()=>E.statusText);if(E.status===401&&a&&u===0){this.logger.info("Got 401 — refreshing token and retrying..."),this._accessToken=yield this.fetchAccessToken(),u++;continue}throw new v_(`Request ${t} ${n} failed (${E.status}): ${T}`,E.status,T)}return E.status===204||t==="DELETE"?{}:E.text().then(T=>T?JSON.parse(T):null)}catch(d){if(clearTimeout(c),d instanceof xi)throw d;if(d instanceof DOMException&&d.name==="AbortError")throw new xm("Request timeout exceeded",u+1,{cause:d});if(d instanceof TypeError){if(u<this.maxRetries){u++;const h=100*Math.random(),m=300*Math.pow(2,u-1)+h;this.logger.info(`Network error, retrying (${u}/${this.maxRetries}) in ${m.toFixed(0)}ms...`),yield new Promise(E=>setTimeout(E,m));continue}throw new xm(`Network error: ${d.message}`,u,{cause:d})}throw new xi(`Unexpected error: ${d instanceof Error?d.message:String(d)}`,"unknown",{cause:d instanceof Error?d:void 0})}}})}assertConnected(){if(!this._isConnected||!this._accessToken)throw new xi("Client is not connected. Call connect() first.","unknown")}parseEntryPayload(t){if(!t.entryPayload)return{};if(typeof t.entryPayload=="string")try{return JSON.parse(t.entryPayload)}catch(n){return{}}return t.entryPayload}getNestedValue(t,...n){let r=t;for(const o of n){if(r==null||typeof r!="object")return;r=r[o]}return r}getNestedString(t,...n){const r=this.getNestedValue(t,...n);return typeof r=="string"?r:""}}const J="cim-widget",Sr=`--${J}`,zr={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd",borderRadius:"0.25rem"},O_=(e=zr)=>({[`${Sr}-primary-color`]:e.primaryColor||zr.primaryColor,[`${Sr}-secondary-color`]:e.secondaryColor||zr.secondaryColor,[`${Sr}-font-color`]:e.fontColor||zr.fontColor,[`${Sr}-font-family`]:e.fontFamily||zr.fontFamily,[`${Sr}-background-color`]:e.backgroundColor||zr.backgroundColor,[`${Sr}-border-color`]:e.borderColor||zr.borderColor,[`${Sr}-border-radius`]:e.borderRadius||zr.borderRadius});function _m(e,t){return function(){return e.apply(t,arguments)}}const{toString:I_}=Object.prototype,{getPrototypeOf:su}=Object,{iterator:au,toStringTag:wm}=Symbol,uu=(e=>t=>{const n=I_.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Yn=e=>(e=e.toLowerCase(),t=>uu(t)===e),lu=e=>t=>typeof t===e,{isArray:lo}=Array,co=lu("undefined");function _s(e){return e!==null&&!co(e)&&e.constructor!==null&&!co(e.constructor)&&an(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Sm=Yn("ArrayBuffer");function R_(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Sm(e.buffer),t}const P_=lu("string"),an=lu("function"),Am=lu("number"),ws=e=>e!==null&&typeof e=="object",L_=e=>e===!0||e===!1,cu=e=>{if(uu(e)!=="object")return!1;const t=su(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(wm in e)&&!(au in e)},D_=e=>{if(!ws(e)||_s(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},M_=Yn("Date"),F_=Yn("File"),B_=e=>!!(e&&typeof e.uri!="undefined"),U_=e=>e&&typeof e.getParts!="undefined",H_=Yn("Blob"),z_=Yn("FileList"),j_=e=>ws(e)&&an(e.pipe);function $_(){return typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:{}}const vm=$_(),Cm=typeof vm.FormData!="undefined"?vm.FormData:void 0,V_=e=>{if(!e)return!1;if(Cm&&e instanceof Cm)return!0;const t=su(e);if(!t||t===Object.prototype||!an(e.append))return!1;const n=uu(e);return n==="formdata"||n==="object"&&an(e.toString)&&e.toString()==="[object FormData]"},Y_=Yn("URLSearchParams"),[W_,q_,G_,K_]=["ReadableStream","Request","Response","Headers"].map(Yn),Q_=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ss(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),lo(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(_s(e))return;const a=n?Object.getOwnPropertyNames(e):Object.keys(e),u=a.length;let c;for(r=0;r<u;r++)c=a[r],t.call(null,e[c],c,e)}}function km(e,t){if(_s(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 _i=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,Nm=e=>!co(e)&&e!==_i;function Gc(...e){const{caseless:t,skipUndefined:n}=Nm(this)&&this||{},r={},o=(a,u)=>{if(u==="__proto__"||u==="constructor"||u==="prototype")return;const c=t&&km(r,u)||u,d=Kc(r,c)?r[c]:void 0;cu(d)&&cu(a)?r[c]=Gc(d,a):cu(a)?r[c]=Gc({},a):lo(a)?r[c]=a.slice():(!n||!co(a))&&(r[c]=a)};for(let a=0,u=e.length;a<u;a++)e[a]&&Ss(e[a],o);return r}const X_=(e,t,n,{allOwnKeys:r}={})=>(Ss(t,(o,a)=>{n&&an(o)?Object.defineProperty(e,a,{__proto__:null,value:_m(o,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,a,{__proto__:null,value:o,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),J_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Z_=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),n&&Object.assign(e.prototype,n)},ew=(e,t,n,r)=>{let o,a,u;const c={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),a=o.length;a-- >0;)u=o[a],(!r||r(u,e,t))&&!c[u]&&(t[u]=e[u],c[u]=!0);e=n!==!1&&su(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},tw=(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},nw=e=>{if(!e)return null;if(lo(e))return e;let t=e.length;if(!Am(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},rw=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&su(Uint8Array)),iw=(e,t)=>{const r=(e&&e[au]).call(e);let o;for(;(o=r.next())&&!o.done;){const a=o.value;t.call(e,a[0],a[1])}},ow=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},sw=Yn("HTMLFormElement"),aw=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Kc=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),uw=Yn("RegExp"),Om=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Ss(n,(o,a)=>{let u;(u=t(o,a,e))!==!1&&(r[a]=u||o)}),Object.defineProperties(e,r)},lw=e=>{Om(e,(t,n)=>{if(an(e)&&["arguments","caller","callee"].includes(n))return!1;const r=e[n];if(an(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+"'")})}})},cw=(e,t)=>{const n={},r=o=>{o.forEach(a=>{n[a]=!0})};return lo(e)?r(e):r(String(e).split(t)),n},dw=()=>{},fw=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function hw(e){return!!(e&&an(e.append)&&e[wm]==="FormData"&&e[au])}const pw=e=>{const t=new WeakSet,n=r=>{if(ws(r)){if(t.has(r))return;if(_s(r))return r;if(!("toJSON"in r)){t.add(r);const o=lo(r)?[]:{};return Ss(r,(a,u)=>{const c=n(a);!co(c)&&(o[u]=c)}),t.delete(r),o}}return r};return n(e)},mw=Yn("AsyncFunction"),gw=e=>e&&(ws(e)||an(e))&&an(e.then)&&an(e.catch),Im=((e,t)=>e?setImmediate:t?((n,r)=>(_i.addEventListener("message",({source:o,data:a})=>{o===_i&&a===n&&r.length&&r.shift()()},!1),o=>{r.push(o),_i.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",an(_i.postMessage)),Ew=typeof queueMicrotask!="undefined"?queueMicrotask.bind(_i):typeof process!="undefined"&&process.nextTick||Im,$={isArray:lo,isArrayBuffer:Sm,isBuffer:_s,isFormData:V_,isArrayBufferView:R_,isString:P_,isNumber:Am,isBoolean:L_,isObject:ws,isPlainObject:cu,isEmptyObject:D_,isReadableStream:W_,isRequest:q_,isResponse:G_,isHeaders:K_,isUndefined:co,isDate:M_,isFile:F_,isReactNativeBlob:B_,isReactNative:U_,isBlob:H_,isRegExp:uw,isFunction:an,isStream:j_,isURLSearchParams:Y_,isTypedArray:rw,isFileList:z_,forEach:Ss,merge:Gc,extend:X_,trim:Q_,stripBOM:J_,inherits:Z_,toFlatObject:ew,kindOf:uu,kindOfTest:Yn,endsWith:tw,toArray:nw,forEachEntry:iw,matchAll:ow,isHTMLForm:sw,hasOwnProperty:Kc,hasOwnProp:Kc,reduceDescriptors:Om,freezeMethods:lw,toObjectSet:cw,toCamelCase:aw,noop:dw,toFiniteNumber:fw,findKey:km,global:_i,isContextDefined:Nm,isSpecCompliantForm:hw,toJSONObject:pw,isAsyncFn:mw,isThenable:gw,setImmediate:Im,asap:Ew,isIterable:e=>e!=null&&an(e[au])},yw=$.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"]),Tw=e=>{const t={};let n,r,o;return e&&e.split(`
9
+ `).forEach(function(u){o=u.indexOf(":"),n=u.substring(0,o).trim().toLowerCase(),r=u.substring(o+1).trim(),!(!n||t[n]&&yw[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t};function bw(e){let t=0,n=e.length;for(;t<n;){const r=e.charCodeAt(t);if(r!==9&&r!==32)break;t+=1}for(;n>t;){const r=e.charCodeAt(n-1);if(r!==9&&r!==32)break;n-=1}return t===0&&n===e.length?e:e.slice(t,n)}const xw=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),_w=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Qc(e,t){return $.isArray(e)?e.map(n=>Qc(n,t)):bw(String(e).replace(t,""))}const ww=e=>Qc(e,xw),Sw=e=>Qc(e,_w);function Rm(e){const t=Object.create(null);return $.forEach(e.toJSON(),(n,r)=>{t[r]=Sw(n)}),t}const Pm=Symbol("internals");function As(e){return e&&String(e).trim().toLowerCase()}function du(e){return e===!1||e==null?e:$.isArray(e)?e.map(du):ww(String(e))}function Aw(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 vw=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Xc(e,t,n,r,o){if($.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!$.isString(t)){if($.isString(r))return t.indexOf(r)!==-1;if($.isRegExp(r))return r.test(t)}}function Cw(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function kw(e,t){const n=$.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{__proto__:null,value:function(o,a,u){return this[r].call(this,t,o,a,u)},configurable:!0})})}let Zt=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function a(c,d,h){const m=As(d);if(!m)throw new Error("header name must be a non-empty string");const E=$.findKey(o,m);(!E||o[E]===void 0||h===!0||h===void 0&&o[E]!==!1)&&(o[E||d]=du(c))}const u=(c,d)=>$.forEach(c,(h,m)=>a(h,m,d));if($.isPlainObject(t)||t instanceof this.constructor)u(t,n);else if($.isString(t)&&(t=t.trim())&&!vw(t))u(Tw(t),n);else if($.isObject(t)&&$.isIterable(t)){let c={},d,h;for(const m of t){if(!$.isArray(m))throw TypeError("Object iterator must return a key-value pair");c[h=m[0]]=(d=c[h])?$.isArray(d)?[...d,m[1]]:[d,m[1]]:m[1]}u(c,n)}else t!=null&&a(n,t,r);return this}get(t,n){if(t=As(t),t){const r=$.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return Aw(o);if($.isFunction(n))return n.call(this,o,r);if($.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=As(t),t){const r=$.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Xc(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function a(u){if(u=As(u),u){const c=$.findKey(r,u);c&&(!n||Xc(r,r[c],c,n))&&(delete r[c],o=!0)}}return $.isArray(t)?t.forEach(a):a(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const a=n[r];(!t||Xc(this,this[a],a,t,!0))&&(delete this[a],o=!0)}return o}normalize(t){const n=this,r={};return $.forEach(this,(o,a)=>{const u=$.findKey(r,a);if(u){n[u]=du(o),delete n[a];return}const c=t?Cw(a):String(a).trim();c!==a&&delete n[a],n[c]=du(o),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return $.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&$.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(`
10
+ `)}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[Pm]=this[Pm]={accessors:{}}).accessors,o=this.prototype;function a(u){const c=As(u);r[c]||(kw(o,u),r[c]=!0)}return $.isArray(t)?t.forEach(a):a(t),this}};Zt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),$.reduceDescriptors(Zt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),$.freezeMethods(Zt);const Nw="[REDACTED ****]";function Ow(e){if($.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if($.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function Iw(e,t){const n=new Set(t.map(a=>String(a).toLowerCase())),r=[],o=a=>{if(a===null||typeof a!="object"||$.isBuffer(a))return a;if(r.indexOf(a)!==-1)return;a instanceof Zt&&(a=a.toJSON()),r.push(a);let u;if($.isArray(a))u=[],a.forEach((c,d)=>{const h=o(c);$.isUndefined(h)||(u[d]=h)});else{if(!$.isPlainObject(a)&&Ow(a))return r.pop(),a;u=Object.create(null);for(const[c,d]of Object.entries(a)){const h=n.has(c.toLowerCase())?Nw:o(d);$.isUndefined(h)||(u[c]=h)}}return r.pop(),u};return o(e)}let ve=class Cx extends Error{static from(t,n,r,o,a,u){const c=new Cx(t.message,n||t.code,r,o,a);return c.cause=t,c.name=t.name,t.status!=null&&c.status==null&&(c.status=t.status),u&&Object.assign(c,u),c}constructor(t,n,r,o,a){super(t),Object.defineProperty(this,"message",{__proto__:null,value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,n&&(this.code=n),r&&(this.config=r),o&&(this.request=o),a&&(this.response=a,this.status=a.status)}toJSON(){const t=this.config,n=t&&$.hasOwnProp(t,"redact")?t.redact:void 0,r=$.isArray(n)&&n.length>0?Iw(t,n):$.toJSONObject(t);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:r,code:this.code,status:this.status}}};ve.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",ve.ERR_BAD_OPTION="ERR_BAD_OPTION",ve.ECONNABORTED="ECONNABORTED",ve.ETIMEDOUT="ETIMEDOUT",ve.ECONNREFUSED="ECONNREFUSED",ve.ERR_NETWORK="ERR_NETWORK",ve.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",ve.ERR_DEPRECATED="ERR_DEPRECATED",ve.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",ve.ERR_BAD_REQUEST="ERR_BAD_REQUEST",ve.ERR_CANCELED="ERR_CANCELED",ve.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",ve.ERR_INVALID_URL="ERR_INVALID_URL",ve.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const Rw=null;function Jc(e){return $.isPlainObject(e)||$.isArray(e)}function Lm(e){return $.endsWith(e,"[]")?e.slice(0,-2):e}function Zc(e,t,n){return e?e.concat(t).map(function(o,a){return o=Lm(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function Pw(e){return $.isArray(e)&&!e.some(Jc)}const Lw=$.toFlatObject($,{},null,function(t){return/^is[A-Z]/.test(t)});function fu(e,t,n){if(!$.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=$.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(A,C){return!$.isUndefined(C[A])});const r=n.metaTokens,o=n.visitor||E,a=n.dots,u=n.indexes,c=n.Blob||typeof Blob!="undefined"&&Blob,d=n.maxDepth===void 0?100:n.maxDepth,h=c&&$.isSpecCompliantForm(t);if(!$.isFunction(o))throw new TypeError("visitor must be a function");function m(w){if(w===null)return"";if($.isDate(w))return w.toISOString();if($.isBoolean(w))return w.toString();if(!h&&$.isBlob(w))throw new ve("Blob is not supported. Use a Buffer instead.");return $.isArrayBuffer(w)||$.isTypedArray(w)?h&&typeof Blob=="function"?new Blob([w]):Buffer.from(w):w}function E(w,A,C){let I=w;if($.isReactNative(t)&&$.isReactNativeBlob(w))return t.append(Zc(C,A,a),m(w)),!1;if(w&&!C&&typeof w=="object"){if($.endsWith(A,"{}"))A=r?A:A.slice(0,-2),w=JSON.stringify(w);else if($.isArray(w)&&Pw(w)||($.isFileList(w)||$.endsWith(A,"[]"))&&(I=$.toArray(w)))return A=Lm(A),I.forEach(function(F,z){!($.isUndefined(F)||F===null)&&t.append(u===!0?Zc([A],z,a):u===null?A:A+"[]",m(F))}),!1}return Jc(w)?!0:(t.append(Zc(C,A,a),m(w)),!1)}const T=[],b=Object.assign(Lw,{defaultVisitor:E,convertValue:m,isVisitable:Jc});function _(w,A,C=0){if(!$.isUndefined(w)){if(C>d)throw new ve("Object is too deeply nested ("+C+" levels). Max depth: "+d,ve.ERR_FORM_DATA_DEPTH_EXCEEDED);if(T.indexOf(w)!==-1)throw Error("Circular reference detected in "+A.join("."));T.push(w),$.forEach(w,function(R,F){(!($.isUndefined(R)||R===null)&&o.call(t,R,$.isString(F)?F.trim():F,A,b))===!0&&_(R,A?A.concat(F):[F],C+1)}),T.pop()}}if(!$.isObject(e))throw new TypeError("data must be an object");return _(e),t}function Dm(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function ed(e,t){this._pairs=[],e&&fu(e,this,t)}const Mm=ed.prototype;Mm.append=function(t,n){this._pairs.push([t,n])},Mm.toString=function(t){const n=t?function(r){return t.call(this,r,Dm)}:Dm;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Dw(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Fm(e,t,n){if(!t)return e;const r=n&&n.encode||Dw,o=$.isFunction(n)?{serialize:n}:n,a=o&&o.serialize;let u;if(a?u=a(t,o):u=$.isURLSearchParams(t)?t.toString():new ed(t,o).toString(r),u){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class Bm{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){$.forEach(this.handlers,function(r){r!==null&&t(r)})}}const td={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},Mw={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:ed,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},nd=typeof window!="undefined"&&typeof document!="undefined",rd=typeof navigator=="object"&&navigator||void 0,Fw=nd&&(!rd||["ReactNative","NativeScript","NS"].indexOf(rd.product)<0),Bw=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Uw=nd&&window.location.href||"http://localhost",Vt=U(U({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:nd,hasStandardBrowserEnv:Fw,hasStandardBrowserWebWorkerEnv:Bw,navigator:rd,origin:Uw},Symbol.toStringTag,{value:"Module"}))),Mw);function Hw(e,t){return fu(e,new Vt.classes.URLSearchParams,U({visitor:function(n,r,o,a){return Vt.isNode&&$.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function zw(e){return $.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function jw(e){const t={},n=Object.keys(e);let r;const o=n.length;let a;for(r=0;r<o;r++)a=n[r],t[a]=e[a];return t}function Um(e){function t(n,r,o,a){let u=n[a++];if(u==="__proto__")return!0;const c=Number.isFinite(+u),d=a>=n.length;return u=!u&&$.isArray(o)?o.length:u,d?($.hasOwnProp(o,u)?o[u]=$.isArray(o[u])?o[u].concat(r):[o[u],r]:o[u]=r,!c):((!$.hasOwnProp(o,u)||!$.isObject(o[u]))&&(o[u]=[]),t(n,r,o[u],a)&&$.isArray(o[u])&&(o[u]=jw(o[u])),!c)}if($.isFormData(e)&&$.isFunction(e.entries)){const n={};return $.forEachEntry(e,(r,o)=>{t(zw(r),o,n,0)}),n}return null}const fo=(e,t)=>e!=null&&$.hasOwnProp(e,t)?e[t]:void 0;function $w(e,t,n){if($.isString(e))try{return(t||JSON.parse)(e),$.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const vs={transitional:td,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=$.isObject(t);if(a&&$.isHTMLForm(t)&&(t=new FormData(t)),$.isFormData(t))return o?JSON.stringify(Um(t)):t;if($.isArrayBuffer(t)||$.isBuffer(t)||$.isStream(t)||$.isFile(t)||$.isBlob(t)||$.isReadableStream(t))return t;if($.isArrayBufferView(t))return t.buffer;if($.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(a){const d=fo(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return Hw(t,d).toString();if((c=$.isFileList(t))||r.indexOf("multipart/form-data")>-1){const h=fo(this,"env"),m=h&&h.FormData;return fu(c?{"files[]":t}:t,m&&new m,d)}}return a||o?(n.setContentType("application/json",!1),$w(t)):t}],transformResponse:[function(t){const n=fo(this,"transitional")||vs.transitional,r=n&&n.forcedJSONParsing,o=fo(this,"responseType"),a=o==="json";if($.isResponse(t)||$.isReadableStream(t))return t;if(t&&$.isString(t)&&(r&&!o||a)){const c=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(t,fo(this,"parseReviver"))}catch(d){if(c)throw d.name==="SyntaxError"?ve.from(d,ve.ERR_BAD_RESPONSE,this,null,fo(this,"response")):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Vt.classes.FormData,Blob:Vt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};$.forEach(["delete","get","head","post","put","patch","query"],e=>{vs.headers[e]={}});function id(e,t){const n=this||vs,r=t||n,o=Zt.from(r.headers);let a=r.data;return $.forEach(e,function(c){a=c.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function Hm(e){return!!(e&&e.__CANCEL__)}let Cs=class extends ve{constructor(t,n,r){super(t==null?"canceled":t,ve.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function zm(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ve("Request failed with status code "+n.status,n.status>=400&&n.status<500?ve.ERR_BAD_REQUEST:ve.ERR_BAD_RESPONSE,n.config,n.request,n))}function Vw(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function Yw(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,a=0,u;return t=t!==void 0?t:1e3,function(d){const h=Date.now(),m=r[a];u||(u=h),n[o]=d,r[o]=h;let E=a,T=0;for(;E!==o;)T+=n[E++],E=E%e;if(o=(o+1)%e,o===a&&(a=(a+1)%e),h-u<t)return;const b=m&&h-m;return b?Math.round(T*1e3/b):void 0}}function Ww(e,t){let n=0,r=1e3/t,o,a;const u=(h,m=Date.now())=>{n=m,o=null,a&&(clearTimeout(a),a=null),e(...h)};return[(...h)=>{const m=Date.now(),E=m-n;E>=r?u(h,m):(o=h,a||(a=setTimeout(()=>{a=null,u(o)},r-E)))},()=>o&&u(o)]}const hu=(e,t,n=3)=>{let r=0;const o=Yw(50,250);return Ww(a=>{if(!a||typeof a.loaded!="number")return;const u=a.loaded,c=a.lengthComputable?a.total:void 0,d=c!=null?Math.min(u,c):u,h=Math.max(0,d-r),m=o(h);r=Math.max(r,d);const E={loaded:d,total:c,progress:c?d/c:void 0,bytes:h,rate:m||void 0,estimated:m&&c?(c-d)/m:void 0,event:a,lengthComputable:c!=null,[t?"download":"upload"]:!0};e(E)},n)},jm=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},$m=e=>(...t)=>$.asap(()=>e(...t)),qw=Vt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Vt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Vt.origin),Vt.navigator&&/(msie|trident)/i.test(Vt.navigator.userAgent)):()=>!0,Gw=Vt.hasStandardBrowserEnv?{write(e,t,n,r,o,a,u){if(typeof document=="undefined")return;const c=[`${e}=${encodeURIComponent(t)}`];$.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),$.isString(r)&&c.push(`path=${r}`),$.isString(o)&&c.push(`domain=${o}`),a===!0&&c.push("secure"),$.isString(u)&&c.push(`SameSite=${u}`),document.cookie=c.join("; ")},read(e){if(typeof document=="undefined")return null;const t=document.cookie.split(";");for(let n=0;n<t.length;n++){const r=t[n].replace(/^\s+/,""),o=r.indexOf("=");if(o!==-1&&r.slice(0,o)===e)return decodeURIComponent(r.slice(o+1))}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Kw(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Qw(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Vm(e,t,n){let r=!Kw(t);return e&&(r||n===!1)?Qw(e,t):t}const Ym=e=>e instanceof Zt?U({},e):e;function wi(e,t){t=t||{};const n=Object.create(null);Object.defineProperty(n,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(h,m,E,T){return $.isPlainObject(h)&&$.isPlainObject(m)?$.merge.call({caseless:T},h,m):$.isPlainObject(m)?$.merge({},m):$.isArray(m)?m.slice():m}function o(h,m,E,T){if($.isUndefined(m)){if(!$.isUndefined(h))return r(void 0,h,E,T)}else return r(h,m,E,T)}function a(h,m){if(!$.isUndefined(m))return r(void 0,m)}function u(h,m){if($.isUndefined(m)){if(!$.isUndefined(h))return r(void 0,h)}else return r(void 0,m)}function c(h,m,E){if($.hasOwnProp(t,E))return r(h,m);if($.hasOwnProp(e,E))return r(void 0,h)}const d={url:a,method:a,data:a,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,withXSRFToken:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,beforeRedirect:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,allowedSocketPaths:u,responseEncoding:u,validateStatus:c,headers:(h,m,E)=>o(Ym(h),Ym(m),E,!0)};return $.forEach(Object.keys(U(U({},e),t)),function(m){if(m==="__proto__"||m==="constructor"||m==="prototype")return;const E=$.hasOwnProp(d,m)?d[m]:o,T=$.hasOwnProp(e,m)?e[m]:void 0,b=$.hasOwnProp(t,m)?t[m]:void 0,_=E(T,b,m);$.isUndefined(_)&&E!==c||(n[m]=_)}),n}const Xw=["content-type","content-length"];function Jw(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,o])=>{Xw.includes(r.toLowerCase())&&e.set(r,o)})}const Zw=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),Wm=e=>{const t=wi({},e),n=T=>$.hasOwnProp(t,T)?t[T]:void 0,r=n("data");let o=n("withXSRFToken");const a=n("xsrfHeaderName"),u=n("xsrfCookieName");let c=n("headers");const d=n("auth"),h=n("baseURL"),m=n("allowAbsoluteUrls"),E=n("url");if(t.headers=c=Zt.from(c),t.url=Fm(Vm(h,E,m),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?Zw(d.password):""))),$.isFormData(r)&&(Vt.hasStandardBrowserEnv||Vt.hasStandardBrowserWebWorkerEnv?c.setContentType(void 0):$.isFunction(r.getHeaders)&&Jw(c,r.getHeaders(),n("formDataHeaderPolicy"))),Vt.hasStandardBrowserEnv&&($.isFunction(o)&&(o=o(t)),o===!0||o==null&&qw(t.url))){const b=a&&u&&Gw.read(u);b&&c.set(a,b)}return t},eS=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=Wm(e);let a=o.data;const u=Zt.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:h}=o,m,E,T,b,_;function w(){b&&b(),_&&_(),o.cancelToken&&o.cancelToken.unsubscribe(m),o.signal&&o.signal.removeEventListener("abort",m)}let A=new XMLHttpRequest;A.open(o.method.toUpperCase(),o.url,!0),A.timeout=o.timeout;function C(){if(!A)return;const R=Zt.from("getAllResponseHeaders"in A&&A.getAllResponseHeaders()),z={data:!c||c==="text"||c==="json"?A.responseText:A.response,status:A.status,statusText:A.statusText,headers:R,config:e,request:A};zm(function(q){n(q),w()},function(q){r(q),w()},z),A=null}"onloadend"in A?A.onloadend=C:A.onreadystatechange=function(){!A||A.readyState!==4||A.status===0&&!(A.responseURL&&A.responseURL.startsWith("file:"))||setTimeout(C)},A.onabort=function(){A&&(r(new ve("Request aborted",ve.ECONNABORTED,e,A)),w(),A=null)},A.onerror=function(F){const z=F&&F.message?F.message:"Network Error",D=new ve(z,ve.ERR_NETWORK,e,A);D.event=F||null,r(D),w(),A=null},A.ontimeout=function(){let F=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const z=o.transitional||td;o.timeoutErrorMessage&&(F=o.timeoutErrorMessage),r(new ve(F,z.clarifyTimeoutError?ve.ETIMEDOUT:ve.ECONNABORTED,e,A)),w(),A=null},a===void 0&&u.setContentType(null),"setRequestHeader"in A&&$.forEach(Rm(u),function(F,z){A.setRequestHeader(z,F)}),$.isUndefined(o.withCredentials)||(A.withCredentials=!!o.withCredentials),c&&c!=="json"&&(A.responseType=o.responseType),h&&([T,_]=hu(h,!0),A.addEventListener("progress",T)),d&&A.upload&&([E,b]=hu(d),A.upload.addEventListener("progress",E),A.upload.addEventListener("loadend",b)),(o.cancelToken||o.signal)&&(m=R=>{A&&(r(!R||R.type?new Cs(null,e,A):R),A.abort(),w(),A=null)},o.cancelToken&&o.cancelToken.subscribe(m),o.signal&&(o.signal.aborted?m():o.signal.addEventListener("abort",m)));const I=Vw(o.url);if(I&&!Vt.protocols.includes(I)){r(new ve("Unsupported protocol "+I+":",ve.ERR_BAD_REQUEST,e));return}A.send(a||null)})},tS=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;const n=new AbortController;let r=!1;const o=function(d){if(!r){r=!0,u();const h=d instanceof Error?d:this.reason;n.abort(h instanceof ve?h:new Cs(h instanceof Error?h.message:h))}};let a=t&&setTimeout(()=>{a=null,o(new ve(`timeout of ${t}ms exceeded`,ve.ETIMEDOUT))},t);const u=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(d=>{d.unsubscribe?d.unsubscribe(o):d.removeEventListener("abort",o)}),e=null)};e.forEach(d=>d.addEventListener("abort",o));const{signal:c}=n;return c.unsubscribe=()=>$.asap(u),c},nS=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},rS=function(e,t){return Zp(this,null,function*(){try{for(var n=vx(iS(e)),r,o,a;r=!(o=yield new so(n.next())).done;r=!1){const u=o.value;yield*em(nS(u,t))}}catch(o){a=[o]}finally{try{r&&(o=n.return)&&(yield new so(o.call(n)))}finally{if(a)throw a[0]}}})},iS=function(e){return Zp(this,null,function*(){if(e[Symbol.asyncIterator]){yield*em(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new so(t.read());if(n)break;yield r}}finally{yield new so(t.cancel())}})},qm=(e,t,n,r)=>{const o=rS(e,t);let a=0,u,c=h=>{u||(u=!0,r&&r(h))};return new ReadableStream({pull(h){return et(this,null,function*(){try{const{done:m,value:E}=yield o.next();if(m){c(),h.close();return}let T=E.byteLength;if(n){let b=a+=T;n(b)}h.enqueue(new Uint8Array(E))}catch(m){throw c(m),m}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})};function oS(e){if(!e||typeof e!="string"||!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const n=e.slice(5,t),r=e.slice(t+1);if(/;base64/i.test(n)){let u=r.length;const c=r.length;for(let b=0;b<c;b++)if(r.charCodeAt(b)===37&&b+2<c){const _=r.charCodeAt(b+1),w=r.charCodeAt(b+2);(_>=48&&_<=57||_>=65&&_<=70||_>=97&&_<=102)&&(w>=48&&w<=57||w>=65&&w<=70||w>=97&&w<=102)&&(u-=2,b+=2)}let d=0,h=c-1;const m=b=>b>=2&&r.charCodeAt(b-2)===37&&r.charCodeAt(b-1)===51&&(r.charCodeAt(b)===68||r.charCodeAt(b)===100);h>=0&&(r.charCodeAt(h)===61?(d++,h--):m(h)&&(d++,h-=3)),d===1&&h>=0&&(r.charCodeAt(h)===61||m(h))&&d++;const T=Math.floor(u/4)*3-(d||0);return T>0?T:0}if(typeof Buffer!="undefined"&&typeof Buffer.byteLength=="function")return Buffer.byteLength(r,"utf8");let a=0;for(let u=0,c=r.length;u<c;u++){const d=r.charCodeAt(u);if(d<128)a+=1;else if(d<2048)a+=2;else if(d>=55296&&d<=56319&&u+1<c){const h=r.charCodeAt(u+1);h>=56320&&h<=57343?(a+=4,u++):a+=3}else a+=3}return a}const od="1.16.1",Gm=64*1024,{isFunction:pu}=$,Km=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},sS=e=>{const t=$.global!==void 0&&$.global!==null?$.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=$.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:o,Request:a,Response:u}=e,c=o?pu(o):typeof fetch=="function",d=pu(a),h=pu(u);if(!c)return!1;const m=c&&pu(n),E=c&&(typeof r=="function"?(C=>I=>C.encode(I))(new r):C=>et(null,null,function*(){return new Uint8Array(yield new a(C).arrayBuffer())})),T=d&&m&&Km(()=>{let C=!1;const I=new a(Vt.origin,{body:new n,method:"POST",get duplex(){return C=!0,"half"}}),R=I.headers.has("Content-Type");return I.body!=null&&I.body.cancel(),C&&!R}),b=h&&m&&Km(()=>$.isReadableStream(new u("").body)),_={stream:b&&(C=>C.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(C=>{!_[C]&&(_[C]=(I,R)=>{let F=I&&I[C];if(F)return F.call(I);throw new ve(`Response type '${C}' is not supported`,ve.ERR_NOT_SUPPORT,R)})});const w=C=>et(null,null,function*(){if(C==null)return 0;if($.isBlob(C))return C.size;if($.isSpecCompliantForm(C))return(yield new a(Vt.origin,{method:"POST",body:C}).arrayBuffer()).byteLength;if($.isArrayBufferView(C)||$.isArrayBuffer(C))return C.byteLength;if($.isURLSearchParams(C)&&(C=C+""),$.isString(C))return(yield E(C)).byteLength}),A=(C,I)=>et(null,null,function*(){const R=$.toFiniteNumber(C.getContentLength());return R==null?w(I):R});return C=>et(null,null,function*(){let{url:I,method:R,data:F,signal:z,cancelToken:D,timeout:q,onDownloadProgress:ce,onUploadProgress:be,responseType:j,headers:ae,withCredentials:he="same-origin",fetchOptions:ge,maxContentLength:ue,maxBodyLength:Te}=Wm(C);const Ne=$.isNumber(ue)&&ue>-1,fe=$.isNumber(Te)&&Te>-1;let K=o||fetch;j=j?(j+"").toLowerCase():"text";let te=tS([z,D&&D.toAbortSignal()],q),S=null;const M=te&&te.unsubscribe&&(()=>{te.unsubscribe()});let X;try{if(Ne&&typeof I=="string"&&I.startsWith("data:")&&oS(I)>ue)throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,S);if(fe&&R!=="get"&&R!=="head"){const Se=yield A(ae,F);if(typeof Se=="number"&&isFinite(Se)&&Se>Te)throw new ve("Request body larger than maxBodyLength limit",ve.ERR_BAD_REQUEST,C,S)}if(be&&T&&R!=="get"&&R!=="head"&&(X=yield A(ae,F))!==0){let Se=new a(I,{method:"POST",body:F,duplex:"half"}),Ve;if($.isFormData(F)&&(Ve=Se.headers.get("content-type"))&&ae.setContentType(Ve),Se.body){const[ut,pn]=jm(X,hu($m(be)));F=qm(Se.body,Gm,ut,pn)}}$.isString(he)||(he=he?"include":"omit");const k=d&&"credentials"in a.prototype;if($.isFormData(F)){const Se=ae.getContentType();Se&&/^multipart\/form-data/i.test(Se)&&!/boundary=/i.test(Se)&&ae.delete("content-type")}ae.set("User-Agent","axios/"+od,!1);const xe=ne(U({},ge),{signal:te,method:R.toUpperCase(),headers:Rm(ae.normalize()),body:F,duplex:"half",credentials:k?he:void 0});S=d&&new a(I,xe);let Pe=yield d?K(S,ge):K(I,xe);if(Ne){const Se=$.toFiniteNumber(Pe.headers.get("content-length"));if(Se!=null&&Se>ue)throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,S)}const Oe=b&&(j==="stream"||j==="response");if(b&&Pe.body&&(ce||Ne||Oe&&M)){const Se={};["status","statusText","headers"].forEach(Xn=>{Se[Xn]=Pe[Xn]});const Ve=$.toFiniteNumber(Pe.headers.get("content-length")),[ut,pn]=ce&&jm(Ve,hu($m(ce),!0))||[];let Yi=0;const Xr=Xn=>{if(Ne&&(Yi=Xn,Yi>ue))throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,S);ut&&ut(Xn)};Pe=new u(qm(Pe.body,Gm,Xr,()=>{pn&&pn(),M&&M()}),Se)}j=j||"text";let He=yield _[$.findKey(_,j)||"text"](Pe,C);if(Ne&&!b&&!Oe){let Se;if(He!=null&&(typeof He.byteLength=="number"?Se=He.byteLength:typeof He.size=="number"?Se=He.size:typeof He=="string"&&(Se=typeof r=="function"?new r().encode(He).byteLength:He.length)),typeof Se=="number"&&Se>ue)throw new ve("maxContentLength size of "+ue+" exceeded",ve.ERR_BAD_RESPONSE,C,S)}return!Oe&&M&&M(),yield new Promise((Se,Ve)=>{zm(Se,Ve,{data:He,headers:Zt.from(Pe.headers),status:Pe.status,statusText:Pe.statusText,config:C,request:S})})}catch(k){if(M&&M(),te&&te.aborted&&te.reason instanceof ve){const xe=te.reason;throw xe.config=C,S&&(xe.request=S),k!==xe&&(xe.cause=k),xe}throw k&&k.name==="TypeError"&&/Load failed|fetch/i.test(k.message)?Object.assign(new ve("Network Error",ve.ERR_NETWORK,C,S,k&&k.response),{cause:k.cause||k}):ve.from(k,k&&k.code,C,S,k&&k.response)}})},aS=new Map,Qm=e=>{let t=e&&e.env||{};const{fetch:n,Request:r,Response:o}=t,a=[r,o,n];let u=a.length,c=u,d,h,m=aS;for(;c--;)d=a[c],h=m.get(d),h===void 0&&m.set(d,h=c?new Map:sS(t)),m=h;return h};Qm();const sd={http:Rw,xhr:eS,fetch:{get:Qm}};$.forEach(sd,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(n){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const Xm=e=>`- ${e}`,uS=e=>$.isFunction(e)||e===null||e===!1;function lS(e,t){e=$.isArray(e)?e:[e];const{length:n}=e;let r,o;const a={};for(let u=0;u<n;u++){r=e[u];let c;if(o=r,!uS(r)&&(o=sd[(c=String(r)).toLowerCase()],o===void 0))throw new ve(`Unknown adapter '${c}'`);if(o&&($.isFunction(o)||(o=o.get(t))))break;a[c||"#"+u]=o}if(!o){const u=Object.entries(a).map(([d,h])=>`adapter ${d} `+(h===!1?"is not supported by the environment":"is not available in the build"));let c=n?u.length>1?`since :
11
+ `+u.map(Xm).join(`
12
+ `):" "+Xm(u[0]):"as no adapter specified";throw new ve("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return o}const Jm={getAdapter:lS,adapters:sd};function ad(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Cs(null,e)}function Zm(e){return ad(e),e.headers=Zt.from(e.headers),e.data=id.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Jm.getAdapter(e.adapter||vs.adapter,e)(e).then(function(r){ad(e),e.response=r;try{r.data=id.call(e,e.transformResponse,r)}finally{delete e.response}return r.headers=Zt.from(r.headers),r},function(r){if(!Hm(r)&&(ad(e),r&&r.response)){e.response=r.response;try{r.response.data=id.call(e,e.transformResponse,r.response)}finally{delete e.response}r.response.headers=Zt.from(r.response.headers)}return Promise.reject(r)})}const mu={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{mu[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const e0={};mu.transitional=function(t,n,r){function o(a,u){return"[Axios v"+od+"] Transitional option '"+a+"'"+u+(r?". "+r:"")}return(a,u,c)=>{if(t===!1)throw new ve(o(u," has been removed"+(n?" in "+n:"")),ve.ERR_DEPRECATED);return n&&!e0[u]&&(e0[u]=!0,console.warn(o(u," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,u,c):!0}},mu.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function cS(e,t,n){if(typeof e!="object")throw new ve("options must be an object",ve.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const a=r[o],u=Object.prototype.hasOwnProperty.call(t,a)?t[a]:void 0;if(u){const c=e[a],d=c===void 0||u(c,a,e);if(d!==!0)throw new ve("option "+a+" must be "+d,ve.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ve("Unknown option "+a,ve.ERR_BAD_OPTION)}}const gu={assertOptions:cS,validators:mu},In=gu.validators;let Si=class{constructor(t){this.defaults=t||{},this.interceptors={request:new Bm,response:new Bm}}request(t,n){return et(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 a=(()=>{if(!o.stack)return"";const u=o.stack.indexOf(`
13
13
  `);return u===-1?"":o.stack.slice(u+1)})();try{if(!r.stack)r.stack=a;else if(a){const u=a.indexOf(`
14
14
  `),c=u===-1?-1:a.indexOf(`
15
15
  `,u+1),d=c===-1?"":a.slice(c+1);String(r.stack).endsWith(d)||(r.stack+=`
16
- `+a)}}catch(u){}}throw r}})}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Si(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&gu.assertOptions(r,{silentJSONParsing:In.transitional(In.boolean),forcedJSONParsing:In.transitional(In.boolean),clarifyTimeoutError:In.transitional(In.boolean),legacyInterceptorReqResOrdering:In.transitional(In.boolean)},!1),o!=null&&($.isFunction(o)?n.paramsSerializer={serialize:o}:gu.assertOptions(o,{encode:In.function,serialize:In.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),gu.assertOptions(n,{baseUrl:In.spelling("baseURL"),withXsrfToken:In.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&$.merge(a.common,a[n.method]);a&&$.forEach(["delete","get","head","post","put","patch","query","common"],x=>{delete a[x]}),n.headers=Zt.concat(u,a);const c=[];let d=!0;this.interceptors.request.forEach(function(S){if(typeof S.runWhen=="function"&&S.runWhen(n)===!1)return;d=d&&S.synchronous;const A=n.transitional||td;A&&A.legacyInterceptorReqResOrdering?c.unshift(S.fulfilled,S.rejected):c.push(S.fulfilled,S.rejected)});const h=[];this.interceptors.response.forEach(function(S){h.push(S.fulfilled,S.rejected)});let m,g=0,T;if(!d){const x=[n0.bind(this),void 0];for(x.unshift(...c),x.push(...h),T=x.length,m=Promise.resolve(n);g<T;)m=m.then(x[g++],x[g++]);return m}T=c.length;let b=n;for(;g<T;){const x=c[g++],S=c[g++];try{b=x(b)}catch(A){S.call(this,A);break}}try{m=n0.call(this,b)}catch(x){return Promise.reject(x)}for(g=0,T=h.length;g<T;)m=m.then(h[g++],h[g++]);return m}getUri(t){t=Si(this.defaults,t);const n=qm(t.baseURL,t.url,t.allowAbsoluteUrls);return Hm(n,t.params,t.paramsSerializer)}};$.forEach(["delete","get","head","options"],function(t){wi.prototype[t]=function(n,r){return this.request(Si(r||{},{method:t,url:n,data:(r||{}).data}))}}),$.forEach(["post","put","patch","query"],function(t){function n(r){return function(a,u,c){return this.request(Si(c||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:u}))}}wi.prototype[t]=n(),t!=="query"&&(wi.prototype[t+"Form"]=n(!0))});let fw=class Nx{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const u=new Promise(c=>{r.subscribe(c),a=c}).then(o);return u.cancel=function(){r.unsubscribe(a)},u},t(function(a,u,c){r.reason||(r.reason=new Cs(a,u,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 Nx(function(o){t=o}),cancel:t}}};function hw(e){return function(n){return e.apply(null,n)}}function pw(e){return $.isObject(e)&&e.isAxiosError===!0}const ud={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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(ud).forEach(([e,t])=>{ud[t]=e});function i0(e){const t=new wi(e),n=Am(wi.prototype.request,t);return $.extend(n,wi.prototype,t,{allOwnKeys:!0}),$.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return i0(Si(e,o))},n}const bt=i0(vs);bt.Axios=wi,bt.CanceledError=Cs,bt.CancelToken=fw,bt.isCancel=$m,bt.VERSION=od,bt.toFormData=fu,bt.AxiosError=ve,bt.Cancel=bt.CanceledError,bt.all=function(t){return Promise.all(t)},bt.spread=hw,bt.isAxiosError=pw,bt.mergeConfig=Si,bt.AxiosHeaders=Zt,bt.formToJSON=e=>jm($.isHTMLForm(e)?new FormData(e):e),bt.getAdapter=t0.getAdapter,bt.HttpStatusCode=ud,bt.default=bt;const{Axios:PM,AxiosError:LM,CanceledError:DM,isCancel:MM,CancelToken:FM,VERSION:BM,all:UM,Cancel:HM,isAxiosError:zM,spread:jM,toFormData:$M,AxiosHeaders:VM,HttpStatusCode:YM,formToJSON:WM,getAdapter:qM,mergeConfig:GM,create:KM}=bt;class mw{constructor(t,n,r,o=!1){Je(this,"CIMULATE_API_HEADER","x-cimulate-api-key");Je(this,"CIMULATE_SEARCH_API_HOST","search.cimulate");Je(this,"CIMULATE_SEARCH_API_PATH","api/v1");Je(this,"baseApiUrl");Je(this,"headers",{});Je(this,"fetchConfig",()=>et(this,null,function*(){try{const t=yield bt.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}}));Je(this,"_mapCopilotUrlToSearchUrl",(t="",n=!1)=>{if(t.endsWith("io")){const o=new URL(t);return o.hostname=o.hostname.replace(/^copilot\./,"api."),o.origin}return n?`https://staging.${this.CIMULATE_SEARCH_API_HOST}.ai`:`https://prod.${this.CIMULATE_SEARCH_API_HOST}.ai`});if(n&&r||!n&&!r)throw new Error("Provide exactly one authentication method: either 'apiKey' or 'apiToken', but not both.");n?this.headers[this.CIMULATE_API_HEADER]=n:r&&(this.headers.Authorization=`Bearer ${r}`),this.baseApiUrl=this._mapCopilotUrlToSearchUrl(t,o)}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}class gw{constructor(t,n,r,o=!1){Je(this,"apiService");Je(this,"config",null);Je(this,"getConfig",()=>et(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}}));Je(this,"getPid",t=>this.getProductFieldValue(t,"pidCol"));Je(this,"getName",t=>this.getProductFieldValue(t,"nameCol"));Je(this,"getDescription",t=>this.getProductFieldValue(t,"description"));Je(this,"getBrand",t=>this.getProductFieldValue(t,"productBrandCol"));Je(this,"getPrice",t=>this.getProductFieldValue(t,"priceCol"));Je(this,"getRelativePdp",t=>this.getProductFieldValue(t,"relativePdpCol"));Je(this,"getPdp",t=>this.getProductFieldValue(t,"pdpCol"));Je(this,"getImage",t=>this.getProductFieldValue(t,"imageCol"));Je(this,"getProductHiddenFields",()=>{const t=this.getProductField("productHiddenFields");return Array.isArray(t)?t:[]});Je(this,"getProductField",t=>this.config?this.config[t]:"");Je(this,"getProductFieldValue",(t,n)=>{const r=this.getProductField(n);return r&&t[r]||""});this.apiService=new mw(t,n,r,o)}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 Ai=(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 Ew{constructor(t=!1){Je(this,"isDevelopment");Je(this,"_log",(t,n,...r)=>{Ai(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 yw={copilot:"Your Search Assistant",messaging:"Commerce Client"},o0=ee.createContext(null),Tw=({mode:e,logoUrl:t,headerText:n="Your Search Assistant",headerConfig:r,globalClassName:o="",entryMessage:a,openLinksInNewTab:u=!1,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,searchPlaceholder:m,searchButtonLabel:g,searchConfig:T,componentConfig:b,conversationHistory:x,resetConversationMessage:S="",apiKey:A,apiToken:C,baseUrl:O,theme:R,isDevelopment:F,__features:z,children:D})=>{const q=e==="messaging",ce=ee.useMemo(()=>q?{config:null}:new gw(O,A,C,F),[q,O,A,C,F]),be=ee.useMemo(()=>new Ew(F),[F]);ee.useEffect(()=>{q||!ce||ce.config||ce.getConfig()},[ce,q]);const j=ee.useMemo(()=>I_(R),[R]),ae=ee.useMemo(()=>{const ue=(T==null?void 0:T.placeholder)||m,Te=(T==null?void 0:T.buttonLabel)||g;let Ne="icon";return T!=null&&T.buttonType?Ne=T.buttonType:g&&(Ne="text"),ne(U({},T||{}),{placeholder:ue,buttonLabel:Te,buttonType:Ne})},[T,m,g]),he=ee.useMemo(()=>ne(U({},r||{}),{logoUrl:t||(r==null?void 0:r.logoUrl),headerText:n||yw[e!=null?e:"copilot"]}),[r,t,n,e]),ge=ee.useMemo(()=>({configModule:ce,headerConfig:he,entryMessage:a,globalClassName:o,openLinksInNewTab:u,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,themeVariables:j,logger:be,searchConfig:ae,enableMinimize:!!(b!=null&&b.enableMinimize),resetConversationMessage:S,conversationHistory:{sinceHours:typeof(x==null?void 0:x.sinceHours)=="number"?x.sinceHours:1,limit:x==null?void 0:x.limit},features:z}),[ce,he,a,o,h,c,d,u,ae,b,S,be,j,x,z]);return P.jsx(o0.Provider,{value:ge,children:D})},an=()=>{const e=ee.useContext(o0);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e},s0={connectionStatus:"disconnected",loading:!0,conversationId:null,messages:[],streamingContent:"",isAgentTyping:!1,progressMessage:"",routingResult:null,error:null};function bw(e,t){switch(t.type){case"SET_CONNECTION_STATUS":return U(ne(U({},e),{connectionStatus:t.status}),t.status==="connected"||t.status==="connecting"?{error:null}:{});case"SET_LOADING":return ne(U({},e),{loading:t.isLoading});case"SET_CONVERSATION_ID":return ne(U({},e),{conversationId:t.id});case"ADD_MESSAGE":return ne(U({},e),{messages:[...e.messages,ne(U({},t.message),{type:"ADD_MESSAGE"})]});case"APPEND_STREAMING_TOKEN":return ne(U({},e),{streamingContent:e.streamingContent+t.token});case"FLUSH_STREAMING":return ne(U({},e),{messages:[...e.messages,ne(U({},t.message),{type:"FLUSH_STREAMING"})],streamingContent:"",isAgentTyping:!1,loading:!1,progressMessage:""});case"SET_AGENT_TYPING":return ne(U({},e),{isAgentTyping:t.isTyping,loading:t.isTyping});case"SET_PROGRESS_MESSAGE":return ne(U({},e),{progressMessage:t.message});case"SET_ROUTING_RESULT":return ne(U({},e),{routingResult:t.result});case"SET_ERROR":return ne(U({},e),{error:t.error,loading:!1,progressMessage:""});case"RESET":return ne(U({},s0),{connectionStatus:e.connectionStatus,loading:!0});default:return e}}const a0=ee.createContext({connectionStatus:"disconnected",isConnected:!1,isAgentTyping:!1,conversationId:null,messages:[],streamingContent:"",progressMessage:"",loading:!0,error:null,sendMessage:()=>{},resetConversation:()=>{}}),u0=({scrt2Url:e,orgId:t,esDeveloperName:n,routingAttributes:r,capabilitiesVersion:o,enableLogging:a=!1,onConnect:u,onMessage:c,onError:d,children:h})=>{const{logger:m}=an(),[g,T]=ee.useReducer(bw,s0),b=ee.useRef(null),x=ee.useRef(c),S=ee.useRef(d),A=ee.useRef(u);x.current=c,S.current=d,A.current=u,ee.useEffect(()=>{const F=new O_({baseURL:e,orgId:t,esDeveloperName:n,options:U({enableLogging:a},o?{capabilitiesVersion:o}:{})});return b.current=F,F.on("connected",()=>{var z;T({type:"SET_CONNECTION_STATUS",status:"connected"}),(z=A.current)==null||z.call(A)}),F.on("disconnected",()=>{T({type:"SET_CONNECTION_STATUS",status:"disconnected"})}),F.on("reconnecting",()=>{T({type:"SET_CONNECTION_STATUS",status:"reconnecting"})}),F.on("message",z=>{var q;const D={id:z.messageId||crypto.randomUUID(),role:"agent",content:z.content,timestamp:z.timestamp,sender:z.sender,raw:z};T({type:"FLUSH_STREAMING",message:D}),(q=x.current)==null||q.call(x,D)}),F.on("streaming_token",z=>{T({type:"APPEND_STREAMING_TOKEN",token:z.token})}),F.on("typing_started",()=>{T({type:"SET_AGENT_TYPING",isTyping:!0})}),F.on("typing_stopped",()=>{T({type:"SET_AGENT_TYPING",isTyping:!1})}),F.on("progress_indicator",z=>{T({type:"SET_PROGRESS_MESSAGE",message:z.message})}),F.on("routing_result",z=>{var D;if(T({type:"SET_ROUTING_RESULT",result:z}),!z.isSuccessful){const q=`Routing failed: ${z.failureType||"unknown"}`;T({type:"SET_ERROR",error:q}),(D=S.current)==null||D.call(S,q)}}),F.on("participant_changed",z=>{if(z.participant.name==="Automated Process")return;const D={id:crypto.randomUUID(),role:"system",content:z.action==="add"?`${z.participant.name||"Agent"} joined the conversation`:`${z.participant.name||"Agent"} left the conversation`,timestamp:new Date().toISOString()};m==null||m.log("🦜 MessagingProvider participant_changed event received",{event:z}),T({type:"ADD_MESSAGE",message:D})}),F.on("conversation_closed",()=>{const z={id:crypto.randomUUID(),role:"system",content:"Conversation reset",timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:z}),T({type:"SET_CONVERSATION_ID",id:null})}),F.on("error",z=>{var D;m==null||m.log("🦜 MessagingProvider ERROR event received",{event:z}),T({type:"SET_ERROR",error:z.message}),z.recoverable||T({type:"SET_CONNECTION_STATUS",status:"error"}),(D=S.current)==null||D.call(S,z.message)}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),F.connect().then(()=>F.createConversation(r)).then(z=>{T({type:"SET_CONVERSATION_ID",id:z})}).catch(z=>{var D;T({type:"SET_CONNECTION_STATUS",status:"error"}),T({type:"SET_ERROR",error:z.message}),(D=S.current)==null||D.call(S,z.message)}),()=>{F.endConversation().finally(()=>{F.disconnect(),F.off()}),b.current=null}},[e,t,n,o]);const C=ee.useCallback(F=>{if(!F.trim())return;const z=b.current;if(!z)return;const D={id:crypto.randomUUID(),role:"user",content:F,timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:D}),T({type:"SET_LOADING",isLoading:!0}),T({type:"SET_PROGRESS_MESSAGE",message:""}),z.sendMessage(F).catch(q=>{var ce;T({type:"SET_ERROR",error:q.message}),(ce=S.current)==null||ce.call(S,q.message)})},[]),O=ee.useCallback(()=>{const F=b.current;F&&(T({type:"RESET"}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),F.endConversation().then(()=>(F.disconnect(),F.connect())).then(()=>F.createConversation(r)).then(z=>{T({type:"SET_CONVERSATION_ID",id:z}),T({type:"SET_CONNECTION_STATUS",status:"connected"})}).catch(z=>{var D;T({type:"SET_ERROR",error:z.message}),T({type:"SET_CONNECTION_STATUS",status:"error"}),(D=S.current)==null||D.call(S,z.message)}))},[r]),R=ee.useMemo(()=>({connectionStatus:g.connectionStatus,isConnected:g.connectionStatus==="connected",isAgentTyping:g.isAgentTyping,conversationId:g.conversationId,messages:g.messages,streamingContent:g.streamingContent,progressMessage:g.progressMessage,error:g.error,loading:g.loading,sendMessage:C,resetConversation:O}),[g,C,O]);return P.jsx(a0.Provider,{value:R,children:h})};function xw(){var e=ee.useRef(!0);return e.current?(e.current=!1,!0):e.current}function _w(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.addEventListener&&e.addEventListener.apply(e,t)}function Sw(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.removeEventListener&&e.removeEventListener.apply(e,t)}var ld=typeof window!="undefined",Eu=function(e){ee.useEffect(e,[])},ww=function(e){var t=ee.useRef(e);t.current=e,Eu(function(){return function(){return t.current()}})},Aw=function(e){var t=ee.useRef(0),n=ee.useState(e),r=n[0],o=n[1],a=ee.useCallback(function(u){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(u)})},[]);return ww(function(){cancelAnimationFrame(t.current)}),[r,a]},vw=function(e,t){return e===t};function Cw(e,t){t===void 0&&(t=vw);var n=ee.useRef(),r=ee.useRef(e),o=xw();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var kw=function(e){var t={},n=t.initialWidth,r=n===void 0?1/0:n,o=t.initialHeight,a=o===void 0?1/0:o,u=t.onChange,c=Aw({width:ld?window.innerWidth:r,height:ld?window.innerHeight:a}),d=c[0],h=c[1];return ee.useEffect(function(){if(ld){var m=function(){var g=window.innerWidth,T=window.innerHeight;h({width:g,height:T}),u&&u(g,T)};return _w(window,"resize",m),function(){Sw(window,"resize",m)}}},[]),d};const cd="cimulate:ui-state-update",Nw=e=>{window.addEventListener(cd,e)},Ow=e=>{window.removeEventListener(cd,e)},Iw=(e,t)=>{const n=new CustomEvent(cd,{detail:{property:e,value:t}});window.dispatchEvent(n)},l0=e=>{if(!["ask_cim","search","browse","pdp"].includes(e))throw new Error(`Invalid entryType: "${e}". Must be 'ask_cim', 'search', 'browse', or 'pdp'.`);tt.entryTypeProxy.entryType=e},vi=e=>{const t=tt.statusProxy.isOpen,n=typeof e=="boolean"?e:!t;tt.statusProxy.isOpen=n,n&&(tt.statusProxy.isMinimized=!1)},yu=e=>{const t=tt.statusProxy.isMinimized,n=typeof e=="boolean"?e:!t;tt.statusProxy.isMinimized=n,n&&(tt.statusProxy.isOpen=!1)},dd=e=>{tt.modalProxy.isFullscreen=e},Tu=e=>{if(!["chat","dialog","modal"].includes(e))throw new Error(`Invalid type: ${e}. Must be 'chat', 'dialog', or 'modal'.`);tt.statusProxy.type=e,e==="dialog"||e==="chat"?tt.modeProxy.mode="embedded":tt.modeProxy.mode="standalone"},fd=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(", ")}.`);tt.dialogProxy.position=e},Rw=e=>{const t=tt.dialogProxy.isFullHeight,n=typeof e=="boolean"?e:!t;tt.dialogProxy.isFullHeight=n};class Pw{constructor(){Je(this,"initialState",{connected:!1,mode:"embedded",entryType:"search",status:{type:"dialog",isOpen:!1,isMinimized:!1},dialog:{position:"bottom-left",isFullHeight:!1,width:""},modal:{isFullscreen:!1}});Je(this,"connectedProxy");Je(this,"modeProxy");Je(this,"entryTypeProxy");Je(this,"statusProxy");Je(this,"dialogProxy");Je(this,"modalProxy",{isFullscreen:!1});Je(this,"_fullGet",(t,n)=>Reflect.get(t,n));Je(this,"_fullSet",(t,n,r)=>{if(!(n in t))throw new Error(`Property ${n} does not exist on UIState`);return Iw(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.entryTypeProxy=new Proxy({entryType:this.initialState.entryType},{get:this._fullGet,set:this._fullSet}),this.statusProxy=new Proxy({type:this.initialState.status.type,isOpen:this.initialState.status.isOpen,isMinimized:this.initialState.status.isMinimized},{get:this._fullGet,set:this._fullSet}),this.dialogProxy=new Proxy({position:this.initialState.dialog.position,isFullHeight:this.initialState.dialog.isFullHeight,width:this.initialState.dialog.width},{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 isMinimized(){return!!this.statusProxy.isMinimized}get type(){return this.statusProxy.type}get entryType(){return this.entryTypeProxy.entryType}get position(){return this.dialogProxy.position}get state(){return{connected:this.connected,mode:this.mode,entryType:this.entryType,status:{type:this.type,isOpen:this.isOpen,isMinimized:this.isMinimized},dialog:{position:this.position,isFullHeight:this.dialogProxy.isFullHeight,width:this.dialogProxy.width},modal:{isFullscreen:this.modalProxy.isFullscreen}}}}const tt=new Pw,c0=ee.createContext({mode:tt.modeProxy.mode,entryType:tt.entryType,status:tt.statusProxy,dialogPosition:tt.dialogProxy.position,isDialogFullHeight:tt.dialogProxy.isFullHeight,dialogWidth:tt.dialogProxy.width,isModalFullscreen:tt.modalProxy.isFullscreen,previousComponentType:tt.statusProxy.type}),Lw=({entryType:e,componentConfig:t,componentType:n,children:r})=>{const[o,a]=ee.useState(e!=null?e:tt.entryTypeProxy.entryType),[u,c]=ee.useState(tt.modeProxy.mode),[d,h]=ee.useState({type:n||tt.statusProxy.type,isOpen:tt.statusProxy.isOpen,isMinimized:tt.statusProxy.isMinimized}),[m,g]=ee.useState(tt.dialogProxy.position),[T,b]=ee.useState(tt.dialogProxy.isFullHeight),[x,S]=ee.useState(tt.dialogProxy.width),[A,C]=ee.useState(tt.modalProxy.isFullscreen),O=Cw(d.type);ee.useEffect(()=>{const F=z=>{const{property:D,value:q}=z.detail||{};if(!(!D||q===void 0)){if(D==="mode"){c(q);return}if(D==="entryType"){a(q);return}if(D==="isMinimized"){h(ce=>ne(U({},ce),{isMinimized:q}));return}if(D==="isOpen"){h(ce=>ne(U({},ce),{isOpen:q}));return}if(D==="type"){h(ce=>ne(U({},ce),{type:q}));return}if(D==="position"){g(q);return}if(D==="isFullHeight"){b(q);return}if(D==="width"){S(q);return}if(D==="isFullscreen"){C(q);return}}};return Nw(F),()=>{Ow(F)}},[]),Eu(()=>{e&&l0(e)}),Eu(()=>{const F=n||(t==null?void 0:t.type);F&&Tu(F),t&&"isOpen"in t&&vi(!!t.isOpen),t&&"isMinimized"in t&&yu(!!t.isMinimized)}),Eu(()=>{if(!(t!=null&&t.options))return;const{dialogPosition:F}=t.options;F&&fd(F),"dialogFullHeight"in t.options&&Rw(!!t.options.dialogFullHeight),"dialogWidth"in t.options&&t.options.dialogWidth&&S(t.options.dialogWidth),"isModalFullscreen"in t.options&&dd(!!t.options.isModalFullscreen)});const R=ee.useMemo(()=>({mode:u,entryType:o,status:d,previousComponentType:O||"dialog",dialogPosition:m,isDialogFullHeight:T,dialogWidth:x,isModalFullscreen:A}),[u,o,d,O,m,T,x,A]);return P.jsx(c0.Provider,{value:R,children:r})},d0=({mode:e,apiKey:t,apiToken:n,baseUrl:r,logoUrl:o,headerText:a,headerConfig:u,theme:c,openLinksInNewTab:d,globalClassName:h,isDevelopment:m=!1,componentType:g,componentConfig:T,entryType:b,entryMessage:x,disclaimerText:S,disclaimerMarkdown:A,clientContext:C,searchPlaceholder:O,searchButtonLabel:R,searchConfig:F,resetConversationMessage:z,conversationHistory:D,messagingConfig:q,__features:ce,children:be})=>P.jsx(Tw,{mode:e,baseUrl:r,apiKey:t,apiToken:n,logoUrl:o,headerText:a,headerConfig:u,entryMessage:x,theme:c,globalClassName:h,openLinksInNewTab:d,searchPlaceholder:O,searchButtonLabel:R,searchConfig:F,componentConfig:T,clientContext:C,disclaimerMarkdown:A,disclaimerText:S,resetConversationMessage:z,conversationHistory:D,isDevelopment:m,__features:ce,children:P.jsx(Lw,{entryType:b,componentConfig:T,componentType:g,children:P.jsx(u0,{scrt2Url:(q==null?void 0:q.scrt2Url)||"",orgId:(q==null?void 0:q.orgId)||"",esDeveloperName:(q==null?void 0:q.esDeveloperName)||"",routingAttributes:(q==null?void 0:q.routingAttributes)||{},capabilitiesVersion:q==null?void 0:q.capabilitiesVersion,enableLogging:m,children:be})})}),fo=()=>{const e=ee.useContext(c0);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};var hd={exports:{}},un={},pd={exports:{}},md={};var f0;function Dw(){return f0||(f0=1,(function(e){function t(K,te){var w=K.length;K.push(te);e:for(;0<w;){var M=w-1>>>1,X=K[M];if(0<o(X,te))K[M]=te,K[w]=X,w=M;else break e}}function n(K){return K.length===0?null:K[0]}function r(K){if(K.length===0)return null;var te=K[0],w=K.pop();if(w!==te){K[0]=w;e:for(var M=0,X=K.length,k=X>>>1;M<k;){var xe=2*(M+1)-1,Pe=K[xe],Oe=xe+1,He=K[Oe];if(0>o(Pe,w))Oe<X&&0>o(He,Pe)?(K[M]=He,K[Oe]=w,M=Oe):(K[M]=Pe,K[xe]=w,M=xe);else if(Oe<X&&0>o(He,w))K[M]=He,K[Oe]=w,M=Oe;else break e}}return te}function o(K,te){var w=K.sortIndex-te.sortIndex;return w!==0?w:K.id-te.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var u=Date,c=u.now();e.unstable_now=function(){return u.now()-c}}var d=[],h=[],m=1,g=null,T=3,b=!1,x=!1,S=!1,A=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,O=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function R(K){for(var te=n(h);te!==null;){if(te.callback===null)r(h);else if(te.startTime<=K)r(h),te.sortIndex=te.expirationTime,t(d,te);else break;te=n(h)}}function F(K){if(S=!1,R(K),!x)if(n(d)!==null)x=!0,Ne(z);else{var te=n(h);te!==null&&fe(F,te.startTime-K)}}function z(K,te){x=!1,S&&(S=!1,C(ce),ce=-1),b=!0;var w=T;try{for(R(te),g=n(d);g!==null&&(!(g.expirationTime>te)||K&&!ae());){var M=g.callback;if(typeof M=="function"){g.callback=null,T=g.priorityLevel;var X=M(g.expirationTime<=te);te=e.unstable_now(),typeof X=="function"?g.callback=X:g===n(d)&&r(d),R(te)}else r(d);g=n(d)}if(g!==null)var k=!0;else{var xe=n(h);xe!==null&&fe(F,xe.startTime-te),k=!1}return k}finally{g=null,T=w,b=!1}}var D=!1,q=null,ce=-1,be=5,j=-1;function ae(){return!(e.unstable_now()-j<be)}function he(){if(q!==null){var K=e.unstable_now();j=K;var te=!0;try{te=q(!0,K)}finally{te?ge():(D=!1,q=null)}}else D=!1}var ge;if(typeof O=="function")ge=function(){O(he)};else if(typeof MessageChannel!="undefined"){var ue=new MessageChannel,Te=ue.port2;ue.port1.onmessage=he,ge=function(){Te.postMessage(null)}}else ge=function(){A(he,0)};function Ne(K){q=K,D||(D=!0,ge())}function fe(K,te){ce=A(function(){K(e.unstable_now())},te)}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(K){K.callback=null},e.unstable_continueExecution=function(){x||b||(x=!0,Ne(z))},e.unstable_forceFrameRate=function(K){0>K||125<K?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):be=0<K?Math.floor(1e3/K):5},e.unstable_getCurrentPriorityLevel=function(){return T},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(K){switch(T){case 1:case 2:case 3:var te=3;break;default:te=T}var w=T;T=te;try{return K()}finally{T=w}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(K,te){switch(K){case 1:case 2:case 3:case 4:case 5:break;default:K=3}var w=T;T=K;try{return te()}finally{T=w}},e.unstable_scheduleCallback=function(K,te,w){var M=e.unstable_now();switch(typeof w=="object"&&w!==null?(w=w.delay,w=typeof w=="number"&&0<w?M+w:M):w=M,K){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=w+X,K={id:m++,callback:te,priorityLevel:K,startTime:w,expirationTime:X,sortIndex:-1},w>M?(K.sortIndex=w,t(h,K),n(d)===null&&K===n(h)&&(S?(C(ce),ce=-1):S=!0,fe(F,w-M))):(K.sortIndex=X,t(d,K),x||b||(x=!0,Ne(z))),K},e.unstable_shouldYield=ae,e.unstable_wrapCallback=function(K){var te=T;return function(){var w=T;T=te;try{return K.apply(this,arguments)}finally{T=w}}}})(md)),md}var h0;function Mw(){return h0||(h0=1,pd.exports=Dw()),pd.exports}var p0;function Fw(){if(p0)return un;p0=1;var e=so(),t=Mw();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 a(i,s){u(i,s),u(i+"Capture",s)}function u(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"),d=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={},g={};function T(i){return d.call(g,i)?!0:d.call(m,i)?!1:h.test(i)?g[i]=!0:(m[i]=!0,!1)}function b(i,s,l,f){if(l!==null&&l.type===0)return!1;switch(typeof s){case"function":case"symbol":return!0;case"boolean":return f?!1:l!==null?!l.acceptsBooleans:(i=i.toLowerCase().slice(0,5),i!=="data-"&&i!=="aria-");default:return!1}}function x(i,s,l,f){if(s===null||typeof s=="undefined"||b(i,s,l,f))return!0;if(f)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,f,E,y,_){this.acceptsBooleans=s===2||s===3||s===4,this.attributeName=f,this.attributeNamespace=E,this.mustUseProperty=l,this.propertyName=i,this.type=s,this.sanitizeURL=y,this.removeEmptyString=_}var A={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){A[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];A[s]=new S(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){A[i]=new S(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){A[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){A[i]=new S(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){A[i]=new S(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){A[i]=new S(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){A[i]=new S(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){A[i]=new S(i,5,!1,i.toLowerCase(),null,!1,!1)});var C=/[\-:]([a-z])/g;function O(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(C,O);A[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(C,O);A[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(C,O);A[s]=new S(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){A[i]=new S(i,1,!1,i.toLowerCase(),null,!1,!1)}),A.xlinkHref=new S("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){A[i]=new S(i,1,!1,i.toLowerCase(),null,!0,!0)});function R(i,s,l,f){var E=A.hasOwnProperty(s)?A[s]:null;(E!==null?E.type!==0:f||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(x(s,l,E,f)&&(l=null),f||E===null?T(s)&&(l===null?i.removeAttribute(s):i.setAttribute(s,""+l)):E.mustUseProperty?i[E.propertyName]=l===null?E.type===3?!1:"":l:(s=E.attributeName,f=E.attributeNamespace,l===null?i.removeAttribute(s):(E=E.type,l=E===3||E===4&&l===!0?"":""+l,f?i.setAttributeNS(f,s,l):i.setAttribute(s,l))))}var F=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,z=Symbol.for("react.element"),D=Symbol.for("react.portal"),q=Symbol.for("react.fragment"),ce=Symbol.for("react.strict_mode"),be=Symbol.for("react.profiler"),j=Symbol.for("react.provider"),ae=Symbol.for("react.context"),he=Symbol.for("react.forward_ref"),ge=Symbol.for("react.suspense"),ue=Symbol.for("react.suspense_list"),Te=Symbol.for("react.memo"),Ne=Symbol.for("react.lazy"),fe=Symbol.for("react.offscreen"),K=Symbol.iterator;function te(i){return i===null||typeof i!="object"?null:(i=K&&i[K]||i["@@iterator"],typeof i=="function"?i:null)}var w=Object.assign,M;function X(i){if(M===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);M=s&&s[1]||""}return`
17
- `+M+i}var k=!1;function xe(i,s){if(!i||k)return"";k=!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(G){var f=G}Reflect.construct(i,[],s)}else{try{s.call()}catch(G){f=G}i.call(s.prototype)}else{try{throw Error()}catch(G){f=G}i()}}catch(G){if(G&&f&&typeof G.stack=="string"){for(var E=G.stack.split(`
16
+ `+a)}}catch(u){}}throw r}})}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=wi(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&gu.assertOptions(r,{silentJSONParsing:In.transitional(In.boolean),forcedJSONParsing:In.transitional(In.boolean),clarifyTimeoutError:In.transitional(In.boolean),legacyInterceptorReqResOrdering:In.transitional(In.boolean)},!1),o!=null&&($.isFunction(o)?n.paramsSerializer={serialize:o}:gu.assertOptions(o,{encode:In.function,serialize:In.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),gu.assertOptions(n,{baseUrl:In.spelling("baseURL"),withXsrfToken:In.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&$.merge(a.common,a[n.method]);a&&$.forEach(["delete","get","head","post","put","patch","query","common"],_=>{delete a[_]}),n.headers=Zt.concat(u,a);const c=[];let d=!0;this.interceptors.request.forEach(function(w){if(typeof w.runWhen=="function"&&w.runWhen(n)===!1)return;d=d&&w.synchronous;const A=n.transitional||td;A&&A.legacyInterceptorReqResOrdering?c.unshift(w.fulfilled,w.rejected):c.push(w.fulfilled,w.rejected)});const h=[];this.interceptors.response.forEach(function(w){h.push(w.fulfilled,w.rejected)});let m,E=0,T;if(!d){const _=[Zm.bind(this),void 0];for(_.unshift(...c),_.push(...h),T=_.length,m=Promise.resolve(n);E<T;)m=m.then(_[E++],_[E++]);return m}T=c.length;let b=n;for(;E<T;){const _=c[E++],w=c[E++];try{b=_(b)}catch(A){w.call(this,A);break}}try{m=Zm.call(this,b)}catch(_){return Promise.reject(_)}for(E=0,T=h.length;E<T;)m=m.then(h[E++],h[E++]);return m}getUri(t){t=wi(this.defaults,t);const n=Vm(t.baseURL,t.url,t.allowAbsoluteUrls);return Fm(n,t.params,t.paramsSerializer)}};$.forEach(["delete","get","head","options"],function(t){Si.prototype[t]=function(n,r){return this.request(wi(r||{},{method:t,url:n,data:(r||{}).data}))}}),$.forEach(["post","put","patch","query"],function(t){function n(r){return function(a,u,c){return this.request(wi(c||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:u}))}}Si.prototype[t]=n(),t!=="query"&&(Si.prototype[t+"Form"]=n(!0))});let dS=class kx{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const u=new Promise(c=>{r.subscribe(c),a=c}).then(o);return u.cancel=function(){r.unsubscribe(a)},u},t(function(a,u,c){r.reason||(r.reason=new Cs(a,u,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 kx(function(o){t=o}),cancel:t}}};function fS(e){return function(n){return e.apply(null,n)}}function hS(e){return $.isObject(e)&&e.isAxiosError===!0}const ud={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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(ud).forEach(([e,t])=>{ud[t]=e});function t0(e){const t=new Si(e),n=_m(Si.prototype.request,t);return $.extend(n,Si.prototype,t,{allOwnKeys:!0}),$.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return t0(wi(e,o))},n}const bt=t0(vs);bt.Axios=Si,bt.CanceledError=Cs,bt.CancelToken=dS,bt.isCancel=Hm,bt.VERSION=od,bt.toFormData=fu,bt.AxiosError=ve,bt.Cancel=bt.CanceledError,bt.all=function(t){return Promise.all(t)},bt.spread=fS,bt.isAxiosError=hS,bt.mergeConfig=wi,bt.AxiosHeaders=Zt,bt.formToJSON=e=>Um($.isHTMLForm(e)?new FormData(e):e),bt.getAdapter=Jm.getAdapter,bt.HttpStatusCode=ud,bt.default=bt;const{Axios:MM,AxiosError:FM,CanceledError:BM,isCancel:UM,CancelToken:HM,VERSION:zM,all:jM,Cancel:$M,isAxiosError:VM,spread:YM,toFormData:WM,AxiosHeaders:qM,HttpStatusCode:GM,formToJSON:KM,getAdapter:QM,mergeConfig:XM,create:JM}=bt;class pS{constructor(t,n,r,o=!1){Je(this,"CIMULATE_API_HEADER","x-cimulate-api-key");Je(this,"CIMULATE_SEARCH_API_HOST","search.cimulate");Je(this,"CIMULATE_SEARCH_API_PATH","api/v1");Je(this,"baseApiUrl");Je(this,"headers",{});Je(this,"fetchConfig",()=>et(this,null,function*(){try{const t=yield bt.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}}));Je(this,"_mapCopilotUrlToSearchUrl",(t="",n=!1)=>{if(t.endsWith("io")){const o=new URL(t);return o.hostname=o.hostname.replace(/^copilot\./,"api."),o.origin}return n?`https://staging.${this.CIMULATE_SEARCH_API_HOST}.ai`:`https://prod.${this.CIMULATE_SEARCH_API_HOST}.ai`});if(n&&r||!n&&!r)throw new Error("Provide exactly one authentication method: either 'apiKey' or 'apiToken', but not both.");n?this.headers[this.CIMULATE_API_HEADER]=n:r&&(this.headers.Authorization=`Bearer ${r}`),this.baseApiUrl=this._mapCopilotUrlToSearchUrl(t,o)}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}class mS{constructor(t,n,r,o=!1){Je(this,"apiService");Je(this,"config",null);Je(this,"getConfig",()=>et(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}}));Je(this,"getPid",t=>this.getProductFieldValue(t,"pidCol"));Je(this,"getName",t=>this.getProductFieldValue(t,"nameCol"));Je(this,"getDescription",t=>this.getProductFieldValue(t,"description"));Je(this,"getBrand",t=>this.getProductFieldValue(t,"productBrandCol"));Je(this,"getPrice",t=>this.getProductFieldValue(t,"priceCol"));Je(this,"getRelativePdp",t=>this.getProductFieldValue(t,"relativePdpCol"));Je(this,"getPdp",t=>this.getProductFieldValue(t,"pdpCol"));Je(this,"getImage",t=>this.getProductFieldValue(t,"imageCol"));Je(this,"getProductHiddenFields",()=>{const t=this.getProductField("productHiddenFields");return Array.isArray(t)?t:[]});Je(this,"getProductField",t=>this.config?this.config[t]:"");Je(this,"getProductFieldValue",(t,n)=>{const r=this.getProductField(n);return r&&t[r]||""});this.apiService=new pS(t,n,r,o)}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 Ai=(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 gS{constructor(t=!1){Je(this,"isDevelopment");Je(this,"_log",(t,n,...r)=>{Ai(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 ES={copilot:"Your Search Assistant",messaging:"Commerce Client"},n0=ee.createContext(null),yS=({mode:e,logoUrl:t,headerText:n="Your Search Assistant",headerConfig:r,globalClassName:o="",entryMessage:a,openLinksInNewTab:u=!1,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,searchPlaceholder:m,searchButtonLabel:E,searchConfig:T,componentConfig:b,conversationHistory:_,resetConversationMessage:w="",apiKey:A,apiToken:C,baseUrl:I,theme:R,isDevelopment:F,__features:z,children:D})=>{const q=e==="messaging",ce=ee.useMemo(()=>q?{config:null}:new mS(I,A,C,F),[q,I,A,C,F]),be=ee.useMemo(()=>new gS(F),[F]);ee.useEffect(()=>{q||!ce||ce.config||ce.getConfig()},[ce,q]);const j=ee.useMemo(()=>O_(R),[R]),ae=ee.useMemo(()=>{const ue=(T==null?void 0:T.placeholder)||m,Te=(T==null?void 0:T.buttonLabel)||E;let Ne="icon";return T!=null&&T.buttonType?Ne=T.buttonType:E&&(Ne="text"),ne(U({},T||{}),{placeholder:ue,buttonLabel:Te,buttonType:Ne})},[T,m,E]),he=ee.useMemo(()=>ne(U({},r||{}),{logoUrl:t||(r==null?void 0:r.logoUrl),headerText:n||ES[e!=null?e:"copilot"]}),[r,t,n,e]),ge=ee.useMemo(()=>({configModule:ce,headerConfig:he,entryMessage:a,globalClassName:o,openLinksInNewTab:u,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,themeVariables:j,logger:be,searchConfig:ae,enableMinimize:!!(b!=null&&b.enableMinimize),resetConversationMessage:w,conversationHistory:{sinceHours:typeof(_==null?void 0:_.sinceHours)=="number"?_.sinceHours:1,limit:_==null?void 0:_.limit},features:z}),[ce,he,a,o,h,c,d,u,ae,b,w,be,j,_,z]);return L.jsx(n0.Provider,{value:ge,children:D})},en=()=>{const e=ee.useContext(n0);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e},r0={connectionStatus:"disconnected",loading:!0,conversationId:null,messages:[],streamingContent:"",isAgentTyping:!1,progressMessage:"",routingResult:null,error:null};function TS(e,t){switch(t.type){case"SET_CONNECTION_STATUS":return U(ne(U({},e),{connectionStatus:t.status}),t.status==="connected"||t.status==="connecting"?{error:null}:{});case"SET_LOADING":return ne(U({},e),{loading:t.isLoading});case"SET_CONVERSATION_ID":return ne(U({},e),{conversationId:t.id});case"ADD_MESSAGE":return ne(U({},e),{messages:[...e.messages,ne(U({},t.message),{type:"ADD_MESSAGE"})]});case"APPEND_STREAMING_TOKEN":return ne(U({},e),{streamingContent:e.streamingContent+t.token});case"FLUSH_STREAMING":return ne(U({},e),{messages:[...e.messages,ne(U({},t.message),{type:"FLUSH_STREAMING"})],streamingContent:"",isAgentTyping:!1,loading:!1,progressMessage:""});case"SET_AGENT_TYPING":return ne(U({},e),{isAgentTyping:t.isTyping,loading:t.isTyping});case"SET_PROGRESS_MESSAGE":return ne(U({},e),{progressMessage:t.message});case"SET_ROUTING_RESULT":return ne(U({},e),{routingResult:t.result});case"SET_ERROR":return ne(U({},e),{error:t.error,loading:!1,progressMessage:""});case"RESET":return ne(U({},r0),{connectionStatus:e.connectionStatus,loading:!0});default:return e}}const i0=ee.createContext({connectionStatus:"disconnected",isConnected:!1,isAgentTyping:!1,conversationId:null,messages:[],streamingContent:"",progressMessage:"",loading:!0,error:null,sendMessage:()=>{},resetConversation:()=>{}}),o0=({scrt2Url:e,orgId:t,esDeveloperName:n,routingAttributes:r,capabilitiesVersion:o,enableLogging:a=!1,onConnect:u,onMessage:c,onError:d,children:h})=>{const{logger:m}=en(),[E,T]=ee.useReducer(TS,r0),b=ee.useRef(null),_=ee.useRef(c),w=ee.useRef(d),A=ee.useRef(u);_.current=c,w.current=d,A.current=u,ee.useEffect(()=>{const F=new N_({baseURL:e,orgId:t,esDeveloperName:n,options:U({enableLogging:a},o?{capabilitiesVersion:o}:{})});return b.current=F,F.on("connected",()=>{var z;T({type:"SET_CONNECTION_STATUS",status:"connected"}),(z=A.current)==null||z.call(A)}),F.on("disconnected",()=>{T({type:"SET_CONNECTION_STATUS",status:"disconnected"})}),F.on("reconnecting",()=>{T({type:"SET_CONNECTION_STATUS",status:"reconnecting"})}),F.on("message",z=>{var q;const D={id:z.messageId||crypto.randomUUID(),role:"agent",content:z.content,timestamp:z.timestamp,sender:z.sender,raw:z};T({type:"FLUSH_STREAMING",message:D}),(q=_.current)==null||q.call(_,D)}),F.on("streaming_token",z=>{T({type:"APPEND_STREAMING_TOKEN",token:z.token})}),F.on("typing_started",()=>{T({type:"SET_AGENT_TYPING",isTyping:!0})}),F.on("typing_stopped",()=>{T({type:"SET_AGENT_TYPING",isTyping:!1})}),F.on("progress_indicator",z=>{T({type:"SET_PROGRESS_MESSAGE",message:z.message})}),F.on("routing_result",z=>{var D;if(T({type:"SET_ROUTING_RESULT",result:z}),!z.isSuccessful){const q=`Routing failed: ${z.failureType||"unknown"}`;T({type:"SET_ERROR",error:q}),(D=w.current)==null||D.call(w,q)}}),F.on("participant_changed",z=>{if(z.participant.name==="Automated Process")return;const D={id:crypto.randomUUID(),role:"system",content:z.action==="add"?`${z.participant.name||"Agent"} joined the conversation`:`${z.participant.name||"Agent"} left the conversation`,timestamp:new Date().toISOString()};m==null||m.log("🦜 MessagingProvider participant_changed event received",{event:z}),T({type:"ADD_MESSAGE",message:D})}),F.on("conversation_closed",()=>{const z={id:crypto.randomUUID(),role:"system",content:"Conversation reset",timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:z}),T({type:"SET_CONVERSATION_ID",id:null})}),F.on("error",z=>{var D;m==null||m.log("🦜 MessagingProvider ERROR event received",{event:z}),T({type:"SET_ERROR",error:z.message}),z.recoverable||T({type:"SET_CONNECTION_STATUS",status:"error"}),(D=w.current)==null||D.call(w,z.message)}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),F.connect().then(()=>F.createConversation(r)).then(z=>{T({type:"SET_CONVERSATION_ID",id:z})}).catch(z=>{var D;T({type:"SET_CONNECTION_STATUS",status:"error"}),T({type:"SET_ERROR",error:z.message}),(D=w.current)==null||D.call(w,z.message)}),()=>{F.endConversation().finally(()=>{F.disconnect(),F.off()}),b.current=null}},[e,t,n,o]);const C=ee.useCallback(F=>{if(!F.trim())return;const z=b.current;if(!z)return;const D={id:crypto.randomUUID(),role:"user",content:F,timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:D}),T({type:"SET_LOADING",isLoading:!0}),T({type:"SET_PROGRESS_MESSAGE",message:""}),z.sendMessage(F).catch(q=>{var ce;T({type:"SET_ERROR",error:q.message}),(ce=w.current)==null||ce.call(w,q.message)})},[]),I=ee.useCallback(()=>{const F=b.current;F&&(T({type:"RESET"}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),F.endConversation().then(()=>(F.disconnect(),F.connect())).then(()=>F.createConversation(r)).then(z=>{T({type:"SET_CONVERSATION_ID",id:z}),T({type:"SET_CONNECTION_STATUS",status:"connected"})}).catch(z=>{var D;T({type:"SET_ERROR",error:z.message}),T({type:"SET_CONNECTION_STATUS",status:"error"}),(D=w.current)==null||D.call(w,z.message)}))},[r]),R=ee.useMemo(()=>({connectionStatus:E.connectionStatus,isConnected:E.connectionStatus==="connected",isAgentTyping:E.isAgentTyping,conversationId:E.conversationId,messages:E.messages,streamingContent:E.streamingContent,progressMessage:E.progressMessage,error:E.error,loading:E.loading,sendMessage:C,resetConversation:I}),[E,C,I]);return L.jsx(i0.Provider,{value:R,children:h})};function bS(){var e=ee.useRef(!0);return e.current?(e.current=!1,!0):e.current}function xS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.addEventListener&&e.addEventListener.apply(e,t)}function _S(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.removeEventListener&&e.removeEventListener.apply(e,t)}var ld=typeof window!="undefined",Eu=function(e){ee.useEffect(e,[])},wS=function(e){var t=ee.useRef(e);t.current=e,Eu(function(){return function(){return t.current()}})},SS=function(e){var t=ee.useRef(0),n=ee.useState(e),r=n[0],o=n[1],a=ee.useCallback(function(u){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(u)})},[]);return wS(function(){cancelAnimationFrame(t.current)}),[r,a]},AS=function(e,t){return e===t};function vS(e,t){t===void 0&&(t=AS);var n=ee.useRef(),r=ee.useRef(e),o=bS();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var CS=function(e){var t={},n=t.initialWidth,r=n===void 0?1/0:n,o=t.initialHeight,a=o===void 0?1/0:o,u=t.onChange,c=SS({width:ld?window.innerWidth:r,height:ld?window.innerHeight:a}),d=c[0],h=c[1];return ee.useEffect(function(){if(ld){var m=function(){var E=window.innerWidth,T=window.innerHeight;h({width:E,height:T}),u&&u(E,T)};return xS(window,"resize",m),function(){_S(window,"resize",m)}}},[]),d};const cd="cimulate:ui-state-update",kS=e=>{window.addEventListener(cd,e)},NS=e=>{window.removeEventListener(cd,e)},OS=(e,t)=>{const n=new CustomEvent(cd,{detail:{property:e,value:t}});window.dispatchEvent(n)},s0=e=>{if(!["ask_cim","search","browse","pdp"].includes(e))throw new Error(`Invalid entryType: "${e}". Must be 'ask_cim', 'search', 'browse', or 'pdp'.`);tt.entryTypeProxy.entryType=e},vi=e=>{const t=tt.statusProxy.isOpen,n=typeof e=="boolean"?e:!t;tt.statusProxy.isOpen=n,n&&(tt.statusProxy.isMinimized=!1)},yu=e=>{const t=tt.statusProxy.isMinimized,n=typeof e=="boolean"?e:!t;tt.statusProxy.isMinimized=n,n&&(tt.statusProxy.isOpen=!1)},dd=e=>{tt.modalProxy.isFullscreen=e},Tu=e=>{if(!["chat","dialog","modal"].includes(e))throw new Error(`Invalid type: ${e}. Must be 'chat', 'dialog', or 'modal'.`);tt.statusProxy.type=e,e==="dialog"||e==="chat"?tt.modeProxy.mode="embedded":tt.modeProxy.mode="standalone"},fd=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(", ")}.`);tt.dialogProxy.position=e},IS=e=>{const t=tt.dialogProxy.isFullHeight,n=typeof e=="boolean"?e:!t;tt.dialogProxy.isFullHeight=n};class RS{constructor(){Je(this,"initialState",{connected:!1,mode:"embedded",entryType:"search",status:{type:"dialog",isOpen:!1,isMinimized:!1},dialog:{position:"bottom-left",isFullHeight:!1,width:""},modal:{isFullscreen:!1}});Je(this,"connectedProxy");Je(this,"modeProxy");Je(this,"entryTypeProxy");Je(this,"statusProxy");Je(this,"dialogProxy");Je(this,"modalProxy",{isFullscreen:!1});Je(this,"_fullGet",(t,n)=>Reflect.get(t,n));Je(this,"_fullSet",(t,n,r)=>{if(!(n in t))throw new Error(`Property ${n} does not exist on UIState`);return OS(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.entryTypeProxy=new Proxy({entryType:this.initialState.entryType},{get:this._fullGet,set:this._fullSet}),this.statusProxy=new Proxy({type:this.initialState.status.type,isOpen:this.initialState.status.isOpen,isMinimized:this.initialState.status.isMinimized},{get:this._fullGet,set:this._fullSet}),this.dialogProxy=new Proxy({position:this.initialState.dialog.position,isFullHeight:this.initialState.dialog.isFullHeight,width:this.initialState.dialog.width},{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 isMinimized(){return!!this.statusProxy.isMinimized}get type(){return this.statusProxy.type}get entryType(){return this.entryTypeProxy.entryType}get position(){return this.dialogProxy.position}get state(){return{connected:this.connected,mode:this.mode,entryType:this.entryType,status:{type:this.type,isOpen:this.isOpen,isMinimized:this.isMinimized},dialog:{position:this.position,isFullHeight:this.dialogProxy.isFullHeight,width:this.dialogProxy.width},modal:{isFullscreen:this.modalProxy.isFullscreen}}}}const tt=new RS,a0=ee.createContext({mode:tt.modeProxy.mode,entryType:tt.entryType,status:tt.statusProxy,dialogPosition:tt.dialogProxy.position,isDialogFullHeight:tt.dialogProxy.isFullHeight,dialogWidth:tt.dialogProxy.width,isModalFullscreen:tt.modalProxy.isFullscreen,previousComponentType:tt.statusProxy.type}),PS=({entryType:e,componentConfig:t,componentType:n,children:r})=>{const[o,a]=ee.useState(e!=null?e:tt.entryTypeProxy.entryType),[u,c]=ee.useState(tt.modeProxy.mode),[d,h]=ee.useState({type:n||tt.statusProxy.type,isOpen:tt.statusProxy.isOpen,isMinimized:tt.statusProxy.isMinimized}),[m,E]=ee.useState(tt.dialogProxy.position),[T,b]=ee.useState(tt.dialogProxy.isFullHeight),[_,w]=ee.useState(tt.dialogProxy.width),[A,C]=ee.useState(tt.modalProxy.isFullscreen),I=vS(d.type);ee.useEffect(()=>{const F=z=>{const{property:D,value:q}=z.detail||{};if(!(!D||q===void 0)){if(D==="mode"){c(q);return}if(D==="entryType"){a(q);return}if(D==="isMinimized"){h(ce=>ne(U({},ce),{isMinimized:q}));return}if(D==="isOpen"){h(ce=>ne(U({},ce),{isOpen:q}));return}if(D==="type"){h(ce=>ne(U({},ce),{type:q}));return}if(D==="position"){E(q);return}if(D==="isFullHeight"){b(q);return}if(D==="width"){w(q);return}if(D==="isFullscreen"){C(q);return}}};return kS(F),()=>{NS(F)}},[]),Eu(()=>{e&&s0(e)}),Eu(()=>{const F=n||(t==null?void 0:t.type);F&&Tu(F),t&&"isOpen"in t&&vi(!!t.isOpen),t&&"isMinimized"in t&&yu(!!t.isMinimized)}),Eu(()=>{if(!(t!=null&&t.options))return;const{dialogPosition:F}=t.options;F&&fd(F),"dialogFullHeight"in t.options&&IS(!!t.options.dialogFullHeight),"dialogWidth"in t.options&&t.options.dialogWidth&&w(t.options.dialogWidth),"isModalFullscreen"in t.options&&dd(!!t.options.isModalFullscreen)});const R=ee.useMemo(()=>({mode:u,entryType:o,status:d,previousComponentType:I||"dialog",dialogPosition:m,isDialogFullHeight:T,dialogWidth:_,isModalFullscreen:A}),[u,o,d,I,m,T,_,A]);return L.jsx(a0.Provider,{value:R,children:r})},u0=({mode:e,apiKey:t,apiToken:n,baseUrl:r,logoUrl:o,headerText:a,headerConfig:u,theme:c,openLinksInNewTab:d,globalClassName:h,isDevelopment:m=!1,componentType:E,componentConfig:T,entryType:b,entryMessage:_,disclaimerText:w,disclaimerMarkdown:A,clientContext:C,searchPlaceholder:I,searchButtonLabel:R,searchConfig:F,resetConversationMessage:z,conversationHistory:D,messagingConfig:q,__features:ce,children:be})=>L.jsx(yS,{mode:e,baseUrl:r,apiKey:t,apiToken:n,logoUrl:o,headerText:a,headerConfig:u,entryMessage:_,theme:c,globalClassName:h,openLinksInNewTab:d,searchPlaceholder:I,searchButtonLabel:R,searchConfig:F,componentConfig:T,clientContext:C,disclaimerMarkdown:A,disclaimerText:w,resetConversationMessage:z,conversationHistory:D,isDevelopment:m,__features:ce,children:L.jsx(PS,{entryType:b,componentConfig:T,componentType:E,children:L.jsx(o0,{scrt2Url:(q==null?void 0:q.scrt2Url)||"",orgId:(q==null?void 0:q.orgId)||"",esDeveloperName:(q==null?void 0:q.esDeveloperName)||"",routingAttributes:(q==null?void 0:q.routingAttributes)||{},capabilitiesVersion:q==null?void 0:q.capabilitiesVersion,enableLogging:m,children:be})})}),Ci=()=>{const e=ee.useContext(a0);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};var hd={exports:{}},un={},pd={exports:{}},md={};var l0;function LS(){return l0||(l0=1,(function(e){function t(K,te){var S=K.length;K.push(te);e:for(;0<S;){var M=S-1>>>1,X=K[M];if(0<o(X,te))K[M]=te,K[S]=X,S=M;else break e}}function n(K){return K.length===0?null:K[0]}function r(K){if(K.length===0)return null;var te=K[0],S=K.pop();if(S!==te){K[0]=S;e:for(var M=0,X=K.length,k=X>>>1;M<k;){var xe=2*(M+1)-1,Pe=K[xe],Oe=xe+1,He=K[Oe];if(0>o(Pe,S))Oe<X&&0>o(He,Pe)?(K[M]=He,K[Oe]=S,M=Oe):(K[M]=Pe,K[xe]=S,M=xe);else if(Oe<X&&0>o(He,S))K[M]=He,K[Oe]=S,M=Oe;else break e}}return te}function o(K,te){var S=K.sortIndex-te.sortIndex;return S!==0?S:K.id-te.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var u=Date,c=u.now();e.unstable_now=function(){return u.now()-c}}var d=[],h=[],m=1,E=null,T=3,b=!1,_=!1,w=!1,A=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,I=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function R(K){for(var te=n(h);te!==null;){if(te.callback===null)r(h);else if(te.startTime<=K)r(h),te.sortIndex=te.expirationTime,t(d,te);else break;te=n(h)}}function F(K){if(w=!1,R(K),!_)if(n(d)!==null)_=!0,Ne(z);else{var te=n(h);te!==null&&fe(F,te.startTime-K)}}function z(K,te){_=!1,w&&(w=!1,C(ce),ce=-1),b=!0;var S=T;try{for(R(te),E=n(d);E!==null&&(!(E.expirationTime>te)||K&&!ae());){var M=E.callback;if(typeof M=="function"){E.callback=null,T=E.priorityLevel;var X=M(E.expirationTime<=te);te=e.unstable_now(),typeof X=="function"?E.callback=X:E===n(d)&&r(d),R(te)}else r(d);E=n(d)}if(E!==null)var k=!0;else{var xe=n(h);xe!==null&&fe(F,xe.startTime-te),k=!1}return k}finally{E=null,T=S,b=!1}}var D=!1,q=null,ce=-1,be=5,j=-1;function ae(){return!(e.unstable_now()-j<be)}function he(){if(q!==null){var K=e.unstable_now();j=K;var te=!0;try{te=q(!0,K)}finally{te?ge():(D=!1,q=null)}}else D=!1}var ge;if(typeof I=="function")ge=function(){I(he)};else if(typeof MessageChannel!="undefined"){var ue=new MessageChannel,Te=ue.port2;ue.port1.onmessage=he,ge=function(){Te.postMessage(null)}}else ge=function(){A(he,0)};function Ne(K){q=K,D||(D=!0,ge())}function fe(K,te){ce=A(function(){K(e.unstable_now())},te)}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(K){K.callback=null},e.unstable_continueExecution=function(){_||b||(_=!0,Ne(z))},e.unstable_forceFrameRate=function(K){0>K||125<K?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):be=0<K?Math.floor(1e3/K):5},e.unstable_getCurrentPriorityLevel=function(){return T},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(K){switch(T){case 1:case 2:case 3:var te=3;break;default:te=T}var S=T;T=te;try{return K()}finally{T=S}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(K,te){switch(K){case 1:case 2:case 3:case 4:case 5:break;default:K=3}var S=T;T=K;try{return te()}finally{T=S}},e.unstable_scheduleCallback=function(K,te,S){var M=e.unstable_now();switch(typeof S=="object"&&S!==null?(S=S.delay,S=typeof S=="number"&&0<S?M+S:M):S=M,K){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=S+X,K={id:m++,callback:te,priorityLevel:K,startTime:S,expirationTime:X,sortIndex:-1},S>M?(K.sortIndex=S,t(h,K),n(d)===null&&K===n(h)&&(w?(C(ce),ce=-1):w=!0,fe(F,S-M))):(K.sortIndex=X,t(d,K),_||b||(_=!0,Ne(z))),K},e.unstable_shouldYield=ae,e.unstable_wrapCallback=function(K){var te=T;return function(){var S=T;T=te;try{return K.apply(this,arguments)}finally{T=S}}}})(md)),md}var c0;function DS(){return c0||(c0=1,pd.exports=LS()),pd.exports}var d0;function MS(){if(d0)return un;d0=1;var e=ao(),t=DS();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 a(i,s){u(i,s),u(i+"Capture",s)}function u(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"),d=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 T(i){return d.call(E,i)?!0:d.call(m,i)?!1:h.test(i)?E[i]=!0:(m[i]=!0,!1)}function b(i,s,l,f){if(l!==null&&l.type===0)return!1;switch(typeof s){case"function":case"symbol":return!0;case"boolean":return f?!1:l!==null?!l.acceptsBooleans:(i=i.toLowerCase().slice(0,5),i!=="data-"&&i!=="aria-");default:return!1}}function _(i,s,l,f){if(s===null||typeof s=="undefined"||b(i,s,l,f))return!0;if(f)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 w(i,s,l,f,g,y,x){this.acceptsBooleans=s===2||s===3||s===4,this.attributeName=f,this.attributeNamespace=g,this.mustUseProperty=l,this.propertyName=i,this.type=s,this.sanitizeURL=y,this.removeEmptyString=x}var A={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){A[i]=new w(i,0,!1,i,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(i){var s=i[0];A[s]=new w(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){A[i]=new w(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){A[i]=new w(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){A[i]=new w(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){A[i]=new w(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){A[i]=new w(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){A[i]=new w(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){A[i]=new w(i,5,!1,i.toLowerCase(),null,!1,!1)});var C=/[\-:]([a-z])/g;function I(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(C,I);A[s]=new w(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(C,I);A[s]=new w(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(C,I);A[s]=new w(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){A[i]=new w(i,1,!1,i.toLowerCase(),null,!1,!1)}),A.xlinkHref=new w("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){A[i]=new w(i,1,!1,i.toLowerCase(),null,!0,!0)});function R(i,s,l,f){var g=A.hasOwnProperty(s)?A[s]:null;(g!==null?g.type!==0:f||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(_(s,l,g,f)&&(l=null),f||g===null?T(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,f=g.attributeNamespace,l===null?i.removeAttribute(s):(g=g.type,l=g===3||g===4&&l===!0?"":""+l,f?i.setAttributeNS(f,s,l):i.setAttribute(s,l))))}var F=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,z=Symbol.for("react.element"),D=Symbol.for("react.portal"),q=Symbol.for("react.fragment"),ce=Symbol.for("react.strict_mode"),be=Symbol.for("react.profiler"),j=Symbol.for("react.provider"),ae=Symbol.for("react.context"),he=Symbol.for("react.forward_ref"),ge=Symbol.for("react.suspense"),ue=Symbol.for("react.suspense_list"),Te=Symbol.for("react.memo"),Ne=Symbol.for("react.lazy"),fe=Symbol.for("react.offscreen"),K=Symbol.iterator;function te(i){return i===null||typeof i!="object"?null:(i=K&&i[K]||i["@@iterator"],typeof i=="function"?i:null)}var S=Object.assign,M;function X(i){if(M===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);M=s&&s[1]||""}return`
17
+ `+M+i}var k=!1;function xe(i,s){if(!i||k)return"";k=!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(G){var f=G}Reflect.construct(i,[],s)}else{try{s.call()}catch(G){f=G}i.call(s.prototype)}else{try{throw Error()}catch(G){f=G}i()}}catch(G){if(G&&f&&typeof G.stack=="string"){for(var g=G.stack.split(`
18
18
  `),y=f.stack.split(`
19
- `),_=E.length-1,I=y.length-1;1<=_&&0<=I&&E[_]!==y[I];)I--;for(;1<=_&&0<=I;_--,I--)if(E[_]!==y[I]){if(_!==1||I!==1)do if(_--,I--,0>I||E[_]!==y[I]){var B=`
20
- `+E[_].replace(" at new "," at ");return i.displayName&&B.includes("<anonymous>")&&(B=B.replace("<anonymous>",i.displayName)),B}while(1<=_&&0<=I);break}}}finally{k=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?X(i):""}function Pe(i){switch(i.tag){case 5:return X(i.type);case 16:return X("Lazy");case 13:return X("Suspense");case 19:return X("SuspenseList");case 0:case 2:case 15:return i=xe(i.type,!1),i;case 11:return i=xe(i.type.render,!1),i;case 1:return i=xe(i.type,!0),i;default:return""}}function Oe(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 q:return"Fragment";case D:return"Portal";case be:return"Profiler";case ce:return"StrictMode";case ge:return"Suspense";case ue:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case ae:return(i.displayName||"Context")+".Consumer";case j:return(i._context.displayName||"Context")+".Provider";case he:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case Te:return s=i.displayName||null,s!==null?s:Oe(i.type)||"Memo";case Ne:s=i._payload,i=i._init;try{return Oe(i(s))}catch(l){}}return null}function He(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 Oe(s);case 8:return s===ce?"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 we(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function Ve(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function ut(i){var s=Ve(i)?"checked":"value",l=Object.getOwnPropertyDescriptor(i.constructor.prototype,s),f=""+i[s];if(!i.hasOwnProperty(s)&&typeof l!="undefined"&&typeof l.get=="function"&&typeof l.set=="function"){var E=l.get,y=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return E.call(this)},set:function(_){f=""+_,y.call(this,_)}}),Object.defineProperty(i,s,{enumerable:l.enumerable}),{getValue:function(){return f},setValue:function(_){f=""+_},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function pn(i){i._valueTracker||(i._valueTracker=ut(i))}function Vi(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var l=s.getValue(),f="";return i&&(f=Ve(i)?i.checked?"true":"false":i.value),i=f,i!==l?(s.setValue(i),!0):!1}function Xr(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 Xn(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 ha(i,s){var l=s.defaultValue==null?"":s.defaultValue,f=s.checked!=null?s.checked:s.defaultChecked;l=we(s.value!=null?s.value:l),i._wrapperState={initialChecked:f,initialValue:l,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function pa(i,s){s=s.checked,s!=null&&R(i,"checked",s,!1)}function Wo(i,s){pa(i,s);var l=we(s.value),f=s.type;if(l!=null)f==="number"?(l===0&&i.value===""||i.value!=l)&&(i.value=""+l):i.value!==""+l&&(i.value=""+l);else if(f==="submit"||f==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?qo(i,s.type,l):s.hasOwnProperty("defaultValue")&&qo(i,s.type,we(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function bl(i,s,l){if(s.hasOwnProperty("value")||s.hasOwnProperty("defaultValue")){var f=s.type;if(!(f!=="submit"&&f!=="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 qo(i,s,l){(s!=="number"||Xr(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var Jr=Array.isArray;function Zr(i,s,l,f){if(i=i.options,s){s={};for(var E=0;E<l.length;E++)s["$"+l[E]]=!0;for(l=0;l<i.length;l++)E=s.hasOwnProperty("$"+i[l].value),i[l].selected!==E&&(i[l].selected=E),E&&f&&(i[l].defaultSelected=!0)}else{for(l=""+we(l),s=null,E=0;E<i.length;E++){if(i[E].value===l){i[E].selected=!0,f&&(i[E].defaultSelected=!0);return}s!==null||i[E].disabled||(s=i[E])}s!==null&&(s.selected=!0)}}function ma(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return w({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function xl(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(Jr(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:we(l)}}function _l(i,s){var l=we(s.value),f=we(s.defaultValue);l!=null&&(l=""+l,l!==i.value&&(i.value=l),s.defaultValue==null&&i.defaultValue!==l&&(i.defaultValue=l)),f!=null&&(i.defaultValue=""+f)}function Sl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function Z(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 ye(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?Z(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Be,Ye=(function(i){return typeof MSApp!="undefined"&&MSApp.execUnsafeLocalFunction?function(s,l,f,E){MSApp.execUnsafeLocalFunction(function(){return i(s,l,f,E)})}: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 Qe(i,s){if(s){var l=i.firstChild;if(l&&l===i.lastChild&&l.nodeType===3){l.nodeValue=s;return}}i.textContent=s}var Ht={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},Or=["Webkit","ms","Moz","O"];Object.keys(Ht).forEach(function(i){Or.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),Ht[s]=Ht[i]})});function Mn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||Ht.hasOwnProperty(i)&&Ht[i]?(""+s).trim():s+"px"}function ei(i,s){i=i.style;for(var l in s)if(s.hasOwnProperty(l)){var f=l.indexOf("--")===0,E=Mn(l,s[l],f);l==="float"&&(l="cssFloat"),f?i.setProperty(l,E):i[l]=E}}var Yi=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(Yi[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 yr(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 An=null;function gh(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var Eh=null,Go=null,Ko=null;function jT(i){if(i=Fa(i)){if(typeof Eh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=Wl(s),Eh(i.stateNode,i.type,s))}}function $T(i){Go?Ko?Ko.push(i):Ko=[i]:Go=i}function VT(){if(Go){var i=Go,s=Ko;if(Ko=Go=null,jT(i),s)for(i=0;i<s.length;i++)jT(s[i])}}function YT(i,s){return i(s)}function WT(){}var yh=!1;function qT(i,s,l){if(yh)return i(s,l);yh=!0;try{return YT(i,s,l)}finally{yh=!1,(Go!==null||Ko!==null)&&(WT(),VT())}}function ga(i,s){var l=i.stateNode;if(l===null)return null;var f=Wl(l);if(f===null)return null;l=f[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":(f=!f.disabled)||(i=i.type,f=!(i==="button"||i==="input"||i==="select"||i==="textarea")),i=!f;break e;default:i=!1}if(i)return null;if(l&&typeof l!="function")throw Error(n(231,s,typeof l));return l}var Th=!1;if(c)try{var Ea={};Object.defineProperty(Ea,"passive",{get:function(){Th=!0}}),window.addEventListener("test",Ea,Ea),window.removeEventListener("test",Ea,Ea)}catch(i){Th=!1}function k5(i,s,l,f,E,y,_,I,B){var G=Array.prototype.slice.call(arguments,3);try{s.apply(l,G)}catch(se){this.onError(se)}}var ya=!1,wl=null,Al=!1,bh=null,N5={onError:function(i){ya=!0,wl=i}};function O5(i,s,l,f,E,y,_,I,B){ya=!1,wl=null,k5.apply(N5,arguments)}function I5(i,s,l,f,E,y,_,I,B){if(O5.apply(this,arguments),ya){if(ya){var G=wl;ya=!1,wl=null}else throw Error(n(198));Al||(Al=!0,bh=G)}}function Wi(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 GT(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 KT(i){if(Wi(i)!==i)throw Error(n(188))}function R5(i){var s=i.alternate;if(!s){if(s=Wi(i),s===null)throw Error(n(188));return s!==i?null:i}for(var l=i,f=s;;){var E=l.return;if(E===null)break;var y=E.alternate;if(y===null){if(f=E.return,f!==null){l=f;continue}break}if(E.child===y.child){for(y=E.child;y;){if(y===l)return KT(E),i;if(y===f)return KT(E),s;y=y.sibling}throw Error(n(188))}if(l.return!==f.return)l=E,f=y;else{for(var _=!1,I=E.child;I;){if(I===l){_=!0,l=E,f=y;break}if(I===f){_=!0,f=E,l=y;break}I=I.sibling}if(!_){for(I=y.child;I;){if(I===l){_=!0,l=y,f=E;break}if(I===f){_=!0,f=y,l=E;break}I=I.sibling}if(!_)throw Error(n(189))}}if(l.alternate!==f)throw Error(n(190))}if(l.tag!==3)throw Error(n(188));return l.stateNode.current===l?i:s}function QT(i){return i=R5(i),i!==null?XT(i):null}function XT(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=XT(i);if(s!==null)return s;i=i.sibling}return null}var JT=t.unstable_scheduleCallback,ZT=t.unstable_cancelCallback,P5=t.unstable_shouldYield,L5=t.unstable_requestPaint,_t=t.unstable_now,D5=t.unstable_getCurrentPriorityLevel,xh=t.unstable_ImmediatePriority,eb=t.unstable_UserBlockingPriority,vl=t.unstable_NormalPriority,M5=t.unstable_LowPriority,tb=t.unstable_IdlePriority,Cl=null,Tr=null;function F5(i){if(Tr&&typeof Tr.onCommitFiberRoot=="function")try{Tr.onCommitFiberRoot(Cl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var Jn=Math.clz32?Math.clz32:H5,B5=Math.log,U5=Math.LN2;function H5(i){return i>>>=0,i===0?32:31-(B5(i)/U5|0)|0}var kl=64,Nl=4194304;function Ta(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 Ol(i,s){var l=i.pendingLanes;if(l===0)return 0;var f=0,E=i.suspendedLanes,y=i.pingedLanes,_=l&268435455;if(_!==0){var I=_&~E;I!==0?f=Ta(I):(y&=_,y!==0&&(f=Ta(y)))}else _=l&~E,_!==0?f=Ta(_):y!==0&&(f=Ta(y));if(f===0)return 0;if(s!==0&&s!==f&&(s&E)===0&&(E=f&-f,y=s&-s,E>=y||E===16&&(y&4194240)!==0))return s;if((f&4)!==0&&(f|=l&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=f;0<s;)l=31-Jn(s),E=1<<l,f|=i[l],s&=~E;return f}function z5(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 j5(i,s){for(var l=i.suspendedLanes,f=i.pingedLanes,E=i.expirationTimes,y=i.pendingLanes;0<y;){var _=31-Jn(y),I=1<<_,B=E[_];B===-1?((I&l)===0||(I&f)!==0)&&(E[_]=z5(I,s)):B<=s&&(i.expiredLanes|=I),y&=~I}}function _h(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function nb(){var i=kl;return kl<<=1,(kl&4194240)===0&&(kl=64),i}function Sh(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function ba(i,s,l){i.pendingLanes|=s,s!==536870912&&(i.suspendedLanes=0,i.pingedLanes=0),i=i.eventTimes,s=31-Jn(s),i[s]=l}function $5(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 f=i.eventTimes;for(i=i.expirationTimes;0<l;){var E=31-Jn(l),y=1<<E;s[E]=0,f[E]=-1,i[E]=-1,l&=~y}}function wh(i,s){var l=i.entangledLanes|=s;for(i=i.entanglements;l;){var f=31-Jn(l),E=1<<f;E&s|i[f]&s&&(i[f]|=s),l&=~E}}var nt=0;function rb(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var ib,Ah,ob,sb,ab,vh=!1,Il=[],ti=null,ni=null,ri=null,xa=new Map,_a=new Map,ii=[],V5="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 ub(i,s){switch(i){case"focusin":case"focusout":ti=null;break;case"dragenter":case"dragleave":ni=null;break;case"mouseover":case"mouseout":ri=null;break;case"pointerover":case"pointerout":xa.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":_a.delete(s.pointerId)}}function Sa(i,s,l,f,E,y){return i===null||i.nativeEvent!==y?(i={blockedOn:s,domEventName:l,eventSystemFlags:f,nativeEvent:y,targetContainers:[E]},s!==null&&(s=Fa(s),s!==null&&Ah(s)),i):(i.eventSystemFlags|=f,s=i.targetContainers,E!==null&&s.indexOf(E)===-1&&s.push(E),i)}function Y5(i,s,l,f,E){switch(s){case"focusin":return ti=Sa(ti,i,s,l,f,E),!0;case"dragenter":return ni=Sa(ni,i,s,l,f,E),!0;case"mouseover":return ri=Sa(ri,i,s,l,f,E),!0;case"pointerover":var y=E.pointerId;return xa.set(y,Sa(xa.get(y)||null,i,s,l,f,E)),!0;case"gotpointercapture":return y=E.pointerId,_a.set(y,Sa(_a.get(y)||null,i,s,l,f,E)),!0}return!1}function lb(i){var s=qi(i.target);if(s!==null){var l=Wi(s);if(l!==null){if(s=l.tag,s===13){if(s=GT(l),s!==null){i.blockedOn=s,ab(i.priority,function(){ob(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 Rl(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=kh(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var f=new l.constructor(l.type,l);An=f,l.target.dispatchEvent(f),An=null}else return s=Fa(l),s!==null&&Ah(s),i.blockedOn=l,!1;s.shift()}return!0}function cb(i,s,l){Rl(i)&&l.delete(s)}function W5(){vh=!1,ti!==null&&Rl(ti)&&(ti=null),ni!==null&&Rl(ni)&&(ni=null),ri!==null&&Rl(ri)&&(ri=null),xa.forEach(cb),_a.forEach(cb)}function wa(i,s){i.blockedOn===s&&(i.blockedOn=null,vh||(vh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,W5)))}function Aa(i){function s(E){return wa(E,i)}if(0<Il.length){wa(Il[0],i);for(var l=1;l<Il.length;l++){var f=Il[l];f.blockedOn===i&&(f.blockedOn=null)}}for(ti!==null&&wa(ti,i),ni!==null&&wa(ni,i),ri!==null&&wa(ri,i),xa.forEach(s),_a.forEach(s),l=0;l<ii.length;l++)f=ii[l],f.blockedOn===i&&(f.blockedOn=null);for(;0<ii.length&&(l=ii[0],l.blockedOn===null);)lb(l),l.blockedOn===null&&ii.shift()}var Qo=F.ReactCurrentBatchConfig,Pl=!0;function q5(i,s,l,f){var E=nt,y=Qo.transition;Qo.transition=null;try{nt=1,Ch(i,s,l,f)}finally{nt=E,Qo.transition=y}}function G5(i,s,l,f){var E=nt,y=Qo.transition;Qo.transition=null;try{nt=4,Ch(i,s,l,f)}finally{nt=E,Qo.transition=y}}function Ch(i,s,l,f){if(Pl){var E=kh(i,s,l,f);if(E===null)Yh(i,s,f,Ll,l),ub(i,f);else if(Y5(E,i,s,l,f))f.stopPropagation();else if(ub(i,f),s&4&&-1<V5.indexOf(i)){for(;E!==null;){var y=Fa(E);if(y!==null&&ib(y),y=kh(i,s,l,f),y===null&&Yh(i,s,f,Ll,l),y===E)break;E=y}E!==null&&f.stopPropagation()}else Yh(i,s,f,null,l)}}var Ll=null;function kh(i,s,l,f){if(Ll=null,i=gh(f),i=qi(i),i!==null)if(s=Wi(i),s===null)i=null;else if(l=s.tag,l===13){if(i=GT(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 Ll=i,null}function db(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(D5()){case xh:return 1;case eb:return 4;case vl:case M5:return 16;case tb:return 536870912;default:return 16}default:return 16}}var oi=null,Nh=null,Dl=null;function fb(){if(Dl)return Dl;var i,s=Nh,l=s.length,f,E="value"in oi?oi.value:oi.textContent,y=E.length;for(i=0;i<l&&s[i]===E[i];i++);var _=l-i;for(f=1;f<=_&&s[l-f]===E[y-f];f++);return Dl=E.slice(i,1<f?1-f:void 0)}function Ml(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 Fl(){return!0}function hb(){return!1}function vn(i){function s(l,f,E,y,_){this._reactName=l,this._targetInst=E,this.type=f,this.nativeEvent=y,this.target=_,this.currentTarget=null;for(var I in i)i.hasOwnProperty(I)&&(l=i[I],this[I]=l?l(y):y[I]);return this.isDefaultPrevented=(y.defaultPrevented!=null?y.defaultPrevented:y.returnValue===!1)?Fl:hb,this.isPropagationStopped=hb,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=Fl)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Fl)},persist:function(){},isPersistent:Fl}),s}var Xo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Oh=vn(Xo),va=w({},Xo,{view:0,detail:0}),K5=vn(va),Ih,Rh,Ca,Bl=w({},va,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Lh,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!==Ca&&(Ca&&i.type==="mousemove"?(Ih=i.screenX-Ca.screenX,Rh=i.screenY-Ca.screenY):Rh=Ih=0,Ca=i),Ih)},movementY:function(i){return"movementY"in i?i.movementY:Rh}}),pb=vn(Bl),Q5=w({},Bl,{dataTransfer:0}),X5=vn(Q5),J5=w({},va,{relatedTarget:0}),Ph=vn(J5),Z5=w({},Xo,{animationName:0,elapsedTime:0,pseudoElement:0}),e8=vn(Z5),t8=w({},Xo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),n8=vn(t8),r8=w({},Xo,{data:0}),mb=vn(r8),i8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},o8={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"},s8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function a8(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=s8[i])?!!s[i]:!1}function Lh(){return a8}var u8=w({},va,{key:function(i){if(i.key){var s=i8[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=Ml(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?o8[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Lh,charCode:function(i){return i.type==="keypress"?Ml(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?Ml(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),l8=vn(u8),c8=w({},Bl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),gb=vn(c8),d8=w({},va,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Lh}),f8=vn(d8),h8=w({},Xo,{propertyName:0,elapsedTime:0,pseudoElement:0}),p8=vn(h8),m8=w({},Bl,{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}),g8=vn(m8),E8=[9,13,27,32],Dh=c&&"CompositionEvent"in window,ka=null;c&&"documentMode"in document&&(ka=document.documentMode);var y8=c&&"TextEvent"in window&&!ka,Eb=c&&(!Dh||ka&&8<ka&&11>=ka),yb=" ",Tb=!1;function bb(i,s){switch(i){case"keyup":return E8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function xb(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var Jo=!1;function T8(i,s){switch(i){case"compositionend":return xb(s);case"keypress":return s.which!==32?null:(Tb=!0,yb);case"textInput":return i=s.data,i===yb&&Tb?null:i;default:return null}}function b8(i,s){if(Jo)return i==="compositionend"||!Dh&&bb(i,s)?(i=fb(),Dl=Nh=oi=null,Jo=!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 Eb&&s.locale!=="ko"?null:s.data;default:return null}}var x8={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 _b(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!x8[i.type]:s==="textarea"}function Sb(i,s,l,f){$T(f),s=$l(s,"onChange"),0<s.length&&(l=new Oh("onChange","change",null,l,f),i.push({event:l,listeners:s}))}var Na=null,Oa=null;function _8(i){zb(i,0)}function Ul(i){var s=rs(i);if(Vi(s))return i}function S8(i,s){if(i==="change")return s}var wb=!1;if(c){var Mh;if(c){var Fh="oninput"in document;if(!Fh){var Ab=document.createElement("div");Ab.setAttribute("oninput","return;"),Fh=typeof Ab.oninput=="function"}Mh=Fh}else Mh=!1;wb=Mh&&(!document.documentMode||9<document.documentMode)}function vb(){Na&&(Na.detachEvent("onpropertychange",Cb),Oa=Na=null)}function Cb(i){if(i.propertyName==="value"&&Ul(Oa)){var s=[];Sb(s,Oa,i,gh(i)),qT(_8,s)}}function w8(i,s,l){i==="focusin"?(vb(),Na=s,Oa=l,Na.attachEvent("onpropertychange",Cb)):i==="focusout"&&vb()}function A8(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return Ul(Oa)}function v8(i,s){if(i==="click")return Ul(s)}function C8(i,s){if(i==="input"||i==="change")return Ul(s)}function k8(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var Zn=typeof Object.is=="function"?Object.is:k8;function Ia(i,s){if(Zn(i,s))return!0;if(typeof i!="object"||i===null||typeof s!="object"||s===null)return!1;var l=Object.keys(i),f=Object.keys(s);if(l.length!==f.length)return!1;for(f=0;f<l.length;f++){var E=l[f];if(!d.call(s,E)||!Zn(i[E],s[E]))return!1}return!0}function kb(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function Nb(i,s){var l=kb(i);i=0;for(var f;l;){if(l.nodeType===3){if(f=i+l.textContent.length,i<=s&&f>=s)return{node:l,offset:s-i};i=f}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=kb(l)}}function Ob(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?Ob(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function Ib(){for(var i=window,s=Xr();s instanceof i.HTMLIFrameElement;){try{var l=typeof s.contentWindow.location.href=="string"}catch(f){l=!1}if(l)i=s.contentWindow;else break;s=Xr(i.document)}return s}function Bh(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 N8(i){var s=Ib(),l=i.focusedElem,f=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&Ob(l.ownerDocument.documentElement,l)){if(f!==null&&Bh(l)){if(s=f.start,i=f.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 E=l.textContent.length,y=Math.min(f.start,E);f=f.end===void 0?y:Math.min(f.end,E),!i.extend&&y>f&&(E=f,f=y,y=E),E=Nb(l,y);var _=Nb(l,f);E&&_&&(i.rangeCount!==1||i.anchorNode!==E.node||i.anchorOffset!==E.offset||i.focusNode!==_.node||i.focusOffset!==_.offset)&&(s=s.createRange(),s.setStart(E.node,E.offset),i.removeAllRanges(),y>f?(i.addRange(s),i.extend(_.node,_.offset)):(s.setEnd(_.node,_.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 O8=c&&"documentMode"in document&&11>=document.documentMode,Zo=null,Uh=null,Ra=null,Hh=!1;function Rb(i,s,l){var f=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Hh||Zo==null||Zo!==Xr(f)||(f=Zo,"selectionStart"in f&&Bh(f)?f={start:f.selectionStart,end:f.selectionEnd}:(f=(f.ownerDocument&&f.ownerDocument.defaultView||window).getSelection(),f={anchorNode:f.anchorNode,anchorOffset:f.anchorOffset,focusNode:f.focusNode,focusOffset:f.focusOffset}),Ra&&Ia(Ra,f)||(Ra=f,f=$l(Uh,"onSelect"),0<f.length&&(s=new Oh("onSelect","select",null,s,l),i.push({event:s,listeners:f}),s.target=Zo)))}function Hl(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var es={animationend:Hl("Animation","AnimationEnd"),animationiteration:Hl("Animation","AnimationIteration"),animationstart:Hl("Animation","AnimationStart"),transitionend:Hl("Transition","TransitionEnd")},zh={},Pb={};c&&(Pb=document.createElement("div").style,"AnimationEvent"in window||(delete es.animationend.animation,delete es.animationiteration.animation,delete es.animationstart.animation),"TransitionEvent"in window||delete es.transitionend.transition);function zl(i){if(zh[i])return zh[i];if(!es[i])return i;var s=es[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in Pb)return zh[i]=s[l];return i}var Lb=zl("animationend"),Db=zl("animationiteration"),Mb=zl("animationstart"),Fb=zl("transitionend"),Bb=new Map,Ub="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 si(i,s){Bb.set(i,s),a(s,[i])}for(var jh=0;jh<Ub.length;jh++){var $h=Ub[jh],I8=$h.toLowerCase(),R8=$h[0].toUpperCase()+$h.slice(1);si(I8,"on"+R8)}si(Lb,"onAnimationEnd"),si(Db,"onAnimationIteration"),si(Mb,"onAnimationStart"),si("dblclick","onDoubleClick"),si("focusin","onFocus"),si("focusout","onBlur"),si(Fb,"onTransitionEnd"),u("onMouseEnter",["mouseout","mouseover"]),u("onMouseLeave",["mouseout","mouseover"]),u("onPointerEnter",["pointerout","pointerover"]),u("onPointerLeave",["pointerout","pointerover"]),a("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),a("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),a("onBeforeInput",["compositionend","keypress","textInput","paste"]),a("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Pa="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(" "),P8=new Set("cancel close invalid load scroll toggle".split(" ").concat(Pa));function Hb(i,s,l){var f=i.type||"unknown-event";i.currentTarget=l,I5(f,s,void 0,i),i.currentTarget=null}function zb(i,s){s=(s&4)!==0;for(var l=0;l<i.length;l++){var f=i[l],E=f.event;f=f.listeners;e:{var y=void 0;if(s)for(var _=f.length-1;0<=_;_--){var I=f[_],B=I.instance,G=I.currentTarget;if(I=I.listener,B!==y&&E.isPropagationStopped())break e;Hb(E,I,G),y=B}else for(_=0;_<f.length;_++){if(I=f[_],B=I.instance,G=I.currentTarget,I=I.listener,B!==y&&E.isPropagationStopped())break e;Hb(E,I,G),y=B}}}if(Al)throw i=bh,Al=!1,bh=null,i}function lt(i,s){var l=s[Xh];l===void 0&&(l=s[Xh]=new Set);var f=i+"__bubble";l.has(f)||(jb(s,i,2,!1),l.add(f))}function Vh(i,s,l){var f=0;s&&(f|=4),jb(l,i,f,s)}var jl="_reactListening"+Math.random().toString(36).slice(2);function La(i){if(!i[jl]){i[jl]=!0,r.forEach(function(l){l!=="selectionchange"&&(P8.has(l)||Vh(l,!1,i),Vh(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[jl]||(s[jl]=!0,Vh("selectionchange",!1,s))}}function jb(i,s,l,f){switch(db(s)){case 1:var E=q5;break;case 4:E=G5;break;default:E=Ch}l=E.bind(null,s,l,i),E=void 0,!Th||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(E=!0),f?E!==void 0?i.addEventListener(s,l,{capture:!0,passive:E}):i.addEventListener(s,l,!0):E!==void 0?i.addEventListener(s,l,{passive:E}):i.addEventListener(s,l,!1)}function Yh(i,s,l,f,E){var y=f;if((s&1)===0&&(s&2)===0&&f!==null)e:for(;;){if(f===null)return;var _=f.tag;if(_===3||_===4){var I=f.stateNode.containerInfo;if(I===E||I.nodeType===8&&I.parentNode===E)break;if(_===4)for(_=f.return;_!==null;){var B=_.tag;if((B===3||B===4)&&(B=_.stateNode.containerInfo,B===E||B.nodeType===8&&B.parentNode===E))return;_=_.return}for(;I!==null;){if(_=qi(I),_===null)return;if(B=_.tag,B===5||B===6){f=y=_;continue e}I=I.parentNode}}f=f.return}qT(function(){var G=y,se=gh(l),de=[];e:{var ie=Bb.get(i);if(ie!==void 0){var _e=Oh,Ae=i;switch(i){case"keypress":if(Ml(l)===0)break e;case"keydown":case"keyup":_e=l8;break;case"focusin":Ae="focus",_e=Ph;break;case"focusout":Ae="blur",_e=Ph;break;case"beforeblur":case"afterblur":_e=Ph;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":_e=pb;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":_e=X5;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":_e=f8;break;case Lb:case Db:case Mb:_e=e8;break;case Fb:_e=p8;break;case"scroll":_e=K5;break;case"wheel":_e=g8;break;case"copy":case"cut":case"paste":_e=n8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":_e=gb}var Ce=(s&4)!==0,St=!Ce&&i==="scroll",V=Ce?ie!==null?ie+"Capture":null:ie;Ce=[];for(var H=G,W;H!==null;){W=H;var Ee=W.stateNode;if(W.tag===5&&Ee!==null&&(W=Ee,V!==null&&(Ee=ga(H,V),Ee!=null&&Ce.push(Da(H,Ee,W)))),St)break;H=H.return}0<Ce.length&&(ie=new _e(ie,Ae,null,l,se),de.push({event:ie,listeners:Ce}))}}if((s&7)===0){e:{if(ie=i==="mouseover"||i==="pointerover",_e=i==="mouseout"||i==="pointerout",ie&&l!==An&&(Ae=l.relatedTarget||l.fromElement)&&(qi(Ae)||Ae[Ir]))break e;if((_e||ie)&&(ie=se.window===se?se:(ie=se.ownerDocument)?ie.defaultView||ie.parentWindow:window,_e?(Ae=l.relatedTarget||l.toElement,_e=G,Ae=Ae?qi(Ae):null,Ae!==null&&(St=Wi(Ae),Ae!==St||Ae.tag!==5&&Ae.tag!==6)&&(Ae=null)):(_e=null,Ae=G),_e!==Ae)){if(Ce=pb,Ee="onMouseLeave",V="onMouseEnter",H="mouse",(i==="pointerout"||i==="pointerover")&&(Ce=gb,Ee="onPointerLeave",V="onPointerEnter",H="pointer"),St=_e==null?ie:rs(_e),W=Ae==null?ie:rs(Ae),ie=new Ce(Ee,H+"leave",_e,l,se),ie.target=St,ie.relatedTarget=W,Ee=null,qi(se)===G&&(Ce=new Ce(V,H+"enter",Ae,l,se),Ce.target=W,Ce.relatedTarget=St,Ee=Ce),St=Ee,_e&&Ae)t:{for(Ce=_e,V=Ae,H=0,W=Ce;W;W=ts(W))H++;for(W=0,Ee=V;Ee;Ee=ts(Ee))W++;for(;0<H-W;)Ce=ts(Ce),H--;for(;0<W-H;)V=ts(V),W--;for(;H--;){if(Ce===V||V!==null&&Ce===V.alternate)break t;Ce=ts(Ce),V=ts(V)}Ce=null}else Ce=null;_e!==null&&$b(de,ie,_e,Ce,!1),Ae!==null&&St!==null&&$b(de,St,Ae,Ce,!0)}}e:{if(ie=G?rs(G):window,_e=ie.nodeName&&ie.nodeName.toLowerCase(),_e==="select"||_e==="input"&&ie.type==="file")var ke=S8;else if(_b(ie))if(wb)ke=C8;else{ke=A8;var De=w8}else(_e=ie.nodeName)&&_e.toLowerCase()==="input"&&(ie.type==="checkbox"||ie.type==="radio")&&(ke=v8);if(ke&&(ke=ke(i,G))){Sb(de,ke,l,se);break e}De&&De(i,ie,G),i==="focusout"&&(De=ie._wrapperState)&&De.controlled&&ie.type==="number"&&qo(ie,"number",ie.value)}switch(De=G?rs(G):window,i){case"focusin":(_b(De)||De.contentEditable==="true")&&(Zo=De,Uh=G,Ra=null);break;case"focusout":Ra=Uh=Zo=null;break;case"mousedown":Hh=!0;break;case"contextmenu":case"mouseup":case"dragend":Hh=!1,Rb(de,l,se);break;case"selectionchange":if(O8)break;case"keydown":case"keyup":Rb(de,l,se)}var Me;if(Dh)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 Jo?bb(i,l)&&(Ue="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(Ue="onCompositionStart");Ue&&(Eb&&l.locale!=="ko"&&(Jo||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&Jo&&(Me=fb()):(oi=se,Nh="value"in oi?oi.value:oi.textContent,Jo=!0)),De=$l(G,Ue),0<De.length&&(Ue=new mb(Ue,i,null,l,se),de.push({event:Ue,listeners:De}),Me?Ue.data=Me:(Me=xb(l),Me!==null&&(Ue.data=Me)))),(Me=y8?T8(i,l):b8(i,l))&&(G=$l(G,"onBeforeInput"),0<G.length&&(se=new mb("onBeforeInput","beforeinput",null,l,se),de.push({event:se,listeners:G}),se.data=Me))}zb(de,s)})}function Da(i,s,l){return{instance:i,listener:s,currentTarget:l}}function $l(i,s){for(var l=s+"Capture",f=[];i!==null;){var E=i,y=E.stateNode;E.tag===5&&y!==null&&(E=y,y=ga(i,l),y!=null&&f.unshift(Da(i,y,E)),y=ga(i,s),y!=null&&f.push(Da(i,y,E))),i=i.return}return f}function ts(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function $b(i,s,l,f,E){for(var y=s._reactName,_=[];l!==null&&l!==f;){var I=l,B=I.alternate,G=I.stateNode;if(B!==null&&B===f)break;I.tag===5&&G!==null&&(I=G,E?(B=ga(l,y),B!=null&&_.unshift(Da(l,B,I))):E||(B=ga(l,y),B!=null&&_.push(Da(l,B,I)))),l=l.return}_.length!==0&&i.push({event:s,listeners:_})}var L8=/\r\n?/g,D8=/\u0000|\uFFFD/g;function Vb(i){return(typeof i=="string"?i:""+i).replace(L8,`
21
- `).replace(D8,"")}function Vl(i,s,l){if(s=Vb(s),Vb(i)!==s&&l)throw Error(n(425))}function Yl(){}var Wh=null,qh=null;function Gh(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 Kh=typeof setTimeout=="function"?setTimeout:void 0,M8=typeof clearTimeout=="function"?clearTimeout:void 0,Yb=typeof Promise=="function"?Promise:void 0,F8=typeof queueMicrotask=="function"?queueMicrotask:typeof Yb!="undefined"?function(i){return Yb.resolve(null).then(i).catch(B8)}:Kh;function B8(i){setTimeout(function(){throw i})}function Qh(i,s){var l=s,f=0;do{var E=l.nextSibling;if(i.removeChild(l),E&&E.nodeType===8)if(l=E.data,l==="/$"){if(f===0){i.removeChild(E),Aa(s);return}f--}else l!=="$"&&l!=="$?"&&l!=="$!"||f++;l=E}while(l);Aa(s)}function ai(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 Wb(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 ns=Math.random().toString(36).slice(2),br="__reactFiber$"+ns,Ma="__reactProps$"+ns,Ir="__reactContainer$"+ns,Xh="__reactEvents$"+ns,U8="__reactListeners$"+ns,H8="__reactHandles$"+ns;function qi(i){var s=i[br];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Ir]||l[br]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=Wb(i);i!==null;){if(l=i[br])return l;i=Wb(i)}return s}i=l,l=i.parentNode}return null}function Fa(i){return i=i[br]||i[Ir],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function rs(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function Wl(i){return i[Ma]||null}var Jh=[],is=-1;function ui(i){return{current:i}}function ct(i){0>is||(i.current=Jh[is],Jh[is]=null,is--)}function at(i,s){is++,Jh[is]=i.current,i.current=s}var li={},Kt=ui(li),mn=ui(!1),Gi=li;function os(i,s){var l=i.type.contextTypes;if(!l)return li;var f=i.stateNode;if(f&&f.__reactInternalMemoizedUnmaskedChildContext===s)return f.__reactInternalMemoizedMaskedChildContext;var E={},y;for(y in l)E[y]=s[y];return f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=E),E}function gn(i){return i=i.childContextTypes,i!=null}function ql(){ct(mn),ct(Kt)}function qb(i,s,l){if(Kt.current!==li)throw Error(n(168));at(Kt,s),at(mn,l)}function Gb(i,s,l){var f=i.stateNode;if(s=s.childContextTypes,typeof f.getChildContext!="function")return l;f=f.getChildContext();for(var E in f)if(!(E in s))throw Error(n(108,He(i)||"Unknown",E));return w({},l,f)}function Gl(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||li,Gi=Kt.current,at(Kt,i),at(mn,mn.current),!0}function Kb(i,s,l){var f=i.stateNode;if(!f)throw Error(n(169));l?(i=Gb(i,s,Gi),f.__reactInternalMemoizedMergedChildContext=i,ct(mn),ct(Kt),at(Kt,i)):ct(mn),at(mn,l)}var Rr=null,Kl=!1,Zh=!1;function Qb(i){Rr===null?Rr=[i]:Rr.push(i)}function z8(i){Kl=!0,Qb(i)}function ci(){if(!Zh&&Rr!==null){Zh=!0;var i=0,s=nt;try{var l=Rr;for(nt=1;i<l.length;i++){var f=l[i];do f=f(!0);while(f!==null)}Rr=null,Kl=!1}catch(E){throw Rr!==null&&(Rr=Rr.slice(i+1)),JT(xh,ci),E}finally{nt=s,Zh=!1}}return null}var ss=[],as=0,Ql=null,Xl=0,Fn=[],Bn=0,Ki=null,Pr=1,Lr="";function Qi(i,s){ss[as++]=Xl,ss[as++]=Ql,Ql=i,Xl=s}function Xb(i,s,l){Fn[Bn++]=Pr,Fn[Bn++]=Lr,Fn[Bn++]=Ki,Ki=i;var f=Pr;i=Lr;var E=32-Jn(f)-1;f&=~(1<<E),l+=1;var y=32-Jn(s)+E;if(30<y){var _=E-E%5;y=(f&(1<<_)-1).toString(32),f>>=_,E-=_,Pr=1<<32-Jn(s)+E|l<<E|f,Lr=y+i}else Pr=1<<y|l<<E|f,Lr=i}function ep(i){i.return!==null&&(Qi(i,1),Xb(i,1,0))}function tp(i){for(;i===Ql;)Ql=ss[--as],ss[as]=null,Xl=ss[--as],ss[as]=null;for(;i===Ki;)Ki=Fn[--Bn],Fn[Bn]=null,Lr=Fn[--Bn],Fn[Bn]=null,Pr=Fn[--Bn],Fn[Bn]=null}var Cn=null,kn=null,pt=!1,er=null;function Jb(i,s){var l=jn(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 Zb(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,Cn=i,kn=ai(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Cn=i,kn=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(l=Ki!==null?{id:Pr,overflow:Lr}:null,i.memoizedState={dehydrated:s,treeContext:l,retryLane:1073741824},l=jn(18,null,null,0),l.stateNode=s,l.return=i,i.child=l,Cn=i,kn=null,!0):!1;default:return!1}}function np(i){return(i.mode&1)!==0&&(i.flags&128)===0}function rp(i){if(pt){var s=kn;if(s){var l=s;if(!Zb(i,s)){if(np(i))throw Error(n(418));s=ai(l.nextSibling);var f=Cn;s&&Zb(i,s)?Jb(f,l):(i.flags=i.flags&-4097|2,pt=!1,Cn=i)}}else{if(np(i))throw Error(n(418));i.flags=i.flags&-4097|2,pt=!1,Cn=i}}}function e2(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Cn=i}function Jl(i){if(i!==Cn)return!1;if(!pt)return e2(i),pt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!Gh(i.type,i.memoizedProps)),s&&(s=kn)){if(np(i))throw t2(),Error(n(418));for(;s;)Jb(i,s),s=ai(s.nextSibling)}if(e2(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){kn=ai(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}kn=null}}else kn=Cn?ai(i.stateNode.nextSibling):null;return!0}function t2(){for(var i=kn;i;)i=ai(i.nextSibling)}function us(){kn=Cn=null,pt=!1}function ip(i){er===null?er=[i]:er.push(i)}var j8=F.ReactCurrentBatchConfig;function Ba(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 f=l.stateNode}if(!f)throw Error(n(147,i));var E=f,y=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===y?s.ref:(s=function(_){var I=E.refs;_===null?delete I[y]:I[y]=_},s._stringRef=y,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function Zl(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function n2(i){var s=i._init;return s(i._payload)}function r2(i){function s(V,H){if(i){var W=V.deletions;W===null?(V.deletions=[H],V.flags|=16):W.push(H)}}function l(V,H){if(!i)return null;for(;H!==null;)s(V,H),H=H.sibling;return null}function f(V,H){for(V=new Map;H!==null;)H.key!==null?V.set(H.key,H):V.set(H.index,H),H=H.sibling;return V}function E(V,H){return V=yi(V,H),V.index=0,V.sibling=null,V}function y(V,H,W){return V.index=W,i?(W=V.alternate,W!==null?(W=W.index,W<H?(V.flags|=2,H):W):(V.flags|=2,H)):(V.flags|=1048576,H)}function _(V){return i&&V.alternate===null&&(V.flags|=2),V}function I(V,H,W,Ee){return H===null||H.tag!==6?(H=Kp(W,V.mode,Ee),H.return=V,H):(H=E(H,W),H.return=V,H)}function B(V,H,W,Ee){var ke=W.type;return ke===q?se(V,H,W.props.children,Ee,W.key):H!==null&&(H.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ne&&n2(ke)===H.type)?(Ee=E(H,W.props),Ee.ref=Ba(V,H,W),Ee.return=V,Ee):(Ee=Sc(W.type,W.key,W.props,null,V.mode,Ee),Ee.ref=Ba(V,H,W),Ee.return=V,Ee)}function G(V,H,W,Ee){return H===null||H.tag!==4||H.stateNode.containerInfo!==W.containerInfo||H.stateNode.implementation!==W.implementation?(H=Qp(W,V.mode,Ee),H.return=V,H):(H=E(H,W.children||[]),H.return=V,H)}function se(V,H,W,Ee,ke){return H===null||H.tag!==7?(H=io(W,V.mode,Ee,ke),H.return=V,H):(H=E(H,W),H.return=V,H)}function de(V,H,W){if(typeof H=="string"&&H!==""||typeof H=="number")return H=Kp(""+H,V.mode,W),H.return=V,H;if(typeof H=="object"&&H!==null){switch(H.$$typeof){case z:return W=Sc(H.type,H.key,H.props,null,V.mode,W),W.ref=Ba(V,null,H),W.return=V,W;case D:return H=Qp(H,V.mode,W),H.return=V,H;case Ne:var Ee=H._init;return de(V,Ee(H._payload),W)}if(Jr(H)||te(H))return H=io(H,V.mode,W,null),H.return=V,H;Zl(V,H)}return null}function ie(V,H,W,Ee){var ke=H!==null?H.key:null;if(typeof W=="string"&&W!==""||typeof W=="number")return ke!==null?null:I(V,H,""+W,Ee);if(typeof W=="object"&&W!==null){switch(W.$$typeof){case z:return W.key===ke?B(V,H,W,Ee):null;case D:return W.key===ke?G(V,H,W,Ee):null;case Ne:return ke=W._init,ie(V,H,ke(W._payload),Ee)}if(Jr(W)||te(W))return ke!==null?null:se(V,H,W,Ee,null);Zl(V,W)}return null}function _e(V,H,W,Ee,ke){if(typeof Ee=="string"&&Ee!==""||typeof Ee=="number")return V=V.get(W)||null,I(H,V,""+Ee,ke);if(typeof Ee=="object"&&Ee!==null){switch(Ee.$$typeof){case z:return V=V.get(Ee.key===null?W:Ee.key)||null,B(H,V,Ee,ke);case D:return V=V.get(Ee.key===null?W:Ee.key)||null,G(H,V,Ee,ke);case Ne:var De=Ee._init;return _e(V,H,W,De(Ee._payload),ke)}if(Jr(Ee)||te(Ee))return V=V.get(W)||null,se(H,V,Ee,ke,null);Zl(H,Ee)}return null}function Ae(V,H,W,Ee){for(var ke=null,De=null,Me=H,Ue=H=0,Ut=null;Me!==null&&Ue<W.length;Ue++){Me.index>Ue?(Ut=Me,Me=null):Ut=Me.sibling;var Ze=ie(V,Me,W[Ue],Ee);if(Ze===null){Me===null&&(Me=Ut);break}i&&Me&&Ze.alternate===null&&s(V,Me),H=y(Ze,H,Ue),De===null?ke=Ze:De.sibling=Ze,De=Ze,Me=Ut}if(Ue===W.length)return l(V,Me),pt&&Qi(V,Ue),ke;if(Me===null){for(;Ue<W.length;Ue++)Me=de(V,W[Ue],Ee),Me!==null&&(H=y(Me,H,Ue),De===null?ke=Me:De.sibling=Me,De=Me);return pt&&Qi(V,Ue),ke}for(Me=f(V,Me);Ue<W.length;Ue++)Ut=_e(Me,V,Ue,W[Ue],Ee),Ut!==null&&(i&&Ut.alternate!==null&&Me.delete(Ut.key===null?Ue:Ut.key),H=y(Ut,H,Ue),De===null?ke=Ut:De.sibling=Ut,De=Ut);return i&&Me.forEach(function(Ti){return s(V,Ti)}),pt&&Qi(V,Ue),ke}function Ce(V,H,W,Ee){var ke=te(W);if(typeof ke!="function")throw Error(n(150));if(W=ke.call(W),W==null)throw Error(n(151));for(var De=ke=null,Me=H,Ue=H=0,Ut=null,Ze=W.next();Me!==null&&!Ze.done;Ue++,Ze=W.next()){Me.index>Ue?(Ut=Me,Me=null):Ut=Me.sibling;var Ti=ie(V,Me,Ze.value,Ee);if(Ti===null){Me===null&&(Me=Ut);break}i&&Me&&Ti.alternate===null&&s(V,Me),H=y(Ti,H,Ue),De===null?ke=Ti:De.sibling=Ti,De=Ti,Me=Ut}if(Ze.done)return l(V,Me),pt&&Qi(V,Ue),ke;if(Me===null){for(;!Ze.done;Ue++,Ze=W.next())Ze=de(V,Ze.value,Ee),Ze!==null&&(H=y(Ze,H,Ue),De===null?ke=Ze:De.sibling=Ze,De=Ze);return pt&&Qi(V,Ue),ke}for(Me=f(V,Me);!Ze.done;Ue++,Ze=W.next())Ze=_e(Me,V,Ue,Ze.value,Ee),Ze!==null&&(i&&Ze.alternate!==null&&Me.delete(Ze.key===null?Ue:Ze.key),H=y(Ze,H,Ue),De===null?ke=Ze:De.sibling=Ze,De=Ze);return i&&Me.forEach(function(xM){return s(V,xM)}),pt&&Qi(V,Ue),ke}function St(V,H,W,Ee){if(typeof W=="object"&&W!==null&&W.type===q&&W.key===null&&(W=W.props.children),typeof W=="object"&&W!==null){switch(W.$$typeof){case z:e:{for(var ke=W.key,De=H;De!==null;){if(De.key===ke){if(ke=W.type,ke===q){if(De.tag===7){l(V,De.sibling),H=E(De,W.props.children),H.return=V,V=H;break e}}else if(De.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ne&&n2(ke)===De.type){l(V,De.sibling),H=E(De,W.props),H.ref=Ba(V,De,W),H.return=V,V=H;break e}l(V,De);break}else s(V,De);De=De.sibling}W.type===q?(H=io(W.props.children,V.mode,Ee,W.key),H.return=V,V=H):(Ee=Sc(W.type,W.key,W.props,null,V.mode,Ee),Ee.ref=Ba(V,H,W),Ee.return=V,V=Ee)}return _(V);case D:e:{for(De=W.key;H!==null;){if(H.key===De)if(H.tag===4&&H.stateNode.containerInfo===W.containerInfo&&H.stateNode.implementation===W.implementation){l(V,H.sibling),H=E(H,W.children||[]),H.return=V,V=H;break e}else{l(V,H);break}else s(V,H);H=H.sibling}H=Qp(W,V.mode,Ee),H.return=V,V=H}return _(V);case Ne:return De=W._init,St(V,H,De(W._payload),Ee)}if(Jr(W))return Ae(V,H,W,Ee);if(te(W))return Ce(V,H,W,Ee);Zl(V,W)}return typeof W=="string"&&W!==""||typeof W=="number"?(W=""+W,H!==null&&H.tag===6?(l(V,H.sibling),H=E(H,W),H.return=V,V=H):(l(V,H),H=Kp(W,V.mode,Ee),H.return=V,V=H),_(V)):l(V,H)}return St}var ls=r2(!0),i2=r2(!1),ec=ui(null),tc=null,cs=null,op=null;function sp(){op=cs=tc=null}function ap(i){var s=ec.current;ct(ec),i._currentValue=s}function up(i,s,l){for(;i!==null;){var f=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,f!==null&&(f.childLanes|=s)):f!==null&&(f.childLanes&s)!==s&&(f.childLanes|=s),i===l)break;i=i.return}}function ds(i,s){tc=i,op=cs=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(En=!0),i.firstContext=null)}function Un(i){var s=i._currentValue;if(op!==i)if(i={context:i,memoizedValue:s,next:null},cs===null){if(tc===null)throw Error(n(308));cs=i,tc.dependencies={lanes:0,firstContext:i}}else cs=cs.next=i;return s}var Xi=null;function lp(i){Xi===null?Xi=[i]:Xi.push(i)}function o2(i,s,l,f){var E=s.interleaved;return E===null?(l.next=l,lp(s)):(l.next=E.next,E.next=l),s.interleaved=l,Dr(i,f)}function Dr(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 di=!1;function cp(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function s2(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 Mr(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function fi(i,s,l){var f=i.updateQueue;if(f===null)return null;if(f=f.shared,(Xe&2)!==0){var E=f.pending;return E===null?s.next=s:(s.next=E.next,E.next=s),f.pending=s,Dr(i,l)}return E=f.interleaved,E===null?(s.next=s,lp(f)):(s.next=E.next,E.next=s),f.interleaved=s,Dr(i,l)}function nc(i,s,l){if(s=s.updateQueue,s!==null&&(s=s.shared,(l&4194240)!==0)){var f=s.lanes;f&=i.pendingLanes,l|=f,s.lanes=l,wh(i,l)}}function a2(i,s){var l=i.updateQueue,f=i.alternate;if(f!==null&&(f=f.updateQueue,l===f)){var E=null,y=null;if(l=l.firstBaseUpdate,l!==null){do{var _={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};y===null?E=y=_:y=y.next=_,l=l.next}while(l!==null);y===null?E=y=s:y=y.next=s}else E=y=s;l={baseState:f.baseState,firstBaseUpdate:E,lastBaseUpdate:y,shared:f.shared,effects:f.effects},i.updateQueue=l;return}i=l.lastBaseUpdate,i===null?l.firstBaseUpdate=s:i.next=s,l.lastBaseUpdate=s}function rc(i,s,l,f){var E=i.updateQueue;di=!1;var y=E.firstBaseUpdate,_=E.lastBaseUpdate,I=E.shared.pending;if(I!==null){E.shared.pending=null;var B=I,G=B.next;B.next=null,_===null?y=G:_.next=G,_=B;var se=i.alternate;se!==null&&(se=se.updateQueue,I=se.lastBaseUpdate,I!==_&&(I===null?se.firstBaseUpdate=G:I.next=G,se.lastBaseUpdate=B))}if(y!==null){var de=E.baseState;_=0,se=G=B=null,I=y;do{var ie=I.lane,_e=I.eventTime;if((f&ie)===ie){se!==null&&(se=se.next={eventTime:_e,lane:0,tag:I.tag,payload:I.payload,callback:I.callback,next:null});e:{var Ae=i,Ce=I;switch(ie=s,_e=l,Ce.tag){case 1:if(Ae=Ce.payload,typeof Ae=="function"){de=Ae.call(_e,de,ie);break e}de=Ae;break e;case 3:Ae.flags=Ae.flags&-65537|128;case 0:if(Ae=Ce.payload,ie=typeof Ae=="function"?Ae.call(_e,de,ie):Ae,ie==null)break e;de=w({},de,ie);break e;case 2:di=!0}}I.callback!==null&&I.lane!==0&&(i.flags|=64,ie=E.effects,ie===null?E.effects=[I]:ie.push(I))}else _e={eventTime:_e,lane:ie,tag:I.tag,payload:I.payload,callback:I.callback,next:null},se===null?(G=se=_e,B=de):se=se.next=_e,_|=ie;if(I=I.next,I===null){if(I=E.shared.pending,I===null)break;ie=I,I=ie.next,ie.next=null,E.lastBaseUpdate=ie,E.shared.pending=null}}while(!0);if(se===null&&(B=de),E.baseState=B,E.firstBaseUpdate=G,E.lastBaseUpdate=se,s=E.shared.interleaved,s!==null){E=s;do _|=E.lane,E=E.next;while(E!==s)}else y===null&&(E.shared.lanes=0);eo|=_,i.lanes=_,i.memoizedState=de}}function u2(i,s,l){if(i=s.effects,s.effects=null,i!==null)for(s=0;s<i.length;s++){var f=i[s],E=f.callback;if(E!==null){if(f.callback=null,f=l,typeof E!="function")throw Error(n(191,E));E.call(f)}}}var Ua={},xr=ui(Ua),Ha=ui(Ua),za=ui(Ua);function Ji(i){if(i===Ua)throw Error(n(174));return i}function dp(i,s){switch(at(za,s),at(Ha,i),at(xr,Ua),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:ye(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=ye(s,i)}ct(xr),at(xr,s)}function fs(){ct(xr),ct(Ha),ct(za)}function l2(i){Ji(za.current);var s=Ji(xr.current),l=ye(s,i.type);s!==l&&(at(Ha,i),at(xr,l))}function fp(i){Ha.current===i&&(ct(xr),ct(Ha))}var mt=ui(0);function ic(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 pp(){for(var i=0;i<hp.length;i++)hp[i]._workInProgressVersionPrimary=null;hp.length=0}var oc=F.ReactCurrentDispatcher,mp=F.ReactCurrentBatchConfig,Zi=0,gt=null,Ot=null,Ft=null,sc=!1,ja=!1,$a=0,$8=0;function Qt(){throw Error(n(321))}function gp(i,s){if(s===null)return!1;for(var l=0;l<s.length&&l<i.length;l++)if(!Zn(i[l],s[l]))return!1;return!0}function Ep(i,s,l,f,E,y){if(Zi=y,gt=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,oc.current=i===null||i.memoizedState===null?q8:G8,i=l(f,E),ja){y=0;do{if(ja=!1,$a=0,25<=y)throw Error(n(301));y+=1,Ft=Ot=null,s.updateQueue=null,oc.current=K8,i=l(f,E)}while(ja)}if(oc.current=lc,s=Ot!==null&&Ot.next!==null,Zi=0,Ft=Ot=gt=null,sc=!1,s)throw Error(n(300));return i}function yp(){var i=$a!==0;return $a=0,i}function _r(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ft===null?gt.memoizedState=Ft=i:Ft=Ft.next=i,Ft}function Hn(){if(Ot===null){var i=gt.alternate;i=i!==null?i.memoizedState:null}else i=Ot.next;var s=Ft===null?gt.memoizedState:Ft.next;if(s!==null)Ft=s,Ot=i;else{if(i===null)throw Error(n(310));Ot=i,i={memoizedState:Ot.memoizedState,baseState:Ot.baseState,baseQueue:Ot.baseQueue,queue:Ot.queue,next:null},Ft===null?gt.memoizedState=Ft=i:Ft=Ft.next=i}return Ft}function Va(i,s){return typeof s=="function"?s(i):s}function Tp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=Ot,E=f.baseQueue,y=l.pending;if(y!==null){if(E!==null){var _=E.next;E.next=y.next,y.next=_}f.baseQueue=E=y,l.pending=null}if(E!==null){y=E.next,f=f.baseState;var I=_=null,B=null,G=y;do{var se=G.lane;if((Zi&se)===se)B!==null&&(B=B.next={lane:0,action:G.action,hasEagerState:G.hasEagerState,eagerState:G.eagerState,next:null}),f=G.hasEagerState?G.eagerState:i(f,G.action);else{var de={lane:se,action:G.action,hasEagerState:G.hasEagerState,eagerState:G.eagerState,next:null};B===null?(I=B=de,_=f):B=B.next=de,gt.lanes|=se,eo|=se}G=G.next}while(G!==null&&G!==y);B===null?_=f:B.next=I,Zn(f,s.memoizedState)||(En=!0),s.memoizedState=f,s.baseState=_,s.baseQueue=B,l.lastRenderedState=f}if(i=l.interleaved,i!==null){E=i;do y=E.lane,gt.lanes|=y,eo|=y,E=E.next;while(E!==i)}else E===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function bp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=l.dispatch,E=l.pending,y=s.memoizedState;if(E!==null){l.pending=null;var _=E=E.next;do y=i(y,_.action),_=_.next;while(_!==E);Zn(y,s.memoizedState)||(En=!0),s.memoizedState=y,s.baseQueue===null&&(s.baseState=y),l.lastRenderedState=y}return[y,f]}function c2(){}function d2(i,s){var l=gt,f=Hn(),E=s(),y=!Zn(f.memoizedState,E);if(y&&(f.memoizedState=E,En=!0),f=f.queue,xp(p2.bind(null,l,f,i),[i]),f.getSnapshot!==s||y||Ft!==null&&Ft.memoizedState.tag&1){if(l.flags|=2048,Ya(9,h2.bind(null,l,f,E,s),void 0,null),Bt===null)throw Error(n(349));(Zi&30)!==0||f2(l,s,E)}return E}function f2(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function h2(i,s,l,f){s.value=l,s.getSnapshot=f,m2(s)&&g2(i)}function p2(i,s,l){return l(function(){m2(s)&&g2(i)})}function m2(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!Zn(i,l)}catch(f){return!0}}function g2(i){var s=Dr(i,1);s!==null&&ir(s,i,1,-1)}function E2(i){var s=_r();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Va,lastRenderedState:i},s.queue=i,i=i.dispatch=W8.bind(null,gt,i),[s.memoizedState,i]}function Ya(i,s,l,f){return i={tag:i,create:s,destroy:l,deps:f,next:null},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.lastEffect=i.next=i):(l=s.lastEffect,l===null?s.lastEffect=i.next=i:(f=l.next,l.next=i,i.next=f,s.lastEffect=i)),i}function y2(){return Hn().memoizedState}function ac(i,s,l,f){var E=_r();gt.flags|=i,E.memoizedState=Ya(1|s,l,void 0,f===void 0?null:f)}function uc(i,s,l,f){var E=Hn();f=f===void 0?null:f;var y=void 0;if(Ot!==null){var _=Ot.memoizedState;if(y=_.destroy,f!==null&&gp(f,_.deps)){E.memoizedState=Ya(s,l,y,f);return}}gt.flags|=i,E.memoizedState=Ya(1|s,l,y,f)}function T2(i,s){return ac(8390656,8,i,s)}function xp(i,s){return uc(2048,8,i,s)}function b2(i,s){return uc(4,2,i,s)}function x2(i,s){return uc(4,4,i,s)}function _2(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 S2(i,s,l){return l=l!=null?l.concat([i]):null,uc(4,4,_2.bind(null,s,i),l)}function _p(){}function w2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&gp(s,f[1])?f[0]:(l.memoizedState=[i,s],i)}function A2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&gp(s,f[1])?f[0]:(i=i(),l.memoizedState=[i,s],i)}function v2(i,s,l){return(Zi&21)===0?(i.baseState&&(i.baseState=!1,En=!0),i.memoizedState=l):(Zn(l,s)||(l=nb(),gt.lanes|=l,eo|=l,i.baseState=!0),s)}function V8(i,s){var l=nt;nt=l!==0&&4>l?l:4,i(!0);var f=mp.transition;mp.transition={};try{i(!1),s()}finally{nt=l,mp.transition=f}}function C2(){return Hn().memoizedState}function Y8(i,s,l){var f=gi(i);if(l={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null},k2(i))N2(s,l);else if(l=o2(i,s,l,f),l!==null){var E=nn();ir(l,i,f,E),O2(l,s,f)}}function W8(i,s,l){var f=gi(i),E={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null};if(k2(i))N2(s,E);else{var y=i.alternate;if(i.lanes===0&&(y===null||y.lanes===0)&&(y=s.lastRenderedReducer,y!==null))try{var _=s.lastRenderedState,I=y(_,l);if(E.hasEagerState=!0,E.eagerState=I,Zn(I,_)){var B=s.interleaved;B===null?(E.next=E,lp(s)):(E.next=B.next,B.next=E),s.interleaved=E;return}}catch(G){}l=o2(i,s,E,f),l!==null&&(E=nn(),ir(l,i,f,E),O2(l,s,f))}}function k2(i){var s=i.alternate;return i===gt||s!==null&&s===gt}function N2(i,s){ja=sc=!0;var l=i.pending;l===null?s.next=s:(s.next=l.next,l.next=s),i.pending=s}function O2(i,s,l){if((l&4194240)!==0){var f=s.lanes;f&=i.pendingLanes,l|=f,s.lanes=l,wh(i,l)}}var lc={readContext:Un,useCallback:Qt,useContext:Qt,useEffect:Qt,useImperativeHandle:Qt,useInsertionEffect:Qt,useLayoutEffect:Qt,useMemo:Qt,useReducer:Qt,useRef:Qt,useState:Qt,useDebugValue:Qt,useDeferredValue:Qt,useTransition:Qt,useMutableSource:Qt,useSyncExternalStore:Qt,useId:Qt,unstable_isNewReconciler:!1},q8={readContext:Un,useCallback:function(i,s){return _r().memoizedState=[i,s===void 0?null:s],i},useContext:Un,useEffect:T2,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,ac(4194308,4,_2.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=_r();return s=s===void 0?null:s,i=i(),l.memoizedState=[i,s],i},useReducer:function(i,s,l){var f=_r();return s=l!==void 0?l(s):s,f.memoizedState=f.baseState=s,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:i,lastRenderedState:s},f.queue=i,i=i.dispatch=Y8.bind(null,gt,i),[f.memoizedState,i]},useRef:function(i){var s=_r();return i={current:i},s.memoizedState=i},useState:E2,useDebugValue:_p,useDeferredValue:function(i){return _r().memoizedState=i},useTransition:function(){var i=E2(!1),s=i[0];return i=V8.bind(null,i[1]),_r().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var f=gt,E=_r();if(pt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Bt===null)throw Error(n(349));(Zi&30)!==0||f2(f,s,l)}E.memoizedState=l;var y={value:l,getSnapshot:s};return E.queue=y,T2(p2.bind(null,f,y,i),[i]),f.flags|=2048,Ya(9,h2.bind(null,f,y,l,s),void 0,null),l},useId:function(){var i=_r(),s=Bt.identifierPrefix;if(pt){var l=Lr,f=Pr;l=(f&~(1<<32-Jn(f)-1)).toString(32)+l,s=":"+s+"R"+l,l=$a++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=$8++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},G8={readContext:Un,useCallback:w2,useContext:Un,useEffect:xp,useImperativeHandle:S2,useInsertionEffect:b2,useLayoutEffect:x2,useMemo:A2,useReducer:Tp,useRef:y2,useState:function(){return Tp(Va)},useDebugValue:_p,useDeferredValue:function(i){var s=Hn();return v2(s,Ot.memoizedState,i)},useTransition:function(){var i=Tp(Va)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:c2,useSyncExternalStore:d2,useId:C2,unstable_isNewReconciler:!1},K8={readContext:Un,useCallback:w2,useContext:Un,useEffect:xp,useImperativeHandle:S2,useInsertionEffect:b2,useLayoutEffect:x2,useMemo:A2,useReducer:bp,useRef:y2,useState:function(){return bp(Va)},useDebugValue:_p,useDeferredValue:function(i){var s=Hn();return Ot===null?s.memoizedState=i:v2(s,Ot.memoizedState,i)},useTransition:function(){var i=bp(Va)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:c2,useSyncExternalStore:d2,useId:C2,unstable_isNewReconciler:!1};function tr(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 Sp(i,s,l,f){s=i.memoizedState,l=l(f,s),l=l==null?s:w({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var cc={isMounted:function(i){return(i=i._reactInternals)?Wi(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var f=nn(),E=gi(i),y=Mr(f,E);y.payload=s,l!=null&&(y.callback=l),s=fi(i,y,E),s!==null&&(ir(s,i,E,f),nc(s,i,E))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var f=nn(),E=gi(i),y=Mr(f,E);y.tag=1,y.payload=s,l!=null&&(y.callback=l),s=fi(i,y,E),s!==null&&(ir(s,i,E,f),nc(s,i,E))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=nn(),f=gi(i),E=Mr(l,f);E.tag=2,s!=null&&(E.callback=s),s=fi(i,E,f),s!==null&&(ir(s,i,f,l),nc(s,i,f))}};function I2(i,s,l,f,E,y,_){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(f,y,_):s.prototype&&s.prototype.isPureReactComponent?!Ia(l,f)||!Ia(E,y):!0}function R2(i,s,l){var f=!1,E=li,y=s.contextType;return typeof y=="object"&&y!==null?y=Un(y):(E=gn(s)?Gi:Kt.current,f=s.contextTypes,y=(f=f!=null)?os(i,E):li),s=new s(l,y),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=cc,i.stateNode=s,s._reactInternals=i,f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=E,i.__reactInternalMemoizedMaskedChildContext=y),s}function P2(i,s,l,f){i=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(l,f),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(l,f),s.state!==i&&cc.enqueueReplaceState(s,s.state,null)}function wp(i,s,l,f){var E=i.stateNode;E.props=l,E.state=i.memoizedState,E.refs={},cp(i);var y=s.contextType;typeof y=="object"&&y!==null?E.context=Un(y):(y=gn(s)?Gi:Kt.current,E.context=os(i,y)),E.state=i.memoizedState,y=s.getDerivedStateFromProps,typeof y=="function"&&(Sp(i,s,y,l),E.state=i.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof E.getSnapshotBeforeUpdate=="function"||typeof E.UNSAFE_componentWillMount!="function"&&typeof E.componentWillMount!="function"||(s=E.state,typeof E.componentWillMount=="function"&&E.componentWillMount(),typeof E.UNSAFE_componentWillMount=="function"&&E.UNSAFE_componentWillMount(),s!==E.state&&cc.enqueueReplaceState(E,E.state,null),rc(i,l,E,f),E.state=i.memoizedState),typeof E.componentDidMount=="function"&&(i.flags|=4194308)}function hs(i,s){try{var l="",f=s;do l+=Pe(f),f=f.return;while(f);var E=l}catch(y){E=`
19
+ `),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 B=`
20
+ `+g[x].replace(" at new "," at ");return i.displayName&&B.includes("<anonymous>")&&(B=B.replace("<anonymous>",i.displayName)),B}while(1<=x&&0<=O);break}}}finally{k=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?X(i):""}function Pe(i){switch(i.tag){case 5:return X(i.type);case 16:return X("Lazy");case 13:return X("Suspense");case 19:return X("SuspenseList");case 0:case 2:case 15:return i=xe(i.type,!1),i;case 11:return i=xe(i.type.render,!1),i;case 1:return i=xe(i.type,!0),i;default:return""}}function Oe(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 q:return"Fragment";case D:return"Portal";case be:return"Profiler";case ce:return"StrictMode";case ge:return"Suspense";case ue:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case ae:return(i.displayName||"Context")+".Consumer";case j:return(i._context.displayName||"Context")+".Provider";case he:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case Te:return s=i.displayName||null,s!==null?s:Oe(i.type)||"Memo";case Ne:s=i._payload,i=i._init;try{return Oe(i(s))}catch(l){}}return null}function He(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 Oe(s);case 8:return s===ce?"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 Se(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function Ve(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function ut(i){var s=Ve(i)?"checked":"value",l=Object.getOwnPropertyDescriptor(i.constructor.prototype,s),f=""+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){f=""+x,y.call(this,x)}}),Object.defineProperty(i,s,{enumerable:l.enumerable}),{getValue:function(){return f},setValue:function(x){f=""+x},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function pn(i){i._valueTracker||(i._valueTracker=ut(i))}function Yi(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var l=s.getValue(),f="";return i&&(f=Ve(i)?i.checked?"true":"false":i.value),i=f,i!==l?(s.setValue(i),!0):!1}function Xr(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 Xn(i,s){var l=s.checked;return S({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function ha(i,s){var l=s.defaultValue==null?"":s.defaultValue,f=s.checked!=null?s.checked:s.defaultChecked;l=Se(s.value!=null?s.value:l),i._wrapperState={initialChecked:f,initialValue:l,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function pa(i,s){s=s.checked,s!=null&&R(i,"checked",s,!1)}function Wo(i,s){pa(i,s);var l=Se(s.value),f=s.type;if(l!=null)f==="number"?(l===0&&i.value===""||i.value!=l)&&(i.value=""+l):i.value!==""+l&&(i.value=""+l);else if(f==="submit"||f==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?qo(i,s.type,l):s.hasOwnProperty("defaultValue")&&qo(i,s.type,Se(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function bl(i,s,l){if(s.hasOwnProperty("value")||s.hasOwnProperty("defaultValue")){var f=s.type;if(!(f!=="submit"&&f!=="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 qo(i,s,l){(s!=="number"||Xr(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var Jr=Array.isArray;function Zr(i,s,l,f){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&&f&&(i[l].defaultSelected=!0)}else{for(l=""+Se(l),s=null,g=0;g<i.length;g++){if(i[g].value===l){i[g].selected=!0,f&&(i[g].defaultSelected=!0);return}s!==null||i[g].disabled||(s=i[g])}s!==null&&(s.selected=!0)}}function ma(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return S({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function xl(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(Jr(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:Se(l)}}function _l(i,s){var l=Se(s.value),f=Se(s.defaultValue);l!=null&&(l=""+l,l!==i.value&&(i.value=l),s.defaultValue==null&&i.defaultValue!==l&&(i.defaultValue=l)),f!=null&&(i.defaultValue=""+f)}function wl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function Z(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 ye(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?Z(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Be,Ye=(function(i){return typeof MSApp!="undefined"&&MSApp.execUnsafeLocalFunction?function(s,l,f,g){MSApp.execUnsafeLocalFunction(function(){return i(s,l,f,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 Qe(i,s){if(s){var l=i.firstChild;if(l&&l===i.lastChild&&l.nodeType===3){l.nodeValue=s;return}}i.textContent=s}var Ht={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},Ir=["Webkit","ms","Moz","O"];Object.keys(Ht).forEach(function(i){Ir.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),Ht[s]=Ht[i]})});function Mn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||Ht.hasOwnProperty(i)&&Ht[i]?(""+s).trim():s+"px"}function ei(i,s){i=i.style;for(var l in s)if(s.hasOwnProperty(l)){var f=l.indexOf("--")===0,g=Mn(l,s[l],f);l==="float"&&(l="cssFloat"),f?i.setProperty(l,g):i[l]=g}}var Wi=S({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(Wi[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 yr(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 An=null;function hh(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var ph=null,Go=null,Ko=null;function zT(i){if(i=Fa(i)){if(typeof ph!="function")throw Error(n(280));var s=i.stateNode;s&&(s=Wl(s),ph(i.stateNode,i.type,s))}}function jT(i){Go?Ko?Ko.push(i):Ko=[i]:Go=i}function $T(){if(Go){var i=Go,s=Ko;if(Ko=Go=null,zT(i),s)for(i=0;i<s.length;i++)zT(s[i])}}function VT(i,s){return i(s)}function YT(){}var mh=!1;function WT(i,s,l){if(mh)return i(s,l);mh=!0;try{return VT(i,s,l)}finally{mh=!1,(Go!==null||Ko!==null)&&(YT(),$T())}}function ga(i,s){var l=i.stateNode;if(l===null)return null;var f=Wl(l);if(f===null)return null;l=f[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":(f=!f.disabled)||(i=i.type,f=!(i==="button"||i==="input"||i==="select"||i==="textarea")),i=!f;break e;default:i=!1}if(i)return null;if(l&&typeof l!="function")throw Error(n(231,s,typeof l));return l}var gh=!1;if(c)try{var Ea={};Object.defineProperty(Ea,"passive",{get:function(){gh=!0}}),window.addEventListener("test",Ea,Ea),window.removeEventListener("test",Ea,Ea)}catch(i){gh=!1}function I5(i,s,l,f,g,y,x,O,B){var G=Array.prototype.slice.call(arguments,3);try{s.apply(l,G)}catch(se){this.onError(se)}}var ya=!1,Sl=null,Al=!1,Eh=null,R5={onError:function(i){ya=!0,Sl=i}};function P5(i,s,l,f,g,y,x,O,B){ya=!1,Sl=null,I5.apply(R5,arguments)}function L5(i,s,l,f,g,y,x,O,B){if(P5.apply(this,arguments),ya){if(ya){var G=Sl;ya=!1,Sl=null}else throw Error(n(198));Al||(Al=!0,Eh=G)}}function qi(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 qT(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 GT(i){if(qi(i)!==i)throw Error(n(188))}function D5(i){var s=i.alternate;if(!s){if(s=qi(i),s===null)throw Error(n(188));return s!==i?null:i}for(var l=i,f=s;;){var g=l.return;if(g===null)break;var y=g.alternate;if(y===null){if(f=g.return,f!==null){l=f;continue}break}if(g.child===y.child){for(y=g.child;y;){if(y===l)return GT(g),i;if(y===f)return GT(g),s;y=y.sibling}throw Error(n(188))}if(l.return!==f.return)l=g,f=y;else{for(var x=!1,O=g.child;O;){if(O===l){x=!0,l=g,f=y;break}if(O===f){x=!0,f=g,l=y;break}O=O.sibling}if(!x){for(O=y.child;O;){if(O===l){x=!0,l=y,f=g;break}if(O===f){x=!0,f=y,l=g;break}O=O.sibling}if(!x)throw Error(n(189))}}if(l.alternate!==f)throw Error(n(190))}if(l.tag!==3)throw Error(n(188));return l.stateNode.current===l?i:s}function KT(i){return i=D5(i),i!==null?QT(i):null}function QT(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=QT(i);if(s!==null)return s;i=i.sibling}return null}var XT=t.unstable_scheduleCallback,JT=t.unstable_cancelCallback,M5=t.unstable_shouldYield,F5=t.unstable_requestPaint,_t=t.unstable_now,B5=t.unstable_getCurrentPriorityLevel,yh=t.unstable_ImmediatePriority,ZT=t.unstable_UserBlockingPriority,vl=t.unstable_NormalPriority,U5=t.unstable_LowPriority,eb=t.unstable_IdlePriority,Cl=null,Tr=null;function H5(i){if(Tr&&typeof Tr.onCommitFiberRoot=="function")try{Tr.onCommitFiberRoot(Cl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var Jn=Math.clz32?Math.clz32:$5,z5=Math.log,j5=Math.LN2;function $5(i){return i>>>=0,i===0?32:31-(z5(i)/j5|0)|0}var kl=64,Nl=4194304;function Ta(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 Ol(i,s){var l=i.pendingLanes;if(l===0)return 0;var f=0,g=i.suspendedLanes,y=i.pingedLanes,x=l&268435455;if(x!==0){var O=x&~g;O!==0?f=Ta(O):(y&=x,y!==0&&(f=Ta(y)))}else x=l&~g,x!==0?f=Ta(x):y!==0&&(f=Ta(y));if(f===0)return 0;if(s!==0&&s!==f&&(s&g)===0&&(g=f&-f,y=s&-s,g>=y||g===16&&(y&4194240)!==0))return s;if((f&4)!==0&&(f|=l&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=f;0<s;)l=31-Jn(s),g=1<<l,f|=i[l],s&=~g;return f}function V5(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 Y5(i,s){for(var l=i.suspendedLanes,f=i.pingedLanes,g=i.expirationTimes,y=i.pendingLanes;0<y;){var x=31-Jn(y),O=1<<x,B=g[x];B===-1?((O&l)===0||(O&f)!==0)&&(g[x]=V5(O,s)):B<=s&&(i.expiredLanes|=O),y&=~O}}function Th(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function tb(){var i=kl;return kl<<=1,(kl&4194240)===0&&(kl=64),i}function bh(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function ba(i,s,l){i.pendingLanes|=s,s!==536870912&&(i.suspendedLanes=0,i.pingedLanes=0),i=i.eventTimes,s=31-Jn(s),i[s]=l}function W5(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 f=i.eventTimes;for(i=i.expirationTimes;0<l;){var g=31-Jn(l),y=1<<g;s[g]=0,f[g]=-1,i[g]=-1,l&=~y}}function xh(i,s){var l=i.entangledLanes|=s;for(i=i.entanglements;l;){var f=31-Jn(l),g=1<<f;g&s|i[f]&s&&(i[f]|=s),l&=~g}}var nt=0;function nb(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var rb,_h,ib,ob,sb,wh=!1,Il=[],ti=null,ni=null,ri=null,xa=new Map,_a=new Map,ii=[],q5="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 ab(i,s){switch(i){case"focusin":case"focusout":ti=null;break;case"dragenter":case"dragleave":ni=null;break;case"mouseover":case"mouseout":ri=null;break;case"pointerover":case"pointerout":xa.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":_a.delete(s.pointerId)}}function wa(i,s,l,f,g,y){return i===null||i.nativeEvent!==y?(i={blockedOn:s,domEventName:l,eventSystemFlags:f,nativeEvent:y,targetContainers:[g]},s!==null&&(s=Fa(s),s!==null&&_h(s)),i):(i.eventSystemFlags|=f,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function G5(i,s,l,f,g){switch(s){case"focusin":return ti=wa(ti,i,s,l,f,g),!0;case"dragenter":return ni=wa(ni,i,s,l,f,g),!0;case"mouseover":return ri=wa(ri,i,s,l,f,g),!0;case"pointerover":var y=g.pointerId;return xa.set(y,wa(xa.get(y)||null,i,s,l,f,g)),!0;case"gotpointercapture":return y=g.pointerId,_a.set(y,wa(_a.get(y)||null,i,s,l,f,g)),!0}return!1}function ub(i){var s=Gi(i.target);if(s!==null){var l=qi(s);if(l!==null){if(s=l.tag,s===13){if(s=qT(l),s!==null){i.blockedOn=s,sb(i.priority,function(){ib(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 Rl(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=Ah(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var f=new l.constructor(l.type,l);An=f,l.target.dispatchEvent(f),An=null}else return s=Fa(l),s!==null&&_h(s),i.blockedOn=l,!1;s.shift()}return!0}function lb(i,s,l){Rl(i)&&l.delete(s)}function K5(){wh=!1,ti!==null&&Rl(ti)&&(ti=null),ni!==null&&Rl(ni)&&(ni=null),ri!==null&&Rl(ri)&&(ri=null),xa.forEach(lb),_a.forEach(lb)}function Sa(i,s){i.blockedOn===s&&(i.blockedOn=null,wh||(wh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,K5)))}function Aa(i){function s(g){return Sa(g,i)}if(0<Il.length){Sa(Il[0],i);for(var l=1;l<Il.length;l++){var f=Il[l];f.blockedOn===i&&(f.blockedOn=null)}}for(ti!==null&&Sa(ti,i),ni!==null&&Sa(ni,i),ri!==null&&Sa(ri,i),xa.forEach(s),_a.forEach(s),l=0;l<ii.length;l++)f=ii[l],f.blockedOn===i&&(f.blockedOn=null);for(;0<ii.length&&(l=ii[0],l.blockedOn===null);)ub(l),l.blockedOn===null&&ii.shift()}var Qo=F.ReactCurrentBatchConfig,Pl=!0;function Q5(i,s,l,f){var g=nt,y=Qo.transition;Qo.transition=null;try{nt=1,Sh(i,s,l,f)}finally{nt=g,Qo.transition=y}}function X5(i,s,l,f){var g=nt,y=Qo.transition;Qo.transition=null;try{nt=4,Sh(i,s,l,f)}finally{nt=g,Qo.transition=y}}function Sh(i,s,l,f){if(Pl){var g=Ah(i,s,l,f);if(g===null)jh(i,s,f,Ll,l),ab(i,f);else if(G5(g,i,s,l,f))f.stopPropagation();else if(ab(i,f),s&4&&-1<q5.indexOf(i)){for(;g!==null;){var y=Fa(g);if(y!==null&&rb(y),y=Ah(i,s,l,f),y===null&&jh(i,s,f,Ll,l),y===g)break;g=y}g!==null&&f.stopPropagation()}else jh(i,s,f,null,l)}}var Ll=null;function Ah(i,s,l,f){if(Ll=null,i=hh(f),i=Gi(i),i!==null)if(s=qi(i),s===null)i=null;else if(l=s.tag,l===13){if(i=qT(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 Ll=i,null}function cb(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(B5()){case yh:return 1;case ZT:return 4;case vl:case U5:return 16;case eb:return 536870912;default:return 16}default:return 16}}var oi=null,vh=null,Dl=null;function db(){if(Dl)return Dl;var i,s=vh,l=s.length,f,g="value"in oi?oi.value:oi.textContent,y=g.length;for(i=0;i<l&&s[i]===g[i];i++);var x=l-i;for(f=1;f<=x&&s[l-f]===g[y-f];f++);return Dl=g.slice(i,1<f?1-f:void 0)}function Ml(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 Fl(){return!0}function fb(){return!1}function vn(i){function s(l,f,g,y,x){this._reactName=l,this._targetInst=g,this.type=f,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)?Fl:fb,this.isPropagationStopped=fb,this}return S(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=Fl)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Fl)},persist:function(){},isPersistent:Fl}),s}var Xo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ch=vn(Xo),va=S({},Xo,{view:0,detail:0}),J5=vn(va),kh,Nh,Ca,Bl=S({},va,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ih,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!==Ca&&(Ca&&i.type==="mousemove"?(kh=i.screenX-Ca.screenX,Nh=i.screenY-Ca.screenY):Nh=kh=0,Ca=i),kh)},movementY:function(i){return"movementY"in i?i.movementY:Nh}}),hb=vn(Bl),Z5=S({},Bl,{dataTransfer:0}),e8=vn(Z5),t8=S({},va,{relatedTarget:0}),Oh=vn(t8),n8=S({},Xo,{animationName:0,elapsedTime:0,pseudoElement:0}),r8=vn(n8),i8=S({},Xo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),o8=vn(i8),s8=S({},Xo,{data:0}),pb=vn(s8),a8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},u8={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 c8(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=l8[i])?!!s[i]:!1}function Ih(){return c8}var d8=S({},va,{key:function(i){if(i.key){var s=a8[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=Ml(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?u8[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ih,charCode:function(i){return i.type==="keypress"?Ml(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?Ml(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),f8=vn(d8),h8=S({},Bl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),mb=vn(h8),p8=S({},va,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ih}),m8=vn(p8),g8=S({},Xo,{propertyName:0,elapsedTime:0,pseudoElement:0}),E8=vn(g8),y8=S({},Bl,{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}),T8=vn(y8),b8=[9,13,27,32],Rh=c&&"CompositionEvent"in window,ka=null;c&&"documentMode"in document&&(ka=document.documentMode);var x8=c&&"TextEvent"in window&&!ka,gb=c&&(!Rh||ka&&8<ka&&11>=ka),Eb=" ",yb=!1;function Tb(i,s){switch(i){case"keyup":return b8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function bb(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var Jo=!1;function _8(i,s){switch(i){case"compositionend":return bb(s);case"keypress":return s.which!==32?null:(yb=!0,Eb);case"textInput":return i=s.data,i===Eb&&yb?null:i;default:return null}}function w8(i,s){if(Jo)return i==="compositionend"||!Rh&&Tb(i,s)?(i=db(),Dl=vh=oi=null,Jo=!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 gb&&s.locale!=="ko"?null:s.data;default:return null}}var S8={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 xb(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!S8[i.type]:s==="textarea"}function _b(i,s,l,f){jT(f),s=$l(s,"onChange"),0<s.length&&(l=new Ch("onChange","change",null,l,f),i.push({event:l,listeners:s}))}var Na=null,Oa=null;function A8(i){Hb(i,0)}function Ul(i){var s=rs(i);if(Yi(s))return i}function v8(i,s){if(i==="change")return s}var wb=!1;if(c){var Ph;if(c){var Lh="oninput"in document;if(!Lh){var Sb=document.createElement("div");Sb.setAttribute("oninput","return;"),Lh=typeof Sb.oninput=="function"}Ph=Lh}else Ph=!1;wb=Ph&&(!document.documentMode||9<document.documentMode)}function Ab(){Na&&(Na.detachEvent("onpropertychange",vb),Oa=Na=null)}function vb(i){if(i.propertyName==="value"&&Ul(Oa)){var s=[];_b(s,Oa,i,hh(i)),WT(A8,s)}}function C8(i,s,l){i==="focusin"?(Ab(),Na=s,Oa=l,Na.attachEvent("onpropertychange",vb)):i==="focusout"&&Ab()}function k8(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return Ul(Oa)}function N8(i,s){if(i==="click")return Ul(s)}function O8(i,s){if(i==="input"||i==="change")return Ul(s)}function I8(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var Zn=typeof Object.is=="function"?Object.is:I8;function Ia(i,s){if(Zn(i,s))return!0;if(typeof i!="object"||i===null||typeof s!="object"||s===null)return!1;var l=Object.keys(i),f=Object.keys(s);if(l.length!==f.length)return!1;for(f=0;f<l.length;f++){var g=l[f];if(!d.call(s,g)||!Zn(i[g],s[g]))return!1}return!0}function Cb(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function kb(i,s){var l=Cb(i);i=0;for(var f;l;){if(l.nodeType===3){if(f=i+l.textContent.length,i<=s&&f>=s)return{node:l,offset:s-i};i=f}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=Cb(l)}}function Nb(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?Nb(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function Ob(){for(var i=window,s=Xr();s instanceof i.HTMLIFrameElement;){try{var l=typeof s.contentWindow.location.href=="string"}catch(f){l=!1}if(l)i=s.contentWindow;else break;s=Xr(i.document)}return s}function Dh(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 R8(i){var s=Ob(),l=i.focusedElem,f=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&Nb(l.ownerDocument.documentElement,l)){if(f!==null&&Dh(l)){if(s=f.start,i=f.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(f.start,g);f=f.end===void 0?y:Math.min(f.end,g),!i.extend&&y>f&&(g=f,f=y,y=g),g=kb(l,y);var x=kb(l,f);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>f?(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 P8=c&&"documentMode"in document&&11>=document.documentMode,Zo=null,Mh=null,Ra=null,Fh=!1;function Ib(i,s,l){var f=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Fh||Zo==null||Zo!==Xr(f)||(f=Zo,"selectionStart"in f&&Dh(f)?f={start:f.selectionStart,end:f.selectionEnd}:(f=(f.ownerDocument&&f.ownerDocument.defaultView||window).getSelection(),f={anchorNode:f.anchorNode,anchorOffset:f.anchorOffset,focusNode:f.focusNode,focusOffset:f.focusOffset}),Ra&&Ia(Ra,f)||(Ra=f,f=$l(Mh,"onSelect"),0<f.length&&(s=new Ch("onSelect","select",null,s,l),i.push({event:s,listeners:f}),s.target=Zo)))}function Hl(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var es={animationend:Hl("Animation","AnimationEnd"),animationiteration:Hl("Animation","AnimationIteration"),animationstart:Hl("Animation","AnimationStart"),transitionend:Hl("Transition","TransitionEnd")},Bh={},Rb={};c&&(Rb=document.createElement("div").style,"AnimationEvent"in window||(delete es.animationend.animation,delete es.animationiteration.animation,delete es.animationstart.animation),"TransitionEvent"in window||delete es.transitionend.transition);function zl(i){if(Bh[i])return Bh[i];if(!es[i])return i;var s=es[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in Rb)return Bh[i]=s[l];return i}var Pb=zl("animationend"),Lb=zl("animationiteration"),Db=zl("animationstart"),Mb=zl("transitionend"),Fb=new Map,Bb="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 si(i,s){Fb.set(i,s),a(s,[i])}for(var Uh=0;Uh<Bb.length;Uh++){var Hh=Bb[Uh],L8=Hh.toLowerCase(),D8=Hh[0].toUpperCase()+Hh.slice(1);si(L8,"on"+D8)}si(Pb,"onAnimationEnd"),si(Lb,"onAnimationIteration"),si(Db,"onAnimationStart"),si("dblclick","onDoubleClick"),si("focusin","onFocus"),si("focusout","onBlur"),si(Mb,"onTransitionEnd"),u("onMouseEnter",["mouseout","mouseover"]),u("onMouseLeave",["mouseout","mouseover"]),u("onPointerEnter",["pointerout","pointerover"]),u("onPointerLeave",["pointerout","pointerover"]),a("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),a("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),a("onBeforeInput",["compositionend","keypress","textInput","paste"]),a("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Pa="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(" "),M8=new Set("cancel close invalid load scroll toggle".split(" ").concat(Pa));function Ub(i,s,l){var f=i.type||"unknown-event";i.currentTarget=l,L5(f,s,void 0,i),i.currentTarget=null}function Hb(i,s){s=(s&4)!==0;for(var l=0;l<i.length;l++){var f=i[l],g=f.event;f=f.listeners;e:{var y=void 0;if(s)for(var x=f.length-1;0<=x;x--){var O=f[x],B=O.instance,G=O.currentTarget;if(O=O.listener,B!==y&&g.isPropagationStopped())break e;Ub(g,O,G),y=B}else for(x=0;x<f.length;x++){if(O=f[x],B=O.instance,G=O.currentTarget,O=O.listener,B!==y&&g.isPropagationStopped())break e;Ub(g,O,G),y=B}}}if(Al)throw i=Eh,Al=!1,Eh=null,i}function lt(i,s){var l=s[Gh];l===void 0&&(l=s[Gh]=new Set);var f=i+"__bubble";l.has(f)||(zb(s,i,2,!1),l.add(f))}function zh(i,s,l){var f=0;s&&(f|=4),zb(l,i,f,s)}var jl="_reactListening"+Math.random().toString(36).slice(2);function La(i){if(!i[jl]){i[jl]=!0,r.forEach(function(l){l!=="selectionchange"&&(M8.has(l)||zh(l,!1,i),zh(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[jl]||(s[jl]=!0,zh("selectionchange",!1,s))}}function zb(i,s,l,f){switch(cb(s)){case 1:var g=Q5;break;case 4:g=X5;break;default:g=Sh}l=g.bind(null,s,l,i),g=void 0,!gh||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(g=!0),f?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 jh(i,s,l,f,g){var y=f;if((s&1)===0&&(s&2)===0&&f!==null)e:for(;;){if(f===null)return;var x=f.tag;if(x===3||x===4){var O=f.stateNode.containerInfo;if(O===g||O.nodeType===8&&O.parentNode===g)break;if(x===4)for(x=f.return;x!==null;){var B=x.tag;if((B===3||B===4)&&(B=x.stateNode.containerInfo,B===g||B.nodeType===8&&B.parentNode===g))return;x=x.return}for(;O!==null;){if(x=Gi(O),x===null)return;if(B=x.tag,B===5||B===6){f=y=x;continue e}O=O.parentNode}}f=f.return}WT(function(){var G=y,se=hh(l),de=[];e:{var re=Fb.get(i);if(re!==void 0){var _e=Ch,Ae=i;switch(i){case"keypress":if(Ml(l)===0)break e;case"keydown":case"keyup":_e=f8;break;case"focusin":Ae="focus",_e=Oh;break;case"focusout":Ae="blur",_e=Oh;break;case"beforeblur":case"afterblur":_e=Oh;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":_e=hb;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":_e=e8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":_e=m8;break;case Pb:case Lb:case Db:_e=r8;break;case Mb:_e=E8;break;case"scroll":_e=J5;break;case"wheel":_e=T8;break;case"copy":case"cut":case"paste":_e=o8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":_e=mb}var Ce=(s&4)!==0,wt=!Ce&&i==="scroll",V=Ce?re!==null?re+"Capture":null:re;Ce=[];for(var H=G,W;H!==null;){W=H;var Ee=W.stateNode;if(W.tag===5&&Ee!==null&&(W=Ee,V!==null&&(Ee=ga(H,V),Ee!=null&&Ce.push(Da(H,Ee,W)))),wt)break;H=H.return}0<Ce.length&&(re=new _e(re,Ae,null,l,se),de.push({event:re,listeners:Ce}))}}if((s&7)===0){e:{if(re=i==="mouseover"||i==="pointerover",_e=i==="mouseout"||i==="pointerout",re&&l!==An&&(Ae=l.relatedTarget||l.fromElement)&&(Gi(Ae)||Ae[Rr]))break e;if((_e||re)&&(re=se.window===se?se:(re=se.ownerDocument)?re.defaultView||re.parentWindow:window,_e?(Ae=l.relatedTarget||l.toElement,_e=G,Ae=Ae?Gi(Ae):null,Ae!==null&&(wt=qi(Ae),Ae!==wt||Ae.tag!==5&&Ae.tag!==6)&&(Ae=null)):(_e=null,Ae=G),_e!==Ae)){if(Ce=hb,Ee="onMouseLeave",V="onMouseEnter",H="mouse",(i==="pointerout"||i==="pointerover")&&(Ce=mb,Ee="onPointerLeave",V="onPointerEnter",H="pointer"),wt=_e==null?re:rs(_e),W=Ae==null?re:rs(Ae),re=new Ce(Ee,H+"leave",_e,l,se),re.target=wt,re.relatedTarget=W,Ee=null,Gi(se)===G&&(Ce=new Ce(V,H+"enter",Ae,l,se),Ce.target=W,Ce.relatedTarget=wt,Ee=Ce),wt=Ee,_e&&Ae)t:{for(Ce=_e,V=Ae,H=0,W=Ce;W;W=ts(W))H++;for(W=0,Ee=V;Ee;Ee=ts(Ee))W++;for(;0<H-W;)Ce=ts(Ce),H--;for(;0<W-H;)V=ts(V),W--;for(;H--;){if(Ce===V||V!==null&&Ce===V.alternate)break t;Ce=ts(Ce),V=ts(V)}Ce=null}else Ce=null;_e!==null&&jb(de,re,_e,Ce,!1),Ae!==null&&wt!==null&&jb(de,wt,Ae,Ce,!0)}}e:{if(re=G?rs(G):window,_e=re.nodeName&&re.nodeName.toLowerCase(),_e==="select"||_e==="input"&&re.type==="file")var ke=v8;else if(xb(re))if(wb)ke=O8;else{ke=k8;var De=C8}else(_e=re.nodeName)&&_e.toLowerCase()==="input"&&(re.type==="checkbox"||re.type==="radio")&&(ke=N8);if(ke&&(ke=ke(i,G))){_b(de,ke,l,se);break e}De&&De(i,re,G),i==="focusout"&&(De=re._wrapperState)&&De.controlled&&re.type==="number"&&qo(re,"number",re.value)}switch(De=G?rs(G):window,i){case"focusin":(xb(De)||De.contentEditable==="true")&&(Zo=De,Mh=G,Ra=null);break;case"focusout":Ra=Mh=Zo=null;break;case"mousedown":Fh=!0;break;case"contextmenu":case"mouseup":case"dragend":Fh=!1,Ib(de,l,se);break;case"selectionchange":if(P8)break;case"keydown":case"keyup":Ib(de,l,se)}var Me;if(Rh)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 Jo?Tb(i,l)&&(Ue="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(Ue="onCompositionStart");Ue&&(gb&&l.locale!=="ko"&&(Jo||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&Jo&&(Me=db()):(oi=se,vh="value"in oi?oi.value:oi.textContent,Jo=!0)),De=$l(G,Ue),0<De.length&&(Ue=new pb(Ue,i,null,l,se),de.push({event:Ue,listeners:De}),Me?Ue.data=Me:(Me=bb(l),Me!==null&&(Ue.data=Me)))),(Me=x8?_8(i,l):w8(i,l))&&(G=$l(G,"onBeforeInput"),0<G.length&&(se=new pb("onBeforeInput","beforeinput",null,l,se),de.push({event:se,listeners:G}),se.data=Me))}Hb(de,s)})}function Da(i,s,l){return{instance:i,listener:s,currentTarget:l}}function $l(i,s){for(var l=s+"Capture",f=[];i!==null;){var g=i,y=g.stateNode;g.tag===5&&y!==null&&(g=y,y=ga(i,l),y!=null&&f.unshift(Da(i,y,g)),y=ga(i,s),y!=null&&f.push(Da(i,y,g))),i=i.return}return f}function ts(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function jb(i,s,l,f,g){for(var y=s._reactName,x=[];l!==null&&l!==f;){var O=l,B=O.alternate,G=O.stateNode;if(B!==null&&B===f)break;O.tag===5&&G!==null&&(O=G,g?(B=ga(l,y),B!=null&&x.unshift(Da(l,B,O))):g||(B=ga(l,y),B!=null&&x.push(Da(l,B,O)))),l=l.return}x.length!==0&&i.push({event:s,listeners:x})}var F8=/\r\n?/g,B8=/\u0000|\uFFFD/g;function $b(i){return(typeof i=="string"?i:""+i).replace(F8,`
21
+ `).replace(B8,"")}function Vl(i,s,l){if(s=$b(s),$b(i)!==s&&l)throw Error(n(425))}function Yl(){}var $h=null,Vh=null;function Yh(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 Wh=typeof setTimeout=="function"?setTimeout:void 0,U8=typeof clearTimeout=="function"?clearTimeout:void 0,Vb=typeof Promise=="function"?Promise:void 0,H8=typeof queueMicrotask=="function"?queueMicrotask:typeof Vb!="undefined"?function(i){return Vb.resolve(null).then(i).catch(z8)}:Wh;function z8(i){setTimeout(function(){throw i})}function qh(i,s){var l=s,f=0;do{var g=l.nextSibling;if(i.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(f===0){i.removeChild(g),Aa(s);return}f--}else l!=="$"&&l!=="$?"&&l!=="$!"||f++;l=g}while(l);Aa(s)}function ai(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 Yb(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 ns=Math.random().toString(36).slice(2),br="__reactFiber$"+ns,Ma="__reactProps$"+ns,Rr="__reactContainer$"+ns,Gh="__reactEvents$"+ns,j8="__reactListeners$"+ns,$8="__reactHandles$"+ns;function Gi(i){var s=i[br];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Rr]||l[br]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=Yb(i);i!==null;){if(l=i[br])return l;i=Yb(i)}return s}i=l,l=i.parentNode}return null}function Fa(i){return i=i[br]||i[Rr],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function rs(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function Wl(i){return i[Ma]||null}var Kh=[],is=-1;function ui(i){return{current:i}}function ct(i){0>is||(i.current=Kh[is],Kh[is]=null,is--)}function at(i,s){is++,Kh[is]=i.current,i.current=s}var li={},Kt=ui(li),mn=ui(!1),Ki=li;function os(i,s){var l=i.type.contextTypes;if(!l)return li;var f=i.stateNode;if(f&&f.__reactInternalMemoizedUnmaskedChildContext===s)return f.__reactInternalMemoizedMaskedChildContext;var g={},y;for(y in l)g[y]=s[y];return f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function gn(i){return i=i.childContextTypes,i!=null}function ql(){ct(mn),ct(Kt)}function Wb(i,s,l){if(Kt.current!==li)throw Error(n(168));at(Kt,s),at(mn,l)}function qb(i,s,l){var f=i.stateNode;if(s=s.childContextTypes,typeof f.getChildContext!="function")return l;f=f.getChildContext();for(var g in f)if(!(g in s))throw Error(n(108,He(i)||"Unknown",g));return S({},l,f)}function Gl(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||li,Ki=Kt.current,at(Kt,i),at(mn,mn.current),!0}function Gb(i,s,l){var f=i.stateNode;if(!f)throw Error(n(169));l?(i=qb(i,s,Ki),f.__reactInternalMemoizedMergedChildContext=i,ct(mn),ct(Kt),at(Kt,i)):ct(mn),at(mn,l)}var Pr=null,Kl=!1,Qh=!1;function Kb(i){Pr===null?Pr=[i]:Pr.push(i)}function V8(i){Kl=!0,Kb(i)}function ci(){if(!Qh&&Pr!==null){Qh=!0;var i=0,s=nt;try{var l=Pr;for(nt=1;i<l.length;i++){var f=l[i];do f=f(!0);while(f!==null)}Pr=null,Kl=!1}catch(g){throw Pr!==null&&(Pr=Pr.slice(i+1)),XT(yh,ci),g}finally{nt=s,Qh=!1}}return null}var ss=[],as=0,Ql=null,Xl=0,Fn=[],Bn=0,Qi=null,Lr=1,Dr="";function Xi(i,s){ss[as++]=Xl,ss[as++]=Ql,Ql=i,Xl=s}function Qb(i,s,l){Fn[Bn++]=Lr,Fn[Bn++]=Dr,Fn[Bn++]=Qi,Qi=i;var f=Lr;i=Dr;var g=32-Jn(f)-1;f&=~(1<<g),l+=1;var y=32-Jn(s)+g;if(30<y){var x=g-g%5;y=(f&(1<<x)-1).toString(32),f>>=x,g-=x,Lr=1<<32-Jn(s)+g|l<<g|f,Dr=y+i}else Lr=1<<y|l<<g|f,Dr=i}function Xh(i){i.return!==null&&(Xi(i,1),Qb(i,1,0))}function Jh(i){for(;i===Ql;)Ql=ss[--as],ss[as]=null,Xl=ss[--as],ss[as]=null;for(;i===Qi;)Qi=Fn[--Bn],Fn[Bn]=null,Dr=Fn[--Bn],Fn[Bn]=null,Lr=Fn[--Bn],Fn[Bn]=null}var Cn=null,kn=null,pt=!1,er=null;function Xb(i,s){var l=jn(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 Jb(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,Cn=i,kn=ai(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Cn=i,kn=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(l=Qi!==null?{id:Lr,overflow:Dr}:null,i.memoizedState={dehydrated:s,treeContext:l,retryLane:1073741824},l=jn(18,null,null,0),l.stateNode=s,l.return=i,i.child=l,Cn=i,kn=null,!0):!1;default:return!1}}function Zh(i){return(i.mode&1)!==0&&(i.flags&128)===0}function ep(i){if(pt){var s=kn;if(s){var l=s;if(!Jb(i,s)){if(Zh(i))throw Error(n(418));s=ai(l.nextSibling);var f=Cn;s&&Jb(i,s)?Xb(f,l):(i.flags=i.flags&-4097|2,pt=!1,Cn=i)}}else{if(Zh(i))throw Error(n(418));i.flags=i.flags&-4097|2,pt=!1,Cn=i}}}function Zb(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Cn=i}function Jl(i){if(i!==Cn)return!1;if(!pt)return Zb(i),pt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!Yh(i.type,i.memoizedProps)),s&&(s=kn)){if(Zh(i))throw e2(),Error(n(418));for(;s;)Xb(i,s),s=ai(s.nextSibling)}if(Zb(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){kn=ai(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}kn=null}}else kn=Cn?ai(i.stateNode.nextSibling):null;return!0}function e2(){for(var i=kn;i;)i=ai(i.nextSibling)}function us(){kn=Cn=null,pt=!1}function tp(i){er===null?er=[i]:er.push(i)}var Y8=F.ReactCurrentBatchConfig;function Ba(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 f=l.stateNode}if(!f)throw Error(n(147,i));var g=f,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 Zl(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function t2(i){var s=i._init;return s(i._payload)}function n2(i){function s(V,H){if(i){var W=V.deletions;W===null?(V.deletions=[H],V.flags|=16):W.push(H)}}function l(V,H){if(!i)return null;for(;H!==null;)s(V,H),H=H.sibling;return null}function f(V,H){for(V=new Map;H!==null;)H.key!==null?V.set(H.key,H):V.set(H.index,H),H=H.sibling;return V}function g(V,H){return V=yi(V,H),V.index=0,V.sibling=null,V}function y(V,H,W){return V.index=W,i?(W=V.alternate,W!==null?(W=W.index,W<H?(V.flags|=2,H):W):(V.flags|=2,H)):(V.flags|=1048576,H)}function x(V){return i&&V.alternate===null&&(V.flags|=2),V}function O(V,H,W,Ee){return H===null||H.tag!==6?(H=Wp(W,V.mode,Ee),H.return=V,H):(H=g(H,W),H.return=V,H)}function B(V,H,W,Ee){var ke=W.type;return ke===q?se(V,H,W.props.children,Ee,W.key):H!==null&&(H.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ne&&t2(ke)===H.type)?(Ee=g(H,W.props),Ee.ref=Ba(V,H,W),Ee.return=V,Ee):(Ee=wc(W.type,W.key,W.props,null,V.mode,Ee),Ee.ref=Ba(V,H,W),Ee.return=V,Ee)}function G(V,H,W,Ee){return H===null||H.tag!==4||H.stateNode.containerInfo!==W.containerInfo||H.stateNode.implementation!==W.implementation?(H=qp(W,V.mode,Ee),H.return=V,H):(H=g(H,W.children||[]),H.return=V,H)}function se(V,H,W,Ee,ke){return H===null||H.tag!==7?(H=oo(W,V.mode,Ee,ke),H.return=V,H):(H=g(H,W),H.return=V,H)}function de(V,H,W){if(typeof H=="string"&&H!==""||typeof H=="number")return H=Wp(""+H,V.mode,W),H.return=V,H;if(typeof H=="object"&&H!==null){switch(H.$$typeof){case z:return W=wc(H.type,H.key,H.props,null,V.mode,W),W.ref=Ba(V,null,H),W.return=V,W;case D:return H=qp(H,V.mode,W),H.return=V,H;case Ne:var Ee=H._init;return de(V,Ee(H._payload),W)}if(Jr(H)||te(H))return H=oo(H,V.mode,W,null),H.return=V,H;Zl(V,H)}return null}function re(V,H,W,Ee){var ke=H!==null?H.key:null;if(typeof W=="string"&&W!==""||typeof W=="number")return ke!==null?null:O(V,H,""+W,Ee);if(typeof W=="object"&&W!==null){switch(W.$$typeof){case z:return W.key===ke?B(V,H,W,Ee):null;case D:return W.key===ke?G(V,H,W,Ee):null;case Ne:return ke=W._init,re(V,H,ke(W._payload),Ee)}if(Jr(W)||te(W))return ke!==null?null:se(V,H,W,Ee,null);Zl(V,W)}return null}function _e(V,H,W,Ee,ke){if(typeof Ee=="string"&&Ee!==""||typeof Ee=="number")return V=V.get(W)||null,O(H,V,""+Ee,ke);if(typeof Ee=="object"&&Ee!==null){switch(Ee.$$typeof){case z:return V=V.get(Ee.key===null?W:Ee.key)||null,B(H,V,Ee,ke);case D:return V=V.get(Ee.key===null?W:Ee.key)||null,G(H,V,Ee,ke);case Ne:var De=Ee._init;return _e(V,H,W,De(Ee._payload),ke)}if(Jr(Ee)||te(Ee))return V=V.get(W)||null,se(H,V,Ee,ke,null);Zl(H,Ee)}return null}function Ae(V,H,W,Ee){for(var ke=null,De=null,Me=H,Ue=H=0,Ut=null;Me!==null&&Ue<W.length;Ue++){Me.index>Ue?(Ut=Me,Me=null):Ut=Me.sibling;var Ze=re(V,Me,W[Ue],Ee);if(Ze===null){Me===null&&(Me=Ut);break}i&&Me&&Ze.alternate===null&&s(V,Me),H=y(Ze,H,Ue),De===null?ke=Ze:De.sibling=Ze,De=Ze,Me=Ut}if(Ue===W.length)return l(V,Me),pt&&Xi(V,Ue),ke;if(Me===null){for(;Ue<W.length;Ue++)Me=de(V,W[Ue],Ee),Me!==null&&(H=y(Me,H,Ue),De===null?ke=Me:De.sibling=Me,De=Me);return pt&&Xi(V,Ue),ke}for(Me=f(V,Me);Ue<W.length;Ue++)Ut=_e(Me,V,Ue,W[Ue],Ee),Ut!==null&&(i&&Ut.alternate!==null&&Me.delete(Ut.key===null?Ue:Ut.key),H=y(Ut,H,Ue),De===null?ke=Ut:De.sibling=Ut,De=Ut);return i&&Me.forEach(function(Ti){return s(V,Ti)}),pt&&Xi(V,Ue),ke}function Ce(V,H,W,Ee){var ke=te(W);if(typeof ke!="function")throw Error(n(150));if(W=ke.call(W),W==null)throw Error(n(151));for(var De=ke=null,Me=H,Ue=H=0,Ut=null,Ze=W.next();Me!==null&&!Ze.done;Ue++,Ze=W.next()){Me.index>Ue?(Ut=Me,Me=null):Ut=Me.sibling;var Ti=re(V,Me,Ze.value,Ee);if(Ti===null){Me===null&&(Me=Ut);break}i&&Me&&Ti.alternate===null&&s(V,Me),H=y(Ti,H,Ue),De===null?ke=Ti:De.sibling=Ti,De=Ti,Me=Ut}if(Ze.done)return l(V,Me),pt&&Xi(V,Ue),ke;if(Me===null){for(;!Ze.done;Ue++,Ze=W.next())Ze=de(V,Ze.value,Ee),Ze!==null&&(H=y(Ze,H,Ue),De===null?ke=Ze:De.sibling=Ze,De=Ze);return pt&&Xi(V,Ue),ke}for(Me=f(V,Me);!Ze.done;Ue++,Ze=W.next())Ze=_e(Me,V,Ue,Ze.value,Ee),Ze!==null&&(i&&Ze.alternate!==null&&Me.delete(Ze.key===null?Ue:Ze.key),H=y(Ze,H,Ue),De===null?ke=Ze:De.sibling=Ze,De=Ze);return i&&Me.forEach(function(SM){return s(V,SM)}),pt&&Xi(V,Ue),ke}function wt(V,H,W,Ee){if(typeof W=="object"&&W!==null&&W.type===q&&W.key===null&&(W=W.props.children),typeof W=="object"&&W!==null){switch(W.$$typeof){case z:e:{for(var ke=W.key,De=H;De!==null;){if(De.key===ke){if(ke=W.type,ke===q){if(De.tag===7){l(V,De.sibling),H=g(De,W.props.children),H.return=V,V=H;break e}}else if(De.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ne&&t2(ke)===De.type){l(V,De.sibling),H=g(De,W.props),H.ref=Ba(V,De,W),H.return=V,V=H;break e}l(V,De);break}else s(V,De);De=De.sibling}W.type===q?(H=oo(W.props.children,V.mode,Ee,W.key),H.return=V,V=H):(Ee=wc(W.type,W.key,W.props,null,V.mode,Ee),Ee.ref=Ba(V,H,W),Ee.return=V,V=Ee)}return x(V);case D:e:{for(De=W.key;H!==null;){if(H.key===De)if(H.tag===4&&H.stateNode.containerInfo===W.containerInfo&&H.stateNode.implementation===W.implementation){l(V,H.sibling),H=g(H,W.children||[]),H.return=V,V=H;break e}else{l(V,H);break}else s(V,H);H=H.sibling}H=qp(W,V.mode,Ee),H.return=V,V=H}return x(V);case Ne:return De=W._init,wt(V,H,De(W._payload),Ee)}if(Jr(W))return Ae(V,H,W,Ee);if(te(W))return Ce(V,H,W,Ee);Zl(V,W)}return typeof W=="string"&&W!==""||typeof W=="number"?(W=""+W,H!==null&&H.tag===6?(l(V,H.sibling),H=g(H,W),H.return=V,V=H):(l(V,H),H=Wp(W,V.mode,Ee),H.return=V,V=H),x(V)):l(V,H)}return wt}var ls=n2(!0),r2=n2(!1),ec=ui(null),tc=null,cs=null,np=null;function rp(){np=cs=tc=null}function ip(i){var s=ec.current;ct(ec),i._currentValue=s}function op(i,s,l){for(;i!==null;){var f=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,f!==null&&(f.childLanes|=s)):f!==null&&(f.childLanes&s)!==s&&(f.childLanes|=s),i===l)break;i=i.return}}function ds(i,s){tc=i,np=cs=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(En=!0),i.firstContext=null)}function Un(i){var s=i._currentValue;if(np!==i)if(i={context:i,memoizedValue:s,next:null},cs===null){if(tc===null)throw Error(n(308));cs=i,tc.dependencies={lanes:0,firstContext:i}}else cs=cs.next=i;return s}var Ji=null;function sp(i){Ji===null?Ji=[i]:Ji.push(i)}function i2(i,s,l,f){var g=s.interleaved;return g===null?(l.next=l,sp(s)):(l.next=g.next,g.next=l),s.interleaved=l,Mr(i,f)}function Mr(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 di=!1;function ap(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function o2(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 Fr(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function fi(i,s,l){var f=i.updateQueue;if(f===null)return null;if(f=f.shared,(Xe&2)!==0){var g=f.pending;return g===null?s.next=s:(s.next=g.next,g.next=s),f.pending=s,Mr(i,l)}return g=f.interleaved,g===null?(s.next=s,sp(f)):(s.next=g.next,g.next=s),f.interleaved=s,Mr(i,l)}function nc(i,s,l){if(s=s.updateQueue,s!==null&&(s=s.shared,(l&4194240)!==0)){var f=s.lanes;f&=i.pendingLanes,l|=f,s.lanes=l,xh(i,l)}}function s2(i,s){var l=i.updateQueue,f=i.alternate;if(f!==null&&(f=f.updateQueue,l===f)){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:f.baseState,firstBaseUpdate:g,lastBaseUpdate:y,shared:f.shared,effects:f.effects},i.updateQueue=l;return}i=l.lastBaseUpdate,i===null?l.firstBaseUpdate=s:i.next=s,l.lastBaseUpdate=s}function rc(i,s,l,f){var g=i.updateQueue;di=!1;var y=g.firstBaseUpdate,x=g.lastBaseUpdate,O=g.shared.pending;if(O!==null){g.shared.pending=null;var B=O,G=B.next;B.next=null,x===null?y=G:x.next=G,x=B;var se=i.alternate;se!==null&&(se=se.updateQueue,O=se.lastBaseUpdate,O!==x&&(O===null?se.firstBaseUpdate=G:O.next=G,se.lastBaseUpdate=B))}if(y!==null){var de=g.baseState;x=0,se=G=B=null,O=y;do{var re=O.lane,_e=O.eventTime;if((f&re)===re){se!==null&&(se=se.next={eventTime:_e,lane:0,tag:O.tag,payload:O.payload,callback:O.callback,next:null});e:{var Ae=i,Ce=O;switch(re=s,_e=l,Ce.tag){case 1:if(Ae=Ce.payload,typeof Ae=="function"){de=Ae.call(_e,de,re);break e}de=Ae;break e;case 3:Ae.flags=Ae.flags&-65537|128;case 0:if(Ae=Ce.payload,re=typeof Ae=="function"?Ae.call(_e,de,re):Ae,re==null)break e;de=S({},de,re);break e;case 2:di=!0}}O.callback!==null&&O.lane!==0&&(i.flags|=64,re=g.effects,re===null?g.effects=[O]:re.push(O))}else _e={eventTime:_e,lane:re,tag:O.tag,payload:O.payload,callback:O.callback,next:null},se===null?(G=se=_e,B=de):se=se.next=_e,x|=re;if(O=O.next,O===null){if(O=g.shared.pending,O===null)break;re=O,O=re.next,re.next=null,g.lastBaseUpdate=re,g.shared.pending=null}}while(!0);if(se===null&&(B=de),g.baseState=B,g.firstBaseUpdate=G,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);to|=x,i.lanes=x,i.memoizedState=de}}function a2(i,s,l){if(i=s.effects,s.effects=null,i!==null)for(s=0;s<i.length;s++){var f=i[s],g=f.callback;if(g!==null){if(f.callback=null,f=l,typeof g!="function")throw Error(n(191,g));g.call(f)}}}var Ua={},xr=ui(Ua),Ha=ui(Ua),za=ui(Ua);function Zi(i){if(i===Ua)throw Error(n(174));return i}function up(i,s){switch(at(za,s),at(Ha,i),at(xr,Ua),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:ye(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=ye(s,i)}ct(xr),at(xr,s)}function fs(){ct(xr),ct(Ha),ct(za)}function u2(i){Zi(za.current);var s=Zi(xr.current),l=ye(s,i.type);s!==l&&(at(Ha,i),at(xr,l))}function lp(i){Ha.current===i&&(ct(xr),ct(Ha))}var mt=ui(0);function ic(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 cp=[];function dp(){for(var i=0;i<cp.length;i++)cp[i]._workInProgressVersionPrimary=null;cp.length=0}var oc=F.ReactCurrentDispatcher,fp=F.ReactCurrentBatchConfig,eo=0,gt=null,Ot=null,Ft=null,sc=!1,ja=!1,$a=0,W8=0;function Qt(){throw Error(n(321))}function hp(i,s){if(s===null)return!1;for(var l=0;l<s.length&&l<i.length;l++)if(!Zn(i[l],s[l]))return!1;return!0}function pp(i,s,l,f,g,y){if(eo=y,gt=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,oc.current=i===null||i.memoizedState===null?Q8:X8,i=l(f,g),ja){y=0;do{if(ja=!1,$a=0,25<=y)throw Error(n(301));y+=1,Ft=Ot=null,s.updateQueue=null,oc.current=J8,i=l(f,g)}while(ja)}if(oc.current=lc,s=Ot!==null&&Ot.next!==null,eo=0,Ft=Ot=gt=null,sc=!1,s)throw Error(n(300));return i}function mp(){var i=$a!==0;return $a=0,i}function _r(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ft===null?gt.memoizedState=Ft=i:Ft=Ft.next=i,Ft}function Hn(){if(Ot===null){var i=gt.alternate;i=i!==null?i.memoizedState:null}else i=Ot.next;var s=Ft===null?gt.memoizedState:Ft.next;if(s!==null)Ft=s,Ot=i;else{if(i===null)throw Error(n(310));Ot=i,i={memoizedState:Ot.memoizedState,baseState:Ot.baseState,baseQueue:Ot.baseQueue,queue:Ot.queue,next:null},Ft===null?gt.memoizedState=Ft=i:Ft=Ft.next=i}return Ft}function Va(i,s){return typeof s=="function"?s(i):s}function gp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=Ot,g=f.baseQueue,y=l.pending;if(y!==null){if(g!==null){var x=g.next;g.next=y.next,y.next=x}f.baseQueue=g=y,l.pending=null}if(g!==null){y=g.next,f=f.baseState;var O=x=null,B=null,G=y;do{var se=G.lane;if((eo&se)===se)B!==null&&(B=B.next={lane:0,action:G.action,hasEagerState:G.hasEagerState,eagerState:G.eagerState,next:null}),f=G.hasEagerState?G.eagerState:i(f,G.action);else{var de={lane:se,action:G.action,hasEagerState:G.hasEagerState,eagerState:G.eagerState,next:null};B===null?(O=B=de,x=f):B=B.next=de,gt.lanes|=se,to|=se}G=G.next}while(G!==null&&G!==y);B===null?x=f:B.next=O,Zn(f,s.memoizedState)||(En=!0),s.memoizedState=f,s.baseState=x,s.baseQueue=B,l.lastRenderedState=f}if(i=l.interleaved,i!==null){g=i;do y=g.lane,gt.lanes|=y,to|=y,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function Ep(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=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);Zn(y,s.memoizedState)||(En=!0),s.memoizedState=y,s.baseQueue===null&&(s.baseState=y),l.lastRenderedState=y}return[y,f]}function l2(){}function c2(i,s){var l=gt,f=Hn(),g=s(),y=!Zn(f.memoizedState,g);if(y&&(f.memoizedState=g,En=!0),f=f.queue,yp(h2.bind(null,l,f,i),[i]),f.getSnapshot!==s||y||Ft!==null&&Ft.memoizedState.tag&1){if(l.flags|=2048,Ya(9,f2.bind(null,l,f,g,s),void 0,null),Bt===null)throw Error(n(349));(eo&30)!==0||d2(l,s,g)}return g}function d2(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function f2(i,s,l,f){s.value=l,s.getSnapshot=f,p2(s)&&m2(i)}function h2(i,s,l){return l(function(){p2(s)&&m2(i)})}function p2(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!Zn(i,l)}catch(f){return!0}}function m2(i){var s=Mr(i,1);s!==null&&ir(s,i,1,-1)}function g2(i){var s=_r();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Va,lastRenderedState:i},s.queue=i,i=i.dispatch=K8.bind(null,gt,i),[s.memoizedState,i]}function Ya(i,s,l,f){return i={tag:i,create:s,destroy:l,deps:f,next:null},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.lastEffect=i.next=i):(l=s.lastEffect,l===null?s.lastEffect=i.next=i:(f=l.next,l.next=i,i.next=f,s.lastEffect=i)),i}function E2(){return Hn().memoizedState}function ac(i,s,l,f){var g=_r();gt.flags|=i,g.memoizedState=Ya(1|s,l,void 0,f===void 0?null:f)}function uc(i,s,l,f){var g=Hn();f=f===void 0?null:f;var y=void 0;if(Ot!==null){var x=Ot.memoizedState;if(y=x.destroy,f!==null&&hp(f,x.deps)){g.memoizedState=Ya(s,l,y,f);return}}gt.flags|=i,g.memoizedState=Ya(1|s,l,y,f)}function y2(i,s){return ac(8390656,8,i,s)}function yp(i,s){return uc(2048,8,i,s)}function T2(i,s){return uc(4,2,i,s)}function b2(i,s){return uc(4,4,i,s)}function x2(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 _2(i,s,l){return l=l!=null?l.concat([i]):null,uc(4,4,x2.bind(null,s,i),l)}function Tp(){}function w2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&hp(s,f[1])?f[0]:(l.memoizedState=[i,s],i)}function S2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&hp(s,f[1])?f[0]:(i=i(),l.memoizedState=[i,s],i)}function A2(i,s,l){return(eo&21)===0?(i.baseState&&(i.baseState=!1,En=!0),i.memoizedState=l):(Zn(l,s)||(l=tb(),gt.lanes|=l,to|=l,i.baseState=!0),s)}function q8(i,s){var l=nt;nt=l!==0&&4>l?l:4,i(!0);var f=fp.transition;fp.transition={};try{i(!1),s()}finally{nt=l,fp.transition=f}}function v2(){return Hn().memoizedState}function G8(i,s,l){var f=gi(i);if(l={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null},C2(i))k2(s,l);else if(l=i2(i,s,l,f),l!==null){var g=rn();ir(l,i,f,g),N2(l,s,f)}}function K8(i,s,l){var f=gi(i),g={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null};if(C2(i))k2(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,Zn(O,x)){var B=s.interleaved;B===null?(g.next=g,sp(s)):(g.next=B.next,B.next=g),s.interleaved=g;return}}catch(G){}l=i2(i,s,g,f),l!==null&&(g=rn(),ir(l,i,f,g),N2(l,s,f))}}function C2(i){var s=i.alternate;return i===gt||s!==null&&s===gt}function k2(i,s){ja=sc=!0;var l=i.pending;l===null?s.next=s:(s.next=l.next,l.next=s),i.pending=s}function N2(i,s,l){if((l&4194240)!==0){var f=s.lanes;f&=i.pendingLanes,l|=f,s.lanes=l,xh(i,l)}}var lc={readContext:Un,useCallback:Qt,useContext:Qt,useEffect:Qt,useImperativeHandle:Qt,useInsertionEffect:Qt,useLayoutEffect:Qt,useMemo:Qt,useReducer:Qt,useRef:Qt,useState:Qt,useDebugValue:Qt,useDeferredValue:Qt,useTransition:Qt,useMutableSource:Qt,useSyncExternalStore:Qt,useId:Qt,unstable_isNewReconciler:!1},Q8={readContext:Un,useCallback:function(i,s){return _r().memoizedState=[i,s===void 0?null:s],i},useContext:Un,useEffect:y2,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,ac(4194308,4,x2.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=_r();return s=s===void 0?null:s,i=i(),l.memoizedState=[i,s],i},useReducer:function(i,s,l){var f=_r();return s=l!==void 0?l(s):s,f.memoizedState=f.baseState=s,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:i,lastRenderedState:s},f.queue=i,i=i.dispatch=G8.bind(null,gt,i),[f.memoizedState,i]},useRef:function(i){var s=_r();return i={current:i},s.memoizedState=i},useState:g2,useDebugValue:Tp,useDeferredValue:function(i){return _r().memoizedState=i},useTransition:function(){var i=g2(!1),s=i[0];return i=q8.bind(null,i[1]),_r().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var f=gt,g=_r();if(pt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Bt===null)throw Error(n(349));(eo&30)!==0||d2(f,s,l)}g.memoizedState=l;var y={value:l,getSnapshot:s};return g.queue=y,y2(h2.bind(null,f,y,i),[i]),f.flags|=2048,Ya(9,f2.bind(null,f,y,l,s),void 0,null),l},useId:function(){var i=_r(),s=Bt.identifierPrefix;if(pt){var l=Dr,f=Lr;l=(f&~(1<<32-Jn(f)-1)).toString(32)+l,s=":"+s+"R"+l,l=$a++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=W8++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},X8={readContext:Un,useCallback:w2,useContext:Un,useEffect:yp,useImperativeHandle:_2,useInsertionEffect:T2,useLayoutEffect:b2,useMemo:S2,useReducer:gp,useRef:E2,useState:function(){return gp(Va)},useDebugValue:Tp,useDeferredValue:function(i){var s=Hn();return A2(s,Ot.memoizedState,i)},useTransition:function(){var i=gp(Va)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:l2,useSyncExternalStore:c2,useId:v2,unstable_isNewReconciler:!1},J8={readContext:Un,useCallback:w2,useContext:Un,useEffect:yp,useImperativeHandle:_2,useInsertionEffect:T2,useLayoutEffect:b2,useMemo:S2,useReducer:Ep,useRef:E2,useState:function(){return Ep(Va)},useDebugValue:Tp,useDeferredValue:function(i){var s=Hn();return Ot===null?s.memoizedState=i:A2(s,Ot.memoizedState,i)},useTransition:function(){var i=Ep(Va)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:l2,useSyncExternalStore:c2,useId:v2,unstable_isNewReconciler:!1};function tr(i,s){if(i&&i.defaultProps){s=S({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function bp(i,s,l,f){s=i.memoizedState,l=l(f,s),l=l==null?s:S({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var cc={isMounted:function(i){return(i=i._reactInternals)?qi(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var f=rn(),g=gi(i),y=Fr(f,g);y.payload=s,l!=null&&(y.callback=l),s=fi(i,y,g),s!==null&&(ir(s,i,g,f),nc(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var f=rn(),g=gi(i),y=Fr(f,g);y.tag=1,y.payload=s,l!=null&&(y.callback=l),s=fi(i,y,g),s!==null&&(ir(s,i,g,f),nc(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=rn(),f=gi(i),g=Fr(l,f);g.tag=2,s!=null&&(g.callback=s),s=fi(i,g,f),s!==null&&(ir(s,i,f,l),nc(s,i,f))}};function O2(i,s,l,f,g,y,x){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(f,y,x):s.prototype&&s.prototype.isPureReactComponent?!Ia(l,f)||!Ia(g,y):!0}function I2(i,s,l){var f=!1,g=li,y=s.contextType;return typeof y=="object"&&y!==null?y=Un(y):(g=gn(s)?Ki:Kt.current,f=s.contextTypes,y=(f=f!=null)?os(i,g):li),s=new s(l,y),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=cc,i.stateNode=s,s._reactInternals=i,f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=y),s}function R2(i,s,l,f){i=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(l,f),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(l,f),s.state!==i&&cc.enqueueReplaceState(s,s.state,null)}function xp(i,s,l,f){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},ap(i);var y=s.contextType;typeof y=="object"&&y!==null?g.context=Un(y):(y=gn(s)?Ki:Kt.current,g.context=os(i,y)),g.state=i.memoizedState,y=s.getDerivedStateFromProps,typeof y=="function"&&(bp(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&&cc.enqueueReplaceState(g,g.state,null),rc(i,l,g,f),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function hs(i,s){try{var l="",f=s;do l+=Pe(f),f=f.return;while(f);var g=l}catch(y){g=`
22
22
  Error generating stack: `+y.message+`
23
- `+y.stack}return{value:i,source:s,stack:E,digest:null}}function Ap(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function vp(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var Q8=typeof WeakMap=="function"?WeakMap:Map;function L2(i,s,l){l=Mr(-1,l),l.tag=3,l.payload={element:null};var f=s.value;return l.callback=function(){Ec||(Ec=!0,zp=f),vp(i,s)},l}function D2(i,s,l){l=Mr(-1,l),l.tag=3;var f=i.type.getDerivedStateFromError;if(typeof f=="function"){var E=s.value;l.payload=function(){return f(E)},l.callback=function(){vp(i,s)}}var y=i.stateNode;return y!==null&&typeof y.componentDidCatch=="function"&&(l.callback=function(){vp(i,s),typeof f!="function"&&(pi===null?pi=new Set([this]):pi.add(this));var _=s.stack;this.componentDidCatch(s.value,{componentStack:_!==null?_:""})}),l}function M2(i,s,l){var f=i.pingCache;if(f===null){f=i.pingCache=new Q8;var E=new Set;f.set(s,E)}else E=f.get(s),E===void 0&&(E=new Set,f.set(s,E));E.has(l)||(E.add(l),i=cM.bind(null,i,s,l),s.then(i,i))}function F2(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 B2(i,s,l,f,E){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=Mr(-1,1),s.tag=2,fi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=E,i)}var X8=F.ReactCurrentOwner,En=!1;function tn(i,s,l,f){s.child=i===null?i2(s,null,l,f):ls(s,i.child,l,f)}function U2(i,s,l,f,E){l=l.render;var y=s.ref;return ds(s,E),f=Ep(i,s,l,f,y,E),l=yp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~E,Fr(i,s,E)):(pt&&l&&ep(s),s.flags|=1,tn(i,s,f,E),s.child)}function H2(i,s,l,f,E){if(i===null){var y=l.type;return typeof y=="function"&&!Gp(y)&&y.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=y,z2(i,s,y,f,E)):(i=Sc(l.type,null,f,s,s.mode,E),i.ref=s.ref,i.return=s,s.child=i)}if(y=i.child,(i.lanes&E)===0){var _=y.memoizedProps;if(l=l.compare,l=l!==null?l:Ia,l(_,f)&&i.ref===s.ref)return Fr(i,s,E)}return s.flags|=1,i=yi(y,f),i.ref=s.ref,i.return=s,s.child=i}function z2(i,s,l,f,E){if(i!==null){var y=i.memoizedProps;if(Ia(y,f)&&i.ref===s.ref)if(En=!1,s.pendingProps=f=y,(i.lanes&E)!==0)(i.flags&131072)!==0&&(En=!0);else return s.lanes=i.lanes,Fr(i,s,E)}return Cp(i,s,l,f,E)}function j2(i,s,l){var f=s.pendingProps,E=f.children,y=i!==null?i.memoizedState:null;if(f.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},at(ms,Nn),Nn|=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,at(ms,Nn),Nn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},f=y!==null?y.baseLanes:l,at(ms,Nn),Nn|=f}else y!==null?(f=y.baseLanes|l,s.memoizedState=null):f=l,at(ms,Nn),Nn|=f;return tn(i,s,E,l),s.child}function $2(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function Cp(i,s,l,f,E){var y=gn(l)?Gi:Kt.current;return y=os(s,y),ds(s,E),l=Ep(i,s,l,f,y,E),f=yp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~E,Fr(i,s,E)):(pt&&f&&ep(s),s.flags|=1,tn(i,s,l,E),s.child)}function V2(i,s,l,f,E){if(gn(l)){var y=!0;Gl(s)}else y=!1;if(ds(s,E),s.stateNode===null)fc(i,s),R2(s,l,f),wp(s,l,f,E),f=!0;else if(i===null){var _=s.stateNode,I=s.memoizedProps;_.props=I;var B=_.context,G=l.contextType;typeof G=="object"&&G!==null?G=Un(G):(G=gn(l)?Gi:Kt.current,G=os(s,G));var se=l.getDerivedStateFromProps,de=typeof se=="function"||typeof _.getSnapshotBeforeUpdate=="function";de||typeof _.UNSAFE_componentWillReceiveProps!="function"&&typeof _.componentWillReceiveProps!="function"||(I!==f||B!==G)&&P2(s,_,f,G),di=!1;var ie=s.memoizedState;_.state=ie,rc(s,f,_,E),B=s.memoizedState,I!==f||ie!==B||mn.current||di?(typeof se=="function"&&(Sp(s,l,se,f),B=s.memoizedState),(I=di||I2(s,l,I,f,ie,B,G))?(de||typeof _.UNSAFE_componentWillMount!="function"&&typeof _.componentWillMount!="function"||(typeof _.componentWillMount=="function"&&_.componentWillMount(),typeof _.UNSAFE_componentWillMount=="function"&&_.UNSAFE_componentWillMount()),typeof _.componentDidMount=="function"&&(s.flags|=4194308)):(typeof _.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=f,s.memoizedState=B),_.props=f,_.state=B,_.context=G,f=I):(typeof _.componentDidMount=="function"&&(s.flags|=4194308),f=!1)}else{_=s.stateNode,s2(i,s),I=s.memoizedProps,G=s.type===s.elementType?I:tr(s.type,I),_.props=G,de=s.pendingProps,ie=_.context,B=l.contextType,typeof B=="object"&&B!==null?B=Un(B):(B=gn(l)?Gi:Kt.current,B=os(s,B));var _e=l.getDerivedStateFromProps;(se=typeof _e=="function"||typeof _.getSnapshotBeforeUpdate=="function")||typeof _.UNSAFE_componentWillReceiveProps!="function"&&typeof _.componentWillReceiveProps!="function"||(I!==de||ie!==B)&&P2(s,_,f,B),di=!1,ie=s.memoizedState,_.state=ie,rc(s,f,_,E);var Ae=s.memoizedState;I!==de||ie!==Ae||mn.current||di?(typeof _e=="function"&&(Sp(s,l,_e,f),Ae=s.memoizedState),(G=di||I2(s,l,G,f,ie,Ae,B)||!1)?(se||typeof _.UNSAFE_componentWillUpdate!="function"&&typeof _.componentWillUpdate!="function"||(typeof _.componentWillUpdate=="function"&&_.componentWillUpdate(f,Ae,B),typeof _.UNSAFE_componentWillUpdate=="function"&&_.UNSAFE_componentWillUpdate(f,Ae,B)),typeof _.componentDidUpdate=="function"&&(s.flags|=4),typeof _.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof _.componentDidUpdate!="function"||I===i.memoizedProps&&ie===i.memoizedState||(s.flags|=4),typeof _.getSnapshotBeforeUpdate!="function"||I===i.memoizedProps&&ie===i.memoizedState||(s.flags|=1024),s.memoizedProps=f,s.memoizedState=Ae),_.props=f,_.state=Ae,_.context=B,f=G):(typeof _.componentDidUpdate!="function"||I===i.memoizedProps&&ie===i.memoizedState||(s.flags|=4),typeof _.getSnapshotBeforeUpdate!="function"||I===i.memoizedProps&&ie===i.memoizedState||(s.flags|=1024),f=!1)}return kp(i,s,l,f,y,E)}function kp(i,s,l,f,E,y){$2(i,s);var _=(s.flags&128)!==0;if(!f&&!_)return E&&Kb(s,l,!1),Fr(i,s,y);f=s.stateNode,X8.current=s;var I=_&&typeof l.getDerivedStateFromError!="function"?null:f.render();return s.flags|=1,i!==null&&_?(s.child=ls(s,i.child,null,y),s.child=ls(s,null,I,y)):tn(i,s,I,y),s.memoizedState=f.state,E&&Kb(s,l,!0),s.child}function Y2(i){var s=i.stateNode;s.pendingContext?qb(i,s.pendingContext,s.pendingContext!==s.context):s.context&&qb(i,s.context,!1),dp(i,s.containerInfo)}function W2(i,s,l,f,E){return us(),ip(E),s.flags|=256,tn(i,s,l,f),s.child}var Np={dehydrated:null,treeContext:null,retryLane:0};function Op(i){return{baseLanes:i,cachePool:null,transitions:null}}function q2(i,s,l){var f=s.pendingProps,E=mt.current,y=!1,_=(s.flags&128)!==0,I;if((I=_)||(I=i!==null&&i.memoizedState===null?!1:(E&2)!==0),I?(y=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(E|=1),at(mt,E&1),i===null)return rp(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):(_=f.children,i=f.fallback,y?(f=s.mode,y=s.child,_={mode:"hidden",children:_},(f&1)===0&&y!==null?(y.childLanes=0,y.pendingProps=_):y=wc(_,f,0,null),i=io(i,f,l,null),y.return=s,i.return=s,y.sibling=i,s.child=y,s.child.memoizedState=Op(l),s.memoizedState=Np,i):Ip(s,_));if(E=i.memoizedState,E!==null&&(I=E.dehydrated,I!==null))return J8(i,s,_,f,I,E,l);if(y){y=f.fallback,_=s.mode,E=i.child,I=E.sibling;var B={mode:"hidden",children:f.children};return(_&1)===0&&s.child!==E?(f=s.child,f.childLanes=0,f.pendingProps=B,s.deletions=null):(f=yi(E,B),f.subtreeFlags=E.subtreeFlags&14680064),I!==null?y=yi(I,y):(y=io(y,_,l,null),y.flags|=2),y.return=s,f.return=s,f.sibling=y,s.child=f,f=y,y=s.child,_=i.child.memoizedState,_=_===null?Op(l):{baseLanes:_.baseLanes|l,cachePool:null,transitions:_.transitions},y.memoizedState=_,y.childLanes=i.childLanes&~l,s.memoizedState=Np,f}return y=i.child,i=y.sibling,f=yi(y,{mode:"visible",children:f.children}),(s.mode&1)===0&&(f.lanes=l),f.return=s,f.sibling=null,i!==null&&(l=s.deletions,l===null?(s.deletions=[i],s.flags|=16):l.push(i)),s.child=f,s.memoizedState=null,f}function Ip(i,s){return s=wc({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function dc(i,s,l,f){return f!==null&&ip(f),ls(s,i.child,null,l),i=Ip(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function J8(i,s,l,f,E,y,_){if(l)return s.flags&256?(s.flags&=-257,f=Ap(Error(n(422))),dc(i,s,_,f)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(y=f.fallback,E=s.mode,f=wc({mode:"visible",children:f.children},E,0,null),y=io(y,E,_,null),y.flags|=2,f.return=s,y.return=s,f.sibling=y,s.child=f,(s.mode&1)!==0&&ls(s,i.child,null,_),s.child.memoizedState=Op(_),s.memoizedState=Np,y);if((s.mode&1)===0)return dc(i,s,_,null);if(E.data==="$!"){if(f=E.nextSibling&&E.nextSibling.dataset,f)var I=f.dgst;return f=I,y=Error(n(419)),f=Ap(y,f,void 0),dc(i,s,_,f)}if(I=(_&i.childLanes)!==0,En||I){if(f=Bt,f!==null){switch(_&-_){case 4:E=2;break;case 16:E=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:E=32;break;case 536870912:E=268435456;break;default:E=0}E=(E&(f.suspendedLanes|_))!==0?0:E,E!==0&&E!==y.retryLane&&(y.retryLane=E,Dr(i,E),ir(f,i,E,-1))}return qp(),f=Ap(Error(n(421))),dc(i,s,_,f)}return E.data==="$?"?(s.flags|=128,s.child=i.child,s=dM.bind(null,i),E._reactRetry=s,null):(i=y.treeContext,kn=ai(E.nextSibling),Cn=s,pt=!0,er=null,i!==null&&(Fn[Bn++]=Pr,Fn[Bn++]=Lr,Fn[Bn++]=Ki,Pr=i.id,Lr=i.overflow,Ki=s),s=Ip(s,f.children),s.flags|=4096,s)}function G2(i,s,l){i.lanes|=s;var f=i.alternate;f!==null&&(f.lanes|=s),up(i.return,s,l)}function Rp(i,s,l,f,E){var y=i.memoizedState;y===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:f,tail:l,tailMode:E}:(y.isBackwards=s,y.rendering=null,y.renderingStartTime=0,y.last=f,y.tail=l,y.tailMode=E)}function K2(i,s,l){var f=s.pendingProps,E=f.revealOrder,y=f.tail;if(tn(i,s,f.children,l),f=mt.current,(f&2)!==0)f=f&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&&G2(i,l,s);else if(i.tag===19)G2(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}f&=1}if(at(mt,f),(s.mode&1)===0)s.memoizedState=null;else switch(E){case"forwards":for(l=s.child,E=null;l!==null;)i=l.alternate,i!==null&&ic(i)===null&&(E=l),l=l.sibling;l=E,l===null?(E=s.child,s.child=null):(E=l.sibling,l.sibling=null),Rp(s,!1,E,l,y);break;case"backwards":for(l=null,E=s.child,s.child=null;E!==null;){if(i=E.alternate,i!==null&&ic(i)===null){s.child=E;break}i=E.sibling,E.sibling=l,l=E,E=i}Rp(s,!0,l,null,y);break;case"together":Rp(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function fc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function Fr(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),eo|=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=yi(i,i.pendingProps),s.child=l,l.return=s;i.sibling!==null;)i=i.sibling,l=l.sibling=yi(i,i.pendingProps),l.return=s;l.sibling=null}return s.child}function Z8(i,s,l){switch(s.tag){case 3:Y2(s),us();break;case 5:l2(s);break;case 1:gn(s.type)&&Gl(s);break;case 4:dp(s,s.stateNode.containerInfo);break;case 10:var f=s.type._context,E=s.memoizedProps.value;at(ec,f._currentValue),f._currentValue=E;break;case 13:if(f=s.memoizedState,f!==null)return f.dehydrated!==null?(at(mt,mt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?q2(i,s,l):(at(mt,mt.current&1),i=Fr(i,s,l),i!==null?i.sibling:null);at(mt,mt.current&1);break;case 19:if(f=(l&s.childLanes)!==0,(i.flags&128)!==0){if(f)return K2(i,s,l);s.flags|=128}if(E=s.memoizedState,E!==null&&(E.rendering=null,E.tail=null,E.lastEffect=null),at(mt,mt.current),f)break;return null;case 22:case 23:return s.lanes=0,j2(i,s,l)}return Fr(i,s,l)}var Q2,Pp,X2,J2;Q2=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}},Pp=function(){},X2=function(i,s,l,f){var E=i.memoizedProps;if(E!==f){i=s.stateNode,Ji(xr.current);var y=null;switch(l){case"input":E=Xn(i,E),f=Xn(i,f),y=[];break;case"select":E=w({},E,{value:void 0}),f=w({},f,{value:void 0}),y=[];break;case"textarea":E=ma(i,E),f=ma(i,f),y=[];break;default:typeof E.onClick!="function"&&typeof f.onClick=="function"&&(i.onclick=Yl)}zt(l,f);var _;l=null;for(G in E)if(!f.hasOwnProperty(G)&&E.hasOwnProperty(G)&&E[G]!=null)if(G==="style"){var I=E[G];for(_ in I)I.hasOwnProperty(_)&&(l||(l={}),l[_]="")}else G!=="dangerouslySetInnerHTML"&&G!=="children"&&G!=="suppressContentEditableWarning"&&G!=="suppressHydrationWarning"&&G!=="autoFocus"&&(o.hasOwnProperty(G)?y||(y=[]):(y=y||[]).push(G,null));for(G in f){var B=f[G];if(I=E!=null?E[G]:void 0,f.hasOwnProperty(G)&&B!==I&&(B!=null||I!=null))if(G==="style")if(I){for(_ in I)!I.hasOwnProperty(_)||B&&B.hasOwnProperty(_)||(l||(l={}),l[_]="");for(_ in B)B.hasOwnProperty(_)&&I[_]!==B[_]&&(l||(l={}),l[_]=B[_])}else l||(y||(y=[]),y.push(G,l)),l=B;else G==="dangerouslySetInnerHTML"?(B=B?B.__html:void 0,I=I?I.__html:void 0,B!=null&&I!==B&&(y=y||[]).push(G,B)):G==="children"?typeof B!="string"&&typeof B!="number"||(y=y||[]).push(G,""+B):G!=="suppressContentEditableWarning"&&G!=="suppressHydrationWarning"&&(o.hasOwnProperty(G)?(B!=null&&G==="onScroll"&&lt("scroll",i),y||I===B||(y=[])):(y=y||[]).push(G,B))}l&&(y=y||[]).push("style",l);var G=y;(s.updateQueue=G)&&(s.flags|=4)}},J2=function(i,s,l,f){l!==f&&(s.flags|=4)};function Wa(i,s){if(!pt)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 f=null;l!==null;)l.alternate!==null&&(f=l),l=l.sibling;f===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:f.sibling=null}}function Xt(i){var s=i.alternate!==null&&i.alternate.child===i.child,l=0,f=0;if(s)for(var E=i.child;E!==null;)l|=E.lanes|E.childLanes,f|=E.subtreeFlags&14680064,f|=E.flags&14680064,E.return=i,E=E.sibling;else for(E=i.child;E!==null;)l|=E.lanes|E.childLanes,f|=E.subtreeFlags,f|=E.flags,E.return=i,E=E.sibling;return i.subtreeFlags|=f,i.childLanes=l,s}function eM(i,s,l){var f=s.pendingProps;switch(tp(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Xt(s),null;case 1:return gn(s.type)&&ql(),Xt(s),null;case 3:return f=s.stateNode,fs(),ct(mn),ct(Kt),pp(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(i===null||i.child===null)&&(Jl(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,er!==null&&(Vp(er),er=null))),Pp(i,s),Xt(s),null;case 5:fp(s);var E=Ji(za.current);if(l=s.type,i!==null&&s.stateNode!=null)X2(i,s,l,f,E),i.ref!==s.ref&&(s.flags|=512,s.flags|=2097152);else{if(!f){if(s.stateNode===null)throw Error(n(166));return Xt(s),null}if(i=Ji(xr.current),Jl(s)){f=s.stateNode,l=s.type;var y=s.memoizedProps;switch(f[br]=s,f[Ma]=y,i=(s.mode&1)!==0,l){case"dialog":lt("cancel",f),lt("close",f);break;case"iframe":case"object":case"embed":lt("load",f);break;case"video":case"audio":for(E=0;E<Pa.length;E++)lt(Pa[E],f);break;case"source":lt("error",f);break;case"img":case"image":case"link":lt("error",f),lt("load",f);break;case"details":lt("toggle",f);break;case"input":ha(f,y),lt("invalid",f);break;case"select":f._wrapperState={wasMultiple:!!y.multiple},lt("invalid",f);break;case"textarea":xl(f,y),lt("invalid",f)}zt(l,y),E=null;for(var _ in y)if(y.hasOwnProperty(_)){var I=y[_];_==="children"?typeof I=="string"?f.textContent!==I&&(y.suppressHydrationWarning!==!0&&Vl(f.textContent,I,i),E=["children",I]):typeof I=="number"&&f.textContent!==""+I&&(y.suppressHydrationWarning!==!0&&Vl(f.textContent,I,i),E=["children",""+I]):o.hasOwnProperty(_)&&I!=null&&_==="onScroll"&&lt("scroll",f)}switch(l){case"input":pn(f),bl(f,y,!0);break;case"textarea":pn(f),Sl(f);break;case"select":case"option":break;default:typeof y.onClick=="function"&&(f.onclick=Yl)}f=E,s.updateQueue=f,f!==null&&(s.flags|=4)}else{_=E.nodeType===9?E:E.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=Z(l)),i==="http://www.w3.org/1999/xhtml"?l==="script"?(i=_.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof f.is=="string"?i=_.createElement(l,{is:f.is}):(i=_.createElement(l),l==="select"&&(_=i,f.multiple?_.multiple=!0:f.size&&(_.size=f.size))):i=_.createElementNS(i,l),i[br]=s,i[Ma]=f,Q2(i,s,!1,!1),s.stateNode=i;e:{switch(_=yr(l,f),l){case"dialog":lt("cancel",i),lt("close",i),E=f;break;case"iframe":case"object":case"embed":lt("load",i),E=f;break;case"video":case"audio":for(E=0;E<Pa.length;E++)lt(Pa[E],i);E=f;break;case"source":lt("error",i),E=f;break;case"img":case"image":case"link":lt("error",i),lt("load",i),E=f;break;case"details":lt("toggle",i),E=f;break;case"input":ha(i,f),E=Xn(i,f),lt("invalid",i);break;case"option":E=f;break;case"select":i._wrapperState={wasMultiple:!!f.multiple},E=w({},f,{value:void 0}),lt("invalid",i);break;case"textarea":xl(i,f),E=ma(i,f),lt("invalid",i);break;default:E=f}zt(l,E),I=E;for(y in I)if(I.hasOwnProperty(y)){var B=I[y];y==="style"?ei(i,B):y==="dangerouslySetInnerHTML"?(B=B?B.__html:void 0,B!=null&&Ye(i,B)):y==="children"?typeof B=="string"?(l!=="textarea"||B!=="")&&Qe(i,B):typeof B=="number"&&Qe(i,""+B):y!=="suppressContentEditableWarning"&&y!=="suppressHydrationWarning"&&y!=="autoFocus"&&(o.hasOwnProperty(y)?B!=null&&y==="onScroll"&&lt("scroll",i):B!=null&&R(i,y,B,_))}switch(l){case"input":pn(i),bl(i,f,!1);break;case"textarea":pn(i),Sl(i);break;case"option":f.value!=null&&i.setAttribute("value",""+we(f.value));break;case"select":i.multiple=!!f.multiple,y=f.value,y!=null?Zr(i,!!f.multiple,y,!1):f.defaultValue!=null&&Zr(i,!!f.multiple,f.defaultValue,!0);break;default:typeof E.onClick=="function"&&(i.onclick=Yl)}switch(l){case"button":case"input":case"select":case"textarea":f=!!f.autoFocus;break e;case"img":f=!0;break e;default:f=!1}}f&&(s.flags|=4)}s.ref!==null&&(s.flags|=512,s.flags|=2097152)}return Xt(s),null;case 6:if(i&&s.stateNode!=null)J2(i,s,i.memoizedProps,f);else{if(typeof f!="string"&&s.stateNode===null)throw Error(n(166));if(l=Ji(za.current),Ji(xr.current),Jl(s)){if(f=s.stateNode,l=s.memoizedProps,f[br]=s,(y=f.nodeValue!==l)&&(i=Cn,i!==null))switch(i.tag){case 3:Vl(f.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Vl(f.nodeValue,l,(i.mode&1)!==0)}y&&(s.flags|=4)}else f=(l.nodeType===9?l:l.ownerDocument).createTextNode(f),f[br]=s,s.stateNode=f}return Xt(s),null;case 13:if(ct(mt),f=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(pt&&kn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)t2(),us(),s.flags|=98560,y=!1;else if(y=Jl(s),f!==null&&f.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[br]=s}else us(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;Xt(s),y=!1}else er!==null&&(Vp(er),er=null),y=!0;if(!y)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=l,s):(f=f!==null,f!==(i!==null&&i.memoizedState!==null)&&f&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(mt.current&1)!==0?It===0&&(It=3):qp())),s.updateQueue!==null&&(s.flags|=4),Xt(s),null);case 4:return fs(),Pp(i,s),i===null&&La(s.stateNode.containerInfo),Xt(s),null;case 10:return ap(s.type._context),Xt(s),null;case 17:return gn(s.type)&&ql(),Xt(s),null;case 19:if(ct(mt),y=s.memoizedState,y===null)return Xt(s),null;if(f=(s.flags&128)!==0,_=y.rendering,_===null)if(f)Wa(y,!1);else{if(It!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(_=ic(i),_!==null){for(s.flags|=128,Wa(y,!1),f=_.updateQueue,f!==null&&(s.updateQueue=f,s.flags|=4),s.subtreeFlags=0,f=l,l=s.child;l!==null;)y=l,i=f,y.flags&=14680066,_=y.alternate,_===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=_.childLanes,y.lanes=_.lanes,y.child=_.child,y.subtreeFlags=0,y.deletions=null,y.memoizedProps=_.memoizedProps,y.memoizedState=_.memoizedState,y.updateQueue=_.updateQueue,y.type=_.type,i=_.dependencies,y.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return at(mt,mt.current&1|2),s.child}i=i.sibling}y.tail!==null&&_t()>gs&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304)}else{if(!f)if(i=ic(_),i!==null){if(s.flags|=128,f=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),Wa(y,!0),y.tail===null&&y.tailMode==="hidden"&&!_.alternate&&!pt)return Xt(s),null}else 2*_t()-y.renderingStartTime>gs&&l!==1073741824&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304);y.isBackwards?(_.sibling=s.child,s.child=_):(l=y.last,l!==null?l.sibling=_:s.child=_,y.last=_)}return y.tail!==null?(s=y.tail,y.rendering=s,y.tail=s.sibling,y.renderingStartTime=_t(),s.sibling=null,l=mt.current,at(mt,f?l&1|2:l&1),s):(Xt(s),null);case 22:case 23:return Wp(),f=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==f&&(s.flags|=8192),f&&(s.mode&1)!==0?(Nn&1073741824)!==0&&(Xt(s),s.subtreeFlags&6&&(s.flags|=8192)):Xt(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function tM(i,s){switch(tp(s),s.tag){case 1:return gn(s.type)&&ql(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return fs(),ct(mn),ct(Kt),pp(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return fp(s),null;case 13:if(ct(mt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));us()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ct(mt),null;case 4:return fs(),null;case 10:return ap(s.type._context),null;case 22:case 23:return Wp(),null;case 24:return null;default:return null}}var hc=!1,Jt=!1,nM=typeof WeakSet=="function"?WeakSet:Set,Se=null;function ps(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(f){yt(i,s,f)}else l.current=null}function Lp(i,s,l){try{l()}catch(f){yt(i,s,f)}}var Z2=!1;function rM(i,s){if(Wh=Pl,i=Ib(),Bh(i)){if("selectionStart"in i)var l={start:i.selectionStart,end:i.selectionEnd};else e:{l=(l=i.ownerDocument)&&l.defaultView||window;var f=l.getSelection&&l.getSelection();if(f&&f.rangeCount!==0){l=f.anchorNode;var E=f.anchorOffset,y=f.focusNode;f=f.focusOffset;try{l.nodeType,y.nodeType}catch(Ee){l=null;break e}var _=0,I=-1,B=-1,G=0,se=0,de=i,ie=null;t:for(;;){for(var _e;de!==l||E!==0&&de.nodeType!==3||(I=_+E),de!==y||f!==0&&de.nodeType!==3||(B=_+f),de.nodeType===3&&(_+=de.nodeValue.length),(_e=de.firstChild)!==null;)ie=de,de=_e;for(;;){if(de===i)break t;if(ie===l&&++G===E&&(I=_),ie===y&&++se===f&&(B=_),(_e=de.nextSibling)!==null)break;de=ie,ie=de.parentNode}de=_e}l=I===-1||B===-1?null:{start:I,end:B}}else l=null}l=l||{start:0,end:0}}else l=null;for(qh={focusedElem:i,selectionRange:l},Pl=!1,Se=s;Se!==null;)if(s=Se,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,Se=i;else for(;Se!==null;){s=Se;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 Ce=Ae.memoizedProps,St=Ae.memoizedState,V=s.stateNode,H=V.getSnapshotBeforeUpdate(s.elementType===s.type?Ce:tr(s.type,Ce),St);V.__reactInternalSnapshotBeforeUpdate=H}break;case 3:var W=s.stateNode.containerInfo;W.nodeType===1?W.textContent="":W.nodeType===9&&W.documentElement&&W.removeChild(W.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(Ee){yt(s,s.return,Ee)}if(i=s.sibling,i!==null){i.return=s.return,Se=i;break}Se=s.return}return Ae=Z2,Z2=!1,Ae}function qa(i,s,l){var f=s.updateQueue;if(f=f!==null?f.lastEffect:null,f!==null){var E=f=f.next;do{if((E.tag&i)===i){var y=E.destroy;E.destroy=void 0,y!==void 0&&Lp(s,l,y)}E=E.next}while(E!==f)}}function pc(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 f=l.create;l.destroy=f()}l=l.next}while(l!==s)}}function Dp(i){var s=i.ref;if(s!==null){var l=i.stateNode;i.tag,i=l,typeof s=="function"?s(i):s.current=i}}function ex(i){var s=i.alternate;s!==null&&(i.alternate=null,ex(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[br],delete s[Ma],delete s[Xh],delete s[U8],delete s[H8])),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 tx(i){return i.tag===5||i.tag===3||i.tag===4}function nx(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||tx(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 Mp(i,s,l){var f=i.tag;if(f===5||f===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=Yl));else if(f!==4&&(i=i.child,i!==null))for(Mp(i,s,l),i=i.sibling;i!==null;)Mp(i,s,l),i=i.sibling}function Fp(i,s,l){var f=i.tag;if(f===5||f===6)i=i.stateNode,s?l.insertBefore(i,s):l.appendChild(i);else if(f!==4&&(i=i.child,i!==null))for(Fp(i,s,l),i=i.sibling;i!==null;)Fp(i,s,l),i=i.sibling}var jt=null,nr=!1;function hi(i,s,l){for(l=l.child;l!==null;)rx(i,s,l),l=l.sibling}function rx(i,s,l){if(Tr&&typeof Tr.onCommitFiberUnmount=="function")try{Tr.onCommitFiberUnmount(Cl,l)}catch(I){}switch(l.tag){case 5:Jt||ps(l,s);case 6:var f=jt,E=nr;jt=null,hi(i,s,l),jt=f,nr=E,jt!==null&&(nr?(i=jt,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):jt.removeChild(l.stateNode));break;case 18:jt!==null&&(nr?(i=jt,l=l.stateNode,i.nodeType===8?Qh(i.parentNode,l):i.nodeType===1&&Qh(i,l),Aa(i)):Qh(jt,l.stateNode));break;case 4:f=jt,E=nr,jt=l.stateNode.containerInfo,nr=!0,hi(i,s,l),jt=f,nr=E;break;case 0:case 11:case 14:case 15:if(!Jt&&(f=l.updateQueue,f!==null&&(f=f.lastEffect,f!==null))){E=f=f.next;do{var y=E,_=y.destroy;y=y.tag,_!==void 0&&((y&2)!==0||(y&4)!==0)&&Lp(l,s,_),E=E.next}while(E!==f)}hi(i,s,l);break;case 1:if(!Jt&&(ps(l,s),f=l.stateNode,typeof f.componentWillUnmount=="function"))try{f.props=l.memoizedProps,f.state=l.memoizedState,f.componentWillUnmount()}catch(I){yt(l,s,I)}hi(i,s,l);break;case 21:hi(i,s,l);break;case 22:l.mode&1?(Jt=(f=Jt)||l.memoizedState!==null,hi(i,s,l),Jt=f):hi(i,s,l);break;default:hi(i,s,l)}}function ix(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new nM),s.forEach(function(f){var E=fM.bind(null,i,f);l.has(f)||(l.add(f),f.then(E,E))})}}function rr(i,s){var l=s.deletions;if(l!==null)for(var f=0;f<l.length;f++){var E=l[f];try{var y=i,_=s,I=_;e:for(;I!==null;){switch(I.tag){case 5:jt=I.stateNode,nr=!1;break e;case 3:jt=I.stateNode.containerInfo,nr=!0;break e;case 4:jt=I.stateNode.containerInfo,nr=!0;break e}I=I.return}if(jt===null)throw Error(n(160));rx(y,_,E),jt=null,nr=!1;var B=E.alternate;B!==null&&(B.return=null),E.return=null}catch(G){yt(E,s,G)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)ox(s,i),s=s.sibling}function ox(i,s){var l=i.alternate,f=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(rr(s,i),Sr(i),f&4){try{qa(3,i,i.return),pc(3,i)}catch(Ce){yt(i,i.return,Ce)}try{qa(5,i,i.return)}catch(Ce){yt(i,i.return,Ce)}}break;case 1:rr(s,i),Sr(i),f&512&&l!==null&&ps(l,l.return);break;case 5:if(rr(s,i),Sr(i),f&512&&l!==null&&ps(l,l.return),i.flags&32){var E=i.stateNode;try{Qe(E,"")}catch(Ce){yt(i,i.return,Ce)}}if(f&4&&(E=i.stateNode,E!=null)){var y=i.memoizedProps,_=l!==null?l.memoizedProps:y,I=i.type,B=i.updateQueue;if(i.updateQueue=null,B!==null)try{I==="input"&&y.type==="radio"&&y.name!=null&&pa(E,y),yr(I,_);var G=yr(I,y);for(_=0;_<B.length;_+=2){var se=B[_],de=B[_+1];se==="style"?ei(E,de):se==="dangerouslySetInnerHTML"?Ye(E,de):se==="children"?Qe(E,de):R(E,se,de,G)}switch(I){case"input":Wo(E,y);break;case"textarea":_l(E,y);break;case"select":var ie=E._wrapperState.wasMultiple;E._wrapperState.wasMultiple=!!y.multiple;var _e=y.value;_e!=null?Zr(E,!!y.multiple,_e,!1):ie!==!!y.multiple&&(y.defaultValue!=null?Zr(E,!!y.multiple,y.defaultValue,!0):Zr(E,!!y.multiple,y.multiple?[]:"",!1))}E[Ma]=y}catch(Ce){yt(i,i.return,Ce)}}break;case 6:if(rr(s,i),Sr(i),f&4){if(i.stateNode===null)throw Error(n(162));E=i.stateNode,y=i.memoizedProps;try{E.nodeValue=y}catch(Ce){yt(i,i.return,Ce)}}break;case 3:if(rr(s,i),Sr(i),f&4&&l!==null&&l.memoizedState.isDehydrated)try{Aa(s.containerInfo)}catch(Ce){yt(i,i.return,Ce)}break;case 4:rr(s,i),Sr(i);break;case 13:rr(s,i),Sr(i),E=i.child,E.flags&8192&&(y=E.memoizedState!==null,E.stateNode.isHidden=y,!y||E.alternate!==null&&E.alternate.memoizedState!==null||(Hp=_t())),f&4&&ix(i);break;case 22:if(se=l!==null&&l.memoizedState!==null,i.mode&1?(Jt=(G=Jt)||se,rr(s,i),Jt=G):rr(s,i),Sr(i),f&8192){if(G=i.memoizedState!==null,(i.stateNode.isHidden=G)&&!se&&(i.mode&1)!==0)for(Se=i,se=i.child;se!==null;){for(de=Se=se;Se!==null;){switch(ie=Se,_e=ie.child,ie.tag){case 0:case 11:case 14:case 15:qa(4,ie,ie.return);break;case 1:ps(ie,ie.return);var Ae=ie.stateNode;if(typeof Ae.componentWillUnmount=="function"){f=ie,l=ie.return;try{s=f,Ae.props=s.memoizedProps,Ae.state=s.memoizedState,Ae.componentWillUnmount()}catch(Ce){yt(f,l,Ce)}}break;case 5:ps(ie,ie.return);break;case 22:if(ie.memoizedState!==null){ux(de);continue}}_e!==null?(_e.return=ie,Se=_e):ux(de)}se=se.sibling}e:for(se=null,de=i;;){if(de.tag===5){if(se===null){se=de;try{E=de.stateNode,G?(y=E.style,typeof y.setProperty=="function"?y.setProperty("display","none","important"):y.display="none"):(I=de.stateNode,B=de.memoizedProps.style,_=B!=null&&B.hasOwnProperty("display")?B.display:null,I.style.display=Mn("display",_))}catch(Ce){yt(i,i.return,Ce)}}}else if(de.tag===6){if(se===null)try{de.stateNode.nodeValue=G?"":de.memoizedProps}catch(Ce){yt(i,i.return,Ce)}}else if((de.tag!==22&&de.tag!==23||de.memoizedState===null||de===i)&&de.child!==null){de.child.return=de,de=de.child;continue}if(de===i)break e;for(;de.sibling===null;){if(de.return===null||de.return===i)break e;se===de&&(se=null),de=de.return}se===de&&(se=null),de.sibling.return=de.return,de=de.sibling}}break;case 19:rr(s,i),Sr(i),f&4&&ix(i);break;case 21:break;default:rr(s,i),Sr(i)}}function Sr(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(tx(l)){var f=l;break e}l=l.return}throw Error(n(160))}switch(f.tag){case 5:var E=f.stateNode;f.flags&32&&(Qe(E,""),f.flags&=-33);var y=nx(i);Fp(i,y,E);break;case 3:case 4:var _=f.stateNode.containerInfo,I=nx(i);Mp(i,I,_);break;default:throw Error(n(161))}}catch(B){yt(i,i.return,B)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function iM(i,s,l){Se=i,sx(i)}function sx(i,s,l){for(var f=(i.mode&1)!==0;Se!==null;){var E=Se,y=E.child;if(E.tag===22&&f){var _=E.memoizedState!==null||hc;if(!_){var I=E.alternate,B=I!==null&&I.memoizedState!==null||Jt;I=hc;var G=Jt;if(hc=_,(Jt=B)&&!G)for(Se=E;Se!==null;)_=Se,B=_.child,_.tag===22&&_.memoizedState!==null?lx(E):B!==null?(B.return=_,Se=B):lx(E);for(;y!==null;)Se=y,sx(y),y=y.sibling;Se=E,hc=I,Jt=G}ax(i)}else(E.subtreeFlags&8772)!==0&&y!==null?(y.return=E,Se=y):ax(i)}}function ax(i){for(;Se!==null;){var s=Se;if((s.flags&8772)!==0){var l=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:Jt||pc(5,s);break;case 1:var f=s.stateNode;if(s.flags&4&&!Jt)if(l===null)f.componentDidMount();else{var E=s.elementType===s.type?l.memoizedProps:tr(s.type,l.memoizedProps);f.componentDidUpdate(E,l.memoizedState,f.__reactInternalSnapshotBeforeUpdate)}var y=s.updateQueue;y!==null&&u2(s,y,f);break;case 3:var _=s.updateQueue;if(_!==null){if(l=null,s.child!==null)switch(s.child.tag){case 5:l=s.child.stateNode;break;case 1:l=s.child.stateNode}u2(s,_,l)}break;case 5:var I=s.stateNode;if(l===null&&s.flags&4){l=I;var B=s.memoizedProps;switch(s.type){case"button":case"input":case"select":case"textarea":B.autoFocus&&l.focus();break;case"img":B.src&&(l.src=B.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(s.memoizedState===null){var G=s.alternate;if(G!==null){var se=G.memoizedState;if(se!==null){var de=se.dehydrated;de!==null&&Aa(de)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Jt||s.flags&512&&Dp(s)}catch(ie){yt(s,s.return,ie)}}if(s===i){Se=null;break}if(l=s.sibling,l!==null){l.return=s.return,Se=l;break}Se=s.return}}function ux(i){for(;Se!==null;){var s=Se;if(s===i){Se=null;break}var l=s.sibling;if(l!==null){l.return=s.return,Se=l;break}Se=s.return}}function lx(i){for(;Se!==null;){var s=Se;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{pc(4,s)}catch(B){yt(s,l,B)}break;case 1:var f=s.stateNode;if(typeof f.componentDidMount=="function"){var E=s.return;try{f.componentDidMount()}catch(B){yt(s,E,B)}}var y=s.return;try{Dp(s)}catch(B){yt(s,y,B)}break;case 5:var _=s.return;try{Dp(s)}catch(B){yt(s,_,B)}}}catch(B){yt(s,s.return,B)}if(s===i){Se=null;break}var I=s.sibling;if(I!==null){I.return=s.return,Se=I;break}Se=s.return}}var oM=Math.ceil,mc=F.ReactCurrentDispatcher,Bp=F.ReactCurrentOwner,zn=F.ReactCurrentBatchConfig,Xe=0,Bt=null,Ct=null,$t=0,Nn=0,ms=ui(0),It=0,Ga=null,eo=0,gc=0,Up=0,Ka=null,yn=null,Hp=0,gs=1/0,Br=null,Ec=!1,zp=null,pi=null,yc=!1,mi=null,Tc=0,Qa=0,jp=null,bc=-1,xc=0;function nn(){return(Xe&6)!==0?_t():bc!==-1?bc:bc=_t()}function gi(i){return(i.mode&1)===0?1:(Xe&2)!==0&&$t!==0?$t&-$t:j8.transition!==null?(xc===0&&(xc=nb()),xc):(i=nt,i!==0||(i=window.event,i=i===void 0?16:db(i.type)),i)}function ir(i,s,l,f){if(50<Qa)throw Qa=0,jp=null,Error(n(185));ba(i,l,f),((Xe&2)===0||i!==Bt)&&(i===Bt&&((Xe&2)===0&&(gc|=l),It===4&&Ei(i,$t)),Tn(i,f),l===1&&Xe===0&&(s.mode&1)===0&&(gs=_t()+500,Kl&&ci()))}function Tn(i,s){var l=i.callbackNode;j5(i,s);var f=Ol(i,i===Bt?$t:0);if(f===0)l!==null&&ZT(l),i.callbackNode=null,i.callbackPriority=0;else if(s=f&-f,i.callbackPriority!==s){if(l!=null&&ZT(l),s===1)i.tag===0?z8(dx.bind(null,i)):Qb(dx.bind(null,i)),F8(function(){(Xe&6)===0&&ci()}),l=null;else{switch(rb(f)){case 1:l=xh;break;case 4:l=eb;break;case 16:l=vl;break;case 536870912:l=tb;break;default:l=vl}l=Tx(l,cx.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function cx(i,s){if(bc=-1,xc=0,(Xe&6)!==0)throw Error(n(327));var l=i.callbackNode;if(Es()&&i.callbackNode!==l)return null;var f=Ol(i,i===Bt?$t:0);if(f===0)return null;if((f&30)!==0||(f&i.expiredLanes)!==0||s)s=_c(i,f);else{s=f;var E=Xe;Xe|=2;var y=hx();(Bt!==i||$t!==s)&&(Br=null,gs=_t()+500,no(i,s));do try{uM();break}catch(I){fx(i,I)}while(!0);sp(),mc.current=y,Xe=E,Ct!==null?s=0:(Bt=null,$t=0,s=It)}if(s!==0){if(s===2&&(E=_h(i),E!==0&&(f=E,s=$p(i,E))),s===1)throw l=Ga,no(i,0),Ei(i,f),Tn(i,_t()),l;if(s===6)Ei(i,f);else{if(E=i.current.alternate,(f&30)===0&&!sM(E)&&(s=_c(i,f),s===2&&(y=_h(i),y!==0&&(f=y,s=$p(i,y))),s===1))throw l=Ga,no(i,0),Ei(i,f),Tn(i,_t()),l;switch(i.finishedWork=E,i.finishedLanes=f,s){case 0:case 1:throw Error(n(345));case 2:ro(i,yn,Br);break;case 3:if(Ei(i,f),(f&130023424)===f&&(s=Hp+500-_t(),10<s)){if(Ol(i,0)!==0)break;if(E=i.suspendedLanes,(E&f)!==f){nn(),i.pingedLanes|=i.suspendedLanes&E;break}i.timeoutHandle=Kh(ro.bind(null,i,yn,Br),s);break}ro(i,yn,Br);break;case 4:if(Ei(i,f),(f&4194240)===f)break;for(s=i.eventTimes,E=-1;0<f;){var _=31-Jn(f);y=1<<_,_=s[_],_>E&&(E=_),f&=~y}if(f=E,f=_t()-f,f=(120>f?120:480>f?480:1080>f?1080:1920>f?1920:3e3>f?3e3:4320>f?4320:1960*oM(f/1960))-f,10<f){i.timeoutHandle=Kh(ro.bind(null,i,yn,Br),f);break}ro(i,yn,Br);break;case 5:ro(i,yn,Br);break;default:throw Error(n(329))}}}return Tn(i,_t()),i.callbackNode===l?cx.bind(null,i):null}function $p(i,s){var l=Ka;return i.current.memoizedState.isDehydrated&&(no(i,s).flags|=256),i=_c(i,s),i!==2&&(s=yn,yn=l,s!==null&&Vp(s)),i}function Vp(i){yn===null?yn=i:yn.push.apply(yn,i)}function sM(i){for(var s=i;;){if(s.flags&16384){var l=s.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var f=0;f<l.length;f++){var E=l[f],y=E.getSnapshot;E=E.value;try{if(!Zn(y(),E))return!1}catch(_){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 Ei(i,s){for(s&=~Up,s&=~gc,i.suspendedLanes|=s,i.pingedLanes&=~s,i=i.expirationTimes;0<s;){var l=31-Jn(s),f=1<<l;i[l]=-1,s&=~f}}function dx(i){if((Xe&6)!==0)throw Error(n(327));Es();var s=Ol(i,0);if((s&1)===0)return Tn(i,_t()),null;var l=_c(i,s);if(i.tag!==0&&l===2){var f=_h(i);f!==0&&(s=f,l=$p(i,f))}if(l===1)throw l=Ga,no(i,0),Ei(i,s),Tn(i,_t()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,ro(i,yn,Br),Tn(i,_t()),null}function Yp(i,s){var l=Xe;Xe|=1;try{return i(s)}finally{Xe=l,Xe===0&&(gs=_t()+500,Kl&&ci())}}function to(i){mi!==null&&mi.tag===0&&(Xe&6)===0&&Es();var s=Xe;Xe|=1;var l=zn.transition,f=nt;try{if(zn.transition=null,nt=1,i)return i()}finally{nt=f,zn.transition=l,Xe=s,(Xe&6)===0&&ci()}}function Wp(){Nn=ms.current,ct(ms)}function no(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,M8(l)),Ct!==null)for(l=Ct.return;l!==null;){var f=l;switch(tp(f),f.tag){case 1:f=f.type.childContextTypes,f!=null&&ql();break;case 3:fs(),ct(mn),ct(Kt),pp();break;case 5:fp(f);break;case 4:fs();break;case 13:ct(mt);break;case 19:ct(mt);break;case 10:ap(f.type._context);break;case 22:case 23:Wp()}l=l.return}if(Bt=i,Ct=i=yi(i.current,null),$t=Nn=s,It=0,Ga=null,Up=gc=eo=0,yn=Ka=null,Xi!==null){for(s=0;s<Xi.length;s++)if(l=Xi[s],f=l.interleaved,f!==null){l.interleaved=null;var E=f.next,y=l.pending;if(y!==null){var _=y.next;y.next=E,f.next=_}l.pending=f}Xi=null}return i}function fx(i,s){do{var l=Ct;try{if(sp(),oc.current=lc,sc){for(var f=gt.memoizedState;f!==null;){var E=f.queue;E!==null&&(E.pending=null),f=f.next}sc=!1}if(Zi=0,Ft=Ot=gt=null,ja=!1,$a=0,Bp.current=null,l===null||l.return===null){It=1,Ga=s,Ct=null;break}e:{var y=i,_=l.return,I=l,B=s;if(s=$t,I.flags|=32768,B!==null&&typeof B=="object"&&typeof B.then=="function"){var G=B,se=I,de=se.tag;if((se.mode&1)===0&&(de===0||de===11||de===15)){var ie=se.alternate;ie?(se.updateQueue=ie.updateQueue,se.memoizedState=ie.memoizedState,se.lanes=ie.lanes):(se.updateQueue=null,se.memoizedState=null)}var _e=F2(_);if(_e!==null){_e.flags&=-257,B2(_e,_,I,y,s),_e.mode&1&&M2(y,G,s),s=_e,B=G;var Ae=s.updateQueue;if(Ae===null){var Ce=new Set;Ce.add(B),s.updateQueue=Ce}else Ae.add(B);break e}else{if((s&1)===0){M2(y,G,s),qp();break e}B=Error(n(426))}}else if(pt&&I.mode&1){var St=F2(_);if(St!==null){(St.flags&65536)===0&&(St.flags|=256),B2(St,_,I,y,s),ip(hs(B,I));break e}}y=B=hs(B,I),It!==4&&(It=2),Ka===null?Ka=[y]:Ka.push(y),y=_;do{switch(y.tag){case 3:y.flags|=65536,s&=-s,y.lanes|=s;var V=L2(y,B,s);a2(y,V);break e;case 1:I=B;var H=y.type,W=y.stateNode;if((y.flags&128)===0&&(typeof H.getDerivedStateFromError=="function"||W!==null&&typeof W.componentDidCatch=="function"&&(pi===null||!pi.has(W)))){y.flags|=65536,s&=-s,y.lanes|=s;var Ee=D2(y,I,s);a2(y,Ee);break e}}y=y.return}while(y!==null)}mx(l)}catch(ke){s=ke,Ct===l&&l!==null&&(Ct=l=l.return);continue}break}while(!0)}function hx(){var i=mc.current;return mc.current=lc,i===null?lc:i}function qp(){(It===0||It===3||It===2)&&(It=4),Bt===null||(eo&268435455)===0&&(gc&268435455)===0||Ei(Bt,$t)}function _c(i,s){var l=Xe;Xe|=2;var f=hx();(Bt!==i||$t!==s)&&(Br=null,no(i,s));do try{aM();break}catch(E){fx(i,E)}while(!0);if(sp(),Xe=l,mc.current=f,Ct!==null)throw Error(n(261));return Bt=null,$t=0,It}function aM(){for(;Ct!==null;)px(Ct)}function uM(){for(;Ct!==null&&!P5();)px(Ct)}function px(i){var s=yx(i.alternate,i,Nn);i.memoizedProps=i.pendingProps,s===null?mx(i):Ct=s,Bp.current=null}function mx(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=eM(l,s,Nn),l!==null){Ct=l;return}}else{if(l=tM(l,s),l!==null){l.flags&=32767,Ct=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{It=6,Ct=null;return}}if(s=s.sibling,s!==null){Ct=s;return}Ct=s=i}while(s!==null);It===0&&(It=5)}function ro(i,s,l){var f=nt,E=zn.transition;try{zn.transition=null,nt=1,lM(i,s,l,f)}finally{zn.transition=E,nt=f}return null}function lM(i,s,l,f){do Es();while(mi!==null);if((Xe&6)!==0)throw Error(n(327));l=i.finishedWork;var E=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($5(i,y),i===Bt&&(Ct=Bt=null,$t=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||yc||(yc=!0,Tx(vl,function(){return Es(),null})),y=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||y){y=zn.transition,zn.transition=null;var _=nt;nt=1;var I=Xe;Xe|=4,Bp.current=null,rM(i,l),ox(l,i),N8(qh),Pl=!!Wh,qh=Wh=null,i.current=l,iM(l),L5(),Xe=I,nt=_,zn.transition=y}else i.current=l;if(yc&&(yc=!1,mi=i,Tc=E),y=i.pendingLanes,y===0&&(pi=null),F5(l.stateNode),Tn(i,_t()),s!==null)for(f=i.onRecoverableError,l=0;l<s.length;l++)E=s[l],f(E.value,{componentStack:E.stack,digest:E.digest});if(Ec)throw Ec=!1,i=zp,zp=null,i;return(Tc&1)!==0&&i.tag!==0&&Es(),y=i.pendingLanes,(y&1)!==0?i===jp?Qa++:(Qa=0,jp=i):Qa=0,ci(),null}function Es(){if(mi!==null){var i=rb(Tc),s=zn.transition,l=nt;try{if(zn.transition=null,nt=16>i?16:i,mi===null)var f=!1;else{if(i=mi,mi=null,Tc=0,(Xe&6)!==0)throw Error(n(331));var E=Xe;for(Xe|=4,Se=i.current;Se!==null;){var y=Se,_=y.child;if((Se.flags&16)!==0){var I=y.deletions;if(I!==null){for(var B=0;B<I.length;B++){var G=I[B];for(Se=G;Se!==null;){var se=Se;switch(se.tag){case 0:case 11:case 15:qa(8,se,y)}var de=se.child;if(de!==null)de.return=se,Se=de;else for(;Se!==null;){se=Se;var ie=se.sibling,_e=se.return;if(ex(se),se===G){Se=null;break}if(ie!==null){ie.return=_e,Se=ie;break}Se=_e}}}var Ae=y.alternate;if(Ae!==null){var Ce=Ae.child;if(Ce!==null){Ae.child=null;do{var St=Ce.sibling;Ce.sibling=null,Ce=St}while(Ce!==null)}}Se=y}}if((y.subtreeFlags&2064)!==0&&_!==null)_.return=y,Se=_;else e:for(;Se!==null;){if(y=Se,(y.flags&2048)!==0)switch(y.tag){case 0:case 11:case 15:qa(9,y,y.return)}var V=y.sibling;if(V!==null){V.return=y.return,Se=V;break e}Se=y.return}}var H=i.current;for(Se=H;Se!==null;){_=Se;var W=_.child;if((_.subtreeFlags&2064)!==0&&W!==null)W.return=_,Se=W;else e:for(_=H;Se!==null;){if(I=Se,(I.flags&2048)!==0)try{switch(I.tag){case 0:case 11:case 15:pc(9,I)}}catch(ke){yt(I,I.return,ke)}if(I===_){Se=null;break e}var Ee=I.sibling;if(Ee!==null){Ee.return=I.return,Se=Ee;break e}Se=I.return}}if(Xe=E,ci(),Tr&&typeof Tr.onPostCommitFiberRoot=="function")try{Tr.onPostCommitFiberRoot(Cl,i)}catch(ke){}f=!0}return f}finally{nt=l,zn.transition=s}}return!1}function gx(i,s,l){s=hs(l,s),s=L2(i,s,1),i=fi(i,s,1),s=nn(),i!==null&&(ba(i,1,s),Tn(i,s))}function yt(i,s,l){if(i.tag===3)gx(i,i,l);else for(;s!==null;){if(s.tag===3){gx(s,i,l);break}else if(s.tag===1){var f=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof f.componentDidCatch=="function"&&(pi===null||!pi.has(f))){i=hs(l,i),i=D2(s,i,1),s=fi(s,i,1),i=nn(),s!==null&&(ba(s,1,i),Tn(s,i));break}}s=s.return}}function cM(i,s,l){var f=i.pingCache;f!==null&&f.delete(s),s=nn(),i.pingedLanes|=i.suspendedLanes&l,Bt===i&&($t&l)===l&&(It===4||It===3&&($t&130023424)===$t&&500>_t()-Hp?no(i,0):Up|=l),Tn(i,s)}function Ex(i,s){s===0&&((i.mode&1)===0?s=1:(s=Nl,Nl<<=1,(Nl&130023424)===0&&(Nl=4194304)));var l=nn();i=Dr(i,s),i!==null&&(ba(i,s,l),Tn(i,l))}function dM(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),Ex(i,l)}function fM(i,s){var l=0;switch(i.tag){case 13:var f=i.stateNode,E=i.memoizedState;E!==null&&(l=E.retryLane);break;case 19:f=i.stateNode;break;default:throw Error(n(314))}f!==null&&f.delete(s),Ex(i,l)}var yx;yx=function(i,s,l){if(i!==null)if(i.memoizedProps!==s.pendingProps||mn.current)En=!0;else{if((i.lanes&l)===0&&(s.flags&128)===0)return En=!1,Z8(i,s,l);En=(i.flags&131072)!==0}else En=!1,pt&&(s.flags&1048576)!==0&&Xb(s,Xl,s.index);switch(s.lanes=0,s.tag){case 2:var f=s.type;fc(i,s),i=s.pendingProps;var E=os(s,Kt.current);ds(s,l),E=Ep(null,s,f,i,E,l);var y=yp();return s.flags|=1,typeof E=="object"&&E!==null&&typeof E.render=="function"&&E.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,gn(f)?(y=!0,Gl(s)):y=!1,s.memoizedState=E.state!==null&&E.state!==void 0?E.state:null,cp(s),E.updater=cc,s.stateNode=E,E._reactInternals=s,wp(s,f,i,l),s=kp(null,s,f,!0,y,l)):(s.tag=0,pt&&y&&ep(s),tn(null,s,E,l),s=s.child),s;case 16:f=s.elementType;e:{switch(fc(i,s),i=s.pendingProps,E=f._init,f=E(f._payload),s.type=f,E=s.tag=pM(f),i=tr(f,i),E){case 0:s=Cp(null,s,f,i,l);break e;case 1:s=V2(null,s,f,i,l);break e;case 11:s=U2(null,s,f,i,l);break e;case 14:s=H2(null,s,f,tr(f.type,i),l);break e}throw Error(n(306,f,""))}return s;case 0:return f=s.type,E=s.pendingProps,E=s.elementType===f?E:tr(f,E),Cp(i,s,f,E,l);case 1:return f=s.type,E=s.pendingProps,E=s.elementType===f?E:tr(f,E),V2(i,s,f,E,l);case 3:e:{if(Y2(s),i===null)throw Error(n(387));f=s.pendingProps,y=s.memoizedState,E=y.element,s2(i,s),rc(s,f,null,l);var _=s.memoizedState;if(f=_.element,y.isDehydrated)if(y={element:f,isDehydrated:!1,cache:_.cache,pendingSuspenseBoundaries:_.pendingSuspenseBoundaries,transitions:_.transitions},s.updateQueue.baseState=y,s.memoizedState=y,s.flags&256){E=hs(Error(n(423)),s),s=W2(i,s,f,l,E);break e}else if(f!==E){E=hs(Error(n(424)),s),s=W2(i,s,f,l,E);break e}else for(kn=ai(s.stateNode.containerInfo.firstChild),Cn=s,pt=!0,er=null,l=i2(s,null,f,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(us(),f===E){s=Fr(i,s,l);break e}tn(i,s,f,l)}s=s.child}return s;case 5:return l2(s),i===null&&rp(s),f=s.type,E=s.pendingProps,y=i!==null?i.memoizedProps:null,_=E.children,Gh(f,E)?_=null:y!==null&&Gh(f,y)&&(s.flags|=32),$2(i,s),tn(i,s,_,l),s.child;case 6:return i===null&&rp(s),null;case 13:return q2(i,s,l);case 4:return dp(s,s.stateNode.containerInfo),f=s.pendingProps,i===null?s.child=ls(s,null,f,l):tn(i,s,f,l),s.child;case 11:return f=s.type,E=s.pendingProps,E=s.elementType===f?E:tr(f,E),U2(i,s,f,E,l);case 7:return tn(i,s,s.pendingProps,l),s.child;case 8:return tn(i,s,s.pendingProps.children,l),s.child;case 12:return tn(i,s,s.pendingProps.children,l),s.child;case 10:e:{if(f=s.type._context,E=s.pendingProps,y=s.memoizedProps,_=E.value,at(ec,f._currentValue),f._currentValue=_,y!==null)if(Zn(y.value,_)){if(y.children===E.children&&!mn.current){s=Fr(i,s,l);break e}}else for(y=s.child,y!==null&&(y.return=s);y!==null;){var I=y.dependencies;if(I!==null){_=y.child;for(var B=I.firstContext;B!==null;){if(B.context===f){if(y.tag===1){B=Mr(-1,l&-l),B.tag=2;var G=y.updateQueue;if(G!==null){G=G.shared;var se=G.pending;se===null?B.next=B:(B.next=se.next,se.next=B),G.pending=B}}y.lanes|=l,B=y.alternate,B!==null&&(B.lanes|=l),up(y.return,l,s),I.lanes|=l;break}B=B.next}}else if(y.tag===10)_=y.type===s.type?null:y.child;else if(y.tag===18){if(_=y.return,_===null)throw Error(n(341));_.lanes|=l,I=_.alternate,I!==null&&(I.lanes|=l),up(_,l,s),_=y.sibling}else _=y.child;if(_!==null)_.return=y;else for(_=y;_!==null;){if(_===s){_=null;break}if(y=_.sibling,y!==null){y.return=_.return,_=y;break}_=_.return}y=_}tn(i,s,E.children,l),s=s.child}return s;case 9:return E=s.type,f=s.pendingProps.children,ds(s,l),E=Un(E),f=f(E),s.flags|=1,tn(i,s,f,l),s.child;case 14:return f=s.type,E=tr(f,s.pendingProps),E=tr(f.type,E),H2(i,s,f,E,l);case 15:return z2(i,s,s.type,s.pendingProps,l);case 17:return f=s.type,E=s.pendingProps,E=s.elementType===f?E:tr(f,E),fc(i,s),s.tag=1,gn(f)?(i=!0,Gl(s)):i=!1,ds(s,l),R2(s,f,E),wp(s,f,E,l),kp(null,s,f,!0,i,l);case 19:return K2(i,s,l);case 22:return j2(i,s,l)}throw Error(n(156,s.tag))};function Tx(i,s){return JT(i,s)}function hM(i,s,l,f){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=f,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function jn(i,s,l,f){return new hM(i,s,l,f)}function Gp(i){return i=i.prototype,!(!i||!i.isReactComponent)}function pM(i){if(typeof i=="function")return Gp(i)?1:0;if(i!=null){if(i=i.$$typeof,i===he)return 11;if(i===Te)return 14}return 2}function yi(i,s){var l=i.alternate;return l===null?(l=jn(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 Sc(i,s,l,f,E,y){var _=2;if(f=i,typeof i=="function")Gp(i)&&(_=1);else if(typeof i=="string")_=5;else e:switch(i){case q:return io(l.children,E,y,s);case ce:_=8,E|=8;break;case be:return i=jn(12,l,s,E|2),i.elementType=be,i.lanes=y,i;case ge:return i=jn(13,l,s,E),i.elementType=ge,i.lanes=y,i;case ue:return i=jn(19,l,s,E),i.elementType=ue,i.lanes=y,i;case fe:return wc(l,E,y,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case j:_=10;break e;case ae:_=9;break e;case he:_=11;break e;case Te:_=14;break e;case Ne:_=16,f=null;break e}throw Error(n(130,i==null?i:typeof i,""))}return s=jn(_,l,s,E),s.elementType=i,s.type=f,s.lanes=y,s}function io(i,s,l,f){return i=jn(7,i,f,s),i.lanes=l,i}function wc(i,s,l,f){return i=jn(22,i,f,s),i.elementType=fe,i.lanes=l,i.stateNode={isHidden:!1},i}function Kp(i,s,l){return i=jn(6,i,null,s),i.lanes=l,i}function Qp(i,s,l){return s=jn(4,i.children!==null?i.children:[],i.key,s),s.lanes=l,s.stateNode={containerInfo:i.containerInfo,pendingChildren:null,implementation:i.implementation},s}function mM(i,s,l,f,E){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=Sh(0),this.expirationTimes=Sh(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Sh(0),this.identifierPrefix=f,this.onRecoverableError=E,this.mutableSourceEagerHydrationData=null}function Xp(i,s,l,f,E,y,_,I,B){return i=new mM(i,s,l,I,B),s===1?(s=1,y===!0&&(s|=8)):s=0,y=jn(3,null,null,s),i.current=y,y.stateNode=i,y.memoizedState={element:f,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},cp(y),i}function gM(i,s,l){var f=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:D,key:f==null?null:""+f,children:i,containerInfo:s,implementation:l}}function bx(i){if(!i)return li;i=i._reactInternals;e:{if(Wi(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(gn(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(gn(l))return Gb(i,l,s)}return s}function xx(i,s,l,f,E,y,_,I,B){return i=Xp(l,f,!0,i,E,y,_,I,B),i.context=bx(null),l=i.current,f=nn(),E=gi(l),y=Mr(f,E),y.callback=s!=null?s:null,fi(l,y,E),i.current.lanes=E,ba(i,E,f),Tn(i,f),i}function Ac(i,s,l,f){var E=s.current,y=nn(),_=gi(E);return l=bx(l),s.context===null?s.context=l:s.pendingContext=l,s=Mr(y,_),s.payload={element:i},f=f===void 0?null:f,f!==null&&(s.callback=f),i=fi(E,s,_),i!==null&&(ir(i,E,_,y),nc(i,E,_)),_}function vc(i){return i=i.current,i.child?(i.child.tag===5,i.child.stateNode):null}function _x(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function Jp(i,s){_x(i,s),(i=i.alternate)&&_x(i,s)}function EM(){return null}var Sx=typeof reportError=="function"?reportError:function(i){console.error(i)};function Zp(i){this._internalRoot=i}Cc.prototype.render=Zp.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Ac(i,s,null,null)},Cc.prototype.unmount=Zp.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;to(function(){Ac(null,i,null,null)}),s[Ir]=null}};function Cc(i){this._internalRoot=i}Cc.prototype.unstable_scheduleHydration=function(i){if(i){var s=sb();i={blockedOn:null,target:i,priority:s};for(var l=0;l<ii.length&&s!==0&&s<ii[l].priority;l++);ii.splice(l,0,i),l===0&&lb(i)}};function em(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function kc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function wx(){}function yM(i,s,l,f,E){if(E){if(typeof f=="function"){var y=f;f=function(){var G=vc(_);y.call(G)}}var _=xx(s,f,i,0,null,!1,!1,"",wx);return i._reactRootContainer=_,i[Ir]=_.current,La(i.nodeType===8?i.parentNode:i),to(),_}for(;E=i.lastChild;)i.removeChild(E);if(typeof f=="function"){var I=f;f=function(){var G=vc(B);I.call(G)}}var B=Xp(i,0,!1,null,null,!1,!1,"",wx);return i._reactRootContainer=B,i[Ir]=B.current,La(i.nodeType===8?i.parentNode:i),to(function(){Ac(s,B,l,f)}),B}function Nc(i,s,l,f,E){var y=l._reactRootContainer;if(y){var _=y;if(typeof E=="function"){var I=E;E=function(){var B=vc(_);I.call(B)}}Ac(s,_,i,E)}else _=yM(l,s,i,E,f);return vc(_)}ib=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=Ta(s.pendingLanes);l!==0&&(wh(s,l|1),Tn(s,_t()),(Xe&6)===0&&(gs=_t()+500,ci()))}break;case 13:to(function(){var f=Dr(i,1);if(f!==null){var E=nn();ir(f,i,1,E)}}),Jp(i,1)}},Ah=function(i){if(i.tag===13){var s=Dr(i,134217728);if(s!==null){var l=nn();ir(s,i,134217728,l)}Jp(i,134217728)}},ob=function(i){if(i.tag===13){var s=gi(i),l=Dr(i,s);if(l!==null){var f=nn();ir(l,i,s,f)}Jp(i,s)}},sb=function(){return nt},ab=function(i,s){var l=nt;try{return nt=i,s()}finally{nt=l}},Eh=function(i,s,l){switch(s){case"input":if(Wo(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 f=l[s];if(f!==i&&f.form===i.form){var E=Wl(f);if(!E)throw Error(n(90));Vi(f),Wo(f,E)}}}break;case"textarea":_l(i,l);break;case"select":s=l.value,s!=null&&Zr(i,!!l.multiple,s,!1)}},YT=Yp,WT=to;var TM={usingClientEntryPoint:!1,Events:[Fa,rs,Wl,$T,VT,Yp]},Xa={findFiberByHostInstance:qi,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},bM={bundleType:Xa.bundleType,version:Xa.version,rendererPackageName:Xa.rendererPackageName,rendererConfig:Xa.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:F.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=QT(i),i===null?null:i.stateNode},findFiberByHostInstance:Xa.findFiberByHostInstance||EM,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 Oc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Oc.isDisabled&&Oc.supportsFiber)try{Cl=Oc.inject(bM),Tr=Oc}catch(i){}}return un.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=TM,un.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!em(s))throw Error(n(200));return gM(i,s,null,l)},un.createRoot=function(i,s){if(!em(i))throw Error(n(299));var l=!1,f="",E=Sx;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(f=s.identifierPrefix),s.onRecoverableError!==void 0&&(E=s.onRecoverableError)),s=Xp(i,1,!1,null,null,l,!1,f,E),i[Ir]=s.current,La(i.nodeType===8?i.parentNode:i),new Zp(s)},un.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=QT(s),i=i===null?null:i.stateNode,i},un.flushSync=function(i){return to(i)},un.hydrate=function(i,s,l){if(!kc(s))throw Error(n(200));return Nc(null,i,s,!0,l)},un.hydrateRoot=function(i,s,l){if(!em(i))throw Error(n(405));var f=l!=null&&l.hydratedSources||null,E=!1,y="",_=Sx;if(l!=null&&(l.unstable_strictMode===!0&&(E=!0),l.identifierPrefix!==void 0&&(y=l.identifierPrefix),l.onRecoverableError!==void 0&&(_=l.onRecoverableError)),s=xx(s,null,i,1,l!=null?l:null,E,!1,y,_),i[Ir]=s.current,La(i),f)for(i=0;i<f.length;i++)l=f[i],E=l._getVersion,E=E(l._source),s.mutableSourceEagerHydrationData==null?s.mutableSourceEagerHydrationData=[l,E]:s.mutableSourceEagerHydrationData.push(l,E);return new Cc(s)},un.render=function(i,s,l){if(!kc(s))throw Error(n(200));return Nc(null,i,s,!1,l)},un.unmountComponentAtNode=function(i){if(!kc(i))throw Error(n(40));return i._reactRootContainer?(to(function(){Nc(null,null,i,!1,function(){i._reactRootContainer=null,i[Ir]=null})}),!0):!1},un.unstable_batchedUpdates=Yp,un.unstable_renderSubtreeIntoContainer=function(i,s,l,f){if(!kc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Nc(i,s,l,!1,f)},un.version="18.3.1-next-f1338f8080-20240426",un}var m0;function g0(){if(m0)return hd.exports;m0=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(),hd.exports=Fw(),hd.exports}var ks=g0();function E0(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=E0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function re(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=E0(e))&&(r&&(r+=" "),r+=t);return r}const jr=({className:e,iconUrl:t,icon:n,type:r="button",ariaLabel:o,title:a,disabled:u=!1,onClick:c})=>!n&&!t?null:P.jsx("button",{className:re(e,`${J}-icon-button`),type:r,"aria-label":o,title:a,onClick:c,disabled:u,children:t?P.jsx("img",{className:re(`${J}-icon-image`),src:t,alt:o,loading:"lazy"}):n}),Bw="data:image/svg+xml,%3csvg%20width='140'%20height='137'%20viewBox='0%200%20140%20137'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M140%2034.5C140%2040.8513%20135.075%2046%20129%2046C122.925%2046%20118%2040.8513%20118%2034.5C118%2028.1487%20122.925%2023%20129%2023C135.075%2023%20140%2028.1487%20140%2034.5Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M85%2011.3028C85%205.06042%2090.1487%200%2096.5%200C102.851%200%20108%205.06042%20108%2011.3028V21.6972C108%2027.9396%20102.851%2033%2096.5%2033C90.1487%2033%2085%2027.9396%2085%2021.6972V11.3028Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M41.3868%2030.0986C36.9601%2025.6719%2036.9601%2018.4948%2041.3868%2014.0682C45.8134%209.64151%2052.9905%209.6415%2057.4172%2014.0682L71.3628%2028.0138C75.7894%2032.4404%2075.7894%2039.6175%2071.3628%2044.0442C66.9361%2048.4708%2059.759%2048.4708%2055.3324%2044.0442L41.3868%2030.0986Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M140%20101C140%2094.9249%20135.075%2090%20129%2090C122.925%2090%20118%2094.9249%20118%20101C118%20107.075%20122.925%20112%20129%20112C135.075%20112%20140%20107.075%20140%20101Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M85%20125.697C85%20131.94%2090.1487%20137%2096.5%20137C102.851%20137%20108%20131.94%20108%20125.697V115.303C108%20109.06%20102.851%20104%2096.5%20104C90.1487%20104%2085%20109.06%2085%20115.303V125.697Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M41.3868%20106.932C36.9601%20111.359%2036.9601%20118.536%2041.3868%20122.963C45.8134%20127.389%2052.9905%20127.39%2057.4172%20122.963L71.3628%20109.017C75.7894%20104.591%2075.7894%2097.4135%2071.3628%2092.9868C66.9361%2088.5602%2059.759%2088.5602%2055.3324%2092.9868L41.3868%20106.932Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M11.259%2080C5.04084%2080%200%2074.8513%200%2068.5C0%2062.1487%205.04084%2057%2011.259%2057H49.741C55.9592%2057%2061%2062.1487%2061%2068.5C61%2074.8513%2055.9592%2080%2049.741%2080H11.259Z'%20fill='%23F3F2EB'/%3e%3c/svg%3e",Uw=()=>{const{globalClassName:e,headerConfig:t,themeVariables:n}=an(),r=()=>{yu(!1),vi(!0)};return ks.createPortal(P.jsx("div",{className:re(e,`${J}-minimized-container`),style:n,children:P.jsx(jr,{className:re(e,`${J}-minimized-button`),ariaLabel:"Open Copilot",icon:P.jsx("img",{src:(t==null?void 0:t.logoUrl)||Bw,alt:"Copilot",className:re(e,`${J}-minimized-icon-img`)}),onClick:r})}),document.body)};var y0={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},T0=bi.createContext&&bi.createContext(y0),Hw=["attr","size","title"];function zw(e,t){if(e==null)return{};var n=jw(e,t),r,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)r=a[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function jw(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 bu(){return bu=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},bu.apply(this,arguments)}function b0(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 xu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?b0(Object(n),!0).forEach(function(r){$w(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $w(e,t,n){return t=Vw(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Vw(e){var t=Yw(e,"string");return typeof t=="symbol"?t:t+""}function Yw(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 x0(e){return e&&e.map((t,n)=>bi.createElement(t.tag,xu({key:n},t.attr),x0(t.child)))}function ln(e){return t=>bi.createElement(Ww,bu({attr:xu({},e.attr)},t),x0(e.child))}function Ww(e){var t=n=>{var{attr:r,size:o,title:a}=e,u=zw(e,Hw),c=o||n.size||"1em",d;return n.className&&(d=n.className),e.className&&(d=(d?d+" ":"")+e.className),bi.createElement("svg",bu({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,u,{className:d,style:xu(xu({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&bi.createElement("title",null,a),e.children)};return T0!==void 0?bi.createElement(T0.Consumer,null,n=>t(n)):t(y0)}function qw(e){return ln({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3.5 8a5.5 5.5 0 1 1 8.596 4.547 9.005 9.005 0 0 1 5.9 8.18.751.751 0 0 1-1.5.045 7.5 7.5 0 0 0-14.993 0 .75.75 0 0 1-1.499-.044 9.005 9.005 0 0 1 5.9-8.181A5.496 5.496 0 0 1 3.5 8ZM9 4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Zm8.29 4c-.148 0-.292.01-.434.03a.75.75 0 1 1-.212-1.484 4.53 4.53 0 0 1 3.38 8.097 6.69 6.69 0 0 1 3.956 6.107.75.75 0 0 1-1.5 0 5.193 5.193 0 0 0-3.696-4.972l-.534-.16v-1.676l.41-.209A3.03 3.03 0 0 0 17.29 8Z"},child:[]}]})(e)}function Ci(){const e=ee.useContext(a0);if(!e)throw new Error("useMessaging must be used within a MessagingProvider");return e}const _0=e=>({[`${Hr}-header-background-color`]:(e==null?void 0:e.headerBackgroundColor)||"transparent"});function S0(e){return ln({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M6 19h12v2H6z"},child:[]}]})(e)}function w0(e){return ln({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 Gw(e){return ln({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 Kw(e){return ln({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 Qw(e){return ln({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 A0=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>P.jsx("button",{className:re(`${J}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),Xw=({searchConfig:e,globalClassName:t})=>{const n=e.buttonIconUrl;return n?P.jsx("img",{className:re(`${J}-search-button-icon-image`,t),src:n,alt:"",loading:"lazy"}):P.jsx(w0,{size:"16px"})},Jw=({className:e,searchConfig:t,globalClassName:n,componentType:r,isLoading:o})=>{if((t==null?void 0:t.buttonType)==="icon")return P.jsx(jr,{className:re(e,n,`cim-${r}-component`,`${J}-search-button-icon`),type:"submit",disabled:o,ariaLabel:(t==null?void 0:t.buttonAriaLabel)||(t==null?void 0:t.buttonLabel)||"Search Copilot",icon:t!=null&&t.buttonIconUrl?null:P.jsx(w0,{size:"16px"}),iconUrl:t==null?void 0:t.buttonIconUrl});const a=(t==null?void 0:t.buttonType)==="icon-text";return P.jsxs(A0,{className:re(e,n,`cim-${r}-component`,`${J}-search-button`),type:"submit","aria-label":(t==null?void 0:t.buttonAriaLabel)||"",disabled:o,children:[a&&P.jsx(Xw,{globalClassName:n,searchConfig:t}),(t==null?void 0:t.buttonLabel)||"Search"]})};function XM(){}function JM(){}function v0(e){const t=[],n=String(e||"");let r=n.indexOf(","),o=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const u=n.slice(o,r).trim();(u||!a)&&t.push(u),o=r+1,r=n.indexOf(",",o)}return t}function C0(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const Zw=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,eA=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,tA={};function k0(e,t){return(tA.jsx?eA:Zw).test(e)}const nA=/[ \t\n\f\r]/g;function rA(e){return typeof e=="object"?e.type==="text"?N0(e.value):!1:N0(e)}function N0(e){return e.replace(nA,"")===""}let Ns=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Ns.prototype.normal={},Ns.prototype.property={},Ns.prototype.space=void 0;function O0(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Ns(n,r,t)}function Os(e){return e.toLowerCase()}let cn=class{constructor(t,n){this.attribute=n,this.property=t}};cn.prototype.attribute="",cn.prototype.booleanish=!1,cn.prototype.boolean=!1,cn.prototype.commaOrSpaceSeparated=!1,cn.prototype.commaSeparated=!1,cn.prototype.defined=!1,cn.prototype.mustUseProperty=!1,cn.prototype.number=!1,cn.prototype.overloadedBoolean=!1,cn.prototype.property="",cn.prototype.spaceSeparated=!1,cn.prototype.space=void 0;let iA=0;const je=ki(),At=ki(),gd=ki(),pe=ki(),ot=ki(),ho=ki(),bn=ki();function ki(){return Ja(2,++iA)}const Ed=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:At,commaOrSpaceSeparated:bn,commaSeparated:ho,number:pe,overloadedBoolean:gd,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),yd=Object.keys(Ed);let Td=class extends cn{constructor(t,n,r,o){let a=-1;if(super(t,n),I0(this,"space",o),typeof r=="number")for(;++a<yd.length;){const u=yd[a];I0(this,yd[a],(r&Ed[u])===Ed[u])}}};Td.prototype.defined=!0;function I0(e,t,n){n&&(e[t]=n)}function po(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const a=new Td(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Os(r)]=r,n[Os(a.attribute)]=r}return new Ns(t,n,e.space)}const R0=po({properties:{ariaActiveDescendant:null,ariaAtomic:At,ariaAutoComplete:null,ariaBusy:At,ariaChecked:At,ariaColCount:pe,ariaColIndex:pe,ariaColSpan:pe,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:At,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:At,ariaFlowTo:ot,ariaGrabbed:At,ariaHasPopup:null,ariaHidden:At,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:pe,ariaLive:null,ariaModal:At,ariaMultiLine:At,ariaMultiSelectable:At,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:pe,ariaPressed:At,ariaReadOnly:At,ariaRelevant:null,ariaRequired:At,ariaRoleDescription:ot,ariaRowCount:pe,ariaRowIndex:pe,ariaRowSpan:pe,ariaSelected:At,ariaSetSize:pe,ariaSort:null,ariaValueMax:pe,ariaValueMin:pe,ariaValueNow:pe,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function P0(e,t){return t in e?e[t]:t}function L0(e,t){return P0(e,t.toLowerCase())}const oA=po({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:ho,acceptCharset:ot,accessKey:ot,action:null,allow:null,allowFullScreen:je,allowPaymentRequest:je,allowUserMedia:je,alt:null,as:null,async:je,autoCapitalize:null,autoComplete:ot,autoFocus:je,autoPlay:je,blocking:ot,capture:null,charSet:null,checked:je,cite:null,className:ot,cols:pe,colSpan:null,content:null,contentEditable:At,controls:je,controlsList:ot,coords:pe|ho,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:gd,draggable:At,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:ot,height:pe,hidden:gd,high:pe,href:null,hrefLang:null,htmlFor:ot,httpEquiv:ot,id:null,imageSizes:null,imageSrcSet:null,inert:je,inputMode:null,integrity:null,is:null,isMap:je,itemId:null,itemProp:ot,itemRef:ot,itemScope:je,itemType:ot,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:ot,placeholder:null,playsInline:je,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:je,referrerPolicy:null,rel:ot,required:je,reversed:je,rows:pe,rowSpan:pe,sandbox:ot,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:At,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:At,width:pe,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ot,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:At,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},space:"html",transform:L0}),sA=po({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:bn,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:ot,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:ho,g2:ho,glyphName:ho,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:bn,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:ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:pe,pointsAtY:pe,pointsAtZ:pe,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:bn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:bn,rev:bn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:bn,requiredFeatures:bn,requiredFonts:bn,requiredFormats:bn,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:bn,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:bn,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:bn,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},space:"svg",transform:P0}),D0=po({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()}}),M0=po({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:L0}),F0=po({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),aA={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"},uA=/[A-Z]/g,B0=/-[a-z]/g,lA=/^data[-\w.:]+$/i;function bd(e,t){const n=Os(t);let r=t,o=cn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&lA.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(B0,dA);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!B0.test(a)){let u=a.replace(uA,cA);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Td}return new o(r,t)}function cA(e){return"-"+e.toLowerCase()}function dA(e){return e.charAt(1).toUpperCase()}const _u=O0([R0,oA,D0,M0,F0],"html"),mo=O0([R0,sA,D0,M0,F0],"svg");function U0(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function H0(e){return e.join(" ").trim()}var go={},xd,z0;function fA(){if(z0)return xd;z0=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,a=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,u=/^[;\s]*/,c=/^\s+|\s+$/g,d=`
24
- `,h="/",m="*",g="",T="comment",b="declaration";xd=function(S,A){if(typeof S!="string")throw new TypeError("First argument must be a string");if(!S)return[];A=A||{};var C=1,O=1;function R(ge){var ue=ge.match(t);ue&&(C+=ue.length);var Te=ge.lastIndexOf(d);O=~Te?ge.length-Te:O+ge.length}function F(){var ge={line:C,column:O};return function(ue){return ue.position=new z(ge),ce(),ue}}function z(ge){this.start=ge,this.end={line:C,column:O},this.source=A.source}z.prototype.content=S;function D(ge){var ue=new Error(A.source+":"+C+":"+O+": "+ge);if(ue.reason=ge,ue.filename=A.source,ue.line=C,ue.column=O,ue.source=S,!A.silent)throw ue}function q(ge){var ue=ge.exec(S);if(ue){var Te=ue[0];return R(Te),S=S.slice(Te.length),ue}}function ce(){q(n)}function be(ge){var ue;for(ge=ge||[];ue=j();)ue!==!1&&ge.push(ue);return ge}function j(){var ge=F();if(!(h!=S.charAt(0)||m!=S.charAt(1))){for(var ue=2;g!=S.charAt(ue)&&(m!=S.charAt(ue)||h!=S.charAt(ue+1));)++ue;if(ue+=2,g===S.charAt(ue-1))return D("End of comment missing");var Te=S.slice(2,ue-2);return O+=2,R(Te),S=S.slice(ue),O+=2,ge({type:T,comment:Te})}}function ae(){var ge=F(),ue=q(r);if(ue){if(j(),!q(o))return D("property missing ':'");var Te=q(a),Ne=ge({type:b,property:x(ue[0].replace(e,g)),value:Te?x(Te[0].replace(e,g)):g});return q(u),Ne}}function he(){var ge=[];be(ge);for(var ue;ue=ae();)ue!==!1&&(ge.push(ue),be(ge));return ge}return ce(),he()};function x(S){return S?S.replace(c,g):g}return xd}var j0;function hA(){if(j0)return go;j0=1;var e=go&&go.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(go,"__esModule",{value:!0}),go.default=n;var t=e(fA());function n(r,o){var a=null;if(!r||typeof r!="string")return a;var u=(0,t.default)(r),c=typeof o=="function";return u.forEach(function(d){if(d.type==="declaration"){var h=d.property,m=d.value;c?o(h,m,d):m&&(a=a||{},a[h]=m)}}),a}return go}var Is={},$0;function pA(){if($0)return Is;$0=1,Object.defineProperty(Is,"__esModule",{value:!0}),Is.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,a=function(h){return!h||n.test(h)||e.test(h)},u=function(h,m){return m.toUpperCase()},c=function(h,m){return"".concat(m,"-")},d=function(h,m){return m===void 0&&(m={}),a(h)?h:(h=h.toLowerCase(),m.reactCompat?h=h.replace(o,c):h=h.replace(r,c),h.replace(t,u))};return Is.camelCase=d,Is}var Rs,V0;function mA(){if(V0)return Rs;V0=1;var e=Rs&&Rs.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(hA()),n=pA();function r(o,a){var u={};return!o||typeof o!="string"||(0,t.default)(o,function(c,d){c&&d&&(u[(0,n.camelCase)(c,a)]=d)}),u}return r.default=r,Rs=r,Rs}var gA=mA();const EA=We(gA),Su=Y0("end"),ar=Y0("start");function Y0(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 W0(e){const t=ar(e),n=Su(e);if(t&&n)return{start:t,end:n}}function Ps(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?q0(e.position):"start"in e||"end"in e?q0(e):"line"in e||"column"in e?_d(e):""}function _d(e){return G0(e&&e.line)+":"+G0(e&&e.column)}function q0(e){return _d(e&&e.start)+"-"+_d(e&&e.end)}function G0(e){return e&&typeof e=="number"?e:1}class Yt extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let o="",a={},u=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a=U({},n)),typeof t=="string"?o=t:!a.cause&&t&&(u=!0,o=t.message,a.cause=t),!a.ruleId&&!a.source&&typeof r=="string"){const d=r.indexOf(":");d===-1?a.ruleId=r:(a.source=r.slice(0,d),a.ruleId=r.slice(d+1))}if(!a.place&&a.ancestors&&a.ancestors){const d=a.ancestors[a.ancestors.length-1];d&&(a.place=d.position)}const c=a.place&&"start"in a.place?a.place.start:a.place;this.ancestors=a.ancestors||void 0,this.cause=a.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=Ps(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=u&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual,this.expected,this.note,this.url}}Yt.prototype.file="",Yt.prototype.name="",Yt.prototype.reason="",Yt.prototype.message="",Yt.prototype.stack="",Yt.prototype.column=void 0,Yt.prototype.line=void 0,Yt.prototype.ancestors=void 0,Yt.prototype.cause=void 0,Yt.prototype.fatal=void 0,Yt.prototype.place=void 0,Yt.prototype.ruleId=void 0,Yt.prototype.source=void 0;const Sd={}.hasOwnProperty,yA=new Map,TA=/[A-Z]/g,bA=new Set(["table","tbody","thead","tfoot","tr"]),xA=new Set(["td","th"]),K0="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function _A(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=OA(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=NA(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"?mo:_u,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=Q0(o,e,void 0);return a&&typeof a!="string"?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function Q0(e,t,n){if(t.type==="element")return SA(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return wA(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return vA(e,t,n);if(t.type==="mdxjsEsm")return AA(e,t);if(t.type==="root")return CA(e,t,n);if(t.type==="text")return kA(e,t)}function SA(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=J0(e,t.tagName,!1),u=IA(e,t);let c=Ad(e,t);return bA.has(t.tagName)&&(c=c.filter(function(d){return typeof d=="string"?!rA(d):!0})),X0(e,u,a,t),wd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function wA(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)}Ls(e,t.position)}function AA(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ls(e,t.position)}function vA(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=t.name===null?e.Fragment:J0(e,t.name,!0),u=RA(e,t),c=Ad(e,t);return X0(e,u,a,t),wd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function CA(e,t,n){const r={};return wd(r,Ad(e,t)),e.create(t,e.Fragment,r,n)}function kA(e,t){return t.value}function X0(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function wd(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function NA(e,t,n){return r;function r(o,a,u,c){const h=Array.isArray(u.children)?n:t;return c?h(a,u,c):h(a,u)}}function OA(e,t){return n;function n(r,o,a,u){const c=Array.isArray(a.children),d=ar(r);return t(o,a,u,c,{columnNumber:d?d.column-1:void 0,fileName:e,lineNumber:d?d.line:void 0},void 0)}}function IA(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&Sd.call(t.properties,o)){const a=PA(e,o,t.properties[o]);if(a){const[u,c]=a;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&xA.has(t.tagName)?r=c:n[u]=c}}if(r){const a=n.style||(n.style={});a[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function RA(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const a=r.data.estree.body[0];a.type;const u=a.expression;u.type;const c=u.properties[0];c.type,Object.assign(n,e.evaluater.evaluateExpression(c.argument))}else Ls(e,t.position);else{const o=r.name;let a;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,a=e.evaluater.evaluateExpression(c.expression)}else Ls(e,t.position);else a=r.value===null?!0:r.value;n[o]=a}return n}function Ad(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:yA;for(;++r<t.children.length;){const a=t.children[r];let u;if(e.passKeys){const d=a.type==="element"?a.tagName:a.type==="mdxJsxFlowElement"||a.type==="mdxJsxTextElement"?a.name:void 0;if(d){const h=o.get(d)||0;u=d+"-"+h,o.set(d,h+1)}}const c=Q0(e,a,u);c!==void 0&&n.push(c)}return n}function PA(e,t,n){const r=bd(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?C0(n):H0(n)),r.property==="style"){let o=typeof n=="object"?n:LA(e,String(n));return e.stylePropertyNameCase==="css"&&(o=DA(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?aA[r.property]||r.property:r.attribute,n]}}function LA(e,t){try{return EA(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new Yt("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=K0+"#cannot-parse-style-attribute",o}}function J0(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const o=t.split(".");let a=-1,u;for(;++a<o.length;){const c=k0(o[a])?{type:"Identifier",name:o[a]}:{type:"Literal",value:o[a]};u=u?{type:"MemberExpression",object:u,property:c,computed:!!(a&&c.type==="Literal"),optional:!1}:c}r=u}else r=k0(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return Sd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);Ls(e)}function Ls(e,t){const n=new Yt("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=K0+"#cannot-handle-mdx-estrees-without-createevaluater",n}function DA(e){const t={};let n;for(n in e)Sd.call(e,n)&&(t[MA(n)]=e[n]);return t}function MA(e){let t=e.replace(TA,FA);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function FA(e){return"-"+e.toLowerCase()}const vd={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"]},BA={};function Cd(e,t){const n=BA,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return Z0(e,r,o)}function Z0(e,t,n){if(UA(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 eg(e.children,t,n)}return Array.isArray(e)?eg(e,t,n):""}function eg(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=Z0(e[o],t,n);return r.join("")}function UA(e){return!!(e&&typeof e=="object")}const tg=document.createElement("i");function kd(e){const t="&"+e+";";tg.innerHTML=t;const n=tg.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function xn(e,t,n,r){const o=e.length;let a=0,u;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)u=Array.from(r),u.unshift(t,n),e.splice(...u);else for(n&&e.splice(t,n);a<r.length;)u=r.slice(a,a+1e4),u.unshift(t,0),e.splice(...u),a+=1e4,t+=1e4}function Rn(e,t){return e.length>0?(xn(e,e.length,0,t),e):t}const ng={}.hasOwnProperty;function rg(e){const t={};let n=-1;for(;++n<e.length;)HA(t,e[n]);return t}function HA(e,t){let n;for(n in t){const o=(ng.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let u;if(a)for(u in a){ng.call(o,u)||(o[u]=[]);const c=a[u];zA(o[u],Array.isArray(c)?c:c?[c]:[])}}}function zA(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);xn(e,0,0,r)}function ig(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 Wn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const en=$r(/[A-Za-z]/),Wt=$r(/[\dA-Za-z]/),jA=$r(/[#-'*+\--9=?A-Z^-~]/);function wu(e){return e!==null&&(e<32||e===127)}const Nd=$r(/\d/),$A=$r(/[\dA-Fa-f]/),VA=$r(/[!-/:-@[-`{-~]/);function Le(e){return e!==null&&e<-2}function it(e){return e!==null&&(e<0||e===32)}function qe(e){return e===-2||e===-1||e===32}const Au=$r(new RegExp("\\p{P}|\\p{S}","u")),Ni=$r(/\s/);function $r(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Eo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let u="";if(a===37&&Wt(e.charCodeAt(n+1))&&Wt(e.charCodeAt(n+2)))o=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(u=String.fromCharCode(a));else if(a>55295&&a<57344){const c=e.charCodeAt(n+1);a<56320&&c>56319&&c<57344?(u=String.fromCharCode(a,c),o=1):u="�"}else u=String.fromCharCode(a);u&&(t.push(e.slice(r,n),encodeURIComponent(u)),r=n+o+1,u=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function Ke(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let a=0;return u;function u(d){return qe(d)?(e.enter(n),c(d)):t(d)}function c(d){return qe(d)&&a++<o?(e.consume(d),c):(e.exit(n),t(d))}}const YA={tokenize:WA};function WA(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"),Ke(e,t,"linePrefix")}function o(c){return e.enter("paragraph"),a(c)}function a(c){const d=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=d),n=d,u(c)}function u(c){if(c===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(c);return}return Le(c)?(e.consume(c),e.exit("chunkText"),a):(e.consume(c),u)}}const qA={tokenize:GA},og={tokenize:KA};function GA(e){const t=this,n=[];let r=0,o,a,u;return c;function c(R){if(r<n.length){const F=n[r];return t.containerState=F[1],e.attempt(F[0].continuation,d,h)(R)}return h(R)}function d(R){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&O();const F=t.events.length;let z=F,D;for(;z--;)if(t.events[z][0]==="exit"&&t.events[z][1].type==="chunkFlow"){D=t.events[z][1].end;break}C(r);let q=F;for(;q<t.events.length;)t.events[q][1].end=U({},D),q++;return xn(t.events,z+1,0,t.events.slice(F)),t.events.length=q,h(R)}return c(R)}function h(R){if(r===n.length){if(!o)return T(R);if(o.currentConstruct&&o.currentConstruct.concrete)return x(R);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(og,m,g)(R)}function m(R){return o&&O(),C(r),T(R)}function g(R){return t.parser.lazy[t.now().line]=r!==n.length,u=t.now().offset,x(R)}function T(R){return t.containerState={},e.attempt(og,b,x)(R)}function b(R){return r++,n.push([t.currentConstruct,t.containerState]),T(R)}function x(R){if(R===null){o&&O(),C(0),e.consume(R);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:a}),S(R)}function S(R){if(R===null){A(e.exit("chunkFlow"),!0),C(0),e.consume(R);return}return Le(R)?(e.consume(R),A(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(R),S)}function A(R,F){const z=t.sliceStream(R);if(F&&z.push(null),R.previous=a,a&&(a.next=R),a=R,o.defineSkip(R.start),o.write(z),t.parser.lazy[R.start.line]){let D=o.events.length;for(;D--;)if(o.events[D][1].start.offset<u&&(!o.events[D][1].end||o.events[D][1].end.offset>u))return;const q=t.events.length;let ce=q,be,j;for(;ce--;)if(t.events[ce][0]==="exit"&&t.events[ce][1].type==="chunkFlow"){if(be){j=t.events[ce][1].end;break}be=!0}for(C(r),D=q;D<t.events.length;)t.events[D][1].end=U({},j),D++;xn(t.events,ce+1,0,t.events.slice(q)),t.events.length=D}}function C(R){let F=n.length;for(;F-- >R;){const z=n[F];t.containerState=z[1],z[0].exit.call(t,e)}n.length=R}function O(){o.write([null]),a=void 0,o=void 0,t.containerState._closeFlow=void 0}}function KA(e,t,n){return Ke(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function yo(e){if(e===null||it(e)||Ni(e))return 1;if(Au(e))return 2}function vu(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const a=e[o].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const Od={name:"attention",resolveAll:QA,tokenize:XA};function QA(e,t){let n=-1,r,o,a,u,c,d,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;d=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 g=U({},e[r][1].end),T=U({},e[n][1].start);sg(g,-d),sg(T,d),u={type:d>1?"strongSequence":"emphasisSequence",start:g,end:U({},e[r][1].end)},c={type:d>1?"strongSequence":"emphasisSequence",start:U({},e[n][1].start),end:T},a={type:d>1?"strongText":"emphasisText",start:U({},e[r][1].end),end:U({},e[n][1].start)},o={type:d>1?"strong":"emphasis",start:U({},u.start),end:U({},c.end)},e[r][1].end=U({},u.start),e[n][1].start=U({},c.end),h=[],e[r][1].end.offset-e[r][1].start.offset&&(h=Rn(h,[["enter",e[r][1],t],["exit",e[r][1],t]])),h=Rn(h,[["enter",o,t],["enter",u,t],["exit",u,t],["enter",a,t]]),h=Rn(h,vu(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),h=Rn(h,[["exit",a,t],["enter",c,t],["exit",c,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(m=2,h=Rn(h,[["enter",e[n][1],t],["exit",e[n][1],t]])):m=0,xn(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 XA(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=yo(r);let a;return u;function u(d){return a=d,e.enter("attentionSequence"),c(d)}function c(d){if(d===a)return e.consume(d),c;const h=e.exit("attentionSequence"),m=yo(d),g=!m||m===2&&o||n.includes(d),T=!o||o===2&&m||n.includes(r);return h._open=!!(a===42?g:g&&(o||!T)),h._close=!!(a===42?T:T&&(m||!g)),t(d)}}function sg(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const JA={name:"autolink",tokenize:ZA};function ZA(e,t,n){let r=0;return o;function o(b){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(b),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(b){return en(b)?(e.consume(b),u):b===64?n(b):h(b)}function u(b){return b===43||b===45||b===46||Wt(b)?(r=1,c(b)):h(b)}function c(b){return b===58?(e.consume(b),r=0,d):(b===43||b===45||b===46||Wt(b))&&r++<32?(e.consume(b),c):(r=0,h(b))}function d(b){return b===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(b),e.exit("autolinkMarker"),e.exit("autolink"),t):b===null||b===32||b===60||wu(b)?n(b):(e.consume(b),d)}function h(b){return b===64?(e.consume(b),m):jA(b)?(e.consume(b),h):n(b)}function m(b){return Wt(b)?g(b):n(b)}function g(b){return b===46?(e.consume(b),r=0,m):b===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(b),e.exit("autolinkMarker"),e.exit("autolink"),t):T(b)}function T(b){if((b===45||Wt(b))&&r++<63){const x=b===45?T:g;return e.consume(b),x}return n(b)}}const Ds={partial:!0,tokenize:ev};function ev(e,t,n){return r;function r(a){return qe(a)?Ke(e,o,"linePrefix")(a):o(a)}function o(a){return a===null||Le(a)?t(a):n(a)}}const ag={continuation:{tokenize:nv},exit:rv,name:"blockQuote",tokenize:tv};function tv(e,t,n){const r=this;return o;function o(u){if(u===62){const c=r.containerState;return c.open||(e.enter("blockQuote",{_container:!0}),c.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(u),e.exit("blockQuoteMarker"),a}return n(u)}function a(u){return qe(u)?(e.enter("blockQuotePrefixWhitespace"),e.consume(u),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(u))}}function nv(e,t,n){const r=this;return o;function o(u){return qe(u)?Ke(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(u):a(u)}function a(u){return e.attempt(ag,t,n)(u)}}function rv(e){e.exit("blockQuote")}const ug={name:"characterEscape",tokenize:iv};function iv(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),o}function o(a){return VA(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const lg={name:"characterReference",tokenize:ov};function ov(e,t,n){const r=this;let o=0,a,u;return c;function c(g){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(g),e.exit("characterReferenceMarker"),d}function d(g){return g===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(g),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),a=31,u=Wt,m(g))}function h(g){return g===88||g===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(g),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,u=$A,m):(e.enter("characterReferenceValue"),a=7,u=Nd,m(g))}function m(g){if(g===59&&o){const T=e.exit("characterReferenceValue");return u===Wt&&!kd(r.sliceSerialize(T))?n(g):(e.enter("characterReferenceMarker"),e.consume(g),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return u(g)&&o++<a?(e.consume(g),m):n(g)}}const cg={partial:!0,tokenize:av},dg={concrete:!0,name:"codeFenced",tokenize:sv};function sv(e,t,n){const r=this,o={partial:!0,tokenize:z};let a=0,u=0,c;return d;function d(D){return h(D)}function h(D){const q=r.events[r.events.length-1];return a=q&&q[1].type==="linePrefix"?q[2].sliceSerialize(q[1],!0).length:0,c=D,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),m(D)}function m(D){return D===c?(u++,e.consume(D),m):u<3?n(D):(e.exit("codeFencedFenceSequence"),qe(D)?Ke(e,g,"whitespace")(D):g(D))}function g(D){return D===null||Le(D)?(e.exit("codeFencedFence"),r.interrupt?t(D):e.check(cg,S,F)(D)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),T(D))}function T(D){return D===null||Le(D)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),g(D)):qe(D)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Ke(e,b,"whitespace")(D)):D===96&&D===c?n(D):(e.consume(D),T)}function b(D){return D===null||Le(D)?g(D):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),x(D))}function x(D){return D===null||Le(D)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),g(D)):D===96&&D===c?n(D):(e.consume(D),x)}function S(D){return e.attempt(o,F,A)(D)}function A(D){return e.enter("lineEnding"),e.consume(D),e.exit("lineEnding"),C}function C(D){return a>0&&qe(D)?Ke(e,O,"linePrefix",a+1)(D):O(D)}function O(D){return D===null||Le(D)?e.check(cg,S,F)(D):(e.enter("codeFlowValue"),R(D))}function R(D){return D===null||Le(D)?(e.exit("codeFlowValue"),O(D)):(e.consume(D),R)}function F(D){return e.exit("codeFenced"),t(D)}function z(D,q,ce){let be=0;return j;function j(Te){return D.enter("lineEnding"),D.consume(Te),D.exit("lineEnding"),ae}function ae(Te){return D.enter("codeFencedFence"),qe(Te)?Ke(D,he,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(Te):he(Te)}function he(Te){return Te===c?(D.enter("codeFencedFenceSequence"),ge(Te)):ce(Te)}function ge(Te){return Te===c?(be++,D.consume(Te),ge):be>=u?(D.exit("codeFencedFenceSequence"),qe(Te)?Ke(D,ue,"whitespace")(Te):ue(Te)):ce(Te)}function ue(Te){return Te===null||Le(Te)?(D.exit("codeFencedFence"),q(Te)):ce(Te)}}}function av(e,t,n){const r=this;return o;function o(u){return u===null?n(u):(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),a)}function a(u){return r.parser.lazy[r.now().line]?n(u):t(u)}}const Id={name:"codeIndented",tokenize:lv},uv={partial:!0,tokenize:cv};function lv(e,t,n){const r=this;return o;function o(h){return e.enter("codeIndented"),Ke(e,a,"linePrefix",5)(h)}function a(h){const m=r.events[r.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?u(h):n(h)}function u(h){return h===null?d(h):Le(h)?e.attempt(uv,u,d)(h):(e.enter("codeFlowValue"),c(h))}function c(h){return h===null||Le(h)?(e.exit("codeFlowValue"),u(h)):(e.consume(h),c)}function d(h){return e.exit("codeIndented"),t(h)}}function cv(e,t,n){const r=this;return o;function o(u){return r.parser.lazy[r.now().line]?n(u):Le(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),o):Ke(e,a,"linePrefix",5)(u)}function a(u){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(u):Le(u)?o(u):n(u)}}const dv={name:"codeText",previous:hv,resolve:fv,tokenize:pv};function fv(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 hv(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function pv(e,t,n){let r=0,o,a;return u;function u(g){return e.enter("codeText"),e.enter("codeTextSequence"),c(g)}function c(g){return g===96?(e.consume(g),r++,c):(e.exit("codeTextSequence"),d(g))}function d(g){return g===null?n(g):g===32?(e.enter("space"),e.consume(g),e.exit("space"),d):g===96?(a=e.enter("codeTextSequence"),o=0,m(g)):Le(g)?(e.enter("lineEnding"),e.consume(g),e.exit("lineEnding"),d):(e.enter("codeTextData"),h(g))}function h(g){return g===null||g===32||g===96||Le(g)?(e.exit("codeTextData"),d(g)):(e.consume(g),h)}function m(g){return g===96?(e.consume(g),o++,m):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(g)):(a.type="codeTextData",h(g))}}class mv{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 a=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return r&&Ms(this.left,r),a.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),Ms(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Ms(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);Ms(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Ms(this.left,n.reverse())}}}function Ms(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 fg(e){const t={};let n=-1,r,o,a,u,c,d,h;const m=new mv(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"&&(d=r[1]._tokenizer.events,a=0,a<d.length&&d[a][1].type==="lineEndingBlank"&&(a+=2),a<d.length&&d[a][1].type==="content"))for(;++a<d.length&&d[a][1].type!=="content";)d[a][1].type==="chunkText"&&(d[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,gv(m,n)),n=t[n],h=!0);else if(r[1]._container){for(a=n,o=void 0;a--;)if(u=m.get(a),u[1].type==="lineEnding"||u[1].type==="lineEndingBlank")u[0]==="enter"&&(o&&(m.get(o)[1].type="lineEndingBlank"),u[1].type="lineEnding",o=a);else if(!(u[1].type==="linePrefix"||u[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 xn(e,0,Number.POSITIVE_INFINITY,m.slice(0)),!h}function gv(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const a=[];let u=n._tokenizer;u||(u=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(u._contentTypeTextTrailing=!0));const c=u.events,d=[],h={};let m,g,T=-1,b=n,x=0,S=0;const A=[S];for(;b;){for(;e.get(++o)[1]!==b;);a.push(o),b._tokenizer||(m=r.sliceStream(b),b.next||m.push(null),g&&u.defineSkip(b.start),b._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=!0),u.write(m),b._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=void 0)),g=b,b=b.next}for(b=n;++T<c.length;)c[T][0]==="exit"&&c[T-1][0]==="enter"&&c[T][1].type===c[T-1][1].type&&c[T][1].start.line!==c[T][1].end.line&&(S=T+1,A.push(S),b._tokenizer=void 0,b.previous=void 0,b=b.next);for(u.events=[],b?(b._tokenizer=void 0,b.previous=void 0):A.pop(),T=A.length;T--;){const C=c.slice(A[T],A[T+1]),O=a.pop();d.push([O,O+C.length-1]),e.splice(O,2,C)}for(d.reverse(),T=-1;++T<d.length;)h[x+d[T][0]]=x+d[T][1],x+=d[T][1]-d[T][0]-1;return h}const Ev={resolve:Tv,tokenize:bv},yv={partial:!0,tokenize:xv};function Tv(e){return fg(e),e}function bv(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?a(c):Le(c)?e.check(yv,u,a)(c):(e.consume(c),o)}function a(c){return e.exit("chunkContent"),e.exit("content"),t(c)}function u(c){return e.consume(c),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,o}}function xv(e,t,n){const r=this;return o;function o(u){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),Ke(e,a,"linePrefix")}function a(u){if(u===null||Le(u))return n(u);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(u):e.interrupt(r.parser.constructs.flow,n,t)(u)}}function hg(e,t,n,r,o,a,u,c,d){const h=d||Number.POSITIVE_INFINITY;let m=0;return g;function g(C){return C===60?(e.enter(r),e.enter(o),e.enter(a),e.consume(C),e.exit(a),T):C===null||C===32||C===41||wu(C)?n(C):(e.enter(r),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),S(C))}function T(C){return C===62?(e.enter(a),e.consume(C),e.exit(a),e.exit(o),e.exit(r),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),b(C))}function b(C){return C===62?(e.exit("chunkString"),e.exit(c),T(C)):C===null||C===60||Le(C)?n(C):(e.consume(C),C===92?x:b)}function x(C){return C===60||C===62||C===92?(e.consume(C),b):b(C)}function S(C){return!m&&(C===null||C===41||it(C))?(e.exit("chunkString"),e.exit(c),e.exit(u),e.exit(r),t(C)):m<h&&C===40?(e.consume(C),m++,S):C===41?(e.consume(C),m--,S):C===null||C===32||C===40||wu(C)?n(C):(e.consume(C),C===92?A:S)}function A(C){return C===40||C===41||C===92?(e.consume(C),S):S(C)}}function pg(e,t,n,r,o,a){const u=this;let c=0,d;return h;function h(b){return e.enter(r),e.enter(o),e.consume(b),e.exit(o),e.enter(a),m}function m(b){return c>999||b===null||b===91||b===93&&!d||b===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(b):b===93?(e.exit(a),e.enter(o),e.consume(b),e.exit(o),e.exit(r),t):Le(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),g(b))}function g(b){return b===null||b===91||b===93||Le(b)||c++>999?(e.exit("chunkString"),m(b)):(e.consume(b),d||(d=!qe(b)),b===92?T:g)}function T(b){return b===91||b===92||b===93?(e.consume(b),c++,g):g(b)}}function mg(e,t,n,r,o,a){let u;return c;function c(T){return T===34||T===39||T===40?(e.enter(r),e.enter(o),e.consume(T),e.exit(o),u=T===40?41:T,d):n(T)}function d(T){return T===u?(e.enter(o),e.consume(T),e.exit(o),e.exit(r),t):(e.enter(a),h(T))}function h(T){return T===u?(e.exit(a),d(u)):T===null?n(T):Le(T)?(e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),Ke(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(T))}function m(T){return T===u||T===null||Le(T)?(e.exit("chunkString"),h(T)):(e.consume(T),T===92?g:m)}function g(T){return T===u||T===92?(e.consume(T),m):m(T)}}function Fs(e,t){let n;return r;function r(o){return Le(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):qe(o)?Ke(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}const _v={name:"definition",tokenize:wv},Sv={partial:!0,tokenize:Av};function wv(e,t,n){const r=this;let o;return a;function a(b){return e.enter("definition"),u(b)}function u(b){return pg.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(b)}function c(b){return o=Wn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),b===58?(e.enter("definitionMarker"),e.consume(b),e.exit("definitionMarker"),d):n(b)}function d(b){return it(b)?Fs(e,h)(b):h(b)}function h(b){return hg(e,m,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(b)}function m(b){return e.attempt(Sv,g,g)(b)}function g(b){return qe(b)?Ke(e,T,"whitespace")(b):T(b)}function T(b){return b===null||Le(b)?(e.exit("definition"),r.parser.defined.push(o),t(b)):n(b)}}function Av(e,t,n){return r;function r(c){return it(c)?Fs(e,o)(c):n(c)}function o(c){return mg(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function a(c){return qe(c)?Ke(e,u,"whitespace")(c):u(c)}function u(c){return c===null||Le(c)?t(c):n(c)}}const vv={name:"hardBreakEscape",tokenize:Cv};function Cv(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),o}function o(a){return Le(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const kv={name:"headingAtx",resolve:Nv,tokenize:Ov};function Nv(e,t){let n=e.length-2,r=3,o,a;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},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},xn(e,r,n-r+1,[["enter",o,t],["enter",a,t],["exit",a,t],["exit",o,t]])),e}function Ov(e,t,n){let r=0;return o;function o(m){return e.enter("atxHeading"),a(m)}function a(m){return e.enter("atxHeadingSequence"),u(m)}function u(m){return m===35&&r++<6?(e.consume(m),u):m===null||it(m)?(e.exit("atxHeadingSequence"),c(m)):n(m)}function c(m){return m===35?(e.enter("atxHeadingSequence"),d(m)):m===null||Le(m)?(e.exit("atxHeading"),t(m)):qe(m)?Ke(e,c,"whitespace")(m):(e.enter("atxHeadingText"),h(m))}function d(m){return m===35?(e.consume(m),d):(e.exit("atxHeadingSequence"),c(m))}function h(m){return m===null||m===35||it(m)?(e.exit("atxHeadingText"),c(m)):(e.consume(m),h)}}const Iv=["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"],gg=["pre","script","style","textarea"],Rv={concrete:!0,name:"htmlFlow",resolveTo:Dv,tokenize:Mv},Pv={partial:!0,tokenize:Bv},Lv={partial:!0,tokenize:Fv};function Dv(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 Mv(e,t,n){const r=this;let o,a,u,c,d;return h;function h(k){return m(k)}function m(k){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(k),g}function g(k){return k===33?(e.consume(k),T):k===47?(e.consume(k),a=!0,S):k===63?(e.consume(k),o=3,r.interrupt?t:w):en(k)?(e.consume(k),u=String.fromCharCode(k),A):n(k)}function T(k){return k===45?(e.consume(k),o=2,b):k===91?(e.consume(k),o=5,c=0,x):en(k)?(e.consume(k),o=4,r.interrupt?t:w):n(k)}function b(k){return k===45?(e.consume(k),r.interrupt?t:w):n(k)}function x(k){const xe="CDATA[";return k===xe.charCodeAt(c++)?(e.consume(k),c===xe.length?r.interrupt?t:he:x):n(k)}function S(k){return en(k)?(e.consume(k),u=String.fromCharCode(k),A):n(k)}function A(k){if(k===null||k===47||k===62||it(k)){const xe=k===47,Pe=u.toLowerCase();return!xe&&!a&&gg.includes(Pe)?(o=1,r.interrupt?t(k):he(k)):Iv.includes(u.toLowerCase())?(o=6,xe?(e.consume(k),C):r.interrupt?t(k):he(k)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?O(k):R(k))}return k===45||Wt(k)?(e.consume(k),u+=String.fromCharCode(k),A):n(k)}function C(k){return k===62?(e.consume(k),r.interrupt?t:he):n(k)}function O(k){return qe(k)?(e.consume(k),O):j(k)}function R(k){return k===47?(e.consume(k),j):k===58||k===95||en(k)?(e.consume(k),F):qe(k)?(e.consume(k),R):j(k)}function F(k){return k===45||k===46||k===58||k===95||Wt(k)?(e.consume(k),F):z(k)}function z(k){return k===61?(e.consume(k),D):qe(k)?(e.consume(k),z):R(k)}function D(k){return k===null||k===60||k===61||k===62||k===96?n(k):k===34||k===39?(e.consume(k),d=k,q):qe(k)?(e.consume(k),D):ce(k)}function q(k){return k===d?(e.consume(k),d=null,be):k===null||Le(k)?n(k):(e.consume(k),q)}function ce(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||it(k)?z(k):(e.consume(k),ce)}function be(k){return k===47||k===62||qe(k)?R(k):n(k)}function j(k){return k===62?(e.consume(k),ae):n(k)}function ae(k){return k===null||Le(k)?he(k):qe(k)?(e.consume(k),ae):n(k)}function he(k){return k===45&&o===2?(e.consume(k),Ne):k===60&&o===1?(e.consume(k),fe):k===62&&o===4?(e.consume(k),M):k===63&&o===3?(e.consume(k),w):k===93&&o===5?(e.consume(k),te):Le(k)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(Pv,X,ge)(k)):k===null||Le(k)?(e.exit("htmlFlowData"),ge(k)):(e.consume(k),he)}function ge(k){return e.check(Lv,ue,X)(k)}function ue(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),Te}function Te(k){return k===null||Le(k)?ge(k):(e.enter("htmlFlowData"),he(k))}function Ne(k){return k===45?(e.consume(k),w):he(k)}function fe(k){return k===47?(e.consume(k),u="",K):he(k)}function K(k){if(k===62){const xe=u.toLowerCase();return gg.includes(xe)?(e.consume(k),M):he(k)}return en(k)&&u.length<8?(e.consume(k),u+=String.fromCharCode(k),K):he(k)}function te(k){return k===93?(e.consume(k),w):he(k)}function w(k){return k===62?(e.consume(k),M):k===45&&o===2?(e.consume(k),w):he(k)}function M(k){return k===null||Le(k)?(e.exit("htmlFlowData"),X(k)):(e.consume(k),M)}function X(k){return e.exit("htmlFlow"),t(k)}}function Fv(e,t,n){const r=this;return o;function o(u){return Le(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),a):n(u)}function a(u){return r.parser.lazy[r.now().line]?n(u):t(u)}}function Bv(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ds,t,n)}}const Uv={name:"htmlText",tokenize:Hv};function Hv(e,t,n){const r=this;let o,a,u;return c;function c(w){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(w),d}function d(w){return w===33?(e.consume(w),h):w===47?(e.consume(w),z):w===63?(e.consume(w),R):en(w)?(e.consume(w),ce):n(w)}function h(w){return w===45?(e.consume(w),m):w===91?(e.consume(w),a=0,x):en(w)?(e.consume(w),O):n(w)}function m(w){return w===45?(e.consume(w),b):n(w)}function g(w){return w===null?n(w):w===45?(e.consume(w),T):Le(w)?(u=g,fe(w)):(e.consume(w),g)}function T(w){return w===45?(e.consume(w),b):g(w)}function b(w){return w===62?Ne(w):w===45?T(w):g(w)}function x(w){const M="CDATA[";return w===M.charCodeAt(a++)?(e.consume(w),a===M.length?S:x):n(w)}function S(w){return w===null?n(w):w===93?(e.consume(w),A):Le(w)?(u=S,fe(w)):(e.consume(w),S)}function A(w){return w===93?(e.consume(w),C):S(w)}function C(w){return w===62?Ne(w):w===93?(e.consume(w),C):S(w)}function O(w){return w===null||w===62?Ne(w):Le(w)?(u=O,fe(w)):(e.consume(w),O)}function R(w){return w===null?n(w):w===63?(e.consume(w),F):Le(w)?(u=R,fe(w)):(e.consume(w),R)}function F(w){return w===62?Ne(w):R(w)}function z(w){return en(w)?(e.consume(w),D):n(w)}function D(w){return w===45||Wt(w)?(e.consume(w),D):q(w)}function q(w){return Le(w)?(u=q,fe(w)):qe(w)?(e.consume(w),q):Ne(w)}function ce(w){return w===45||Wt(w)?(e.consume(w),ce):w===47||w===62||it(w)?be(w):n(w)}function be(w){return w===47?(e.consume(w),Ne):w===58||w===95||en(w)?(e.consume(w),j):Le(w)?(u=be,fe(w)):qe(w)?(e.consume(w),be):Ne(w)}function j(w){return w===45||w===46||w===58||w===95||Wt(w)?(e.consume(w),j):ae(w)}function ae(w){return w===61?(e.consume(w),he):Le(w)?(u=ae,fe(w)):qe(w)?(e.consume(w),ae):be(w)}function he(w){return w===null||w===60||w===61||w===62||w===96?n(w):w===34||w===39?(e.consume(w),o=w,ge):Le(w)?(u=he,fe(w)):qe(w)?(e.consume(w),he):(e.consume(w),ue)}function ge(w){return w===o?(e.consume(w),o=void 0,Te):w===null?n(w):Le(w)?(u=ge,fe(w)):(e.consume(w),ge)}function ue(w){return w===null||w===34||w===39||w===60||w===61||w===96?n(w):w===47||w===62||it(w)?be(w):(e.consume(w),ue)}function Te(w){return w===47||w===62||it(w)?be(w):n(w)}function Ne(w){return w===62?(e.consume(w),e.exit("htmlTextData"),e.exit("htmlText"),t):n(w)}function fe(w){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),K}function K(w){return qe(w)?Ke(e,te,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(w):te(w)}function te(w){return e.enter("htmlTextData"),u(w)}}const Rd={name:"labelEnd",resolveAll:Vv,resolveTo:Yv,tokenize:Wv},zv={tokenize:qv},jv={tokenize:Gv},$v={tokenize:Kv};function Vv(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&&xn(e,0,e.length,n),e}function Yv(e,t){let n=e.length,r=0,o,a,u,c;for(;n--;)if(o=e[n][1],a){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[n][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(u){if(e[n][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(a=n,o.type!=="labelLink")){r=2;break}}else o.type==="labelEnd"&&(u=n);const d={type:e[a][1].type==="labelLink"?"link":"image",start:U({},e[a][1].start),end:U({},e[e.length-1][1].end)},h={type:"label",start:U({},e[a][1].start),end:U({},e[u][1].end)},m={type:"labelText",start:U({},e[a+r+2][1].end),end:U({},e[u-2][1].start)};return c=[["enter",d,t],["enter",h,t]],c=Rn(c,e.slice(a+1,a+r+3)),c=Rn(c,[["enter",m,t]]),c=Rn(c,vu(t.parser.constructs.insideSpan.null,e.slice(a+r+4,u-3),t)),c=Rn(c,[["exit",m,t],e[u-2],e[u-1],["exit",h,t]]),c=Rn(c,e.slice(u+1)),c=Rn(c,[["exit",d,t]]),xn(e,a,e.length,c),e}function Wv(e,t,n){const r=this;let o=r.events.length,a,u;for(;o--;)if((r.events[o][1].type==="labelImage"||r.events[o][1].type==="labelLink")&&!r.events[o][1]._balanced){a=r.events[o][1];break}return c;function c(T){return a?a._inactive?g(T):(u=r.parser.defined.includes(Wn(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(T),e.exit("labelMarker"),e.exit("labelEnd"),d):n(T)}function d(T){return T===40?e.attempt(zv,m,u?m:g)(T):T===91?e.attempt(jv,m,u?h:g)(T):u?m(T):g(T)}function h(T){return e.attempt($v,m,g)(T)}function m(T){return t(T)}function g(T){return a._balanced=!0,n(T)}}function qv(e,t,n){return r;function r(g){return e.enter("resource"),e.enter("resourceMarker"),e.consume(g),e.exit("resourceMarker"),o}function o(g){return it(g)?Fs(e,a)(g):a(g)}function a(g){return g===41?m(g):hg(e,u,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(g)}function u(g){return it(g)?Fs(e,d)(g):m(g)}function c(g){return n(g)}function d(g){return g===34||g===39||g===40?mg(e,h,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(g):m(g)}function h(g){return it(g)?Fs(e,m)(g):m(g)}function m(g){return g===41?(e.enter("resourceMarker"),e.consume(g),e.exit("resourceMarker"),e.exit("resource"),t):n(g)}}function Gv(e,t,n){const r=this;return o;function o(c){return pg.call(r,e,a,u,"reference","referenceMarker","referenceString")(c)}function a(c){return r.parser.defined.includes(Wn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(c):n(c)}function u(c){return n(c)}}function Kv(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),o}function o(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const Qv={name:"labelStartImage",resolveAll:Rd.resolveAll,tokenize:Xv};function Xv(e,t,n){const r=this;return o;function o(c){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(c),e.exit("labelImageMarker"),a}function a(c){return c===91?(e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelImage"),u):n(c)}function u(c){return c===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(c):t(c)}}const Jv={name:"labelStartLink",resolveAll:Rd.resolveAll,tokenize:Zv};function Zv(e,t,n){const r=this;return o;function o(u){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(u),e.exit("labelMarker"),e.exit("labelLink"),a}function a(u){return u===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(u):t(u)}}const Pd={name:"lineEnding",tokenize:eC};function eC(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Ke(e,t,"linePrefix")}}const Cu={name:"thematicBreak",tokenize:tC};function tC(e,t,n){let r=0,o;return a;function a(h){return e.enter("thematicBreak"),u(h)}function u(h){return o=h,c(h)}function c(h){return h===o?(e.enter("thematicBreakSequence"),d(h)):r>=3&&(h===null||Le(h))?(e.exit("thematicBreak"),t(h)):n(h)}function d(h){return h===o?(e.consume(h),r++,d):(e.exit("thematicBreakSequence"),qe(h)?Ke(e,c,"whitespace")(h):c(h))}}const dn={continuation:{tokenize:oC},exit:aC,name:"list",tokenize:iC},nC={partial:!0,tokenize:uC},rC={partial:!0,tokenize:sC};function iC(e,t,n){const r=this,o=r.events[r.events.length-1];let a=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,u=0;return c;function c(b){const x=r.containerState.type||(b===42||b===43||b===45?"listUnordered":"listOrdered");if(x==="listUnordered"?!r.containerState.marker||b===r.containerState.marker:Nd(b)){if(r.containerState.type||(r.containerState.type=x,e.enter(x,{_container:!0})),x==="listUnordered")return e.enter("listItemPrefix"),b===42||b===45?e.check(Cu,n,h)(b):h(b);if(!r.interrupt||b===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),d(b)}return n(b)}function d(b){return Nd(b)&&++u<10?(e.consume(b),d):(!r.interrupt||u<2)&&(r.containerState.marker?b===r.containerState.marker:b===41||b===46)?(e.exit("listItemValue"),h(b)):n(b)}function h(b){return e.enter("listItemMarker"),e.consume(b),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||b,e.check(Ds,r.interrupt?n:m,e.attempt(nC,T,g))}function m(b){return r.containerState.initialBlankLine=!0,a++,T(b)}function g(b){return qe(b)?(e.enter("listItemPrefixWhitespace"),e.consume(b),e.exit("listItemPrefixWhitespace"),T):n(b)}function T(b){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(b)}}function oC(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Ds,o,a);function o(c){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Ke(e,t,"listItemIndent",r.containerState.size+1)(c)}function a(c){return r.containerState.furtherBlankLines||!qe(c)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,u(c)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(rC,t,u)(c))}function u(c){return r.containerState._closeFlow=!0,r.interrupt=void 0,Ke(e,e.attempt(dn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function sC(e,t,n){const r=this;return Ke(e,o,"listItemIndent",r.containerState.size+1);function o(a){const u=r.events[r.events.length-1];return u&&u[1].type==="listItemIndent"&&u[2].sliceSerialize(u[1],!0).length===r.containerState.size?t(a):n(a)}}function aC(e){e.exit(this.containerState.type)}function uC(e,t,n){const r=this;return Ke(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(a){const u=r.events[r.events.length-1];return!qe(a)&&u&&u[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const Eg={name:"setextUnderline",resolveTo:lC,tokenize:cC};function lC(e,t){let n=e.length,r,o,a;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),!a&&e[n][1].type==="definition"&&(a=n);const u={type:"setextHeading",start:U({},e[r][1].start),end:U({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",a?(e.splice(o,0,["enter",u,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end=U({},e[a][1].end)):e[r][1]=u,e.push(["exit",u,t]),e}function cC(e,t,n){const r=this;let o;return a;function a(h){let m=r.events.length,g;for(;m--;)if(r.events[m][1].type!=="lineEnding"&&r.events[m][1].type!=="linePrefix"&&r.events[m][1].type!=="content"){g=r.events[m][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||g)?(e.enter("setextHeadingLine"),o=h,u(h)):n(h)}function u(h){return e.enter("setextHeadingLineSequence"),c(h)}function c(h){return h===o?(e.consume(h),c):(e.exit("setextHeadingLineSequence"),qe(h)?Ke(e,d,"lineSuffix")(h):d(h))}function d(h){return h===null||Le(h)?(e.exit("setextHeadingLine"),t(h)):n(h)}}const dC={tokenize:fC};function fC(e){const t=this,n=e.attempt(Ds,r,e.attempt(this.parser.constructs.flowInitial,o,Ke(e,e.attempt(this.parser.constructs.flow,o,e.attempt(Ev,o)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const hC={resolveAll:Tg()},pC=yg("string"),mC=yg("text");function yg(e){return{resolveAll:Tg(e==="text"?gC:void 0),tokenize:t};function t(n){const r=this,o=this.parser.constructs[e],a=n.attempt(o,u,c);return u;function u(m){return h(m)?a(m):c(m)}function c(m){if(m===null){n.consume(m);return}return n.enter("data"),n.consume(m),d}function d(m){return h(m)?(n.exit("data"),a(m)):(n.consume(m),d)}function h(m){if(m===null)return!0;const g=o[m];let T=-1;if(g)for(;++T<g.length;){const b=g[T];if(!b.previous||b.previous.call(r,r.previous))return!0}return!1}}}function Tg(e){return t;function t(n,r){let o=-1,a;for(;++o<=n.length;)a===void 0?n[o]&&n[o][1].type==="data"&&(a=o,o++):(!n[o]||n[o][1].type!=="data")&&(o!==a+2&&(n[a][1].end=n[o-1][1].end,n.splice(a+2,o-a-2),o=a+2),a=void 0);return e?e(n,r):n}}function gC(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 a=o.length,u=-1,c=0,d;for(;a--;){const h=o[a];if(typeof h=="string"){for(u=h.length;h.charCodeAt(u-1)===32;)c++,u--;if(u)break;u=-1}else if(h===-2)d=!0,c++;else if(h!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(c=0),c){const h={type:n===e.length||d||c<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?u:r.start._bufferIndex+u,_index:r.start._index+a,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 EC=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:_v},disable:{null:[]},document:{42:dn,43:dn,45:dn,48:dn,49:dn,50:dn,51:dn,52:dn,53:dn,54:dn,55:dn,56:dn,57:dn,62:ag},flow:{35:kv,42:Cu,45:[Eg,Cu],60:Rv,61:Eg,95:Cu,96:dg,126:dg},flowInitial:{[-2]:Id,[-1]:Id,32:Id},insideSpan:{null:[Od,hC]},string:{38:lg,92:ug},text:{[-5]:Pd,[-4]:Pd,[-3]:Pd,33:Qv,38:lg,42:Od,60:[JA,Uv],91:Jv,92:[vv,ug],93:Rd,95:Od,96:dv}},Symbol.toStringTag,{value:"Module"}));function yC(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={},a=[];let u=[],c=[];const d={attempt:q(z),check:q(D),consume:O,enter:R,exit:F,interrupt:q(D,{interrupt:!0})},h={code:null,containerState:{},defineSkip:S,events:[],now:x,parser:e,previous:null,sliceSerialize:T,sliceStream:b,write:g};let m=t.tokenize.call(h,d);return t.resolveAll&&a.push(t),h;function g(ae){return u=Rn(u,ae),A(),u[u.length-1]!==null?[]:(ce(t,0),h.events=vu(a,h.events,h),h.events)}function T(ae,he){return bC(b(ae),he)}function b(ae){return TC(u,ae)}function x(){const{_bufferIndex:ae,_index:he,line:ge,column:ue,offset:Te}=r;return{_bufferIndex:ae,_index:he,line:ge,column:ue,offset:Te}}function S(ae){o[ae.line]=ae.column,j()}function A(){let ae;for(;r._index<u.length;){const he=u[r._index];if(typeof he=="string")for(ae=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===ae&&r._bufferIndex<he.length;)C(he.charCodeAt(r._bufferIndex));else C(he)}}function C(ae){m=m(ae)}function O(ae){Le(ae)?(r.line++,r.column=1,r.offset+=ae===-3?2:1,j()):ae!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===u[r._index].length&&(r._bufferIndex=-1,r._index++)),h.previous=ae}function R(ae,he){const ge=he||{};return ge.type=ae,ge.start=x(),h.events.push(["enter",ge,h]),c.push(ge),ge}function F(ae){const he=c.pop();return he.end=x(),h.events.push(["exit",he,h]),he}function z(ae,he){ce(ae,he.from)}function D(ae,he){he.restore()}function q(ae,he){return ge;function ge(ue,Te,Ne){let fe,K,te,w;return Array.isArray(ue)?X(ue):"tokenize"in ue?X([ue]):M(ue);function M(Oe){return He;function He(we){const Ve=we!==null&&Oe[we],ut=we!==null&&Oe.null,pn=[...Array.isArray(Ve)?Ve:Ve?[Ve]:[],...Array.isArray(ut)?ut:ut?[ut]:[]];return X(pn)(we)}}function X(Oe){return fe=Oe,K=0,Oe.length===0?Ne:k(Oe[K])}function k(Oe){return He;function He(we){return w=be(),te=Oe,Oe.partial||(h.currentConstruct=Oe),Oe.name&&h.parser.constructs.disable.null.includes(Oe.name)?Pe():Oe.tokenize.call(he?Object.assign(Object.create(h),he):h,d,xe,Pe)(we)}}function xe(Oe){return ae(te,w),Te}function Pe(Oe){return w.restore(),++K<fe.length?k(fe[K]):Ne}}}function ce(ae,he){ae.resolveAll&&!a.includes(ae)&&a.push(ae),ae.resolve&&xn(h.events,he,h.events.length-he,ae.resolve(h.events.slice(he),h)),ae.resolveTo&&(h.events=ae.resolveTo(h.events,h))}function be(){const ae=x(),he=h.previous,ge=h.currentConstruct,ue=h.events.length,Te=Array.from(c);return{from:ue,restore:Ne};function Ne(){r=ae,h.previous=he,h.currentConstruct=ge,h.events.length=ue,c=Te,j()}}function j(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function TC(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,a=t.end._bufferIndex;let u;if(n===o)u=[e[n].slice(r,a)];else{if(u=e.slice(n,o),r>-1){const c=u[0];typeof c=="string"?u[0]=c.slice(r):u.shift()}a>0&&u.push(e[o].slice(0,a))}return u}function bC(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const a=e[n];let u;if(typeof a=="string")u=a;else switch(a){case-5:{u="\r";break}case-4:{u=`
23
+ `+y.stack}return{value:i,source:s,stack:g,digest:null}}function _p(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function wp(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var Z8=typeof WeakMap=="function"?WeakMap:Map;function P2(i,s,l){l=Fr(-1,l),l.tag=3,l.payload={element:null};var f=s.value;return l.callback=function(){Ec||(Ec=!0,Bp=f),wp(i,s)},l}function L2(i,s,l){l=Fr(-1,l),l.tag=3;var f=i.type.getDerivedStateFromError;if(typeof f=="function"){var g=s.value;l.payload=function(){return f(g)},l.callback=function(){wp(i,s)}}var y=i.stateNode;return y!==null&&typeof y.componentDidCatch=="function"&&(l.callback=function(){wp(i,s),typeof f!="function"&&(pi===null?pi=new Set([this]):pi.add(this));var x=s.stack;this.componentDidCatch(s.value,{componentStack:x!==null?x:""})}),l}function D2(i,s,l){var f=i.pingCache;if(f===null){f=i.pingCache=new Z8;var g=new Set;f.set(s,g)}else g=f.get(s),g===void 0&&(g=new Set,f.set(s,g));g.has(l)||(g.add(l),i=hM.bind(null,i,s,l),s.then(i,i))}function M2(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 F2(i,s,l,f,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=Fr(-1,1),s.tag=2,fi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var eM=F.ReactCurrentOwner,En=!1;function nn(i,s,l,f){s.child=i===null?r2(s,null,l,f):ls(s,i.child,l,f)}function B2(i,s,l,f,g){l=l.render;var y=s.ref;return ds(s,g),f=pp(i,s,l,f,y,g),l=mp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Br(i,s,g)):(pt&&l&&Xh(s),s.flags|=1,nn(i,s,f,g),s.child)}function U2(i,s,l,f,g){if(i===null){var y=l.type;return typeof y=="function"&&!Yp(y)&&y.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=y,H2(i,s,y,f,g)):(i=wc(l.type,null,f,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:Ia,l(x,f)&&i.ref===s.ref)return Br(i,s,g)}return s.flags|=1,i=yi(y,f),i.ref=s.ref,i.return=s,s.child=i}function H2(i,s,l,f,g){if(i!==null){var y=i.memoizedProps;if(Ia(y,f)&&i.ref===s.ref)if(En=!1,s.pendingProps=f=y,(i.lanes&g)!==0)(i.flags&131072)!==0&&(En=!0);else return s.lanes=i.lanes,Br(i,s,g)}return Sp(i,s,l,f,g)}function z2(i,s,l){var f=s.pendingProps,g=f.children,y=i!==null?i.memoizedState:null;if(f.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},at(ms,Nn),Nn|=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,at(ms,Nn),Nn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},f=y!==null?y.baseLanes:l,at(ms,Nn),Nn|=f}else y!==null?(f=y.baseLanes|l,s.memoizedState=null):f=l,at(ms,Nn),Nn|=f;return nn(i,s,g,l),s.child}function j2(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function Sp(i,s,l,f,g){var y=gn(l)?Ki:Kt.current;return y=os(s,y),ds(s,g),l=pp(i,s,l,f,y,g),f=mp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Br(i,s,g)):(pt&&f&&Xh(s),s.flags|=1,nn(i,s,l,g),s.child)}function $2(i,s,l,f,g){if(gn(l)){var y=!0;Gl(s)}else y=!1;if(ds(s,g),s.stateNode===null)fc(i,s),I2(s,l,f),xp(s,l,f,g),f=!0;else if(i===null){var x=s.stateNode,O=s.memoizedProps;x.props=O;var B=x.context,G=l.contextType;typeof G=="object"&&G!==null?G=Un(G):(G=gn(l)?Ki:Kt.current,G=os(s,G));var se=l.getDerivedStateFromProps,de=typeof se=="function"||typeof x.getSnapshotBeforeUpdate=="function";de||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(O!==f||B!==G)&&R2(s,x,f,G),di=!1;var re=s.memoizedState;x.state=re,rc(s,f,x,g),B=s.memoizedState,O!==f||re!==B||mn.current||di?(typeof se=="function"&&(bp(s,l,se,f),B=s.memoizedState),(O=di||O2(s,l,O,f,re,B,G))?(de||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=f,s.memoizedState=B),x.props=f,x.state=B,x.context=G,f=O):(typeof x.componentDidMount=="function"&&(s.flags|=4194308),f=!1)}else{x=s.stateNode,o2(i,s),O=s.memoizedProps,G=s.type===s.elementType?O:tr(s.type,O),x.props=G,de=s.pendingProps,re=x.context,B=l.contextType,typeof B=="object"&&B!==null?B=Un(B):(B=gn(l)?Ki:Kt.current,B=os(s,B));var _e=l.getDerivedStateFromProps;(se=typeof _e=="function"||typeof x.getSnapshotBeforeUpdate=="function")||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(O!==de||re!==B)&&R2(s,x,f,B),di=!1,re=s.memoizedState,x.state=re,rc(s,f,x,g);var Ae=s.memoizedState;O!==de||re!==Ae||mn.current||di?(typeof _e=="function"&&(bp(s,l,_e,f),Ae=s.memoizedState),(G=di||O2(s,l,G,f,re,Ae,B)||!1)?(se||typeof x.UNSAFE_componentWillUpdate!="function"&&typeof x.componentWillUpdate!="function"||(typeof x.componentWillUpdate=="function"&&x.componentWillUpdate(f,Ae,B),typeof x.UNSAFE_componentWillUpdate=="function"&&x.UNSAFE_componentWillUpdate(f,Ae,B)),typeof x.componentDidUpdate=="function"&&(s.flags|=4),typeof x.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof x.componentDidUpdate!="function"||O===i.memoizedProps&&re===i.memoizedState||(s.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||O===i.memoizedProps&&re===i.memoizedState||(s.flags|=1024),s.memoizedProps=f,s.memoizedState=Ae),x.props=f,x.state=Ae,x.context=B,f=G):(typeof x.componentDidUpdate!="function"||O===i.memoizedProps&&re===i.memoizedState||(s.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||O===i.memoizedProps&&re===i.memoizedState||(s.flags|=1024),f=!1)}return Ap(i,s,l,f,y,g)}function Ap(i,s,l,f,g,y){j2(i,s);var x=(s.flags&128)!==0;if(!f&&!x)return g&&Gb(s,l,!1),Br(i,s,y);f=s.stateNode,eM.current=s;var O=x&&typeof l.getDerivedStateFromError!="function"?null:f.render();return s.flags|=1,i!==null&&x?(s.child=ls(s,i.child,null,y),s.child=ls(s,null,O,y)):nn(i,s,O,y),s.memoizedState=f.state,g&&Gb(s,l,!0),s.child}function V2(i){var s=i.stateNode;s.pendingContext?Wb(i,s.pendingContext,s.pendingContext!==s.context):s.context&&Wb(i,s.context,!1),up(i,s.containerInfo)}function Y2(i,s,l,f,g){return us(),tp(g),s.flags|=256,nn(i,s,l,f),s.child}var vp={dehydrated:null,treeContext:null,retryLane:0};function Cp(i){return{baseLanes:i,cachePool:null,transitions:null}}function W2(i,s,l){var f=s.pendingProps,g=mt.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),at(mt,g&1),i===null)return ep(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=f.children,i=f.fallback,y?(f=s.mode,y=s.child,x={mode:"hidden",children:x},(f&1)===0&&y!==null?(y.childLanes=0,y.pendingProps=x):y=Sc(x,f,0,null),i=oo(i,f,l,null),y.return=s,i.return=s,y.sibling=i,s.child=y,s.child.memoizedState=Cp(l),s.memoizedState=vp,i):kp(s,x));if(g=i.memoizedState,g!==null&&(O=g.dehydrated,O!==null))return tM(i,s,x,f,O,g,l);if(y){y=f.fallback,x=s.mode,g=i.child,O=g.sibling;var B={mode:"hidden",children:f.children};return(x&1)===0&&s.child!==g?(f=s.child,f.childLanes=0,f.pendingProps=B,s.deletions=null):(f=yi(g,B),f.subtreeFlags=g.subtreeFlags&14680064),O!==null?y=yi(O,y):(y=oo(y,x,l,null),y.flags|=2),y.return=s,f.return=s,f.sibling=y,s.child=f,f=y,y=s.child,x=i.child.memoizedState,x=x===null?Cp(l):{baseLanes:x.baseLanes|l,cachePool:null,transitions:x.transitions},y.memoizedState=x,y.childLanes=i.childLanes&~l,s.memoizedState=vp,f}return y=i.child,i=y.sibling,f=yi(y,{mode:"visible",children:f.children}),(s.mode&1)===0&&(f.lanes=l),f.return=s,f.sibling=null,i!==null&&(l=s.deletions,l===null?(s.deletions=[i],s.flags|=16):l.push(i)),s.child=f,s.memoizedState=null,f}function kp(i,s){return s=Sc({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function dc(i,s,l,f){return f!==null&&tp(f),ls(s,i.child,null,l),i=kp(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function tM(i,s,l,f,g,y,x){if(l)return s.flags&256?(s.flags&=-257,f=_p(Error(n(422))),dc(i,s,x,f)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(y=f.fallback,g=s.mode,f=Sc({mode:"visible",children:f.children},g,0,null),y=oo(y,g,x,null),y.flags|=2,f.return=s,y.return=s,f.sibling=y,s.child=f,(s.mode&1)!==0&&ls(s,i.child,null,x),s.child.memoizedState=Cp(x),s.memoizedState=vp,y);if((s.mode&1)===0)return dc(i,s,x,null);if(g.data==="$!"){if(f=g.nextSibling&&g.nextSibling.dataset,f)var O=f.dgst;return f=O,y=Error(n(419)),f=_p(y,f,void 0),dc(i,s,x,f)}if(O=(x&i.childLanes)!==0,En||O){if(f=Bt,f!==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&(f.suspendedLanes|x))!==0?0:g,g!==0&&g!==y.retryLane&&(y.retryLane=g,Mr(i,g),ir(f,i,g,-1))}return Vp(),f=_p(Error(n(421))),dc(i,s,x,f)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=pM.bind(null,i),g._reactRetry=s,null):(i=y.treeContext,kn=ai(g.nextSibling),Cn=s,pt=!0,er=null,i!==null&&(Fn[Bn++]=Lr,Fn[Bn++]=Dr,Fn[Bn++]=Qi,Lr=i.id,Dr=i.overflow,Qi=s),s=kp(s,f.children),s.flags|=4096,s)}function q2(i,s,l){i.lanes|=s;var f=i.alternate;f!==null&&(f.lanes|=s),op(i.return,s,l)}function Np(i,s,l,f,g){var y=i.memoizedState;y===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:f,tail:l,tailMode:g}:(y.isBackwards=s,y.rendering=null,y.renderingStartTime=0,y.last=f,y.tail=l,y.tailMode=g)}function G2(i,s,l){var f=s.pendingProps,g=f.revealOrder,y=f.tail;if(nn(i,s,f.children,l),f=mt.current,(f&2)!==0)f=f&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&&q2(i,l,s);else if(i.tag===19)q2(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}f&=1}if(at(mt,f),(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&&ic(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),Np(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&&ic(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}Np(s,!0,l,null,y);break;case"together":Np(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function fc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function Br(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),to|=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=yi(i,i.pendingProps),s.child=l,l.return=s;i.sibling!==null;)i=i.sibling,l=l.sibling=yi(i,i.pendingProps),l.return=s;l.sibling=null}return s.child}function nM(i,s,l){switch(s.tag){case 3:V2(s),us();break;case 5:u2(s);break;case 1:gn(s.type)&&Gl(s);break;case 4:up(s,s.stateNode.containerInfo);break;case 10:var f=s.type._context,g=s.memoizedProps.value;at(ec,f._currentValue),f._currentValue=g;break;case 13:if(f=s.memoizedState,f!==null)return f.dehydrated!==null?(at(mt,mt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?W2(i,s,l):(at(mt,mt.current&1),i=Br(i,s,l),i!==null?i.sibling:null);at(mt,mt.current&1);break;case 19:if(f=(l&s.childLanes)!==0,(i.flags&128)!==0){if(f)return G2(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),at(mt,mt.current),f)break;return null;case 22:case 23:return s.lanes=0,z2(i,s,l)}return Br(i,s,l)}var K2,Op,Q2,X2;K2=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}},Op=function(){},Q2=function(i,s,l,f){var g=i.memoizedProps;if(g!==f){i=s.stateNode,Zi(xr.current);var y=null;switch(l){case"input":g=Xn(i,g),f=Xn(i,f),y=[];break;case"select":g=S({},g,{value:void 0}),f=S({},f,{value:void 0}),y=[];break;case"textarea":g=ma(i,g),f=ma(i,f),y=[];break;default:typeof g.onClick!="function"&&typeof f.onClick=="function"&&(i.onclick=Yl)}zt(l,f);var x;l=null;for(G in g)if(!f.hasOwnProperty(G)&&g.hasOwnProperty(G)&&g[G]!=null)if(G==="style"){var O=g[G];for(x in O)O.hasOwnProperty(x)&&(l||(l={}),l[x]="")}else G!=="dangerouslySetInnerHTML"&&G!=="children"&&G!=="suppressContentEditableWarning"&&G!=="suppressHydrationWarning"&&G!=="autoFocus"&&(o.hasOwnProperty(G)?y||(y=[]):(y=y||[]).push(G,null));for(G in f){var B=f[G];if(O=g!=null?g[G]:void 0,f.hasOwnProperty(G)&&B!==O&&(B!=null||O!=null))if(G==="style")if(O){for(x in O)!O.hasOwnProperty(x)||B&&B.hasOwnProperty(x)||(l||(l={}),l[x]="");for(x in B)B.hasOwnProperty(x)&&O[x]!==B[x]&&(l||(l={}),l[x]=B[x])}else l||(y||(y=[]),y.push(G,l)),l=B;else G==="dangerouslySetInnerHTML"?(B=B?B.__html:void 0,O=O?O.__html:void 0,B!=null&&O!==B&&(y=y||[]).push(G,B)):G==="children"?typeof B!="string"&&typeof B!="number"||(y=y||[]).push(G,""+B):G!=="suppressContentEditableWarning"&&G!=="suppressHydrationWarning"&&(o.hasOwnProperty(G)?(B!=null&&G==="onScroll"&&lt("scroll",i),y||O===B||(y=[])):(y=y||[]).push(G,B))}l&&(y=y||[]).push("style",l);var G=y;(s.updateQueue=G)&&(s.flags|=4)}},X2=function(i,s,l,f){l!==f&&(s.flags|=4)};function Wa(i,s){if(!pt)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 f=null;l!==null;)l.alternate!==null&&(f=l),l=l.sibling;f===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:f.sibling=null}}function Xt(i){var s=i.alternate!==null&&i.alternate.child===i.child,l=0,f=0;if(s)for(var g=i.child;g!==null;)l|=g.lanes|g.childLanes,f|=g.subtreeFlags&14680064,f|=g.flags&14680064,g.return=i,g=g.sibling;else for(g=i.child;g!==null;)l|=g.lanes|g.childLanes,f|=g.subtreeFlags,f|=g.flags,g.return=i,g=g.sibling;return i.subtreeFlags|=f,i.childLanes=l,s}function rM(i,s,l){var f=s.pendingProps;switch(Jh(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Xt(s),null;case 1:return gn(s.type)&&ql(),Xt(s),null;case 3:return f=s.stateNode,fs(),ct(mn),ct(Kt),dp(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(i===null||i.child===null)&&(Jl(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,er!==null&&(zp(er),er=null))),Op(i,s),Xt(s),null;case 5:lp(s);var g=Zi(za.current);if(l=s.type,i!==null&&s.stateNode!=null)Q2(i,s,l,f,g),i.ref!==s.ref&&(s.flags|=512,s.flags|=2097152);else{if(!f){if(s.stateNode===null)throw Error(n(166));return Xt(s),null}if(i=Zi(xr.current),Jl(s)){f=s.stateNode,l=s.type;var y=s.memoizedProps;switch(f[br]=s,f[Ma]=y,i=(s.mode&1)!==0,l){case"dialog":lt("cancel",f),lt("close",f);break;case"iframe":case"object":case"embed":lt("load",f);break;case"video":case"audio":for(g=0;g<Pa.length;g++)lt(Pa[g],f);break;case"source":lt("error",f);break;case"img":case"image":case"link":lt("error",f),lt("load",f);break;case"details":lt("toggle",f);break;case"input":ha(f,y),lt("invalid",f);break;case"select":f._wrapperState={wasMultiple:!!y.multiple},lt("invalid",f);break;case"textarea":xl(f,y),lt("invalid",f)}zt(l,y),g=null;for(var x in y)if(y.hasOwnProperty(x)){var O=y[x];x==="children"?typeof O=="string"?f.textContent!==O&&(y.suppressHydrationWarning!==!0&&Vl(f.textContent,O,i),g=["children",O]):typeof O=="number"&&f.textContent!==""+O&&(y.suppressHydrationWarning!==!0&&Vl(f.textContent,O,i),g=["children",""+O]):o.hasOwnProperty(x)&&O!=null&&x==="onScroll"&&lt("scroll",f)}switch(l){case"input":pn(f),bl(f,y,!0);break;case"textarea":pn(f),wl(f);break;case"select":case"option":break;default:typeof y.onClick=="function"&&(f.onclick=Yl)}f=g,s.updateQueue=f,f!==null&&(s.flags|=4)}else{x=g.nodeType===9?g:g.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=Z(l)),i==="http://www.w3.org/1999/xhtml"?l==="script"?(i=x.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof f.is=="string"?i=x.createElement(l,{is:f.is}):(i=x.createElement(l),l==="select"&&(x=i,f.multiple?x.multiple=!0:f.size&&(x.size=f.size))):i=x.createElementNS(i,l),i[br]=s,i[Ma]=f,K2(i,s,!1,!1),s.stateNode=i;e:{switch(x=yr(l,f),l){case"dialog":lt("cancel",i),lt("close",i),g=f;break;case"iframe":case"object":case"embed":lt("load",i),g=f;break;case"video":case"audio":for(g=0;g<Pa.length;g++)lt(Pa[g],i);g=f;break;case"source":lt("error",i),g=f;break;case"img":case"image":case"link":lt("error",i),lt("load",i),g=f;break;case"details":lt("toggle",i),g=f;break;case"input":ha(i,f),g=Xn(i,f),lt("invalid",i);break;case"option":g=f;break;case"select":i._wrapperState={wasMultiple:!!f.multiple},g=S({},f,{value:void 0}),lt("invalid",i);break;case"textarea":xl(i,f),g=ma(i,f),lt("invalid",i);break;default:g=f}zt(l,g),O=g;for(y in O)if(O.hasOwnProperty(y)){var B=O[y];y==="style"?ei(i,B):y==="dangerouslySetInnerHTML"?(B=B?B.__html:void 0,B!=null&&Ye(i,B)):y==="children"?typeof B=="string"?(l!=="textarea"||B!=="")&&Qe(i,B):typeof B=="number"&&Qe(i,""+B):y!=="suppressContentEditableWarning"&&y!=="suppressHydrationWarning"&&y!=="autoFocus"&&(o.hasOwnProperty(y)?B!=null&&y==="onScroll"&&lt("scroll",i):B!=null&&R(i,y,B,x))}switch(l){case"input":pn(i),bl(i,f,!1);break;case"textarea":pn(i),wl(i);break;case"option":f.value!=null&&i.setAttribute("value",""+Se(f.value));break;case"select":i.multiple=!!f.multiple,y=f.value,y!=null?Zr(i,!!f.multiple,y,!1):f.defaultValue!=null&&Zr(i,!!f.multiple,f.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=Yl)}switch(l){case"button":case"input":case"select":case"textarea":f=!!f.autoFocus;break e;case"img":f=!0;break e;default:f=!1}}f&&(s.flags|=4)}s.ref!==null&&(s.flags|=512,s.flags|=2097152)}return Xt(s),null;case 6:if(i&&s.stateNode!=null)X2(i,s,i.memoizedProps,f);else{if(typeof f!="string"&&s.stateNode===null)throw Error(n(166));if(l=Zi(za.current),Zi(xr.current),Jl(s)){if(f=s.stateNode,l=s.memoizedProps,f[br]=s,(y=f.nodeValue!==l)&&(i=Cn,i!==null))switch(i.tag){case 3:Vl(f.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Vl(f.nodeValue,l,(i.mode&1)!==0)}y&&(s.flags|=4)}else f=(l.nodeType===9?l:l.ownerDocument).createTextNode(f),f[br]=s,s.stateNode=f}return Xt(s),null;case 13:if(ct(mt),f=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(pt&&kn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)e2(),us(),s.flags|=98560,y=!1;else if(y=Jl(s),f!==null&&f.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[br]=s}else us(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;Xt(s),y=!1}else er!==null&&(zp(er),er=null),y=!0;if(!y)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=l,s):(f=f!==null,f!==(i!==null&&i.memoizedState!==null)&&f&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(mt.current&1)!==0?It===0&&(It=3):Vp())),s.updateQueue!==null&&(s.flags|=4),Xt(s),null);case 4:return fs(),Op(i,s),i===null&&La(s.stateNode.containerInfo),Xt(s),null;case 10:return ip(s.type._context),Xt(s),null;case 17:return gn(s.type)&&ql(),Xt(s),null;case 19:if(ct(mt),y=s.memoizedState,y===null)return Xt(s),null;if(f=(s.flags&128)!==0,x=y.rendering,x===null)if(f)Wa(y,!1);else{if(It!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(x=ic(i),x!==null){for(s.flags|=128,Wa(y,!1),f=x.updateQueue,f!==null&&(s.updateQueue=f,s.flags|=4),s.subtreeFlags=0,f=l,l=s.child;l!==null;)y=l,i=f,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 at(mt,mt.current&1|2),s.child}i=i.sibling}y.tail!==null&&_t()>gs&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304)}else{if(!f)if(i=ic(x),i!==null){if(s.flags|=128,f=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),Wa(y,!0),y.tail===null&&y.tailMode==="hidden"&&!x.alternate&&!pt)return Xt(s),null}else 2*_t()-y.renderingStartTime>gs&&l!==1073741824&&(s.flags|=128,f=!0,Wa(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=_t(),s.sibling=null,l=mt.current,at(mt,f?l&1|2:l&1),s):(Xt(s),null);case 22:case 23:return $p(),f=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==f&&(s.flags|=8192),f&&(s.mode&1)!==0?(Nn&1073741824)!==0&&(Xt(s),s.subtreeFlags&6&&(s.flags|=8192)):Xt(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function iM(i,s){switch(Jh(s),s.tag){case 1:return gn(s.type)&&ql(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return fs(),ct(mn),ct(Kt),dp(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return lp(s),null;case 13:if(ct(mt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));us()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ct(mt),null;case 4:return fs(),null;case 10:return ip(s.type._context),null;case 22:case 23:return $p(),null;case 24:return null;default:return null}}var hc=!1,Jt=!1,oM=typeof WeakSet=="function"?WeakSet:Set,we=null;function ps(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(f){yt(i,s,f)}else l.current=null}function Ip(i,s,l){try{l()}catch(f){yt(i,s,f)}}var J2=!1;function sM(i,s){if($h=Pl,i=Ob(),Dh(i)){if("selectionStart"in i)var l={start:i.selectionStart,end:i.selectionEnd};else e:{l=(l=i.ownerDocument)&&l.defaultView||window;var f=l.getSelection&&l.getSelection();if(f&&f.rangeCount!==0){l=f.anchorNode;var g=f.anchorOffset,y=f.focusNode;f=f.focusOffset;try{l.nodeType,y.nodeType}catch(Ee){l=null;break e}var x=0,O=-1,B=-1,G=0,se=0,de=i,re=null;t:for(;;){for(var _e;de!==l||g!==0&&de.nodeType!==3||(O=x+g),de!==y||f!==0&&de.nodeType!==3||(B=x+f),de.nodeType===3&&(x+=de.nodeValue.length),(_e=de.firstChild)!==null;)re=de,de=_e;for(;;){if(de===i)break t;if(re===l&&++G===g&&(O=x),re===y&&++se===f&&(B=x),(_e=de.nextSibling)!==null)break;de=re,re=de.parentNode}de=_e}l=O===-1||B===-1?null:{start:O,end:B}}else l=null}l=l||{start:0,end:0}}else l=null;for(Vh={focusedElem:i,selectionRange:l},Pl=!1,we=s;we!==null;)if(s=we,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,we=i;else for(;we!==null;){s=we;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 Ce=Ae.memoizedProps,wt=Ae.memoizedState,V=s.stateNode,H=V.getSnapshotBeforeUpdate(s.elementType===s.type?Ce:tr(s.type,Ce),wt);V.__reactInternalSnapshotBeforeUpdate=H}break;case 3:var W=s.stateNode.containerInfo;W.nodeType===1?W.textContent="":W.nodeType===9&&W.documentElement&&W.removeChild(W.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(Ee){yt(s,s.return,Ee)}if(i=s.sibling,i!==null){i.return=s.return,we=i;break}we=s.return}return Ae=J2,J2=!1,Ae}function qa(i,s,l){var f=s.updateQueue;if(f=f!==null?f.lastEffect:null,f!==null){var g=f=f.next;do{if((g.tag&i)===i){var y=g.destroy;g.destroy=void 0,y!==void 0&&Ip(s,l,y)}g=g.next}while(g!==f)}}function pc(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 f=l.create;l.destroy=f()}l=l.next}while(l!==s)}}function Rp(i){var s=i.ref;if(s!==null){var l=i.stateNode;i.tag,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[br],delete s[Ma],delete s[Gh],delete s[j8],delete s[$8])),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 ex(i){return i.tag===5||i.tag===3||i.tag===4}function tx(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||ex(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 Pp(i,s,l){var f=i.tag;if(f===5||f===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=Yl));else if(f!==4&&(i=i.child,i!==null))for(Pp(i,s,l),i=i.sibling;i!==null;)Pp(i,s,l),i=i.sibling}function Lp(i,s,l){var f=i.tag;if(f===5||f===6)i=i.stateNode,s?l.insertBefore(i,s):l.appendChild(i);else if(f!==4&&(i=i.child,i!==null))for(Lp(i,s,l),i=i.sibling;i!==null;)Lp(i,s,l),i=i.sibling}var jt=null,nr=!1;function hi(i,s,l){for(l=l.child;l!==null;)nx(i,s,l),l=l.sibling}function nx(i,s,l){if(Tr&&typeof Tr.onCommitFiberUnmount=="function")try{Tr.onCommitFiberUnmount(Cl,l)}catch(O){}switch(l.tag){case 5:Jt||ps(l,s);case 6:var f=jt,g=nr;jt=null,hi(i,s,l),jt=f,nr=g,jt!==null&&(nr?(i=jt,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):jt.removeChild(l.stateNode));break;case 18:jt!==null&&(nr?(i=jt,l=l.stateNode,i.nodeType===8?qh(i.parentNode,l):i.nodeType===1&&qh(i,l),Aa(i)):qh(jt,l.stateNode));break;case 4:f=jt,g=nr,jt=l.stateNode.containerInfo,nr=!0,hi(i,s,l),jt=f,nr=g;break;case 0:case 11:case 14:case 15:if(!Jt&&(f=l.updateQueue,f!==null&&(f=f.lastEffect,f!==null))){g=f=f.next;do{var y=g,x=y.destroy;y=y.tag,x!==void 0&&((y&2)!==0||(y&4)!==0)&&Ip(l,s,x),g=g.next}while(g!==f)}hi(i,s,l);break;case 1:if(!Jt&&(ps(l,s),f=l.stateNode,typeof f.componentWillUnmount=="function"))try{f.props=l.memoizedProps,f.state=l.memoizedState,f.componentWillUnmount()}catch(O){yt(l,s,O)}hi(i,s,l);break;case 21:hi(i,s,l);break;case 22:l.mode&1?(Jt=(f=Jt)||l.memoizedState!==null,hi(i,s,l),Jt=f):hi(i,s,l);break;default:hi(i,s,l)}}function rx(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new oM),s.forEach(function(f){var g=mM.bind(null,i,f);l.has(f)||(l.add(f),f.then(g,g))})}}function rr(i,s){var l=s.deletions;if(l!==null)for(var f=0;f<l.length;f++){var g=l[f];try{var y=i,x=s,O=x;e:for(;O!==null;){switch(O.tag){case 5:jt=O.stateNode,nr=!1;break e;case 3:jt=O.stateNode.containerInfo,nr=!0;break e;case 4:jt=O.stateNode.containerInfo,nr=!0;break e}O=O.return}if(jt===null)throw Error(n(160));nx(y,x,g),jt=null,nr=!1;var B=g.alternate;B!==null&&(B.return=null),g.return=null}catch(G){yt(g,s,G)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)ix(s,i),s=s.sibling}function ix(i,s){var l=i.alternate,f=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(rr(s,i),wr(i),f&4){try{qa(3,i,i.return),pc(3,i)}catch(Ce){yt(i,i.return,Ce)}try{qa(5,i,i.return)}catch(Ce){yt(i,i.return,Ce)}}break;case 1:rr(s,i),wr(i),f&512&&l!==null&&ps(l,l.return);break;case 5:if(rr(s,i),wr(i),f&512&&l!==null&&ps(l,l.return),i.flags&32){var g=i.stateNode;try{Qe(g,"")}catch(Ce){yt(i,i.return,Ce)}}if(f&4&&(g=i.stateNode,g!=null)){var y=i.memoizedProps,x=l!==null?l.memoizedProps:y,O=i.type,B=i.updateQueue;if(i.updateQueue=null,B!==null)try{O==="input"&&y.type==="radio"&&y.name!=null&&pa(g,y),yr(O,x);var G=yr(O,y);for(x=0;x<B.length;x+=2){var se=B[x],de=B[x+1];se==="style"?ei(g,de):se==="dangerouslySetInnerHTML"?Ye(g,de):se==="children"?Qe(g,de):R(g,se,de,G)}switch(O){case"input":Wo(g,y);break;case"textarea":_l(g,y);break;case"select":var re=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!y.multiple;var _e=y.value;_e!=null?Zr(g,!!y.multiple,_e,!1):re!==!!y.multiple&&(y.defaultValue!=null?Zr(g,!!y.multiple,y.defaultValue,!0):Zr(g,!!y.multiple,y.multiple?[]:"",!1))}g[Ma]=y}catch(Ce){yt(i,i.return,Ce)}}break;case 6:if(rr(s,i),wr(i),f&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,y=i.memoizedProps;try{g.nodeValue=y}catch(Ce){yt(i,i.return,Ce)}}break;case 3:if(rr(s,i),wr(i),f&4&&l!==null&&l.memoizedState.isDehydrated)try{Aa(s.containerInfo)}catch(Ce){yt(i,i.return,Ce)}break;case 4:rr(s,i),wr(i);break;case 13:rr(s,i),wr(i),g=i.child,g.flags&8192&&(y=g.memoizedState!==null,g.stateNode.isHidden=y,!y||g.alternate!==null&&g.alternate.memoizedState!==null||(Fp=_t())),f&4&&rx(i);break;case 22:if(se=l!==null&&l.memoizedState!==null,i.mode&1?(Jt=(G=Jt)||se,rr(s,i),Jt=G):rr(s,i),wr(i),f&8192){if(G=i.memoizedState!==null,(i.stateNode.isHidden=G)&&!se&&(i.mode&1)!==0)for(we=i,se=i.child;se!==null;){for(de=we=se;we!==null;){switch(re=we,_e=re.child,re.tag){case 0:case 11:case 14:case 15:qa(4,re,re.return);break;case 1:ps(re,re.return);var Ae=re.stateNode;if(typeof Ae.componentWillUnmount=="function"){f=re,l=re.return;try{s=f,Ae.props=s.memoizedProps,Ae.state=s.memoizedState,Ae.componentWillUnmount()}catch(Ce){yt(f,l,Ce)}}break;case 5:ps(re,re.return);break;case 22:if(re.memoizedState!==null){ax(de);continue}}_e!==null?(_e.return=re,we=_e):ax(de)}se=se.sibling}e:for(se=null,de=i;;){if(de.tag===5){if(se===null){se=de;try{g=de.stateNode,G?(y=g.style,typeof y.setProperty=="function"?y.setProperty("display","none","important"):y.display="none"):(O=de.stateNode,B=de.memoizedProps.style,x=B!=null&&B.hasOwnProperty("display")?B.display:null,O.style.display=Mn("display",x))}catch(Ce){yt(i,i.return,Ce)}}}else if(de.tag===6){if(se===null)try{de.stateNode.nodeValue=G?"":de.memoizedProps}catch(Ce){yt(i,i.return,Ce)}}else if((de.tag!==22&&de.tag!==23||de.memoizedState===null||de===i)&&de.child!==null){de.child.return=de,de=de.child;continue}if(de===i)break e;for(;de.sibling===null;){if(de.return===null||de.return===i)break e;se===de&&(se=null),de=de.return}se===de&&(se=null),de.sibling.return=de.return,de=de.sibling}}break;case 19:rr(s,i),wr(i),f&4&&rx(i);break;case 21:break;default:rr(s,i),wr(i)}}function wr(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(ex(l)){var f=l;break e}l=l.return}throw Error(n(160))}switch(f.tag){case 5:var g=f.stateNode;f.flags&32&&(Qe(g,""),f.flags&=-33);var y=tx(i);Lp(i,y,g);break;case 3:case 4:var x=f.stateNode.containerInfo,O=tx(i);Pp(i,O,x);break;default:throw Error(n(161))}}catch(B){yt(i,i.return,B)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function aM(i,s,l){we=i,ox(i)}function ox(i,s,l){for(var f=(i.mode&1)!==0;we!==null;){var g=we,y=g.child;if(g.tag===22&&f){var x=g.memoizedState!==null||hc;if(!x){var O=g.alternate,B=O!==null&&O.memoizedState!==null||Jt;O=hc;var G=Jt;if(hc=x,(Jt=B)&&!G)for(we=g;we!==null;)x=we,B=x.child,x.tag===22&&x.memoizedState!==null?ux(g):B!==null?(B.return=x,we=B):ux(g);for(;y!==null;)we=y,ox(y),y=y.sibling;we=g,hc=O,Jt=G}sx(i)}else(g.subtreeFlags&8772)!==0&&y!==null?(y.return=g,we=y):sx(i)}}function sx(i){for(;we!==null;){var s=we;if((s.flags&8772)!==0){var l=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:Jt||pc(5,s);break;case 1:var f=s.stateNode;if(s.flags&4&&!Jt)if(l===null)f.componentDidMount();else{var g=s.elementType===s.type?l.memoizedProps:tr(s.type,l.memoizedProps);f.componentDidUpdate(g,l.memoizedState,f.__reactInternalSnapshotBeforeUpdate)}var y=s.updateQueue;y!==null&&a2(s,y,f);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}a2(s,x,l)}break;case 5:var O=s.stateNode;if(l===null&&s.flags&4){l=O;var B=s.memoizedProps;switch(s.type){case"button":case"input":case"select":case"textarea":B.autoFocus&&l.focus();break;case"img":B.src&&(l.src=B.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(s.memoizedState===null){var G=s.alternate;if(G!==null){var se=G.memoizedState;if(se!==null){var de=se.dehydrated;de!==null&&Aa(de)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Jt||s.flags&512&&Rp(s)}catch(re){yt(s,s.return,re)}}if(s===i){we=null;break}if(l=s.sibling,l!==null){l.return=s.return,we=l;break}we=s.return}}function ax(i){for(;we!==null;){var s=we;if(s===i){we=null;break}var l=s.sibling;if(l!==null){l.return=s.return,we=l;break}we=s.return}}function ux(i){for(;we!==null;){var s=we;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{pc(4,s)}catch(B){yt(s,l,B)}break;case 1:var f=s.stateNode;if(typeof f.componentDidMount=="function"){var g=s.return;try{f.componentDidMount()}catch(B){yt(s,g,B)}}var y=s.return;try{Rp(s)}catch(B){yt(s,y,B)}break;case 5:var x=s.return;try{Rp(s)}catch(B){yt(s,x,B)}}}catch(B){yt(s,s.return,B)}if(s===i){we=null;break}var O=s.sibling;if(O!==null){O.return=s.return,we=O;break}we=s.return}}var uM=Math.ceil,mc=F.ReactCurrentDispatcher,Dp=F.ReactCurrentOwner,zn=F.ReactCurrentBatchConfig,Xe=0,Bt=null,Ct=null,$t=0,Nn=0,ms=ui(0),It=0,Ga=null,to=0,gc=0,Mp=0,Ka=null,yn=null,Fp=0,gs=1/0,Ur=null,Ec=!1,Bp=null,pi=null,yc=!1,mi=null,Tc=0,Qa=0,Up=null,bc=-1,xc=0;function rn(){return(Xe&6)!==0?_t():bc!==-1?bc:bc=_t()}function gi(i){return(i.mode&1)===0?1:(Xe&2)!==0&&$t!==0?$t&-$t:Y8.transition!==null?(xc===0&&(xc=tb()),xc):(i=nt,i!==0||(i=window.event,i=i===void 0?16:cb(i.type)),i)}function ir(i,s,l,f){if(50<Qa)throw Qa=0,Up=null,Error(n(185));ba(i,l,f),((Xe&2)===0||i!==Bt)&&(i===Bt&&((Xe&2)===0&&(gc|=l),It===4&&Ei(i,$t)),Tn(i,f),l===1&&Xe===0&&(s.mode&1)===0&&(gs=_t()+500,Kl&&ci()))}function Tn(i,s){var l=i.callbackNode;Y5(i,s);var f=Ol(i,i===Bt?$t:0);if(f===0)l!==null&&JT(l),i.callbackNode=null,i.callbackPriority=0;else if(s=f&-f,i.callbackPriority!==s){if(l!=null&&JT(l),s===1)i.tag===0?V8(cx.bind(null,i)):Kb(cx.bind(null,i)),H8(function(){(Xe&6)===0&&ci()}),l=null;else{switch(nb(f)){case 1:l=yh;break;case 4:l=ZT;break;case 16:l=vl;break;case 536870912:l=eb;break;default:l=vl}l=yx(l,lx.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function lx(i,s){if(bc=-1,xc=0,(Xe&6)!==0)throw Error(n(327));var l=i.callbackNode;if(Es()&&i.callbackNode!==l)return null;var f=Ol(i,i===Bt?$t:0);if(f===0)return null;if((f&30)!==0||(f&i.expiredLanes)!==0||s)s=_c(i,f);else{s=f;var g=Xe;Xe|=2;var y=fx();(Bt!==i||$t!==s)&&(Ur=null,gs=_t()+500,ro(i,s));do try{dM();break}catch(O){dx(i,O)}while(!0);rp(),mc.current=y,Xe=g,Ct!==null?s=0:(Bt=null,$t=0,s=It)}if(s!==0){if(s===2&&(g=Th(i),g!==0&&(f=g,s=Hp(i,g))),s===1)throw l=Ga,ro(i,0),Ei(i,f),Tn(i,_t()),l;if(s===6)Ei(i,f);else{if(g=i.current.alternate,(f&30)===0&&!lM(g)&&(s=_c(i,f),s===2&&(y=Th(i),y!==0&&(f=y,s=Hp(i,y))),s===1))throw l=Ga,ro(i,0),Ei(i,f),Tn(i,_t()),l;switch(i.finishedWork=g,i.finishedLanes=f,s){case 0:case 1:throw Error(n(345));case 2:io(i,yn,Ur);break;case 3:if(Ei(i,f),(f&130023424)===f&&(s=Fp+500-_t(),10<s)){if(Ol(i,0)!==0)break;if(g=i.suspendedLanes,(g&f)!==f){rn(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=Wh(io.bind(null,i,yn,Ur),s);break}io(i,yn,Ur);break;case 4:if(Ei(i,f),(f&4194240)===f)break;for(s=i.eventTimes,g=-1;0<f;){var x=31-Jn(f);y=1<<x,x=s[x],x>g&&(g=x),f&=~y}if(f=g,f=_t()-f,f=(120>f?120:480>f?480:1080>f?1080:1920>f?1920:3e3>f?3e3:4320>f?4320:1960*uM(f/1960))-f,10<f){i.timeoutHandle=Wh(io.bind(null,i,yn,Ur),f);break}io(i,yn,Ur);break;case 5:io(i,yn,Ur);break;default:throw Error(n(329))}}}return Tn(i,_t()),i.callbackNode===l?lx.bind(null,i):null}function Hp(i,s){var l=Ka;return i.current.memoizedState.isDehydrated&&(ro(i,s).flags|=256),i=_c(i,s),i!==2&&(s=yn,yn=l,s!==null&&zp(s)),i}function zp(i){yn===null?yn=i:yn.push.apply(yn,i)}function lM(i){for(var s=i;;){if(s.flags&16384){var l=s.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var f=0;f<l.length;f++){var g=l[f],y=g.getSnapshot;g=g.value;try{if(!Zn(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 Ei(i,s){for(s&=~Mp,s&=~gc,i.suspendedLanes|=s,i.pingedLanes&=~s,i=i.expirationTimes;0<s;){var l=31-Jn(s),f=1<<l;i[l]=-1,s&=~f}}function cx(i){if((Xe&6)!==0)throw Error(n(327));Es();var s=Ol(i,0);if((s&1)===0)return Tn(i,_t()),null;var l=_c(i,s);if(i.tag!==0&&l===2){var f=Th(i);f!==0&&(s=f,l=Hp(i,f))}if(l===1)throw l=Ga,ro(i,0),Ei(i,s),Tn(i,_t()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,io(i,yn,Ur),Tn(i,_t()),null}function jp(i,s){var l=Xe;Xe|=1;try{return i(s)}finally{Xe=l,Xe===0&&(gs=_t()+500,Kl&&ci())}}function no(i){mi!==null&&mi.tag===0&&(Xe&6)===0&&Es();var s=Xe;Xe|=1;var l=zn.transition,f=nt;try{if(zn.transition=null,nt=1,i)return i()}finally{nt=f,zn.transition=l,Xe=s,(Xe&6)===0&&ci()}}function $p(){Nn=ms.current,ct(ms)}function ro(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,U8(l)),Ct!==null)for(l=Ct.return;l!==null;){var f=l;switch(Jh(f),f.tag){case 1:f=f.type.childContextTypes,f!=null&&ql();break;case 3:fs(),ct(mn),ct(Kt),dp();break;case 5:lp(f);break;case 4:fs();break;case 13:ct(mt);break;case 19:ct(mt);break;case 10:ip(f.type._context);break;case 22:case 23:$p()}l=l.return}if(Bt=i,Ct=i=yi(i.current,null),$t=Nn=s,It=0,Ga=null,Mp=gc=to=0,yn=Ka=null,Ji!==null){for(s=0;s<Ji.length;s++)if(l=Ji[s],f=l.interleaved,f!==null){l.interleaved=null;var g=f.next,y=l.pending;if(y!==null){var x=y.next;y.next=g,f.next=x}l.pending=f}Ji=null}return i}function dx(i,s){do{var l=Ct;try{if(rp(),oc.current=lc,sc){for(var f=gt.memoizedState;f!==null;){var g=f.queue;g!==null&&(g.pending=null),f=f.next}sc=!1}if(eo=0,Ft=Ot=gt=null,ja=!1,$a=0,Dp.current=null,l===null||l.return===null){It=1,Ga=s,Ct=null;break}e:{var y=i,x=l.return,O=l,B=s;if(s=$t,O.flags|=32768,B!==null&&typeof B=="object"&&typeof B.then=="function"){var G=B,se=O,de=se.tag;if((se.mode&1)===0&&(de===0||de===11||de===15)){var re=se.alternate;re?(se.updateQueue=re.updateQueue,se.memoizedState=re.memoizedState,se.lanes=re.lanes):(se.updateQueue=null,se.memoizedState=null)}var _e=M2(x);if(_e!==null){_e.flags&=-257,F2(_e,x,O,y,s),_e.mode&1&&D2(y,G,s),s=_e,B=G;var Ae=s.updateQueue;if(Ae===null){var Ce=new Set;Ce.add(B),s.updateQueue=Ce}else Ae.add(B);break e}else{if((s&1)===0){D2(y,G,s),Vp();break e}B=Error(n(426))}}else if(pt&&O.mode&1){var wt=M2(x);if(wt!==null){(wt.flags&65536)===0&&(wt.flags|=256),F2(wt,x,O,y,s),tp(hs(B,O));break e}}y=B=hs(B,O),It!==4&&(It=2),Ka===null?Ka=[y]:Ka.push(y),y=x;do{switch(y.tag){case 3:y.flags|=65536,s&=-s,y.lanes|=s;var V=P2(y,B,s);s2(y,V);break e;case 1:O=B;var H=y.type,W=y.stateNode;if((y.flags&128)===0&&(typeof H.getDerivedStateFromError=="function"||W!==null&&typeof W.componentDidCatch=="function"&&(pi===null||!pi.has(W)))){y.flags|=65536,s&=-s,y.lanes|=s;var Ee=L2(y,O,s);s2(y,Ee);break e}}y=y.return}while(y!==null)}px(l)}catch(ke){s=ke,Ct===l&&l!==null&&(Ct=l=l.return);continue}break}while(!0)}function fx(){var i=mc.current;return mc.current=lc,i===null?lc:i}function Vp(){(It===0||It===3||It===2)&&(It=4),Bt===null||(to&268435455)===0&&(gc&268435455)===0||Ei(Bt,$t)}function _c(i,s){var l=Xe;Xe|=2;var f=fx();(Bt!==i||$t!==s)&&(Ur=null,ro(i,s));do try{cM();break}catch(g){dx(i,g)}while(!0);if(rp(),Xe=l,mc.current=f,Ct!==null)throw Error(n(261));return Bt=null,$t=0,It}function cM(){for(;Ct!==null;)hx(Ct)}function dM(){for(;Ct!==null&&!M5();)hx(Ct)}function hx(i){var s=Ex(i.alternate,i,Nn);i.memoizedProps=i.pendingProps,s===null?px(i):Ct=s,Dp.current=null}function px(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=rM(l,s,Nn),l!==null){Ct=l;return}}else{if(l=iM(l,s),l!==null){l.flags&=32767,Ct=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{It=6,Ct=null;return}}if(s=s.sibling,s!==null){Ct=s;return}Ct=s=i}while(s!==null);It===0&&(It=5)}function io(i,s,l){var f=nt,g=zn.transition;try{zn.transition=null,nt=1,fM(i,s,l,f)}finally{zn.transition=g,nt=f}return null}function fM(i,s,l,f){do Es();while(mi!==null);if((Xe&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(W5(i,y),i===Bt&&(Ct=Bt=null,$t=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||yc||(yc=!0,yx(vl,function(){return Es(),null})),y=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||y){y=zn.transition,zn.transition=null;var x=nt;nt=1;var O=Xe;Xe|=4,Dp.current=null,sM(i,l),ix(l,i),R8(Vh),Pl=!!$h,Vh=$h=null,i.current=l,aM(l),F5(),Xe=O,nt=x,zn.transition=y}else i.current=l;if(yc&&(yc=!1,mi=i,Tc=g),y=i.pendingLanes,y===0&&(pi=null),H5(l.stateNode),Tn(i,_t()),s!==null)for(f=i.onRecoverableError,l=0;l<s.length;l++)g=s[l],f(g.value,{componentStack:g.stack,digest:g.digest});if(Ec)throw Ec=!1,i=Bp,Bp=null,i;return(Tc&1)!==0&&i.tag!==0&&Es(),y=i.pendingLanes,(y&1)!==0?i===Up?Qa++:(Qa=0,Up=i):Qa=0,ci(),null}function Es(){if(mi!==null){var i=nb(Tc),s=zn.transition,l=nt;try{if(zn.transition=null,nt=16>i?16:i,mi===null)var f=!1;else{if(i=mi,mi=null,Tc=0,(Xe&6)!==0)throw Error(n(331));var g=Xe;for(Xe|=4,we=i.current;we!==null;){var y=we,x=y.child;if((we.flags&16)!==0){var O=y.deletions;if(O!==null){for(var B=0;B<O.length;B++){var G=O[B];for(we=G;we!==null;){var se=we;switch(se.tag){case 0:case 11:case 15:qa(8,se,y)}var de=se.child;if(de!==null)de.return=se,we=de;else for(;we!==null;){se=we;var re=se.sibling,_e=se.return;if(Z2(se),se===G){we=null;break}if(re!==null){re.return=_e,we=re;break}we=_e}}}var Ae=y.alternate;if(Ae!==null){var Ce=Ae.child;if(Ce!==null){Ae.child=null;do{var wt=Ce.sibling;Ce.sibling=null,Ce=wt}while(Ce!==null)}}we=y}}if((y.subtreeFlags&2064)!==0&&x!==null)x.return=y,we=x;else e:for(;we!==null;){if(y=we,(y.flags&2048)!==0)switch(y.tag){case 0:case 11:case 15:qa(9,y,y.return)}var V=y.sibling;if(V!==null){V.return=y.return,we=V;break e}we=y.return}}var H=i.current;for(we=H;we!==null;){x=we;var W=x.child;if((x.subtreeFlags&2064)!==0&&W!==null)W.return=x,we=W;else e:for(x=H;we!==null;){if(O=we,(O.flags&2048)!==0)try{switch(O.tag){case 0:case 11:case 15:pc(9,O)}}catch(ke){yt(O,O.return,ke)}if(O===x){we=null;break e}var Ee=O.sibling;if(Ee!==null){Ee.return=O.return,we=Ee;break e}we=O.return}}if(Xe=g,ci(),Tr&&typeof Tr.onPostCommitFiberRoot=="function")try{Tr.onPostCommitFiberRoot(Cl,i)}catch(ke){}f=!0}return f}finally{nt=l,zn.transition=s}}return!1}function mx(i,s,l){s=hs(l,s),s=P2(i,s,1),i=fi(i,s,1),s=rn(),i!==null&&(ba(i,1,s),Tn(i,s))}function yt(i,s,l){if(i.tag===3)mx(i,i,l);else for(;s!==null;){if(s.tag===3){mx(s,i,l);break}else if(s.tag===1){var f=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof f.componentDidCatch=="function"&&(pi===null||!pi.has(f))){i=hs(l,i),i=L2(s,i,1),s=fi(s,i,1),i=rn(),s!==null&&(ba(s,1,i),Tn(s,i));break}}s=s.return}}function hM(i,s,l){var f=i.pingCache;f!==null&&f.delete(s),s=rn(),i.pingedLanes|=i.suspendedLanes&l,Bt===i&&($t&l)===l&&(It===4||It===3&&($t&130023424)===$t&&500>_t()-Fp?ro(i,0):Mp|=l),Tn(i,s)}function gx(i,s){s===0&&((i.mode&1)===0?s=1:(s=Nl,Nl<<=1,(Nl&130023424)===0&&(Nl=4194304)));var l=rn();i=Mr(i,s),i!==null&&(ba(i,s,l),Tn(i,l))}function pM(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),gx(i,l)}function mM(i,s){var l=0;switch(i.tag){case 13:var f=i.stateNode,g=i.memoizedState;g!==null&&(l=g.retryLane);break;case 19:f=i.stateNode;break;default:throw Error(n(314))}f!==null&&f.delete(s),gx(i,l)}var Ex;Ex=function(i,s,l){if(i!==null)if(i.memoizedProps!==s.pendingProps||mn.current)En=!0;else{if((i.lanes&l)===0&&(s.flags&128)===0)return En=!1,nM(i,s,l);En=(i.flags&131072)!==0}else En=!1,pt&&(s.flags&1048576)!==0&&Qb(s,Xl,s.index);switch(s.lanes=0,s.tag){case 2:var f=s.type;fc(i,s),i=s.pendingProps;var g=os(s,Kt.current);ds(s,l),g=pp(null,s,f,i,g,l);var y=mp();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,gn(f)?(y=!0,Gl(s)):y=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,ap(s),g.updater=cc,s.stateNode=g,g._reactInternals=s,xp(s,f,i,l),s=Ap(null,s,f,!0,y,l)):(s.tag=0,pt&&y&&Xh(s),nn(null,s,g,l),s=s.child),s;case 16:f=s.elementType;e:{switch(fc(i,s),i=s.pendingProps,g=f._init,f=g(f._payload),s.type=f,g=s.tag=EM(f),i=tr(f,i),g){case 0:s=Sp(null,s,f,i,l);break e;case 1:s=$2(null,s,f,i,l);break e;case 11:s=B2(null,s,f,i,l);break e;case 14:s=U2(null,s,f,tr(f.type,i),l);break e}throw Error(n(306,f,""))}return s;case 0:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),Sp(i,s,f,g,l);case 1:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),$2(i,s,f,g,l);case 3:e:{if(V2(s),i===null)throw Error(n(387));f=s.pendingProps,y=s.memoizedState,g=y.element,o2(i,s),rc(s,f,null,l);var x=s.memoizedState;if(f=x.element,y.isDehydrated)if(y={element:f,isDehydrated:!1,cache:x.cache,pendingSuspenseBoundaries:x.pendingSuspenseBoundaries,transitions:x.transitions},s.updateQueue.baseState=y,s.memoizedState=y,s.flags&256){g=hs(Error(n(423)),s),s=Y2(i,s,f,l,g);break e}else if(f!==g){g=hs(Error(n(424)),s),s=Y2(i,s,f,l,g);break e}else for(kn=ai(s.stateNode.containerInfo.firstChild),Cn=s,pt=!0,er=null,l=r2(s,null,f,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(us(),f===g){s=Br(i,s,l);break e}nn(i,s,f,l)}s=s.child}return s;case 5:return u2(s),i===null&&ep(s),f=s.type,g=s.pendingProps,y=i!==null?i.memoizedProps:null,x=g.children,Yh(f,g)?x=null:y!==null&&Yh(f,y)&&(s.flags|=32),j2(i,s),nn(i,s,x,l),s.child;case 6:return i===null&&ep(s),null;case 13:return W2(i,s,l);case 4:return up(s,s.stateNode.containerInfo),f=s.pendingProps,i===null?s.child=ls(s,null,f,l):nn(i,s,f,l),s.child;case 11:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),B2(i,s,f,g,l);case 7:return nn(i,s,s.pendingProps,l),s.child;case 8:return nn(i,s,s.pendingProps.children,l),s.child;case 12:return nn(i,s,s.pendingProps.children,l),s.child;case 10:e:{if(f=s.type._context,g=s.pendingProps,y=s.memoizedProps,x=g.value,at(ec,f._currentValue),f._currentValue=x,y!==null)if(Zn(y.value,x)){if(y.children===g.children&&!mn.current){s=Br(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 B=O.firstContext;B!==null;){if(B.context===f){if(y.tag===1){B=Fr(-1,l&-l),B.tag=2;var G=y.updateQueue;if(G!==null){G=G.shared;var se=G.pending;se===null?B.next=B:(B.next=se.next,se.next=B),G.pending=B}}y.lanes|=l,B=y.alternate,B!==null&&(B.lanes|=l),op(y.return,l,s),O.lanes|=l;break}B=B.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),op(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}nn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,f=s.pendingProps.children,ds(s,l),g=Un(g),f=f(g),s.flags|=1,nn(i,s,f,l),s.child;case 14:return f=s.type,g=tr(f,s.pendingProps),g=tr(f.type,g),U2(i,s,f,g,l);case 15:return H2(i,s,s.type,s.pendingProps,l);case 17:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),fc(i,s),s.tag=1,gn(f)?(i=!0,Gl(s)):i=!1,ds(s,l),I2(s,f,g),xp(s,f,g,l),Ap(null,s,f,!0,i,l);case 19:return G2(i,s,l);case 22:return z2(i,s,l)}throw Error(n(156,s.tag))};function yx(i,s){return XT(i,s)}function gM(i,s,l,f){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=f,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function jn(i,s,l,f){return new gM(i,s,l,f)}function Yp(i){return i=i.prototype,!(!i||!i.isReactComponent)}function EM(i){if(typeof i=="function")return Yp(i)?1:0;if(i!=null){if(i=i.$$typeof,i===he)return 11;if(i===Te)return 14}return 2}function yi(i,s){var l=i.alternate;return l===null?(l=jn(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 wc(i,s,l,f,g,y){var x=2;if(f=i,typeof i=="function")Yp(i)&&(x=1);else if(typeof i=="string")x=5;else e:switch(i){case q:return oo(l.children,g,y,s);case ce:x=8,g|=8;break;case be:return i=jn(12,l,s,g|2),i.elementType=be,i.lanes=y,i;case ge:return i=jn(13,l,s,g),i.elementType=ge,i.lanes=y,i;case ue:return i=jn(19,l,s,g),i.elementType=ue,i.lanes=y,i;case fe:return Sc(l,g,y,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case j:x=10;break e;case ae:x=9;break e;case he:x=11;break e;case Te:x=14;break e;case Ne:x=16,f=null;break e}throw Error(n(130,i==null?i:typeof i,""))}return s=jn(x,l,s,g),s.elementType=i,s.type=f,s.lanes=y,s}function oo(i,s,l,f){return i=jn(7,i,f,s),i.lanes=l,i}function Sc(i,s,l,f){return i=jn(22,i,f,s),i.elementType=fe,i.lanes=l,i.stateNode={isHidden:!1},i}function Wp(i,s,l){return i=jn(6,i,null,s),i.lanes=l,i}function qp(i,s,l){return s=jn(4,i.children!==null?i.children:[],i.key,s),s.lanes=l,s.stateNode={containerInfo:i.containerInfo,pendingChildren:null,implementation:i.implementation},s}function yM(i,s,l,f,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=bh(0),this.expirationTimes=bh(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=bh(0),this.identifierPrefix=f,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function Gp(i,s,l,f,g,y,x,O,B){return i=new yM(i,s,l,O,B),s===1?(s=1,y===!0&&(s|=8)):s=0,y=jn(3,null,null,s),i.current=y,y.stateNode=i,y.memoizedState={element:f,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},ap(y),i}function TM(i,s,l){var f=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:D,key:f==null?null:""+f,children:i,containerInfo:s,implementation:l}}function Tx(i){if(!i)return li;i=i._reactInternals;e:{if(qi(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(gn(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(gn(l))return qb(i,l,s)}return s}function bx(i,s,l,f,g,y,x,O,B){return i=Gp(l,f,!0,i,g,y,x,O,B),i.context=Tx(null),l=i.current,f=rn(),g=gi(l),y=Fr(f,g),y.callback=s!=null?s:null,fi(l,y,g),i.current.lanes=g,ba(i,g,f),Tn(i,f),i}function Ac(i,s,l,f){var g=s.current,y=rn(),x=gi(g);return l=Tx(l),s.context===null?s.context=l:s.pendingContext=l,s=Fr(y,x),s.payload={element:i},f=f===void 0?null:f,f!==null&&(s.callback=f),i=fi(g,s,x),i!==null&&(ir(i,g,x,y),nc(i,g,x)),x}function vc(i){return i=i.current,i.child?(i.child.tag===5,i.child.stateNode):null}function xx(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function Kp(i,s){xx(i,s),(i=i.alternate)&&xx(i,s)}function bM(){return null}var _x=typeof reportError=="function"?reportError:function(i){console.error(i)};function Qp(i){this._internalRoot=i}Cc.prototype.render=Qp.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Ac(i,s,null,null)},Cc.prototype.unmount=Qp.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;no(function(){Ac(null,i,null,null)}),s[Rr]=null}};function Cc(i){this._internalRoot=i}Cc.prototype.unstable_scheduleHydration=function(i){if(i){var s=ob();i={blockedOn:null,target:i,priority:s};for(var l=0;l<ii.length&&s!==0&&s<ii[l].priority;l++);ii.splice(l,0,i),l===0&&ub(i)}};function Xp(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function kc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function wx(){}function xM(i,s,l,f,g){if(g){if(typeof f=="function"){var y=f;f=function(){var G=vc(x);y.call(G)}}var x=bx(s,f,i,0,null,!1,!1,"",wx);return i._reactRootContainer=x,i[Rr]=x.current,La(i.nodeType===8?i.parentNode:i),no(),x}for(;g=i.lastChild;)i.removeChild(g);if(typeof f=="function"){var O=f;f=function(){var G=vc(B);O.call(G)}}var B=Gp(i,0,!1,null,null,!1,!1,"",wx);return i._reactRootContainer=B,i[Rr]=B.current,La(i.nodeType===8?i.parentNode:i),no(function(){Ac(s,B,l,f)}),B}function Nc(i,s,l,f,g){var y=l._reactRootContainer;if(y){var x=y;if(typeof g=="function"){var O=g;g=function(){var B=vc(x);O.call(B)}}Ac(s,x,i,g)}else x=xM(l,s,i,g,f);return vc(x)}rb=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=Ta(s.pendingLanes);l!==0&&(xh(s,l|1),Tn(s,_t()),(Xe&6)===0&&(gs=_t()+500,ci()))}break;case 13:no(function(){var f=Mr(i,1);if(f!==null){var g=rn();ir(f,i,1,g)}}),Kp(i,1)}},_h=function(i){if(i.tag===13){var s=Mr(i,134217728);if(s!==null){var l=rn();ir(s,i,134217728,l)}Kp(i,134217728)}},ib=function(i){if(i.tag===13){var s=gi(i),l=Mr(i,s);if(l!==null){var f=rn();ir(l,i,s,f)}Kp(i,s)}},ob=function(){return nt},sb=function(i,s){var l=nt;try{return nt=i,s()}finally{nt=l}},ph=function(i,s,l){switch(s){case"input":if(Wo(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 f=l[s];if(f!==i&&f.form===i.form){var g=Wl(f);if(!g)throw Error(n(90));Yi(f),Wo(f,g)}}}break;case"textarea":_l(i,l);break;case"select":s=l.value,s!=null&&Zr(i,!!l.multiple,s,!1)}},VT=jp,YT=no;var _M={usingClientEntryPoint:!1,Events:[Fa,rs,Wl,jT,$T,jp]},Xa={findFiberByHostInstance:Gi,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},wM={bundleType:Xa.bundleType,version:Xa.version,rendererPackageName:Xa.rendererPackageName,rendererConfig:Xa.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:F.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=KT(i),i===null?null:i.stateNode},findFiberByHostInstance:Xa.findFiberByHostInstance||bM,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 Oc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Oc.isDisabled&&Oc.supportsFiber)try{Cl=Oc.inject(wM),Tr=Oc}catch(i){}}return un.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=_M,un.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Xp(s))throw Error(n(200));return TM(i,s,null,l)},un.createRoot=function(i,s){if(!Xp(i))throw Error(n(299));var l=!1,f="",g=_x;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(f=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=Gp(i,1,!1,null,null,l,!1,f,g),i[Rr]=s.current,La(i.nodeType===8?i.parentNode:i),new Qp(s)},un.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=KT(s),i=i===null?null:i.stateNode,i},un.flushSync=function(i){return no(i)},un.hydrate=function(i,s,l){if(!kc(s))throw Error(n(200));return Nc(null,i,s,!0,l)},un.hydrateRoot=function(i,s,l){if(!Xp(i))throw Error(n(405));var f=l!=null&&l.hydratedSources||null,g=!1,y="",x=_x;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(y=l.identifierPrefix),l.onRecoverableError!==void 0&&(x=l.onRecoverableError)),s=bx(s,null,i,1,l!=null?l:null,g,!1,y,x),i[Rr]=s.current,La(i),f)for(i=0;i<f.length;i++)l=f[i],g=l._getVersion,g=g(l._source),s.mutableSourceEagerHydrationData==null?s.mutableSourceEagerHydrationData=[l,g]:s.mutableSourceEagerHydrationData.push(l,g);return new Cc(s)},un.render=function(i,s,l){if(!kc(s))throw Error(n(200));return Nc(null,i,s,!1,l)},un.unmountComponentAtNode=function(i){if(!kc(i))throw Error(n(40));return i._reactRootContainer?(no(function(){Nc(null,null,i,!1,function(){i._reactRootContainer=null,i[Rr]=null})}),!0):!1},un.unstable_batchedUpdates=jp,un.unstable_renderSubtreeIntoContainer=function(i,s,l,f){if(!kc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Nc(i,s,l,!1,f)},un.version="18.3.1-next-f1338f8080-20240426",un}var f0;function h0(){if(f0)return hd.exports;f0=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(),hd.exports=MS(),hd.exports}var ks=h0();function p0(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=p0(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=p0(e))&&(r&&(r+=" "),r+=t);return r}const jr=({className:e,iconUrl:t,icon:n,type:r="button",ariaLabel:o,title:a,disabled:u=!1,onClick:c})=>!n&&!t?null:L.jsx("button",{className:oe(e,`${J}-icon-button`),type:r,"aria-label":o,title:a,onClick:c,disabled:u,children:t?L.jsx("img",{className:oe(`${J}-icon-image`),src:t,alt:o,loading:"lazy"}):n}),FS="data:image/svg+xml,%3csvg%20width='140'%20height='137'%20viewBox='0%200%20140%20137'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M140%2034.5C140%2040.8513%20135.075%2046%20129%2046C122.925%2046%20118%2040.8513%20118%2034.5C118%2028.1487%20122.925%2023%20129%2023C135.075%2023%20140%2028.1487%20140%2034.5Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M85%2011.3028C85%205.06042%2090.1487%200%2096.5%200C102.851%200%20108%205.06042%20108%2011.3028V21.6972C108%2027.9396%20102.851%2033%2096.5%2033C90.1487%2033%2085%2027.9396%2085%2021.6972V11.3028Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M41.3868%2030.0986C36.9601%2025.6719%2036.9601%2018.4948%2041.3868%2014.0682C45.8134%209.64151%2052.9905%209.6415%2057.4172%2014.0682L71.3628%2028.0138C75.7894%2032.4404%2075.7894%2039.6175%2071.3628%2044.0442C66.9361%2048.4708%2059.759%2048.4708%2055.3324%2044.0442L41.3868%2030.0986Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M140%20101C140%2094.9249%20135.075%2090%20129%2090C122.925%2090%20118%2094.9249%20118%20101C118%20107.075%20122.925%20112%20129%20112C135.075%20112%20140%20107.075%20140%20101Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M85%20125.697C85%20131.94%2090.1487%20137%2096.5%20137C102.851%20137%20108%20131.94%20108%20125.697V115.303C108%20109.06%20102.851%20104%2096.5%20104C90.1487%20104%2085%20109.06%2085%20115.303V125.697Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M41.3868%20106.932C36.9601%20111.359%2036.9601%20118.536%2041.3868%20122.963C45.8134%20127.389%2052.9905%20127.39%2057.4172%20122.963L71.3628%20109.017C75.7894%20104.591%2075.7894%2097.4135%2071.3628%2092.9868C66.9361%2088.5602%2059.759%2088.5602%2055.3324%2092.9868L41.3868%20106.932Z'%20fill='%23F3F2EB'/%3e%3cpath%20d='M11.259%2080C5.04084%2080%200%2074.8513%200%2068.5C0%2062.1487%205.04084%2057%2011.259%2057H49.741C55.9592%2057%2061%2062.1487%2061%2068.5C61%2074.8513%2055.9592%2080%2049.741%2080H11.259Z'%20fill='%23F3F2EB'/%3e%3c/svg%3e",BS=()=>{const{globalClassName:e,headerConfig:t,themeVariables:n}=en(),r=()=>{yu(!1),vi(!0)};return ks.createPortal(L.jsx("div",{className:oe(e,`${J}-minimized-container`),style:n,children:L.jsx(jr,{className:oe(e,`${J}-minimized-button`),ariaLabel:"Open Copilot",icon:L.jsx("img",{src:(t==null?void 0:t.logoUrl)||FS,alt:"Copilot",className:oe(e,`${J}-minimized-icon-img`)}),onClick:r})}),document.body)};var m0={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},g0=bi.createContext&&bi.createContext(m0),US=["attr","size","title"];function HS(e,t){if(e==null)return{};var n=zS(e,t),r,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)r=a[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function zS(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 bu(){return bu=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},bu.apply(this,arguments)}function E0(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 xu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?E0(Object(n),!0).forEach(function(r){jS(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function jS(e,t,n){return t=$S(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $S(e){var t=VS(e,"string");return typeof t=="symbol"?t:t+""}function VS(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 y0(e){return e&&e.map((t,n)=>bi.createElement(t.tag,xu({key:n},t.attr),y0(t.child)))}function ln(e){return t=>bi.createElement(YS,bu({attr:xu({},e.attr)},t),y0(e.child))}function YS(e){var t=n=>{var{attr:r,size:o,title:a}=e,u=HS(e,US),c=o||n.size||"1em",d;return n.className&&(d=n.className),e.className&&(d=(d?d+" ":"")+e.className),bi.createElement("svg",bu({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,u,{className:d,style:xu(xu({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&bi.createElement("title",null,a),e.children)};return g0!==void 0?bi.createElement(g0.Consumer,null,n=>t(n)):t(m0)}function WS(e){return ln({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3.5 8a5.5 5.5 0 1 1 8.596 4.547 9.005 9.005 0 0 1 5.9 8.18.751.751 0 0 1-1.5.045 7.5 7.5 0 0 0-14.993 0 .75.75 0 0 1-1.499-.044 9.005 9.005 0 0 1 5.9-8.181A5.496 5.496 0 0 1 3.5 8ZM9 4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Zm8.29 4c-.148 0-.292.01-.434.03a.75.75 0 1 1-.212-1.484 4.53 4.53 0 0 1 3.38 8.097 6.69 6.69 0 0 1 3.956 6.107.75.75 0 0 1-1.5 0 5.193 5.193 0 0 0-3.696-4.972l-.534-.16v-1.676l.41-.209A3.03 3.03 0 0 0 17.29 8Z"},child:[]}]})(e)}function ki(){const e=ee.useContext(i0);if(!e)throw new Error("useMessaging must be used within a MessagingProvider");return e}const qS=e=>({[`${Sr}-header-background-color`]:(e==null?void 0:e.headerBackgroundColor)||"transparent",[`${Sr}-header-text-font-size`]:(e==null?void 0:e.headerTextFontSize)||"1.25rem"});function T0(e){return ln({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M6 19h12v2H6z"},child:[]}]})(e)}function b0(e){return ln({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 GS(e){return ln({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 KS(e){return ln({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 QS(e){return ln({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 x0=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>L.jsx("button",{className:oe(`${J}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),XS=({searchConfig:e,globalClassName:t})=>{const n=e.buttonIconUrl;return n?L.jsx("img",{className:oe(`${J}-search-button-icon-image`,t),src:n,alt:"",loading:"lazy"}):L.jsx(b0,{size:"16px"})},JS=({className:e,searchConfig:t,globalClassName:n,componentType:r,isLoading:o})=>{if((t==null?void 0:t.buttonType)==="icon")return L.jsx(jr,{className:oe(e,n,`cim-${r}-component`,`${J}-search-button-icon`),type:"submit",disabled:o,ariaLabel:(t==null?void 0:t.buttonAriaLabel)||(t==null?void 0:t.buttonLabel)||"Search Copilot",icon:t!=null&&t.buttonIconUrl?null:L.jsx(b0,{size:"16px"}),iconUrl:t==null?void 0:t.buttonIconUrl});const a=(t==null?void 0:t.buttonType)==="icon-text";return L.jsxs(x0,{className:oe(e,n,`cim-${r}-component`,`${J}-search-button`),type:"submit","aria-label":(t==null?void 0:t.buttonAriaLabel)||"",disabled:o,children:[a&&L.jsx(XS,{globalClassName:n,searchConfig:t}),(t==null?void 0:t.buttonLabel)||"Search"]})};function eF(){}function tF(){}function _0(e){const t=[],n=String(e||"");let r=n.indexOf(","),o=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const u=n.slice(o,r).trim();(u||!a)&&t.push(u),o=r+1,r=n.indexOf(",",o)}return t}function w0(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const ZS=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,eA=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,tA={};function S0(e,t){return(tA.jsx?eA:ZS).test(e)}const nA=/[ \t\n\f\r]/g;function rA(e){return typeof e=="object"?e.type==="text"?A0(e.value):!1:A0(e)}function A0(e){return e.replace(nA,"")===""}let Ns=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Ns.prototype.normal={},Ns.prototype.property={},Ns.prototype.space=void 0;function v0(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Ns(n,r,t)}function Os(e){return e.toLowerCase()}let cn=class{constructor(t,n){this.attribute=n,this.property=t}};cn.prototype.attribute="",cn.prototype.booleanish=!1,cn.prototype.boolean=!1,cn.prototype.commaOrSpaceSeparated=!1,cn.prototype.commaSeparated=!1,cn.prototype.defined=!1,cn.prototype.mustUseProperty=!1,cn.prototype.number=!1,cn.prototype.overloadedBoolean=!1,cn.prototype.property="",cn.prototype.spaceSeparated=!1,cn.prototype.space=void 0;let iA=0;const je=Ni(),At=Ni(),gd=Ni(),pe=Ni(),ot=Ni(),ho=Ni(),bn=Ni();function Ni(){return Ja(2,++iA)}const Ed=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:At,commaOrSpaceSeparated:bn,commaSeparated:ho,number:pe,overloadedBoolean:gd,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),yd=Object.keys(Ed);let Td=class extends cn{constructor(t,n,r,o){let a=-1;if(super(t,n),C0(this,"space",o),typeof r=="number")for(;++a<yd.length;){const u=yd[a];C0(this,yd[a],(r&Ed[u])===Ed[u])}}};Td.prototype.defined=!0;function C0(e,t,n){n&&(e[t]=n)}function po(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const a=new Td(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Os(r)]=r,n[Os(a.attribute)]=r}return new Ns(t,n,e.space)}const k0=po({properties:{ariaActiveDescendant:null,ariaAtomic:At,ariaAutoComplete:null,ariaBusy:At,ariaChecked:At,ariaColCount:pe,ariaColIndex:pe,ariaColSpan:pe,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:At,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:At,ariaFlowTo:ot,ariaGrabbed:At,ariaHasPopup:null,ariaHidden:At,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:pe,ariaLive:null,ariaModal:At,ariaMultiLine:At,ariaMultiSelectable:At,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:pe,ariaPressed:At,ariaReadOnly:At,ariaRelevant:null,ariaRequired:At,ariaRoleDescription:ot,ariaRowCount:pe,ariaRowIndex:pe,ariaRowSpan:pe,ariaSelected:At,ariaSetSize:pe,ariaSort:null,ariaValueMax:pe,ariaValueMin:pe,ariaValueNow:pe,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function N0(e,t){return t in e?e[t]:t}function O0(e,t){return N0(e,t.toLowerCase())}const oA=po({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:ho,acceptCharset:ot,accessKey:ot,action:null,allow:null,allowFullScreen:je,allowPaymentRequest:je,allowUserMedia:je,alt:null,as:null,async:je,autoCapitalize:null,autoComplete:ot,autoFocus:je,autoPlay:je,blocking:ot,capture:null,charSet:null,checked:je,cite:null,className:ot,cols:pe,colSpan:null,content:null,contentEditable:At,controls:je,controlsList:ot,coords:pe|ho,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:gd,draggable:At,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:ot,height:pe,hidden:gd,high:pe,href:null,hrefLang:null,htmlFor:ot,httpEquiv:ot,id:null,imageSizes:null,imageSrcSet:null,inert:je,inputMode:null,integrity:null,is:null,isMap:je,itemId:null,itemProp:ot,itemRef:ot,itemScope:je,itemType:ot,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:ot,placeholder:null,playsInline:je,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:je,referrerPolicy:null,rel:ot,required:je,reversed:je,rows:pe,rowSpan:pe,sandbox:ot,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:At,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:At,width:pe,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ot,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:At,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},space:"html",transform:O0}),sA=po({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:bn,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:ot,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:ho,g2:ho,glyphName:ho,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:bn,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:ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:pe,pointsAtY:pe,pointsAtZ:pe,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:bn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:bn,rev:bn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:bn,requiredFeatures:bn,requiredFonts:bn,requiredFormats:bn,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:bn,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:bn,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:bn,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},space:"svg",transform:N0}),I0=po({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()}}),R0=po({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:O0}),P0=po({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),aA={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"},uA=/[A-Z]/g,L0=/-[a-z]/g,lA=/^data[-\w.:]+$/i;function bd(e,t){const n=Os(t);let r=t,o=cn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&lA.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(L0,dA);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!L0.test(a)){let u=a.replace(uA,cA);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Td}return new o(r,t)}function cA(e){return"-"+e.toLowerCase()}function dA(e){return e.charAt(1).toUpperCase()}const _u=v0([k0,oA,I0,R0,P0],"html"),mo=v0([k0,sA,I0,R0,P0],"svg");function D0(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function M0(e){return e.join(" ").trim()}var go={},xd,F0;function fA(){if(F0)return xd;F0=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,a=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,u=/^[;\s]*/,c=/^\s+|\s+$/g,d=`
24
+ `,h="/",m="*",E="",T="comment",b="declaration";xd=function(w,A){if(typeof w!="string")throw new TypeError("First argument must be a string");if(!w)return[];A=A||{};var C=1,I=1;function R(ge){var ue=ge.match(t);ue&&(C+=ue.length);var Te=ge.lastIndexOf(d);I=~Te?ge.length-Te:I+ge.length}function F(){var ge={line:C,column:I};return function(ue){return ue.position=new z(ge),ce(),ue}}function z(ge){this.start=ge,this.end={line:C,column:I},this.source=A.source}z.prototype.content=w;function D(ge){var ue=new Error(A.source+":"+C+":"+I+": "+ge);if(ue.reason=ge,ue.filename=A.source,ue.line=C,ue.column=I,ue.source=w,!A.silent)throw ue}function q(ge){var ue=ge.exec(w);if(ue){var Te=ue[0];return R(Te),w=w.slice(Te.length),ue}}function ce(){q(n)}function be(ge){var ue;for(ge=ge||[];ue=j();)ue!==!1&&ge.push(ue);return ge}function j(){var ge=F();if(!(h!=w.charAt(0)||m!=w.charAt(1))){for(var ue=2;E!=w.charAt(ue)&&(m!=w.charAt(ue)||h!=w.charAt(ue+1));)++ue;if(ue+=2,E===w.charAt(ue-1))return D("End of comment missing");var Te=w.slice(2,ue-2);return I+=2,R(Te),w=w.slice(ue),I+=2,ge({type:T,comment:Te})}}function ae(){var ge=F(),ue=q(r);if(ue){if(j(),!q(o))return D("property missing ':'");var Te=q(a),Ne=ge({type:b,property:_(ue[0].replace(e,E)),value:Te?_(Te[0].replace(e,E)):E});return q(u),Ne}}function he(){var ge=[];be(ge);for(var ue;ue=ae();)ue!==!1&&(ge.push(ue),be(ge));return ge}return ce(),he()};function _(w){return w?w.replace(c,E):E}return xd}var B0;function hA(){if(B0)return go;B0=1;var e=go&&go.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(go,"__esModule",{value:!0}),go.default=n;var t=e(fA());function n(r,o){var a=null;if(!r||typeof r!="string")return a;var u=(0,t.default)(r),c=typeof o=="function";return u.forEach(function(d){if(d.type==="declaration"){var h=d.property,m=d.value;c?o(h,m,d):m&&(a=a||{},a[h]=m)}}),a}return go}var Is={},U0;function pA(){if(U0)return Is;U0=1,Object.defineProperty(Is,"__esModule",{value:!0}),Is.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,a=function(h){return!h||n.test(h)||e.test(h)},u=function(h,m){return m.toUpperCase()},c=function(h,m){return"".concat(m,"-")},d=function(h,m){return m===void 0&&(m={}),a(h)?h:(h=h.toLowerCase(),m.reactCompat?h=h.replace(o,c):h=h.replace(r,c),h.replace(t,u))};return Is.camelCase=d,Is}var Rs,H0;function mA(){if(H0)return Rs;H0=1;var e=Rs&&Rs.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(hA()),n=pA();function r(o,a){var u={};return!o||typeof o!="string"||(0,t.default)(o,function(c,d){c&&d&&(u[(0,n.camelCase)(c,a)]=d)}),u}return r.default=r,Rs=r,Rs}var gA=mA();const EA=We(gA),wu=z0("end"),ar=z0("start");function z0(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 j0(e){const t=ar(e),n=wu(e);if(t&&n)return{start:t,end:n}}function Ps(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?$0(e.position):"start"in e||"end"in e?$0(e):"line"in e||"column"in e?_d(e):""}function _d(e){return V0(e&&e.line)+":"+V0(e&&e.column)}function $0(e){return _d(e&&e.start)+"-"+_d(e&&e.end)}function V0(e){return e&&typeof e=="number"?e:1}class Yt extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let o="",a={},u=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a=U({},n)),typeof t=="string"?o=t:!a.cause&&t&&(u=!0,o=t.message,a.cause=t),!a.ruleId&&!a.source&&typeof r=="string"){const d=r.indexOf(":");d===-1?a.ruleId=r:(a.source=r.slice(0,d),a.ruleId=r.slice(d+1))}if(!a.place&&a.ancestors&&a.ancestors){const d=a.ancestors[a.ancestors.length-1];d&&(a.place=d.position)}const c=a.place&&"start"in a.place?a.place.start:a.place;this.ancestors=a.ancestors||void 0,this.cause=a.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=Ps(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=u&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual,this.expected,this.note,this.url}}Yt.prototype.file="",Yt.prototype.name="",Yt.prototype.reason="",Yt.prototype.message="",Yt.prototype.stack="",Yt.prototype.column=void 0,Yt.prototype.line=void 0,Yt.prototype.ancestors=void 0,Yt.prototype.cause=void 0,Yt.prototype.fatal=void 0,Yt.prototype.place=void 0,Yt.prototype.ruleId=void 0,Yt.prototype.source=void 0;const wd={}.hasOwnProperty,yA=new Map,TA=/[A-Z]/g,bA=new Set(["table","tbody","thead","tfoot","tr"]),xA=new Set(["td","th"]),Y0="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function _A(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=OA(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=NA(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"?mo:_u,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=W0(o,e,void 0);return a&&typeof a!="string"?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function W0(e,t,n){if(t.type==="element")return wA(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return SA(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return vA(e,t,n);if(t.type==="mdxjsEsm")return AA(e,t);if(t.type==="root")return CA(e,t,n);if(t.type==="text")return kA(e,t)}function wA(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=G0(e,t.tagName,!1),u=IA(e,t);let c=Ad(e,t);return bA.has(t.tagName)&&(c=c.filter(function(d){return typeof d=="string"?!rA(d):!0})),q0(e,u,a,t),Sd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function SA(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)}Ls(e,t.position)}function AA(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ls(e,t.position)}function vA(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=t.name===null?e.Fragment:G0(e,t.name,!0),u=RA(e,t),c=Ad(e,t);return q0(e,u,a,t),Sd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function CA(e,t,n){const r={};return Sd(r,Ad(e,t)),e.create(t,e.Fragment,r,n)}function kA(e,t){return t.value}function q0(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Sd(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function NA(e,t,n){return r;function r(o,a,u,c){const h=Array.isArray(u.children)?n:t;return c?h(a,u,c):h(a,u)}}function OA(e,t){return n;function n(r,o,a,u){const c=Array.isArray(a.children),d=ar(r);return t(o,a,u,c,{columnNumber:d?d.column-1:void 0,fileName:e,lineNumber:d?d.line:void 0},void 0)}}function IA(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&wd.call(t.properties,o)){const a=PA(e,o,t.properties[o]);if(a){const[u,c]=a;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&xA.has(t.tagName)?r=c:n[u]=c}}if(r){const a=n.style||(n.style={});a[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function RA(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const a=r.data.estree.body[0];a.type;const u=a.expression;u.type;const c=u.properties[0];c.type,Object.assign(n,e.evaluater.evaluateExpression(c.argument))}else Ls(e,t.position);else{const o=r.name;let a;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,a=e.evaluater.evaluateExpression(c.expression)}else Ls(e,t.position);else a=r.value===null?!0:r.value;n[o]=a}return n}function Ad(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:yA;for(;++r<t.children.length;){const a=t.children[r];let u;if(e.passKeys){const d=a.type==="element"?a.tagName:a.type==="mdxJsxFlowElement"||a.type==="mdxJsxTextElement"?a.name:void 0;if(d){const h=o.get(d)||0;u=d+"-"+h,o.set(d,h+1)}}const c=W0(e,a,u);c!==void 0&&n.push(c)}return n}function PA(e,t,n){const r=bd(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?w0(n):M0(n)),r.property==="style"){let o=typeof n=="object"?n:LA(e,String(n));return e.stylePropertyNameCase==="css"&&(o=DA(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?aA[r.property]||r.property:r.attribute,n]}}function LA(e,t){try{return EA(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new Yt("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=Y0+"#cannot-parse-style-attribute",o}}function G0(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const o=t.split(".");let a=-1,u;for(;++a<o.length;){const c=S0(o[a])?{type:"Identifier",name:o[a]}:{type:"Literal",value:o[a]};u=u?{type:"MemberExpression",object:u,property:c,computed:!!(a&&c.type==="Literal"),optional:!1}:c}r=u}else r=S0(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return wd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);Ls(e)}function Ls(e,t){const n=new Yt("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=Y0+"#cannot-handle-mdx-estrees-without-createevaluater",n}function DA(e){const t={};let n;for(n in e)wd.call(e,n)&&(t[MA(n)]=e[n]);return t}function MA(e){let t=e.replace(TA,FA);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function FA(e){return"-"+e.toLowerCase()}const vd={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"]},BA={};function Cd(e,t){const n=BA,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return K0(e,r,o)}function K0(e,t,n){if(UA(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 Q0(e.children,t,n)}return Array.isArray(e)?Q0(e,t,n):""}function Q0(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=K0(e[o],t,n);return r.join("")}function UA(e){return!!(e&&typeof e=="object")}const X0=document.createElement("i");function kd(e){const t="&"+e+";";X0.innerHTML=t;const n=X0.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function xn(e,t,n,r){const o=e.length;let a=0,u;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)u=Array.from(r),u.unshift(t,n),e.splice(...u);else for(n&&e.splice(t,n);a<r.length;)u=r.slice(a,a+1e4),u.unshift(t,0),e.splice(...u),a+=1e4,t+=1e4}function Rn(e,t){return e.length>0?(xn(e,e.length,0,t),e):t}const J0={}.hasOwnProperty;function Z0(e){const t={};let n=-1;for(;++n<e.length;)HA(t,e[n]);return t}function HA(e,t){let n;for(n in t){const o=(J0.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let u;if(a)for(u in a){J0.call(o,u)||(o[u]=[]);const c=a[u];zA(o[u],Array.isArray(c)?c:c?[c]:[])}}}function zA(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);xn(e,0,0,r)}function eg(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 Wn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const tn=$r(/[A-Za-z]/),Wt=$r(/[\dA-Za-z]/),jA=$r(/[#-'*+\--9=?A-Z^-~]/);function Su(e){return e!==null&&(e<32||e===127)}const Nd=$r(/\d/),$A=$r(/[\dA-Fa-f]/),VA=$r(/[!-/:-@[-`{-~]/);function Le(e){return e!==null&&e<-2}function it(e){return e!==null&&(e<0||e===32)}function qe(e){return e===-2||e===-1||e===32}const Au=$r(new RegExp("\\p{P}|\\p{S}","u")),Oi=$r(/\s/);function $r(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Eo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let u="";if(a===37&&Wt(e.charCodeAt(n+1))&&Wt(e.charCodeAt(n+2)))o=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(u=String.fromCharCode(a));else if(a>55295&&a<57344){const c=e.charCodeAt(n+1);a<56320&&c>56319&&c<57344?(u=String.fromCharCode(a,c),o=1):u="�"}else u=String.fromCharCode(a);u&&(t.push(e.slice(r,n),encodeURIComponent(u)),r=n+o+1,u=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function Ke(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let a=0;return u;function u(d){return qe(d)?(e.enter(n),c(d)):t(d)}function c(d){return qe(d)&&a++<o?(e.consume(d),c):(e.exit(n),t(d))}}const YA={tokenize:WA};function WA(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"),Ke(e,t,"linePrefix")}function o(c){return e.enter("paragraph"),a(c)}function a(c){const d=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=d),n=d,u(c)}function u(c){if(c===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(c);return}return Le(c)?(e.consume(c),e.exit("chunkText"),a):(e.consume(c),u)}}const qA={tokenize:GA},tg={tokenize:KA};function GA(e){const t=this,n=[];let r=0,o,a,u;return c;function c(R){if(r<n.length){const F=n[r];return t.containerState=F[1],e.attempt(F[0].continuation,d,h)(R)}return h(R)}function d(R){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&I();const F=t.events.length;let z=F,D;for(;z--;)if(t.events[z][0]==="exit"&&t.events[z][1].type==="chunkFlow"){D=t.events[z][1].end;break}C(r);let q=F;for(;q<t.events.length;)t.events[q][1].end=U({},D),q++;return xn(t.events,z+1,0,t.events.slice(F)),t.events.length=q,h(R)}return c(R)}function h(R){if(r===n.length){if(!o)return T(R);if(o.currentConstruct&&o.currentConstruct.concrete)return _(R);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(tg,m,E)(R)}function m(R){return o&&I(),C(r),T(R)}function E(R){return t.parser.lazy[t.now().line]=r!==n.length,u=t.now().offset,_(R)}function T(R){return t.containerState={},e.attempt(tg,b,_)(R)}function b(R){return r++,n.push([t.currentConstruct,t.containerState]),T(R)}function _(R){if(R===null){o&&I(),C(0),e.consume(R);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:a}),w(R)}function w(R){if(R===null){A(e.exit("chunkFlow"),!0),C(0),e.consume(R);return}return Le(R)?(e.consume(R),A(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(R),w)}function A(R,F){const z=t.sliceStream(R);if(F&&z.push(null),R.previous=a,a&&(a.next=R),a=R,o.defineSkip(R.start),o.write(z),t.parser.lazy[R.start.line]){let D=o.events.length;for(;D--;)if(o.events[D][1].start.offset<u&&(!o.events[D][1].end||o.events[D][1].end.offset>u))return;const q=t.events.length;let ce=q,be,j;for(;ce--;)if(t.events[ce][0]==="exit"&&t.events[ce][1].type==="chunkFlow"){if(be){j=t.events[ce][1].end;break}be=!0}for(C(r),D=q;D<t.events.length;)t.events[D][1].end=U({},j),D++;xn(t.events,ce+1,0,t.events.slice(q)),t.events.length=D}}function C(R){let F=n.length;for(;F-- >R;){const z=n[F];t.containerState=z[1],z[0].exit.call(t,e)}n.length=R}function I(){o.write([null]),a=void 0,o=void 0,t.containerState._closeFlow=void 0}}function KA(e,t,n){return Ke(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function yo(e){if(e===null||it(e)||Oi(e))return 1;if(Au(e))return 2}function vu(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const a=e[o].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const Od={name:"attention",resolveAll:QA,tokenize:XA};function QA(e,t){let n=-1,r,o,a,u,c,d,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;d=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),T=U({},e[n][1].start);ng(E,-d),ng(T,d),u={type:d>1?"strongSequence":"emphasisSequence",start:E,end:U({},e[r][1].end)},c={type:d>1?"strongSequence":"emphasisSequence",start:U({},e[n][1].start),end:T},a={type:d>1?"strongText":"emphasisText",start:U({},e[r][1].end),end:U({},e[n][1].start)},o={type:d>1?"strong":"emphasis",start:U({},u.start),end:U({},c.end)},e[r][1].end=U({},u.start),e[n][1].start=U({},c.end),h=[],e[r][1].end.offset-e[r][1].start.offset&&(h=Rn(h,[["enter",e[r][1],t],["exit",e[r][1],t]])),h=Rn(h,[["enter",o,t],["enter",u,t],["exit",u,t],["enter",a,t]]),h=Rn(h,vu(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),h=Rn(h,[["exit",a,t],["enter",c,t],["exit",c,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(m=2,h=Rn(h,[["enter",e[n][1],t],["exit",e[n][1],t]])):m=0,xn(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 XA(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=yo(r);let a;return u;function u(d){return a=d,e.enter("attentionSequence"),c(d)}function c(d){if(d===a)return e.consume(d),c;const h=e.exit("attentionSequence"),m=yo(d),E=!m||m===2&&o||n.includes(d),T=!o||o===2&&m||n.includes(r);return h._open=!!(a===42?E:E&&(o||!T)),h._close=!!(a===42?T:T&&(m||!E)),t(d)}}function ng(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const JA={name:"autolink",tokenize:ZA};function ZA(e,t,n){let r=0;return o;function o(b){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(b),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(b){return tn(b)?(e.consume(b),u):b===64?n(b):h(b)}function u(b){return b===43||b===45||b===46||Wt(b)?(r=1,c(b)):h(b)}function c(b){return b===58?(e.consume(b),r=0,d):(b===43||b===45||b===46||Wt(b))&&r++<32?(e.consume(b),c):(r=0,h(b))}function d(b){return b===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(b),e.exit("autolinkMarker"),e.exit("autolink"),t):b===null||b===32||b===60||Su(b)?n(b):(e.consume(b),d)}function h(b){return b===64?(e.consume(b),m):jA(b)?(e.consume(b),h):n(b)}function m(b){return Wt(b)?E(b):n(b)}function E(b){return b===46?(e.consume(b),r=0,m):b===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(b),e.exit("autolinkMarker"),e.exit("autolink"),t):T(b)}function T(b){if((b===45||Wt(b))&&r++<63){const _=b===45?T:E;return e.consume(b),_}return n(b)}}const Ds={partial:!0,tokenize:ev};function ev(e,t,n){return r;function r(a){return qe(a)?Ke(e,o,"linePrefix")(a):o(a)}function o(a){return a===null||Le(a)?t(a):n(a)}}const rg={continuation:{tokenize:nv},exit:rv,name:"blockQuote",tokenize:tv};function tv(e,t,n){const r=this;return o;function o(u){if(u===62){const c=r.containerState;return c.open||(e.enter("blockQuote",{_container:!0}),c.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(u),e.exit("blockQuoteMarker"),a}return n(u)}function a(u){return qe(u)?(e.enter("blockQuotePrefixWhitespace"),e.consume(u),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(u))}}function nv(e,t,n){const r=this;return o;function o(u){return qe(u)?Ke(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(u):a(u)}function a(u){return e.attempt(rg,t,n)(u)}}function rv(e){e.exit("blockQuote")}const ig={name:"characterEscape",tokenize:iv};function iv(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),o}function o(a){return VA(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const og={name:"characterReference",tokenize:ov};function ov(e,t,n){const r=this;let o=0,a,u;return c;function c(E){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),d}function d(E){return E===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(E),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),a=31,u=Wt,m(E))}function h(E){return E===88||E===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(E),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,u=$A,m):(e.enter("characterReferenceValue"),a=7,u=Nd,m(E))}function m(E){if(E===59&&o){const T=e.exit("characterReferenceValue");return u===Wt&&!kd(r.sliceSerialize(T))?n(E):(e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return u(E)&&o++<a?(e.consume(E),m):n(E)}}const sg={partial:!0,tokenize:av},ag={concrete:!0,name:"codeFenced",tokenize:sv};function sv(e,t,n){const r=this,o={partial:!0,tokenize:z};let a=0,u=0,c;return d;function d(D){return h(D)}function h(D){const q=r.events[r.events.length-1];return a=q&&q[1].type==="linePrefix"?q[2].sliceSerialize(q[1],!0).length:0,c=D,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),m(D)}function m(D){return D===c?(u++,e.consume(D),m):u<3?n(D):(e.exit("codeFencedFenceSequence"),qe(D)?Ke(e,E,"whitespace")(D):E(D))}function E(D){return D===null||Le(D)?(e.exit("codeFencedFence"),r.interrupt?t(D):e.check(sg,w,F)(D)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),T(D))}function T(D){return D===null||Le(D)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),E(D)):qe(D)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Ke(e,b,"whitespace")(D)):D===96&&D===c?n(D):(e.consume(D),T)}function b(D){return D===null||Le(D)?E(D):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),_(D))}function _(D){return D===null||Le(D)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),E(D)):D===96&&D===c?n(D):(e.consume(D),_)}function w(D){return e.attempt(o,F,A)(D)}function A(D){return e.enter("lineEnding"),e.consume(D),e.exit("lineEnding"),C}function C(D){return a>0&&qe(D)?Ke(e,I,"linePrefix",a+1)(D):I(D)}function I(D){return D===null||Le(D)?e.check(sg,w,F)(D):(e.enter("codeFlowValue"),R(D))}function R(D){return D===null||Le(D)?(e.exit("codeFlowValue"),I(D)):(e.consume(D),R)}function F(D){return e.exit("codeFenced"),t(D)}function z(D,q,ce){let be=0;return j;function j(Te){return D.enter("lineEnding"),D.consume(Te),D.exit("lineEnding"),ae}function ae(Te){return D.enter("codeFencedFence"),qe(Te)?Ke(D,he,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(Te):he(Te)}function he(Te){return Te===c?(D.enter("codeFencedFenceSequence"),ge(Te)):ce(Te)}function ge(Te){return Te===c?(be++,D.consume(Te),ge):be>=u?(D.exit("codeFencedFenceSequence"),qe(Te)?Ke(D,ue,"whitespace")(Te):ue(Te)):ce(Te)}function ue(Te){return Te===null||Le(Te)?(D.exit("codeFencedFence"),q(Te)):ce(Te)}}}function av(e,t,n){const r=this;return o;function o(u){return u===null?n(u):(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),a)}function a(u){return r.parser.lazy[r.now().line]?n(u):t(u)}}const Id={name:"codeIndented",tokenize:lv},uv={partial:!0,tokenize:cv};function lv(e,t,n){const r=this;return o;function o(h){return e.enter("codeIndented"),Ke(e,a,"linePrefix",5)(h)}function a(h){const m=r.events[r.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?u(h):n(h)}function u(h){return h===null?d(h):Le(h)?e.attempt(uv,u,d)(h):(e.enter("codeFlowValue"),c(h))}function c(h){return h===null||Le(h)?(e.exit("codeFlowValue"),u(h)):(e.consume(h),c)}function d(h){return e.exit("codeIndented"),t(h)}}function cv(e,t,n){const r=this;return o;function o(u){return r.parser.lazy[r.now().line]?n(u):Le(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),o):Ke(e,a,"linePrefix",5)(u)}function a(u){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(u):Le(u)?o(u):n(u)}}const dv={name:"codeText",previous:hv,resolve:fv,tokenize:pv};function fv(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 hv(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function pv(e,t,n){let r=0,o,a;return u;function u(E){return e.enter("codeText"),e.enter("codeTextSequence"),c(E)}function c(E){return E===96?(e.consume(E),r++,c):(e.exit("codeTextSequence"),d(E))}function d(E){return E===null?n(E):E===32?(e.enter("space"),e.consume(E),e.exit("space"),d):E===96?(a=e.enter("codeTextSequence"),o=0,m(E)):Le(E)?(e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),d):(e.enter("codeTextData"),h(E))}function h(E){return E===null||E===32||E===96||Le(E)?(e.exit("codeTextData"),d(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)):(a.type="codeTextData",h(E))}}class mv{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 a=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return r&&Ms(this.left,r),a.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),Ms(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Ms(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);Ms(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Ms(this.left,n.reverse())}}}function Ms(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 ug(e){const t={};let n=-1,r,o,a,u,c,d,h;const m=new mv(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"&&(d=r[1]._tokenizer.events,a=0,a<d.length&&d[a][1].type==="lineEndingBlank"&&(a+=2),a<d.length&&d[a][1].type==="content"))for(;++a<d.length&&d[a][1].type!=="content";)d[a][1].type==="chunkText"&&(d[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,gv(m,n)),n=t[n],h=!0);else if(r[1]._container){for(a=n,o=void 0;a--;)if(u=m.get(a),u[1].type==="lineEnding"||u[1].type==="lineEndingBlank")u[0]==="enter"&&(o&&(m.get(o)[1].type="lineEndingBlank"),u[1].type="lineEnding",o=a);else if(!(u[1].type==="linePrefix"||u[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 xn(e,0,Number.POSITIVE_INFINITY,m.slice(0)),!h}function gv(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const a=[];let u=n._tokenizer;u||(u=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(u._contentTypeTextTrailing=!0));const c=u.events,d=[],h={};let m,E,T=-1,b=n,_=0,w=0;const A=[w];for(;b;){for(;e.get(++o)[1]!==b;);a.push(o),b._tokenizer||(m=r.sliceStream(b),b.next||m.push(null),E&&u.defineSkip(b.start),b._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=!0),u.write(m),b._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=void 0)),E=b,b=b.next}for(b=n;++T<c.length;)c[T][0]==="exit"&&c[T-1][0]==="enter"&&c[T][1].type===c[T-1][1].type&&c[T][1].start.line!==c[T][1].end.line&&(w=T+1,A.push(w),b._tokenizer=void 0,b.previous=void 0,b=b.next);for(u.events=[],b?(b._tokenizer=void 0,b.previous=void 0):A.pop(),T=A.length;T--;){const C=c.slice(A[T],A[T+1]),I=a.pop();d.push([I,I+C.length-1]),e.splice(I,2,C)}for(d.reverse(),T=-1;++T<d.length;)h[_+d[T][0]]=_+d[T][1],_+=d[T][1]-d[T][0]-1;return h}const Ev={resolve:Tv,tokenize:bv},yv={partial:!0,tokenize:xv};function Tv(e){return ug(e),e}function bv(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?a(c):Le(c)?e.check(yv,u,a)(c):(e.consume(c),o)}function a(c){return e.exit("chunkContent"),e.exit("content"),t(c)}function u(c){return e.consume(c),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,o}}function xv(e,t,n){const r=this;return o;function o(u){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),Ke(e,a,"linePrefix")}function a(u){if(u===null||Le(u))return n(u);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(u):e.interrupt(r.parser.constructs.flow,n,t)(u)}}function lg(e,t,n,r,o,a,u,c,d){const h=d||Number.POSITIVE_INFINITY;let m=0;return E;function E(C){return C===60?(e.enter(r),e.enter(o),e.enter(a),e.consume(C),e.exit(a),T):C===null||C===32||C===41||Su(C)?n(C):(e.enter(r),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),w(C))}function T(C){return C===62?(e.enter(a),e.consume(C),e.exit(a),e.exit(o),e.exit(r),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),b(C))}function b(C){return C===62?(e.exit("chunkString"),e.exit(c),T(C)):C===null||C===60||Le(C)?n(C):(e.consume(C),C===92?_:b)}function _(C){return C===60||C===62||C===92?(e.consume(C),b):b(C)}function w(C){return!m&&(C===null||C===41||it(C))?(e.exit("chunkString"),e.exit(c),e.exit(u),e.exit(r),t(C)):m<h&&C===40?(e.consume(C),m++,w):C===41?(e.consume(C),m--,w):C===null||C===32||C===40||Su(C)?n(C):(e.consume(C),C===92?A:w)}function A(C){return C===40||C===41||C===92?(e.consume(C),w):w(C)}}function cg(e,t,n,r,o,a){const u=this;let c=0,d;return h;function h(b){return e.enter(r),e.enter(o),e.consume(b),e.exit(o),e.enter(a),m}function m(b){return c>999||b===null||b===91||b===93&&!d||b===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(b):b===93?(e.exit(a),e.enter(o),e.consume(b),e.exit(o),e.exit(r),t):Le(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),E(b))}function E(b){return b===null||b===91||b===93||Le(b)||c++>999?(e.exit("chunkString"),m(b)):(e.consume(b),d||(d=!qe(b)),b===92?T:E)}function T(b){return b===91||b===92||b===93?(e.consume(b),c++,E):E(b)}}function dg(e,t,n,r,o,a){let u;return c;function c(T){return T===34||T===39||T===40?(e.enter(r),e.enter(o),e.consume(T),e.exit(o),u=T===40?41:T,d):n(T)}function d(T){return T===u?(e.enter(o),e.consume(T),e.exit(o),e.exit(r),t):(e.enter(a),h(T))}function h(T){return T===u?(e.exit(a),d(u)):T===null?n(T):Le(T)?(e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),Ke(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(T))}function m(T){return T===u||T===null||Le(T)?(e.exit("chunkString"),h(T)):(e.consume(T),T===92?E:m)}function E(T){return T===u||T===92?(e.consume(T),m):m(T)}}function Fs(e,t){let n;return r;function r(o){return Le(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):qe(o)?Ke(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}const _v={name:"definition",tokenize:Sv},wv={partial:!0,tokenize:Av};function Sv(e,t,n){const r=this;let o;return a;function a(b){return e.enter("definition"),u(b)}function u(b){return cg.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(b)}function c(b){return o=Wn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),b===58?(e.enter("definitionMarker"),e.consume(b),e.exit("definitionMarker"),d):n(b)}function d(b){return it(b)?Fs(e,h)(b):h(b)}function h(b){return lg(e,m,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(b)}function m(b){return e.attempt(wv,E,E)(b)}function E(b){return qe(b)?Ke(e,T,"whitespace")(b):T(b)}function T(b){return b===null||Le(b)?(e.exit("definition"),r.parser.defined.push(o),t(b)):n(b)}}function Av(e,t,n){return r;function r(c){return it(c)?Fs(e,o)(c):n(c)}function o(c){return dg(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function a(c){return qe(c)?Ke(e,u,"whitespace")(c):u(c)}function u(c){return c===null||Le(c)?t(c):n(c)}}const vv={name:"hardBreakEscape",tokenize:Cv};function Cv(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),o}function o(a){return Le(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const kv={name:"headingAtx",resolve:Nv,tokenize:Ov};function Nv(e,t){let n=e.length-2,r=3,o,a;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},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},xn(e,r,n-r+1,[["enter",o,t],["enter",a,t],["exit",a,t],["exit",o,t]])),e}function Ov(e,t,n){let r=0;return o;function o(m){return e.enter("atxHeading"),a(m)}function a(m){return e.enter("atxHeadingSequence"),u(m)}function u(m){return m===35&&r++<6?(e.consume(m),u):m===null||it(m)?(e.exit("atxHeadingSequence"),c(m)):n(m)}function c(m){return m===35?(e.enter("atxHeadingSequence"),d(m)):m===null||Le(m)?(e.exit("atxHeading"),t(m)):qe(m)?Ke(e,c,"whitespace")(m):(e.enter("atxHeadingText"),h(m))}function d(m){return m===35?(e.consume(m),d):(e.exit("atxHeadingSequence"),c(m))}function h(m){return m===null||m===35||it(m)?(e.exit("atxHeadingText"),c(m)):(e.consume(m),h)}}const Iv=["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"],fg=["pre","script","style","textarea"],Rv={concrete:!0,name:"htmlFlow",resolveTo:Dv,tokenize:Mv},Pv={partial:!0,tokenize:Bv},Lv={partial:!0,tokenize:Fv};function Dv(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 Mv(e,t,n){const r=this;let o,a,u,c,d;return h;function h(k){return m(k)}function m(k){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(k),E}function E(k){return k===33?(e.consume(k),T):k===47?(e.consume(k),a=!0,w):k===63?(e.consume(k),o=3,r.interrupt?t:S):tn(k)?(e.consume(k),u=String.fromCharCode(k),A):n(k)}function T(k){return k===45?(e.consume(k),o=2,b):k===91?(e.consume(k),o=5,c=0,_):tn(k)?(e.consume(k),o=4,r.interrupt?t:S):n(k)}function b(k){return k===45?(e.consume(k),r.interrupt?t:S):n(k)}function _(k){const xe="CDATA[";return k===xe.charCodeAt(c++)?(e.consume(k),c===xe.length?r.interrupt?t:he:_):n(k)}function w(k){return tn(k)?(e.consume(k),u=String.fromCharCode(k),A):n(k)}function A(k){if(k===null||k===47||k===62||it(k)){const xe=k===47,Pe=u.toLowerCase();return!xe&&!a&&fg.includes(Pe)?(o=1,r.interrupt?t(k):he(k)):Iv.includes(u.toLowerCase())?(o=6,xe?(e.consume(k),C):r.interrupt?t(k):he(k)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?I(k):R(k))}return k===45||Wt(k)?(e.consume(k),u+=String.fromCharCode(k),A):n(k)}function C(k){return k===62?(e.consume(k),r.interrupt?t:he):n(k)}function I(k){return qe(k)?(e.consume(k),I):j(k)}function R(k){return k===47?(e.consume(k),j):k===58||k===95||tn(k)?(e.consume(k),F):qe(k)?(e.consume(k),R):j(k)}function F(k){return k===45||k===46||k===58||k===95||Wt(k)?(e.consume(k),F):z(k)}function z(k){return k===61?(e.consume(k),D):qe(k)?(e.consume(k),z):R(k)}function D(k){return k===null||k===60||k===61||k===62||k===96?n(k):k===34||k===39?(e.consume(k),d=k,q):qe(k)?(e.consume(k),D):ce(k)}function q(k){return k===d?(e.consume(k),d=null,be):k===null||Le(k)?n(k):(e.consume(k),q)}function ce(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||it(k)?z(k):(e.consume(k),ce)}function be(k){return k===47||k===62||qe(k)?R(k):n(k)}function j(k){return k===62?(e.consume(k),ae):n(k)}function ae(k){return k===null||Le(k)?he(k):qe(k)?(e.consume(k),ae):n(k)}function he(k){return k===45&&o===2?(e.consume(k),Ne):k===60&&o===1?(e.consume(k),fe):k===62&&o===4?(e.consume(k),M):k===63&&o===3?(e.consume(k),S):k===93&&o===5?(e.consume(k),te):Le(k)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(Pv,X,ge)(k)):k===null||Le(k)?(e.exit("htmlFlowData"),ge(k)):(e.consume(k),he)}function ge(k){return e.check(Lv,ue,X)(k)}function ue(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),Te}function Te(k){return k===null||Le(k)?ge(k):(e.enter("htmlFlowData"),he(k))}function Ne(k){return k===45?(e.consume(k),S):he(k)}function fe(k){return k===47?(e.consume(k),u="",K):he(k)}function K(k){if(k===62){const xe=u.toLowerCase();return fg.includes(xe)?(e.consume(k),M):he(k)}return tn(k)&&u.length<8?(e.consume(k),u+=String.fromCharCode(k),K):he(k)}function te(k){return k===93?(e.consume(k),S):he(k)}function S(k){return k===62?(e.consume(k),M):k===45&&o===2?(e.consume(k),S):he(k)}function M(k){return k===null||Le(k)?(e.exit("htmlFlowData"),X(k)):(e.consume(k),M)}function X(k){return e.exit("htmlFlow"),t(k)}}function Fv(e,t,n){const r=this;return o;function o(u){return Le(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),a):n(u)}function a(u){return r.parser.lazy[r.now().line]?n(u):t(u)}}function Bv(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ds,t,n)}}const Uv={name:"htmlText",tokenize:Hv};function Hv(e,t,n){const r=this;let o,a,u;return c;function c(S){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(S),d}function d(S){return S===33?(e.consume(S),h):S===47?(e.consume(S),z):S===63?(e.consume(S),R):tn(S)?(e.consume(S),ce):n(S)}function h(S){return S===45?(e.consume(S),m):S===91?(e.consume(S),a=0,_):tn(S)?(e.consume(S),I):n(S)}function m(S){return S===45?(e.consume(S),b):n(S)}function E(S){return S===null?n(S):S===45?(e.consume(S),T):Le(S)?(u=E,fe(S)):(e.consume(S),E)}function T(S){return S===45?(e.consume(S),b):E(S)}function b(S){return S===62?Ne(S):S===45?T(S):E(S)}function _(S){const M="CDATA[";return S===M.charCodeAt(a++)?(e.consume(S),a===M.length?w:_):n(S)}function w(S){return S===null?n(S):S===93?(e.consume(S),A):Le(S)?(u=w,fe(S)):(e.consume(S),w)}function A(S){return S===93?(e.consume(S),C):w(S)}function C(S){return S===62?Ne(S):S===93?(e.consume(S),C):w(S)}function I(S){return S===null||S===62?Ne(S):Le(S)?(u=I,fe(S)):(e.consume(S),I)}function R(S){return S===null?n(S):S===63?(e.consume(S),F):Le(S)?(u=R,fe(S)):(e.consume(S),R)}function F(S){return S===62?Ne(S):R(S)}function z(S){return tn(S)?(e.consume(S),D):n(S)}function D(S){return S===45||Wt(S)?(e.consume(S),D):q(S)}function q(S){return Le(S)?(u=q,fe(S)):qe(S)?(e.consume(S),q):Ne(S)}function ce(S){return S===45||Wt(S)?(e.consume(S),ce):S===47||S===62||it(S)?be(S):n(S)}function be(S){return S===47?(e.consume(S),Ne):S===58||S===95||tn(S)?(e.consume(S),j):Le(S)?(u=be,fe(S)):qe(S)?(e.consume(S),be):Ne(S)}function j(S){return S===45||S===46||S===58||S===95||Wt(S)?(e.consume(S),j):ae(S)}function ae(S){return S===61?(e.consume(S),he):Le(S)?(u=ae,fe(S)):qe(S)?(e.consume(S),ae):be(S)}function he(S){return S===null||S===60||S===61||S===62||S===96?n(S):S===34||S===39?(e.consume(S),o=S,ge):Le(S)?(u=he,fe(S)):qe(S)?(e.consume(S),he):(e.consume(S),ue)}function ge(S){return S===o?(e.consume(S),o=void 0,Te):S===null?n(S):Le(S)?(u=ge,fe(S)):(e.consume(S),ge)}function ue(S){return S===null||S===34||S===39||S===60||S===61||S===96?n(S):S===47||S===62||it(S)?be(S):(e.consume(S),ue)}function Te(S){return S===47||S===62||it(S)?be(S):n(S)}function Ne(S){return S===62?(e.consume(S),e.exit("htmlTextData"),e.exit("htmlText"),t):n(S)}function fe(S){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),K}function K(S){return qe(S)?Ke(e,te,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(S):te(S)}function te(S){return e.enter("htmlTextData"),u(S)}}const Rd={name:"labelEnd",resolveAll:Vv,resolveTo:Yv,tokenize:Wv},zv={tokenize:qv},jv={tokenize:Gv},$v={tokenize:Kv};function Vv(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&&xn(e,0,e.length,n),e}function Yv(e,t){let n=e.length,r=0,o,a,u,c;for(;n--;)if(o=e[n][1],a){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[n][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(u){if(e[n][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(a=n,o.type!=="labelLink")){r=2;break}}else o.type==="labelEnd"&&(u=n);const d={type:e[a][1].type==="labelLink"?"link":"image",start:U({},e[a][1].start),end:U({},e[e.length-1][1].end)},h={type:"label",start:U({},e[a][1].start),end:U({},e[u][1].end)},m={type:"labelText",start:U({},e[a+r+2][1].end),end:U({},e[u-2][1].start)};return c=[["enter",d,t],["enter",h,t]],c=Rn(c,e.slice(a+1,a+r+3)),c=Rn(c,[["enter",m,t]]),c=Rn(c,vu(t.parser.constructs.insideSpan.null,e.slice(a+r+4,u-3),t)),c=Rn(c,[["exit",m,t],e[u-2],e[u-1],["exit",h,t]]),c=Rn(c,e.slice(u+1)),c=Rn(c,[["exit",d,t]]),xn(e,a,e.length,c),e}function Wv(e,t,n){const r=this;let o=r.events.length,a,u;for(;o--;)if((r.events[o][1].type==="labelImage"||r.events[o][1].type==="labelLink")&&!r.events[o][1]._balanced){a=r.events[o][1];break}return c;function c(T){return a?a._inactive?E(T):(u=r.parser.defined.includes(Wn(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(T),e.exit("labelMarker"),e.exit("labelEnd"),d):n(T)}function d(T){return T===40?e.attempt(zv,m,u?m:E)(T):T===91?e.attempt(jv,m,u?h:E)(T):u?m(T):E(T)}function h(T){return e.attempt($v,m,E)(T)}function m(T){return t(T)}function E(T){return a._balanced=!0,n(T)}}function qv(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 it(E)?Fs(e,a)(E):a(E)}function a(E){return E===41?m(E):lg(e,u,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function u(E){return it(E)?Fs(e,d)(E):m(E)}function c(E){return n(E)}function d(E){return E===34||E===39||E===40?dg(e,h,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(E):m(E)}function h(E){return it(E)?Fs(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 Gv(e,t,n){const r=this;return o;function o(c){return cg.call(r,e,a,u,"reference","referenceMarker","referenceString")(c)}function a(c){return r.parser.defined.includes(Wn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(c):n(c)}function u(c){return n(c)}}function Kv(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),o}function o(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const Qv={name:"labelStartImage",resolveAll:Rd.resolveAll,tokenize:Xv};function Xv(e,t,n){const r=this;return o;function o(c){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(c),e.exit("labelImageMarker"),a}function a(c){return c===91?(e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelImage"),u):n(c)}function u(c){return c===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(c):t(c)}}const Jv={name:"labelStartLink",resolveAll:Rd.resolveAll,tokenize:Zv};function Zv(e,t,n){const r=this;return o;function o(u){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(u),e.exit("labelMarker"),e.exit("labelLink"),a}function a(u){return u===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(u):t(u)}}const Pd={name:"lineEnding",tokenize:eC};function eC(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Ke(e,t,"linePrefix")}}const Cu={name:"thematicBreak",tokenize:tC};function tC(e,t,n){let r=0,o;return a;function a(h){return e.enter("thematicBreak"),u(h)}function u(h){return o=h,c(h)}function c(h){return h===o?(e.enter("thematicBreakSequence"),d(h)):r>=3&&(h===null||Le(h))?(e.exit("thematicBreak"),t(h)):n(h)}function d(h){return h===o?(e.consume(h),r++,d):(e.exit("thematicBreakSequence"),qe(h)?Ke(e,c,"whitespace")(h):c(h))}}const dn={continuation:{tokenize:oC},exit:aC,name:"list",tokenize:iC},nC={partial:!0,tokenize:uC},rC={partial:!0,tokenize:sC};function iC(e,t,n){const r=this,o=r.events[r.events.length-1];let a=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,u=0;return c;function c(b){const _=r.containerState.type||(b===42||b===43||b===45?"listUnordered":"listOrdered");if(_==="listUnordered"?!r.containerState.marker||b===r.containerState.marker:Nd(b)){if(r.containerState.type||(r.containerState.type=_,e.enter(_,{_container:!0})),_==="listUnordered")return e.enter("listItemPrefix"),b===42||b===45?e.check(Cu,n,h)(b):h(b);if(!r.interrupt||b===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),d(b)}return n(b)}function d(b){return Nd(b)&&++u<10?(e.consume(b),d):(!r.interrupt||u<2)&&(r.containerState.marker?b===r.containerState.marker:b===41||b===46)?(e.exit("listItemValue"),h(b)):n(b)}function h(b){return e.enter("listItemMarker"),e.consume(b),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||b,e.check(Ds,r.interrupt?n:m,e.attempt(nC,T,E))}function m(b){return r.containerState.initialBlankLine=!0,a++,T(b)}function E(b){return qe(b)?(e.enter("listItemPrefixWhitespace"),e.consume(b),e.exit("listItemPrefixWhitespace"),T):n(b)}function T(b){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(b)}}function oC(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Ds,o,a);function o(c){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Ke(e,t,"listItemIndent",r.containerState.size+1)(c)}function a(c){return r.containerState.furtherBlankLines||!qe(c)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,u(c)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(rC,t,u)(c))}function u(c){return r.containerState._closeFlow=!0,r.interrupt=void 0,Ke(e,e.attempt(dn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function sC(e,t,n){const r=this;return Ke(e,o,"listItemIndent",r.containerState.size+1);function o(a){const u=r.events[r.events.length-1];return u&&u[1].type==="listItemIndent"&&u[2].sliceSerialize(u[1],!0).length===r.containerState.size?t(a):n(a)}}function aC(e){e.exit(this.containerState.type)}function uC(e,t,n){const r=this;return Ke(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(a){const u=r.events[r.events.length-1];return!qe(a)&&u&&u[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const hg={name:"setextUnderline",resolveTo:lC,tokenize:cC};function lC(e,t){let n=e.length,r,o,a;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),!a&&e[n][1].type==="definition"&&(a=n);const u={type:"setextHeading",start:U({},e[r][1].start),end:U({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",a?(e.splice(o,0,["enter",u,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end=U({},e[a][1].end)):e[r][1]=u,e.push(["exit",u,t]),e}function cC(e,t,n){const r=this;let o;return a;function a(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,u(h)):n(h)}function u(h){return e.enter("setextHeadingLineSequence"),c(h)}function c(h){return h===o?(e.consume(h),c):(e.exit("setextHeadingLineSequence"),qe(h)?Ke(e,d,"lineSuffix")(h):d(h))}function d(h){return h===null||Le(h)?(e.exit("setextHeadingLine"),t(h)):n(h)}}const dC={tokenize:fC};function fC(e){const t=this,n=e.attempt(Ds,r,e.attempt(this.parser.constructs.flowInitial,o,Ke(e,e.attempt(this.parser.constructs.flow,o,e.attempt(Ev,o)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const hC={resolveAll:mg()},pC=pg("string"),mC=pg("text");function pg(e){return{resolveAll:mg(e==="text"?gC:void 0),tokenize:t};function t(n){const r=this,o=this.parser.constructs[e],a=n.attempt(o,u,c);return u;function u(m){return h(m)?a(m):c(m)}function c(m){if(m===null){n.consume(m);return}return n.enter("data"),n.consume(m),d}function d(m){return h(m)?(n.exit("data"),a(m)):(n.consume(m),d)}function h(m){if(m===null)return!0;const E=o[m];let T=-1;if(E)for(;++T<E.length;){const b=E[T];if(!b.previous||b.previous.call(r,r.previous))return!0}return!1}}}function mg(e){return t;function t(n,r){let o=-1,a;for(;++o<=n.length;)a===void 0?n[o]&&n[o][1].type==="data"&&(a=o,o++):(!n[o]||n[o][1].type!=="data")&&(o!==a+2&&(n[a][1].end=n[o-1][1].end,n.splice(a+2,o-a-2),o=a+2),a=void 0);return e?e(n,r):n}}function gC(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 a=o.length,u=-1,c=0,d;for(;a--;){const h=o[a];if(typeof h=="string"){for(u=h.length;h.charCodeAt(u-1)===32;)c++,u--;if(u)break;u=-1}else if(h===-2)d=!0,c++;else if(h!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(c=0),c){const h={type:n===e.length||d||c<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?u:r.start._bufferIndex+u,_index:r.start._index+a,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 EC=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:_v},disable:{null:[]},document:{42:dn,43:dn,45:dn,48:dn,49:dn,50:dn,51:dn,52:dn,53:dn,54:dn,55:dn,56:dn,57:dn,62:rg},flow:{35:kv,42:Cu,45:[hg,Cu],60:Rv,61:hg,95:Cu,96:ag,126:ag},flowInitial:{[-2]:Id,[-1]:Id,32:Id},insideSpan:{null:[Od,hC]},string:{38:og,92:ig},text:{[-5]:Pd,[-4]:Pd,[-3]:Pd,33:Qv,38:og,42:Od,60:[JA,Uv],91:Jv,92:[vv,ig],93:Rd,95:Od,96:dv}},Symbol.toStringTag,{value:"Module"}));function yC(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={},a=[];let u=[],c=[];const d={attempt:q(z),check:q(D),consume:I,enter:R,exit:F,interrupt:q(D,{interrupt:!0})},h={code:null,containerState:{},defineSkip:w,events:[],now:_,parser:e,previous:null,sliceSerialize:T,sliceStream:b,write:E};let m=t.tokenize.call(h,d);return t.resolveAll&&a.push(t),h;function E(ae){return u=Rn(u,ae),A(),u[u.length-1]!==null?[]:(ce(t,0),h.events=vu(a,h.events,h),h.events)}function T(ae,he){return bC(b(ae),he)}function b(ae){return TC(u,ae)}function _(){const{_bufferIndex:ae,_index:he,line:ge,column:ue,offset:Te}=r;return{_bufferIndex:ae,_index:he,line:ge,column:ue,offset:Te}}function w(ae){o[ae.line]=ae.column,j()}function A(){let ae;for(;r._index<u.length;){const he=u[r._index];if(typeof he=="string")for(ae=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===ae&&r._bufferIndex<he.length;)C(he.charCodeAt(r._bufferIndex));else C(he)}}function C(ae){m=m(ae)}function I(ae){Le(ae)?(r.line++,r.column=1,r.offset+=ae===-3?2:1,j()):ae!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===u[r._index].length&&(r._bufferIndex=-1,r._index++)),h.previous=ae}function R(ae,he){const ge=he||{};return ge.type=ae,ge.start=_(),h.events.push(["enter",ge,h]),c.push(ge),ge}function F(ae){const he=c.pop();return he.end=_(),h.events.push(["exit",he,h]),he}function z(ae,he){ce(ae,he.from)}function D(ae,he){he.restore()}function q(ae,he){return ge;function ge(ue,Te,Ne){let fe,K,te,S;return Array.isArray(ue)?X(ue):"tokenize"in ue?X([ue]):M(ue);function M(Oe){return He;function He(Se){const Ve=Se!==null&&Oe[Se],ut=Se!==null&&Oe.null,pn=[...Array.isArray(Ve)?Ve:Ve?[Ve]:[],...Array.isArray(ut)?ut:ut?[ut]:[]];return X(pn)(Se)}}function X(Oe){return fe=Oe,K=0,Oe.length===0?Ne:k(Oe[K])}function k(Oe){return He;function He(Se){return S=be(),te=Oe,Oe.partial||(h.currentConstruct=Oe),Oe.name&&h.parser.constructs.disable.null.includes(Oe.name)?Pe():Oe.tokenize.call(he?Object.assign(Object.create(h),he):h,d,xe,Pe)(Se)}}function xe(Oe){return ae(te,S),Te}function Pe(Oe){return S.restore(),++K<fe.length?k(fe[K]):Ne}}}function ce(ae,he){ae.resolveAll&&!a.includes(ae)&&a.push(ae),ae.resolve&&xn(h.events,he,h.events.length-he,ae.resolve(h.events.slice(he),h)),ae.resolveTo&&(h.events=ae.resolveTo(h.events,h))}function be(){const ae=_(),he=h.previous,ge=h.currentConstruct,ue=h.events.length,Te=Array.from(c);return{from:ue,restore:Ne};function Ne(){r=ae,h.previous=he,h.currentConstruct=ge,h.events.length=ue,c=Te,j()}}function j(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function TC(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,a=t.end._bufferIndex;let u;if(n===o)u=[e[n].slice(r,a)];else{if(u=e.slice(n,o),r>-1){const c=u[0];typeof c=="string"?u[0]=c.slice(r):u.shift()}a>0&&u.push(e[o].slice(0,a))}return u}function bC(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const a=e[n];let u;if(typeof a=="string")u=a;else switch(a){case-5:{u="\r";break}case-4:{u=`
25
25
  `;break}case-3:{u=`\r
26
- `;break}case-2:{u=t?" ":" ";break}case-1:{if(!t&&o)continue;u=" ";break}default:u=String.fromCharCode(a)}o=a===-2,r.push(u)}return r.join("")}function xC(e){const r={constructs:rg([EC,...(e||{}).extensions||[]]),content:o(YA),defined:[],document:o(qA),flow:o(dC),lazy:{},string:o(pC),text:o(mC)};return r;function o(a){return u;function u(c){return yC(r,a,c)}}}function _C(e){for(;!fg(e););return e}const bg=/[\0\t\n\r]/g;function SC(){let e=1,t="",n=!0,r;return o;function o(a,u,c){const d=[];let h,m,g,T,b;for(a=t+(typeof a=="string"?a.toString():new TextDecoder(u||void 0).decode(a)),g=0,t="",n&&(a.charCodeAt(0)===65279&&g++,n=void 0);g<a.length;){if(bg.lastIndex=g,h=bg.exec(a),T=h&&h.index!==void 0?h.index:a.length,b=a.charCodeAt(T),!h){t=a.slice(g);break}if(b===10&&g===T&&r)d.push(-3),r=void 0;else switch(r&&(d.push(-5),r=void 0),g<T&&(d.push(a.slice(g,T)),e+=T-g),b){case 0:{d.push(65533),e++;break}case 9:{for(m=Math.ceil(e/4)*4,d.push(-2);e++<m;)d.push(-1);break}case 10:{d.push(-4),e=1;break}default:r=!0,e=1}g=T+1}return c&&(r&&d.push(-5),t&&d.push(t),d.push(null)),d}}const wC=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function AC(e){return e.replace(wC,vC)}function vC(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return ig(n.slice(a?2:1),a?16:10)}return kd(n)||e}const xg={}.hasOwnProperty;function CC(e,t,n){return typeof t!="string"&&(n=t,t=void 0),kC(n)(_C(xC(n).document().write(SC()(e,t,!0))))}function kC(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(qo),autolinkProtocol:be,autolinkEmail:be,atxHeading:a(ha),blockQuote:a(ut),characterEscape:be,characterReference:be,codeFenced:a(pn),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(pn,u),codeText:a(Vi,u),codeTextData:be,data:be,codeFlowValue:be,definition:a(Xr),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(Xn),hardBreakEscape:a(pa),hardBreakTrailing:a(pa),htmlFlow:a(Wo,u),htmlFlowData:be,htmlText:a(Wo,u),htmlTextData:be,image:a(bl),label:u,link:a(qo),listItem:a(Zr),listItemValue:T,listOrdered:a(Jr,g),listUnordered:a(Jr),paragraph:a(ma),reference:k,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(ha),strong:a(xl),thematicBreak:a(Sl)},exit:{atxHeading:d(),atxHeadingSequence:z,autolink:d(),autolinkEmail:Ve,autolinkProtocol:we,blockQuote:d(),characterEscapeValue:j,characterReferenceMarkerHexadecimal:Pe,characterReferenceMarkerNumeric:Pe,characterReferenceValue:Oe,characterReference:He,codeFenced:d(A),codeFencedFence:S,codeFencedFenceInfo:b,codeFencedFenceMeta:x,codeFlowValue:j,codeIndented:d(C),codeText:d(Te),codeTextData:j,data:j,definition:d(),definitionDestinationString:F,definitionLabelString:O,definitionTitleString:R,emphasis:d(),hardBreakEscape:d(he),hardBreakTrailing:d(he),htmlFlow:d(ge),htmlFlowData:j,htmlText:d(ue),htmlTextData:j,image:d(fe),label:te,labelText:K,lineEnding:ae,link:d(Ne),listItem:d(),listOrdered:d(),listUnordered:d(),paragraph:d(),referenceString:xe,resourceDestinationString:w,resourceTitleString:M,resource:X,setextHeading:d(ce),setextHeadingLineSequence:q,setextHeadingText:D,strong:d(),thematicBreak:d()}};_g(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(Z){let ye={type:"root",children:[]};const Be={stack:[ye],tokenStack:[],config:t,enter:c,exit:h,buffer:u,resume:m,data:n},Ye=[];let Qe=-1;for(;++Qe<Z.length;)if(Z[Qe][1].type==="listOrdered"||Z[Qe][1].type==="listUnordered")if(Z[Qe][0]==="enter")Ye.push(Qe);else{const Ht=Ye.pop();Qe=o(Z,Ht,Qe)}for(Qe=-1;++Qe<Z.length;){const Ht=t[Z[Qe][0]];xg.call(Ht,Z[Qe][1].type)&&Ht[Z[Qe][1].type].call(Object.assign({sliceSerialize:Z[Qe][2].sliceSerialize},Be),Z[Qe][1])}if(Be.tokenStack.length>0){const Ht=Be.tokenStack[Be.tokenStack.length-1];(Ht[1]||Sg).call(Be,void 0,Ht[0])}for(ye.position={start:Vr(Z.length>0?Z[0][1].start:{line:1,column:1,offset:0}),end:Vr(Z.length>0?Z[Z.length-2][1].end:{line:1,column:1,offset:0})},Qe=-1;++Qe<t.transforms.length;)ye=t.transforms[Qe](ye)||ye;return ye}function o(Z,ye,Be){let Ye=ye-1,Qe=-1,Ht=!1,Or,Mn,ei,Yi;for(;++Ye<=Be;){const zt=Z[Ye];switch(zt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{zt[0]==="enter"?Qe++:Qe--,Yi=void 0;break}case"lineEndingBlank":{zt[0]==="enter"&&(Or&&!Yi&&!Qe&&!ei&&(ei=Ye),Yi=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Yi=void 0}if(!Qe&&zt[0]==="enter"&&zt[1].type==="listItemPrefix"||Qe===-1&&zt[0]==="exit"&&(zt[1].type==="listUnordered"||zt[1].type==="listOrdered")){if(Or){let yr=Ye;for(Mn=void 0;yr--;){const An=Z[yr];if(An[1].type==="lineEnding"||An[1].type==="lineEndingBlank"){if(An[0]==="exit")continue;Mn&&(Z[Mn][1].type="lineEndingBlank",Ht=!0),An[1].type="lineEnding",Mn=yr}else if(!(An[1].type==="linePrefix"||An[1].type==="blockQuotePrefix"||An[1].type==="blockQuotePrefixWhitespace"||An[1].type==="blockQuoteMarker"||An[1].type==="listItemIndent"))break}ei&&(!Mn||ei<Mn)&&(Or._spread=!0),Or.end=Object.assign({},Mn?Z[Mn][1].start:zt[1].end),Z.splice(Mn||Ye,0,["exit",Or,zt[2]]),Ye++,Be++}if(zt[1].type==="listItemPrefix"){const yr={type:"listItem",_spread:!1,start:Object.assign({},zt[1].start),end:void 0};Or=yr,Z.splice(Ye,0,["enter",yr,zt[2]]),Ye++,Be++,ei=void 0,Yi=!0}}}return Z[ye][1]._spread=Ht,Be}function a(Z,ye){return Be;function Be(Ye){c.call(this,Z(Ye),Ye),ye&&ye.call(this,Ye)}}function u(){this.stack.push({type:"fragment",children:[]})}function c(Z,ye,Be){this.stack[this.stack.length-1].children.push(Z),this.stack.push(Z),this.tokenStack.push([ye,Be||void 0]),Z.position={start:Vr(ye.start),end:void 0}}function d(Z){return ye;function ye(Be){Z&&Z.call(this,Be),h.call(this,Be)}}function h(Z,ye){const Be=this.stack.pop(),Ye=this.tokenStack.pop();if(Ye)Ye[0].type!==Z.type&&(ye?ye.call(this,Z,Ye[0]):(Ye[1]||Sg).call(this,Z,Ye[0]));else throw new Error("Cannot close `"+Z.type+"` ("+Ps({start:Z.start,end:Z.end})+"): it’s not open");Be.position.end=Vr(Z.end)}function m(){return Cd(this.stack.pop())}function g(){this.data.expectingFirstListItemValue=!0}function T(Z){if(this.data.expectingFirstListItemValue){const ye=this.stack[this.stack.length-2];ye.start=Number.parseInt(this.sliceSerialize(Z),10),this.data.expectingFirstListItemValue=void 0}}function b(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.lang=Z}function x(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.meta=Z}function S(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function A(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function C(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z.replace(/(\r?\n|\r)$/g,"")}function O(Z){const ye=this.resume(),Be=this.stack[this.stack.length-1];Be.label=ye,Be.identifier=Wn(this.sliceSerialize(Z)).toLowerCase()}function R(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.title=Z}function F(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.url=Z}function z(Z){const ye=this.stack[this.stack.length-1];if(!ye.depth){const Be=this.sliceSerialize(Z).length;ye.depth=Be}}function D(){this.data.setextHeadingSlurpLineEnding=!0}function q(Z){const ye=this.stack[this.stack.length-1];ye.depth=this.sliceSerialize(Z).codePointAt(0)===61?1:2}function ce(){this.data.setextHeadingSlurpLineEnding=void 0}function be(Z){const Be=this.stack[this.stack.length-1].children;let Ye=Be[Be.length-1];(!Ye||Ye.type!=="text")&&(Ye=_l(),Ye.position={start:Vr(Z.start),end:void 0},Be.push(Ye)),this.stack.push(Ye)}function j(Z){const ye=this.stack.pop();ye.value+=this.sliceSerialize(Z),ye.position.end=Vr(Z.end)}function ae(Z){const ye=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=ye.children[ye.children.length-1];Be.position.end=Vr(Z.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(ye.type)&&(be.call(this,Z),j.call(this,Z))}function he(){this.data.atHardBreak=!0}function ge(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z}function ue(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z}function Te(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z}function Ne(){const Z=this.stack[this.stack.length-1];if(this.data.inReference){const ye=this.data.referenceType||"shortcut";Z.type+="Reference",Z.referenceType=ye,delete Z.url,delete Z.title}else delete Z.identifier,delete Z.label;this.data.referenceType=void 0}function fe(){const Z=this.stack[this.stack.length-1];if(this.data.inReference){const ye=this.data.referenceType||"shortcut";Z.type+="Reference",Z.referenceType=ye,delete Z.url,delete Z.title}else delete Z.identifier,delete Z.label;this.data.referenceType=void 0}function K(Z){const ye=this.sliceSerialize(Z),Be=this.stack[this.stack.length-2];Be.label=AC(ye),Be.identifier=Wn(ye).toLowerCase()}function te(){const Z=this.stack[this.stack.length-1],ye=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const Ye=Z.children;Be.children=Ye}else Be.alt=ye}function w(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.url=Z}function M(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.title=Z}function X(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function xe(Z){const ye=this.resume(),Be=this.stack[this.stack.length-1];Be.label=ye,Be.identifier=Wn(this.sliceSerialize(Z)).toLowerCase(),this.data.referenceType="full"}function Pe(Z){this.data.characterReferenceType=Z.type}function Oe(Z){const ye=this.sliceSerialize(Z),Be=this.data.characterReferenceType;let Ye;Be?(Ye=ig(ye,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ye=kd(ye);const Qe=this.stack[this.stack.length-1];Qe.value+=Ye}function He(Z){const ye=this.stack.pop();ye.position.end=Vr(Z.end)}function we(Z){j.call(this,Z);const ye=this.stack[this.stack.length-1];ye.url=this.sliceSerialize(Z)}function Ve(Z){j.call(this,Z);const ye=this.stack[this.stack.length-1];ye.url="mailto:"+this.sliceSerialize(Z)}function ut(){return{type:"blockquote",children:[]}}function pn(){return{type:"code",lang:null,meta:null,value:""}}function Vi(){return{type:"inlineCode",value:""}}function Xr(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Xn(){return{type:"emphasis",children:[]}}function ha(){return{type:"heading",depth:0,children:[]}}function pa(){return{type:"break"}}function Wo(){return{type:"html",value:""}}function bl(){return{type:"image",title:null,url:"",alt:null}}function qo(){return{type:"link",title:null,url:"",children:[]}}function Jr(Z){return{type:"list",ordered:Z.type==="listOrdered",start:null,spread:Z._spread,children:[]}}function Zr(Z){return{type:"listItem",spread:Z._spread,checked:null,children:[]}}function ma(){return{type:"paragraph",children:[]}}function xl(){return{type:"strong",children:[]}}function _l(){return{type:"text",value:""}}function Sl(){return{type:"thematicBreak"}}}function Vr(e){return{line:e.line,column:e.column,offset:e.offset}}function _g(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?_g(e,r):NC(e,r)}}function NC(e,t){let n;for(n in t)if(xg.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 Sg(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Ps({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ps({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Ps({start:t.start,end:t.end})+") is still open")}function OC(e){const t=this;t.parser=n;function n(r){return CC(r,ne(U(U({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function IC(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 RC(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
26
+ `;break}case-2:{u=t?" ":" ";break}case-1:{if(!t&&o)continue;u=" ";break}default:u=String.fromCharCode(a)}o=a===-2,r.push(u)}return r.join("")}function xC(e){const r={constructs:Z0([EC,...(e||{}).extensions||[]]),content:o(YA),defined:[],document:o(qA),flow:o(dC),lazy:{},string:o(pC),text:o(mC)};return r;function o(a){return u;function u(c){return yC(r,a,c)}}}function _C(e){for(;!ug(e););return e}const gg=/[\0\t\n\r]/g;function wC(){let e=1,t="",n=!0,r;return o;function o(a,u,c){const d=[];let h,m,E,T,b;for(a=t+(typeof a=="string"?a.toString():new TextDecoder(u||void 0).decode(a)),E=0,t="",n&&(a.charCodeAt(0)===65279&&E++,n=void 0);E<a.length;){if(gg.lastIndex=E,h=gg.exec(a),T=h&&h.index!==void 0?h.index:a.length,b=a.charCodeAt(T),!h){t=a.slice(E);break}if(b===10&&E===T&&r)d.push(-3),r=void 0;else switch(r&&(d.push(-5),r=void 0),E<T&&(d.push(a.slice(E,T)),e+=T-E),b){case 0:{d.push(65533),e++;break}case 9:{for(m=Math.ceil(e/4)*4,d.push(-2);e++<m;)d.push(-1);break}case 10:{d.push(-4),e=1;break}default:r=!0,e=1}E=T+1}return c&&(r&&d.push(-5),t&&d.push(t),d.push(null)),d}}const SC=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function AC(e){return e.replace(SC,vC)}function vC(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return eg(n.slice(a?2:1),a?16:10)}return kd(n)||e}const Eg={}.hasOwnProperty;function CC(e,t,n){return typeof t!="string"&&(n=t,t=void 0),kC(n)(_C(xC(n).document().write(wC()(e,t,!0))))}function kC(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(qo),autolinkProtocol:be,autolinkEmail:be,atxHeading:a(ha),blockQuote:a(ut),characterEscape:be,characterReference:be,codeFenced:a(pn),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(pn,u),codeText:a(Yi,u),codeTextData:be,data:be,codeFlowValue:be,definition:a(Xr),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(Xn),hardBreakEscape:a(pa),hardBreakTrailing:a(pa),htmlFlow:a(Wo,u),htmlFlowData:be,htmlText:a(Wo,u),htmlTextData:be,image:a(bl),label:u,link:a(qo),listItem:a(Zr),listItemValue:T,listOrdered:a(Jr,E),listUnordered:a(Jr),paragraph:a(ma),reference:k,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(ha),strong:a(xl),thematicBreak:a(wl)},exit:{atxHeading:d(),atxHeadingSequence:z,autolink:d(),autolinkEmail:Ve,autolinkProtocol:Se,blockQuote:d(),characterEscapeValue:j,characterReferenceMarkerHexadecimal:Pe,characterReferenceMarkerNumeric:Pe,characterReferenceValue:Oe,characterReference:He,codeFenced:d(A),codeFencedFence:w,codeFencedFenceInfo:b,codeFencedFenceMeta:_,codeFlowValue:j,codeIndented:d(C),codeText:d(Te),codeTextData:j,data:j,definition:d(),definitionDestinationString:F,definitionLabelString:I,definitionTitleString:R,emphasis:d(),hardBreakEscape:d(he),hardBreakTrailing:d(he),htmlFlow:d(ge),htmlFlowData:j,htmlText:d(ue),htmlTextData:j,image:d(fe),label:te,labelText:K,lineEnding:ae,link:d(Ne),listItem:d(),listOrdered:d(),listUnordered:d(),paragraph:d(),referenceString:xe,resourceDestinationString:S,resourceTitleString:M,resource:X,setextHeading:d(ce),setextHeadingLineSequence:q,setextHeadingText:D,strong:d(),thematicBreak:d()}};yg(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(Z){let ye={type:"root",children:[]};const Be={stack:[ye],tokenStack:[],config:t,enter:c,exit:h,buffer:u,resume:m,data:n},Ye=[];let Qe=-1;for(;++Qe<Z.length;)if(Z[Qe][1].type==="listOrdered"||Z[Qe][1].type==="listUnordered")if(Z[Qe][0]==="enter")Ye.push(Qe);else{const Ht=Ye.pop();Qe=o(Z,Ht,Qe)}for(Qe=-1;++Qe<Z.length;){const Ht=t[Z[Qe][0]];Eg.call(Ht,Z[Qe][1].type)&&Ht[Z[Qe][1].type].call(Object.assign({sliceSerialize:Z[Qe][2].sliceSerialize},Be),Z[Qe][1])}if(Be.tokenStack.length>0){const Ht=Be.tokenStack[Be.tokenStack.length-1];(Ht[1]||Tg).call(Be,void 0,Ht[0])}for(ye.position={start:Vr(Z.length>0?Z[0][1].start:{line:1,column:1,offset:0}),end:Vr(Z.length>0?Z[Z.length-2][1].end:{line:1,column:1,offset:0})},Qe=-1;++Qe<t.transforms.length;)ye=t.transforms[Qe](ye)||ye;return ye}function o(Z,ye,Be){let Ye=ye-1,Qe=-1,Ht=!1,Ir,Mn,ei,Wi;for(;++Ye<=Be;){const zt=Z[Ye];switch(zt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{zt[0]==="enter"?Qe++:Qe--,Wi=void 0;break}case"lineEndingBlank":{zt[0]==="enter"&&(Ir&&!Wi&&!Qe&&!ei&&(ei=Ye),Wi=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Wi=void 0}if(!Qe&&zt[0]==="enter"&&zt[1].type==="listItemPrefix"||Qe===-1&&zt[0]==="exit"&&(zt[1].type==="listUnordered"||zt[1].type==="listOrdered")){if(Ir){let yr=Ye;for(Mn=void 0;yr--;){const An=Z[yr];if(An[1].type==="lineEnding"||An[1].type==="lineEndingBlank"){if(An[0]==="exit")continue;Mn&&(Z[Mn][1].type="lineEndingBlank",Ht=!0),An[1].type="lineEnding",Mn=yr}else if(!(An[1].type==="linePrefix"||An[1].type==="blockQuotePrefix"||An[1].type==="blockQuotePrefixWhitespace"||An[1].type==="blockQuoteMarker"||An[1].type==="listItemIndent"))break}ei&&(!Mn||ei<Mn)&&(Ir._spread=!0),Ir.end=Object.assign({},Mn?Z[Mn][1].start:zt[1].end),Z.splice(Mn||Ye,0,["exit",Ir,zt[2]]),Ye++,Be++}if(zt[1].type==="listItemPrefix"){const yr={type:"listItem",_spread:!1,start:Object.assign({},zt[1].start),end:void 0};Ir=yr,Z.splice(Ye,0,["enter",yr,zt[2]]),Ye++,Be++,ei=void 0,Wi=!0}}}return Z[ye][1]._spread=Ht,Be}function a(Z,ye){return Be;function Be(Ye){c.call(this,Z(Ye),Ye),ye&&ye.call(this,Ye)}}function u(){this.stack.push({type:"fragment",children:[]})}function c(Z,ye,Be){this.stack[this.stack.length-1].children.push(Z),this.stack.push(Z),this.tokenStack.push([ye,Be||void 0]),Z.position={start:Vr(ye.start),end:void 0}}function d(Z){return ye;function ye(Be){Z&&Z.call(this,Be),h.call(this,Be)}}function h(Z,ye){const Be=this.stack.pop(),Ye=this.tokenStack.pop();if(Ye)Ye[0].type!==Z.type&&(ye?ye.call(this,Z,Ye[0]):(Ye[1]||Tg).call(this,Z,Ye[0]));else throw new Error("Cannot close `"+Z.type+"` ("+Ps({start:Z.start,end:Z.end})+"): it’s not open");Be.position.end=Vr(Z.end)}function m(){return Cd(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function T(Z){if(this.data.expectingFirstListItemValue){const ye=this.stack[this.stack.length-2];ye.start=Number.parseInt(this.sliceSerialize(Z),10),this.data.expectingFirstListItemValue=void 0}}function b(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.lang=Z}function _(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.meta=Z}function w(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function A(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function C(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z.replace(/(\r?\n|\r)$/g,"")}function I(Z){const ye=this.resume(),Be=this.stack[this.stack.length-1];Be.label=ye,Be.identifier=Wn(this.sliceSerialize(Z)).toLowerCase()}function R(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.title=Z}function F(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.url=Z}function z(Z){const ye=this.stack[this.stack.length-1];if(!ye.depth){const Be=this.sliceSerialize(Z).length;ye.depth=Be}}function D(){this.data.setextHeadingSlurpLineEnding=!0}function q(Z){const ye=this.stack[this.stack.length-1];ye.depth=this.sliceSerialize(Z).codePointAt(0)===61?1:2}function ce(){this.data.setextHeadingSlurpLineEnding=void 0}function be(Z){const Be=this.stack[this.stack.length-1].children;let Ye=Be[Be.length-1];(!Ye||Ye.type!=="text")&&(Ye=_l(),Ye.position={start:Vr(Z.start),end:void 0},Be.push(Ye)),this.stack.push(Ye)}function j(Z){const ye=this.stack.pop();ye.value+=this.sliceSerialize(Z),ye.position.end=Vr(Z.end)}function ae(Z){const ye=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=ye.children[ye.children.length-1];Be.position.end=Vr(Z.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(ye.type)&&(be.call(this,Z),j.call(this,Z))}function he(){this.data.atHardBreak=!0}function ge(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z}function ue(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z}function Te(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.value=Z}function Ne(){const Z=this.stack[this.stack.length-1];if(this.data.inReference){const ye=this.data.referenceType||"shortcut";Z.type+="Reference",Z.referenceType=ye,delete Z.url,delete Z.title}else delete Z.identifier,delete Z.label;this.data.referenceType=void 0}function fe(){const Z=this.stack[this.stack.length-1];if(this.data.inReference){const ye=this.data.referenceType||"shortcut";Z.type+="Reference",Z.referenceType=ye,delete Z.url,delete Z.title}else delete Z.identifier,delete Z.label;this.data.referenceType=void 0}function K(Z){const ye=this.sliceSerialize(Z),Be=this.stack[this.stack.length-2];Be.label=AC(ye),Be.identifier=Wn(ye).toLowerCase()}function te(){const Z=this.stack[this.stack.length-1],ye=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const Ye=Z.children;Be.children=Ye}else Be.alt=ye}function S(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.url=Z}function M(){const Z=this.resume(),ye=this.stack[this.stack.length-1];ye.title=Z}function X(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function xe(Z){const ye=this.resume(),Be=this.stack[this.stack.length-1];Be.label=ye,Be.identifier=Wn(this.sliceSerialize(Z)).toLowerCase(),this.data.referenceType="full"}function Pe(Z){this.data.characterReferenceType=Z.type}function Oe(Z){const ye=this.sliceSerialize(Z),Be=this.data.characterReferenceType;let Ye;Be?(Ye=eg(ye,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ye=kd(ye);const Qe=this.stack[this.stack.length-1];Qe.value+=Ye}function He(Z){const ye=this.stack.pop();ye.position.end=Vr(Z.end)}function Se(Z){j.call(this,Z);const ye=this.stack[this.stack.length-1];ye.url=this.sliceSerialize(Z)}function Ve(Z){j.call(this,Z);const ye=this.stack[this.stack.length-1];ye.url="mailto:"+this.sliceSerialize(Z)}function ut(){return{type:"blockquote",children:[]}}function pn(){return{type:"code",lang:null,meta:null,value:""}}function Yi(){return{type:"inlineCode",value:""}}function Xr(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Xn(){return{type:"emphasis",children:[]}}function ha(){return{type:"heading",depth:0,children:[]}}function pa(){return{type:"break"}}function Wo(){return{type:"html",value:""}}function bl(){return{type:"image",title:null,url:"",alt:null}}function qo(){return{type:"link",title:null,url:"",children:[]}}function Jr(Z){return{type:"list",ordered:Z.type==="listOrdered",start:null,spread:Z._spread,children:[]}}function Zr(Z){return{type:"listItem",spread:Z._spread,checked:null,children:[]}}function ma(){return{type:"paragraph",children:[]}}function xl(){return{type:"strong",children:[]}}function _l(){return{type:"text",value:""}}function wl(){return{type:"thematicBreak"}}}function Vr(e){return{line:e.line,column:e.column,offset:e.offset}}function yg(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?yg(e,r):NC(e,r)}}function NC(e,t){let n;for(n in t)if(Eg.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 Tg(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Ps({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ps({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Ps({start:t.start,end:t.end})+") is still open")}function OC(e){const t=this;t.parser=n;function n(r){return CC(r,ne(U(U({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function IC(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 RC(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
27
27
  `}]}function PC(e,t){const n=t.value?t.value+`
28
- `:"",r={},o=t.lang?t.lang.split(/\s+/):[];o.length>0&&(r.className=["language-"+o[0]]);let a={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:"element",tagName:"pre",properties:{},children:[a]},e.patch(t,a),a}function LC(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function DC(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function MC(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),o=Eo(r.toLowerCase()),a=e.footnoteOrder.indexOf(r);let u,c=e.footnoteCounts.get(r);c===void 0?(c=0,e.footnoteOrder.push(r),u=e.footnoteOrder.length):u=a+1,c+=1,e.footnoteCounts.set(r,c);const d={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(u)}]};e.patch(t,d);const h={type:"element",tagName:"sup",properties:{},children:[d]};return e.patch(t,h),e.applyData(t,h)}function FC(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 BC(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function wg(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),a=o[0];a&&a.type==="text"?a.value="["+a.value:o.unshift({type:"text",value:"["});const u=o[o.length-1];return u&&u.type==="text"?u.value+=r:o.push({type:"text",value:r}),o}function UC(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return wg(e,t);const o={src:Eo(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(o.title=r.title);const a={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,a),e.applyData(t,a)}function HC(e,t){const n={src:Eo(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 zC(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 jC(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return wg(e,t);const o={href:Eo(r.url||"")};r.title!==null&&r.title!==void 0&&(o.title=r.title);const a={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function $C(e,t){const n={href:Eo(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 VC(e,t,n){const r=e.all(t),o=n?YC(n):Ag(t),a={},u=[];if(typeof t.checked=="boolean"){const m=r[0];let g;m&&m.type==="element"&&m.tagName==="p"?g=m:(g={type:"element",tagName:"p",properties:{},children:[]},r.unshift(g)),g.children.length>0&&g.children.unshift({type:"text",value:" "}),g.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),a.className=["task-list-item"]}let c=-1;for(;++c<r.length;){const m=r[c];(o||c!==0||m.type!=="element"||m.tagName!=="p")&&u.push({type:"text",value:`
28
+ `:"",r={},o=t.lang?t.lang.split(/\s+/):[];o.length>0&&(r.className=["language-"+o[0]]);let a={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:"element",tagName:"pre",properties:{},children:[a]},e.patch(t,a),a}function LC(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function DC(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function MC(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),o=Eo(r.toLowerCase()),a=e.footnoteOrder.indexOf(r);let u,c=e.footnoteCounts.get(r);c===void 0?(c=0,e.footnoteOrder.push(r),u=e.footnoteOrder.length):u=a+1,c+=1,e.footnoteCounts.set(r,c);const d={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(u)}]};e.patch(t,d);const h={type:"element",tagName:"sup",properties:{},children:[d]};return e.patch(t,h),e.applyData(t,h)}function FC(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 BC(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function bg(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),a=o[0];a&&a.type==="text"?a.value="["+a.value:o.unshift({type:"text",value:"["});const u=o[o.length-1];return u&&u.type==="text"?u.value+=r:o.push({type:"text",value:r}),o}function UC(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return bg(e,t);const o={src:Eo(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(o.title=r.title);const a={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,a),e.applyData(t,a)}function HC(e,t){const n={src:Eo(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 zC(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 jC(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return bg(e,t);const o={href:Eo(r.url||"")};r.title!==null&&r.title!==void 0&&(o.title=r.title);const a={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function $C(e,t){const n={href:Eo(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 VC(e,t,n){const r=e.all(t),o=n?YC(n):xg(t),a={},u=[];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:[]}),a.className=["task-list-item"]}let c=-1;for(;++c<r.length;){const m=r[c];(o||c!==0||m.type!=="element"||m.tagName!=="p")&&u.push({type:"text",value:`
29
29
  `}),m.type==="element"&&m.tagName==="p"&&!o?u.push(...m.children):u.push(m)}const d=r[r.length-1];d&&(o||d.type!=="element"||d.tagName!=="p")&&u.push({type:"text",value:`
30
- `});const h={type:"element",tagName:"li",properties:a,children:u};return e.patch(t,h),e.applyData(t,h)}function YC(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=Ag(n[r])}return t}function Ag(e){const t=e.spread;return t==null?e.children.length>1:t}function WC(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 u=r[o];if(u.type==="element"&&u.tagName==="li"&&u.properties&&Array.isArray(u.properties.className)&&u.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const a={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function qC(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function GC(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function KC(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function QC(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const u={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],u),o.push(u)}if(n.length>0){const u={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},c=ar(t.children[1]),d=Su(t.children[t.children.length-1]);c&&d&&(u.position={start:c,end:d}),o.push(u)}const a={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,a),e.applyData(t,a)}function XC(e,t,n){const r=n?n.children:void 0,a=(r?r.indexOf(t):1)===0?"th":"td",u=n&&n.type==="table"?n.align:void 0,c=u?u.length:t.children.length;let d=-1;const h=[];for(;++d<c;){const g=t.children[d],T={},b=u?u[d]:void 0;b&&(T.align=b);let x={type:"element",tagName:a,properties:T,children:[]};g&&(x.children=e.all(g),e.patch(g,x),x=e.applyData(g,x)),h.push(x)}const m={type:"element",tagName:"tr",properties:{},children:e.wrap(h,!0)};return e.patch(t,m),e.applyData(t,m)}function JC(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const vg=9,Cg=32;function ZC(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const a=[];for(;r;)a.push(kg(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return a.push(kg(t.slice(o),o>0,!1)),a.join("")}function kg(e,t,n){let r=0,o=e.length;if(t){let a=e.codePointAt(r);for(;a===vg||a===Cg;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(o-1);for(;a===vg||a===Cg;)o--,a=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function ek(e,t){const n={type:"text",value:ZC(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function tk(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const nk={blockquote:IC,break:RC,code:PC,delete:LC,emphasis:DC,footnoteReference:MC,heading:FC,html:BC,imageReference:UC,image:HC,inlineCode:zC,linkReference:jC,link:$C,listItem:VC,list:WC,paragraph:qC,root:GC,strong:KC,table:QC,tableCell:JC,tableRow:XC,text:ek,thematicBreak:tk,toml:ku,yaml:ku,definition:ku,footnoteDefinition:ku};function ku(){}const Ng=-1,Nu=0,Bs=1,Ou=2,Ld=3,Dd=4,Md=5,Fd=6,Og=7,Ig=8,Rg=typeof self=="object"?self:globalThis,rk=(e,t)=>{const n=(o,a)=>(e.set(a,o),o),r=o=>{if(e.has(o))return e.get(o);const[a,u]=t[o];switch(a){case Nu:case Ng:return n(u,o);case Bs:{const c=n([],o);for(const d of u)c.push(r(d));return c}case Ou:{const c=n({},o);for(const[d,h]of u)c[r(d)]=r(h);return c}case Ld:return n(new Date(u),o);case Dd:{const{source:c,flags:d}=u;return n(new RegExp(c,d),o)}case Md:{const c=n(new Map,o);for(const[d,h]of u)c.set(r(d),r(h));return c}case Fd:{const c=n(new Set,o);for(const d of u)c.add(r(d));return c}case Og:{const{name:c,message:d}=u;return n(new Rg[c](d),o)}case Ig:return n(BigInt(u),o);case"BigInt":return n(Object(BigInt(u)),o);case"ArrayBuffer":return n(new Uint8Array(u).buffer,u);case"DataView":{const{buffer:c}=new Uint8Array(u);return n(new DataView(c),u)}}return n(new Rg[a](u),o)};return r},Pg=e=>rk(new Map,e)(0),To="",{toString:ik}={},{keys:ok}=Object,Us=e=>{const t=typeof e;if(t!=="object"||!e)return[Nu,t];const n=ik.call(e).slice(8,-1);switch(n){case"Array":return[Bs,To];case"Object":return[Ou,To];case"Date":return[Ld,To];case"RegExp":return[Dd,To];case"Map":return[Md,To];case"Set":return[Fd,To];case"DataView":return[Bs,n]}return n.includes("Array")?[Bs,n]:n.includes("Error")?[Og,n]:[Ou,n]},Iu=([e,t])=>e===Nu&&(t==="function"||t==="symbol"),sk=(e,t,n,r)=>{const o=(u,c)=>{const d=r.push(u)-1;return n.set(c,d),d},a=u=>{if(n.has(u))return n.get(u);let[c,d]=Us(u);switch(c){case Nu:{let m=u;switch(d){case"bigint":c=Ig,m=u.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+d);m=null;break;case"undefined":return o([Ng],u)}return o([c,m],u)}case Bs:{if(d){let T=u;return d==="DataView"?T=new Uint8Array(u.buffer):d==="ArrayBuffer"&&(T=new Uint8Array(u)),o([d,[...T]],u)}const m=[],g=o([c,m],u);for(const T of u)m.push(a(T));return g}case Ou:{if(d)switch(d){case"BigInt":return o([d,u.toString()],u);case"Boolean":case"Number":case"String":return o([d,u.valueOf()],u)}if(t&&"toJSON"in u)return a(u.toJSON());const m=[],g=o([c,m],u);for(const T of ok(u))(e||!Iu(Us(u[T])))&&m.push([a(T),a(u[T])]);return g}case Ld:return o([c,u.toISOString()],u);case Dd:{const{source:m,flags:g}=u;return o([c,{source:m,flags:g}],u)}case Md:{const m=[],g=o([c,m],u);for(const[T,b]of u)(e||!(Iu(Us(T))||Iu(Us(b))))&&m.push([a(T),a(b)]);return g}case Fd:{const m=[],g=o([c,m],u);for(const T of u)(e||!Iu(Us(T)))&&m.push(a(T));return g}}const{message:h}=u;return o([c,{name:d,message:h}],u)};return a},Lg=(e,{json:t,lossy:n}={})=>{const r=[];return sk(!(t||n),!!t,new Map,r)(e),r},Oi=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Pg(Lg(e,t)):structuredClone(e):(e,t)=>Pg(Lg(e,t));function ak(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 uk(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function lk(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||ak,r=e.options.footnoteBackLabel||uk,o=e.options.footnoteLabel||"Footnotes",a=e.options.footnoteLabelTagName||"h2",u=e.options.footnoteLabelProperties||{className:["sr-only"]},c=[];let d=-1;for(;++d<e.footnoteOrder.length;){const h=e.footnoteById.get(e.footnoteOrder[d]);if(!h)continue;const m=e.all(h),g=String(h.identifier).toUpperCase(),T=Eo(g.toLowerCase());let b=0;const x=[],S=e.footnoteCounts.get(g);for(;S!==void 0&&++b<=S;){x.length>0&&x.push({type:"text",value:" "});let O=typeof n=="string"?n:n(d,b);typeof O=="string"&&(O={type:"text",value:O}),x.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+T+(b>1?"-"+b:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(d,b),className:["data-footnote-backref"]},children:Array.isArray(O)?O:[O]})}const A=m[m.length-1];if(A&&A.type==="element"&&A.tagName==="p"){const O=A.children[A.children.length-1];O&&O.type==="text"?O.value+=" ":A.children.push({type:"text",value:" "}),A.children.push(...x)}else m.push(...x);const C={type:"element",tagName:"li",properties:{id:t+"fn-"+T},children:e.wrap(m,!0)};e.patch(h,C),c.push(C)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:ne(U({},Oi(u)),{id:"footnote-label"}),children:[{type:"text",value:o}]},{type:"text",value:`
30
+ `});const h={type:"element",tagName:"li",properties:a,children:u};return e.patch(t,h),e.applyData(t,h)}function YC(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=xg(n[r])}return t}function xg(e){const t=e.spread;return t==null?e.children.length>1:t}function WC(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 u=r[o];if(u.type==="element"&&u.tagName==="li"&&u.properties&&Array.isArray(u.properties.className)&&u.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const a={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function qC(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function GC(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function KC(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function QC(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const u={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],u),o.push(u)}if(n.length>0){const u={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},c=ar(t.children[1]),d=wu(t.children[t.children.length-1]);c&&d&&(u.position={start:c,end:d}),o.push(u)}const a={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,a),e.applyData(t,a)}function XC(e,t,n){const r=n?n.children:void 0,a=(r?r.indexOf(t):1)===0?"th":"td",u=n&&n.type==="table"?n.align:void 0,c=u?u.length:t.children.length;let d=-1;const h=[];for(;++d<c;){const E=t.children[d],T={},b=u?u[d]:void 0;b&&(T.align=b);let _={type:"element",tagName:a,properties:T,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 JC(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const _g=9,wg=32;function ZC(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const a=[];for(;r;)a.push(Sg(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return a.push(Sg(t.slice(o),o>0,!1)),a.join("")}function Sg(e,t,n){let r=0,o=e.length;if(t){let a=e.codePointAt(r);for(;a===_g||a===wg;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(o-1);for(;a===_g||a===wg;)o--,a=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function ek(e,t){const n={type:"text",value:ZC(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function tk(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const nk={blockquote:IC,break:RC,code:PC,delete:LC,emphasis:DC,footnoteReference:MC,heading:FC,html:BC,imageReference:UC,image:HC,inlineCode:zC,linkReference:jC,link:$C,listItem:VC,list:WC,paragraph:qC,root:GC,strong:KC,table:QC,tableCell:JC,tableRow:XC,text:ek,thematicBreak:tk,toml:ku,yaml:ku,definition:ku,footnoteDefinition:ku};function ku(){}const Ag=-1,Nu=0,Bs=1,Ou=2,Ld=3,Dd=4,Md=5,Fd=6,vg=7,Cg=8,kg=typeof self=="object"?self:globalThis,rk=(e,t)=>{const n=(o,a)=>(e.set(a,o),o),r=o=>{if(e.has(o))return e.get(o);const[a,u]=t[o];switch(a){case Nu:case Ag:return n(u,o);case Bs:{const c=n([],o);for(const d of u)c.push(r(d));return c}case Ou:{const c=n({},o);for(const[d,h]of u)c[r(d)]=r(h);return c}case Ld:return n(new Date(u),o);case Dd:{const{source:c,flags:d}=u;return n(new RegExp(c,d),o)}case Md:{const c=n(new Map,o);for(const[d,h]of u)c.set(r(d),r(h));return c}case Fd:{const c=n(new Set,o);for(const d of u)c.add(r(d));return c}case vg:{const{name:c,message:d}=u;return n(new kg[c](d),o)}case Cg:return n(BigInt(u),o);case"BigInt":return n(Object(BigInt(u)),o);case"ArrayBuffer":return n(new Uint8Array(u).buffer,u);case"DataView":{const{buffer:c}=new Uint8Array(u);return n(new DataView(c),u)}}return n(new kg[a](u),o)};return r},Ng=e=>rk(new Map,e)(0),To="",{toString:ik}={},{keys:ok}=Object,Us=e=>{const t=typeof e;if(t!=="object"||!e)return[Nu,t];const n=ik.call(e).slice(8,-1);switch(n){case"Array":return[Bs,To];case"Object":return[Ou,To];case"Date":return[Ld,To];case"RegExp":return[Dd,To];case"Map":return[Md,To];case"Set":return[Fd,To];case"DataView":return[Bs,n]}return n.includes("Array")?[Bs,n]:n.includes("Error")?[vg,n]:[Ou,n]},Iu=([e,t])=>e===Nu&&(t==="function"||t==="symbol"),sk=(e,t,n,r)=>{const o=(u,c)=>{const d=r.push(u)-1;return n.set(c,d),d},a=u=>{if(n.has(u))return n.get(u);let[c,d]=Us(u);switch(c){case Nu:{let m=u;switch(d){case"bigint":c=Cg,m=u.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+d);m=null;break;case"undefined":return o([Ag],u)}return o([c,m],u)}case Bs:{if(d){let T=u;return d==="DataView"?T=new Uint8Array(u.buffer):d==="ArrayBuffer"&&(T=new Uint8Array(u)),o([d,[...T]],u)}const m=[],E=o([c,m],u);for(const T of u)m.push(a(T));return E}case Ou:{if(d)switch(d){case"BigInt":return o([d,u.toString()],u);case"Boolean":case"Number":case"String":return o([d,u.valueOf()],u)}if(t&&"toJSON"in u)return a(u.toJSON());const m=[],E=o([c,m],u);for(const T of ok(u))(e||!Iu(Us(u[T])))&&m.push([a(T),a(u[T])]);return E}case Ld:return o([c,u.toISOString()],u);case Dd:{const{source:m,flags:E}=u;return o([c,{source:m,flags:E}],u)}case Md:{const m=[],E=o([c,m],u);for(const[T,b]of u)(e||!(Iu(Us(T))||Iu(Us(b))))&&m.push([a(T),a(b)]);return E}case Fd:{const m=[],E=o([c,m],u);for(const T of u)(e||!Iu(Us(T)))&&m.push(a(T));return E}}const{message:h}=u;return o([c,{name:d,message:h}],u)};return a},Og=(e,{json:t,lossy:n}={})=>{const r=[];return sk(!(t||n),!!t,new Map,r)(e),r},Ii=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Ng(Og(e,t)):structuredClone(e):(e,t)=>Ng(Og(e,t));function ak(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 uk(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function lk(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||ak,r=e.options.footnoteBackLabel||uk,o=e.options.footnoteLabel||"Footnotes",a=e.options.footnoteLabelTagName||"h2",u=e.options.footnoteLabelProperties||{className:["sr-only"]},c=[];let d=-1;for(;++d<e.footnoteOrder.length;){const h=e.footnoteById.get(e.footnoteOrder[d]);if(!h)continue;const m=e.all(h),E=String(h.identifier).toUpperCase(),T=Eo(E.toLowerCase());let b=0;const _=[],w=e.footnoteCounts.get(E);for(;w!==void 0&&++b<=w;){_.length>0&&_.push({type:"text",value:" "});let I=typeof n=="string"?n:n(d,b);typeof I=="string"&&(I={type:"text",value:I}),_.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+T+(b>1?"-"+b:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(d,b),className:["data-footnote-backref"]},children:Array.isArray(I)?I:[I]})}const A=m[m.length-1];if(A&&A.type==="element"&&A.tagName==="p"){const I=A.children[A.children.length-1];I&&I.type==="text"?I.value+=" ":A.children.push({type:"text",value:" "}),A.children.push(..._)}else m.push(..._);const C={type:"element",tagName:"li",properties:{id:t+"fn-"+T},children:e.wrap(m,!0)};e.patch(h,C),c.push(C)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:ne(U({},Ii(u)),{id:"footnote-label"}),children:[{type:"text",value:o}]},{type:"text",value:`
31
31
  `},{type:"element",tagName:"ol",properties:{},children:e.wrap(c,!0)},{type:"text",value:`
32
- `}]}}const Ru=(function(e){if(e==null)return hk;if(typeof e=="function")return Pu(e);if(typeof e=="object")return Array.isArray(e)?ck(e):dk(e);if(typeof e=="string")return fk(e);throw new Error("Expected function, string, or object as test")});function ck(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Ru(e[n]);return Pu(r);function r(...o){let a=-1;for(;++a<t.length;)if(t[a].apply(this,o))return!0;return!1}}function dk(e){const t=e;return Pu(n);function n(r){const o=r;let a;for(a in e)if(o[a]!==t[a])return!1;return!0}}function fk(e){return Pu(t);function t(n){return n&&n.type===e}}function Pu(e){return t;function t(n,r,o){return!!(pk(n)&&e.call(this,n,typeof r=="number"?r:void 0,o||void 0))}}function hk(){return!0}function pk(e){return e!==null&&typeof e=="object"&&"type"in e}function uF(e){return e}const Dg=[],mk=!0,Bd=!1,gk="skip";function Mg(e,t,n,r){let o;typeof t=="function"&&typeof n!="function"?(r=n,n=t):o=t;const a=Ru(o),u=r?-1:1;c(e,void 0,[])();function c(d,h,m){const g=d&&typeof d=="object"?d:{};if(typeof g.type=="string"){const b=typeof g.tagName=="string"?g.tagName:typeof g.name=="string"?g.name:void 0;Object.defineProperty(T,"name",{value:"node ("+(d.type+(b?"<"+b+">":""))+")"})}return T;function T(){let b=Dg,x,S,A;if((!t||a(d,h,m[m.length-1]||void 0))&&(b=Ek(n(d,m)),b[0]===Bd))return b;if("children"in d&&d.children){const C=d;if(C.children&&b[0]!==gk)for(S=(r?C.children.length:-1)+u,A=m.concat(C);S>-1&&S<C.children.length;){const O=C.children[S];if(x=c(O,S,A)(),x[0]===Bd)return x;S=typeof x[1]=="number"?x[1]:S+u}}return b}}}function Ek(e){return Array.isArray(e)?e:typeof e=="number"?[mk,e]:e==null?Dg:[e]}function Lu(e,t,n,r){let o,a,u;typeof t=="function"&&typeof n!="function"?(a=void 0,u=t,o=n):(a=t,u=n,o=r),Mg(e,a,c,o);function c(d,h){const m=h[h.length-1],g=m?m.children.indexOf(d):void 0;return u(d,g,m)}}const Ud={}.hasOwnProperty,yk={};function Tk(e,t){const n=t||yk,r=new Map,o=new Map,a=new Map,u=U(U({},nk),n.handlers),c={all:h,applyData:xk,definitionById:r,footnoteById:o,footnoteCounts:a,footnoteOrder:[],handlers:u,one:d,options:n,patch:bk,wrap:Sk};return Lu(e,function(m){if(m.type==="definition"||m.type==="footnoteDefinition"){const g=m.type==="definition"?r:o,T=String(m.identifier).toUpperCase();g.has(T)||g.set(T,m)}}),c;function d(m,g){const T=m.type,b=c.handlers[T];if(Ud.call(c.handlers,T)&&b)return b(c,m,g);if(c.options.passThrough&&c.options.passThrough.includes(T)){if("children"in m){const S=m,{children:A}=S,C=rn(S,["children"]),O=Oi(C);return O.children=c.all(m),O}return Oi(m)}return(c.options.unknownHandler||_k)(c,m,g)}function h(m){const g=[];if("children"in m){const T=m.children;let b=-1;for(;++b<T.length;){const x=c.one(T[b],m);if(x){if(b&&T[b-1].type==="break"&&(!Array.isArray(x)&&x.type==="text"&&(x.value=Fg(x.value)),!Array.isArray(x)&&x.type==="element")){const S=x.children[0];S&&S.type==="text"&&(S.value=Fg(S.value))}Array.isArray(x)?g.push(...x):g.push(x)}}}return g}}function bk(e,t){e.position&&(t.position=W0(e))}function xk(e,t){let n=t;if(e&&e.data){const r=e.data.hName,o=e.data.hChildren,a=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const u="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:u}}n.type==="element"&&a&&Object.assign(n.properties,Oi(a)),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function _k(e,t){const n=t.data||{},r="value"in t&&!(Ud.call(n,"hProperties")||Ud.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 Sk(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
32
+ `}]}}const Ru=(function(e){if(e==null)return hk;if(typeof e=="function")return Pu(e);if(typeof e=="object")return Array.isArray(e)?ck(e):dk(e);if(typeof e=="string")return fk(e);throw new Error("Expected function, string, or object as test")});function ck(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Ru(e[n]);return Pu(r);function r(...o){let a=-1;for(;++a<t.length;)if(t[a].apply(this,o))return!0;return!1}}function dk(e){const t=e;return Pu(n);function n(r){const o=r;let a;for(a in e)if(o[a]!==t[a])return!1;return!0}}function fk(e){return Pu(t);function t(n){return n&&n.type===e}}function Pu(e){return t;function t(n,r,o){return!!(pk(n)&&e.call(this,n,typeof r=="number"?r:void 0,o||void 0))}}function hk(){return!0}function pk(e){return e!==null&&typeof e=="object"&&"type"in e}function dF(e){return e}const Ig=[],mk=!0,Bd=!1,gk="skip";function Rg(e,t,n,r){let o;typeof t=="function"&&typeof n!="function"?(r=n,n=t):o=t;const a=Ru(o),u=r?-1:1;c(e,void 0,[])();function c(d,h,m){const E=d&&typeof d=="object"?d:{};if(typeof E.type=="string"){const b=typeof E.tagName=="string"?E.tagName:typeof E.name=="string"?E.name:void 0;Object.defineProperty(T,"name",{value:"node ("+(d.type+(b?"<"+b+">":""))+")"})}return T;function T(){let b=Ig,_,w,A;if((!t||a(d,h,m[m.length-1]||void 0))&&(b=Ek(n(d,m)),b[0]===Bd))return b;if("children"in d&&d.children){const C=d;if(C.children&&b[0]!==gk)for(w=(r?C.children.length:-1)+u,A=m.concat(C);w>-1&&w<C.children.length;){const I=C.children[w];if(_=c(I,w,A)(),_[0]===Bd)return _;w=typeof _[1]=="number"?_[1]:w+u}}return b}}}function Ek(e){return Array.isArray(e)?e:typeof e=="number"?[mk,e]:e==null?Ig:[e]}function Lu(e,t,n,r){let o,a,u;typeof t=="function"&&typeof n!="function"?(a=void 0,u=t,o=n):(a=t,u=n,o=r),Rg(e,a,c,o);function c(d,h){const m=h[h.length-1],E=m?m.children.indexOf(d):void 0;return u(d,E,m)}}const Ud={}.hasOwnProperty,yk={};function Tk(e,t){const n=t||yk,r=new Map,o=new Map,a=new Map,u=U(U({},nk),n.handlers),c={all:h,applyData:xk,definitionById:r,footnoteById:o,footnoteCounts:a,footnoteOrder:[],handlers:u,one:d,options:n,patch:bk,wrap:wk};return Lu(e,function(m){if(m.type==="definition"||m.type==="footnoteDefinition"){const E=m.type==="definition"?r:o,T=String(m.identifier).toUpperCase();E.has(T)||E.set(T,m)}}),c;function d(m,E){const T=m.type,b=c.handlers[T];if(Ud.call(c.handlers,T)&&b)return b(c,m,E);if(c.options.passThrough&&c.options.passThrough.includes(T)){if("children"in m){const w=m,{children:A}=w,C=on(w,["children"]),I=Ii(C);return I.children=c.all(m),I}return Ii(m)}return(c.options.unknownHandler||_k)(c,m,E)}function h(m){const E=[];if("children"in m){const T=m.children;let b=-1;for(;++b<T.length;){const _=c.one(T[b],m);if(_){if(b&&T[b-1].type==="break"&&(!Array.isArray(_)&&_.type==="text"&&(_.value=Pg(_.value)),!Array.isArray(_)&&_.type==="element")){const w=_.children[0];w&&w.type==="text"&&(w.value=Pg(w.value))}Array.isArray(_)?E.push(..._):E.push(_)}}}return E}}function bk(e,t){e.position&&(t.position=j0(e))}function xk(e,t){let n=t;if(e&&e.data){const r=e.data.hName,o=e.data.hChildren,a=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const u="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:u}}n.type==="element"&&a&&Object.assign(n.properties,Ii(a)),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function _k(e,t){const n=t.data||{},r="value"in t&&!(Ud.call(n,"hProperties")||Ud.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 wk(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
33
33
  `});++r<e.length;)r&&n.push({type:"text",value:`
34
34
  `}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
35
- `}),n}function Fg(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function Bg(e,t){const n=Tk(e,t),r=n.one(e,void 0),o=lk(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&a.children.push({type:"text",value:`
36
- `},o),a}function wk(e,t){return e&&"run"in e?function(n,r){return et(this,null,function*(){const o=Bg(n,U({file:r},t));yield e.run(o,r)})}:function(n,r){return Bg(n,U({file:r},e||t))}}function Ug(e){if(e)throw e}var Hd,Hg;function Ak(){if(Hg)return Hd;Hg=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]"},a=function(h){if(!h||t.call(h)!=="[object Object]")return!1;var m=e.call(h,"constructor"),g=h.constructor&&h.constructor.prototype&&e.call(h.constructor.prototype,"isPrototypeOf");if(h.constructor&&!m&&!g)return!1;var T;for(T in h);return typeof T=="undefined"||e.call(h,T)},u=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 Hd=function d(){var h,m,g,T,b,x,S=arguments[0],A=1,C=arguments.length,O=!1;for(typeof S=="boolean"&&(O=S,S=arguments[1]||{},A=2),(S==null||typeof S!="object"&&typeof S!="function")&&(S={});A<C;++A)if(h=arguments[A],h!=null)for(m in h)g=c(S,m),T=c(h,m),S!==T&&(O&&T&&(a(T)||(b=o(T)))?(b?(b=!1,x=g&&o(g)?g:[]):x=g&&a(g)?g:{},u(S,{name:m,newValue:d(O,x,T)})):typeof T!="undefined"&&u(S,{name:m,newValue:T}));return S},Hd}var vk=Ak();const zd=We(vk);function jd(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 Ck(){const e=[],t={run:n,use:r};return t;function n(...o){let a=-1;const u=o.pop();if(typeof u!="function")throw new TypeError("Expected function as last argument, not "+u);c(null,...o);function c(d,...h){const m=e[++a];let g=-1;if(d){u(d);return}for(;++g<o.length;)(h[g]===null||h[g]===void 0)&&(h[g]=o[g]);o=h,m?kk(m,c)(...h):u(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 kk(e,t){let n;return r;function r(...u){const c=e.length>u.length;let d;c&&u.push(o);try{d=e.apply(this,u)}catch(h){const m=h;if(c&&n)throw m;return o(m)}c||(d&&d.then&&typeof d.then=="function"?d.then(a,o):d instanceof Error?o(d):a(d))}function o(u,...c){n||(n=!0,t(u,...c))}function a(u){o(null,u)}}const ur={basename:Nk,dirname:Ok,extname:Ik,join:Rk,sep:"/"};function Nk(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Hs(e);let n=0,r=-1,o=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(a){n=o+1;break}}else r<0&&(a=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let u=-1,c=t.length-1;for(;o--;)if(e.codePointAt(o)===47){if(a){n=o+1;break}}else u<0&&(a=!0,u=o+1),c>-1&&(e.codePointAt(o)===t.codePointAt(c--)?c<0&&(r=o):(c=-1,r=u));return n===r?r=u:r<0&&(r=e.length),e.slice(n,r)}function Ok(e){if(Hs(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 Ik(e){Hs(e);let t=e.length,n=-1,r=0,o=-1,a=0,u;for(;t--;){const c=e.codePointAt(t);if(c===47){if(u){r=t+1;break}continue}n<0&&(u=!0,n=t+1),c===46?o<0?o=t:a!==1&&(a=1):o>-1&&(a=-1)}return o<0||n<0||a===0||a===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function Rk(...e){let t=-1,n;for(;++t<e.length;)Hs(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Pk(n)}function Pk(e){Hs(e);const t=e.codePointAt(0)===47;let n=Lk(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Lk(e,t){let n="",r=0,o=-1,a=0,u=-1,c,d;for(;++u<=e.length;){if(u<e.length)c=e.codePointAt(u);else{if(c===47)break;c=47}if(c===47){if(!(o===u-1||a===1))if(o!==u-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(d=n.lastIndexOf("/"),d!==n.length-1){d<0?(n="",r=0):(n=n.slice(0,d),r=n.length-1-n.lastIndexOf("/")),o=u,a=0;continue}}else if(n.length>0){n="",r=0,o=u,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,u):n=e.slice(o+1,u),r=u-o-1;o=u,a=0}else c===46&&a>-1?a++:a=-1}return n}function Hs(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Dk={cwd:Mk};function Mk(){return"/"}function $d(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function Fk(e){if(typeof e=="string")e=new URL(e);else if(!$d(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 Bk(e)}function Bk(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 Vd=["history","path","basename","stem","extname","dirname"];class zg{constructor(t){let n;t?$d(t)?n={path:t}:typeof t=="string"||Uk(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":Dk.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<Vd.length;){const a=Vd[r];a in n&&n[a]!==void 0&&n[a]!==null&&(this[a]=a==="history"?[...n[a]]:n[a])}let o;for(o in n)Vd.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?ur.basename(this.path):void 0}set basename(t){Wd(t,"basename"),Yd(t,"basename"),this.path=ur.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?ur.dirname(this.path):void 0}set dirname(t){jg(this.basename,"dirname"),this.path=ur.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?ur.extname(this.path):void 0}set extname(t){if(Yd(t,"extname"),jg(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=ur.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){$d(t)&&(t=Fk(t)),Wd(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?ur.basename(this.path,this.extname):void 0}set stem(t){Wd(t,"stem"),Yd(t,"stem"),this.path=ur.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 Yt(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 Yd(e,t){if(e&&e.includes(ur.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+ur.sep+"`")}function Wd(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function jg(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function Uk(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Hk=(function(e){const r=this.constructor.prototype,o=r[e],a=function(){return o.apply(a,arguments)};return Object.setPrototypeOf(a,r),a}),zk={}.hasOwnProperty;class qd extends Hk{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=Ck()}copy(){const t=new qd;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?(Qd("data",this.frozen),this.namespace[t]=n,this):zk.call(this.namespace,t)&&this.namespace[t]||void 0:t?(Qd("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=Du(t),r=this.parser||this.Parser;return Gd("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Gd("process",this.parser||this.Parser),Kd("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(a,u){const c=Du(t),d=r.parse(c);r.run(d,c,function(m,g,T){if(m||!g||!T)return h(m);const b=g,x=r.stringify(b,T);Vk(x)?T.value=x:T.result=x,h(m,T)});function h(m,g){m||!g?u(m):a?a(g):n(void 0,g)}}}processSync(t){let n=!1,r;return this.freeze(),Gd("processSync",this.parser||this.Parser),Kd("processSync",this.compiler||this.Compiler),this.process(t,o),Vg("processSync","process",n),r;function o(a,u){n=!0,Ug(a),r=u}}run(t,n,r){$g(t),this.freeze();const o=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?a(void 0,r):new Promise(a);function a(u,c){const d=Du(n);o.run(t,d,h);function h(m,g,T){const b=g||t;m?c(m):u?u(b):r(void 0,b,T)}}}runSync(t,n){let r=!1,o;return this.run(t,n,a),Vg("runSync","run",r),o;function a(u,c){Ug(u),o=c,r=!0}}stringify(t,n){this.freeze();const r=Du(n),o=this.compiler||this.Compiler;return Kd("stringify",o),$g(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(Qd("use",this.frozen),t!=null)if(typeof t=="function")d(t,n);else if(typeof t=="object")Array.isArray(t)?c(t):u(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(h){if(typeof h=="function")d(h,[]);else if(typeof h=="object")if(Array.isArray(h)){const[m,...g]=h;d(m,g)}else u(h);else throw new TypeError("Expected usable value, not `"+h+"`")}function u(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 g=h[m];a(g)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function d(h,m){let g=-1,T=-1;for(;++g<r.length;)if(r[g][0]===h){T=g;break}if(T===-1)r.push([h,...m]);else if(m.length>0){let[b,...x]=m;const S=r[T][1];jd(S)&&jd(b)&&(b=zd(!0,S,b)),r[T]=[h,b,...x]}}}}const jk=new qd().freeze();function Gd(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Kd(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Qd(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 $g(e){if(!jd(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Vg(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Du(e){return $k(e)?e:new zg(e)}function $k(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Vk(e){return typeof e=="string"||Yk(e)}function Yk(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Wk="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",Yg=[],Wg={allowDangerousHtml:!0},qk=/^(https?|ircs?|mailto|xmpp)$/i,Gk=[{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 qg(e){const t=Kk(e),n=Qk(e);return Xk(t.runSync(t.parse(n),n),e)}function Kk(e){const t=e.rehypePlugins||Yg,n=e.remarkPlugins||Yg,r=e.remarkRehypeOptions?U(U({},e.remarkRehypeOptions),Wg):Wg;return jk().use(OC).use(n).use(wk,r).use(t)}function Qk(e){const t=e.children||"",n=new zg;return typeof t=="string"&&(n.value=t),n}function Xk(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,a=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,d=t.urlTransform||Jk;for(const m of Gk)Object.hasOwn(t,m.from)&&(""+m.from+(m.to?"use `"+m.to+"` instead":"remove it")+Wk+m.id,void 0);return Lu(e,h),_A(e,{Fragment:P.Fragment,components:o,ignoreInvalidStyle:!0,jsx:P.jsx,jsxs:P.jsxs,passKeys:!0,passNode:!0});function h(m,g,T){if(m.type==="raw"&&T&&typeof g=="number")return u?T.children.splice(g,1):T.children[g]={type:"text",value:m.value},g;if(m.type==="element"){let b;for(b in vd)if(Object.hasOwn(vd,b)&&Object.hasOwn(m.properties,b)){const x=m.properties[b],S=vd[b];(S===null||S.includes(m.tagName))&&(m.properties[b]=d(String(x||""),b,m))}}if(m.type==="element"){let b=n?!n.includes(m.tagName):a?a.includes(m.tagName):!1;if(!b&&r&&typeof g=="number"&&(b=!r(m,g,T)),b&&T&&typeof g=="number")return c&&m.children?T.children.splice(g,1,...m.children):T.children.splice(g,1),g}}}function Jk(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||qk.test(e.slice(0,t))?e:""}const Gg=/[#.]/g;function Zk(e,t){const n=e||"",r={};let o=0,a,u;for(;o<n.length;){Gg.lastIndex=o;const c=Gg.exec(n),d=n.slice(o,c?c.index:n.length);d&&(a?a==="#"?r.id=d:Array.isArray(r.className)?r.className.push(d):r.className=[d]:u=d,o+=d.length),c&&(a=c[0],o++)}return{type:"element",tagName:u||t||"div",properties:r,children:[]}}function Kg(e,t,n){const r=n?rN(n):void 0;function o(a,u,...c){let d;if(a==null){d={type:"root",children:[]};const h=u;c.unshift(h)}else{d=Zk(a,t);const h=d.tagName.toLowerCase(),m=r?r.get(h):void 0;if(d.tagName=m||h,eN(u))c.unshift(u);else for(const[g,T]of Object.entries(u))tN(e,d.properties,g,T)}for(const h of c)Xd(d.children,h);return d.type==="element"&&d.tagName==="template"&&(d.content={type:"root",children:d.children},d.children=[]),d}return o}function eN(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 a=o;for(const u of a)if(typeof u!="number"&&typeof u!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function tN(e,t,n,r){const o=bd(e,n);let a;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;a=r}else typeof r=="boolean"?a=r:typeof r=="string"?o.spaceSeparated?a=U0(r):o.commaSeparated?a=v0(r):o.commaOrSpaceSeparated?a=U0(v0(r).join(" ")):a=Qg(o,o.property,r):Array.isArray(r)?a=[...r]:a=o.property==="style"?nN(r):String(r);if(Array.isArray(a)){const u=[];for(const c of a)u.push(Qg(o,o.property,c));a=u}o.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[o.property]=a}}function Xd(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)Xd(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?Xd(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function Qg(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||Os(n)===Os(t)))return!0}return n}function nN(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function rN(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const iN=["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"],oN=Kg(_u,"div"),sN=Kg(mo,"g",iN);function aN(e){const t=String(e),n=[];return{toOffset:o,toPoint:r};function r(a){if(typeof a=="number"&&a>-1&&a<=t.length){let u=0;for(;;){let c=n[u];if(c===void 0){const d=Xg(t,n[u-1]);c=d===-1?t.length+1:d+1,n[u]=c}if(c>a)return{line:u+1,column:a-(u>0?n[u-1]:0)+1,offset:a};u++}}}function o(a){if(a&&typeof a.line=="number"&&typeof a.column=="number"&&!Number.isNaN(a.line)&&!Number.isNaN(a.column)){for(;n.length<a.line;){const c=n[n.length-1],d=Xg(t,c),h=d===-1?t.length+1:d+1;if(c===h)break;n.push(h)}const u=(a.line>1?n[a.line-2]:0)+a.column-1;if(u<n[a.line-1])return u}}}function Xg(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
37
- `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ii={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/"},Jg={}.hasOwnProperty,uN=Object.prototype;function lN(e,t){const n=t||{};return Jd({file:n.file||void 0,location:!1,schema:n.space==="svg"?mo:_u,verbose:n.verbose||!1},e)}function Jd(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Mu(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:Zg(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const a=String(e.file),u=aN(a),c=u.toPoint(0),d=u.toPoint(a.length);n.position={start:c,end:d}}return n}case"#documentType":{const r=t;return n={type:"doctype"},Mu(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Mu(e,r,n),n}default:return n=cN(e,t),n}}function Zg(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=Jd(e,t[n]);r.push(o)}return r}function cN(e,t){const n=e.schema;e.schema=t.namespaceURI===Ii.svg?mo:_u;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],d=(c.prefix?c.prefix+":":"")+c.name;Jg.call(uN,d)||(o[d]=c.value)}const u=(e.schema.space==="svg"?sN:oN)(t.tagName,o,Zg(e,t.childNodes));if(Mu(e,t,u),u.tagName==="template"){const c=t,d=c.sourceCodeLocation,h=d&&d.startTag&&bo(d.startTag),m=d&&d.endTag&&bo(d.endTag),g=Jd(e,c.content);h&&m&&e.file&&(g.position={start:h.end,end:m.start}),u.content=g}return e.schema=n,u}function Mu(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=dN(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function dN(e,t,n){const r=bo(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 a={};let u;if(n.attrs)for(u in n.attrs)Jg.call(n.attrs,u)&&(a[bd(e.schema,u).property]=bo(n.attrs[u]));n.startTag;const c=bo(n.startTag),d=n.endTag?bo(n.endTag):void 0,h={opening:c};d&&(h.closing=d),h.properties=a,t.data={position:h}}}return r}function bo(e){const t=e1({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=e1({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function e1(e){return e.line&&e.column?e:void 0}class zs{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}zs.prototype.property={},zs.prototype.normal={},zs.prototype.space=null;function t1(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 zs(n,r,t)}function Zd(e){return e.toLowerCase()}class Pn{constructor(t,n){this.property=t,this.attribute=n}}Pn.prototype.space=null,Pn.prototype.boolean=!1,Pn.prototype.booleanish=!1,Pn.prototype.overloadedBoolean=!1,Pn.prototype.number=!1,Pn.prototype.commaSeparated=!1,Pn.prototype.spaceSeparated=!1,Pn.prototype.commaOrSpaceSeparated=!1,Pn.prototype.mustUseProperty=!1,Pn.prototype.defined=!1;let fN=0;const ze=Ri(),vt=Ri(),n1=Ri(),me=Ri(),st=Ri(),xo=Ri(),_n=Ri();function Ri(){return Ja(2,++fN)}const ef=Object.freeze(Object.defineProperty({__proto__:null,boolean:ze,booleanish:vt,commaOrSpaceSeparated:_n,commaSeparated:xo,number:me,overloadedBoolean:n1,spaceSeparated:st},Symbol.toStringTag,{value:"Module"})),tf=Object.keys(ef);class nf extends Pn{constructor(t,n,r,o){let a=-1;if(super(t,n),r1(this,"space",o),typeof r=="number")for(;++a<tf.length;){const u=tf[a];r1(this,tf[a],(r&ef[u])===ef[u])}}}nf.prototype.defined=!0;function r1(e,t,n){n&&(e[t]=n)}const hN={}.hasOwnProperty;function _o(e){const t={},n={};let r;for(r in e.properties)if(hN.call(e.properties,r)){const o=e.properties[r],a=new nf(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Zd(r)]=r,n[Zd(a.attribute)]=r}return new zs(t,n,e.space)}const i1=_o({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}}),o1=_o({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function s1(e,t){return t in e?e[t]:t}function a1(e,t){return s1(e,t.toLowerCase())}const u1=_o({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:a1,properties:{xmlns:null,xmlnsXLink:null}}),l1=_o({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:vt,ariaAutoComplete:null,ariaBusy:vt,ariaChecked:vt,ariaColCount:me,ariaColIndex:me,ariaColSpan:me,ariaControls:st,ariaCurrent:null,ariaDescribedBy:st,ariaDetails:null,ariaDisabled:vt,ariaDropEffect:st,ariaErrorMessage:null,ariaExpanded:vt,ariaFlowTo:st,ariaGrabbed:vt,ariaHasPopup:null,ariaHidden:vt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:st,ariaLevel:me,ariaLive:null,ariaModal:vt,ariaMultiLine:vt,ariaMultiSelectable:vt,ariaOrientation:null,ariaOwns:st,ariaPlaceholder:null,ariaPosInSet:me,ariaPressed:vt,ariaReadOnly:vt,ariaRelevant:null,ariaRequired:vt,ariaRoleDescription:st,ariaRowCount:me,ariaRowIndex:me,ariaRowSpan:me,ariaSelected:vt,ariaSetSize:me,ariaSort:null,ariaValueMax:me,ariaValueMin:me,ariaValueNow:me,ariaValueText:null,role:null}}),pN=_o({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:a1,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:xo,acceptCharset:st,accessKey:st,action:null,allow:null,allowFullScreen:ze,allowPaymentRequest:ze,allowUserMedia:ze,alt:null,as:null,async:ze,autoCapitalize:null,autoComplete:st,autoFocus:ze,autoPlay:ze,blocking:st,capture:null,charSet:null,checked:ze,cite:null,className:st,cols:me,colSpan:null,content:null,contentEditable:vt,controls:ze,controlsList:st,coords:me|xo,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ze,defer:ze,dir:null,dirName:null,disabled:ze,download:n1,draggable:vt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:ze,formTarget:null,headers:st,height:me,hidden:ze,high:me,href:null,hrefLang:null,htmlFor:st,httpEquiv:st,id:null,imageSizes:null,imageSrcSet:null,inert:ze,inputMode:null,integrity:null,is:null,isMap:ze,itemId:null,itemProp:st,itemRef:st,itemScope:ze,itemType:st,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:ze,low:me,manifest:null,max:null,maxLength:me,media:null,method:null,min:null,minLength:me,multiple:ze,muted:ze,name:null,nonce:null,noModule:ze,noValidate:ze,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:ze,optimum:me,pattern:null,ping:st,placeholder:null,playsInline:ze,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:ze,referrerPolicy:null,rel:st,required:ze,reversed:ze,rows:me,rowSpan:me,sandbox:st,scope:null,scoped:ze,seamless:ze,selected:ze,shadowRootClonable:ze,shadowRootDelegatesFocus:ze,shadowRootMode:null,shape:null,size:me,sizes:null,slot:null,span:me,spellCheck:vt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:me,step:null,style:null,tabIndex:me,target:null,title:null,translate:null,type:null,typeMustMatch:ze,useMap:null,value:vt,width:me,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:st,axis:null,background:null,bgColor:null,border:me,borderColor:null,bottomMargin:me,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:ze,declare:ze,event:null,face:null,frame:null,frameBorder:null,hSpace:me,leftMargin:me,link:null,longDesc:null,lowSrc:null,marginHeight:me,marginWidth:me,noResize:ze,noHref:ze,noShade:ze,noWrap:ze,object:null,profile:null,prompt:null,rev:null,rightMargin:me,rules:null,scheme:null,scrolling:vt,standby:null,summary:null,text:null,topMargin:me,valueType:null,version:null,vAlign:null,vLink:null,vSpace:me,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:ze,disableRemotePlayback:ze,prefix:null,property:null,results:me,security:null,unselectable:null}}),mN=_o({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:s1,properties:{about:_n,accentHeight:me,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:me,amplitude:me,arabicForm:null,ascent:me,attributeName:null,attributeType:null,azimuth:me,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:me,by:null,calcMode:null,capHeight:me,className:st,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:me,diffuseConstant:me,direction:null,display:null,dur:null,divisor:me,dominantBaseline:null,download:ze,dx:null,dy:null,edgeMode:null,editable:null,elevation:me,enableBackground:null,end:null,event:null,exponent:me,externalResourcesRequired:null,fill:null,fillOpacity:me,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:xo,g2:xo,glyphName:xo,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:me,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:me,horizOriginX:me,horizOriginY:me,id:null,ideographic:me,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:me,k:me,k1:me,k2:me,k3:me,k4:me,kernelMatrix:_n,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:me,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:me,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:me,overlineThickness:me,paintOrder:null,panose1:null,path:null,pathLength:me,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:st,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:me,pointsAtY:me,pointsAtZ:me,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:_n,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:_n,rev:_n,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:_n,requiredFeatures:_n,requiredFonts:_n,requiredFormats:_n,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:me,specularExponent:me,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:me,strikethroughThickness:me,string:null,stroke:null,strokeDashArray:_n,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:me,strokeOpacity:me,strokeWidth:null,style:null,surfaceScale:me,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:_n,tabIndex:me,tableValues:null,target:null,targetX:me,targetY:me,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:_n,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:me,underlineThickness:me,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:me,values:null,vAlphabetic:me,vMathematical:me,vectorEffect:null,vHanging:me,vIdeographic:me,version:null,vertAdvY:me,vertOriginX:me,vertOriginY:me,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:me,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),gN=/^data[-\w.:]+$/i,c1=/-[a-z]/g,EN=/[A-Z]/g;function yN(e,t){const n=Zd(t);let r=t,o=Pn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&gN.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(c1,bN);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!c1.test(a)){let u=a.replace(EN,TN);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=nf}return new o(r,t)}function TN(e){return"-"+e.toLowerCase()}function bN(e){return e.charAt(1).toUpperCase()}const xN=t1([o1,i1,u1,l1,pN],"html"),d1=t1([o1,i1,u1,l1,mN],"svg"),f1={}.hasOwnProperty;function h1(e,t){const n=t||{};function r(o,...a){let u=r.invalid;const c=r.handlers;if(o&&f1.call(o,e)){const d=String(o[e]);u=f1.call(c,d)?c[d]:r.unknown}if(u)return u.call(this,o,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const _N={},SN={}.hasOwnProperty,p1=h1("type",{handlers:{root:AN,element:ON,text:kN,comment:NN,doctype:CN}});function wN(e,t){const r=(t||_N).space;return p1(e,r==="svg"?d1:xN)}function AN(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=rf(e.children,n,t),So(e,n),n}function vN(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=rf(e.children,n,t),So(e,n),n}function CN(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return So(e,t),t}function kN(e){const t={nodeName:"#text",value:e.value,parentNode:null};return So(e,t),t}function NN(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return So(e,t),t}function ON(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=d1);const o=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&SN.call(e.properties,a)){const d=IN(r,a,e.properties[a]);d&&o.push(d)}}const u=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Ii[u],childNodes:[],parentNode:null};return c.childNodes=rf(e.children,c,r),So(e,c),e.tagName==="template"&&e.content&&(c.content=vN(e.content,r)),c}function IN(e,t,n){const r=yN(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?C0(n):H0(n));const o={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=o.name.indexOf(":");a<0?o.prefix="":(o.name=o.name.slice(a+1),o.prefix=r.attribute.slice(0,a)),o.namespace=Ii[r.space]}return o}function rf(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const a=p1(e[r],n);a.parentNode=t,o.push(a)}return o}function So(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 RN=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],PN=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]),ft="�";var v;(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"})(v||(v={}));const fn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function m1(e){return e>=55296&&e<=57343}function LN(e){return e>=56320&&e<=57343}function DN(e,t){return(e-55296)*1024+9216+t}function g1(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function E1(e){return e>=64976&&e<=65007||PN.has(e)}var Q;(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"})(Q||(Q={}));const MN=65536;class FN{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=MN,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:a}=this,u=o+n,c=a+n;return{code:t,startLine:r,endLine:r,startCol:u,endCol:u,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(LN(n))return this.pos++,this._addGap(),DN(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,v.EOF;return this._err(Q.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,v.EOF;const r=this.html.charCodeAt(n);return r===v.CARRIAGE_RETURN?v.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,v.EOF;let t=this.html.charCodeAt(this.pos);return t===v.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,v.LINE_FEED):t===v.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,m1(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===v.LINE_FEED||t===v.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){g1(t)?this._err(Q.controlCharacterInInputStream):E1(t)&&this._err(Q.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var $e;(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"})($e||($e={}));function y1(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 BN=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))),UN=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 HN(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=UN.get(e))!==null&&t!==void 0?t:e}var Pt;(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"})(Pt||(Pt={}));const zN=32;var Yr;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Yr||(Yr={}));function of(e){return e>=Pt.ZERO&&e<=Pt.NINE}function jN(e){return e>=Pt.UPPER_A&&e<=Pt.UPPER_F||e>=Pt.LOWER_A&&e<=Pt.LOWER_F}function $N(e){return e>=Pt.UPPER_A&&e<=Pt.UPPER_Z||e>=Pt.LOWER_A&&e<=Pt.LOWER_Z||of(e)}function VN(e){return e===Pt.EQUALS||$N(e)}var Lt;(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"})(Lt||(Lt={}));var wr;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(wr||(wr={}));class YN{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Lt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=wr.Strict}startEntity(t){this.decodeMode=t,this.state=Lt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Lt.EntityStart:return t.charCodeAt(n)===Pt.NUM?(this.state=Lt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Lt.NamedEntity,this.stateNamedEntity(t,n));case Lt.NumericStart:return this.stateNumericStart(t,n);case Lt.NumericDecimal:return this.stateNumericDecimal(t,n);case Lt.NumericHex:return this.stateNumericHex(t,n);case Lt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|zN)===Pt.LOWER_X?(this.state=Lt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Lt.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,o){if(n!==r){const a=r-n;this.result=this.result*Math.pow(o,a)+Number.parseInt(t.substr(n,a),o),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const o=t.charCodeAt(n);if(of(o)||jN(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(of(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===Pt.SEMI)this.consumed+=1;else if(this.decodeMode===wr.Strict)return 0;return this.emitCodePoint(HN(this.result),this.consumed),this.errors&&(t!==Pt.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const u=t.charCodeAt(n);if(this.treeIndex=WN(r,o,this.treeIndex+Math.max(1,a),u),this.treeIndex<0)return this.result===0||this.decodeMode===wr.Attribute&&(a===0||VN(u))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14,a!==0){if(u===Pt.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==wr.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]&Yr.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]&~Yr.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Lt.NamedEntity:return this.result!==0&&(this.decodeMode!==wr.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Lt.NumericDecimal:return this.emitNumericEntity(0,2);case Lt.NumericHex:return this.emitNumericEntity(0,3);case Lt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Lt.EntityStart:return 0}}}function WN(e,t,n,r){const o=(t&Yr.BRANCH_LENGTH)>>7,a=t&Yr.JUMP_TABLE;if(o===0)return a!==0&&r===a?n:-1;if(a){const d=r-a;return d<0||d>=o?-1:e[n+d]-1}let u=n,c=u+o-1;for(;u<=c;){const d=u+c>>>1,h=e[d];if(h<r)u=d+1;else if(h>r)c=d-1;else return e[d+o]}return-1}var oe;(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/"})(oe||(oe={}));var Pi;(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"})(Pi||(Pi={}));var Ln;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Ln||(Ln={}));var Y;(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"})(Y||(Y={}));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 qN=new Map([[Y.A,p.A],[Y.ADDRESS,p.ADDRESS],[Y.ANNOTATION_XML,p.ANNOTATION_XML],[Y.APPLET,p.APPLET],[Y.AREA,p.AREA],[Y.ARTICLE,p.ARTICLE],[Y.ASIDE,p.ASIDE],[Y.B,p.B],[Y.BASE,p.BASE],[Y.BASEFONT,p.BASEFONT],[Y.BGSOUND,p.BGSOUND],[Y.BIG,p.BIG],[Y.BLOCKQUOTE,p.BLOCKQUOTE],[Y.BODY,p.BODY],[Y.BR,p.BR],[Y.BUTTON,p.BUTTON],[Y.CAPTION,p.CAPTION],[Y.CENTER,p.CENTER],[Y.CODE,p.CODE],[Y.COL,p.COL],[Y.COLGROUP,p.COLGROUP],[Y.DD,p.DD],[Y.DESC,p.DESC],[Y.DETAILS,p.DETAILS],[Y.DIALOG,p.DIALOG],[Y.DIR,p.DIR],[Y.DIV,p.DIV],[Y.DL,p.DL],[Y.DT,p.DT],[Y.EM,p.EM],[Y.EMBED,p.EMBED],[Y.FIELDSET,p.FIELDSET],[Y.FIGCAPTION,p.FIGCAPTION],[Y.FIGURE,p.FIGURE],[Y.FONT,p.FONT],[Y.FOOTER,p.FOOTER],[Y.FOREIGN_OBJECT,p.FOREIGN_OBJECT],[Y.FORM,p.FORM],[Y.FRAME,p.FRAME],[Y.FRAMESET,p.FRAMESET],[Y.H1,p.H1],[Y.H2,p.H2],[Y.H3,p.H3],[Y.H4,p.H4],[Y.H5,p.H5],[Y.H6,p.H6],[Y.HEAD,p.HEAD],[Y.HEADER,p.HEADER],[Y.HGROUP,p.HGROUP],[Y.HR,p.HR],[Y.HTML,p.HTML],[Y.I,p.I],[Y.IMG,p.IMG],[Y.IMAGE,p.IMAGE],[Y.INPUT,p.INPUT],[Y.IFRAME,p.IFRAME],[Y.KEYGEN,p.KEYGEN],[Y.LABEL,p.LABEL],[Y.LI,p.LI],[Y.LINK,p.LINK],[Y.LISTING,p.LISTING],[Y.MAIN,p.MAIN],[Y.MALIGNMARK,p.MALIGNMARK],[Y.MARQUEE,p.MARQUEE],[Y.MATH,p.MATH],[Y.MENU,p.MENU],[Y.META,p.META],[Y.MGLYPH,p.MGLYPH],[Y.MI,p.MI],[Y.MO,p.MO],[Y.MN,p.MN],[Y.MS,p.MS],[Y.MTEXT,p.MTEXT],[Y.NAV,p.NAV],[Y.NOBR,p.NOBR],[Y.NOFRAMES,p.NOFRAMES],[Y.NOEMBED,p.NOEMBED],[Y.NOSCRIPT,p.NOSCRIPT],[Y.OBJECT,p.OBJECT],[Y.OL,p.OL],[Y.OPTGROUP,p.OPTGROUP],[Y.OPTION,p.OPTION],[Y.P,p.P],[Y.PARAM,p.PARAM],[Y.PLAINTEXT,p.PLAINTEXT],[Y.PRE,p.PRE],[Y.RB,p.RB],[Y.RP,p.RP],[Y.RT,p.RT],[Y.RTC,p.RTC],[Y.RUBY,p.RUBY],[Y.S,p.S],[Y.SCRIPT,p.SCRIPT],[Y.SEARCH,p.SEARCH],[Y.SECTION,p.SECTION],[Y.SELECT,p.SELECT],[Y.SOURCE,p.SOURCE],[Y.SMALL,p.SMALL],[Y.SPAN,p.SPAN],[Y.STRIKE,p.STRIKE],[Y.STRONG,p.STRONG],[Y.STYLE,p.STYLE],[Y.SUB,p.SUB],[Y.SUMMARY,p.SUMMARY],[Y.SUP,p.SUP],[Y.TABLE,p.TABLE],[Y.TBODY,p.TBODY],[Y.TEMPLATE,p.TEMPLATE],[Y.TEXTAREA,p.TEXTAREA],[Y.TFOOT,p.TFOOT],[Y.TD,p.TD],[Y.TH,p.TH],[Y.THEAD,p.THEAD],[Y.TITLE,p.TITLE],[Y.TR,p.TR],[Y.TRACK,p.TRACK],[Y.TT,p.TT],[Y.U,p.U],[Y.UL,p.UL],[Y.SVG,p.SVG],[Y.VAR,p.VAR],[Y.WBR,p.WBR],[Y.XMP,p.XMP]]);function wo(e){var t;return(t=qN.get(e))!==null&&t!==void 0?t:p.UNKNOWN}const le=p,GN={[oe.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]),[oe.MATHML]:new Set([le.MI,le.MO,le.MN,le.MS,le.MTEXT,le.ANNOTATION_XML]),[oe.SVG]:new Set([le.TITLE,le.FOREIGN_OBJECT,le.DESC]),[oe.XLINK]:new Set,[oe.XML]:new Set,[oe.XMLNS]:new Set},sf=new Set([le.H1,le.H2,le.H3,le.H4,le.H5,le.H6]);Y.STYLE,Y.SCRIPT,Y.XMP,Y.IFRAME,Y.NOEMBED,Y.NOFRAMES,Y.PLAINTEXT;var N;(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"})(N||(N={}));const xt={DATA:N.DATA,RCDATA:N.RCDATA,RAWTEXT:N.RAWTEXT,SCRIPT_DATA:N.SCRIPT_DATA,PLAINTEXT:N.PLAINTEXT,CDATA_SECTION:N.CDATA_SECTION};function KN(e){return e>=v.DIGIT_0&&e<=v.DIGIT_9}function js(e){return e>=v.LATIN_CAPITAL_A&&e<=v.LATIN_CAPITAL_Z}function QN(e){return e>=v.LATIN_SMALL_A&&e<=v.LATIN_SMALL_Z}function Wr(e){return QN(e)||js(e)}function T1(e){return Wr(e)||KN(e)}function Fu(e){return e+32}function b1(e){return e===v.SPACE||e===v.LINE_FEED||e===v.TABULATION||e===v.FORM_FEED}function x1(e){return b1(e)||e===v.SOLIDUS||e===v.GREATER_THAN_SIGN}function XN(e){return e===v.NULL?Q.nullCharacterReference:e>1114111?Q.characterReferenceOutsideUnicodeRange:m1(e)?Q.surrogateCharacterReference:E1(e)?Q.noncharacterCharacterReference:g1(e)||e===v.CARRIAGE_RETURN?Q.controlCharacterReference:null}class JN{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=N.DATA,this.returnState=N.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new FN(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new YN(BN,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(Q.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(Q.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=XN(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:$e.START_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:$e.END_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:$e.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:$e.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(y1(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(Q.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=wo(t.tagName),t.type===$e.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(Q.endTagWithAttributes),t.selfClosing&&this._err(Q.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 $e.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case $e.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case $e.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:$e.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=b1(t)?$e.WHITESPACE_CHARACTER:t===v.NULL?$e.NULL_CHARACTER:$e.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken($e.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=N.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?wr.Attribute:wr.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===N.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case N.DATA:{this._stateData(t);break}case N.RCDATA:{this._stateRcdata(t);break}case N.RAWTEXT:{this._stateRawtext(t);break}case N.SCRIPT_DATA:{this._stateScriptData(t);break}case N.PLAINTEXT:{this._statePlaintext(t);break}case N.TAG_OPEN:{this._stateTagOpen(t);break}case N.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case N.TAG_NAME:{this._stateTagName(t);break}case N.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case N.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case N.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case N.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case N.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case N.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case N.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case N.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case N.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case N.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case N.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case N.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case N.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case N.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case N.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case N.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case N.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case N.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case N.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case N.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case N.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case N.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case N.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case N.BOGUS_COMMENT:{this._stateBogusComment(t);break}case N.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case N.COMMENT_START:{this._stateCommentStart(t);break}case N.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case N.COMMENT:{this._stateComment(t);break}case N.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case N.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case N.COMMENT_END:{this._stateCommentEnd(t);break}case N.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case N.DOCTYPE:{this._stateDoctype(t);break}case N.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case N.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case N.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case N.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case N.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case N.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case N.CDATA_SECTION:{this._stateCdataSection(t);break}case N.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case N.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case N.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case N.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case v.LESS_THAN_SIGN:{this.state=N.TAG_OPEN;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitCodePoint(t);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case v.AMPERSAND:{this._startCharacterReference();break}case v.LESS_THAN_SIGN:{this.state=N.RCDATA_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case v.LESS_THAN_SIGN:{this.state=N.RAWTEXT_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Wr(t))this._createStartTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case v.EXCLAMATION_MARK:{this.state=N.MARKUP_DECLARATION_OPEN;break}case v.SOLIDUS:{this.state=N.END_TAG_OPEN;break}case v.QUESTION_MARK:{this._err(Q.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t);break}case v.EOF:{this._err(Q.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(Q.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=N.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Wr(t))this._createEndTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case v.GREATER_THAN_SIGN:{this._err(Q.missingEndTagName),this.state=N.DATA;break}case v.EOF:{this._err(Q.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(Q.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_ATTRIBUTE_NAME;break}case v.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.tagName+=ft;break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(js(t)?Fu(t):t)}}_stateRcdataLessThanSign(t){t===v.SOLIDUS?this.state=N.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Wr(t)?(this.state=N.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=N.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 v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=N.BEFORE_ATTRIBUTE_NAME,!1;case v.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=N.SELF_CLOSING_START_TAG,!1;case v.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=N.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===v.SOLIDUS?this.state=N.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Wr(t)?(this.state=N.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case v.SOLIDUS:{this.state=N.SCRIPT_DATA_END_TAG_OPEN;break}case v.EXCLAMATION_MARK:{this.state=N.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=N.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===v.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===v.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case v.HYPHEN_MINUS:{this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case v.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===v.SOLIDUS?this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Wr(t)?(this._emitChars("<"),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&x1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case v.HYPHEN_MINUS:{this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case v.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===v.SOLIDUS?(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&x1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.SOLIDUS:case v.GREATER_THAN_SIGN:case v.EOF:{this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case v.EQUALS_SIGN:{this._err(Q.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=N.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:case v.SOLIDUS:case v.GREATER_THAN_SIGN:case v.EOF:{this._leaveAttrName(),this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case v.EQUALS_SIGN:{this._leaveAttrName(),this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case v.QUOTATION_MARK:case v.APOSTROPHE:case v.LESS_THAN_SIGN:{this._err(Q.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.name+=ft;break}default:this.currentAttr.name+=String.fromCodePoint(js(t)?Fu(t):t)}}_stateAfterAttributeName(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case v.EQUALS_SIGN:{this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.QUOTATION_MARK:{this.state=N.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this.state=N.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingAttributeValue),this.state=N.DATA,this.emitCurrentTagToken();break}default:this.state=N.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case v.QUOTATION_MARK:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case v.APOSTROPHE:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case v.QUOTATION_MARK:case v.APOSTROPHE:case v.LESS_THAN_SIGN:case v.EQUALS_SIGN:case v.GRAVE_ACCENT:{this._err(Q.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case v.SOLIDUS:{this._leaveAttrValue(),this.state=N.SELF_CLOSING_START_TAG;break}case v.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this._err(Q.missingWhitespaceBetweenAttributes),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case v.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=N.DATA,this.emitCurrentTagToken();break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this._err(Q.unexpectedSolidusInTag),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case v.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.data+=ft;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(fn.DASH_DASH,!0)?(this._createCommentToken(fn.DASH_DASH.length+1),this.state=N.COMMENT_START):this._consumeSequenceIfMatch(fn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(fn.DOCTYPE.length+1),this.state=N.DOCTYPE):this._consumeSequenceIfMatch(fn.CDATA_START,!0)?this.inForeignNode?this.state=N.CDATA_SECTION:(this._err(Q.cdataInHtmlContent),this._createCommentToken(fn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=N.BOGUS_COMMENT):this._ensureHibernation()||(this._err(Q.incorrectlyOpenedComment),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_START_DASH;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptClosingOfEmptyComment),this.state=N.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptClosingOfEmptyComment),this.state=N.DATA,this.emitCurrentComment(n);break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_END_DASH;break}case v.LESS_THAN_SIGN:{n.data+="<",this.state=N.COMMENT_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.data+=ft;break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case v.EXCLAMATION_MARK:{n.data+="!",this.state=N.COMMENT_LESS_THAN_SIGN_BANG;break}case v.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===v.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=N.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===v.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=N.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==v.GREATER_THAN_SIGN&&t!==v.EOF&&this._err(Q.nestedComment),this.state=N.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case v.EXCLAMATION_MARK:{this.state=N.COMMENT_END_BANG;break}case v.HYPHEN_MINUS:{n.data+="-";break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{n.data+="--!",this.state=N.COMMENT_END_DASH;break}case v.GREATER_THAN_SIGN:{this._err(Q.incorrectlyClosedComment),this.state=N.DATA,this.emitCurrentComment(n);break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=N.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_NAME;break}case v.GREATER_THAN_SIGN:{this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case v.EOF:{this._err(Q.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingWhitespaceBeforeDoctypeName),this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(js(t))this._createDoctypeToken(String.fromCharCode(Fu(t))),this.state=N.DOCTYPE_NAME;else switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.NULL:{this._err(Q.unexpectedNullCharacter),this._createDoctypeToken(ft),this.state=N.DOCTYPE_NAME;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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=N.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.AFTER_DOCTYPE_NAME;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.name+=ft;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(js(t)?Fu(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(fn.PUBLIC,!1)?this.state=N.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(fn.SYSTEM,!1)?this.state=N.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(Q.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case v.QUOTATION_MARK:{this._err(Q.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this._err(Q.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.QUOTATION_MARK:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case v.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.publicId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.publicId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.QUOTATION_MARK:{this._err(Q.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this._err(Q.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case v.QUOTATION_MARK:{this._err(Q.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this._err(Q.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case v.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.systemId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.systemId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case v.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.NULL:{this._err(Q.unexpectedNullCharacter);break}case v.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case v.RIGHT_SQUARE_BRACKET:{this.state=N.CDATA_SECTION_BRACKET;break}case v.EOF:{this._err(Q.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===v.RIGHT_SQUARE_BRACKET?this.state=N.CDATA_SECTION_END:(this._emitChars("]"),this.state=N.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case v.GREATER_THAN_SIGN:{this.state=N.DATA;break}case v.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=N.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(v.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&T1(this.preprocessor.peek(1))?N.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){T1(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===v.SEMICOLON&&this._err(Q.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const _1=new Set([p.DD,p.DT,p.LI,p.OPTGROUP,p.OPTION,p.P,p.RB,p.RP,p.RT,p.RTC]),S1=new Set([..._1,p.CAPTION,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]),Bu=new Set([p.APPLET,p.CAPTION,p.HTML,p.MARQUEE,p.OBJECT,p.TABLE,p.TD,p.TEMPLATE,p.TH]),ZN=new Set([...Bu,p.OL,p.UL]),e3=new Set([...Bu,p.BUTTON]),w1=new Set([p.ANNOTATION_XML,p.MI,p.MN,p.MO,p.MS,p.MTEXT]),A1=new Set([p.DESC,p.FOREIGN_OBJECT,p.TITLE]),t3=new Set([p.TR,p.TEMPLATE,p.HTML]),n3=new Set([p.TBODY,p.TFOOT,p.THEAD,p.TEMPLATE,p.HTML]),r3=new Set([p.TABLE,p.TEMPLATE,p.HTML]),i3=new Set([p.TD,p.TH]);class o3{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)===oe.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])!==oe.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(sf,oe.HTML)}popUntilTableCellPopped(){this.popUntilPopped(i3,oe.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(r3,oe.HTML)}clearBackToTableBodyContext(){this.clearBackTo(n3,oe.HTML)}clearBackToTableRowContext(){this.clearBackTo(t3,oe.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 oe.HTML:{if(o===t)return!0;if(n.has(o))return!1;break}case oe.SVG:{if(A1.has(o))return!1;break}case oe.MATHML:{if(w1.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Bu)}hasInListItemScope(t){return this.hasInDynamicScope(t,ZN)}hasInButtonScope(t){return this.hasInDynamicScope(t,e3)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case oe.HTML:{if(sf.has(n))return!0;if(Bu.has(n))return!1;break}case oe.SVG:{if(A1.has(n))return!1;break}case oe.MATHML:{if(w1.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===oe.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])===oe.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])===oe.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&&_1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&S1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&S1.has(this.currentTagId);)this.pop()}}const af=3;var lr;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(lr||(lr={}));const v1={type:lr.Marker};class s3{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],o=n.length,a=this.treeAdapter.getTagName(t),u=this.treeAdapter.getNamespaceURI(t);for(let c=0;c<this.entries.length;c++){const d=this.entries[c];if(d.type===lr.Marker)break;const{element:h}=d;if(this.treeAdapter.getTagName(h)===a&&this.treeAdapter.getNamespaceURI(h)===u){const m=this.treeAdapter.getAttrList(h);m.length===o&&r.push({idx:c,attrs:m})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<af)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<af)return;const o=new Map(n.map(u=>[u.name,u.value]));let a=0;for(let u=0;u<r.length;u++){const c=r[u];c.attrs.every(d=>o.get(d.name)===d.value)&&(a+=1,a>=af&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(v1)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:lr.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:lr.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(v1);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===lr.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===lr.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===lr.Element&&n.element===t)}}const qr={createDocument(){return{nodeName:"#document",mode:Ln.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(a=>a.nodeName==="#documentType");if(o)o.name=t,o.publicId=n,o.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};qr.appendChild(e,a)}},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(qr.isTextNode(n)){n.value+=t;return}}qr.appendChild(e,qr.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&qr.isTextNode(r)?r.value+=t:qr.insertBefore(e,qr.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)}},C1="html",a3="about:legacy-compat",u3="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",k1=["+//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//"],l3=[...k1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],c3=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),N1=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],d3=[...N1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function O1(e,t){return t.some(n=>e.startsWith(n))}function f3(e){return e.name===C1&&e.publicId===null&&(e.systemId===null||e.systemId===a3)}function h3(e){if(e.name!==C1)return Ln.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===u3)return Ln.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),c3.has(n))return Ln.QUIRKS;let r=t===null?l3:k1;if(O1(n,r))return Ln.QUIRKS;if(r=t===null?N1:d3,O1(n,r))return Ln.LIMITED_QUIRKS}return Ln.NO_QUIRKS}const I1={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},p3="definitionurl",m3="definitionURL",g3=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])),E3=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:oe.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:oe.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:oe.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:oe.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:oe.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:oe.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:oe.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:oe.XML}],["xml:space",{prefix:"xml",name:"space",namespace:oe.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:oe.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:oe.XMLNS}]]),y3=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])),T3=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 b3(e){const t=e.tagID;return t===p.FONT&&e.attrs.some(({name:r})=>r===Pi.COLOR||r===Pi.SIZE||r===Pi.FACE)||T3.has(t)}function R1(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===p3){e.attrs[t].name=m3;break}}function P1(e){for(let t=0;t<e.attrs.length;t++){const n=g3.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function uf(e){for(let t=0;t<e.attrs.length;t++){const n=E3.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 x3(e){const t=y3.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=wo(e.tagName))}function _3(e,t){return t===oe.MATHML&&(e===p.MI||e===p.MO||e===p.MN||e===p.MS||e===p.MTEXT)}function S3(e,t,n){if(t===oe.MATHML&&e===p.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Pi.ENCODING){const o=n[r].value.toLowerCase();return o===I1.TEXT_HTML||o===I1.APPLICATION_XML}}return t===oe.SVG&&(e===p.FOREIGN_OBJECT||e===p.DESC||e===p.TITLE)}function w3(e,t,n,r){return(!r||r===oe.HTML)&&S3(e,t,n)||(!r||r===oe.MATHML)&&_3(e,t)}const A3="hidden",v3=8,C3=3;var L;(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"})(L||(L={}));const k3={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},L1=new Set([p.TABLE,p.TBODY,p.TFOOT,p.THEAD,p.TR]),D1={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:qr,onParseError:null};class M1{constructor(t,n,r=null,o=null){this.fragmentContext=r,this.scriptHandler=o,this.currentToken=null,this.stopped=!1,this.insertionMode=L.INITIAL,this.originalInsertionMode=L.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({},D1),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 JN(this.options,this),this.activeFormattingElements=new s3(this.treeAdapter),this.fragmentContextID=r?wo(this.treeAdapter.getTagName(r)):p.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new o3(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({},D1),n);t!=null||(t=r.treeAdapter.createElement(Y.TEMPLATE,oe.HTML,[]));const o=r.treeAdapter.createElement("documentmock",oe.HTML,[]),a=new this(r,o,t);return a.fragmentContextID===p.TEMPLATE&&a.tmplInsertionModeStack.unshift(L.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}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 a=(o=t.location)!==null&&o!==void 0?o:k3,u={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(u)}onItemPush(t,n,r){var o,a;(a=(o=this.treeAdapter).onItemPush)===null||a===void 0||a.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 a,u;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,u=this.fragmentContextID):{current:a,currentTagId:u}=this.openElements,this._setContextModes(a,u)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===oe.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,oe.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=L.TEXT}switchToPlaintextParsing(){this.insertionMode=L.TEXT,this.originalInsertionMode=L.IN_BODY,this.tokenizer.state=xt.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)===Y.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==oe.HTML))switch(this.fragmentContextID){case p.TITLE:case p.TEXTAREA:{this.tokenizer.state=xt.RCDATA;break}case p.STYLE:case p.XMP:case p.IFRAME:case p.NOEMBED:case p.NOFRAMES:case p.NOSCRIPT:{this.tokenizer.state=xt.RAWTEXT;break}case p.SCRIPT:{this.tokenizer.state=xt.SCRIPT_DATA;break}case p.PLAINTEXT:{this.tokenizer.state=xt.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 u=this.treeAdapter.getChildNodes(this.document).find(c=>this.treeAdapter.isDocumentTypeNode(c));u&&this.treeAdapter.setNodeSourceCodeLocation(u,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&ne(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,oe.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,oe.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(Y.HTML,oe.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),a=r?o.lastIndexOf(r):o.length,u=o[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(u)){const{endLine:d,endCol:h,endOffset:m}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(u,{endLine:d,endCol:h,endOffset:m})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(u,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),a=n.type===$e.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,a)}}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)===Y.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===oe.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===p.MGLYPH||t.tagID===p.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,oe.HTML)}_processToken(t){switch(t.type){case $e.CHARACTER:{this.onCharacter(t);break}case $e.NULL_CHARACTER:{this.onNullCharacter(t);break}case $e.COMMENT:{this.onComment(t);break}case $e.DOCTYPE:{this.onDoctype(t);break}case $e.START_TAG:{this._processStartTag(t);break}case $e.END_TAG:{this.onEndTag(t);break}case $e.EOF:{this.onEof(t);break}case $e.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const o=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return w3(t,o,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===lr.Marker||this.openElements.contains(o.element)),r=n===-1?t-1:n-1;for(let o=r;o>=0;o--){const a=this.activeFormattingElements.entries[o];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=L.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=L.IN_ROW;return}case p.TBODY:case p.THEAD:case p.TFOOT:{this.insertionMode=L.IN_TABLE_BODY;return}case p.CAPTION:{this.insertionMode=L.IN_CAPTION;return}case p.COLGROUP:{this.insertionMode=L.IN_COLUMN_GROUP;return}case p.TABLE:{this.insertionMode=L.IN_TABLE;return}case p.BODY:{this.insertionMode=L.IN_BODY;return}case p.FRAMESET:{this.insertionMode=L.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?L.AFTER_HEAD:L.BEFORE_HEAD;return}case p.TD:case p.TH:{if(t>0){this.insertionMode=L.IN_CELL;return}break}case p.HEAD:{if(t>0){this.insertionMode=L.IN_HEAD;return}break}}this.insertionMode=L.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=L.IN_SELECT_IN_TABLE;return}}this.insertionMode=L.IN_SELECT}_isElementCausesFosterParenting(t){return L1.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)===oe.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 GN[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){iI(this,t);return}switch(this.insertionMode){case L.INITIAL:{$s(this,t);break}case L.BEFORE_HTML:{Vs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{qs(this,t);break}case L.AFTER_HEAD:{Gs(this,t);break}case L.IN_BODY:case L.IN_CAPTION:case L.IN_CELL:case L.IN_TEMPLATE:{B1(this,t);break}case L.TEXT:case L.IN_SELECT:case L.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{ff(this,t);break}case L.IN_TABLE_TEXT:{W1(this,t);break}case L.IN_COLUMN_GROUP:{zu(this,t);break}case L.AFTER_BODY:{Vu(this,t);break}case L.AFTER_AFTER_BODY:{Yu(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){rI(this,t);return}switch(this.insertionMode){case L.INITIAL:{$s(this,t);break}case L.BEFORE_HTML:{Vs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{qs(this,t);break}case L.AFTER_HEAD:{Gs(this,t);break}case L.TEXT:{this._insertCharacters(t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{ff(this,t);break}case L.IN_COLUMN_GROUP:{zu(this,t);break}case L.AFTER_BODY:{Vu(this,t);break}case L.AFTER_AFTER_BODY:{Yu(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){cf(this,t);return}switch(this.insertionMode){case L.INITIAL:case L.BEFORE_HTML:case L.BEFORE_HEAD:case L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:case L.IN_BODY:case L.IN_TABLE:case L.IN_CAPTION:case L.IN_COLUMN_GROUP:case L.IN_TABLE_BODY:case L.IN_ROW:case L.IN_CELL:case L.IN_SELECT:case L.IN_SELECT_IN_TABLE:case L.IN_TEMPLATE:case L.IN_FRAMESET:case L.AFTER_FRAMESET:{cf(this,t);break}case L.IN_TABLE_TEXT:{Xs(this,t);break}case L.AFTER_BODY:{D3(this,t);break}case L.AFTER_AFTER_BODY:case L.AFTER_AFTER_FRAMESET:{M3(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case L.INITIAL:{F3(this,t);break}case L.BEFORE_HEAD:case L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:{this._err(t,Q.misplacedDoctype);break}case L.IN_TABLE_TEXT:{Xs(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,Q.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?oI(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{$s(this,t);break}case L.BEFORE_HTML:{B3(this,t);break}case L.BEFORE_HEAD:{H3(this,t);break}case L.IN_HEAD:{qn(this,t);break}case L.IN_HEAD_NO_SCRIPT:{$3(this,t);break}case L.AFTER_HEAD:{Y3(this,t);break}case L.IN_BODY:{qt(this,t);break}case L.IN_TABLE:{Ao(this,t);break}case L.IN_TABLE_TEXT:{Xs(this,t);break}case L.IN_CAPTION:{zO(this,t);break}case L.IN_COLUMN_GROUP:{hf(this,t);break}case L.IN_TABLE_BODY:{ju(this,t);break}case L.IN_ROW:{$u(this,t);break}case L.IN_CELL:{VO(this,t);break}case L.IN_SELECT:{K1(this,t);break}case L.IN_SELECT_IN_TABLE:{WO(this,t);break}case L.IN_TEMPLATE:{GO(this,t);break}case L.AFTER_BODY:{QO(this,t);break}case L.IN_FRAMESET:{XO(this,t);break}case L.AFTER_FRAMESET:{ZO(this,t);break}case L.AFTER_AFTER_BODY:{tI(this,t);break}case L.AFTER_AFTER_FRAMESET:{nI(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?sI(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{$s(this,t);break}case L.BEFORE_HTML:{U3(this,t);break}case L.BEFORE_HEAD:{z3(this,t);break}case L.IN_HEAD:{j3(this,t);break}case L.IN_HEAD_NO_SCRIPT:{V3(this,t);break}case L.AFTER_HEAD:{W3(this,t);break}case L.IN_BODY:{Hu(this,t);break}case L.TEXT:{IO(this,t);break}case L.IN_TABLE:{Ks(this,t);break}case L.IN_TABLE_TEXT:{Xs(this,t);break}case L.IN_CAPTION:{jO(this,t);break}case L.IN_COLUMN_GROUP:{$O(this,t);break}case L.IN_TABLE_BODY:{pf(this,t);break}case L.IN_ROW:{G1(this,t);break}case L.IN_CELL:{YO(this,t);break}case L.IN_SELECT:{Q1(this,t);break}case L.IN_SELECT_IN_TABLE:{qO(this,t);break}case L.IN_TEMPLATE:{KO(this,t);break}case L.AFTER_BODY:{J1(this,t);break}case L.IN_FRAMESET:{JO(this,t);break}case L.AFTER_FRAMESET:{eI(this,t);break}case L.AFTER_AFTER_BODY:{Yu(this,t);break}}}onEof(t){switch(this.insertionMode){case L.INITIAL:{$s(this,t);break}case L.BEFORE_HTML:{Vs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{qs(this,t);break}case L.AFTER_HEAD:{Gs(this,t);break}case L.IN_BODY:case L.IN_TABLE:case L.IN_CAPTION:case L.IN_COLUMN_GROUP:case L.IN_TABLE_BODY:case L.IN_ROW:case L.IN_CELL:case L.IN_SELECT:case L.IN_SELECT_IN_TABLE:{V1(this,t);break}case L.TEXT:{RO(this,t);break}case L.IN_TABLE_TEXT:{Xs(this,t);break}case L.IN_TEMPLATE:{X1(this,t);break}case L.AFTER_BODY:case L.IN_FRAMESET:case L.AFTER_FRAMESET:case L.AFTER_AFTER_BODY:case L.AFTER_AFTER_FRAMESET:{df(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===v.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 L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:case L.TEXT:case L.IN_COLUMN_GROUP:case L.IN_SELECT:case L.IN_SELECT_IN_TABLE:case L.IN_FRAMESET:case L.AFTER_FRAMESET:{this._insertCharacters(t);break}case L.IN_BODY:case L.IN_CAPTION:case L.IN_CELL:case L.IN_TEMPLATE:case L.AFTER_BODY:case L.AFTER_AFTER_BODY:case L.AFTER_AFTER_FRAMESET:{F1(this,t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{ff(this,t);break}case L.IN_TABLE_TEXT:{Y1(this,t);break}}}}function N3(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):$1(e,t),n}function O3(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 I3(e,t,n){let r=t,o=e.openElements.getCommonAncestor(t);for(let a=0,u=o;u!==n;a++,u=o){o=e.openElements.getCommonAncestor(u);const c=e.activeFormattingElements.getElementEntry(u),d=c&&a>=C3;!c||d?(d&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(u)):(u=R3(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(u,r),r=u)}return r}function R3(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 P3(e,t,n){const r=e.treeAdapter.getTagName(t),o=wo(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);o===p.TEMPLATE&&a===oe.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function L3(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:o}=n,a=e.treeAdapter.createElement(o.tagName,r,o.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,o),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,o.tagID)}function lf(e,t){for(let n=0;n<v3;n++){const r=N3(e,t);if(!r)break;const o=O3(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const a=I3(e,o,r.element),u=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),u&&P3(e,u,a),L3(e,o,r)}}function cf(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function D3(e,t){e._appendCommentNode(t,e.openElements.items[0])}function M3(e,t){e._appendCommentNode(t,e.document)}function df(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 a=e.openElements.items[1],u=e.treeAdapter.getNodeSourceCodeLocation(a);u&&!u.endTag&&e._setEndLocation(a,t)}}}}function F3(e,t){e._setDocumentType(t);const n=t.forceQuirks?Ln.QUIRKS:h3(t);f3(t)||e._err(t,Q.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=L.BEFORE_HTML}function $s(e,t){e._err(t,Q.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Ln.QUIRKS),e.insertionMode=L.BEFORE_HTML,e._processToken(t)}function B3(e,t){t.tagID===p.HTML?(e._insertElement(t,oe.HTML),e.insertionMode=L.BEFORE_HEAD):Vs(e,t)}function U3(e,t){const n=t.tagID;(n===p.HTML||n===p.HEAD||n===p.BODY||n===p.BR)&&Vs(e,t)}function Vs(e,t){e._insertFakeRootElement(),e.insertionMode=L.BEFORE_HEAD,e._processToken(t)}function H3(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.HEAD:{e._insertElement(t,oe.HTML),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD;break}default:Ys(e,t)}}function z3(e,t){const n=t.tagID;n===p.HEAD||n===p.BODY||n===p.HTML||n===p.BR?Ys(e,t):e._err(t,Q.endTagWithoutMatchingOpenElement)}function Ys(e,t){e._insertFakeElement(Y.HEAD,p.HEAD),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD,e._processToken(t)}function qn(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:{e._appendElement(t,oe.HTML),t.ackSelfClosing=!0;break}case p.TITLE:{e._switchToTextParsing(t,xt.RCDATA);break}case p.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,xt.RAWTEXT):(e._insertElement(t,oe.HTML),e.insertionMode=L.IN_HEAD_NO_SCRIPT);break}case p.NOFRAMES:case p.STYLE:{e._switchToTextParsing(t,xt.RAWTEXT);break}case p.SCRIPT:{e._switchToTextParsing(t,xt.SCRIPT_DATA);break}case p.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=L.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(L.IN_TEMPLATE);break}case p.HEAD:{e._err(t,Q.misplacedStartTagForHeadElement);break}default:Ws(e,t)}}function j3(e,t){switch(t.tagID){case p.HEAD:{e.openElements.pop(),e.insertionMode=L.AFTER_HEAD;break}case p.BODY:case p.BR:case p.HTML:{Ws(e,t);break}case p.TEMPLATE:{Li(e,t);break}default:e._err(t,Q.endTagWithoutMatchingOpenElement)}}function Li(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==p.TEMPLATE&&e._err(t,Q.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,Q.endTagWithoutMatchingOpenElement)}function Ws(e,t){e.openElements.pop(),e.insertionMode=L.AFTER_HEAD,e._processToken(t)}function $3(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.BASEFONT:case p.BGSOUND:case p.HEAD:case p.LINK:case p.META:case p.NOFRAMES:case p.STYLE:{qn(e,t);break}case p.NOSCRIPT:{e._err(t,Q.nestedNoscriptInHead);break}default:qs(e,t)}}function V3(e,t){switch(t.tagID){case p.NOSCRIPT:{e.openElements.pop(),e.insertionMode=L.IN_HEAD;break}case p.BR:{qs(e,t);break}default:e._err(t,Q.endTagWithoutMatchingOpenElement)}}function qs(e,t){const n=t.type===$e.EOF?Q.openElementsLeftAfterEof:Q.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=L.IN_HEAD,e._processToken(t)}function Y3(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.BODY:{e._insertElement(t,oe.HTML),e.framesetOk=!1,e.insertionMode=L.IN_BODY;break}case p.FRAMESET:{e._insertElement(t,oe.HTML),e.insertionMode=L.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,Q.abandonedHeadElementChild),e.openElements.push(e.headElement,p.HEAD),qn(e,t),e.openElements.remove(e.headElement);break}case p.HEAD:{e._err(t,Q.misplacedStartTagForHeadElement);break}default:Gs(e,t)}}function W3(e,t){switch(t.tagID){case p.BODY:case p.HTML:case p.BR:{Gs(e,t);break}case p.TEMPLATE:{Li(e,t);break}default:e._err(t,Q.endTagWithoutMatchingOpenElement)}}function Gs(e,t){e._insertFakeElement(Y.BODY,p.BODY),e.insertionMode=L.IN_BODY,Uu(e,t)}function Uu(e,t){switch(t.type){case $e.CHARACTER:{B1(e,t);break}case $e.WHITESPACE_CHARACTER:{F1(e,t);break}case $e.COMMENT:{cf(e,t);break}case $e.START_TAG:{qt(e,t);break}case $e.END_TAG:{Hu(e,t);break}case $e.EOF:{V1(e,t);break}}}function F1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function B1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function q3(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function G3(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function K3(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,oe.HTML),e.insertionMode=L.IN_FRAMESET)}function Q3(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,oe.HTML)}function X3(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&sf.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,oe.HTML)}function J3(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,oe.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function Z3(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,oe.HTML),n||(e.formElement=e.openElements.current))}function eO(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,oe.HTML)}function tO(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,oe.HTML),e.tokenizer.state=xt.PLAINTEXT}function nO(e,t){e.openElements.hasInScope(p.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML),e.framesetOk=!1}function rO(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(Y.A);n&&(lf(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function iO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function oO(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(p.NOBR)&&(lf(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,oe.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function sO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function aO(e,t){e.treeAdapter.getDocumentMode(e.document)!==Ln.QUIRKS&&e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,oe.HTML),e.framesetOk=!1,e.insertionMode=L.IN_TABLE}function U1(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,oe.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function H1(e){const t=y1(e,Pi.TYPE);return t!=null&&t.toLowerCase()===A3}function uO(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,oe.HTML),H1(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function lO(e,t){e._appendElement(t,oe.HTML),t.ackSelfClosing=!0}function cO(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._appendElement(t,oe.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function dO(e,t){t.tagName=Y.IMG,t.tagID=p.IMG,U1(e,t)}function fO(e,t){e._insertElement(t,oe.HTML),e.skipNextNewLine=!0,e.tokenizer.state=xt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=L.TEXT}function hO(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function pO(e,t){e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function z1(e,t){e._switchToTextParsing(t,xt.RAWTEXT)}function mO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===L.IN_TABLE||e.insertionMode===L.IN_CAPTION||e.insertionMode===L.IN_TABLE_BODY||e.insertionMode===L.IN_ROW||e.insertionMode===L.IN_CELL?L.IN_SELECT_IN_TABLE:L.IN_SELECT}function gO(e,t){e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML)}function EO(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,oe.HTML)}function yO(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(p.RTC),e._insertElement(t,oe.HTML)}function TO(e,t){e._reconstructActiveFormattingElements(),R1(t),uf(t),t.selfClosing?e._appendElement(t,oe.MATHML):e._insertElement(t,oe.MATHML),t.ackSelfClosing=!0}function bO(e,t){e._reconstructActiveFormattingElements(),P1(t),uf(t),t.selfClosing?e._appendElement(t,oe.SVG):e._insertElement(t,oe.SVG),t.ackSelfClosing=!0}function j1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,oe.HTML)}function qt(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:{iO(e,t);break}case p.A:{rO(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{X3(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:{Q3(e,t);break}case p.LI:case p.DD:case p.DT:{eO(e,t);break}case p.BR:case p.IMG:case p.WBR:case p.AREA:case p.EMBED:case p.KEYGEN:{U1(e,t);break}case p.HR:{cO(e,t);break}case p.RB:case p.RTC:{EO(e,t);break}case p.RT:case p.RP:{yO(e,t);break}case p.PRE:case p.LISTING:{J3(e,t);break}case p.XMP:{hO(e,t);break}case p.SVG:{bO(e,t);break}case p.HTML:{q3(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:{qn(e,t);break}case p.BODY:{G3(e,t);break}case p.FORM:{Z3(e,t);break}case p.NOBR:{oO(e,t);break}case p.MATH:{TO(e,t);break}case p.TABLE:{aO(e,t);break}case p.INPUT:{uO(e,t);break}case p.PARAM:case p.TRACK:case p.SOURCE:{lO(e,t);break}case p.IMAGE:{dO(e,t);break}case p.BUTTON:{nO(e,t);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{sO(e,t);break}case p.IFRAME:{pO(e,t);break}case p.SELECT:{mO(e,t);break}case p.OPTION:case p.OPTGROUP:{gO(e,t);break}case p.NOEMBED:case p.NOFRAMES:{z1(e,t);break}case p.FRAMESET:{K3(e,t);break}case p.TEXTAREA:{fO(e,t);break}case p.NOSCRIPT:{e.options.scriptingEnabled?z1(e,t):j1(e,t);break}case p.PLAINTEXT:{tO(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:j1(e,t)}}function xO(e,t){if(e.openElements.hasInScope(p.BODY)&&(e.insertionMode=L.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function _O(e,t){e.openElements.hasInScope(p.BODY)&&(e.insertionMode=L.AFTER_BODY,J1(e,t))}function SO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function wO(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 AO(e){e.openElements.hasInButtonScope(p.P)||e._insertFakeElement(Y.P,p.P),e._closePElement()}function vO(e){e.openElements.hasInListItemScope(p.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(p.LI),e.openElements.popUntilTagNamePopped(p.LI))}function CO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function kO(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function NO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function OO(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(Y.BR,p.BR),e.openElements.pop(),e.framesetOk=!1}function $1(e,t){const n=t.tagName,r=t.tagID;for(let o=e.openElements.stackTop;o>0;o--){const a=e.openElements.items[o],u=e.openElements.tagIDs[o];if(r===u&&(r!==p.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=o&&e.openElements.shortenToLength(o);break}if(e._isSpecialElement(a,u))break}}function Hu(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:{lf(e,t);break}case p.P:{AO(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:{SO(e,t);break}case p.LI:{vO(e);break}case p.DD:case p.DT:{CO(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{kO(e);break}case p.BR:{OO(e);break}case p.BODY:{xO(e,t);break}case p.HTML:{_O(e,t);break}case p.FORM:{wO(e);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{NO(e,t);break}case p.TEMPLATE:{Li(e,t);break}default:$1(e,t)}}function V1(e,t){e.tmplInsertionModeStack.length>0?X1(e,t):df(e,t)}function IO(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 RO(e,t){e._err(t,Q.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function ff(e,t){if(e.openElements.currentTagId!==void 0&&L1.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=L.IN_TABLE_TEXT,t.type){case $e.CHARACTER:{W1(e,t);break}case $e.WHITESPACE_CHARACTER:{Y1(e,t);break}}else Qs(e,t)}function PO(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,oe.HTML),e.insertionMode=L.IN_CAPTION}function LO(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,oe.HTML),e.insertionMode=L.IN_COLUMN_GROUP}function DO(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.COLGROUP,p.COLGROUP),e.insertionMode=L.IN_COLUMN_GROUP,hf(e,t)}function MO(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,oe.HTML),e.insertionMode=L.IN_TABLE_BODY}function FO(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.TBODY,p.TBODY),e.insertionMode=L.IN_TABLE_BODY,ju(e,t)}function BO(e,t){e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function UO(e,t){H1(t)?e._appendElement(t,oe.HTML):Qs(e,t),t.ackSelfClosing=!0}function HO(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,oe.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Ao(e,t){switch(t.tagID){case p.TD:case p.TH:case p.TR:{FO(e,t);break}case p.STYLE:case p.SCRIPT:case p.TEMPLATE:{qn(e,t);break}case p.COL:{DO(e,t);break}case p.FORM:{HO(e,t);break}case p.TABLE:{BO(e,t);break}case p.TBODY:case p.TFOOT:case p.THEAD:{MO(e,t);break}case p.INPUT:{UO(e,t);break}case p.CAPTION:{PO(e,t);break}case p.COLGROUP:{LO(e,t);break}default:Qs(e,t)}}function Ks(e,t){switch(t.tagID){case p.TABLE:{e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode());break}case p.TEMPLATE:{Li(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:Qs(e,t)}}function Qs(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,Uu(e,t),e.fosterParentingEnabled=n}function Y1(e,t){e.pendingCharacterTokens.push(t)}function W1(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Xs(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Qs(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const q1=new Set([p.CAPTION,p.COL,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]);function zO(e,t){const n=t.tagID;q1.has(n)?e.openElements.hasInTableScope(p.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,Ao(e,t)):qt(e,t)}function jO(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=L.IN_TABLE,n===p.TABLE&&Ks(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:Hu(e,t)}}function hf(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.COL:{e._appendElement(t,oe.HTML),t.ackSelfClosing=!0;break}case p.TEMPLATE:{qn(e,t);break}default:zu(e,t)}}function $O(e,t){switch(t.tagID){case p.COLGROUP:{e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE);break}case p.TEMPLATE:{Li(e,t);break}case p.COL:break;default:zu(e,t)}}function zu(e,t){e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE,e._processToken(t))}function ju(e,t){switch(t.tagID){case p.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,oe.HTML),e.insertionMode=L.IN_ROW;break}case p.TH:case p.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(Y.TR,p.TR),e.insertionMode=L.IN_ROW,$u(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=L.IN_TABLE,Ao(e,t));break}default:Ao(e,t)}}function pf(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=L.IN_TABLE);break}case p.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE,Ks(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:Ks(e,t)}}function $u(e,t){switch(t.tagID){case p.TH:case p.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,oe.HTML),e.insertionMode=L.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=L.IN_TABLE_BODY,ju(e,t));break}default:Ao(e,t)}}function G1(e,t){switch(t.tagID){case p.TR:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY);break}case p.TABLE:{e.openElements.hasInTableScope(p.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,pf(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=L.IN_TABLE_BODY,pf(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:Ks(e,t)}}function VO(e,t){const n=t.tagID;q1.has(n)?(e.openElements.hasInTableScope(p.TD)||e.openElements.hasInTableScope(p.TH))&&(e._closeTableCell(),$u(e,t)):qt(e,t)}function YO(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=L.IN_ROW);break}case p.TABLE:case p.TBODY:case p.TFOOT:case p.THEAD:case p.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),G1(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:break;default:Hu(e,t)}}function K1(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.OPTION:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._insertElement(t,oe.HTML);break}case p.OPTGROUP:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._insertElement(t,oe.HTML);break}case p.HR:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._appendElement(t,oe.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:{qn(e,t);break}}}function Q1(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:{Li(e,t);break}}}function WO(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)):K1(e,t)}function qO(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)):Q1(e,t)}function GO(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:{qn(e,t);break}case p.CAPTION:case p.COLGROUP:case p.TBODY:case p.TFOOT:case p.THEAD:{e.tmplInsertionModeStack[0]=L.IN_TABLE,e.insertionMode=L.IN_TABLE,Ao(e,t);break}case p.COL:{e.tmplInsertionModeStack[0]=L.IN_COLUMN_GROUP,e.insertionMode=L.IN_COLUMN_GROUP,hf(e,t);break}case p.TR:{e.tmplInsertionModeStack[0]=L.IN_TABLE_BODY,e.insertionMode=L.IN_TABLE_BODY,ju(e,t);break}case p.TD:case p.TH:{e.tmplInsertionModeStack[0]=L.IN_ROW,e.insertionMode=L.IN_ROW,$u(e,t);break}default:e.tmplInsertionModeStack[0]=L.IN_BODY,e.insertionMode=L.IN_BODY,qt(e,t)}}function KO(e,t){t.tagID===p.TEMPLATE&&Li(e,t)}function X1(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):df(e,t)}function QO(e,t){t.tagID===p.HTML?qt(e,t):Vu(e,t)}function J1(e,t){var n;if(t.tagID===p.HTML){if(e.fragmentContext||(e.insertionMode=L.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 Vu(e,t)}function Vu(e,t){e.insertionMode=L.IN_BODY,Uu(e,t)}function XO(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.FRAMESET:{e._insertElement(t,oe.HTML);break}case p.FRAME:{e._appendElement(t,oe.HTML),t.ackSelfClosing=!0;break}case p.NOFRAMES:{qn(e,t);break}}}function JO(e,t){t.tagID===p.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==p.FRAMESET&&(e.insertionMode=L.AFTER_FRAMESET))}function ZO(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.NOFRAMES:{qn(e,t);break}}}function eI(e,t){t.tagID===p.HTML&&(e.insertionMode=L.AFTER_AFTER_FRAMESET)}function tI(e,t){t.tagID===p.HTML?qt(e,t):Yu(e,t)}function Yu(e,t){e.insertionMode=L.IN_BODY,Uu(e,t)}function nI(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.NOFRAMES:{qn(e,t);break}}}function rI(e,t){t.chars=ft,e._insertCharacters(t)}function iI(e,t){e._insertCharacters(t),e.framesetOk=!1}function Z1(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==oe.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function oI(e,t){if(b3(t))Z1(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===oe.MATHML?R1(t):r===oe.SVG&&(x3(t),P1(t)),uf(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function sI(e,t){if(t.tagID===p.P||t.tagID===p.BR){Z1(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)===oe.HTML){e._endTagOutsideForeignContent(t);break}const o=e.treeAdapter.getTagName(r);if(o.toLowerCase()===t.tagName){t.tagName=o,e.openElements.shortenToLength(n);break}}}Y.AREA,Y.BASE,Y.BASEFONT,Y.BGSOUND,Y.BR,Y.COL,Y.EMBED,Y.FRAME,Y.HR,Y.IMG,Y.INPUT,Y.KEYGEN,Y.LINK,Y.META,Y.PARAM,Y.SOURCE,Y.TRACK,Y.WBR;const aI=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,uI=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),eE={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function tE(e,t){const n=yI(e),r=h1("type",{handlers:{root:lI,element:cI,text:dI,comment:rE,doctype:fI,raw:pI},unknown:mI}),o={parser:n?new M1(eE):M1.getFragmentParser(void 0,eE),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),vo(o,ar());const a=n?o.parser.document:o.parser.getFragment(),u=lN(a,{file:o.options.file});return o.stitches&&Lu(u,"comment",function(c,d,h){const m=c;if(m.value.stitch&&h&&d!==void 0){const g=h.children;return g[d]=m.value.stitch,d}}),u.type==="root"&&u.children.length===1&&u.children[0].type===e.type?u.children[0]:u}function nE(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function lI(e,t){nE(e.children,t)}function cI(e,t){gI(e,t),nE(e.children,t),EI(e,t)}function dI(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:$e.CHARACTER,chars:e.value,location:Js(e)};vo(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function fI(e,t){const n={type:$e.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Js(e)};vo(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function hI(e,t){t.stitches=!0;const n=TI(e);if("children"in e&&"children"in n){const r=tE({type:"root",children:e.children},t.options);n.children=r.children}rE({type:"comment",value:{stitch:n}},t)}function rE(e,t){const n=e.value,r={type:$e.COMMENT,data:n,location:Js(e)};vo(t,ar(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function pI(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,iE(t,ar(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(aI,"&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 mI(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))hI(n,t);else{let r="";throw uI.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 vo(e,t){iE(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=xt.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 iE(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 gI(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===xt.PLAINTEXT)return;vo(t,ar(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Ii.html;o===Ii.html&&n==="svg"&&(o=Ii.svg);const a=wN(ne(U({},e),{children:[]}),{space:o===Ii.svg?"svg":"html"}),u={type:$e.START_TAG,tagName:n,tagID:wo(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Js(e)};t.parser.currentToken=u,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function EI(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&RN.includes(n)||t.parser.tokenizer.state===xt.PLAINTEXT)return;vo(t,Su(e));const r={type:$e.END_TAG,tagName:n,tagID:wo(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Js(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===xt.RCDATA||t.parser.tokenizer.state===xt.RAWTEXT||t.parser.tokenizer.state===xt.SCRIPT_DATA)&&(t.parser.tokenizer.state=xt.DATA)}function yI(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Js(e){const t=ar(e)||{line:void 0,column:void 0,offset:void 0},n=Su(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 TI(e){return"children"in e?Oi(ne(U({},e),{children:[]})):Oi(e)}function oE(e){return function(t,n){return tE(t,ne(U({},e),{file:n}))}}const Di=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],sE={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Di,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Di],h2:[["className","sr-only"]],img:[...Di,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Di,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Di],table:[...Di],ul:[...Di,["className","contains-task-list"]],"*":["abbr","accept","acceptCharset","accessKey","action","align","alt","axis","border","cellPadding","cellSpacing","char","charOff","charSet","checked","clear","colSpan","color","cols","compact","coords","dateTime","dir","encType","frame","hSpace","headers","height","hrefLang","htmlFor","id","isMap","itemProp","label","lang","maxLength","media","method","multiple","name","noHref","noShade","noWrap","open","prompt","readOnly","rev","rowSpan","rows","rules","scope","selected","shape","size","span","start","summary","tabIndex","title","useMap","vAlign","value","width"]},clobber:["ariaDescribedBy","ariaLabelledBy","id","name"],clobberPrefix:"user-content-",protocols:{cite:["http","https"],href:["http","https","irc","ircs","mailto","xmpp"],longDesc:["http","https"],src:["http","https"]},required:{input:{disabled:!0,type:"checkbox"}},strip:["script"],tagNames:["a","b","blockquote","br","code","dd","del","details","div","dl","dt","em","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","li","ol","p","picture","pre","q","rp","rt","ruby","s","samp","section","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","tr","tt","ul","var"]},Gr={}.hasOwnProperty;function bI(e,t){let n={type:"root",children:[]};const r={schema:t?U(U({},sE),t):sE,stack:[]},o=aE(r,e);return o&&(Array.isArray(o)?o.length===1?n=o[0]:n.children=o:n=o),n}function aE(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return xI(e,n);case"doctype":return _I(e,n);case"element":return SI(e,n);case"root":return wI(e,n);case"text":return AI(e,n)}}}function xI(e,t){if(e.schema.allowComments){const n=typeof t.value=="string"?t.value:"",r=n.indexOf("-->"),a={type:"comment",value:r<0?n:n.slice(0,r)};return Zs(a,t),a}}function _I(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return Zs(n,t),n}}function SI(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=uE(e,t.children),o=vI(e,t.properties);e.stack.pop();let a=!1;if(n&&n!=="*"&&(!e.schema.tagNames||e.schema.tagNames.includes(n))&&(a=!0,e.schema.ancestors&&Gr.call(e.schema.ancestors,n))){const c=e.schema.ancestors[n];let d=-1;for(a=!1;++d<c.length;)e.stack.includes(c[d])&&(a=!0)}if(!a)return e.schema.strip&&!e.schema.strip.includes(n)?r:void 0;const u={type:"element",tagName:n,properties:o,children:r};return Zs(u,t),u}function wI(e,t){const r={type:"root",children:uE(e,t.children)};return Zs(r,t),r}function AI(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return Zs(r,t),r}function uE(e,t){const n=[];if(Array.isArray(t)){const r=t;let o=-1;for(;++o<r.length;){const a=aE(e,r[o]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function vI(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,o=e.schema.required,a=r&&Gr.call(r,n)?r[n]:void 0,u=r&&Gr.call(r,"*")?r["*"]:void 0,c=t&&typeof t=="object"?t:{},d={};let h;for(h in c)if(Gr.call(c,h)){const m=c[h];let g=lE(e,dE(a,h),h,m);g==null&&(g=lE(e,dE(u,h),h,m)),g!=null&&(d[h]=g)}if(o&&Gr.call(o,n)){const m=o[n];for(h in m)Gr.call(m,h)&&!Gr.call(d,h)&&(d[h]=m[h])}return d}function lE(e,t,n,r){return t?Array.isArray(r)?CI(e,t,n,r):cE(e,t,n,r):void 0}function CI(e,t,n,r){let o=-1;const a=[];for(;++o<r.length;){const u=cE(e,t,n,r[o]);(typeof u=="number"||typeof u=="string")&&a.push(u)}return a}function cE(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&kI(e,n,r)){if(typeof t=="object"&&t.length>1){let o=!1,a=0;for(;++a<t.length;){const u=t[a];if(u&&typeof u=="object"&&"flags"in u){if(u.test(String(r))){o=!0;break}}else if(u===r){o=!0;break}}if(!o)return}return e.schema.clobber&&e.schema.clobberPrefix&&e.schema.clobber.includes(n)?e.schema.clobberPrefix+r:r}}function kI(e,t,n){const r=e.schema.protocols&&Gr.call(e.schema.protocols,t)?e.schema.protocols[t]:void 0;if(!r||r.length===0)return!0;const o=String(n),a=o.indexOf(":"),u=o.indexOf("?"),c=o.indexOf("#"),d=o.indexOf("/");if(a<0||d>-1&&a>d||u>-1&&a>u||c>-1&&a>c)return!0;let h=-1;for(;++h<r.length;){const m=r[h];if(a===m.length&&o.slice(0,m.length)===m)return!0}return!1}function Zs(e,t){const n=W0(t);t.data&&(e.data=Oi(t.data)),n&&(e.position=n)}function dE(e,t){let n,r=-1;if(e)for(;++r<e.length;){const o=e[r],a=typeof o=="string"?o:o[0];if(a===t)return o;a==="data*"&&(n=o)}if(t.length>4&&t.slice(0,4).toLowerCase()==="data")return n}function NI(e){return function(t){return bI(t,e)}}const fE=({globalClassName:e,openLinksInNewTab:t,href:n,title:r,children:o})=>{const a=n?t?"_blank":"_self":void 0;return P.jsx("a",ne(U(U({className:re(e,`${J}-link`)},n?{href:n,target:a}:{}),r?{title:r}:{}),{rel:"noopener noreferrer",children:o}))},OI=()=>{const{disclaimerText:e,disclaimerMarkdown:t,globalClassName:n}=an();return!e&&!t?null:P.jsx("div",{className:re(n,`${J}-disclaimer`),children:t?P.jsx(qg,{rehypePlugins:[oE,NI],components:{ul:({children:r})=>P.jsx("ul",{className:re(n,`${J}-ul`),children:r}),ol:({children:r})=>P.jsx("ol",{className:re(n,`${J}-ol`),children:r}),li:({children:r})=>P.jsx("li",{className:re(n,`${J}-li`),children:r}),a:({href:r,title:o,children:a})=>P.jsx(fE,{globalClassName:n,openLinksInNewTab:!0,href:r,title:o,children:a}),img:({src:r,alt:o})=>P.jsx("img",{className:re(n,`${J}-disclaimer-image`),src:r,alt:o}),p:({children:r})=>P.jsx("p",{className:re(n,`${J}-disclaimer-text`),children:r}),span:({children:r})=>P.jsx("span",{className:re(n,`${J}-disclaimer-text-span`),children:r})},children:t}):P.jsx("p",{className:re(n,`${J}-disclaimer-text`),children:e})})},mf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{isConnected:o}=Ci(),{globalClassName:a,searchConfig:u}=an(),c=ee.useRef(null),d=o?"connected":"disconnected",h=t||!o,m=T=>{var x;T.preventDefault();const b=(((x=c.current)==null?void 0:x.value)||"").trim();b&&(c.current.value="",r(b))},g=()=>{r("Can you connect me to a human?")};return P.jsxs("div",{className:re(a,e,`cim-${n}-component`,`${J}-search-bar-wrapper`),children:[P.jsxs("form",{className:re(a,e,`cim-${n}-component`,`${J}-search-bar`),name:`${J}-search-form`,onSubmit:m,children:[P.jsx("span",{role:"status",className:re(`${J}-connection-status-icon`,d)}),P.jsx("input",{className:re(a,e,`cim-${n}-component`,`${J}-search-input`),type:"text",ref:c,placeholder:(u==null?void 0:u.placeholder)||"Ask us anything",name:`${J}-user-input`,disabled:h}),P.jsx(Jw,{className:e,globalClassName:a,searchConfig:u,componentType:n,isLoading:h}),P.jsx(jr,{className:re(a,`${J}-escalate-btn`),ariaLabel:"Connect to a human agent",title:"Connect to a human agent",disabled:h,onClick:g,icon:P.jsx(qw,{})})]}),P.jsx(OI,{})]})};function II(e){return ln({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 hE=ee.createContext(null),ea=()=>{var n;const e=()=>{},t=ee.useContext(hE);return(n=t==null?void 0:t.closeMenu)!=null?n:e},gf=({onClearChat:e,componentType:t})=>{const n=ea(),r=()=>{e(),n()};return P.jsxs("button",{className:re(`${J}-overflow-menu-button`,"clear-chat-button",`cim-${t}-component`),onClick:r,children:[P.jsx(II,{}),"Clear chat"]})};function RI(e){return e==null?[]:Array.isArray(e)?e:[e]}var PI=(e,...t)=>e.concat(t),LI=(e,...t)=>e.filter(n=>!t.includes(n)),DI=e=>Array.from(new Set(e));function pE(e,t,n={}){const{step:r=1,loop:o=!0}=n,a=t+r,u=e.length,c=u-1;return t===-1?r>0?0:c:a<0?o?c:0:a>=u?o?0:t>u?u:t:a}function MI(e,t,n={}){const{step:r=1,loop:o=!0}=n;return pE(e,t,{step:-r,loop:o})}var FI=e=>Array.isArray(e),mE=e=>e!=null&&typeof e=="object",BI=e=>mE(e)&&!FI(e),Wu=e=>typeof e=="string",Co=e=>typeof e=="function",UI=e=>e==null,HI=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),zI=e=>Object.prototype.toString.call(e),gE=Function.prototype.toString,jI=gE.call(Object),$I=e=>{if(!mE(e)||zI(e)!="[object Object]"||WI(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=HI(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&gE.call(n)==jI},VI=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,YI=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,WI=e=>VI(e)||YI(e),qI=e=>e(),GI=()=>{},Ef=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function KI(e,t=0){let n=0,r=null;return((...o)=>{const a=Date.now(),u=a-n;u>=t?(r&&(clearTimeout(r),r=null),e(...o),n=a):r||(r=setTimeout(()=>{e(...o),n=Date.now(),r=null},t-u))})}var{min:QI,max:XI}=Math,JI=e=>Number.isNaN(e),ZI=e=>JI(e)?0:e,EE=(e,t,n)=>QI(XI(ZI(e),t),n);function yf(e){if(!$I(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 Tf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function eR(e,t){if(e==null)throw new Error(t())}function tR(e,t,n){let r=[];for(const o of t)e[o]==null&&r.push(o);if(r.length>0)throw new Error(`[zag-js${` > ${n}`}] missing required props: ${r.join(", ")}`)}var nR=Object.defineProperty,rR=(e,t,n)=>t in e?nR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bf=(e,t,n)=>rR(e,typeof t!="symbol"?t+"":t,n),yE=()=>{},qu=e=>typeof e=="object"&&e!==null,ko=e=>e?"":void 0,TE=e=>e?"true":void 0,iR=1,oR=9,sR=11,Dt=e=>qu(e)&&e.nodeType===iR&&typeof e.nodeName=="string",Gu=e=>qu(e)&&e.nodeType===oR,aR=e=>qu(e)&&e===e.window,bE=e=>Dt(e)?e.localName||"":"#document";function uR(e){return["html","body","#document"].includes(bE(e))}var lR=e=>qu(e)&&e.nodeType!==void 0,Mi=e=>lR(e)&&e.nodeType===sR&&"host"in e,cR=e=>Dt(e)&&e.localName==="input",dR=e=>Dt(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function ta(e){if(!e)return!1;const t=e.getRootNode();return Io(t)===e}var fR=/(textarea|select)/;function hR(e){if(e==null||!Dt(e))return!1;try{return cR(e)&&e.selectionStart!=null||fR.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function No(e,t){var r;if(!e||!t||!Dt(e)||!Dt(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Mi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function cr(e){var t;return Gu(e)?e:aR(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function pR(e){return cr(e).documentElement}function Oo(e){var t,n,r;return Mi(e)?Oo(e.host):Gu(e)?(t=e.defaultView)!=null?t:window:Dt(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Io(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 mR(e){if(bE(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Mi(e)&&e.host||pR(e);return Mi(t)?t.host:t}function xf(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),Gu(t)||Mi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var _f=new WeakMap;function Ro(e){return _f.has(e)||_f.set(e,Oo(e).getComputedStyle(e)),_f.get(e)}var Sf=new Set(["menu","listbox","dialog","grid","tree","region"]),gR=e=>Sf.has(e),xE=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function _E(e,t){const n=new Set,r=xf(e),o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=xE(c);for(const h of d){if(!h||n.has(h))continue;n.add(h);const m=r.getElementById(h);if(m){const g=m.getAttribute("role"),T=m.getAttribute("aria-modal")==="true";if(g&&gR(g)&&!T&&(m===t||m.contains(t)||o(m)))return!0}}}return!1};return o(e)}function SE(e,t){const n=xf(e),r=new Set,o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=xE(c);for(const h of d){if(!h||r.has(h))continue;r.add(h);const m=n.getElementById(h);if(m){const g=m.getAttribute("role"),T=m.getAttribute("aria-modal")==="true";g&&Sf.has(g)&&!T&&(t(m),o(m))}}}};o(e)}function ER(e){const t=new Set;return SE(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function yR(e){const t=e.getAttribute("role");return!!(t&&Sf.has(t))}function TR(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function bR(e){var t;return TR(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function xR(e){if(!e.id)return!1;const t=xf(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&yR(e))}var wf=()=>typeof document!="undefined";function _R(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Af=e=>wf()&&e.test(_R()),SR=e=>wf()&&e.test(navigator.vendor),wE=()=>wf()&&!!navigator.maxTouchPoints,wR=()=>Af(/^iPhone/i),AR=()=>Af(/^iPad/i)||vf()&&navigator.maxTouchPoints>1,Ku=()=>wR()||AR(),vR=()=>vf()||Ku(),vf=()=>Af(/^Mac/i),CR=()=>vR()&&SR(/apple/i);function kR(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 Gn(e){var n;const t=kR(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var AE=e=>e.button===0,NR=e=>e.button===2||vf()&&e.ctrlKey&&e.button===0,OR=e=>"touches"in e&&e.touches.length>0,IR={Up:"ArrowUp",Down:"ArrowDown",Esc:"Escape"," ":"Space",",":"Comma",Left:"ArrowLeft",Right:"ArrowRight"},vE={ArrowLeft:"ArrowRight",ArrowRight:"ArrowLeft"};function RR(e,t={}){var u;const{dir:n="ltr",orientation:r="horizontal"}=t;let o=e.key;return o=(u=IR[o])!=null?u:o,n==="rtl"&&r==="horizontal"&&o in vE&&(o=vE[o]),o}function CE(e,t="client"){const n=OR(e)?e.touches[0]||e.changedTouches[0]:e;return{x:n[`${t}X`],y:n[`${t}Y`]}}var Mt=(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)}},kE=e=>Dt(e)&&e.tagName==="IFRAME",PR=/^(audio|video|details)$/;function NE(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var LR=e=>!Number.isNaN(NE(e)),DR=e=>NE(e)<0;function MR(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 OE(e,t,n){const r=[...e],o=[...e],a=new Set,u=new Map;e.forEach((d,h)=>u.set(d,h));let c=0;for(;c<o.length;){const d=o[c++];if(!d||a.has(d))continue;a.add(d);const h=MR(d,t);if(h){const m=Array.from(h.querySelectorAll(Qu)).filter(n),g=u.get(d);if(g!==void 0){const T=g+1;r.splice(T,0,...m),m.forEach((b,x)=>{u.set(b,T+x)});for(let b=T+m.length;b<r.length;b++)u.set(r[b],b)}else{const T=r.length;r.push(...m),m.forEach((b,x)=>{u.set(b,T+x)})}o.push(...m)}}return r}var Qu="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",IE=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Qu));(n==!0||n=="if-empty"&&o.length===0)&&Dt(e)&&dr(e)&&o.unshift(e);const u=[];for(const c of o)if(dr(c)){if(kE(c)&&c.contentDocument){const d=c.contentDocument.body;u.push(...IE(d,{getShadowRoot:r}));continue}u.push(c)}return r?OE(u,r,dr):u};function dr(e){return!Dt(e)||e.closest("[inert]")?!1:e.matches(Qu)&&dR(e)}function Po(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Qu));n&&Fi(e)&&o.unshift(e);const a=[];for(const u of o)if(Fi(u)){if(kE(u)&&u.contentDocument){const c=u.contentDocument.body;a.push(...Po(c,{getShadowRoot:r}));continue}a.push(u)}if(r){const u=OE(a,r,Fi);return!u.length&&n?o:u}return!a.length&&n?o:a}function Fi(e){return Dt(e)&&e.tabIndex>0?!0:dr(e)&&!DR(e)}function FR(e,t={}){const n=Po(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function BR(e,t={}){const{current:n,getShadowRoot:r}=t,o=Po(e,{getShadowRoot:r}),a=(e==null?void 0:e.ownerDocument)||document,u=n!=null?n:Io(a);if(!u)return null;const c=o.indexOf(u);return o[c+1]||null}function na(e){return e.tabIndex<0&&(PR.test(e.localName)||hR(e))&&!LR(e)?0:e.tabIndex}function RE(e){const{root:t,getInitialEl:n,filter:r,enabled:o=!0}=e;if(!o)return;let a=null;if(a||(a=typeof n=="function"?n():n),a||(a=t==null?void 0:t.querySelector("[data-autofocus],[autofocus]")),!a){const u=Po(t);a=r?u.filter(r)[0]:u[0]}return a||t||void 0}var UR=class Ox{constructor(){bf(this,"id",null),bf(this,"fn_cleanup"),bf(this,"cleanup",()=>{this.cancel()})}static create(){return new Ox}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 kt(e){const t=UR.create();return t.request(e),t.cleanup}function PE(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 Cf(e){const t=mR(e);return uR(t)?cr(t).body:Dt(t)&&jR(t)?t:Cf(t)}var HR=/auto|scroll|overlay|hidden|clip/,zR=new Set(["inline","contents"]);function jR(e){const t=Oo(e),{overflow:n,overflowX:r,overflowY:o,display:a}=t.getComputedStyle(e);return HR.test(n+o+r)&&!zR.has(a)}var Lo="default",kf="",Xu=new WeakMap;function $R(e={}){const{target:t,doc:n}=e,r=n!=null?n:document,o=r.documentElement;return Ku()?(Lo==="default"&&(kf=o.style.webkitUserSelect,o.style.webkitUserSelect="none"),Lo="disabled"):t&&(Xu.set(t,t.style.userSelect),t.style.userSelect="none"),()=>VR({target:t,doc:r})}function VR(e={}){const{target:t,doc:n}=e,o=(n!=null?n:document).documentElement;if(Ku()){if(Lo!=="disabled")return;Lo="restoring",setTimeout(()=>{PE(()=>{Lo==="restoring"&&(o.style.webkitUserSelect==="none"&&(o.style.webkitUserSelect=kf||""),kf="",Lo="default")})},300)}else if(t&&Xu.has(t)){const a=Xu.get(t);t.style.userSelect==="none"&&(t.style.userSelect=a!=null?a:""),t.getAttribute("style")===""&&t.removeAttribute("style"),Xu.delete(t)}}function YR(e={}){const u=e,{defer:t,target:n}=u,r=rn(u,["defer","target"]),o=t?kt:c=>c(),a=[];return a.push(o(()=>{const c=typeof n=="function"?n():n;a.push($R(ne(U({},r),{target:c})))})),()=>{a.forEach(c=>c==null?void 0:c())}}function WR(e,t){const{onPointerMove:n,onPointerUp:r}=t,o=c=>{const d=CE(c),h=Math.sqrt(Ja(d.x,2)+Ja(d.y,2)),m=c.pointerType==="touch"?10:5;if(!(h<m)){if(c.pointerType==="mouse"&&c.button===0){a(c);return}n({point:d,event:c})}},a=c=>{const d=CE(c);r({point:d,event:c})},u=[Mt(e,"pointermove",o,!1),Mt(e,"pointerup",a,!1),Mt(e,"pointercancel",a,!1),Mt(e,"contextmenu",a,!1),YR({doc:e})];return()=>{u.forEach(c=>c())}}function qR(e,t={}){const{triggerElement:n,onFocus:r,onFocusEnter:o,getShadowRoot:a}=t,u=(e==null?void 0:e.ownerDocument)||document,c=u.body;function d(h){if(h.key!=="Tab")return;let m=null;const[g,T]=FR(e,{includeContainer:!0,getShadowRoot:a}),b=BR(c,{current:n,getShadowRoot:a}),x=!g&&!T;h.shiftKey&&ta(b)?(o==null||o(),m=T):h.shiftKey&&(ta(g)||x)?m=n:!h.shiftKey&&ta(n)?(o==null||o(),m=g):!h.shiftKey&&(ta(T)||x)&&(m=b),m&&(h.preventDefault(),typeof r=="function"?r(m):m.focus())}return Mt(u,"keydown",d,!0)}function GR(e,t){const c=t,{defer:n,triggerElement:r}=c,o=rn(c,["defer","triggerElement"]),a=n?kt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof r=="function"?r():r;u.push(qR(d,U({triggerElement:h},o)))})),()=>{u.forEach(d=>d==null?void 0:d())}}function KR(e,t){var n;return Array.from((n=e==null?void 0:e.querySelectorAll(t))!=null?n:[])}function Ju(e,t){if(!e)return yE;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 QR(e,t,n){if(!e)return yE;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 XR(e,t,n){const{signal:r}=t;return[new Promise((u,c)=>{const d=setTimeout(()=>{c(new Error(`Timeout of ${n}ms exceeded`))},n);r.addEventListener("abort",()=>{clearTimeout(d),c(new Error("Promise aborted"))}),e.then(h=>{r.aborted||(clearTimeout(d),u(h))}).catch(h=>{r.aborted||(clearTimeout(d),c(h))})}),()=>t.abort()]}function JR(e,t){const{timeout:n,rootNode:r}=t,o=Oo(r),a=cr(r),u=new o.AbortController;return XR(new Promise(c=>{const d=e();if(d){c(d);return}const h=new o.MutationObserver(()=>{const m=e();m&&m.isConnected&&(h.disconnect(),c(m))});h.observe(a.body,{childList:!0,subtree:!0})}),u,n)}var ZR=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),eP=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,LE=e=>{const t={};let n;for(;n=eP.exec(e);)t[n[1]]=n[2];return t},tP=(e,t)=>{if(Wu(e)){if(Wu(t))return`${e};${t}`;e=LE(e)}else Wu(t)&&(t=LE(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function Nt(...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]=Ef(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=ZR(t[o],n[o]);continue}if(o==="style"){t[o]=tP(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 lF(e){return e}var Do=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Do||{}),Nf="__init__";function nP(e){const t=()=>{var u,c;return(c=(u=e.getRootNode)==null?void 0:u.call(e))!=null?c:document},n=()=>cr(t()),r=()=>{var u;return(u=n().defaultView)!=null?u:window},o=()=>Io(t()),a=u=>t().getElementById(u);return ne(U({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:ta,getById:a})}function rP(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var Mo=()=>e=>Array.from(new Set(e)),DE=typeof globalThis.document!="undefined"?ee.useLayoutEffect:ee.useEffect;function Zu(e){var g,T;const t=(g=e().value)!=null?g:e().defaultValue,n=(T=e().isEqual)!=null?T:Object.is,[r]=ee.useState(t),[o,a]=ee.useState(r),u=e().value!==void 0,c=ee.useRef(o);c.current=u?e().value:o;const d=ee.useRef(c.current);DE(()=>{d.current=c.current},[o,e().value]);const h=b=>{var A,C;const x=d.current,S=Co(b)?b(x):b;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:S,prev:x}),u||a(S),n(S,x)||(C=(A=e()).onChange)==null||C.call(A,S,x)};function m(){return u?e().value:o}return{initial:r,ref:c,get:m,set(b){(e().sync?ks.flushSync:qI)(()=>h(b))},invoke(b,x){var S,A;(A=(S=e()).onChange)==null||A.call(S,b,x)},hash(b){var x,S,A;return(A=(S=(x=e()).hash)==null?void 0:S.call(x,b))!=null?A:String(b)}}}Zu.cleanup=e=>{ee.useEffect(()=>e,[])},Zu.ref=e=>{const t=ee.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function iP(e){const t=ee.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var oP=(e,t)=>{const n=ee.useRef(!1),r=ee.useRef(!1);ee.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),ee.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function el(e,t={}){var ae,he,ge,ue,Te,Ne;const n=ee.useMemo(()=>{const{id:fe,ids:K,getRootNode:te}=t;return nP({id:fe,ids:K,getRootNode:te})},[t]),r=(...fe)=>{e.debug&&console.log(...fe)},o=(he=(ae=e.props)==null?void 0:ae.call(e,{props:yf(t),scope:n}))!=null?he:t,a=sP(o),u=(ge=e.context)==null?void 0:ge.call(e,{prop:a,bindable:Zu,scope:n,flush:FE,getContext(){return d},getComputed(){return z},getRefs(){return S},getEvent(){return b()}}),c=ME(u),d={get(fe){var K;return(K=c.current)==null?void 0:K[fe].ref.current},set(fe,K){var te;(te=c.current)==null||te[fe].set(K)},initial(fe){var K;return(K=c.current)==null?void 0:K[fe].initial},hash(fe){var te,w;const K=(te=c.current)==null?void 0:te[fe].get();return(w=c.current)==null?void 0:w[fe].hash(K)}},h=ee.useRef(new Map),m=ee.useRef(null),g=ee.useRef(null),T=ee.useRef({type:""}),b=()=>ne(U({},T.current),{current(){return T.current},previous(){return g.current}}),x=()=>ne(U({},D),{matches(...fe){return fe.includes(D.ref.current)},hasTag(fe){var K,te;return!!((te=(K=e.states[D.ref.current])==null?void 0:K.tags)!=null&&te.includes(fe))}}),S=iP((Te=(ue=e.refs)==null?void 0:ue.call(e,{prop:a,context:d}))!=null?Te:{}),A=()=>({state:x(),context:d,event:b(),prop:a,send:j,action:C,guard:O,track:oP,refs:S,computed:z,flush:FE,scope:n,choose:F}),C=fe=>{const K=Co(fe)?fe(A()):fe;if(!K)return;const te=K.map(w=>{var X,k;const M=(k=(X=e.implementations)==null?void 0:X.actions)==null?void 0:k[w];return M||Tf(`[zag-js] No implementation found for action "${JSON.stringify(w)}"`),M});for(const w of te)w==null||w(A())},O=fe=>{var K,te;return Co(fe)?fe(A()):(te=(K=e.implementations)==null?void 0:K.guards)==null?void 0:te[fe](A())},R=fe=>{const K=Co(fe)?fe(A()):fe;if(!K)return;const te=K.map(M=>{var k,xe;const X=(xe=(k=e.implementations)==null?void 0:k.effects)==null?void 0:xe[M];return X||Tf(`[zag-js] No implementation found for effect "${JSON.stringify(M)}"`),X}),w=[];for(const M of te){const X=M==null?void 0:M(A());X&&w.push(X)}return()=>w.forEach(M=>M==null?void 0:M())},F=fe=>RI(fe).find(K=>{let te=!K.guard;return Wu(K.guard)?te=!!O(K.guard):Co(K.guard)&&(te=K.guard(A())),te}),z=fe=>{eR(e.computed,()=>"[zag-js] No computed object found on machine");const K=e.computed[fe];return K({context:d,event:b(),prop:a,refs:S,scope:n,computed:z})},D=Zu(()=>({defaultValue:e.initialState({prop:a}),onChange(fe,K){var w,M,X,k;if(K){const xe=h.current.get(K);xe==null||xe(),h.current.delete(K)}K&&C((w=e.states[K])==null?void 0:w.exit),C((M=m.current)==null?void 0:M.actions);const te=R((X=e.states[fe])==null?void 0:X.effects);if(te&&h.current.set(fe,te),K===Nf){C(e.entry);const xe=R(e.effects);xe&&h.current.set(Nf,xe)}C((k=e.states[fe])==null?void 0:k.entry)}})),q=ee.useRef(void 0),ce=ee.useRef(Do.NotStarted);DE(()=>{queueMicrotask(()=>{var M;const te=ce.current===Do.Started;ce.current=Do.Started,r(te?"rehydrating...":"initializing...");const w=(M=q.current)!=null?M:D.initial;D.invoke(w,te?D.get():Nf)});const fe=h.current,K=D.ref.current;return()=>{r("unmounting..."),q.current=K,ce.current=Do.Stopped,fe.forEach(te=>te==null?void 0:te()),h.current=new Map,m.current=null,queueMicrotask(()=>{C(e.exit)})}},[]);const be=()=>"ref"in D?D.ref.current:D.get(),j=fe=>{queueMicrotask(()=>{var k,xe,Pe,Oe,He;if(ce.current!==Do.Started)return;g.current=T.current,T.current=fe;let K=be();const te=(Pe=(k=e.states[K].on)==null?void 0:k[fe.type])!=null?Pe:(xe=e.on)==null?void 0:xe[fe.type],w=F(te);if(!w)return;m.current=w;const M=(Oe=w.target)!=null?Oe:K;r("transition",fe.type,w.target||K,`(${w.actions})`);const X=M!==K;X?ks.flushSync(()=>D.set(M)):w.reenter&&!X?D.invoke(K,K):C((He=w.actions)!=null?He:[])})};return(Ne=e.watch)==null||Ne.call(e,A()),{state:x(),send:j,context:d,prop:a,scope:n,refs:S,computed:z,event:b(),getStatus:()=>ce.current}}function ME(e){const t=ee.useRef(e);return t.current=e,t}function sP(e){const t=ME(e);return function(r){return t.current[r]}}function FE(e){queueMicrotask(()=>{ks.flushSync(()=>e())})}var Of=rP(e=>e);function tl(...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 aP(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 If=e=>{const t=ee.memo(ee.forwardRef((n,r)=>{const h=n,{asChild:o,children:a}=h,u=rn(h,["asChild","children"]);if(!o)return ee.createElement(e,ne(U({},u),{ref:r}),a);if(!ee.isValidElement(a))return null;const c=ee.Children.only(a),d=aP(c);return ee.cloneElement(c,ne(U({},Nt(u,c.props)),{ref:r?tl(r,d):d}))}));return t.displayName=e.displayName||e.name,t},Gt=(()=>{const e=new Map;return new Proxy(If,{apply(t,n,r){return If(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,If(r)),e.get(r)}})})();function uP(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Bi(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:a,defaultValue:u}=e,c=ee.createContext(u);c.displayName=t;function d(){var m;const h=ee.useContext(c);if(!h&&n){const g=new Error(a!=null?a:uP(r,o));throw g.name="ContextError",(m=Error.captureStackTrace)==null||m.call(Error,g,d),g}return h}return[c.Provider,d,c]}const[lP,Rf]=Bi({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[BE,ra]=Bi({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),UE=ee.forwardRef((e,t)=>{const n=Rf(),r=ra(),o=Nt(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:P.jsx(Gt.div,ne(U({},o),{ref:tl(r.ref,t)}))});UE.displayName="PopoverContent";const HE=ee.forwardRef((e,t)=>{const n=Rf(),r=ra(),o=Nt(n.getPositionerProps(),e);return r.unmounted?null:P.jsx(Gt.div,ne(U({},o),{ref:t}))});HE.displayName="PopoverPositioner";const ia=()=>(e,t)=>t.reduce((n,r)=>{const[o,a]=n,u=r;return a[u]!==void 0&&(o[u]=a[u]),delete a[u],[o,a]},[{},U({},e)]),zE=e=>ia()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function cP(e,t){const{state:n,send:r,context:o}=e,a=n.matches("mounted","unmountSuspended");return{skip:!o.get("initial"),present:a,setNode(u){u&&r({type:"NODE.SET",node:u})},unmount(){r({type:"UNMOUNT"})}}}var dP={props({props:e}){return ne(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",Ro(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 a=t.get("node");if(!o&&(a==null?void 0:a.ownerDocument.visibilityState)==="hidden")return n({type:"UNMOUNT",src:"visibilitychange"});kt(()=>{var c,d;const u=nl(t.get("styles"));e.set("unmountAnimationName",u),u==="none"||u===e.get("prevAnimationName")||((c=t.get("styles"))==null?void 0:c.display)==="none"||((d=t.get("styles"))==null?void 0:d.animationDuration)==="0s"?n({type:"UNMOUNT",src:"presence.changed"}):n({type:"UNMOUNT.SUSPEND"})})},setPrevAnimationName:({context:e,refs:t})=>{kt(()=>{e.set("prevAnimationName",nl(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 a=d=>{var m,g,T;((T=(g=(m=d.composedPath)==null?void 0:m.call(d))==null?void 0:g[0])!=null?T:d.target)===o&&e.set("prevAnimationName",nl(t.get("styles")))},u=d=>{const h=nl(t.get("styles"));Gn(d)===o&&h===e.get("unmountAnimationName")&&!r("present")&&n({type:"UNMOUNT",src:"animationend"})};o.addEventListener("animationstart",a),o.addEventListener("animationcancel",u),o.addEventListener("animationend",u);const c=Ju(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",a),o.removeEventListener("animationcancel",u),o.removeEventListener("animationend",u),PE(()=>c())}}}}};function nl(e){return(e==null?void 0:e.animationName)||"none"}Mo()(["onExitComplete","present","immediate"]);function fP(e,t={}){const{sync:n=!1}=t,r=hP(e);return ee.useCallback((...o)=>{var a;return n?queueMicrotask(()=>{var u;return(u=r.current)==null?void 0:u.call(r,...o)}):(a=r.current)==null?void 0:a.call(r,...o)},[n,r])}function hP(e){const t=ee.useRef(e);return t.current=e,t}const Pf=(e={})=>{const T=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=T,a=rn(T,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),u=ee.useRef(!1),c=ne(U({},a),{present:r,onExitComplete:fP(e.onExitComplete)}),d=el(dP,c),h=cP(d);h.present&&(u.current=!0);const m=!h.present&&!u.current&&t||n&&!h.present&&u.current,g=()=>({"data-state":h.skip&&o?void 0:r?"open":"closed",hidden:!h.present});return{ref:h.setNode,getPresenceProps:g,present:h.present,unmounted:m}};var Ui=(e,t=[])=>({parts:(...n)=>{if(pP(t))return Ui(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>Ui(e,[...t,...n]),omit:(...n)=>Ui(e,t.filter(r=>!n.includes(r))),rename:n=>Ui(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`,`& [data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`].join(", "),attrs:{"data-scope":Fo(e),"data-part":Fo(r)}}}),{})}),Fo=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),pP=e=>e.length===0;const mP=["top","right","bottom","left"],Kr=Math.min,Sn=Math.max,rl=Math.round,il=Math.floor,fr=e=>({x:e,y:e}),gP={left:"right",right:"left",bottom:"top",top:"bottom"},EP={start:"end",end:"start"};function Lf(e,t,n){return Sn(e,Kr(t,n))}function Ar(e,t){return typeof e=="function"?e(t):e}function vr(e){return e.split("-")[0]}function Bo(e){return e.split("-")[1]}function Df(e){return e==="x"?"y":"x"}function Mf(e){return e==="y"?"height":"width"}const yP=new Set(["top","bottom"]);function hr(e){return yP.has(vr(e))?"y":"x"}function Ff(e){return Df(hr(e))}function TP(e,t,n){n===void 0&&(n=!1);const r=Bo(e),o=Ff(e),a=Mf(o);let u=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(u=ol(u)),[u,ol(u)]}function bP(e){const t=ol(e);return[Bf(e),t,Bf(t)]}function Bf(e){return e.replace(/start|end/g,t=>EP[t])}const jE=["left","right"],$E=["right","left"],xP=["top","bottom"],_P=["bottom","top"];function SP(e,t,n){switch(e){case"top":case"bottom":return n?t?$E:jE:t?jE:$E;case"left":case"right":return t?xP:_P;default:return[]}}function wP(e,t,n,r){const o=Bo(e);let a=SP(vr(e),n==="start",r);return o&&(a=a.map(u=>u+"-"+o),t&&(a=a.concat(a.map(Bf)))),a}function ol(e){return e.replace(/left|right|bottom|top/g,t=>gP[t])}function AP(e){return U({top:0,right:0,bottom:0,left:0},e)}function VE(e){return typeof e!="number"?AP(e):{top:e,right:e,bottom:e,left:e}}function sl(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 YE(e,t,n){let{reference:r,floating:o}=e;const a=hr(t),u=Ff(t),c=Mf(u),d=vr(t),h=a==="y",m=r.x+r.width/2-o.width/2,g=r.y+r.height/2-o.height/2,T=r[c]/2-o[c]/2;let b;switch(d){case"top":b={x:m,y:r.y-o.height};break;case"bottom":b={x:m,y:r.y+r.height};break;case"right":b={x:r.x+r.width,y:g};break;case"left":b={x:r.x-o.width,y:g};break;default:b={x:r.x,y:r.y}}switch(Bo(t)){case"start":b[u]-=T*(n&&h?-1:1);break;case"end":b[u]+=T*(n&&h?-1:1);break}return b}const vP=(e,t,n)=>et(null,null,function*(){const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:u}=n,c=a.filter(Boolean),d=yield u.isRTL==null?void 0:u.isRTL(t);let h=yield u.getElementRects({reference:e,floating:t,strategy:o}),{x:m,y:g}=YE(h,r,d),T=r,b={},x=0;for(let S=0;S<c.length;S++){const{name:A,fn:C}=c[S],{x:O,y:R,data:F,reset:z}=yield C({x:m,y:g,initialPlacement:r,placement:T,strategy:o,middlewareData:b,rects:h,platform:u,elements:{reference:e,floating:t}});m=O!=null?O:m,g=R!=null?R:g,b=ne(U({},b),{[A]:U(U({},b[A]),F)}),z&&x<=50&&(x++,typeof z=="object"&&(z.placement&&(T=z.placement),z.rects&&(h=z.rects===!0?yield u.getElementRects({reference:e,floating:t,strategy:o}):z.rects),{x:m,y:g}=YE(h,T,d)),S=-1)}return{x:m,y:g,placement:T,strategy:o,middlewareData:b}});function oa(e,t){return et(this,null,function*(){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:u,elements:c,strategy:d}=e,{boundary:h="clippingAncestors",rootBoundary:m="viewport",elementContext:g="floating",altBoundary:T=!1,padding:b=0}=Ar(t,e),x=VE(b),A=c[T?g==="floating"?"reference":"floating":g],C=sl(yield a.getClippingRect({element:(n=yield a.isElement==null?void 0:a.isElement(A))==null||n?A:A.contextElement||(yield a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:h,rootBoundary:m,strategy:d})),O=g==="floating"?{x:r,y:o,width:u.floating.width,height:u.floating.height}:u.reference,R=yield a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating),F=(yield a.isElement==null?void 0:a.isElement(R))?(yield a.getScale==null?void 0:a.getScale(R))||{x:1,y:1}:{x:1,y:1},z=sl(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:O,offsetParent:R,strategy:d}):O);return{top:(C.top-z.top+x.top)/F.y,bottom:(z.bottom-C.bottom+x.bottom)/F.y,left:(C.left-z.left+x.left)/F.x,right:(z.right-C.right+x.right)/F.x}})}const CP=e=>({name:"arrow",options:e,fn(n){return et(this,null,function*(){const{x:r,y:o,placement:a,rects:u,platform:c,elements:d,middlewareData:h}=n,{element:m,padding:g=0}=Ar(e,n)||{};if(m==null)return{};const T=VE(g),b={x:r,y:o},x=Ff(a),S=Mf(x),A=yield c.getDimensions(m),C=x==="y",O=C?"top":"left",R=C?"bottom":"right",F=C?"clientHeight":"clientWidth",z=u.reference[S]+u.reference[x]-b[x]-u.floating[S],D=b[x]-u.reference[x],q=yield c.getOffsetParent==null?void 0:c.getOffsetParent(m);let ce=q?q[F]:0;(!ce||!(yield c.isElement==null?void 0:c.isElement(q)))&&(ce=d.floating[F]||u.floating[S]);const be=z/2-D/2,j=ce/2-A[S]/2-1,ae=Kr(T[O],j),he=Kr(T[R],j),ge=ae,ue=ce-A[S]-he,Te=ce/2-A[S]/2+be,Ne=Lf(ge,Te,ue),fe=!h.arrow&&Bo(a)!=null&&Te!==Ne&&u.reference[S]/2-(Te<ge?ae:he)-A[S]/2<0,K=fe?Te<ge?Te-ge:Te-ue:0;return{[x]:b[x]+K,data:U({[x]:Ne,centerOffset:Te-Ne-K},fe&&{alignmentOffset:K}),reset:fe}})}}),kP=function(e){return e===void 0&&(e={}),{name:"flip",options:e,fn(n){return et(this,null,function*(){var r,o;const{placement:a,middlewareData:u,rects:c,initialPlacement:d,platform:h,elements:m}=n,Te=Ar(e,n),{mainAxis:g=!0,crossAxis:T=!0,fallbackPlacements:b,fallbackStrategy:x="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:A=!0}=Te,C=rn(Te,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=u.arrow)!=null&&r.alignmentOffset)return{};const O=vr(a),R=hr(d),F=vr(d)===d,z=yield h.isRTL==null?void 0:h.isRTL(m.floating),D=b||(F||!A?[ol(d)]:bP(d)),q=S!=="none";!b&&q&&D.push(...wP(d,A,S,z));const ce=[d,...D],be=yield oa(n,C),j=[];let ae=((o=u.flip)==null?void 0:o.overflows)||[];if(g&&j.push(be[O]),T){const Ne=TP(a,c,z);j.push(be[Ne[0]],be[Ne[1]])}if(ae=[...ae,{placement:a,overflows:j}],!j.every(Ne=>Ne<=0)){var he,ge;const Ne=(((he=u.flip)==null?void 0:he.index)||0)+1,fe=ce[Ne];if(fe&&(!(T==="alignment"?R!==hr(fe):!1)||ae.every(w=>hr(w.placement)===R?w.overflows[0]>0:!0)))return{data:{index:Ne,overflows:ae},reset:{placement:fe}};let K=(ge=ae.filter(te=>te.overflows[0]<=0).sort((te,w)=>te.overflows[1]-w.overflows[1])[0])==null?void 0:ge.placement;if(!K)switch(x){case"bestFit":{var ue;const te=(ue=ae.filter(w=>{if(q){const M=hr(w.placement);return M===R||M==="y"}return!0}).map(w=>[w.placement,w.overflows.filter(M=>M>0).reduce((M,X)=>M+X,0)]).sort((w,M)=>w[1]-M[1])[0])==null?void 0:ue[0];te&&(K=te);break}case"initialPlacement":K=d;break}if(a!==K)return{reset:{placement:K}}}return{}})}}};function WE(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function qE(e){return mP.some(t=>e[t]>=0)}const NP=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return et(this,null,function*(){const{rects:r}=n,u=Ar(e,n),{strategy:o="referenceHidden"}=u,a=rn(u,["strategy"]);switch(o){case"referenceHidden":{const c=yield oa(n,ne(U({},a),{elementContext:"reference"})),d=WE(c,r.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:qE(d)}}}case"escaped":{const c=yield oa(n,ne(U({},a),{altBoundary:!0})),d=WE(c,r.floating);return{data:{escapedOffsets:d,escaped:qE(d)}}}default:return{}}})}}},GE=new Set(["left","top"]);function OP(e,t){return et(this,null,function*(){const{placement:n,platform:r,elements:o}=e,a=yield r.isRTL==null?void 0:r.isRTL(o.floating),u=vr(n),c=Bo(n),d=hr(n)==="y",h=GE.has(u)?-1:1,m=a&&d?-1:1,g=Ar(t,e);let{mainAxis:T,crossAxis:b,alignmentAxis:x}=typeof g=="number"?{mainAxis:g,crossAxis:0,alignmentAxis:null}:{mainAxis:g.mainAxis||0,crossAxis:g.crossAxis||0,alignmentAxis:g.alignmentAxis};return c&&typeof x=="number"&&(b=c==="end"?x*-1:x),d?{x:b*m,y:T*h}:{x:T*h,y:b*m}})}const IP=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(n){return et(this,null,function*(){var r,o;const{x:a,y:u,placement:c,middlewareData:d}=n,h=yield OP(n,e);return c===((r=d.offset)==null?void 0:r.placement)&&(o=d.arrow)!=null&&o.alignmentOffset?{}:{x:a+h.x,y:u+h.y,data:ne(U({},h),{placement:c})}})}}},RP=function(e){return e===void 0&&(e={}),{name:"shift",options:e,fn(n){return et(this,null,function*(){const{x:r,y:o,placement:a}=n,C=Ar(e,n),{mainAxis:u=!0,crossAxis:c=!1,limiter:d={fn:O=>{let{x:R,y:F}=O;return{x:R,y:F}}}}=C,h=rn(C,["mainAxis","crossAxis","limiter"]),m={x:r,y:o},g=yield oa(n,h),T=hr(vr(a)),b=Df(T);let x=m[b],S=m[T];if(u){const O=b==="y"?"top":"left",R=b==="y"?"bottom":"right",F=x+g[O],z=x-g[R];x=Lf(F,x,z)}if(c){const O=T==="y"?"top":"left",R=T==="y"?"bottom":"right",F=S+g[O],z=S-g[R];S=Lf(F,S,z)}const A=d.fn(ne(U({},n),{[b]:x,[T]:S}));return ne(U({},A),{data:{x:A.x-r,y:A.y-o,enabled:{[b]:u,[T]:c}}})})}}},PP=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:u}=t,{offset:c=0,mainAxis:d=!0,crossAxis:h=!0}=Ar(e,t),m={x:n,y:r},g=hr(o),T=Df(g);let b=m[T],x=m[g];const S=Ar(c,t),A=typeof S=="number"?{mainAxis:S,crossAxis:0}:U({mainAxis:0,crossAxis:0},S);if(d){const R=T==="y"?"height":"width",F=a.reference[T]-a.floating[R]+A.mainAxis,z=a.reference[T]+a.reference[R]-A.mainAxis;b<F?b=F:b>z&&(b=z)}if(h){var C,O;const R=T==="y"?"width":"height",F=GE.has(vr(o)),z=a.reference[g]-a.floating[R]+(F&&((C=u.offset)==null?void 0:C[g])||0)+(F?0:A.crossAxis),D=a.reference[g]+a.reference[R]+(F?0:((O=u.offset)==null?void 0:O[g])||0)-(F?A.crossAxis:0);x<z?x=z:x>D&&(x=D)}return{[T]:b,[g]:x}}}},LP=function(e){return e===void 0&&(e={}),{name:"size",options:e,fn(n){return et(this,null,function*(){var r,o;const{placement:a,rects:u,platform:c,elements:d}=n,ae=Ar(e,n),{apply:h=()=>{}}=ae,m=rn(ae,["apply"]),g=yield oa(n,m),T=vr(a),b=Bo(a),x=hr(a)==="y",{width:S,height:A}=u.floating;let C,O;T==="top"||T==="bottom"?(C=T,O=b===((yield c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(O=T,C=b==="end"?"top":"bottom");const R=A-g.top-g.bottom,F=S-g.left-g.right,z=Kr(A-g[C],R),D=Kr(S-g[O],F),q=!n.middlewareData.shift;let ce=z,be=D;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(be=F),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(ce=R),q&&!b){const he=Sn(g.left,0),ge=Sn(g.right,0),ue=Sn(g.top,0),Te=Sn(g.bottom,0);x?be=S-2*(he!==0||ge!==0?he+ge:Sn(g.left,g.right)):ce=A-2*(ue!==0||Te!==0?ue+Te:Sn(g.top,g.bottom))}yield h(ne(U({},n),{availableWidth:be,availableHeight:ce}));const j=yield c.getDimensions(d.floating);return S!==j.width||A!==j.height?{reset:{rects:!0}}:{}})}}};function al(){return typeof window!="undefined"}function Uo(e){return KE(e)?(e.nodeName||"").toLowerCase():"#document"}function wn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function pr(e){var t;return(t=(KE(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function KE(e){return al()?e instanceof Node||e instanceof wn(e).Node:!1}function Kn(e){return al()?e instanceof Element||e instanceof wn(e).Element:!1}function mr(e){return al()?e instanceof HTMLElement||e instanceof wn(e).HTMLElement:!1}function QE(e){return!al()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof wn(e).ShadowRoot}const DP=new Set(["inline","contents"]);function sa(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!DP.has(o)}const MP=new Set(["table","td","th"]);function FP(e){return MP.has(Uo(e))}const BP=[":popover-open",":modal"];function ul(e){return BP.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const UP=["transform","translate","scale","rotate","perspective"],HP=["transform","translate","scale","rotate","perspective","filter"],zP=["paint","layout","strict","content"];function Uf(e){const t=Hf(),n=Kn(e)?Qn(e):e;return UP.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)||HP.some(r=>(n.willChange||"").includes(r))||zP.some(r=>(n.contain||"").includes(r))}function jP(e){let t=Qr(e);for(;mr(t)&&!Ho(t);){if(Uf(t))return t;if(ul(t))return null;t=Qr(t)}return null}function Hf(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const $P=new Set(["html","body","#document"]);function Ho(e){return $P.has(Uo(e))}function Qn(e){return wn(e).getComputedStyle(e)}function ll(e){return Kn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Qr(e){if(Uo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||QE(e)&&e.host||pr(e);return QE(t)?t.host:t}function XE(e){const t=Qr(e);return Ho(t)?e.ownerDocument?e.ownerDocument.body:e.body:mr(t)&&sa(t)?t:XE(t)}function aa(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=XE(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),u=wn(o);if(a){const c=zf(u);return t.concat(u,u.visualViewport||[],sa(o)?o:[],c&&n?aa(c):[])}return t.concat(o,aa(o,[],n))}function zf(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function JE(e){const t=Qn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=mr(e),a=o?e.offsetWidth:n,u=o?e.offsetHeight:r,c=rl(n)!==a||rl(r)!==u;return c&&(n=a,r=u),{width:n,height:r,$:c}}function jf(e){return Kn(e)?e:e.contextElement}function zo(e){const t=jf(e);if(!mr(t))return fr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=JE(t);let u=(a?rl(n.width):n.width)/r,c=(a?rl(n.height):n.height)/o;return(!u||!Number.isFinite(u))&&(u=1),(!c||!Number.isFinite(c))&&(c=1),{x:u,y:c}}const VP=fr(0);function ZE(e){const t=wn(e);return!Hf()||!t.visualViewport?VP:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function YP(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==wn(e)?!1:t}function Hi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=jf(e);let u=fr(1);t&&(r?Kn(r)&&(u=zo(r)):u=zo(e));const c=YP(a,n,r)?ZE(a):fr(0);let d=(o.left+c.x)/u.x,h=(o.top+c.y)/u.y,m=o.width/u.x,g=o.height/u.y;if(a){const T=wn(a),b=r&&Kn(r)?wn(r):r;let x=T,S=zf(x);for(;S&&r&&b!==x;){const A=zo(S),C=S.getBoundingClientRect(),O=Qn(S),R=C.left+(S.clientLeft+parseFloat(O.paddingLeft))*A.x,F=C.top+(S.clientTop+parseFloat(O.paddingTop))*A.y;d*=A.x,h*=A.y,m*=A.x,g*=A.y,d+=R,h+=F,x=wn(S),S=zf(x)}}return sl({width:m,height:g,x:d,y:h})}function cl(e,t){const n=ll(e).scrollLeft;return t?t.left+n:Hi(pr(e)).left+n}function ey(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-cl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function WP(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",u=pr(r),c=t?ul(t.floating):!1;if(r===u||c&&a)return n;let d={scrollLeft:0,scrollTop:0},h=fr(1);const m=fr(0),g=mr(r);if((g||!g&&!a)&&((Uo(r)!=="body"||sa(u))&&(d=ll(r)),mr(r))){const b=Hi(r);h=zo(r),m.x=b.x+r.clientLeft,m.y=b.y+r.clientTop}const T=u&&!g&&!a?ey(u,d):fr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+m.x+T.x,y:n.y*h.y-d.scrollTop*h.y+m.y+T.y}}function qP(e){return Array.from(e.getClientRects())}function GP(e){const t=pr(e),n=ll(e),r=e.ownerDocument.body,o=Sn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Sn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let u=-n.scrollLeft+cl(e);const c=-n.scrollTop;return Qn(r).direction==="rtl"&&(u+=Sn(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:u,y:c}}const ty=25;function KP(e,t){const n=wn(e),r=pr(e),o=n.visualViewport;let a=r.clientWidth,u=r.clientHeight,c=0,d=0;if(o){a=o.width,u=o.height;const m=Hf();(!m||m&&t==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const h=cl(r);if(h<=0){const m=r.ownerDocument,g=m.body,T=getComputedStyle(g),b=m.compatMode==="CSS1Compat"&&parseFloat(T.marginLeft)+parseFloat(T.marginRight)||0,x=Math.abs(r.clientWidth-g.clientWidth-b);x<=ty&&(a-=x)}else h<=ty&&(a+=h);return{width:a,height:u,x:c,y:d}}const QP=new Set(["absolute","fixed"]);function XP(e,t){const n=Hi(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=mr(e)?zo(e):fr(1),u=e.clientWidth*a.x,c=e.clientHeight*a.y,d=o*a.x,h=r*a.y;return{width:u,height:c,x:d,y:h}}function ny(e,t,n){let r;if(t==="viewport")r=KP(e,n);else if(t==="document")r=GP(pr(e));else if(Kn(t))r=XP(t,n);else{const o=ZE(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return sl(r)}function ry(e,t){const n=Qr(e);return n===t||!Kn(n)||Ho(n)?!1:Qn(n).position==="fixed"||ry(n,t)}function JP(e,t){const n=t.get(e);if(n)return n;let r=aa(e,[],!1).filter(c=>Kn(c)&&Uo(c)!=="body"),o=null;const a=Qn(e).position==="fixed";let u=a?Qr(e):e;for(;Kn(u)&&!Ho(u);){const c=Qn(u),d=Uf(u);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&QP.has(o.position)||sa(u)&&!d&&ry(e,u))?r=r.filter(m=>m!==u):o=c,u=Qr(u)}return t.set(e,r),r}function ZP(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const u=[...n==="clippingAncestors"?ul(t)?[]:JP(t,this._c):[].concat(n),r],c=u[0],d=u.reduce((h,m)=>{const g=ny(t,m,o);return h.top=Sn(g.top,h.top),h.right=Kr(g.right,h.right),h.bottom=Kr(g.bottom,h.bottom),h.left=Sn(g.left,h.left),h},ny(t,c,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function eL(e){const{width:t,height:n}=JE(e);return{width:t,height:n}}function tL(e,t,n){const r=mr(t),o=pr(t),a=n==="fixed",u=Hi(e,!0,a,t);let c={scrollLeft:0,scrollTop:0};const d=fr(0);function h(){d.x=cl(o)}if(r||!r&&!a)if((Uo(t)!=="body"||sa(o))&&(c=ll(t)),r){const b=Hi(t,!0,a,t);d.x=b.x+t.clientLeft,d.y=b.y+t.clientTop}else o&&h();a&&!r&&o&&h();const m=o&&!r&&!a?ey(o,c):fr(0),g=u.left+c.scrollLeft-d.x-m.x,T=u.top+c.scrollTop-d.y-m.y;return{x:g,y:T,width:u.width,height:u.height}}function $f(e){return Qn(e).position==="static"}function iy(e,t){if(!mr(e)||Qn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return pr(e)===n&&(n=n.ownerDocument.body),n}function oy(e,t){const n=wn(e);if(ul(e))return n;if(!mr(e)){let o=Qr(e);for(;o&&!Ho(o);){if(Kn(o)&&!$f(o))return o;o=Qr(o)}return n}let r=iy(e,t);for(;r&&FP(r)&&$f(r);)r=iy(r,t);return r&&Ho(r)&&$f(r)&&!Uf(r)?n:r||jP(e)||n}const nL=function(e){return et(this,null,function*(){const t=this.getOffsetParent||oy,n=this.getDimensions,r=yield n(e.floating);return{reference:tL(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function rL(e){return Qn(e).direction==="rtl"}const iL={convertOffsetParentRelativeRectToViewportRelativeRect:WP,getDocumentElement:pr,getClippingRect:ZP,getOffsetParent:oy,getElementRects:nL,getClientRects:qP,getDimensions:eL,getScale:zo,isElement:Kn,isRTL:rL};function sy(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function oL(e,t){let n=null,r;const o=pr(e);function a(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function u(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),a();const h=e.getBoundingClientRect(),{left:m,top:g,width:T,height:b}=h;if(c||t(),!T||!b)return;const x=il(g),S=il(o.clientWidth-(m+T)),A=il(o.clientHeight-(g+b)),C=il(m),R={rootMargin:-x+"px "+-S+"px "+-A+"px "+-C+"px",threshold:Sn(0,Kr(1,d))||1};let F=!0;function z(D){const q=D[0].intersectionRatio;if(q!==d){if(!F)return u();q?u(!1,q):r=setTimeout(()=>{u(!1,1e-7)},1e3)}q===1&&!sy(h,e.getBoundingClientRect())&&u(),F=!1}try{n=new IntersectionObserver(z,ne(U({},R),{root:o.ownerDocument}))}catch(D){n=new IntersectionObserver(z,R)}n.observe(e)}return u(!0),a}function sL(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:u=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:d=!1}=r,h=jf(e),m=o||a?[...h?aa(h):[],...aa(t)]:[];m.forEach(C=>{o&&C.addEventListener("scroll",n,{passive:!0}),a&&C.addEventListener("resize",n)});const g=h&&c?oL(h,n):null;let T=-1,b=null;u&&(b=new ResizeObserver(C=>{let[O]=C;O&&O.target===h&&b&&(b.unobserve(t),cancelAnimationFrame(T),T=requestAnimationFrame(()=>{var R;(R=b)==null||R.observe(t)})),n()}),h&&!d&&b.observe(h),b.observe(t));let x,S=d?Hi(e):null;d&&A();function A(){const C=Hi(e);S&&!sy(S,C)&&n(),S=C,x=requestAnimationFrame(A)}return n(),()=>{var C;m.forEach(O=>{o&&O.removeEventListener("scroll",n),a&&O.removeEventListener("resize",n)}),g==null||g(),(C=b)==null||C.disconnect(),b=null,d&&cancelAnimationFrame(x)}}const aL=IP,uL=RP,lL=kP,cL=LP,dL=NP,fL=CP,hL=PP,pL=(e,t,n)=>{const r=new Map,o=U({platform:iL},n),a=ne(U({},o.platform),{_c:r});return vP(e,t,ne(U({},o),{platform:a}))};function ay(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 ne(U({},o),{toJSON:()=>o})}function mL(e){if(!e)return ay();const{x:t,y:n,width:r,height:o}=e;return ay(t,n,r,o)}function gL(e,t){return{contextElement:Dt(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?mL(r):n.getBoundingClientRect()}}}var ua=e=>({variable:e,reference:`var(${e})`}),Cr={arrowSize:ua("--arrow-size"),arrowSizeHalf:ua("--arrow-size-half"),arrowBg:ua("--arrow-background"),transformOrigin:ua("--transform-origin"),arrowOffset:ua("--arrow-offset")},EL=e=>e==="top"||e==="bottom"?"y":"x";function yL(e,t){return{name:"transformOrigin",fn(n){var be,j,ae,he,ge;const{elements:r,middlewareData:o,placement:a,rects:u,y:c}=n,d=a.split("-")[0],h=EL(d),m=((be=o.arrow)==null?void 0:be.x)||0,g=((j=o.arrow)==null?void 0:j.y)||0,T=(t==null?void 0:t.clientWidth)||0,b=(t==null?void 0:t.clientHeight)||0,x=m+T/2,S=g+b/2,A=Math.abs(((ae=o.shift)==null?void 0:ae.y)||0),C=u.reference.height/2,O=b/2,R=(ge=(he=e.offset)==null?void 0:he.mainAxis)!=null?ge:e.gutter,F=typeof R=="number"?R+O:R!=null?R:O,z=A>F,D={top:`${x}px calc(100% + ${F}px)`,bottom:`${x}px ${-F}px`,left:`calc(100% + ${F}px) ${S}px`,right:`${-F}px ${S}px`}[d],q=`${x}px ${u.reference.y+C-c}px`,ce=!!e.overlap&&h==="y"&&z;return r.floating.style.setProperty(Cr.transformOrigin.variable,ce?q:D),{data:{transformOrigin:ce?q:D}}}}}var TL={name:"rects",fn({rects:e}){return{data:e}}},bL=e=>{if(e)return{name:"shiftArrow",fn({placement:t,middlewareData:n}){if(!n.arrow)return{};const{x:r,y:o}=n.arrow,a=t.split("-")[0];return Object.assign(e.style,{left:r!=null?`${r}px`:"",top:o!=null?`${o}px`:"",[a]:`calc(100% + ${Cr.arrowOffset.reference})`}),{}}}};function xL(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var _L={strategy:"absolute",placement:"bottom",listeners:!0,gutter:8,flip:!0,slide:!0,overlap:!1,sameWidth:!1,fitViewport:!1,overflowPadding:8,arrowPadding:4};function uy(e,t){const n=e.devicePixelRatio||1;return Math.round(t*n)/n}function Vf(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function SL(e,t,n){const r=e||t.createElement("div");return fL({element:r,padding:n.arrowPadding})}function wL(e,t){var n;if(!UI((n=t.offset)!=null?n:t.gutter))return aL(({placement:r})=>{var m,g,T,b;const o=((e==null?void 0:e.clientHeight)||0)/2,a=(g=(m=t.offset)==null?void 0:m.mainAxis)!=null?g:t.gutter,u=typeof a=="number"?a+o:a!=null?a:o,{hasAlign:c}=xL(r),d=c?void 0:t.shift,h=(b=(T=t.offset)==null?void 0:T.crossAxis)!=null?b:d;return yf({crossAxis:h,mainAxis:u,alignmentAxis:t.shift})})}function AL(e){if(!e.flip)return;const t=Vf(e.boundary);return lL(ne(U({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function vL(e){if(!e.slide&&!e.overlap)return;const t=Vf(e.boundary);return uL(ne(U({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:hL()}))}function CL(e){return cL({padding:e.overflowPadding,apply({elements:t,rects:n,availableHeight:r,availableWidth:o}){const a=t.floating,u=Math.round(n.reference.width),c=Math.round(n.reference.height);o=Math.floor(o),r=Math.floor(r),a.style.setProperty("--reference-width",`${u}px`),a.style.setProperty("--reference-height",`${c}px`),a.style.setProperty("--available-width",`${o}px`),a.style.setProperty("--available-height",`${r}px`)}})}function kL(e){var t;if(e.hideWhenDetached)return dL({strategy:"referenceHidden",boundary:(t=Vf(e.boundary))!=null?t:"clippingAncestors"})}function NL(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function OL(e,t,n={}){const r=gL(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},_L,n),a=t.querySelector("[data-part=arrow]"),u=[wL(a,o),AL(o),vL(o),SL(a,t.ownerDocument,o),bL(a),yL({gutter:o.gutter,offset:o.offset,overlap:o.overlap},a),CL(o),kL(o),TL],{placement:c,strategy:d,onComplete:h,onPositioned:m}=o,g=()=>et(null,null,function*(){var F;if(!r||!t)return;const S=yield pL(r,t,{placement:c,middleware:u,strategy:d});h==null||h(S),m==null||m({placed:!0});const A=Oo(t),C=uy(A,S.x),O=uy(A,S.y);t.style.setProperty("--x",`${C}px`),t.style.setProperty("--y",`${O}px`),o.hideWhenDetached&&(((F=S.middlewareData.hide)==null?void 0:F.referenceHidden)?(t.style.setProperty("visibility","hidden"),t.style.setProperty("pointer-events","none")):(t.style.removeProperty("visibility"),t.style.removeProperty("pointer-events")));const R=t.firstElementChild;if(R){const z=Ro(R);t.style.setProperty("--z-index",z.zIndex)}}),T=()=>et(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:g,floatingElement:t}),m==null||m({placed:!0})):yield g()}),b=NL(o.listeners),x=o.listeners?sL(r,t,T,b):GI;return T(),()=>{x==null||x(),m==null||m({placed:!1})}}function ly(e,t,n={}){const c=n,{defer:r}=c,o=rn(c,["defer"]),a=r?kt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof t=="function"?t():t;u.push(OL(d,h,o))})),()=>{u.forEach(d=>d==null?void 0:d())}}var IL={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function RL(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:Cr.arrowSize.reference,height:Cr.arrowSize.reference,[Cr.arrowSizeHalf.variable]:`calc(${Cr.arrowSize.reference} / 2)`,[Cr.arrowOffset.variable]:`calc(${Cr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?IL[t.split("-")[0]]:void 0,background:Cr.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 jo=new WeakMap,dl=new WeakMap,fl={},Yf=0,cy=e=>e&&(e.host||cy(e.parentNode)),PL=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=cy(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),LL=new Set(["script","output","status","next-route-announcer"]),DL=e=>LL.has(e.localName)||e.role==="status"||e.hasAttribute("aria-live")?!0:e.matches("[data-live-announcer]"),ML=(e,t)=>{const{parentNode:n,markerName:r,controlAttribute:o,followControlledElements:a=!0}=t,u=PL(n,Array.isArray(e)?e:[e]);fl[r]||(fl[r]=new WeakMap);const c=fl[r],d=[],h=new Set,m=new Set(u),g=b=>{!b||h.has(b)||(h.add(b),g(b.parentNode))};u.forEach(b=>{g(b),a&&Dt(b)&&SE(b,x=>{g(x)})});const T=b=>{!b||m.has(b)||Array.prototype.forEach.call(b.children,x=>{if(h.has(x))T(x);else try{if(DL(x))return;const A=x.getAttribute(o)==="true",C=(jo.get(x)||0)+1,O=(c.get(x)||0)+1;jo.set(x,C),c.set(x,O),d.push(x),C===1&&A&&dl.set(x,!0),O===1&&x.setAttribute(r,""),A||x.setAttribute(o,"true")}catch(S){console.error("[zag-js > ariaHidden] cannot operate on ",x,S)}})};return T(n),h.clear(),Yf++,()=>{d.forEach(b=>{const x=jo.get(b)-1,S=c.get(b)-1;jo.set(b,x),c.set(b,S),x||(dl.has(b)||b.removeAttribute(o),dl.delete(b)),S||b.removeAttribute(r)}),Yf--,Yf||(jo=new WeakMap,jo=new WeakMap,dl=new WeakMap,fl={})}},FL=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,BL=(e,t=FL(e),n="data-aria-hidden",r=!0)=>{if(t)return ML(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},UL=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function dy(e,t={}){const{defer:n=!0}=t,r=n?UL:a=>a(),o=[];return o.push(r(()=>{const u=(typeof e=="function"?e():e).filter(Boolean);u.length!==0&&o.push(BL(u))})),()=>{o.forEach(a=>a==null?void 0:a())}}function HL(e){const t={each(n){var r;for(let o=0;o<((r=e.frames)==null?void 0:r.length);o+=1){const a=e.frames[o];a&&n(a)}},addEventListener(n,r,o){return t.each(a=>{try{a.document.addEventListener(n,r,o)}catch(u){}}),()=>{try{t.removeEventListener(n,r,o)}catch(a){}}},removeEventListener(n,r,o){t.each(a=>{try{a.document.removeEventListener(n,r,o)}catch(u){}})}};return t}function zL(e){const t=e.frameElement!=null?e.parent:null;return{addEventListener:(n,r,o)=>{try{t==null||t.addEventListener(n,r,o)}catch(a){}return()=>{try{t==null||t.removeEventListener(n,r,o)}catch(a){}}},removeEventListener:(n,r,o)=>{try{t==null||t.removeEventListener(n,r,o)}catch(a){}}}}var fy="pointerdown.outside",hy="focus.outside";function jL(e){for(const t of e)if(Dt(t)&&dr(t))return!0;return!1}var py=e=>"clientY"in e;function $L(e,t){if(!py(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 VL(e,t){return e.y<=t.y&&t.y<=e.y+e.height&&e.x<=t.x&&t.x<=e.x+e.width}function my(e,t){if(!t||!py(e))return!1;const n=t.scrollHeight>t.clientHeight,r=n&&e.clientX>t.offsetLeft+t.clientWidth,o=t.scrollWidth>t.clientWidth,a=o&&e.clientY>t.offsetTop+t.clientHeight,u={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 VL(u,c)?r||a:!1}function YL(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:a,defer:u,followControlledElements:c=!0}=t;if(!e)return;const d=cr(e),h=Oo(e),m=HL(h),g=zL(h);function T(R,F){if(!Dt(F)||!F.isConnected||No(e,F)||$L(e,R)||c&&_E(e,F))return!1;const z=d.querySelector(`[aria-controls="${e.id}"]`);if(z){const q=Cf(z);if(my(R,q))return!1}const D=Cf(e);return my(R,D)?!1:!(n!=null&&n(F))}const b=new Set,x=Mi(e==null?void 0:e.getRootNode());function S(R){function F(z){var be,j;const D=u&&!wE()?kt:ae=>ae(),q=z!=null?z:R,ce=(j=(be=q==null?void 0:q.composedPath)==null?void 0:be.call(q))!=null?j:[q==null?void 0:q.target];D(()=>{const ae=x?ce[0]:Gn(R);if(!(!e||!T(R,ae))){if(o||a){const he=Ef(o,a);e.addEventListener(fy,he,{once:!0})}gy(e,fy,{bubbles:!1,cancelable:!0,detail:{originalEvent:q,contextmenu:NR(q),focusable:jL(ce),target:ae}})}})}R.pointerType==="touch"?(b.forEach(z=>z()),b.add(Mt(d,"click",F,{once:!0})),b.add(g.addEventListener("click",F,{once:!0})),b.add(m.addEventListener("click",F,{once:!0}))):F()}const A=new Set,C=setTimeout(()=>{A.add(Mt(d,"pointerdown",S,!0)),A.add(g.addEventListener("pointerdown",S,!0)),A.add(m.addEventListener("pointerdown",S,!0))},0);function O(R){(u?kt:z=>z())(()=>{var q,ce;const z=(ce=(q=R==null?void 0:R.composedPath)==null?void 0:q.call(R))!=null?ce:[R==null?void 0:R.target],D=x?z[0]:Gn(R);if(!(!e||!T(R,D))){if(r||a){const be=Ef(r,a);e.addEventListener(hy,be,{once:!0})}gy(e,hy,{bubbles:!1,cancelable:!0,detail:{originalEvent:R,contextmenu:!1,focusable:dr(D),target:D}})}})}return wE()||(A.add(Mt(d,"focusin",O,!0)),A.add(g.addEventListener("focusin",O,!0)),A.add(m.addEventListener("focusin",O,!0))),()=>{clearTimeout(C),b.forEach(R=>R()),A.forEach(R=>R())}}function WL(e,t){const{defer:n}=t,r=n?kt:a=>a(),o=[];return o.push(r(()=>{const a=typeof e=="function"?e():e;o.push(YL(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}function gy(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function qL(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return Mt(cr(e),"keydown",n,{capture:!0})}var Ey="layer:request-dismiss",Dn={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=>No(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>No(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=>Dn.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];KL(e,Ey,o=>{var a;(a=r.requestDismiss)==null||a.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),GL(e,Ey,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function GL(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 KL(e,t,n){e.addEventListener(t,n,{once:!0})}var yy;function Ty(){Dn.layers.forEach(({node:e})=>{e.style.pointerEvents=Dn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function QL(e){e.style.pointerEvents=""}function XL(e,t){const n=cr(e),r=[];return Dn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(yy=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[a,u]=JR(()=>{const c=o();return Dt(c)?c:null},{timeout:1e3});a.then(c=>r.push(Ju(c,{pointerEvents:"auto"}))),r.push(u)}),()=>{Dn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=yy,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function JL(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Tf("[@zag-js/dismissable] node is `null` or `undefined`");return}if(!e)return;const{onDismiss:r,onRequestDismiss:o,pointerBlocking:a,exclude:u,debug:c,type:d="dialog"}=t,h={dismiss:r,node:e,type:d,pointerBlocking:a,requestDismiss:o};Dn.add(h),Ty();function m(S){var C,O;const A=Gn(S.detail.originalEvent);Dn.isBelowPointerBlockingLayer(e)||Dn.isInBranch(A)||((C=t.onPointerDownOutside)==null||C.call(t,S),(O=t.onInteractOutside)==null||O.call(t,S),!S.defaultPrevented&&(c&&console.log("onPointerDownOutside:",S.detail.originalEvent),r==null||r()))}function g(S){var C,O;const A=Gn(S.detail.originalEvent);Dn.isInBranch(A)||((C=t.onFocusOutside)==null||C.call(t,S),(O=t.onInteractOutside)==null||O.call(t,S),!S.defaultPrevented&&(c&&console.log("onFocusOutside:",S.detail.originalEvent),r==null||r()))}function T(S){var A;Dn.isTopMost(e)&&((A=t.onEscapeKeyDown)==null||A.call(t,S),!S.defaultPrevented&&r&&(S.preventDefault(),r()))}function b(S){var R;if(!e)return!1;const A=typeof u=="function"?u():u,C=Array.isArray(A)?A:[A],O=(R=t.persistentElements)==null?void 0:R.map(F=>F()).filter(Dt);return O&&C.push(...O),C.some(F=>No(F,S))||Dn.isInNestedLayer(e,S)}const x=[a?XL(e,t.persistentElements):void 0,qL(e,T),WL(e,{exclude:b,onFocusOutside:g,onPointerDownOutside:m,defer:t.defer})];return()=>{Dn.remove(e),Ty(),QL(e),x.forEach(S=>S==null?void 0:S())}}function by(e,t){const{defer:n}=t,r=n?kt:a=>a(),o=[];return o.push(r(()=>{const a=Co(e)?e():e;o.push(JL(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}var ZL=Object.defineProperty,e6=(e,t,n)=>t in e?ZL(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ht=(e,t,n)=>e6(e,typeof t!="symbol"?t+"":t,n),xy={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()}},t6=[],n6=class{constructor(e,t){ht(this,"trapStack"),ht(this,"config"),ht(this,"doc"),ht(this,"state",{containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0}),ht(this,"portalContainers",new Set),ht(this,"listenerCleanups",[]),ht(this,"handleFocus",r=>{const o=Gn(r),a=this.findContainerIndex(o,r)>=0;if(a||Gu(o))a&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let u,c=!0;if(this.state.mostRecentlyFocusedNode)if(na(this.state.mostRecentlyFocusedNode)>0){const d=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:h}=this.state.containerGroups[d];if(h.length>0){const m=h.findIndex(g=>g===this.state.mostRecentlyFocusedNode);m>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?m+1<h.length&&(u=h[m+1],c=!1):m-1>=0&&(u=h[m-1],c=!1))}}else this.state.containerGroups.some(d=>d.tabbableNodes.some(h=>na(h)>0))||(c=!1);else c=!1;c&&(u=this.findNextNavNode({target:this.state.mostRecentlyFocusedNode,isBackward:this.config.isKeyBackward(this.state.recentNavEvent)})),u?this.tryFocus(u):this.tryFocus(this.state.mostRecentlyFocusedNode||this.getInitialFocusNode())}this.state.recentNavEvent=void 0}),ht(this,"handlePointerDown",r=>{const o=Gn(r);if(!(this.findContainerIndex(o,r)>=0)){if(ca(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}ca(this.config.allowOutsideClick,r)||r.preventDefault()}}),ht(this,"handleClick",r=>{const o=Gn(r);this.findContainerIndex(o,r)>=0||ca(this.config.clickOutsideDeactivates,r)||ca(this.config.allowOutsideClick,r)||(r.preventDefault(),r.stopImmediatePropagation())}),ht(this,"handleTabKey",r=>{if(this.config.isKeyForward(r)||this.config.isKeyBackward(r)){this.state.recentNavEvent=r;const o=this.config.isKeyBackward(r),a=this.findNextNavNode({event:r,isBackward:o});if(!a)return;la(r)&&r.preventDefault(),this.tryFocus(a)}}),ht(this,"handleEscapeKey",r=>{r6(r)&&ca(this.config.escapeDeactivates,r)!==!1&&(r.preventDefault(),this.deactivate())}),ht(this,"_mutationObserver"),ht(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(d=>{if(d.nodeType!==Node.ELEMENT_NODE)return!1;const h=d;return bR(h)?!0:h.id&&!this.state.containers.some(m=>m.contains(h))?xR(h):!1}):!1)&&this.state.active&&!this.state.paused&&(this.updateTabbableNodes(),this.updatePortalContainers())})}),ht(this,"updateObservedNodes",()=>{var r;(r=this._mutationObserver)==null||r.disconnect(),this.state.active&&!this.state.paused&&(this.state.containers.map(o=>{var a;(a=this._mutationObserver)==null||a.observe(o,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}),this.portalContainers.forEach(o=>{this.observePortalContainer(o)}))}),ht(this,"getInitialFocusNode",()=>{let r=this.getNodeForOption("initialFocus",{hasFallback:!0});if(r===!1)return!1;if(r===void 0||r&&!dr(r)){const o=Io(this.doc);if(o&&this.findContainerIndex(o)>=0)r=o;else{const a=this.state.tabbableGroups[0];r=a&&a.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}),ht(this,"tryFocus",r=>{if(r!==!1&&r!==Io(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,i6(r)&&r.select()}}),ht(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(),xy.deactivateTrap(this.trapStack,this),this.portalContainers.clear();const a=this.getOption(o,"onDeactivate"),u=this.getOption(o,"onPostDeactivate"),c=this.getOption(o,"checkCanReturnFocus"),d=this.getOption(o,"returnFocus","returnFocusOnDeactivate");a==null||a();const h=()=>{_y(()=>{if(d){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(m)}u==null||u()})};if(d&&c){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);return c(m).then(h,h),this}return h(),this}),ht(this,"pause",r=>{if(this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onPause"),a=this.getOption(r,"onPostPause");return this.state.paused=!0,o==null||o(),this.removeListeners(),this.updateObservedNodes(),a==null||a(),this}),ht(this,"unpause",r=>{if(!this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onUnpause"),a=this.getOption(r,"onPostUnpause");return this.state.paused=!1,o==null||o(),this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),a==null||a(),this}),ht(this,"updateContainerElements",r=>(this.state.containers=Array.isArray(r)?r.filter(Boolean):[r].filter(Boolean),this.state.active&&this.updateTabbableNodes(),this.updateObservedNodes(),this)),ht(this,"getReturnFocusNode",r=>{const o=this.getNodeForOption("setReturnFocus",{params:[r]});return o||(o===!1?!1:r)}),ht(this,"getOption",(r,o,a)=>r&&r[o]!==void 0?r[o]:this.config[a||o]),ht(this,"getNodeForOption",(r,{hasFallback:o=!1,params:a=[]}={})=>{let u=this.config[r];if(typeof u=="function"&&(u=u(...a)),u===!0&&(u=void 0),!u){if(u===void 0||u===!1)return u;throw new Error(`\`${r}\` was specified but was not a node, or did not return a node`)}let c=u;if(typeof u=="string"){try{c=this.doc.querySelector(u)}catch(d){throw new Error(`\`${r}\` appears to be an invalid selector; error="${d.message}"`)}if(!c&&!o)throw new Error(`\`${r}\` as selector refers to no known node`)}return c}),ht(this,"findNextNavNode",r=>{const{event:o,isBackward:a=!1}=r,u=r.target||Gn(o);this.updateTabbableNodes();let c=null;if(this.state.tabbableGroups.length>0){const d=this.findContainerIndex(u,o),h=d>=0?this.state.containerGroups[d]:void 0;if(d<0)a?c=this.state.tabbableGroups[this.state.tabbableGroups.length-1].lastTabbableNode:c=this.state.tabbableGroups[0].firstTabbableNode;else if(a){let m=this.state.tabbableGroups.findIndex(({firstTabbableNode:g})=>u===g);if(m<0&&((h==null?void 0:h.container)===u||dr(u)&&!Fi(u)&&!(h!=null&&h.nextTabbableNode(u,!1)))&&(m=d),m>=0){const g=m===0?this.state.tabbableGroups.length-1:m-1,T=this.state.tabbableGroups[g];c=na(u)>=0?T.lastTabbableNode:T.lastDomTabbableNode}else la(o)||(c=h==null?void 0:h.nextTabbableNode(u,!1))}else{let m=this.state.tabbableGroups.findIndex(({lastTabbableNode:g})=>u===g);if(m<0&&((h==null?void 0:h.container)===u||dr(u)&&!Fi(u)&&!(h!=null&&h.nextTabbableNode(u)))&&(m=d),m>=0){const g=m===this.state.tabbableGroups.length-1?0:m+1,T=this.state.tabbableGroups[g];c=na(u)>=0?T.firstTabbableNode:T.firstDomTabbableNode}else la(o)||(c=h==null?void 0:h.nextTabbableNode(u))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||t6;const n=U({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return la(r)&&!r.shiftKey},isKeyBackward(r){return la(r)&&r.shiftKey}},t);this.doc=n.document||cr(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=>{ER(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(a=>a===e)||this.isControlledElement(r,e))}isControlledElement(e,t){return this.config.followControlledElements?_E(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Po(e,{getShadowRoot:this.config.getShadowRoot}),n=IE(e,{getShadowRoot:this.config.getShadowRoot}),r=t[0],o=t[t.length-1],a=r,u=o;let c=!1;for(let h=0;h<t.length;h++)if(na(t[h])>0){c=!0;break}function d(h,m=!0){const g=t.indexOf(h);if(g>=0)return t[g+(m?1:-1)];const T=n.indexOf(h);if(!(T<0)){if(m){for(let b=T+1;b<n.length;b++)if(Fi(n[b]))return n[b]}else for(let b=T-1;b>=0;b--)if(Fi(n[b]))return n[b]}}return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:c,firstTabbableNode:r,lastTabbableNode:o,firstDomTabbableNode:a,lastDomTabbableNode:u,nextTabbableNode:d}}),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 xy.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?_y(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(Mt(this.doc,"focusin",this.handleFocus,!0),Mt(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),Mt(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),Mt(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),Mt(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),Mt(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=Io(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)}},la=e=>e.key==="Tab",ca=(e,...t)=>typeof e=="function"?e(...t):e,r6=e=>!e.isComposing&&e.key==="Escape",_y=e=>setTimeout(e,0),i6=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function Sy(e,t={}){let n;const r=kt(()=>{const o=typeof e=="function"?e():e;if(o){n=new n6(o,ne(U({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:cr(o)}));try{n.activate()}catch(a){}}});return function(){n==null||n.deactivate(),r()}}var Wf="data-scroll-lock";function o6(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function wy(e){const t=Ro(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function Ay(e){var b;const t=e!=null?e:document,n=(b=t.defaultView)!=null?b:window,{documentElement:r,body:o}=t;if(o.hasAttribute(Wf))return;const u=wy(r)||wy(o),c=n.innerWidth-r.clientWidth;o.setAttribute(Wf,"");const d=()=>QR(r,"--scrollbar-width",`${c}px`),h=o6(r),m=()=>{const x={overflow:"hidden"};return!u&&c>0&&(x[h]=`${c}px`),Ju(o,x)},g=()=>{var z,D;const{scrollX:x,scrollY:S,visualViewport:A}=n,C=(z=A==null?void 0:A.offsetLeft)!=null?z:0,O=(D=A==null?void 0:A.offsetTop)!=null?D:0,R={position:"fixed",overflow:"hidden",top:`${-(S-Math.floor(O))}px`,left:`${-(x-Math.floor(C))}px`,right:"0"};!u&&c>0&&(R[h]=`${c}px`);const F=Ju(o,R);return()=>{F==null||F(),n.scrollTo({left:x,top:S,behavior:"instant"})}},T=[d(),Ku()?g():m()];return()=>{T.forEach(x=>x==null?void 0:x()),o.removeAttribute(Wf)}}var s6=Ui("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),gr=s6.build(),vy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},Cy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},qf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},ky=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},a6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},Gf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},Kf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},u6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},Ny=e=>e.getById(vy(e)),$o=e=>e.getById(Cy(e)),Vo=e=>e.getById(qf(e)),Oy=e=>e.getById(ky(e)),l6=e=>e.getById(Gf(e)),c6=e=>e.getById(Kf(e));function d6(e,t){const{state:n,context:r,send:o,computed:a,prop:u,scope:c}=e,d=n.matches("open"),h=r.get("currentPlacement"),m=a("currentPortalled"),g=r.get("renderedElements"),T=RL(ne(U({},u("positioning")),{placement:h}));return{portalled:m,open:d,setOpen(b){n.matches("open")!==b&&o({type:b?"OPEN":"CLOSE"})},reposition(b={}){o({type:"POSITIONING.SET",options:b})},getArrowProps(){return t.element(ne(U({id:a6(c)},gr.arrow.attrs),{dir:u("dir"),style:T.arrow}))},getArrowTipProps(){return t.element(ne(U({},gr.arrowTip.attrs),{dir:u("dir"),style:T.arrowTip}))},getAnchorProps(){return t.element(ne(U({},gr.anchor.attrs),{dir:u("dir"),id:vy(c)}))},getTriggerProps(){return t.button(ne(U({},gr.trigger.attrs),{dir:u("dir"),type:"button","data-placement":h,id:Cy(c),"aria-haspopup":"dialog","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":qf(c),onPointerDown(b){AE(b)&&CR()&&b.currentTarget.focus()},onClick(b){b.defaultPrevented||o({type:"TOGGLE"})},onBlur(b){o({type:"TRIGGER_BLUR",target:b.relatedTarget})}}))},getIndicatorProps(){return t.element(ne(U({},gr.indicator.attrs),{dir:u("dir"),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ne(U({id:ky(c)},gr.positioner.attrs),{dir:u("dir"),style:T.floating}))},getContentProps(){return t.element(ne(U({},gr.content.attrs),{dir:u("dir"),id:qf(c),tabIndex:-1,role:"dialog","aria-modal":TE(u("modal")),hidden:!d,"data-state":d?"open":"closed","data-expanded":ko(d),"aria-labelledby":g.title?Gf(c):void 0,"aria-describedby":g.description?Kf(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(ne(U({},gr.title.attrs),{id:Gf(c),dir:u("dir")}))},getDescriptionProps(){return t.element(ne(U({},gr.description.attrs),{id:Kf(c),dir:u("dir")}))},getCloseTriggerProps(){return t.button(ne(U({},gr.closeTrigger.attrs),{dir:u("dir"),id:u6(c),type:"button","aria-label":"close",onClick(b){b.defaultPrevented||(b.stopPropagation(),o({type:"CLOSE"}))}}))}}}var f6={props({props:e}){return ne(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 a;e.set("currentPlacement",t("positioning").placement);const r=(a=Ny(n))!=null?a:$o(n);return ly(r,()=>Oy(n),ne(U({},t("positioning")),{defer:!0,onComplete(u){e.set("currentPlacement",u.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Vo(n);let o=!0;return by(r,{type:"popover",pointerBlocking:t("modal"),exclude:$o(n),defer:!0,onEscapeKeyDown(a){var u;(u=t("onEscapeKeyDown"))==null||u(a),!t("closeOnEscape")&&a.preventDefault()},onInteractOutside(a){var u;(u=t("onInteractOutside"))==null||u(a),!a.defaultPrevented&&(o=!(a.detail.focusable||a.detail.contextmenu),t("closeOnInteractOutside")||a.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:GR(()=>Vo(t),{triggerElement:$o(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?dy(()=>[Vo(t),$o(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return Ay(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?Sy(()=>Vo(t),{initialFocus:()=>RE({root:Vo(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")}),getShadowRoot:!0}):void 0}},actions:{reposition({event:e,prop:t,scope:n,context:r}){var u;const o=(u=Ny(n))!=null?u:$o(n);ly(o,()=>Oy(n),ne(U(U({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){kt(()=>{Object.assign(e.get("renderedElements"),{title:!!l6(t),description:!!c6(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||kt(()=>{const n=RE({root:Vo(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||kt(()=>{const a=$o(t);a==null||a.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})}}}};Mo()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[dF,hl]=Bi({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[fF,Qf]=Bi({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),h6=e=>{const t=ee.useId(),{getRootNode:n}=hl(),{dir:r}=Qf(),o=U({id:t,dir:r,getRootNode:n},e),a=el(f6,o);return d6(a,Of)},p6=e=>{const[t,u]=zE(e),c=u,{children:n}=c,r=rn(c,["children"]),o=h6(r),a=Pf(Nt({present:o.open},t));return P.jsx(lP,{value:o,children:P.jsx(BE,{value:a,children:n})})},Iy=ee.forwardRef((e,t)=>{const n=Rf(),r=ra(),o=Nt(ne(U({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return P.jsx(Gt.button,ne(U({},o),{ref:t}))});Iy.displayName="PopoverTrigger";function m6(e){return ln({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 g6(e){return ln({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 E6(e){return ln({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0"},child:[]}]})(e)}function y6(e){return ln({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708"},child:[]}]})(e)}function T6(e){return ln({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M9.5 13a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"},child:[]}]})(e)}const Xf=({className:e,componentType:t,children:n})=>{const[r,o]=ee.useState(!1),{globalClassName:a}=an(),u=h=>{o(h.open)},c=ee.useCallback(()=>{o(!1)},[]),d=ee.useMemo(()=>({closeMenu:c}),[c]);return P.jsxs(p6,{open:r,onOpenChange:u,positioning:{placement:"bottom-end"},children:[P.jsx(Iy,{"aria-label":`Overflow menu for ${t}`,className:re(`${J}-overflow-menu-button-trigger`,`${J}-icon-button`,a,e,`cim-${t}-component`),children:P.jsx(T6,{})}),P.jsx(HE,{children:P.jsx(UE,{className:re(`${J}-overflow-menu-list`,a,`cim-${t}-component`),children:P.jsx(hE.Provider,{value:d,children:n})})})]})};function Ry(e){return ln({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 Py(e){return ln({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[b6,zi]=Bi({name:"CarouselContext",hookName:"useCarouselContext",providerName:"<CarouselProvider />"}),Ly=ee.forwardRef((e,t)=>{const n=zi(),r=Nt(n.getControlProps(),e);return P.jsx(Gt.div,ne(U(U({},r),e),{ref:t}))});Ly.displayName="CarouselControl";const Dy=ee.forwardRef((e,t)=>{const[n,r]=ia()(e,["readOnly","index"]),o=zi(),a=Nt(o.getIndicatorProps(n),r);return P.jsx(Gt.button,ne(U({},a),{ref:t}))});Dy.displayName="CarouselIndicator";const My=ee.forwardRef((e,t)=>{const n=zi(),r=Nt(n.getIndicatorGroupProps(),e);return P.jsx(Gt.div,ne(U({},r),{ref:t}))});My.displayName="CarouselIndicatorGroup";const Fy=ee.forwardRef((e,t)=>{const[n,r]=ia()(e,["index","snapAlign"]),o=zi(),a=Nt(o.getItemProps(n),r);return P.jsx(Gt.div,ne(U({},a),{ref:t}))});Fy.displayName="CarouselItem";const By=ee.forwardRef((e,t)=>{const n=zi(),r=Nt(n.getItemGroupProps(),e);return P.jsx(Gt.div,ne(U({},r),{ref:t}))});By.displayName="CarouselItemGroup";const Uy=ee.forwardRef((e,t)=>{const n=zi(),r=Nt(n.getNextTriggerProps(),e);return P.jsx(Gt.button,ne(U({},r),{ref:t}))});Uy.displayName="CarouselNextTrigger";const Hy=ee.forwardRef((e,t)=>{const n=zi(),r=Nt(n.getPrevTriggerProps(),e);return P.jsx(Gt.button,ne(U({},r),{ref:t}))});Hy.displayName="CarouselPrevTrigger";function x6(e){const t=Ro(e),n=e.getBoundingClientRect();let r=t.getPropertyValue("scroll-padding-left").replace("auto","0px"),o=t.getPropertyValue("scroll-padding-top").replace("auto","0px"),a=t.getPropertyValue("scroll-padding-right").replace("auto","0px"),u=t.getPropertyValue("scroll-padding-bottom").replace("auto","0px");function c(T,b){let x=parseFloat(T);return/%/.test(T)&&(x/=100,x*=b),Number.isNaN(x)?0:x}let d=c(r,n.width),h=c(o,n.height),m=c(a,n.width),g=c(u,n.height);return{x:{before:d,after:m},y:{before:h,after:g}}}function _6(e,t,n="both"){return n==="x"&&e.right>=t.left&&e.left<=t.right||n==="y"&&e.bottom>=t.top&&e.top<=t.bottom||n==="both"&&e.right>=t.left&&e.left<=t.right&&e.bottom>=t.top&&e.top<=t.bottom}function zy(e){let t=[];for(const n of e.children)t=t.concat(n,zy(n));return t}function jy(e,t=!1){const n=e.getBoundingClientRect(),r={x:{start:[],center:[],end:[]},y:{start:[],center:[],end:[]}},o=t?zy(e):e.children;for(const a of["x","y"]){const u=a==="x"?"y":"x",c=a==="x"?"left":"top",d=a==="x"?"width":"height",h=a==="x"?"scrollLeft":"scrollTop";for(const m of o){const g=m.getBoundingClientRect();if(!_6(n,g,u))continue;const T=Ro(m);let[b,x]=T.getPropertyValue("scroll-snap-align").split(" ");typeof x=="undefined"&&(x=b);const S=a==="x"?x:b,A=g[c]-n[c]+e[h];switch(S){case"none":break;case"start":r[a].start.push({node:m,position:A});break;case"center":r[a].center.push({node:m,position:A+g[d]/2});break;case"end":r[a].end.push({node:m,position:A+g[d]});break}}}return r}function $y(e){const t=e.getBoundingClientRect(),n=x6(e),r=jy(e),o={x:e.scrollWidth-e.offsetWidth,y:e.scrollHeight-e.offsetHeight};return{x:Vy([...r.x.start.map(a=>a.position-n.x.before),...r.x.center.map(a=>a.position-t.width/2),...r.x.end.map(a=>a.position-t.width+n.x.after)].map(Yy(0,o.x))),y:Vy([...r.y.start.map(a=>a.position-n.y.before),...r.y.center.map(a=>a.position-t.height/2),...r.y.end.map(a=>a.position-t.height+n.y.after)].map(Yy(0,o.y)))}}function S6(e,t,n){const r=jy(e),o=[...r[t].start,...r[t].center,...r[t].end];for(const a of o)if(n(a.node))return a.position}var Vy=e=>[...new Set(e)],Yy=(e,t)=>n=>Math.max(e,Math.min(t,n)),w6=Ui("carousel").parts("root","itemGroup","item","control","nextTrigger","prevTrigger","indicatorGroup","indicator","autoplayTrigger"),kr=w6.build(),A6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.root)!=null?n:`carousel:${e.id}`},v6=(e,t)=>{var n,r,o;return(o=(r=(n=e.ids)==null?void 0:n.item)==null?void 0:r.call(n,t))!=null?o:`carousel:${e.id}:item:${t}`},pl=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.itemGroup)!=null?n:`carousel:${e.id}:item-group`},C6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.nextTrigger)!=null?n:`carousel:${e.id}:next-trigger`},k6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.prevTrigger)!=null?n:`carousel:${e.id}:prev-trigger`},N6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.indicatorGroup)!=null?n:`carousel:${e.id}:indicator-group`},Wy=(e,t)=>{var n,r,o;return(o=(r=(n=e.ids)==null?void 0:n.indicator)==null?void 0:r.call(n,t))!=null?o:`carousel:${e.id}:indicator:${t}`},hn=e=>e.getById(pl(e)),qy=e=>KR(hn(e),"[data-part=item]"),O6=(e,t)=>e.getById(Wy(e,t)),Gy=e=>{const t=hn(e);if(!t)return;const n=Po(t);t.setAttribute("tabindex",n.length>0?"-1":"0")};function I6(e,t){const{state:n,context:r,computed:o,send:a,scope:u,prop:c}=e,d=n.matches("autoplay"),h=n.matches("dragging"),m=o("canScrollNext"),g=o("canScrollPrev"),T=o("isHorizontal"),b=Array.from(r.get("pageSnapPoints")),x=r.get("page"),S=c("slidesPerPage"),A=c("padding"),C=c("translations");return{isPlaying:d,isDragging:h,page:x,pageSnapPoints:b,canScrollNext:m,canScrollPrev:g,getProgress(){return x/b.length},scrollToIndex(O,R){a({type:"INDEX.SET",index:O,instant:R})},scrollTo(O,R){a({type:"PAGE.SET",index:O,instant:R})},scrollNext(O){a({type:"PAGE.NEXT",instant:O})},scrollPrev(O){a({type:"PAGE.PREV",instant:O})},play(){a({type:"AUTOPLAY.START"})},pause(){a({type:"AUTOPLAY.PAUSE"})},isInView(O){return Array.from(r.get("slidesInView")).includes(O)},refresh(){a({type:"SNAP.REFRESH"})},getRootProps(){return t.element(ne(U({},kr.root.attrs),{id:A6(u),role:"region","aria-roledescription":"carousel","data-orientation":c("orientation"),dir:c("dir"),style:{"--slides-per-page":S,"--slide-spacing":c("spacing"),"--slide-item-size":"calc(100% / var(--slides-per-page) - var(--slide-spacing) * (var(--slides-per-page) - 1) / var(--slides-per-page))"}}))},getItemGroupProps(){return t.element(ne(U({},kr.itemGroup.attrs),{id:pl(u),"data-orientation":c("orientation"),"data-dragging":ko(h),dir:c("dir"),"aria-live":d?"off":"polite",onFocus(O){No(O.currentTarget,Gn(O))&&a({type:"VIEWPORT.FOCUS"})},onBlur(O){No(O.currentTarget,O.relatedTarget)||a({type:"VIEWPORT.BLUR"})},onMouseDown(O){if(O.defaultPrevented||!c("allowMouseDrag")||!AE(O))return;const R=Gn(O);dr(R)&&R!==O.currentTarget||(O.preventDefault(),a({type:"DRAGGING.START"}))},onWheel:KI(O=>{const R=c("orientation")==="horizontal"?"deltaX":"deltaY";O[R]<0&&!o("canScrollPrev")||O[R]>0&&!o("canScrollNext")||a({type:"USER.SCROLL"})},150),onTouchStart(){a({type:"USER.SCROLL"})},style:{display:"grid",gap:"var(--slide-spacing)",scrollSnapType:[T?"x":"y",c("snapType")].join(" "),gridAutoFlow:T?"column":"row",scrollbarWidth:"none",overscrollBehaviorX:"contain",[T?"gridAutoColumns":"gridAutoRows"]:"var(--slide-item-size)",[T?"scrollPaddingInline":"scrollPaddingBlock"]:A,[T?"paddingInline":"paddingBlock"]:A,[T?"overflowX":"overflowY"]:"auto"}}))},getItemProps(O){const R=r.get("slidesInView").includes(O.index);return t.element(ne(U({},kr.item.attrs),{id:v6(u,O.index),dir:c("dir"),role:"group","data-index":O.index,"data-inview":ko(R),"aria-roledescription":"slide","data-orientation":c("orientation"),"aria-label":C.item(O.index,c("slideCount")),"aria-hidden":TE(!R),style:{scrollSnapAlign:(()=>{var ce;const F=(ce=O.snapAlign)!=null?ce:"start",z=c("slidesPerMove"),D=z==="auto"?Math.floor(c("slidesPerPage")):z;return(O.index+D)%D===0?F:void 0})()}}))},getControlProps(){return t.element(ne(U({},kr.control.attrs),{"data-orientation":c("orientation")}))},getPrevTriggerProps(){return t.button(ne(U({},kr.prevTrigger.attrs),{id:k6(u),type:"button",disabled:!g,dir:c("dir"),"aria-label":C.prevTrigger,"data-orientation":c("orientation"),"aria-controls":pl(u),onClick(O){O.defaultPrevented||a({type:"PAGE.PREV",src:"trigger"})}}))},getNextTriggerProps(){return t.button(ne(U({},kr.nextTrigger.attrs),{dir:c("dir"),id:C6(u),type:"button","aria-label":C.nextTrigger,"data-orientation":c("orientation"),"aria-controls":pl(u),disabled:!m,onClick(O){O.defaultPrevented||a({type:"PAGE.NEXT",src:"trigger"})}}))},getIndicatorGroupProps(){return t.element(ne(U({},kr.indicatorGroup.attrs),{dir:c("dir"),id:N6(u),"data-orientation":c("orientation"),onKeyDown(O){if(O.defaultPrevented)return;const R="indicator",F={ArrowDown(q){T||(a({type:"PAGE.NEXT",src:R}),q.preventDefault())},ArrowUp(q){T||(a({type:"PAGE.PREV",src:R}),q.preventDefault())},ArrowRight(q){T&&(a({type:"PAGE.NEXT",src:R}),q.preventDefault())},ArrowLeft(q){T&&(a({type:"PAGE.PREV",src:R}),q.preventDefault())},Home(q){a({type:"PAGE.SET",index:0,src:R}),q.preventDefault()},End(q){a({type:"PAGE.SET",index:b.length-1,src:R}),q.preventDefault()}},z=RR(O,{dir:c("dir"),orientation:c("orientation")}),D=F[z];D==null||D(O)}}))},getIndicatorProps(O){return t.button(ne(U({},kr.indicator.attrs),{dir:c("dir"),id:Wy(u,O.index),type:"button","data-orientation":c("orientation"),"data-index":O.index,"data-readonly":ko(O.readOnly),"data-current":ko(O.index===x),"aria-label":C.indicator(O.index),onClick(R){R.defaultPrevented||O.readOnly||a({type:"PAGE.SET",index:O.index,src:"indicator"})}}))},getAutoplayTriggerProps(){return t.button(ne(U({},kr.autoplayTrigger.attrs),{type:"button","data-orientation":c("orientation"),"data-pressed":ko(d),"aria-label":d?C.autoplayStop:C.autoplayStart,onClick(O){O.defaultPrevented||a({type:d?"AUTOPLAY.PAUSE":"AUTOPLAY.START"})}}))}}}var R6={props({props:e}){return tR(e,["slideCount"],"carousel"),ne(U({dir:"ltr",defaultPage:0,orientation:"horizontal",snapType:"mandatory",loop:!!e.autoplay,slidesPerPage:1,slidesPerMove:"auto",spacing:"0px",autoplay:!1,allowMouseDrag:!1,inViewThreshold:.6},e),{translations:U({nextTrigger:"Next slide",prevTrigger:"Previous slide",indicator:t=>`Go to slide ${t+1}`,item:(t,n)=>`${t+1} of ${n}`,autoplayStart:"Start slide rotation",autoplayStop:"Stop slide rotation"},e.translations)})},refs(){return{timeoutRef:void 0}},initialState({prop:e}){return e("autoplay")?"autoplay":"idle"},context({prop:e,bindable:t,getContext:n}){return{page:t(()=>({defaultValue:e("defaultPage"),value:e("page"),onChange(r){var u;const a=n().get("pageSnapPoints");(u=e("onPageChange"))==null||u({page:r,pageSnapPoint:a[r]})}})),pageSnapPoints:t(()=>({defaultValue:P6(e("slideCount"),e("slidesPerMove"),e("slidesPerPage"))})),slidesInView:t(()=>({defaultValue:[]}))}},computed:{isRtl:({prop:e})=>e("dir")==="rtl",isHorizontal:({prop:e})=>e("orientation")==="horizontal",canScrollNext:({prop:e,context:t})=>e("loop")||t.get("page")<t.get("pageSnapPoints").length-1,canScrollPrev:({prop:e,context:t})=>e("loop")||t.get("page")>0,autoplayInterval:({prop:e})=>{const t=e("autoplay");return BI(t)?t.delay:4e3}},watch({track:e,action:t,context:n,prop:r,send:o}){e([()=>r("slidesPerPage"),()=>r("slidesPerMove")],()=>{t(["setSnapPoints"])}),e([()=>n.get("page")],()=>{t(["scrollToPage","focusIndicatorEl"])}),e([()=>r("orientation")],()=>{t(["setSnapPoints","scrollToPage"])}),e([()=>r("slideCount")],()=>{o({type:"SNAP.REFRESH",src:"slide.count"})}),e([()=>!!r("autoplay")],()=>{o({type:r("autoplay")?"AUTOPLAY.START":"AUTOPLAY.PAUSE",src:"autoplay.prop.change"})})},on:{"PAGE.NEXT":{target:"idle",actions:["clearScrollEndTimer","setNextPage"]},"PAGE.PREV":{target:"idle",actions:["clearScrollEndTimer","setPrevPage"]},"PAGE.SET":{target:"idle",actions:["clearScrollEndTimer","setPage"]},"INDEX.SET":{target:"idle",actions:["clearScrollEndTimer","setMatchingPage"]},"SNAP.REFRESH":{actions:["setSnapPoints","clampPage"]},"PAGE.SCROLL":{actions:["scrollToPage"]}},effects:["trackSlideMutation","trackSlideIntersections","trackSlideResize"],entry:["setSnapPoints","setPage"],exit:["clearScrollEndTimer"],states:{idle:{on:{"DRAGGING.START":{target:"dragging",actions:["invokeDragStart"]},"AUTOPLAY.START":{target:"autoplay",actions:["invokeAutoplayStart"]},"USER.SCROLL":{target:"userScroll"},"VIEWPORT.FOCUS":{target:"focus"}}},focus:{effects:["trackKeyboardScroll"],on:{"VIEWPORT.BLUR":{target:"idle"},"PAGE.NEXT":{actions:["clearScrollEndTimer","setNextPage"]},"PAGE.PREV":{actions:["clearScrollEndTimer","setPrevPage"]},"PAGE.SET":{actions:["clearScrollEndTimer","setPage"]},"INDEX.SET":{actions:["clearScrollEndTimer","setMatchingPage"]},"USER.SCROLL":{target:"userScroll"}}},dragging:{effects:["trackPointerMove"],entry:["disableScrollSnap"],on:{DRAGGING:{actions:["scrollSlides","invokeDragging"]},"DRAGGING.END":{target:"idle",actions:["endDragging","invokeDraggingEnd"]}}},userScroll:{effects:["trackScroll"],on:{"SCROLL.END":[{guard:"isFocused",target:"focus",actions:["setClosestPage"]},{target:"idle",actions:["setClosestPage"]}]}},autoplay:{effects:["trackDocumentVisibility","trackScroll","autoUpdateSlide"],exit:["invokeAutoplayEnd"],on:{"AUTOPLAY.TICK":{actions:["setNextPage","invokeAutoplay"]},"DRAGGING.START":{target:"dragging",actions:["invokeDragStart"]},"AUTOPLAY.PAUSE":{target:"idle"}}}},implementations:{guards:{isFocused:({scope:e})=>e.isActiveElement(hn(e))},effects:{autoUpdateSlide({computed:e,send:t}){const n=setInterval(()=>{t({type:e("canScrollNext")?"AUTOPLAY.TICK":"AUTOPLAY.PAUSE",src:"autoplay.interval"})},e("autoplayInterval"));return()=>clearInterval(n)},trackSlideMutation({scope:e,send:t}){const n=hn(e);if(!n)return;const r=e.getWin(),o=new r.MutationObserver(()=>{t({type:"SNAP.REFRESH",src:"slide.mutation"}),Gy(e)});return Gy(e),o.observe(n,{childList:!0,subtree:!0}),()=>o.disconnect()},trackSlideResize({scope:e,send:t}){if(!hn(e))return;const r=e.getWin(),o=()=>{t({type:"SNAP.REFRESH",src:"slide.resize"})};kt(()=>{o(),kt(()=>{t({type:"PAGE.SCROLL",instant:!0})})});const a=new r.ResizeObserver(o);return qy(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackSlideIntersections({scope:e,prop:t,context:n}){const r=hn(e),o=e.getWin(),a=new o.IntersectionObserver(u=>{const c=u.reduce((d,h)=>{var T;const m=h.target,g=Number((T=m.dataset.index)!=null?T:"-1");return g==null||Number.isNaN(g)||g===-1?d:h.isIntersecting?PI(d,g):LI(d,g)},n.get("slidesInView"));n.set("slidesInView",DI(c))},{root:r,threshold:t("inViewThreshold")});return qy(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackScroll({send:e,refs:t,scope:n}){const r=hn(n);return r?Mt(r,"scroll",()=>{clearTimeout(t.get("timeoutRef")),t.set("timeoutRef",void 0),t.set("timeoutRef",setTimeout(()=>{e({type:"SCROLL.END"})},150))},{passive:!0}):void 0},trackDocumentVisibility({scope:e,send:t}){const n=e.getDoc();return Mt(n,"visibilitychange",()=>{n.visibilityState!=="visible"&&t({type:"AUTOPLAY.PAUSE",src:"doc.hidden"})})},trackPointerMove({scope:e,send:t}){const n=e.getDoc();return WR(n,{onPointerMove({event:r}){t({type:"DRAGGING",left:-r.movementX,top:-r.movementY})},onPointerUp(){t({type:"DRAGGING.END"})}})},trackKeyboardScroll({scope:e,send:t,context:n}){const r=e.getWin();return Mt(r,"keydown",a=>{switch(a.key){case"ArrowRight":a.preventDefault(),t({type:"PAGE.NEXT"});break;case"ArrowLeft":a.preventDefault(),t({type:"PAGE.PREV"});break;case"Home":a.preventDefault(),t({type:"PAGE.SET",index:0});break;case"End":a.preventDefault(),t({type:"PAGE.SET",index:n.get("pageSnapPoints").length-1})}},{capture:!0})}},actions:{clearScrollEndTimer({refs:e}){e.get("timeoutRef")!=null&&(clearTimeout(e.get("timeoutRef")),e.set("timeoutRef",void 0))},scrollToPage({context:e,event:t,scope:n,computed:r,flush:o}){var h;const a=t.instant?"instant":"smooth",u=EE((h=t.index)!=null?h:e.get("page"),0,e.get("pageSnapPoints").length-1),c=hn(n);if(!c)return;const d=r("isHorizontal")?"left":"top";o(()=>{c.scrollTo({[d]:e.get("pageSnapPoints")[u],behavior:a})})},setClosestPage({context:e,scope:t,computed:n}){const r=hn(t);if(!r)return;const o=n("isHorizontal")?r.scrollLeft:r.scrollTop,a=e.get("pageSnapPoints").findIndex(u=>Math.abs(u-o)<1);a!==-1&&e.set("page",a)},setNextPage({context:e,prop:t,state:n}){const r=n.matches("autoplay")||t("loop"),o=pE(e.get("pageSnapPoints"),e.get("page"),{loop:r});e.set("page",o)},setPrevPage({context:e,prop:t,state:n}){const r=n.matches("autoplay")||t("loop"),o=MI(e.get("pageSnapPoints"),e.get("page"),{loop:r});e.set("page",o)},setMatchingPage({context:e,event:t,computed:n,scope:r}){const o=hn(r);if(!o)return;const a=S6(o,n("isHorizontal")?"x":"y",c=>c.dataset.index===t.index.toString());if(a==null)return;const u=e.get("pageSnapPoints").findIndex(c=>Math.abs(c-a)<1);e.set("page",u)},setPage({context:e,event:t}){var r;const n=(r=t.index)!=null?r:e.get("page");e.set("page",n)},clampPage({context:e}){const t=EE(e.get("page"),0,e.get("pageSnapPoints").length-1);e.set("page",t)},setSnapPoints({context:e,computed:t,scope:n}){const r=hn(n);if(!r)return;const o=$y(r);e.set("pageSnapPoints",t("isHorizontal")?o.x:o.y)},disableScrollSnap({scope:e}){const t=hn(e);if(!t)return;const n=getComputedStyle(t);t.dataset.scrollSnapType=n.getPropertyValue("scroll-snap-type"),t.style.setProperty("scroll-snap-type","none")},scrollSlides({scope:e,event:t}){const n=hn(e);n==null||n.scrollBy({left:t.left,top:t.top,behavior:"instant"})},endDragging({scope:e,context:t,computed:n}){const r=hn(e);if(!r)return;const o=r.scrollLeft,a=r.scrollTop,u=$y(r),c=u.x.reduce((h,m)=>Math.abs(m-o)<Math.abs(h-o)?m:h,u.x[0]),d=u.y.reduce((h,m)=>Math.abs(m-a)<Math.abs(h-a)?m:h,u.y[0]);kt(()=>{r.scrollTo({left:c,top:d,behavior:"smooth"});const h=n("isHorizontal")?c:d;t.set("page",t.get("pageSnapPoints").indexOf(h));const m=r.dataset.scrollSnapType;m&&(r.style.setProperty("scroll-snap-type",m),delete r.dataset.scrollSnapType)})},focusIndicatorEl({context:e,event:t,scope:n}){if(t.src!=="indicator")return;const r=O6(n,e.get("page"));r&&kt(()=>r.focus({preventScroll:!0}))},invokeDragStart({context:e,prop:t}){var n;(n=t("onDragStatusChange"))==null||n({type:"dragging.start",isDragging:!0,page:e.get("page")})},invokeDragging({context:e,prop:t}){var n;(n=t("onDragStatusChange"))==null||n({type:"dragging",isDragging:!0,page:e.get("page")})},invokeDraggingEnd({context:e,prop:t}){var n;(n=t("onDragStatusChange"))==null||n({type:"dragging.end",isDragging:!1,page:e.get("page")})},invokeAutoplay({context:e,prop:t}){var n;(n=t("onAutoplayStatusChange"))==null||n({type:"autoplay",isPlaying:!0,page:e.get("page")})},invokeAutoplayStart({context:e,prop:t}){var n;(n=t("onAutoplayStatusChange"))==null||n({type:"autoplay.start",isPlaying:!0,page:e.get("page")})},invokeAutoplayEnd({context:e,prop:t}){var n;(n=t("onAutoplayStatusChange"))==null||n({type:"autoplay.stop",isPlaying:!1,page:e.get("page")})}}}};function P6(e,t,n){if(e==null||n<=0)return[];const r=[],o=t==="auto"?Math.floor(n):t;if(o<=0)return[];for(let a=0;a<e&&!(a+n>e);a+=o)r.push(a);return r}Mo()(["dir","getRootNode","id","ids","loop","page","defaultPage","onPageChange","orientation","slideCount","slidesPerPage","slidesPerMove","spacing","padding","autoplay","allowMouseDrag","inViewThreshold","translations","snapType","onDragStatusChange","onAutoplayStatusChange"]),Mo()(["index","readOnly"]),Mo()(["index","snapAlign"]);const L6=e=>{const t=ee.useId(),{getRootNode:n}=hl(),{dir:r}=Qf(),o=U({id:t,dir:r,getRootNode:n},e),a=el(R6,o);return I6(a,Of)},Ky=ee.forwardRef((e,t)=>{const[n,r]=ia()(e,["allowMouseDrag","autoplay","defaultPage","id","ids","inViewThreshold","loop","onAutoplayStatusChange","onDragStatusChange","onPageChange","orientation","padding","page","slideCount","slidesPerMove","slidesPerPage","snapType","spacing","translations"]),o=L6(n),a=Nt(o.getRootProps(),r);return P.jsx(b6,{value:o,children:P.jsx(Gt.div,ne(U({},a),{ref:t}))})});Ky.displayName="CarouselRoot";const D6=180,M6=e=>{const t=e.trim(),n=parseFloat(t);return Number.isNaN(n)?0:t.endsWith("rem")?n*16:n},F6=({globalClassName:e,className:t,itemMinWidth:n=D6,spacing:r="0.5rem",loop:o=!1,allowMouseDrag:a=!0,showIndicators:u=!0,showNavigation:c=!0,onPageChange:d,ariaLabel:h="Product carousel",children:m})=>{const g=Array.from(m),T=g.length,b=ee.useRef(null),[x,S]=ee.useState(0),{width:A}=kw();ee.useLayoutEffect(()=>{b.current&&S(b.current.getBoundingClientRect().width)},[A,T]);const C=M6(r),O=n+C,R=x>0?(x+C)/O:1,F=Math.max(1,Math.floor(R));if(T===0)return null;const z=T>F,D=Math.ceil(T/F),q=z?Math.max(1,R):F;return P.jsxs(Ky,{ref:b,className:re(e,t,`${J}-carousel`),slidesPerPage:q,slidesPerMove:F,spacing:r,loop:o,allowMouseDrag:a,slideCount:T,onPageChange:d,"aria-label":h,children:[P.jsx(By,{className:re(e,`${J}-carousel__item-group`,{"carousel-row-container":!z}),children:g.map((ce,be)=>P.jsx(Fy,{index:be,className:re(e,`${J}-carousel__item`),children:ce},be))}),c&&z&&P.jsxs(Ly,{className:re(e,`${J}-carousel__control`),children:[P.jsx(Hy,{className:re(e,`${J}-carousel__prev-trigger`),"aria-label":"Previous slide",children:P.jsx(E6,{})}),P.jsx(Uy,{className:re(e,`${J}-carousel__next-trigger`),"aria-label":"Next slide",children:P.jsx(y6,{})})]}),u&&z&&P.jsx(My,{className:re(e,`${J}-carousel__indicator-group`),children:Array.from({length:D},(ce,be)=>P.jsx(Dy,{index:be,className:re(e,`${J}-carousel__indicator`),"aria-label":`Go to slide group ${be+1}`},be))})]})},Qy=({className:e,label:t="Close",onClick:n,disabled:r=!1})=>P.jsx("button",{"aria-label":t,className:re(e,`${J}-close-button`),disabled:r,onClick:n,children:P.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:P.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"})})}),B6=({className:e,globalClassName:t,suggestions:n,disabled:r,isWidgetStandalone:o,onSuggestionClick:a})=>{const u=o?"standalone":"embedded",c=d=>()=>{a(d)};return P.jsx("div",{className:re(t,`${J}-suggestion-container ${u}`,e),children:n.map(d=>o?P.jsx(A0,{disabled:r,className:re(t,`${J}-suggestion-button standalone`),onClick:c(d),children:d},d):P.jsx("button",{disabled:r,className:re(t,`${J}-suggestion-button embedded`),onClick:c(d),children:d},d))})},Xy=({componentType:e,isIcon:t})=>{const{globalClassName:n,enableMinimize:r}=an();if(!r)return null;const o=()=>{vi(!1),yu(!0)};return t?P.jsx(jr,{className:re(n,`${J}-toggle-minimize-button`,`cim-${e}-component`),ariaLabel:"Toggle Minimize",title:"Minimize",onClick:o,icon:P.jsx(S0,{})}):P.jsxs("button",{className:re(n,`${J}-overflow-menu-button`,`${J}-toggle-minimize-button`,`cim-${e}-component`),onClick:o,children:[P.jsx(S0,{}),"Minimize"]})},Jy=({componentType:e,isIcon:t})=>{const{globalClassName:n}=an(),r=ea(),o=()=>{Tu("modal"),r()};return t?P.jsx(jr,{className:re(n,`${J}-toggle-modal-button`,`cim-${e}-component`),ariaLabel:"Toggle Modal",onClick:o,icon:P.jsx(Py,{})}):P.jsxs("button",{className:re(n,`${J}-overflow-menu-button`,`${J}-toggle-modal-button`,`cim-${e}-component`),onClick:o,children:[P.jsx(Py,{}),"Show modal"]})};function Zy(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 U6(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function H6(e,t,n){const o=Ru((n||{}).ignore||[]),a=z6(t);let u=-1;for(;++u<a.length;)Mg(e,"text",c);function c(h,m){let g=-1,T;for(;++g<m.length;){const b=m[g],x=T?T.children:void 0;if(o(b,x?x.indexOf(b):void 0,T))return;T=b}if(T)return d(h,m)}function d(h,m){const g=m[m.length-1],T=a[u][0],b=a[u][1];let x=0;const A=g.children.indexOf(h);let C=!1,O=[];T.lastIndex=0;let R=T.exec(h.value);for(;R;){const F=R.index,z={index:R.index,input:R.input,stack:[...m,h]};let D=b(...R,z);if(typeof D=="string"&&(D=D.length>0?{type:"text",value:D}:void 0),D===!1?T.lastIndex=F+1:(x!==F&&O.push({type:"text",value:h.value.slice(x,F)}),Array.isArray(D)?O.push(...D):D&&O.push(D),x=F+R[0].length,C=!0),!T.global)break;R=T.exec(h.value)}return C?(x<h.value.length&&O.push({type:"text",value:h.value.slice(x)}),g.children.splice(A,1,...O)):O=[h],A+O.length}}function z6(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([j6(o[0]),$6(o[1])])}return t}function j6(e){return typeof e=="string"?new RegExp(U6(e),"g"):e}function $6(e){return typeof e=="function"?e:function(){return e}}const Jf="phrasing",Zf=["autolink","link","image","label"];function V6(){return{transforms:[X6],enter:{literalAutolink:W6,literalAutolinkEmail:eh,literalAutolinkHttp:eh,literalAutolinkWww:eh},exit:{literalAutolink:Q6,literalAutolinkEmail:K6,literalAutolinkHttp:q6,literalAutolinkWww:G6}}}function Y6(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Jf,notInConstruct:Zf},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Jf,notInConstruct:Zf},{character:":",before:"[ps]",after:"\\/",inConstruct:Jf,notInConstruct:Zf}]}}function W6(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function eh(e){this.config.enter.autolinkProtocol.call(this,e)}function q6(e){this.config.exit.autolinkProtocol.call(this,e)}function G6(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 K6(e){this.config.exit.autolinkEmail.call(this,e)}function Q6(e){this.exit(e)}function X6(e){H6(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,J6],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Z6]],{ignore:["link","linkReference"]})}function J6(e,t,n,r,o){let a="";if(!eT(o)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!e4(n)))return!1;const u=t4(n+r);if(!u[0])return!1;const c={type:"link",title:null,url:a+t+u[0],children:[{type:"text",value:t+u[0]}]};return u[1]?[c,{type:"text",value:u[1]}]:c}function Z6(e,t,n,r){return!eT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function e4(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 t4(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=Zy(e,"(");let a=Zy(e,")");for(;r!==-1&&o>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),a++;return[e,n]}function eT(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Ni(n)||Au(n))&&(!t||n!==47)}tT.peek=c4;function n4(){this.buffer()}function r4(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function i4(){this.buffer()}function o4(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function s4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Wn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function a4(e){this.exit(e)}function u4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Wn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function l4(e){this.exit(e)}function c4(){return"["}function tT(e,t,n,r){const o=n.createTracker(r);let a=o.move("[^");const u=n.enter("footnoteReference"),c=n.enter("reference");return a+=o.move(n.safe(n.associationId(e),{after:"]",before:a})),c(),u(),a+=o.move("]"),a}function d4(){return{enter:{gfmFootnoteCallString:n4,gfmFootnoteCall:r4,gfmFootnoteDefinitionLabelString:i4,gfmFootnoteDefinition:o4},exit:{gfmFootnoteCallString:s4,gfmFootnoteCall:a4,gfmFootnoteDefinitionLabelString:u4,gfmFootnoteDefinition:l4}}}function f4(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:tT},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,o,a,u){const c=a.createTracker(u);let d=c.move("[^");const h=a.enter("footnoteDefinition"),m=a.enter("label");return d+=c.move(a.safe(a.associationId(r),{before:d,after:"]"})),m(),d+=c.move("]:"),r.children&&r.children.length>0&&(c.shift(4),d+=c.move((t?`
38
- `:" ")+a.indentLines(a.containerFlow(r,c.current()),t?nT:h4))),h(),d}}function h4(e,t,n){return t===0?e:nT(e,t,n)}function nT(e,t,n){return(n?"":" ")+e}const p4=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];rT.peek=T4;function m4(){return{canContainEols:["delete"],enter:{strikethrough:E4},exit:{strikethrough:y4}}}function g4(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:p4}],handlers:{delete:rT}}}function E4(e){this.enter({type:"delete",children:[]},e)}function y4(e){this.exit(e)}function rT(e,t,n,r){const o=n.createTracker(r),a=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,ne(U({},o.current()),{before:u,after:"~"})),u+=o.move("~~"),a(),u}function T4(){return"~"}function b4(e){return e.length}function x4(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||b4,a=[],u=[],c=[],d=[];let h=0,m=-1;for(;++m<e.length;){const S=[],A=[];let C=-1;for(e[m].length>h&&(h=e[m].length);++C<e[m].length;){const O=_4(e[m][C]);if(n.alignDelimiters!==!1){const R=o(O);A[C]=R,(d[C]===void 0||R>d[C])&&(d[C]=R)}S.push(O)}u[m]=S,c[m]=A}let g=-1;if(typeof r=="object"&&"length"in r)for(;++g<h;)a[g]=iT(r[g]);else{const S=iT(r);for(;++g<h;)a[g]=S}g=-1;const T=[],b=[];for(;++g<h;){const S=a[g];let A="",C="";S===99?(A=":",C=":"):S===108?A=":":S===114&&(C=":");let O=n.alignDelimiters===!1?1:Math.max(1,d[g]-A.length-C.length);const R=A+"-".repeat(O)+C;n.alignDelimiters!==!1&&(O=A.length+O+C.length,O>d[g]&&(d[g]=O),b[g]=O),T[g]=R}u.splice(1,0,T),c.splice(1,0,b),m=-1;const x=[];for(;++m<u.length;){const S=u[m],A=c[m];g=-1;const C=[];for(;++g<h;){const O=S[g]||"";let R="",F="";if(n.alignDelimiters!==!1){const z=d[g]-(A[g]||0),D=a[g];D===114?R=" ".repeat(z):D===99?z%2?(R=" ".repeat(z/2+.5),F=" ".repeat(z/2-.5)):(R=" ".repeat(z/2),F=R):F=" ".repeat(z)}n.delimiterStart!==!1&&!g&&C.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&O==="")&&(n.delimiterStart!==!1||g)&&C.push(" "),n.alignDelimiters!==!1&&C.push(R),C.push(O),n.alignDelimiters!==!1&&C.push(F),n.padding!==!1&&C.push(" "),(n.delimiterEnd!==!1||g!==h-1)&&C.push("|")}x.push(n.delimiterEnd===!1?C.join("").replace(/ +$/,""):C.join(""))}return x.join(`
39
- `)}function _4(e){return e==null?"":String(e)}function iT(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 S4(e,t,n,r){const o=n.enter("blockquote"),a=n.createTracker(r);a.move("> "),a.shift(2);const u=n.indentLines(n.containerFlow(e,a.current()),w4);return o(),u}function w4(e,t,n){return">"+(n?"":" ")+e}function A4(e,t){return oT(e,t.inConstruct,!0)&&!oT(e,t.notInConstruct,!1)}function oT(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 sT(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if(n.unsafe[o].character===`
40
- `&&A4(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return`\\
41
- `}function v4(e,t){const n=String(e);let r=n.indexOf(t),o=r,a=0,u=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===o?++a>u&&(u=a):a=1,o=r+t.length,r=n.indexOf(t,o);return u}function C4(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 k4(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 N4(e,t,n,r){const o=k4(n),a=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(C4(e,n)){const g=n.enter("codeIndented"),T=n.indentLines(a,O4);return g(),T}const c=n.createTracker(r),d=o.repeat(Math.max(v4(a,o)+1,3)),h=n.enter("codeFenced");let m=c.move(d);if(e.lang){const g=n.enter(`codeFencedLang${u}`);m+=c.move(n.safe(e.lang,U({before:m,after:" ",encode:["`"]},c.current()))),g()}if(e.lang&&e.meta){const g=n.enter(`codeFencedMeta${u}`);m+=c.move(" "),m+=c.move(n.safe(e.meta,U({before:m,after:`
42
- `,encode:["`"]},c.current()))),g()}return m+=c.move(`
35
+ `}),n}function Pg(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function Lg(e,t){const n=Tk(e,t),r=n.one(e,void 0),o=lk(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&a.children.push({type:"text",value:`
36
+ `},o),a}function Sk(e,t){return e&&"run"in e?function(n,r){return et(this,null,function*(){const o=Lg(n,U({file:r},t));yield e.run(o,r)})}:function(n,r){return Lg(n,U({file:r},e||t))}}function Dg(e){if(e)throw e}var Hd,Mg;function Ak(){if(Mg)return Hd;Mg=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]"},a=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 T;for(T in h);return typeof T=="undefined"||e.call(h,T)},u=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 Hd=function d(){var h,m,E,T,b,_,w=arguments[0],A=1,C=arguments.length,I=!1;for(typeof w=="boolean"&&(I=w,w=arguments[1]||{},A=2),(w==null||typeof w!="object"&&typeof w!="function")&&(w={});A<C;++A)if(h=arguments[A],h!=null)for(m in h)E=c(w,m),T=c(h,m),w!==T&&(I&&T&&(a(T)||(b=o(T)))?(b?(b=!1,_=E&&o(E)?E:[]):_=E&&a(E)?E:{},u(w,{name:m,newValue:d(I,_,T)})):typeof T!="undefined"&&u(w,{name:m,newValue:T}));return w},Hd}var vk=Ak();const zd=We(vk);function jd(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 Ck(){const e=[],t={run:n,use:r};return t;function n(...o){let a=-1;const u=o.pop();if(typeof u!="function")throw new TypeError("Expected function as last argument, not "+u);c(null,...o);function c(d,...h){const m=e[++a];let E=-1;if(d){u(d);return}for(;++E<o.length;)(h[E]===null||h[E]===void 0)&&(h[E]=o[E]);o=h,m?kk(m,c)(...h):u(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 kk(e,t){let n;return r;function r(...u){const c=e.length>u.length;let d;c&&u.push(o);try{d=e.apply(this,u)}catch(h){const m=h;if(c&&n)throw m;return o(m)}c||(d&&d.then&&typeof d.then=="function"?d.then(a,o):d instanceof Error?o(d):a(d))}function o(u,...c){n||(n=!0,t(u,...c))}function a(u){o(null,u)}}const ur={basename:Nk,dirname:Ok,extname:Ik,join:Rk,sep:"/"};function Nk(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Hs(e);let n=0,r=-1,o=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(a){n=o+1;break}}else r<0&&(a=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let u=-1,c=t.length-1;for(;o--;)if(e.codePointAt(o)===47){if(a){n=o+1;break}}else u<0&&(a=!0,u=o+1),c>-1&&(e.codePointAt(o)===t.codePointAt(c--)?c<0&&(r=o):(c=-1,r=u));return n===r?r=u:r<0&&(r=e.length),e.slice(n,r)}function Ok(e){if(Hs(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 Ik(e){Hs(e);let t=e.length,n=-1,r=0,o=-1,a=0,u;for(;t--;){const c=e.codePointAt(t);if(c===47){if(u){r=t+1;break}continue}n<0&&(u=!0,n=t+1),c===46?o<0?o=t:a!==1&&(a=1):o>-1&&(a=-1)}return o<0||n<0||a===0||a===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function Rk(...e){let t=-1,n;for(;++t<e.length;)Hs(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Pk(n)}function Pk(e){Hs(e);const t=e.codePointAt(0)===47;let n=Lk(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Lk(e,t){let n="",r=0,o=-1,a=0,u=-1,c,d;for(;++u<=e.length;){if(u<e.length)c=e.codePointAt(u);else{if(c===47)break;c=47}if(c===47){if(!(o===u-1||a===1))if(o!==u-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(d=n.lastIndexOf("/"),d!==n.length-1){d<0?(n="",r=0):(n=n.slice(0,d),r=n.length-1-n.lastIndexOf("/")),o=u,a=0;continue}}else if(n.length>0){n="",r=0,o=u,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,u):n=e.slice(o+1,u),r=u-o-1;o=u,a=0}else c===46&&a>-1?a++:a=-1}return n}function Hs(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Dk={cwd:Mk};function Mk(){return"/"}function $d(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function Fk(e){if(typeof e=="string")e=new URL(e);else if(!$d(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 Bk(e)}function Bk(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 Vd=["history","path","basename","stem","extname","dirname"];class Fg{constructor(t){let n;t?$d(t)?n={path:t}:typeof t=="string"||Uk(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":Dk.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<Vd.length;){const a=Vd[r];a in n&&n[a]!==void 0&&n[a]!==null&&(this[a]=a==="history"?[...n[a]]:n[a])}let o;for(o in n)Vd.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?ur.basename(this.path):void 0}set basename(t){Wd(t,"basename"),Yd(t,"basename"),this.path=ur.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?ur.dirname(this.path):void 0}set dirname(t){Bg(this.basename,"dirname"),this.path=ur.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?ur.extname(this.path):void 0}set extname(t){if(Yd(t,"extname"),Bg(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=ur.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){$d(t)&&(t=Fk(t)),Wd(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?ur.basename(this.path,this.extname):void 0}set stem(t){Wd(t,"stem"),Yd(t,"stem"),this.path=ur.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 Yt(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 Yd(e,t){if(e&&e.includes(ur.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+ur.sep+"`")}function Wd(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Bg(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function Uk(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Hk=(function(e){const r=this.constructor.prototype,o=r[e],a=function(){return o.apply(a,arguments)};return Object.setPrototypeOf(a,r),a}),zk={}.hasOwnProperty;class qd extends Hk{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=Ck()}copy(){const t=new qd;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?(Qd("data",this.frozen),this.namespace[t]=n,this):zk.call(this.namespace,t)&&this.namespace[t]||void 0:t?(Qd("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=Du(t),r=this.parser||this.Parser;return Gd("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Gd("process",this.parser||this.Parser),Kd("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(a,u){const c=Du(t),d=r.parse(c);r.run(d,c,function(m,E,T){if(m||!E||!T)return h(m);const b=E,_=r.stringify(b,T);Vk(_)?T.value=_:T.result=_,h(m,T)});function h(m,E){m||!E?u(m):a?a(E):n(void 0,E)}}}processSync(t){let n=!1,r;return this.freeze(),Gd("processSync",this.parser||this.Parser),Kd("processSync",this.compiler||this.Compiler),this.process(t,o),Hg("processSync","process",n),r;function o(a,u){n=!0,Dg(a),r=u}}run(t,n,r){Ug(t),this.freeze();const o=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?a(void 0,r):new Promise(a);function a(u,c){const d=Du(n);o.run(t,d,h);function h(m,E,T){const b=E||t;m?c(m):u?u(b):r(void 0,b,T)}}}runSync(t,n){let r=!1,o;return this.run(t,n,a),Hg("runSync","run",r),o;function a(u,c){Dg(u),o=c,r=!0}}stringify(t,n){this.freeze();const r=Du(n),o=this.compiler||this.Compiler;return Kd("stringify",o),Ug(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(Qd("use",this.frozen),t!=null)if(typeof t=="function")d(t,n);else if(typeof t=="object")Array.isArray(t)?c(t):u(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(h){if(typeof h=="function")d(h,[]);else if(typeof h=="object")if(Array.isArray(h)){const[m,...E]=h;d(m,E)}else u(h);else throw new TypeError("Expected usable value, not `"+h+"`")}function u(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];a(E)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function d(h,m){let E=-1,T=-1;for(;++E<r.length;)if(r[E][0]===h){T=E;break}if(T===-1)r.push([h,...m]);else if(m.length>0){let[b,..._]=m;const w=r[T][1];jd(w)&&jd(b)&&(b=zd(!0,w,b)),r[T]=[h,b,..._]}}}}const jk=new qd().freeze();function Gd(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Kd(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Qd(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 Ug(e){if(!jd(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Hg(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Du(e){return $k(e)?e:new Fg(e)}function $k(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Vk(e){return typeof e=="string"||Yk(e)}function Yk(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Wk="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",zg=[],jg={allowDangerousHtml:!0},qk=/^(https?|ircs?|mailto|xmpp)$/i,Gk=[{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 $g(e){const t=Kk(e),n=Qk(e);return Xk(t.runSync(t.parse(n),n),e)}function Kk(e){const t=e.rehypePlugins||zg,n=e.remarkPlugins||zg,r=e.remarkRehypeOptions?U(U({},e.remarkRehypeOptions),jg):jg;return jk().use(OC).use(n).use(Sk,r).use(t)}function Qk(e){const t=e.children||"",n=new Fg;return typeof t=="string"&&(n.value=t),n}function Xk(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,a=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,d=t.urlTransform||Jk;for(const m of Gk)Object.hasOwn(t,m.from)&&(""+m.from+(m.to?"use `"+m.to+"` instead":"remove it")+Wk+m.id,void 0);return Lu(e,h),_A(e,{Fragment:L.Fragment,components:o,ignoreInvalidStyle:!0,jsx:L.jsx,jsxs:L.jsxs,passKeys:!0,passNode:!0});function h(m,E,T){if(m.type==="raw"&&T&&typeof E=="number")return u?T.children.splice(E,1):T.children[E]={type:"text",value:m.value},E;if(m.type==="element"){let b;for(b in vd)if(Object.hasOwn(vd,b)&&Object.hasOwn(m.properties,b)){const _=m.properties[b],w=vd[b];(w===null||w.includes(m.tagName))&&(m.properties[b]=d(String(_||""),b,m))}}if(m.type==="element"){let b=n?!n.includes(m.tagName):a?a.includes(m.tagName):!1;if(!b&&r&&typeof E=="number"&&(b=!r(m,E,T)),b&&T&&typeof E=="number")return c&&m.children?T.children.splice(E,1,...m.children):T.children.splice(E,1),E}}}function Jk(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||qk.test(e.slice(0,t))?e:""}const Vg=/[#.]/g;function Zk(e,t){const n=e||"",r={};let o=0,a,u;for(;o<n.length;){Vg.lastIndex=o;const c=Vg.exec(n),d=n.slice(o,c?c.index:n.length);d&&(a?a==="#"?r.id=d:Array.isArray(r.className)?r.className.push(d):r.className=[d]:u=d,o+=d.length),c&&(a=c[0],o++)}return{type:"element",tagName:u||t||"div",properties:r,children:[]}}function Yg(e,t,n){const r=n?rN(n):void 0;function o(a,u,...c){let d;if(a==null){d={type:"root",children:[]};const h=u;c.unshift(h)}else{d=Zk(a,t);const h=d.tagName.toLowerCase(),m=r?r.get(h):void 0;if(d.tagName=m||h,eN(u))c.unshift(u);else for(const[E,T]of Object.entries(u))tN(e,d.properties,E,T)}for(const h of c)Xd(d.children,h);return d.type==="element"&&d.tagName==="template"&&(d.content={type:"root",children:d.children},d.children=[]),d}return o}function eN(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 a=o;for(const u of a)if(typeof u!="number"&&typeof u!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function tN(e,t,n,r){const o=bd(e,n);let a;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;a=r}else typeof r=="boolean"?a=r:typeof r=="string"?o.spaceSeparated?a=D0(r):o.commaSeparated?a=_0(r):o.commaOrSpaceSeparated?a=D0(_0(r).join(" ")):a=Wg(o,o.property,r):Array.isArray(r)?a=[...r]:a=o.property==="style"?nN(r):String(r);if(Array.isArray(a)){const u=[];for(const c of a)u.push(Wg(o,o.property,c));a=u}o.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[o.property]=a}}function Xd(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)Xd(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?Xd(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function Wg(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||Os(n)===Os(t)))return!0}return n}function nN(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function rN(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const iN=["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"],oN=Yg(_u,"div"),sN=Yg(mo,"g",iN);function aN(e){const t=String(e),n=[];return{toOffset:o,toPoint:r};function r(a){if(typeof a=="number"&&a>-1&&a<=t.length){let u=0;for(;;){let c=n[u];if(c===void 0){const d=qg(t,n[u-1]);c=d===-1?t.length+1:d+1,n[u]=c}if(c>a)return{line:u+1,column:a-(u>0?n[u-1]:0)+1,offset:a};u++}}}function o(a){if(a&&typeof a.line=="number"&&typeof a.column=="number"&&!Number.isNaN(a.line)&&!Number.isNaN(a.column)){for(;n.length<a.line;){const c=n[n.length-1],d=qg(t,c),h=d===-1?t.length+1:d+1;if(c===h)break;n.push(h)}const u=(a.line>1?n[a.line-2]:0)+a.column-1;if(u<n[a.line-1])return u}}}function qg(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
37
+ `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ri={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/"},Gg={}.hasOwnProperty,uN=Object.prototype;function lN(e,t){const n=t||{};return Jd({file:n.file||void 0,location:!1,schema:n.space==="svg"?mo:_u,verbose:n.verbose||!1},e)}function Jd(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Mu(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:Kg(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const a=String(e.file),u=aN(a),c=u.toPoint(0),d=u.toPoint(a.length);n.position={start:c,end:d}}return n}case"#documentType":{const r=t;return n={type:"doctype"},Mu(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Mu(e,r,n),n}default:return n=cN(e,t),n}}function Kg(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=Jd(e,t[n]);r.push(o)}return r}function cN(e,t){const n=e.schema;e.schema=t.namespaceURI===Ri.svg?mo:_u;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],d=(c.prefix?c.prefix+":":"")+c.name;Gg.call(uN,d)||(o[d]=c.value)}const u=(e.schema.space==="svg"?sN:oN)(t.tagName,o,Kg(e,t.childNodes));if(Mu(e,t,u),u.tagName==="template"){const c=t,d=c.sourceCodeLocation,h=d&&d.startTag&&bo(d.startTag),m=d&&d.endTag&&bo(d.endTag),E=Jd(e,c.content);h&&m&&e.file&&(E.position={start:h.end,end:m.start}),u.content=E}return e.schema=n,u}function Mu(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=dN(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function dN(e,t,n){const r=bo(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 a={};let u;if(n.attrs)for(u in n.attrs)Gg.call(n.attrs,u)&&(a[bd(e.schema,u).property]=bo(n.attrs[u]));n.startTag;const c=bo(n.startTag),d=n.endTag?bo(n.endTag):void 0,h={opening:c};d&&(h.closing=d),h.properties=a,t.data={position:h}}}return r}function bo(e){const t=Qg({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=Qg({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function Qg(e){return e.line&&e.column?e:void 0}class zs{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}zs.prototype.property={},zs.prototype.normal={},zs.prototype.space=null;function Xg(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 zs(n,r,t)}function Zd(e){return e.toLowerCase()}class Pn{constructor(t,n){this.property=t,this.attribute=n}}Pn.prototype.space=null,Pn.prototype.boolean=!1,Pn.prototype.booleanish=!1,Pn.prototype.overloadedBoolean=!1,Pn.prototype.number=!1,Pn.prototype.commaSeparated=!1,Pn.prototype.spaceSeparated=!1,Pn.prototype.commaOrSpaceSeparated=!1,Pn.prototype.mustUseProperty=!1,Pn.prototype.defined=!1;let fN=0;const ze=Pi(),vt=Pi(),Jg=Pi(),me=Pi(),st=Pi(),xo=Pi(),_n=Pi();function Pi(){return Ja(2,++fN)}const ef=Object.freeze(Object.defineProperty({__proto__:null,boolean:ze,booleanish:vt,commaOrSpaceSeparated:_n,commaSeparated:xo,number:me,overloadedBoolean:Jg,spaceSeparated:st},Symbol.toStringTag,{value:"Module"})),tf=Object.keys(ef);class nf extends Pn{constructor(t,n,r,o){let a=-1;if(super(t,n),Zg(this,"space",o),typeof r=="number")for(;++a<tf.length;){const u=tf[a];Zg(this,tf[a],(r&ef[u])===ef[u])}}}nf.prototype.defined=!0;function Zg(e,t,n){n&&(e[t]=n)}const hN={}.hasOwnProperty;function _o(e){const t={},n={};let r;for(r in e.properties)if(hN.call(e.properties,r)){const o=e.properties[r],a=new nf(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Zd(r)]=r,n[Zd(a.attribute)]=r}return new zs(t,n,e.space)}const e1=_o({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}}),t1=_o({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function n1(e,t){return t in e?e[t]:t}function r1(e,t){return n1(e,t.toLowerCase())}const i1=_o({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:r1,properties:{xmlns:null,xmlnsXLink:null}}),o1=_o({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:vt,ariaAutoComplete:null,ariaBusy:vt,ariaChecked:vt,ariaColCount:me,ariaColIndex:me,ariaColSpan:me,ariaControls:st,ariaCurrent:null,ariaDescribedBy:st,ariaDetails:null,ariaDisabled:vt,ariaDropEffect:st,ariaErrorMessage:null,ariaExpanded:vt,ariaFlowTo:st,ariaGrabbed:vt,ariaHasPopup:null,ariaHidden:vt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:st,ariaLevel:me,ariaLive:null,ariaModal:vt,ariaMultiLine:vt,ariaMultiSelectable:vt,ariaOrientation:null,ariaOwns:st,ariaPlaceholder:null,ariaPosInSet:me,ariaPressed:vt,ariaReadOnly:vt,ariaRelevant:null,ariaRequired:vt,ariaRoleDescription:st,ariaRowCount:me,ariaRowIndex:me,ariaRowSpan:me,ariaSelected:vt,ariaSetSize:me,ariaSort:null,ariaValueMax:me,ariaValueMin:me,ariaValueNow:me,ariaValueText:null,role:null}}),pN=_o({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:r1,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:xo,acceptCharset:st,accessKey:st,action:null,allow:null,allowFullScreen:ze,allowPaymentRequest:ze,allowUserMedia:ze,alt:null,as:null,async:ze,autoCapitalize:null,autoComplete:st,autoFocus:ze,autoPlay:ze,blocking:st,capture:null,charSet:null,checked:ze,cite:null,className:st,cols:me,colSpan:null,content:null,contentEditable:vt,controls:ze,controlsList:st,coords:me|xo,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ze,defer:ze,dir:null,dirName:null,disabled:ze,download:Jg,draggable:vt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:ze,formTarget:null,headers:st,height:me,hidden:ze,high:me,href:null,hrefLang:null,htmlFor:st,httpEquiv:st,id:null,imageSizes:null,imageSrcSet:null,inert:ze,inputMode:null,integrity:null,is:null,isMap:ze,itemId:null,itemProp:st,itemRef:st,itemScope:ze,itemType:st,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:ze,low:me,manifest:null,max:null,maxLength:me,media:null,method:null,min:null,minLength:me,multiple:ze,muted:ze,name:null,nonce:null,noModule:ze,noValidate:ze,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:ze,optimum:me,pattern:null,ping:st,placeholder:null,playsInline:ze,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:ze,referrerPolicy:null,rel:st,required:ze,reversed:ze,rows:me,rowSpan:me,sandbox:st,scope:null,scoped:ze,seamless:ze,selected:ze,shadowRootClonable:ze,shadowRootDelegatesFocus:ze,shadowRootMode:null,shape:null,size:me,sizes:null,slot:null,span:me,spellCheck:vt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:me,step:null,style:null,tabIndex:me,target:null,title:null,translate:null,type:null,typeMustMatch:ze,useMap:null,value:vt,width:me,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:st,axis:null,background:null,bgColor:null,border:me,borderColor:null,bottomMargin:me,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:ze,declare:ze,event:null,face:null,frame:null,frameBorder:null,hSpace:me,leftMargin:me,link:null,longDesc:null,lowSrc:null,marginHeight:me,marginWidth:me,noResize:ze,noHref:ze,noShade:ze,noWrap:ze,object:null,profile:null,prompt:null,rev:null,rightMargin:me,rules:null,scheme:null,scrolling:vt,standby:null,summary:null,text:null,topMargin:me,valueType:null,version:null,vAlign:null,vLink:null,vSpace:me,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:ze,disableRemotePlayback:ze,prefix:null,property:null,results:me,security:null,unselectable:null}}),mN=_o({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:n1,properties:{about:_n,accentHeight:me,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:me,amplitude:me,arabicForm:null,ascent:me,attributeName:null,attributeType:null,azimuth:me,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:me,by:null,calcMode:null,capHeight:me,className:st,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:me,diffuseConstant:me,direction:null,display:null,dur:null,divisor:me,dominantBaseline:null,download:ze,dx:null,dy:null,edgeMode:null,editable:null,elevation:me,enableBackground:null,end:null,event:null,exponent:me,externalResourcesRequired:null,fill:null,fillOpacity:me,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:xo,g2:xo,glyphName:xo,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:me,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:me,horizOriginX:me,horizOriginY:me,id:null,ideographic:me,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:me,k:me,k1:me,k2:me,k3:me,k4:me,kernelMatrix:_n,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:me,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:me,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:me,overlineThickness:me,paintOrder:null,panose1:null,path:null,pathLength:me,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:st,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:me,pointsAtY:me,pointsAtZ:me,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:_n,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:_n,rev:_n,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:_n,requiredFeatures:_n,requiredFonts:_n,requiredFormats:_n,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:me,specularExponent:me,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:me,strikethroughThickness:me,string:null,stroke:null,strokeDashArray:_n,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:me,strokeOpacity:me,strokeWidth:null,style:null,surfaceScale:me,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:_n,tabIndex:me,tableValues:null,target:null,targetX:me,targetY:me,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:_n,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:me,underlineThickness:me,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:me,values:null,vAlphabetic:me,vMathematical:me,vectorEffect:null,vHanging:me,vIdeographic:me,version:null,vertAdvY:me,vertOriginX:me,vertOriginY:me,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:me,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),gN=/^data[-\w.:]+$/i,s1=/-[a-z]/g,EN=/[A-Z]/g;function yN(e,t){const n=Zd(t);let r=t,o=Pn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&gN.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(s1,bN);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!s1.test(a)){let u=a.replace(EN,TN);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=nf}return new o(r,t)}function TN(e){return"-"+e.toLowerCase()}function bN(e){return e.charAt(1).toUpperCase()}const xN=Xg([t1,e1,i1,o1,pN],"html"),a1=Xg([t1,e1,i1,o1,mN],"svg"),u1={}.hasOwnProperty;function l1(e,t){const n=t||{};function r(o,...a){let u=r.invalid;const c=r.handlers;if(o&&u1.call(o,e)){const d=String(o[e]);u=u1.call(c,d)?c[d]:r.unknown}if(u)return u.call(this,o,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const _N={},wN={}.hasOwnProperty,c1=l1("type",{handlers:{root:AN,element:ON,text:kN,comment:NN,doctype:CN}});function SN(e,t){const r=(t||_N).space;return c1(e,r==="svg"?a1:xN)}function AN(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=rf(e.children,n,t),wo(e,n),n}function vN(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=rf(e.children,n,t),wo(e,n),n}function CN(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return wo(e,t),t}function kN(e){const t={nodeName:"#text",value:e.value,parentNode:null};return wo(e,t),t}function NN(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return wo(e,t),t}function ON(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=a1);const o=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&wN.call(e.properties,a)){const d=IN(r,a,e.properties[a]);d&&o.push(d)}}const u=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Ri[u],childNodes:[],parentNode:null};return c.childNodes=rf(e.children,c,r),wo(e,c),e.tagName==="template"&&e.content&&(c.content=vN(e.content,r)),c}function IN(e,t,n){const r=yN(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?w0(n):M0(n));const o={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=o.name.indexOf(":");a<0?o.prefix="":(o.name=o.name.slice(a+1),o.prefix=r.attribute.slice(0,a)),o.namespace=Ri[r.space]}return o}function rf(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const a=c1(e[r],n);a.parentNode=t,o.push(a)}return o}function wo(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 RN=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],PN=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]),ft="�";var v;(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"})(v||(v={}));const fn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function d1(e){return e>=55296&&e<=57343}function LN(e){return e>=56320&&e<=57343}function DN(e,t){return(e-55296)*1024+9216+t}function f1(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function h1(e){return e>=64976&&e<=65007||PN.has(e)}var Q;(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"})(Q||(Q={}));const MN=65536;class FN{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=MN,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:a}=this,u=o+n,c=a+n;return{code:t,startLine:r,endLine:r,startCol:u,endCol:u,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(LN(n))return this.pos++,this._addGap(),DN(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,v.EOF;return this._err(Q.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,v.EOF;const r=this.html.charCodeAt(n);return r===v.CARRIAGE_RETURN?v.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,v.EOF;let t=this.html.charCodeAt(this.pos);return t===v.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,v.LINE_FEED):t===v.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,d1(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===v.LINE_FEED||t===v.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){f1(t)?this._err(Q.controlCharacterInInputStream):h1(t)&&this._err(Q.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var $e;(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"})($e||($e={}));function p1(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 BN=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))),UN=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 HN(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=UN.get(e))!==null&&t!==void 0?t:e}var Pt;(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"})(Pt||(Pt={}));const zN=32;var Yr;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Yr||(Yr={}));function of(e){return e>=Pt.ZERO&&e<=Pt.NINE}function jN(e){return e>=Pt.UPPER_A&&e<=Pt.UPPER_F||e>=Pt.LOWER_A&&e<=Pt.LOWER_F}function $N(e){return e>=Pt.UPPER_A&&e<=Pt.UPPER_Z||e>=Pt.LOWER_A&&e<=Pt.LOWER_Z||of(e)}function VN(e){return e===Pt.EQUALS||$N(e)}var Lt;(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"})(Lt||(Lt={}));var Ar;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Ar||(Ar={}));class YN{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Lt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Ar.Strict}startEntity(t){this.decodeMode=t,this.state=Lt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Lt.EntityStart:return t.charCodeAt(n)===Pt.NUM?(this.state=Lt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Lt.NamedEntity,this.stateNamedEntity(t,n));case Lt.NumericStart:return this.stateNumericStart(t,n);case Lt.NumericDecimal:return this.stateNumericDecimal(t,n);case Lt.NumericHex:return this.stateNumericHex(t,n);case Lt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|zN)===Pt.LOWER_X?(this.state=Lt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Lt.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,o){if(n!==r){const a=r-n;this.result=this.result*Math.pow(o,a)+Number.parseInt(t.substr(n,a),o),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const o=t.charCodeAt(n);if(of(o)||jN(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(of(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===Pt.SEMI)this.consumed+=1;else if(this.decodeMode===Ar.Strict)return 0;return this.emitCodePoint(HN(this.result),this.consumed),this.errors&&(t!==Pt.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const u=t.charCodeAt(n);if(this.treeIndex=WN(r,o,this.treeIndex+Math.max(1,a),u),this.treeIndex<0)return this.result===0||this.decodeMode===Ar.Attribute&&(a===0||VN(u))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14,a!==0){if(u===Pt.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==Ar.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]&Yr.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]&~Yr.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Lt.NamedEntity:return this.result!==0&&(this.decodeMode!==Ar.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Lt.NumericDecimal:return this.emitNumericEntity(0,2);case Lt.NumericHex:return this.emitNumericEntity(0,3);case Lt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Lt.EntityStart:return 0}}}function WN(e,t,n,r){const o=(t&Yr.BRANCH_LENGTH)>>7,a=t&Yr.JUMP_TABLE;if(o===0)return a!==0&&r===a?n:-1;if(a){const d=r-a;return d<0||d>=o?-1:e[n+d]-1}let u=n,c=u+o-1;for(;u<=c;){const d=u+c>>>1,h=e[d];if(h<r)u=d+1;else if(h>r)c=d-1;else return e[d+o]}return-1}var ie;(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/"})(ie||(ie={}));var Li;(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"})(Li||(Li={}));var Ln;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Ln||(Ln={}));var Y;(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"})(Y||(Y={}));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 qN=new Map([[Y.A,p.A],[Y.ADDRESS,p.ADDRESS],[Y.ANNOTATION_XML,p.ANNOTATION_XML],[Y.APPLET,p.APPLET],[Y.AREA,p.AREA],[Y.ARTICLE,p.ARTICLE],[Y.ASIDE,p.ASIDE],[Y.B,p.B],[Y.BASE,p.BASE],[Y.BASEFONT,p.BASEFONT],[Y.BGSOUND,p.BGSOUND],[Y.BIG,p.BIG],[Y.BLOCKQUOTE,p.BLOCKQUOTE],[Y.BODY,p.BODY],[Y.BR,p.BR],[Y.BUTTON,p.BUTTON],[Y.CAPTION,p.CAPTION],[Y.CENTER,p.CENTER],[Y.CODE,p.CODE],[Y.COL,p.COL],[Y.COLGROUP,p.COLGROUP],[Y.DD,p.DD],[Y.DESC,p.DESC],[Y.DETAILS,p.DETAILS],[Y.DIALOG,p.DIALOG],[Y.DIR,p.DIR],[Y.DIV,p.DIV],[Y.DL,p.DL],[Y.DT,p.DT],[Y.EM,p.EM],[Y.EMBED,p.EMBED],[Y.FIELDSET,p.FIELDSET],[Y.FIGCAPTION,p.FIGCAPTION],[Y.FIGURE,p.FIGURE],[Y.FONT,p.FONT],[Y.FOOTER,p.FOOTER],[Y.FOREIGN_OBJECT,p.FOREIGN_OBJECT],[Y.FORM,p.FORM],[Y.FRAME,p.FRAME],[Y.FRAMESET,p.FRAMESET],[Y.H1,p.H1],[Y.H2,p.H2],[Y.H3,p.H3],[Y.H4,p.H4],[Y.H5,p.H5],[Y.H6,p.H6],[Y.HEAD,p.HEAD],[Y.HEADER,p.HEADER],[Y.HGROUP,p.HGROUP],[Y.HR,p.HR],[Y.HTML,p.HTML],[Y.I,p.I],[Y.IMG,p.IMG],[Y.IMAGE,p.IMAGE],[Y.INPUT,p.INPUT],[Y.IFRAME,p.IFRAME],[Y.KEYGEN,p.KEYGEN],[Y.LABEL,p.LABEL],[Y.LI,p.LI],[Y.LINK,p.LINK],[Y.LISTING,p.LISTING],[Y.MAIN,p.MAIN],[Y.MALIGNMARK,p.MALIGNMARK],[Y.MARQUEE,p.MARQUEE],[Y.MATH,p.MATH],[Y.MENU,p.MENU],[Y.META,p.META],[Y.MGLYPH,p.MGLYPH],[Y.MI,p.MI],[Y.MO,p.MO],[Y.MN,p.MN],[Y.MS,p.MS],[Y.MTEXT,p.MTEXT],[Y.NAV,p.NAV],[Y.NOBR,p.NOBR],[Y.NOFRAMES,p.NOFRAMES],[Y.NOEMBED,p.NOEMBED],[Y.NOSCRIPT,p.NOSCRIPT],[Y.OBJECT,p.OBJECT],[Y.OL,p.OL],[Y.OPTGROUP,p.OPTGROUP],[Y.OPTION,p.OPTION],[Y.P,p.P],[Y.PARAM,p.PARAM],[Y.PLAINTEXT,p.PLAINTEXT],[Y.PRE,p.PRE],[Y.RB,p.RB],[Y.RP,p.RP],[Y.RT,p.RT],[Y.RTC,p.RTC],[Y.RUBY,p.RUBY],[Y.S,p.S],[Y.SCRIPT,p.SCRIPT],[Y.SEARCH,p.SEARCH],[Y.SECTION,p.SECTION],[Y.SELECT,p.SELECT],[Y.SOURCE,p.SOURCE],[Y.SMALL,p.SMALL],[Y.SPAN,p.SPAN],[Y.STRIKE,p.STRIKE],[Y.STRONG,p.STRONG],[Y.STYLE,p.STYLE],[Y.SUB,p.SUB],[Y.SUMMARY,p.SUMMARY],[Y.SUP,p.SUP],[Y.TABLE,p.TABLE],[Y.TBODY,p.TBODY],[Y.TEMPLATE,p.TEMPLATE],[Y.TEXTAREA,p.TEXTAREA],[Y.TFOOT,p.TFOOT],[Y.TD,p.TD],[Y.TH,p.TH],[Y.THEAD,p.THEAD],[Y.TITLE,p.TITLE],[Y.TR,p.TR],[Y.TRACK,p.TRACK],[Y.TT,p.TT],[Y.U,p.U],[Y.UL,p.UL],[Y.SVG,p.SVG],[Y.VAR,p.VAR],[Y.WBR,p.WBR],[Y.XMP,p.XMP]]);function So(e){var t;return(t=qN.get(e))!==null&&t!==void 0?t:p.UNKNOWN}const le=p,GN={[ie.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]),[ie.MATHML]:new Set([le.MI,le.MO,le.MN,le.MS,le.MTEXT,le.ANNOTATION_XML]),[ie.SVG]:new Set([le.TITLE,le.FOREIGN_OBJECT,le.DESC]),[ie.XLINK]:new Set,[ie.XML]:new Set,[ie.XMLNS]:new Set},sf=new Set([le.H1,le.H2,le.H3,le.H4,le.H5,le.H6]);Y.STYLE,Y.SCRIPT,Y.XMP,Y.IFRAME,Y.NOEMBED,Y.NOFRAMES,Y.PLAINTEXT;var N;(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"})(N||(N={}));const xt={DATA:N.DATA,RCDATA:N.RCDATA,RAWTEXT:N.RAWTEXT,SCRIPT_DATA:N.SCRIPT_DATA,PLAINTEXT:N.PLAINTEXT,CDATA_SECTION:N.CDATA_SECTION};function KN(e){return e>=v.DIGIT_0&&e<=v.DIGIT_9}function js(e){return e>=v.LATIN_CAPITAL_A&&e<=v.LATIN_CAPITAL_Z}function QN(e){return e>=v.LATIN_SMALL_A&&e<=v.LATIN_SMALL_Z}function Wr(e){return QN(e)||js(e)}function m1(e){return Wr(e)||KN(e)}function Fu(e){return e+32}function g1(e){return e===v.SPACE||e===v.LINE_FEED||e===v.TABULATION||e===v.FORM_FEED}function E1(e){return g1(e)||e===v.SOLIDUS||e===v.GREATER_THAN_SIGN}function XN(e){return e===v.NULL?Q.nullCharacterReference:e>1114111?Q.characterReferenceOutsideUnicodeRange:d1(e)?Q.surrogateCharacterReference:h1(e)?Q.noncharacterCharacterReference:f1(e)||e===v.CARRIAGE_RETURN?Q.controlCharacterReference:null}class JN{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=N.DATA,this.returnState=N.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new FN(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new YN(BN,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(Q.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(Q.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=XN(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:$e.START_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:$e.END_TAG,tagName:"",tagID:p.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:$e.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:$e.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(p1(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(Q.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=So(t.tagName),t.type===$e.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(Q.endTagWithAttributes),t.selfClosing&&this._err(Q.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 $e.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case $e.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case $e.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:$e.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=g1(t)?$e.WHITESPACE_CHARACTER:t===v.NULL?$e.NULL_CHARACTER:$e.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken($e.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=N.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Ar.Attribute:Ar.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===N.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case N.DATA:{this._stateData(t);break}case N.RCDATA:{this._stateRcdata(t);break}case N.RAWTEXT:{this._stateRawtext(t);break}case N.SCRIPT_DATA:{this._stateScriptData(t);break}case N.PLAINTEXT:{this._statePlaintext(t);break}case N.TAG_OPEN:{this._stateTagOpen(t);break}case N.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case N.TAG_NAME:{this._stateTagName(t);break}case N.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case N.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case N.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case N.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case N.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case N.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case N.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case N.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case N.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case N.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case N.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case N.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case N.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case N.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case N.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case N.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case N.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case N.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case N.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case N.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case N.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case N.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case N.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case N.BOGUS_COMMENT:{this._stateBogusComment(t);break}case N.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case N.COMMENT_START:{this._stateCommentStart(t);break}case N.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case N.COMMENT:{this._stateComment(t);break}case N.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case N.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case N.COMMENT_END:{this._stateCommentEnd(t);break}case N.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case N.DOCTYPE:{this._stateDoctype(t);break}case N.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case N.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case N.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case N.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case N.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case N.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case N.CDATA_SECTION:{this._stateCdataSection(t);break}case N.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case N.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case N.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case N.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case v.LESS_THAN_SIGN:{this.state=N.TAG_OPEN;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitCodePoint(t);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case v.AMPERSAND:{this._startCharacterReference();break}case v.LESS_THAN_SIGN:{this.state=N.RCDATA_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case v.LESS_THAN_SIGN:{this.state=N.RAWTEXT_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Wr(t))this._createStartTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case v.EXCLAMATION_MARK:{this.state=N.MARKUP_DECLARATION_OPEN;break}case v.SOLIDUS:{this.state=N.END_TAG_OPEN;break}case v.QUESTION_MARK:{this._err(Q.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t);break}case v.EOF:{this._err(Q.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(Q.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=N.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Wr(t))this._createEndTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case v.GREATER_THAN_SIGN:{this._err(Q.missingEndTagName),this.state=N.DATA;break}case v.EOF:{this._err(Q.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(Q.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_ATTRIBUTE_NAME;break}case v.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.tagName+=ft;break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(js(t)?Fu(t):t)}}_stateRcdataLessThanSign(t){t===v.SOLIDUS?this.state=N.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Wr(t)?(this.state=N.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=N.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 v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=N.BEFORE_ATTRIBUTE_NAME,!1;case v.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=N.SELF_CLOSING_START_TAG,!1;case v.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=N.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===v.SOLIDUS?this.state=N.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Wr(t)?(this.state=N.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case v.SOLIDUS:{this.state=N.SCRIPT_DATA_END_TAG_OPEN;break}case v.EXCLAMATION_MARK:{this.state=N.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=N.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===v.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===v.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case v.HYPHEN_MINUS:{this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case v.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===v.SOLIDUS?this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Wr(t)?(this._emitChars("<"),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&E1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case v.HYPHEN_MINUS:{this._emitChars("-");break}case v.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case v.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case v.EOF:{this._err(Q.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===v.SOLIDUS?(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&E1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.SOLIDUS:case v.GREATER_THAN_SIGN:case v.EOF:{this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case v.EQUALS_SIGN:{this._err(Q.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=N.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:case v.SOLIDUS:case v.GREATER_THAN_SIGN:case v.EOF:{this._leaveAttrName(),this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case v.EQUALS_SIGN:{this._leaveAttrName(),this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case v.QUOTATION_MARK:case v.APOSTROPHE:case v.LESS_THAN_SIGN:{this._err(Q.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.name+=ft;break}default:this.currentAttr.name+=String.fromCodePoint(js(t)?Fu(t):t)}}_stateAfterAttributeName(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case v.EQUALS_SIGN:{this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.QUOTATION_MARK:{this.state=N.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this.state=N.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingAttributeValue),this.state=N.DATA,this.emitCurrentTagToken();break}default:this.state=N.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case v.QUOTATION_MARK:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case v.APOSTROPHE:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case v.AMPERSAND:{this._startCharacterReference();break}case v.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case v.QUOTATION_MARK:case v.APOSTROPHE:case v.LESS_THAN_SIGN:case v.EQUALS_SIGN:case v.GRAVE_ACCENT:{this._err(Q.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case v.SOLIDUS:{this._leaveAttrValue(),this.state=N.SELF_CLOSING_START_TAG;break}case v.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this._err(Q.missingWhitespaceBetweenAttributes),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case v.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=N.DATA,this.emitCurrentTagToken();break}case v.EOF:{this._err(Q.eofInTag),this._emitEOFToken();break}default:this._err(Q.unexpectedSolidusInTag),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case v.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.data+=ft;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(fn.DASH_DASH,!0)?(this._createCommentToken(fn.DASH_DASH.length+1),this.state=N.COMMENT_START):this._consumeSequenceIfMatch(fn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(fn.DOCTYPE.length+1),this.state=N.DOCTYPE):this._consumeSequenceIfMatch(fn.CDATA_START,!0)?this.inForeignNode?this.state=N.CDATA_SECTION:(this._err(Q.cdataInHtmlContent),this._createCommentToken(fn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=N.BOGUS_COMMENT):this._ensureHibernation()||(this._err(Q.incorrectlyOpenedComment),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_START_DASH;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptClosingOfEmptyComment),this.state=N.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptClosingOfEmptyComment),this.state=N.DATA,this.emitCurrentComment(n);break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_END_DASH;break}case v.LESS_THAN_SIGN:{n.data+="<",this.state=N.COMMENT_LESS_THAN_SIGN;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.data+=ft;break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case v.EXCLAMATION_MARK:{n.data+="!",this.state=N.COMMENT_LESS_THAN_SIGN_BANG;break}case v.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===v.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=N.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===v.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=N.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==v.GREATER_THAN_SIGN&&t!==v.EOF&&this._err(Q.nestedComment),this.state=N.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case v.EXCLAMATION_MARK:{this.state=N.COMMENT_END_BANG;break}case v.HYPHEN_MINUS:{n.data+="-";break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case v.HYPHEN_MINUS:{n.data+="--!",this.state=N.COMMENT_END_DASH;break}case v.GREATER_THAN_SIGN:{this._err(Q.incorrectlyClosedComment),this.state=N.DATA,this.emitCurrentComment(n);break}case v.EOF:{this._err(Q.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=N.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_NAME;break}case v.GREATER_THAN_SIGN:{this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case v.EOF:{this._err(Q.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingWhitespaceBeforeDoctypeName),this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(js(t))this._createDoctypeToken(String.fromCharCode(Fu(t))),this.state=N.DOCTYPE_NAME;else switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.NULL:{this._err(Q.unexpectedNullCharacter),this._createDoctypeToken(ft),this.state=N.DOCTYPE_NAME;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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=N.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.AFTER_DOCTYPE_NAME;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.name+=ft;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(js(t)?Fu(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(fn.PUBLIC,!1)?this.state=N.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(fn.SYSTEM,!1)?this.state=N.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(Q.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case v.QUOTATION_MARK:{this._err(Q.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this._err(Q.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.QUOTATION_MARK:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case v.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.publicId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.publicId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case v.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.QUOTATION_MARK:{this._err(Q.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this._err(Q.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case v.QUOTATION_MARK:{this._err(Q.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{this._err(Q.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case v.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case v.GREATER_THAN_SIGN:{this._err(Q.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case v.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.systemId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case v.NULL:{this._err(Q.unexpectedNullCharacter),n.systemId+=ft;break}case v.GREATER_THAN_SIGN:{this._err(Q.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.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 v.SPACE:case v.LINE_FEED:case v.TABULATION:case v.FORM_FEED:break;case v.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.EOF:{this._err(Q.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(Q.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case v.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case v.NULL:{this._err(Q.unexpectedNullCharacter);break}case v.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case v.RIGHT_SQUARE_BRACKET:{this.state=N.CDATA_SECTION_BRACKET;break}case v.EOF:{this._err(Q.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===v.RIGHT_SQUARE_BRACKET?this.state=N.CDATA_SECTION_END:(this._emitChars("]"),this.state=N.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case v.GREATER_THAN_SIGN:{this.state=N.DATA;break}case v.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=N.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(v.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&m1(this.preprocessor.peek(1))?N.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){m1(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===v.SEMICOLON&&this._err(Q.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const y1=new Set([p.DD,p.DT,p.LI,p.OPTGROUP,p.OPTION,p.P,p.RB,p.RP,p.RT,p.RTC]),T1=new Set([...y1,p.CAPTION,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]),Bu=new Set([p.APPLET,p.CAPTION,p.HTML,p.MARQUEE,p.OBJECT,p.TABLE,p.TD,p.TEMPLATE,p.TH]),ZN=new Set([...Bu,p.OL,p.UL]),e3=new Set([...Bu,p.BUTTON]),b1=new Set([p.ANNOTATION_XML,p.MI,p.MN,p.MO,p.MS,p.MTEXT]),x1=new Set([p.DESC,p.FOREIGN_OBJECT,p.TITLE]),t3=new Set([p.TR,p.TEMPLATE,p.HTML]),n3=new Set([p.TBODY,p.TFOOT,p.THEAD,p.TEMPLATE,p.HTML]),r3=new Set([p.TABLE,p.TEMPLATE,p.HTML]),i3=new Set([p.TD,p.TH]);class o3{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)===ie.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])!==ie.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(sf,ie.HTML)}popUntilTableCellPopped(){this.popUntilPopped(i3,ie.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(r3,ie.HTML)}clearBackToTableBodyContext(){this.clearBackTo(n3,ie.HTML)}clearBackToTableRowContext(){this.clearBackTo(t3,ie.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 ie.HTML:{if(o===t)return!0;if(n.has(o))return!1;break}case ie.SVG:{if(x1.has(o))return!1;break}case ie.MATHML:{if(b1.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Bu)}hasInListItemScope(t){return this.hasInDynamicScope(t,ZN)}hasInButtonScope(t){return this.hasInDynamicScope(t,e3)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case ie.HTML:{if(sf.has(n))return!0;if(Bu.has(n))return!1;break}case ie.SVG:{if(x1.has(n))return!1;break}case ie.MATHML:{if(b1.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===ie.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])===ie.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])===ie.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&&y1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&T1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&T1.has(this.currentTagId);)this.pop()}}const af=3;var lr;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(lr||(lr={}));const _1={type:lr.Marker};class s3{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],o=n.length,a=this.treeAdapter.getTagName(t),u=this.treeAdapter.getNamespaceURI(t);for(let c=0;c<this.entries.length;c++){const d=this.entries[c];if(d.type===lr.Marker)break;const{element:h}=d;if(this.treeAdapter.getTagName(h)===a&&this.treeAdapter.getNamespaceURI(h)===u){const m=this.treeAdapter.getAttrList(h);m.length===o&&r.push({idx:c,attrs:m})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<af)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<af)return;const o=new Map(n.map(u=>[u.name,u.value]));let a=0;for(let u=0;u<r.length;u++){const c=r[u];c.attrs.every(d=>o.get(d.name)===d.value)&&(a+=1,a>=af&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(_1)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:lr.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:lr.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(_1);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===lr.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===lr.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===lr.Element&&n.element===t)}}const qr={createDocument(){return{nodeName:"#document",mode:Ln.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(a=>a.nodeName==="#documentType");if(o)o.name=t,o.publicId=n,o.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};qr.appendChild(e,a)}},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(qr.isTextNode(n)){n.value+=t;return}}qr.appendChild(e,qr.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&qr.isTextNode(r)?r.value+=t:qr.insertBefore(e,qr.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)}},w1="html",a3="about:legacy-compat",u3="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",S1=["+//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//"],l3=[...S1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],c3=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),A1=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],d3=[...A1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function v1(e,t){return t.some(n=>e.startsWith(n))}function f3(e){return e.name===w1&&e.publicId===null&&(e.systemId===null||e.systemId===a3)}function h3(e){if(e.name!==w1)return Ln.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===u3)return Ln.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),c3.has(n))return Ln.QUIRKS;let r=t===null?l3:S1;if(v1(n,r))return Ln.QUIRKS;if(r=t===null?A1:d3,v1(n,r))return Ln.LIMITED_QUIRKS}return Ln.NO_QUIRKS}const C1={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},p3="definitionurl",m3="definitionURL",g3=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])),E3=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:ie.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:ie.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:ie.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:ie.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:ie.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:ie.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:ie.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:ie.XML}],["xml:space",{prefix:"xml",name:"space",namespace:ie.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:ie.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:ie.XMLNS}]]),y3=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])),T3=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 b3(e){const t=e.tagID;return t===p.FONT&&e.attrs.some(({name:r})=>r===Li.COLOR||r===Li.SIZE||r===Li.FACE)||T3.has(t)}function k1(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===p3){e.attrs[t].name=m3;break}}function N1(e){for(let t=0;t<e.attrs.length;t++){const n=g3.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function uf(e){for(let t=0;t<e.attrs.length;t++){const n=E3.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 x3(e){const t=y3.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=So(e.tagName))}function _3(e,t){return t===ie.MATHML&&(e===p.MI||e===p.MO||e===p.MN||e===p.MS||e===p.MTEXT)}function w3(e,t,n){if(t===ie.MATHML&&e===p.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Li.ENCODING){const o=n[r].value.toLowerCase();return o===C1.TEXT_HTML||o===C1.APPLICATION_XML}}return t===ie.SVG&&(e===p.FOREIGN_OBJECT||e===p.DESC||e===p.TITLE)}function S3(e,t,n,r){return(!r||r===ie.HTML)&&w3(e,t,n)||(!r||r===ie.MATHML)&&_3(e,t)}const A3="hidden",v3=8,C3=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 k3={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},O1=new Set([p.TABLE,p.TBODY,p.TFOOT,p.THEAD,p.TR]),I1={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:qr,onParseError:null};class R1{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({},I1),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 JN(this.options,this),this.activeFormattingElements=new s3(this.treeAdapter),this.fragmentContextID=r?So(this.treeAdapter.getTagName(r)):p.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new o3(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({},I1),n);t!=null||(t=r.treeAdapter.createElement(Y.TEMPLATE,ie.HTML,[]));const o=r.treeAdapter.createElement("documentmock",ie.HTML,[]),a=new this(r,o,t);return a.fragmentContextID===p.TEMPLATE&&a.tmplInsertionModeStack.unshift(P.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}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 a=(o=t.location)!==null&&o!==void 0?o:k3,u={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(u)}onItemPush(t,n,r){var o,a;(a=(o=this.treeAdapter).onItemPush)===null||a===void 0||a.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 a,u;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,u=this.fragmentContextID):{current:a,currentTagId:u}=this.openElements,this._setContextModes(a,u)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===ie.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,ie.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=xt.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)===Y.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==ie.HTML))switch(this.fragmentContextID){case p.TITLE:case p.TEXTAREA:{this.tokenizer.state=xt.RCDATA;break}case p.STYLE:case p.XMP:case p.IFRAME:case p.NOEMBED:case p.NOFRAMES:case p.NOSCRIPT:{this.tokenizer.state=xt.RAWTEXT;break}case p.SCRIPT:{this.tokenizer.state=xt.SCRIPT_DATA;break}case p.PLAINTEXT:{this.tokenizer.state=xt.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 u=this.treeAdapter.getChildNodes(this.document).find(c=>this.treeAdapter.isDocumentTypeNode(c));u&&this.treeAdapter.setNodeSourceCodeLocation(u,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&ne(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,ie.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,ie.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(Y.HTML,ie.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),a=r?o.lastIndexOf(r):o.length,u=o[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(u)){const{endLine:d,endCol:h,endOffset:m}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(u,{endLine:d,endCol:h,endOffset:m})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(u,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),a=n.type===$e.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,a)}}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)===Y.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===ie.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===p.MGLYPH||t.tagID===p.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,ie.HTML)}_processToken(t){switch(t.type){case $e.CHARACTER:{this.onCharacter(t);break}case $e.NULL_CHARACTER:{this.onNullCharacter(t);break}case $e.COMMENT:{this.onComment(t);break}case $e.DOCTYPE:{this.onDoctype(t);break}case $e.START_TAG:{this._processStartTag(t);break}case $e.END_TAG:{this.onEndTag(t);break}case $e.EOF:{this.onEof(t);break}case $e.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const o=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return S3(t,o,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===lr.Marker||this.openElements.contains(o.element)),r=n===-1?t-1:n-1;for(let o=r;o>=0;o--){const a=this.activeFormattingElements.entries[o];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.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 O1.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)===ie.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 GN[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){iI(this,t);return}switch(this.insertionMode){case P.INITIAL:{$s(this,t);break}case P.BEFORE_HTML:{Vs(this,t);break}case P.BEFORE_HEAD:{Ys(this,t);break}case P.IN_HEAD:{Ws(this,t);break}case P.IN_HEAD_NO_SCRIPT:{qs(this,t);break}case P.AFTER_HEAD:{Gs(this,t);break}case P.IN_BODY:case P.IN_CAPTION:case P.IN_CELL:case P.IN_TEMPLATE:{L1(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:{ff(this,t);break}case P.IN_TABLE_TEXT:{j1(this,t);break}case P.IN_COLUMN_GROUP:{zu(this,t);break}case P.AFTER_BODY:{Vu(this,t);break}case P.AFTER_AFTER_BODY:{Yu(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){rI(this,t);return}switch(this.insertionMode){case P.INITIAL:{$s(this,t);break}case P.BEFORE_HTML:{Vs(this,t);break}case P.BEFORE_HEAD:{Ys(this,t);break}case P.IN_HEAD:{Ws(this,t);break}case P.IN_HEAD_NO_SCRIPT:{qs(this,t);break}case P.AFTER_HEAD:{Gs(this,t);break}case P.TEXT:{this._insertCharacters(t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{ff(this,t);break}case P.IN_COLUMN_GROUP:{zu(this,t);break}case P.AFTER_BODY:{Vu(this,t);break}case P.AFTER_AFTER_BODY:{Yu(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){cf(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:{cf(this,t);break}case P.IN_TABLE_TEXT:{Xs(this,t);break}case P.AFTER_BODY:{D3(this,t);break}case P.AFTER_AFTER_BODY:case P.AFTER_AFTER_FRAMESET:{M3(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case P.INITIAL:{F3(this,t);break}case P.BEFORE_HEAD:case P.IN_HEAD:case P.IN_HEAD_NO_SCRIPT:case P.AFTER_HEAD:{this._err(t,Q.misplacedDoctype);break}case P.IN_TABLE_TEXT:{Xs(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,Q.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?oI(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case P.INITIAL:{$s(this,t);break}case P.BEFORE_HTML:{B3(this,t);break}case P.BEFORE_HEAD:{H3(this,t);break}case P.IN_HEAD:{qn(this,t);break}case P.IN_HEAD_NO_SCRIPT:{$3(this,t);break}case P.AFTER_HEAD:{Y3(this,t);break}case P.IN_BODY:{qt(this,t);break}case P.IN_TABLE:{Ao(this,t);break}case P.IN_TABLE_TEXT:{Xs(this,t);break}case P.IN_CAPTION:{zO(this,t);break}case P.IN_COLUMN_GROUP:{hf(this,t);break}case P.IN_TABLE_BODY:{ju(this,t);break}case P.IN_ROW:{$u(this,t);break}case P.IN_CELL:{VO(this,t);break}case P.IN_SELECT:{Y1(this,t);break}case P.IN_SELECT_IN_TABLE:{WO(this,t);break}case P.IN_TEMPLATE:{GO(this,t);break}case P.AFTER_BODY:{QO(this,t);break}case P.IN_FRAMESET:{XO(this,t);break}case P.AFTER_FRAMESET:{ZO(this,t);break}case P.AFTER_AFTER_BODY:{tI(this,t);break}case P.AFTER_AFTER_FRAMESET:{nI(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?sI(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case P.INITIAL:{$s(this,t);break}case P.BEFORE_HTML:{U3(this,t);break}case P.BEFORE_HEAD:{z3(this,t);break}case P.IN_HEAD:{j3(this,t);break}case P.IN_HEAD_NO_SCRIPT:{V3(this,t);break}case P.AFTER_HEAD:{W3(this,t);break}case P.IN_BODY:{Hu(this,t);break}case P.TEXT:{IO(this,t);break}case P.IN_TABLE:{Ks(this,t);break}case P.IN_TABLE_TEXT:{Xs(this,t);break}case P.IN_CAPTION:{jO(this,t);break}case P.IN_COLUMN_GROUP:{$O(this,t);break}case P.IN_TABLE_BODY:{pf(this,t);break}case P.IN_ROW:{V1(this,t);break}case P.IN_CELL:{YO(this,t);break}case P.IN_SELECT:{W1(this,t);break}case P.IN_SELECT_IN_TABLE:{qO(this,t);break}case P.IN_TEMPLATE:{KO(this,t);break}case P.AFTER_BODY:{G1(this,t);break}case P.IN_FRAMESET:{JO(this,t);break}case P.AFTER_FRAMESET:{eI(this,t);break}case P.AFTER_AFTER_BODY:{Yu(this,t);break}}}onEof(t){switch(this.insertionMode){case P.INITIAL:{$s(this,t);break}case P.BEFORE_HTML:{Vs(this,t);break}case P.BEFORE_HEAD:{Ys(this,t);break}case P.IN_HEAD:{Ws(this,t);break}case P.IN_HEAD_NO_SCRIPT:{qs(this,t);break}case P.AFTER_HEAD:{Gs(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:{H1(this,t);break}case P.TEXT:{RO(this,t);break}case P.IN_TABLE_TEXT:{Xs(this,t);break}case P.IN_TEMPLATE:{q1(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:{df(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===v.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:{P1(this,t);break}case P.IN_TABLE:case P.IN_TABLE_BODY:case P.IN_ROW:{ff(this,t);break}case P.IN_TABLE_TEXT:{z1(this,t);break}}}}function N3(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):U1(e,t),n}function O3(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 I3(e,t,n){let r=t,o=e.openElements.getCommonAncestor(t);for(let a=0,u=o;u!==n;a++,u=o){o=e.openElements.getCommonAncestor(u);const c=e.activeFormattingElements.getElementEntry(u),d=c&&a>=C3;!c||d?(d&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(u)):(u=R3(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(u,r),r=u)}return r}function R3(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 P3(e,t,n){const r=e.treeAdapter.getTagName(t),o=So(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);o===p.TEMPLATE&&a===ie.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function L3(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:o}=n,a=e.treeAdapter.createElement(o.tagName,r,o.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,o),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,o.tagID)}function lf(e,t){for(let n=0;n<v3;n++){const r=N3(e,t);if(!r)break;const o=O3(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const a=I3(e,o,r.element),u=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),u&&P3(e,u,a),L3(e,o,r)}}function cf(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function D3(e,t){e._appendCommentNode(t,e.openElements.items[0])}function M3(e,t){e._appendCommentNode(t,e.document)}function df(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 a=e.openElements.items[1],u=e.treeAdapter.getNodeSourceCodeLocation(a);u&&!u.endTag&&e._setEndLocation(a,t)}}}}function F3(e,t){e._setDocumentType(t);const n=t.forceQuirks?Ln.QUIRKS:h3(t);f3(t)||e._err(t,Q.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=P.BEFORE_HTML}function $s(e,t){e._err(t,Q.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Ln.QUIRKS),e.insertionMode=P.BEFORE_HTML,e._processToken(t)}function B3(e,t){t.tagID===p.HTML?(e._insertElement(t,ie.HTML),e.insertionMode=P.BEFORE_HEAD):Vs(e,t)}function U3(e,t){const n=t.tagID;(n===p.HTML||n===p.HEAD||n===p.BODY||n===p.BR)&&Vs(e,t)}function Vs(e,t){e._insertFakeRootElement(),e.insertionMode=P.BEFORE_HEAD,e._processToken(t)}function H3(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.HEAD:{e._insertElement(t,ie.HTML),e.headElement=e.openElements.current,e.insertionMode=P.IN_HEAD;break}default:Ys(e,t)}}function z3(e,t){const n=t.tagID;n===p.HEAD||n===p.BODY||n===p.HTML||n===p.BR?Ys(e,t):e._err(t,Q.endTagWithoutMatchingOpenElement)}function Ys(e,t){e._insertFakeElement(Y.HEAD,p.HEAD),e.headElement=e.openElements.current,e.insertionMode=P.IN_HEAD,e._processToken(t)}function qn(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.BASE:case p.BASEFONT:case p.BGSOUND:case p.LINK:case p.META:{e._appendElement(t,ie.HTML),t.ackSelfClosing=!0;break}case p.TITLE:{e._switchToTextParsing(t,xt.RCDATA);break}case p.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,xt.RAWTEXT):(e._insertElement(t,ie.HTML),e.insertionMode=P.IN_HEAD_NO_SCRIPT);break}case p.NOFRAMES:case p.STYLE:{e._switchToTextParsing(t,xt.RAWTEXT);break}case p.SCRIPT:{e._switchToTextParsing(t,xt.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,Q.misplacedStartTagForHeadElement);break}default:Ws(e,t)}}function j3(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:{Ws(e,t);break}case p.TEMPLATE:{Di(e,t);break}default:e._err(t,Q.endTagWithoutMatchingOpenElement)}}function Di(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==p.TEMPLATE&&e._err(t,Q.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,Q.endTagWithoutMatchingOpenElement)}function Ws(e,t){e.openElements.pop(),e.insertionMode=P.AFTER_HEAD,e._processToken(t)}function $3(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.BASEFONT:case p.BGSOUND:case p.HEAD:case p.LINK:case p.META:case p.NOFRAMES:case p.STYLE:{qn(e,t);break}case p.NOSCRIPT:{e._err(t,Q.nestedNoscriptInHead);break}default:qs(e,t)}}function V3(e,t){switch(t.tagID){case p.NOSCRIPT:{e.openElements.pop(),e.insertionMode=P.IN_HEAD;break}case p.BR:{qs(e,t);break}default:e._err(t,Q.endTagWithoutMatchingOpenElement)}}function qs(e,t){const n=t.type===$e.EOF?Q.openElementsLeftAfterEof:Q.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=P.IN_HEAD,e._processToken(t)}function Y3(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.BODY:{e._insertElement(t,ie.HTML),e.framesetOk=!1,e.insertionMode=P.IN_BODY;break}case p.FRAMESET:{e._insertElement(t,ie.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,Q.abandonedHeadElementChild),e.openElements.push(e.headElement,p.HEAD),qn(e,t),e.openElements.remove(e.headElement);break}case p.HEAD:{e._err(t,Q.misplacedStartTagForHeadElement);break}default:Gs(e,t)}}function W3(e,t){switch(t.tagID){case p.BODY:case p.HTML:case p.BR:{Gs(e,t);break}case p.TEMPLATE:{Di(e,t);break}default:e._err(t,Q.endTagWithoutMatchingOpenElement)}}function Gs(e,t){e._insertFakeElement(Y.BODY,p.BODY),e.insertionMode=P.IN_BODY,Uu(e,t)}function Uu(e,t){switch(t.type){case $e.CHARACTER:{L1(e,t);break}case $e.WHITESPACE_CHARACTER:{P1(e,t);break}case $e.COMMENT:{cf(e,t);break}case $e.START_TAG:{qt(e,t);break}case $e.END_TAG:{Hu(e,t);break}case $e.EOF:{H1(e,t);break}}}function P1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function L1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function q3(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function G3(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function K3(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,ie.HTML),e.insertionMode=P.IN_FRAMESET)}function Q3(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,ie.HTML)}function X3(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&sf.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,ie.HTML)}function J3(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,ie.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function Z3(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,ie.HTML),n||(e.formElement=e.openElements.current))}function eO(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,ie.HTML)}function tO(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,ie.HTML),e.tokenizer.state=xt.PLAINTEXT}function nO(e,t){e.openElements.hasInScope(p.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,ie.HTML),e.framesetOk=!1}function rO(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(Y.A);n&&(lf(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,ie.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function iO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ie.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function oO(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(p.NOBR)&&(lf(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,ie.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function sO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ie.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function aO(e,t){e.treeAdapter.getDocumentMode(e.document)!==Ln.QUIRKS&&e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._insertElement(t,ie.HTML),e.framesetOk=!1,e.insertionMode=P.IN_TABLE}function D1(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,ie.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function M1(e){const t=p1(e,Li.TYPE);return t!=null&&t.toLowerCase()===A3}function uO(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,ie.HTML),M1(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function lO(e,t){e._appendElement(t,ie.HTML),t.ackSelfClosing=!0}function cO(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._appendElement(t,ie.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function dO(e,t){t.tagName=Y.IMG,t.tagID=p.IMG,D1(e,t)}function fO(e,t){e._insertElement(t,ie.HTML),e.skipNextNewLine=!0,e.tokenizer.state=xt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=P.TEXT}function hO(e,t){e.openElements.hasInButtonScope(p.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function pO(e,t){e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function F1(e,t){e._switchToTextParsing(t,xt.RAWTEXT)}function mO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ie.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 gO(e,t){e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,ie.HTML)}function EO(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,ie.HTML)}function yO(e,t){e.openElements.hasInScope(p.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(p.RTC),e._insertElement(t,ie.HTML)}function TO(e,t){e._reconstructActiveFormattingElements(),k1(t),uf(t),t.selfClosing?e._appendElement(t,ie.MATHML):e._insertElement(t,ie.MATHML),t.ackSelfClosing=!0}function bO(e,t){e._reconstructActiveFormattingElements(),N1(t),uf(t),t.selfClosing?e._appendElement(t,ie.SVG):e._insertElement(t,ie.SVG),t.ackSelfClosing=!0}function B1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ie.HTML)}function qt(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:{iO(e,t);break}case p.A:{rO(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{X3(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:{Q3(e,t);break}case p.LI:case p.DD:case p.DT:{eO(e,t);break}case p.BR:case p.IMG:case p.WBR:case p.AREA:case p.EMBED:case p.KEYGEN:{D1(e,t);break}case p.HR:{cO(e,t);break}case p.RB:case p.RTC:{EO(e,t);break}case p.RT:case p.RP:{yO(e,t);break}case p.PRE:case p.LISTING:{J3(e,t);break}case p.XMP:{hO(e,t);break}case p.SVG:{bO(e,t);break}case p.HTML:{q3(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:{qn(e,t);break}case p.BODY:{G3(e,t);break}case p.FORM:{Z3(e,t);break}case p.NOBR:{oO(e,t);break}case p.MATH:{TO(e,t);break}case p.TABLE:{aO(e,t);break}case p.INPUT:{uO(e,t);break}case p.PARAM:case p.TRACK:case p.SOURCE:{lO(e,t);break}case p.IMAGE:{dO(e,t);break}case p.BUTTON:{nO(e,t);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{sO(e,t);break}case p.IFRAME:{pO(e,t);break}case p.SELECT:{mO(e,t);break}case p.OPTION:case p.OPTGROUP:{gO(e,t);break}case p.NOEMBED:case p.NOFRAMES:{F1(e,t);break}case p.FRAMESET:{K3(e,t);break}case p.TEXTAREA:{fO(e,t);break}case p.NOSCRIPT:{e.options.scriptingEnabled?F1(e,t):B1(e,t);break}case p.PLAINTEXT:{tO(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:B1(e,t)}}function xO(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 _O(e,t){e.openElements.hasInScope(p.BODY)&&(e.insertionMode=P.AFTER_BODY,G1(e,t))}function wO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function SO(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 AO(e){e.openElements.hasInButtonScope(p.P)||e._insertFakeElement(Y.P,p.P),e._closePElement()}function vO(e){e.openElements.hasInListItemScope(p.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(p.LI),e.openElements.popUntilTagNamePopped(p.LI))}function CO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function kO(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function NO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function OO(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(Y.BR,p.BR),e.openElements.pop(),e.framesetOk=!1}function U1(e,t){const n=t.tagName,r=t.tagID;for(let o=e.openElements.stackTop;o>0;o--){const a=e.openElements.items[o],u=e.openElements.tagIDs[o];if(r===u&&(r!==p.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=o&&e.openElements.shortenToLength(o);break}if(e._isSpecialElement(a,u))break}}function Hu(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:{lf(e,t);break}case p.P:{AO(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:{wO(e,t);break}case p.LI:{vO(e);break}case p.DD:case p.DT:{CO(e,t);break}case p.H1:case p.H2:case p.H3:case p.H4:case p.H5:case p.H6:{kO(e);break}case p.BR:{OO(e);break}case p.BODY:{xO(e,t);break}case p.HTML:{_O(e,t);break}case p.FORM:{SO(e);break}case p.APPLET:case p.OBJECT:case p.MARQUEE:{NO(e,t);break}case p.TEMPLATE:{Di(e,t);break}default:U1(e,t)}}function H1(e,t){e.tmplInsertionModeStack.length>0?q1(e,t):df(e,t)}function IO(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 RO(e,t){e._err(t,Q.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function ff(e,t){if(e.openElements.currentTagId!==void 0&&O1.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 $e.CHARACTER:{j1(e,t);break}case $e.WHITESPACE_CHARACTER:{z1(e,t);break}}else Qs(e,t)}function PO(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,ie.HTML),e.insertionMode=P.IN_CAPTION}function LO(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,ie.HTML),e.insertionMode=P.IN_COLUMN_GROUP}function DO(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.COLGROUP,p.COLGROUP),e.insertionMode=P.IN_COLUMN_GROUP,hf(e,t)}function MO(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,ie.HTML),e.insertionMode=P.IN_TABLE_BODY}function FO(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.TBODY,p.TBODY),e.insertionMode=P.IN_TABLE_BODY,ju(e,t)}function BO(e,t){e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function UO(e,t){M1(t)?e._appendElement(t,ie.HTML):Qs(e,t),t.ackSelfClosing=!0}function HO(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,ie.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Ao(e,t){switch(t.tagID){case p.TD:case p.TH:case p.TR:{FO(e,t);break}case p.STYLE:case p.SCRIPT:case p.TEMPLATE:{qn(e,t);break}case p.COL:{DO(e,t);break}case p.FORM:{HO(e,t);break}case p.TABLE:{BO(e,t);break}case p.TBODY:case p.TFOOT:case p.THEAD:{MO(e,t);break}case p.INPUT:{UO(e,t);break}case p.CAPTION:{PO(e,t);break}case p.COLGROUP:{LO(e,t);break}default:Qs(e,t)}}function Ks(e,t){switch(t.tagID){case p.TABLE:{e.openElements.hasInTableScope(p.TABLE)&&(e.openElements.popUntilTagNamePopped(p.TABLE),e._resetInsertionMode());break}case p.TEMPLATE:{Di(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:Qs(e,t)}}function Qs(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,Uu(e,t),e.fosterParentingEnabled=n}function z1(e,t){e.pendingCharacterTokens.push(t)}function j1(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Xs(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Qs(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const $1=new Set([p.CAPTION,p.COL,p.COLGROUP,p.TBODY,p.TD,p.TFOOT,p.TH,p.THEAD,p.TR]);function zO(e,t){const n=t.tagID;$1.has(n)?e.openElements.hasInTableScope(p.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(p.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=P.IN_TABLE,Ao(e,t)):qt(e,t)}function jO(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&&Ks(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:Hu(e,t)}}function hf(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.COL:{e._appendElement(t,ie.HTML),t.ackSelfClosing=!0;break}case p.TEMPLATE:{qn(e,t);break}default:zu(e,t)}}function $O(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:{Di(e,t);break}case p.COL:break;default:zu(e,t)}}function zu(e,t){e.openElements.currentTagId===p.COLGROUP&&(e.openElements.pop(),e.insertionMode=P.IN_TABLE,e._processToken(t))}function ju(e,t){switch(t.tagID){case p.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,ie.HTML),e.insertionMode=P.IN_ROW;break}case p.TH:case p.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(Y.TR,p.TR),e.insertionMode=P.IN_ROW,$u(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,Ao(e,t));break}default:Ao(e,t)}}function pf(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,Ks(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:Ks(e,t)}}function $u(e,t){switch(t.tagID){case p.TH:case p.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,ie.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,ju(e,t));break}default:Ao(e,t)}}function V1(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,pf(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,pf(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:Ks(e,t)}}function VO(e,t){const n=t.tagID;$1.has(n)?(e.openElements.hasInTableScope(p.TD)||e.openElements.hasInTableScope(p.TH))&&(e._closeTableCell(),$u(e,t)):qt(e,t)}function YO(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(),V1(e,t));break}case p.BODY:case p.CAPTION:case p.COL:case p.COLGROUP:case p.HTML:break;default:Hu(e,t)}}function Y1(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.OPTION:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e._insertElement(t,ie.HTML);break}case p.OPTGROUP:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._insertElement(t,ie.HTML);break}case p.HR:{e.openElements.currentTagId===p.OPTION&&e.openElements.pop(),e.openElements.currentTagId===p.OPTGROUP&&e.openElements.pop(),e._appendElement(t,ie.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:{qn(e,t);break}}}function W1(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:{Di(e,t);break}}}function WO(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)):Y1(e,t)}function qO(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)):W1(e,t)}function GO(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:{qn(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,Ao(e,t);break}case p.COL:{e.tmplInsertionModeStack[0]=P.IN_COLUMN_GROUP,e.insertionMode=P.IN_COLUMN_GROUP,hf(e,t);break}case p.TR:{e.tmplInsertionModeStack[0]=P.IN_TABLE_BODY,e.insertionMode=P.IN_TABLE_BODY,ju(e,t);break}case p.TD:case p.TH:{e.tmplInsertionModeStack[0]=P.IN_ROW,e.insertionMode=P.IN_ROW,$u(e,t);break}default:e.tmplInsertionModeStack[0]=P.IN_BODY,e.insertionMode=P.IN_BODY,qt(e,t)}}function KO(e,t){t.tagID===p.TEMPLATE&&Di(e,t)}function q1(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(p.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):df(e,t)}function QO(e,t){t.tagID===p.HTML?qt(e,t):Vu(e,t)}function G1(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 Vu(e,t)}function Vu(e,t){e.insertionMode=P.IN_BODY,Uu(e,t)}function XO(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.FRAMESET:{e._insertElement(t,ie.HTML);break}case p.FRAME:{e._appendElement(t,ie.HTML),t.ackSelfClosing=!0;break}case p.NOFRAMES:{qn(e,t);break}}}function JO(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 ZO(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.NOFRAMES:{qn(e,t);break}}}function eI(e,t){t.tagID===p.HTML&&(e.insertionMode=P.AFTER_AFTER_FRAMESET)}function tI(e,t){t.tagID===p.HTML?qt(e,t):Yu(e,t)}function Yu(e,t){e.insertionMode=P.IN_BODY,Uu(e,t)}function nI(e,t){switch(t.tagID){case p.HTML:{qt(e,t);break}case p.NOFRAMES:{qn(e,t);break}}}function rI(e,t){t.chars=ft,e._insertCharacters(t)}function iI(e,t){e._insertCharacters(t),e.framesetOk=!1}function K1(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==ie.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function oI(e,t){if(b3(t))K1(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===ie.MATHML?k1(t):r===ie.SVG&&(x3(t),N1(t)),uf(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function sI(e,t){if(t.tagID===p.P||t.tagID===p.BR){K1(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)===ie.HTML){e._endTagOutsideForeignContent(t);break}const o=e.treeAdapter.getTagName(r);if(o.toLowerCase()===t.tagName){t.tagName=o,e.openElements.shortenToLength(n);break}}}Y.AREA,Y.BASE,Y.BASEFONT,Y.BGSOUND,Y.BR,Y.COL,Y.EMBED,Y.FRAME,Y.HR,Y.IMG,Y.INPUT,Y.KEYGEN,Y.LINK,Y.META,Y.PARAM,Y.SOURCE,Y.TRACK,Y.WBR;const aI=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,uI=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Q1={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function X1(e,t){const n=yI(e),r=l1("type",{handlers:{root:lI,element:cI,text:dI,comment:Z1,doctype:fI,raw:pI},unknown:mI}),o={parser:n?new R1(Q1):R1.getFragmentParser(void 0,Q1),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),vo(o,ar());const a=n?o.parser.document:o.parser.getFragment(),u=lN(a,{file:o.options.file});return o.stitches&&Lu(u,"comment",function(c,d,h){const m=c;if(m.value.stitch&&h&&d!==void 0){const E=h.children;return E[d]=m.value.stitch,d}}),u.type==="root"&&u.children.length===1&&u.children[0].type===e.type?u.children[0]:u}function J1(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function lI(e,t){J1(e.children,t)}function cI(e,t){gI(e,t),J1(e.children,t),EI(e,t)}function dI(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:$e.CHARACTER,chars:e.value,location:Js(e)};vo(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function fI(e,t){const n={type:$e.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Js(e)};vo(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function hI(e,t){t.stitches=!0;const n=TI(e);if("children"in e&&"children"in n){const r=X1({type:"root",children:e.children},t.options);n.children=r.children}Z1({type:"comment",value:{stitch:n}},t)}function Z1(e,t){const n=e.value,r={type:$e.COMMENT,data:n,location:Js(e)};vo(t,ar(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function pI(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,eE(t,ar(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(aI,"&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 mI(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))hI(n,t);else{let r="";throw uI.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 vo(e,t){eE(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=xt.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 eE(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 gI(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===xt.PLAINTEXT)return;vo(t,ar(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Ri.html;o===Ri.html&&n==="svg"&&(o=Ri.svg);const a=SN(ne(U({},e),{children:[]}),{space:o===Ri.svg?"svg":"html"}),u={type:$e.START_TAG,tagName:n,tagID:So(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Js(e)};t.parser.currentToken=u,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function EI(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&RN.includes(n)||t.parser.tokenizer.state===xt.PLAINTEXT)return;vo(t,wu(e));const r={type:$e.END_TAG,tagName:n,tagID:So(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Js(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===xt.RCDATA||t.parser.tokenizer.state===xt.RAWTEXT||t.parser.tokenizer.state===xt.SCRIPT_DATA)&&(t.parser.tokenizer.state=xt.DATA)}function yI(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Js(e){const t=ar(e)||{line:void 0,column:void 0,offset:void 0},n=wu(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 TI(e){return"children"in e?Ii(ne(U({},e),{children:[]})):Ii(e)}function tE(e){return function(t,n){return X1(t,ne(U({},e),{file:n}))}}const Mi=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],nE={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Mi,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Mi],h2:[["className","sr-only"]],img:[...Mi,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Mi,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Mi],table:[...Mi],ul:[...Mi,["className","contains-task-list"]],"*":["abbr","accept","acceptCharset","accessKey","action","align","alt","axis","border","cellPadding","cellSpacing","char","charOff","charSet","checked","clear","colSpan","color","cols","compact","coords","dateTime","dir","encType","frame","hSpace","headers","height","hrefLang","htmlFor","id","isMap","itemProp","label","lang","maxLength","media","method","multiple","name","noHref","noShade","noWrap","open","prompt","readOnly","rev","rowSpan","rows","rules","scope","selected","shape","size","span","start","summary","tabIndex","title","useMap","vAlign","value","width"]},clobber:["ariaDescribedBy","ariaLabelledBy","id","name"],clobberPrefix:"user-content-",protocols:{cite:["http","https"],href:["http","https","irc","ircs","mailto","xmpp"],longDesc:["http","https"],src:["http","https"]},required:{input:{disabled:!0,type:"checkbox"}},strip:["script"],tagNames:["a","b","blockquote","br","code","dd","del","details","div","dl","dt","em","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","li","ol","p","picture","pre","q","rp","rt","ruby","s","samp","section","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","tr","tt","ul","var"]},Gr={}.hasOwnProperty;function bI(e,t){let n={type:"root",children:[]};const r={schema:t?U(U({},nE),t):nE,stack:[]},o=rE(r,e);return o&&(Array.isArray(o)?o.length===1?n=o[0]:n.children=o:n=o),n}function rE(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return xI(e,n);case"doctype":return _I(e,n);case"element":return wI(e,n);case"root":return SI(e,n);case"text":return AI(e,n)}}}function xI(e,t){if(e.schema.allowComments){const n=typeof t.value=="string"?t.value:"",r=n.indexOf("-->"),a={type:"comment",value:r<0?n:n.slice(0,r)};return Zs(a,t),a}}function _I(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return Zs(n,t),n}}function wI(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=iE(e,t.children),o=vI(e,t.properties);e.stack.pop();let a=!1;if(n&&n!=="*"&&(!e.schema.tagNames||e.schema.tagNames.includes(n))&&(a=!0,e.schema.ancestors&&Gr.call(e.schema.ancestors,n))){const c=e.schema.ancestors[n];let d=-1;for(a=!1;++d<c.length;)e.stack.includes(c[d])&&(a=!0)}if(!a)return e.schema.strip&&!e.schema.strip.includes(n)?r:void 0;const u={type:"element",tagName:n,properties:o,children:r};return Zs(u,t),u}function SI(e,t){const r={type:"root",children:iE(e,t.children)};return Zs(r,t),r}function AI(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return Zs(r,t),r}function iE(e,t){const n=[];if(Array.isArray(t)){const r=t;let o=-1;for(;++o<r.length;){const a=rE(e,r[o]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function vI(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,o=e.schema.required,a=r&&Gr.call(r,n)?r[n]:void 0,u=r&&Gr.call(r,"*")?r["*"]:void 0,c=t&&typeof t=="object"?t:{},d={};let h;for(h in c)if(Gr.call(c,h)){const m=c[h];let E=oE(e,aE(a,h),h,m);E==null&&(E=oE(e,aE(u,h),h,m)),E!=null&&(d[h]=E)}if(o&&Gr.call(o,n)){const m=o[n];for(h in m)Gr.call(m,h)&&!Gr.call(d,h)&&(d[h]=m[h])}return d}function oE(e,t,n,r){return t?Array.isArray(r)?CI(e,t,n,r):sE(e,t,n,r):void 0}function CI(e,t,n,r){let o=-1;const a=[];for(;++o<r.length;){const u=sE(e,t,n,r[o]);(typeof u=="number"||typeof u=="string")&&a.push(u)}return a}function sE(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&kI(e,n,r)){if(typeof t=="object"&&t.length>1){let o=!1,a=0;for(;++a<t.length;){const u=t[a];if(u&&typeof u=="object"&&"flags"in u){if(u.test(String(r))){o=!0;break}}else if(u===r){o=!0;break}}if(!o)return}return e.schema.clobber&&e.schema.clobberPrefix&&e.schema.clobber.includes(n)?e.schema.clobberPrefix+r:r}}function kI(e,t,n){const r=e.schema.protocols&&Gr.call(e.schema.protocols,t)?e.schema.protocols[t]:void 0;if(!r||r.length===0)return!0;const o=String(n),a=o.indexOf(":"),u=o.indexOf("?"),c=o.indexOf("#"),d=o.indexOf("/");if(a<0||d>-1&&a>d||u>-1&&a>u||c>-1&&a>c)return!0;let h=-1;for(;++h<r.length;){const m=r[h];if(a===m.length&&o.slice(0,m.length)===m)return!0}return!1}function Zs(e,t){const n=j0(t);t.data&&(e.data=Ii(t.data)),n&&(e.position=n)}function aE(e,t){let n,r=-1;if(e)for(;++r<e.length;){const o=e[r],a=typeof o=="string"?o:o[0];if(a===t)return o;a==="data*"&&(n=o)}if(t.length>4&&t.slice(0,4).toLowerCase()==="data")return n}function NI(e){return function(t){return bI(t,e)}}const uE=({globalClassName:e,openLinksInNewTab:t,href:n,title:r,children:o})=>{const a=n?t?"_blank":"_self":void 0;return L.jsx("a",ne(U(U({className:oe(e,`${J}-link`)},n?{href:n,target:a}:{}),r?{title:r}:{}),{rel:"noopener noreferrer",children:o}))},OI=()=>{const{disclaimerText:e,disclaimerMarkdown:t,globalClassName:n}=en();return!e&&!t?null:L.jsx("div",{className:oe(n,`${J}-disclaimer`),children:t?L.jsx($g,{rehypePlugins:[tE,NI],components:{ul:({children:r})=>L.jsx("ul",{className:oe(n,`${J}-ul`),children:r}),ol:({children:r})=>L.jsx("ol",{className:oe(n,`${J}-ol`),children:r}),li:({children:r})=>L.jsx("li",{className:oe(n,`${J}-li`),children:r}),a:({href:r,title:o,children:a})=>L.jsx(uE,{globalClassName:n,openLinksInNewTab:!0,href:r,title:o,children:a}),img:({src:r,alt:o})=>L.jsx("img",{className:oe(n,`${J}-disclaimer-image`),src:r,alt:o}),p:({children:r})=>L.jsx("p",{className:oe(n,`${J}-disclaimer-text`),children:r}),span:({children:r})=>L.jsx("span",{className:oe(n,`${J}-disclaimer-text-span`),children:r})},children:t}):L.jsx("p",{className:oe(n,`${J}-disclaimer-text`),children:e})})},mf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{isConnected:o}=ki(),{globalClassName:a,searchConfig:u}=en(),c=ee.useRef(null),d=t||!o,h=E=>{var b;E.preventDefault();const T=(((b=c.current)==null?void 0:b.value)||"").trim();T&&(c.current.value="",r(T))},m=()=>{r("Can you connect me to a human?")};return L.jsxs("div",{className:oe(a,e,`cim-${n}-component`,`${J}-search-bar-wrapper`),children:[L.jsxs("form",{className:oe(a,e,`cim-${n}-component`,`${J}-search-bar`),name:`${J}-search-form`,onSubmit:h,children:[L.jsx("input",{className:oe(a,e,`cim-${n}-component`,`${J}-search-input`),type:"text",ref:c,placeholder:(u==null?void 0:u.placeholder)||"Ask us anything",name:`${J}-user-input`,disabled:d}),L.jsx(JS,{className:e,globalClassName:a,searchConfig:u,componentType:n,isLoading:d}),L.jsx(jr,{className:oe(a,`${J}-escalate-btn`),ariaLabel:"Connect to a human agent",title:"Connect to a human agent",disabled:d,onClick:m,icon:L.jsx(WS,{})})]}),L.jsx(OI,{})]})};function II(e){return ln({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 lE=ee.createContext(null),ea=()=>{var n;const e=()=>{},t=ee.useContext(lE);return(n=t==null?void 0:t.closeMenu)!=null?n:e},cE=({onClearChat:e,componentType:t})=>{const n=ea(),r=()=>{e(),n()};return L.jsxs("button",{className:oe(`${J}-overflow-menu-button`,"clear-chat-button",`cim-${t}-component`),onClick:r,children:[L.jsx(II,{}),"Clear chat"]})};function RI(e){return e==null?[]:Array.isArray(e)?e:[e]}var PI=(e,...t)=>e.concat(t),LI=(e,...t)=>e.filter(n=>!t.includes(n)),DI=e=>Array.from(new Set(e));function dE(e,t,n={}){const{step:r=1,loop:o=!0}=n,a=t+r,u=e.length,c=u-1;return t===-1?r>0?0:c:a<0?o?c:0:a>=u?o?0:t>u?u:t:a}function MI(e,t,n={}){const{step:r=1,loop:o=!0}=n;return dE(e,t,{step:-r,loop:o})}var FI=e=>Array.isArray(e),fE=e=>e!=null&&typeof e=="object",BI=e=>fE(e)&&!FI(e),Wu=e=>typeof e=="string",Co=e=>typeof e=="function",UI=e=>e==null,HI=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),zI=e=>Object.prototype.toString.call(e),hE=Function.prototype.toString,jI=hE.call(Object),$I=e=>{if(!fE(e)||zI(e)!="[object Object]"||WI(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=HI(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&hE.call(n)==jI},VI=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,YI=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,WI=e=>VI(e)||YI(e),qI=e=>e(),GI=()=>{},gf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function KI(e,t=0){let n=0,r=null;return((...o)=>{const a=Date.now(),u=a-n;u>=t?(r&&(clearTimeout(r),r=null),e(...o),n=a):r||(r=setTimeout(()=>{e(...o),n=Date.now(),r=null},t-u))})}var{min:QI,max:XI}=Math,JI=e=>Number.isNaN(e),ZI=e=>JI(e)?0:e,pE=(e,t,n)=>QI(XI(ZI(e),t),n);function Ef(e){if(!$I(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]=Ef(o))}return n}function yf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function eR(e,t){if(e==null)throw new Error(t())}function tR(e,t,n){let r=[];for(const o of t)e[o]==null&&r.push(o);if(r.length>0)throw new Error(`[zag-js${` > ${n}`}] missing required props: ${r.join(", ")}`)}var nR=Object.defineProperty,rR=(e,t,n)=>t in e?nR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tf=(e,t,n)=>rR(e,typeof t!="symbol"?t+"":t,n),mE=()=>{},qu=e=>typeof e=="object"&&e!==null,ko=e=>e?"":void 0,gE=e=>e?"true":void 0,iR=1,oR=9,sR=11,Dt=e=>qu(e)&&e.nodeType===iR&&typeof e.nodeName=="string",Gu=e=>qu(e)&&e.nodeType===oR,aR=e=>qu(e)&&e===e.window,EE=e=>Dt(e)?e.localName||"":"#document";function uR(e){return["html","body","#document"].includes(EE(e))}var lR=e=>qu(e)&&e.nodeType!==void 0,Fi=e=>lR(e)&&e.nodeType===sR&&"host"in e,cR=e=>Dt(e)&&e.localName==="input",dR=e=>Dt(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function ta(e){if(!e)return!1;const t=e.getRootNode();return Io(t)===e}var fR=/(textarea|select)/;function hR(e){if(e==null||!Dt(e))return!1;try{return cR(e)&&e.selectionStart!=null||fR.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function No(e,t){var r;if(!e||!t||!Dt(e)||!Dt(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Fi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function cr(e){var t;return Gu(e)?e:aR(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function pR(e){return cr(e).documentElement}function Oo(e){var t,n,r;return Fi(e)?Oo(e.host):Gu(e)?(t=e.defaultView)!=null?t:window:Dt(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Io(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 mR(e){if(EE(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Fi(e)&&e.host||pR(e);return Fi(t)?t.host:t}function bf(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),Gu(t)||Fi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var xf=new WeakMap;function Ro(e){return xf.has(e)||xf.set(e,Oo(e).getComputedStyle(e)),xf.get(e)}var _f=new Set(["menu","listbox","dialog","grid","tree","region"]),gR=e=>_f.has(e),yE=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function TE(e,t){const n=new Set,r=bf(e),o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=yE(c);for(const h of d){if(!h||n.has(h))continue;n.add(h);const m=r.getElementById(h);if(m){const E=m.getAttribute("role"),T=m.getAttribute("aria-modal")==="true";if(E&&gR(E)&&!T&&(m===t||m.contains(t)||o(m)))return!0}}}return!1};return o(e)}function bE(e,t){const n=bf(e),r=new Set,o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=yE(c);for(const h of d){if(!h||r.has(h))continue;r.add(h);const m=n.getElementById(h);if(m){const E=m.getAttribute("role"),T=m.getAttribute("aria-modal")==="true";E&&_f.has(E)&&!T&&(t(m),o(m))}}}};o(e)}function ER(e){const t=new Set;return bE(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function yR(e){const t=e.getAttribute("role");return!!(t&&_f.has(t))}function TR(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function bR(e){var t;return TR(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function xR(e){if(!e.id)return!1;const t=bf(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&yR(e))}var wf=()=>typeof document!="undefined";function _R(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Sf=e=>wf()&&e.test(_R()),wR=e=>wf()&&e.test(navigator.vendor),xE=()=>wf()&&!!navigator.maxTouchPoints,SR=()=>Sf(/^iPhone/i),AR=()=>Sf(/^iPad/i)||Af()&&navigator.maxTouchPoints>1,Ku=()=>SR()||AR(),vR=()=>Af()||Ku(),Af=()=>Sf(/^Mac/i),CR=()=>vR()&&wR(/apple/i);function kR(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 Gn(e){var n;const t=kR(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var _E=e=>e.button===0,NR=e=>e.button===2||Af()&&e.ctrlKey&&e.button===0,OR=e=>"touches"in e&&e.touches.length>0,IR={Up:"ArrowUp",Down:"ArrowDown",Esc:"Escape"," ":"Space",",":"Comma",Left:"ArrowLeft",Right:"ArrowRight"},wE={ArrowLeft:"ArrowRight",ArrowRight:"ArrowLeft"};function RR(e,t={}){var u;const{dir:n="ltr",orientation:r="horizontal"}=t;let o=e.key;return o=(u=IR[o])!=null?u:o,n==="rtl"&&r==="horizontal"&&o in wE&&(o=wE[o]),o}function SE(e,t="client"){const n=OR(e)?e.touches[0]||e.changedTouches[0]:e;return{x:n[`${t}X`],y:n[`${t}Y`]}}var Mt=(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)}},AE=e=>Dt(e)&&e.tagName==="IFRAME",PR=/^(audio|video|details)$/;function vE(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var LR=e=>!Number.isNaN(vE(e)),DR=e=>vE(e)<0;function MR(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 CE(e,t,n){const r=[...e],o=[...e],a=new Set,u=new Map;e.forEach((d,h)=>u.set(d,h));let c=0;for(;c<o.length;){const d=o[c++];if(!d||a.has(d))continue;a.add(d);const h=MR(d,t);if(h){const m=Array.from(h.querySelectorAll(Qu)).filter(n),E=u.get(d);if(E!==void 0){const T=E+1;r.splice(T,0,...m),m.forEach((b,_)=>{u.set(b,T+_)});for(let b=T+m.length;b<r.length;b++)u.set(r[b],b)}else{const T=r.length;r.push(...m),m.forEach((b,_)=>{u.set(b,T+_)})}o.push(...m)}}return r}var Qu="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",kE=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Qu));(n==!0||n=="if-empty"&&o.length===0)&&Dt(e)&&dr(e)&&o.unshift(e);const u=[];for(const c of o)if(dr(c)){if(AE(c)&&c.contentDocument){const d=c.contentDocument.body;u.push(...kE(d,{getShadowRoot:r}));continue}u.push(c)}return r?CE(u,r,dr):u};function dr(e){return!Dt(e)||e.closest("[inert]")?!1:e.matches(Qu)&&dR(e)}function Po(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Qu));n&&Bi(e)&&o.unshift(e);const a=[];for(const u of o)if(Bi(u)){if(AE(u)&&u.contentDocument){const c=u.contentDocument.body;a.push(...Po(c,{getShadowRoot:r}));continue}a.push(u)}if(r){const u=CE(a,r,Bi);return!u.length&&n?o:u}return!a.length&&n?o:a}function Bi(e){return Dt(e)&&e.tabIndex>0?!0:dr(e)&&!DR(e)}function FR(e,t={}){const n=Po(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function BR(e,t={}){const{current:n,getShadowRoot:r}=t,o=Po(e,{getShadowRoot:r}),a=(e==null?void 0:e.ownerDocument)||document,u=n!=null?n:Io(a);if(!u)return null;const c=o.indexOf(u);return o[c+1]||null}function na(e){return e.tabIndex<0&&(PR.test(e.localName)||hR(e))&&!LR(e)?0:e.tabIndex}function NE(e){const{root:t,getInitialEl:n,filter:r,enabled:o=!0}=e;if(!o)return;let a=null;if(a||(a=typeof n=="function"?n():n),a||(a=t==null?void 0:t.querySelector("[data-autofocus],[autofocus]")),!a){const u=Po(t);a=r?u.filter(r)[0]:u[0]}return a||t||void 0}var UR=class Nx{constructor(){Tf(this,"id",null),Tf(this,"fn_cleanup"),Tf(this,"cleanup",()=>{this.cancel()})}static create(){return new Nx}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 kt(e){const t=UR.create();return t.request(e),t.cleanup}function OE(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 vf(e){const t=mR(e);return uR(t)?cr(t).body:Dt(t)&&jR(t)?t:vf(t)}var HR=/auto|scroll|overlay|hidden|clip/,zR=new Set(["inline","contents"]);function jR(e){const t=Oo(e),{overflow:n,overflowX:r,overflowY:o,display:a}=t.getComputedStyle(e);return HR.test(n+o+r)&&!zR.has(a)}var Lo="default",Cf="",Xu=new WeakMap;function $R(e={}){const{target:t,doc:n}=e,r=n!=null?n:document,o=r.documentElement;return Ku()?(Lo==="default"&&(Cf=o.style.webkitUserSelect,o.style.webkitUserSelect="none"),Lo="disabled"):t&&(Xu.set(t,t.style.userSelect),t.style.userSelect="none"),()=>VR({target:t,doc:r})}function VR(e={}){const{target:t,doc:n}=e,o=(n!=null?n:document).documentElement;if(Ku()){if(Lo!=="disabled")return;Lo="restoring",setTimeout(()=>{OE(()=>{Lo==="restoring"&&(o.style.webkitUserSelect==="none"&&(o.style.webkitUserSelect=Cf||""),Cf="",Lo="default")})},300)}else if(t&&Xu.has(t)){const a=Xu.get(t);t.style.userSelect==="none"&&(t.style.userSelect=a!=null?a:""),t.getAttribute("style")===""&&t.removeAttribute("style"),Xu.delete(t)}}function YR(e={}){const u=e,{defer:t,target:n}=u,r=on(u,["defer","target"]),o=t?kt:c=>c(),a=[];return a.push(o(()=>{const c=typeof n=="function"?n():n;a.push($R(ne(U({},r),{target:c})))})),()=>{a.forEach(c=>c==null?void 0:c())}}function WR(e,t){const{onPointerMove:n,onPointerUp:r}=t,o=c=>{const d=SE(c),h=Math.sqrt(Ja(d.x,2)+Ja(d.y,2)),m=c.pointerType==="touch"?10:5;if(!(h<m)){if(c.pointerType==="mouse"&&c.button===0){a(c);return}n({point:d,event:c})}},a=c=>{const d=SE(c);r({point:d,event:c})},u=[Mt(e,"pointermove",o,!1),Mt(e,"pointerup",a,!1),Mt(e,"pointercancel",a,!1),Mt(e,"contextmenu",a,!1),YR({doc:e})];return()=>{u.forEach(c=>c())}}function qR(e,t={}){const{triggerElement:n,onFocus:r,onFocusEnter:o,getShadowRoot:a}=t,u=(e==null?void 0:e.ownerDocument)||document,c=u.body;function d(h){if(h.key!=="Tab")return;let m=null;const[E,T]=FR(e,{includeContainer:!0,getShadowRoot:a}),b=BR(c,{current:n,getShadowRoot:a}),_=!E&&!T;h.shiftKey&&ta(b)?(o==null||o(),m=T):h.shiftKey&&(ta(E)||_)?m=n:!h.shiftKey&&ta(n)?(o==null||o(),m=E):!h.shiftKey&&(ta(T)||_)&&(m=b),m&&(h.preventDefault(),typeof r=="function"?r(m):m.focus())}return Mt(u,"keydown",d,!0)}function GR(e,t){const c=t,{defer:n,triggerElement:r}=c,o=on(c,["defer","triggerElement"]),a=n?kt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof r=="function"?r():r;u.push(qR(d,U({triggerElement:h},o)))})),()=>{u.forEach(d=>d==null?void 0:d())}}function KR(e,t){var n;return Array.from((n=e==null?void 0:e.querySelectorAll(t))!=null?n:[])}function Ju(e,t){if(!e)return mE;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 QR(e,t,n){if(!e)return mE;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 XR(e,t,n){const{signal:r}=t;return[new Promise((u,c)=>{const d=setTimeout(()=>{c(new Error(`Timeout of ${n}ms exceeded`))},n);r.addEventListener("abort",()=>{clearTimeout(d),c(new Error("Promise aborted"))}),e.then(h=>{r.aborted||(clearTimeout(d),u(h))}).catch(h=>{r.aborted||(clearTimeout(d),c(h))})}),()=>t.abort()]}function JR(e,t){const{timeout:n,rootNode:r}=t,o=Oo(r),a=cr(r),u=new o.AbortController;return XR(new Promise(c=>{const d=e();if(d){c(d);return}const h=new o.MutationObserver(()=>{const m=e();m&&m.isConnected&&(h.disconnect(),c(m))});h.observe(a.body,{childList:!0,subtree:!0})}),u,n)}var ZR=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),eP=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,IE=e=>{const t={};let n;for(;n=eP.exec(e);)t[n[1]]=n[2];return t},tP=(e,t)=>{if(Wu(e)){if(Wu(t))return`${e};${t}`;e=IE(e)}else Wu(t)&&(t=IE(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function Nt(...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]=ZR(t[o],n[o]);continue}if(o==="style"){t[o]=tP(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 fF(e){return e}var Do=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Do||{}),kf="__init__";function nP(e){const t=()=>{var u,c;return(c=(u=e.getRootNode)==null?void 0:u.call(e))!=null?c:document},n=()=>cr(t()),r=()=>{var u;return(u=n().defaultView)!=null?u:window},o=()=>Io(t()),a=u=>t().getElementById(u);return ne(U({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:ta,getById:a})}function rP(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var Mo=()=>e=>Array.from(new Set(e)),RE=typeof globalThis.document!="undefined"?ee.useLayoutEffect:ee.useEffect;function Zu(e){var E,T;const t=(E=e().value)!=null?E:e().defaultValue,n=(T=e().isEqual)!=null?T:Object.is,[r]=ee.useState(t),[o,a]=ee.useState(r),u=e().value!==void 0,c=ee.useRef(o);c.current=u?e().value:o;const d=ee.useRef(c.current);RE(()=>{d.current=c.current},[o,e().value]);const h=b=>{var A,C;const _=d.current,w=Co(b)?b(_):b;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:w,prev:_}),u||a(w),n(w,_)||(C=(A=e()).onChange)==null||C.call(A,w,_)};function m(){return u?e().value:o}return{initial:r,ref:c,get:m,set(b){(e().sync?ks.flushSync:qI)(()=>h(b))},invoke(b,_){var w,A;(A=(w=e()).onChange)==null||A.call(w,b,_)},hash(b){var _,w,A;return(A=(w=(_=e()).hash)==null?void 0:w.call(_,b))!=null?A:String(b)}}}Zu.cleanup=e=>{ee.useEffect(()=>e,[])},Zu.ref=e=>{const t=ee.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function iP(e){const t=ee.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var oP=(e,t)=>{const n=ee.useRef(!1),r=ee.useRef(!1);ee.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),ee.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function el(e,t={}){var ae,he,ge,ue,Te,Ne;const n=ee.useMemo(()=>{const{id:fe,ids:K,getRootNode:te}=t;return nP({id:fe,ids:K,getRootNode:te})},[t]),r=(...fe)=>{e.debug&&console.log(...fe)},o=(he=(ae=e.props)==null?void 0:ae.call(e,{props:Ef(t),scope:n}))!=null?he:t,a=sP(o),u=(ge=e.context)==null?void 0:ge.call(e,{prop:a,bindable:Zu,scope:n,flush:LE,getContext(){return d},getComputed(){return z},getRefs(){return w},getEvent(){return b()}}),c=PE(u),d={get(fe){var K;return(K=c.current)==null?void 0:K[fe].ref.current},set(fe,K){var te;(te=c.current)==null||te[fe].set(K)},initial(fe){var K;return(K=c.current)==null?void 0:K[fe].initial},hash(fe){var te,S;const K=(te=c.current)==null?void 0:te[fe].get();return(S=c.current)==null?void 0:S[fe].hash(K)}},h=ee.useRef(new Map),m=ee.useRef(null),E=ee.useRef(null),T=ee.useRef({type:""}),b=()=>ne(U({},T.current),{current(){return T.current},previous(){return E.current}}),_=()=>ne(U({},D),{matches(...fe){return fe.includes(D.ref.current)},hasTag(fe){var K,te;return!!((te=(K=e.states[D.ref.current])==null?void 0:K.tags)!=null&&te.includes(fe))}}),w=iP((Te=(ue=e.refs)==null?void 0:ue.call(e,{prop:a,context:d}))!=null?Te:{}),A=()=>({state:_(),context:d,event:b(),prop:a,send:j,action:C,guard:I,track:oP,refs:w,computed:z,flush:LE,scope:n,choose:F}),C=fe=>{const K=Co(fe)?fe(A()):fe;if(!K)return;const te=K.map(S=>{var X,k;const M=(k=(X=e.implementations)==null?void 0:X.actions)==null?void 0:k[S];return M||yf(`[zag-js] No implementation found for action "${JSON.stringify(S)}"`),M});for(const S of te)S==null||S(A())},I=fe=>{var K,te;return Co(fe)?fe(A()):(te=(K=e.implementations)==null?void 0:K.guards)==null?void 0:te[fe](A())},R=fe=>{const K=Co(fe)?fe(A()):fe;if(!K)return;const te=K.map(M=>{var k,xe;const X=(xe=(k=e.implementations)==null?void 0:k.effects)==null?void 0:xe[M];return X||yf(`[zag-js] No implementation found for effect "${JSON.stringify(M)}"`),X}),S=[];for(const M of te){const X=M==null?void 0:M(A());X&&S.push(X)}return()=>S.forEach(M=>M==null?void 0:M())},F=fe=>RI(fe).find(K=>{let te=!K.guard;return Wu(K.guard)?te=!!I(K.guard):Co(K.guard)&&(te=K.guard(A())),te}),z=fe=>{eR(e.computed,()=>"[zag-js] No computed object found on machine");const K=e.computed[fe];return K({context:d,event:b(),prop:a,refs:w,scope:n,computed:z})},D=Zu(()=>({defaultValue:e.initialState({prop:a}),onChange(fe,K){var S,M,X,k;if(K){const xe=h.current.get(K);xe==null||xe(),h.current.delete(K)}K&&C((S=e.states[K])==null?void 0:S.exit),C((M=m.current)==null?void 0:M.actions);const te=R((X=e.states[fe])==null?void 0:X.effects);if(te&&h.current.set(fe,te),K===kf){C(e.entry);const xe=R(e.effects);xe&&h.current.set(kf,xe)}C((k=e.states[fe])==null?void 0:k.entry)}})),q=ee.useRef(void 0),ce=ee.useRef(Do.NotStarted);RE(()=>{queueMicrotask(()=>{var M;const te=ce.current===Do.Started;ce.current=Do.Started,r(te?"rehydrating...":"initializing...");const S=(M=q.current)!=null?M:D.initial;D.invoke(S,te?D.get():kf)});const fe=h.current,K=D.ref.current;return()=>{r("unmounting..."),q.current=K,ce.current=Do.Stopped,fe.forEach(te=>te==null?void 0:te()),h.current=new Map,m.current=null,queueMicrotask(()=>{C(e.exit)})}},[]);const be=()=>"ref"in D?D.ref.current:D.get(),j=fe=>{queueMicrotask(()=>{var k,xe,Pe,Oe,He;if(ce.current!==Do.Started)return;E.current=T.current,T.current=fe;let K=be();const te=(Pe=(k=e.states[K].on)==null?void 0:k[fe.type])!=null?Pe:(xe=e.on)==null?void 0:xe[fe.type],S=F(te);if(!S)return;m.current=S;const M=(Oe=S.target)!=null?Oe:K;r("transition",fe.type,S.target||K,`(${S.actions})`);const X=M!==K;X?ks.flushSync(()=>D.set(M)):S.reenter&&!X?D.invoke(K,K):C((He=S.actions)!=null?He:[])})};return(Ne=e.watch)==null||Ne.call(e,A()),{state:_(),send:j,context:d,prop:a,scope:n,refs:w,computed:z,event:b(),getStatus:()=>ce.current}}function PE(e){const t=ee.useRef(e);return t.current=e,t}function sP(e){const t=PE(e);return function(r){return t.current[r]}}function LE(e){queueMicrotask(()=>{ks.flushSync(()=>e())})}var Nf=rP(e=>e);function tl(...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 aP(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 Of=e=>{const t=ee.memo(ee.forwardRef((n,r)=>{const h=n,{asChild:o,children:a}=h,u=on(h,["asChild","children"]);if(!o)return ee.createElement(e,ne(U({},u),{ref:r}),a);if(!ee.isValidElement(a))return null;const c=ee.Children.only(a),d=aP(c);return ee.cloneElement(c,ne(U({},Nt(u,c.props)),{ref:r?tl(r,d):d}))}));return t.displayName=e.displayName||e.name,t},Gt=(()=>{const e=new Map;return new Proxy(Of,{apply(t,n,r){return Of(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,Of(r)),e.get(r)}})})();function uP(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Ui(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:a,defaultValue:u}=e,c=ee.createContext(u);c.displayName=t;function d(){var m;const h=ee.useContext(c);if(!h&&n){const E=new Error(a!=null?a:uP(r,o));throw E.name="ContextError",(m=Error.captureStackTrace)==null||m.call(Error,E,d),E}return h}return[c.Provider,d,c]}const[lP,If]=Ui({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[DE,ra]=Ui({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),ME=ee.forwardRef((e,t)=>{const n=If(),r=ra(),o=Nt(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:L.jsx(Gt.div,ne(U({},o),{ref:tl(r.ref,t)}))});ME.displayName="PopoverContent";const FE=ee.forwardRef((e,t)=>{const n=If(),r=ra(),o=Nt(n.getPositionerProps(),e);return r.unmounted?null:L.jsx(Gt.div,ne(U({},o),{ref:t}))});FE.displayName="PopoverPositioner";const ia=()=>(e,t)=>t.reduce((n,r)=>{const[o,a]=n,u=r;return a[u]!==void 0&&(o[u]=a[u]),delete a[u],[o,a]},[{},U({},e)]),BE=e=>ia()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function cP(e,t){const{state:n,send:r,context:o}=e,a=n.matches("mounted","unmountSuspended");return{skip:!o.get("initial"),present:a,setNode(u){u&&r({type:"NODE.SET",node:u})},unmount(){r({type:"UNMOUNT"})}}}var dP={props({props:e}){return ne(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",Ro(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 a=t.get("node");if(!o&&(a==null?void 0:a.ownerDocument.visibilityState)==="hidden")return n({type:"UNMOUNT",src:"visibilitychange"});kt(()=>{var c,d;const u=nl(t.get("styles"));e.set("unmountAnimationName",u),u==="none"||u===e.get("prevAnimationName")||((c=t.get("styles"))==null?void 0:c.display)==="none"||((d=t.get("styles"))==null?void 0:d.animationDuration)==="0s"?n({type:"UNMOUNT",src:"presence.changed"}):n({type:"UNMOUNT.SUSPEND"})})},setPrevAnimationName:({context:e,refs:t})=>{kt(()=>{e.set("prevAnimationName",nl(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 a=d=>{var m,E,T;((T=(E=(m=d.composedPath)==null?void 0:m.call(d))==null?void 0:E[0])!=null?T:d.target)===o&&e.set("prevAnimationName",nl(t.get("styles")))},u=d=>{const h=nl(t.get("styles"));Gn(d)===o&&h===e.get("unmountAnimationName")&&!r("present")&&n({type:"UNMOUNT",src:"animationend"})};o.addEventListener("animationstart",a),o.addEventListener("animationcancel",u),o.addEventListener("animationend",u);const c=Ju(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",a),o.removeEventListener("animationcancel",u),o.removeEventListener("animationend",u),OE(()=>c())}}}}};function nl(e){return(e==null?void 0:e.animationName)||"none"}Mo()(["onExitComplete","present","immediate"]);function fP(e,t={}){const{sync:n=!1}=t,r=hP(e);return ee.useCallback((...o)=>{var a;return n?queueMicrotask(()=>{var u;return(u=r.current)==null?void 0:u.call(r,...o)}):(a=r.current)==null?void 0:a.call(r,...o)},[n,r])}function hP(e){const t=ee.useRef(e);return t.current=e,t}const Rf=(e={})=>{const T=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=T,a=on(T,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),u=ee.useRef(!1),c=ne(U({},a),{present:r,onExitComplete:fP(e.onExitComplete)}),d=el(dP,c),h=cP(d);h.present&&(u.current=!0);const m=!h.present&&!u.current&&t||n&&!h.present&&u.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 Hi=(e,t=[])=>({parts:(...n)=>{if(pP(t))return Hi(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>Hi(e,[...t,...n]),omit:(...n)=>Hi(e,t.filter(r=>!n.includes(r))),rename:n=>Hi(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`,`& [data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`].join(", "),attrs:{"data-scope":Fo(e),"data-part":Fo(r)}}}),{})}),Fo=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),pP=e=>e.length===0;const mP=["top","right","bottom","left"],Kr=Math.min,wn=Math.max,rl=Math.round,il=Math.floor,fr=e=>({x:e,y:e}),gP={left:"right",right:"left",bottom:"top",top:"bottom"},EP={start:"end",end:"start"};function Pf(e,t,n){return wn(e,Kr(t,n))}function vr(e,t){return typeof e=="function"?e(t):e}function Cr(e){return e.split("-")[0]}function Bo(e){return e.split("-")[1]}function Lf(e){return e==="x"?"y":"x"}function Df(e){return e==="y"?"height":"width"}const yP=new Set(["top","bottom"]);function hr(e){return yP.has(Cr(e))?"y":"x"}function Mf(e){return Lf(hr(e))}function TP(e,t,n){n===void 0&&(n=!1);const r=Bo(e),o=Mf(e),a=Df(o);let u=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(u=ol(u)),[u,ol(u)]}function bP(e){const t=ol(e);return[Ff(e),t,Ff(t)]}function Ff(e){return e.replace(/start|end/g,t=>EP[t])}const UE=["left","right"],HE=["right","left"],xP=["top","bottom"],_P=["bottom","top"];function wP(e,t,n){switch(e){case"top":case"bottom":return n?t?HE:UE:t?UE:HE;case"left":case"right":return t?xP:_P;default:return[]}}function SP(e,t,n,r){const o=Bo(e);let a=wP(Cr(e),n==="start",r);return o&&(a=a.map(u=>u+"-"+o),t&&(a=a.concat(a.map(Ff)))),a}function ol(e){return e.replace(/left|right|bottom|top/g,t=>gP[t])}function AP(e){return U({top:0,right:0,bottom:0,left:0},e)}function zE(e){return typeof e!="number"?AP(e):{top:e,right:e,bottom:e,left:e}}function sl(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 jE(e,t,n){let{reference:r,floating:o}=e;const a=hr(t),u=Mf(t),c=Df(u),d=Cr(t),h=a==="y",m=r.x+r.width/2-o.width/2,E=r.y+r.height/2-o.height/2,T=r[c]/2-o[c]/2;let b;switch(d){case"top":b={x:m,y:r.y-o.height};break;case"bottom":b={x:m,y:r.y+r.height};break;case"right":b={x:r.x+r.width,y:E};break;case"left":b={x:r.x-o.width,y:E};break;default:b={x:r.x,y:r.y}}switch(Bo(t)){case"start":b[u]-=T*(n&&h?-1:1);break;case"end":b[u]+=T*(n&&h?-1:1);break}return b}const vP=(e,t,n)=>et(null,null,function*(){const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:u}=n,c=a.filter(Boolean),d=yield u.isRTL==null?void 0:u.isRTL(t);let h=yield u.getElementRects({reference:e,floating:t,strategy:o}),{x:m,y:E}=jE(h,r,d),T=r,b={},_=0;for(let w=0;w<c.length;w++){const{name:A,fn:C}=c[w],{x:I,y:R,data:F,reset:z}=yield C({x:m,y:E,initialPlacement:r,placement:T,strategy:o,middlewareData:b,rects:h,platform:u,elements:{reference:e,floating:t}});m=I!=null?I:m,E=R!=null?R:E,b=ne(U({},b),{[A]:U(U({},b[A]),F)}),z&&_<=50&&(_++,typeof z=="object"&&(z.placement&&(T=z.placement),z.rects&&(h=z.rects===!0?yield u.getElementRects({reference:e,floating:t,strategy:o}):z.rects),{x:m,y:E}=jE(h,T,d)),w=-1)}return{x:m,y:E,placement:T,strategy:o,middlewareData:b}});function oa(e,t){return et(this,null,function*(){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:u,elements:c,strategy:d}=e,{boundary:h="clippingAncestors",rootBoundary:m="viewport",elementContext:E="floating",altBoundary:T=!1,padding:b=0}=vr(t,e),_=zE(b),A=c[T?E==="floating"?"reference":"floating":E],C=sl(yield a.getClippingRect({element:(n=yield a.isElement==null?void 0:a.isElement(A))==null||n?A:A.contextElement||(yield a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:h,rootBoundary:m,strategy:d})),I=E==="floating"?{x:r,y:o,width:u.floating.width,height:u.floating.height}:u.reference,R=yield a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating),F=(yield a.isElement==null?void 0:a.isElement(R))?(yield a.getScale==null?void 0:a.getScale(R))||{x:1,y:1}:{x:1,y:1},z=sl(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:I,offsetParent:R,strategy:d}):I);return{top:(C.top-z.top+_.top)/F.y,bottom:(z.bottom-C.bottom+_.bottom)/F.y,left:(C.left-z.left+_.left)/F.x,right:(z.right-C.right+_.right)/F.x}})}const CP=e=>({name:"arrow",options:e,fn(n){return et(this,null,function*(){const{x:r,y:o,placement:a,rects:u,platform:c,elements:d,middlewareData:h}=n,{element:m,padding:E=0}=vr(e,n)||{};if(m==null)return{};const T=zE(E),b={x:r,y:o},_=Mf(a),w=Df(_),A=yield c.getDimensions(m),C=_==="y",I=C?"top":"left",R=C?"bottom":"right",F=C?"clientHeight":"clientWidth",z=u.reference[w]+u.reference[_]-b[_]-u.floating[w],D=b[_]-u.reference[_],q=yield c.getOffsetParent==null?void 0:c.getOffsetParent(m);let ce=q?q[F]:0;(!ce||!(yield c.isElement==null?void 0:c.isElement(q)))&&(ce=d.floating[F]||u.floating[w]);const be=z/2-D/2,j=ce/2-A[w]/2-1,ae=Kr(T[I],j),he=Kr(T[R],j),ge=ae,ue=ce-A[w]-he,Te=ce/2-A[w]/2+be,Ne=Pf(ge,Te,ue),fe=!h.arrow&&Bo(a)!=null&&Te!==Ne&&u.reference[w]/2-(Te<ge?ae:he)-A[w]/2<0,K=fe?Te<ge?Te-ge:Te-ue:0;return{[_]:b[_]+K,data:U({[_]:Ne,centerOffset:Te-Ne-K},fe&&{alignmentOffset:K}),reset:fe}})}}),kP=function(e){return e===void 0&&(e={}),{name:"flip",options:e,fn(n){return et(this,null,function*(){var r,o;const{placement:a,middlewareData:u,rects:c,initialPlacement:d,platform:h,elements:m}=n,Te=vr(e,n),{mainAxis:E=!0,crossAxis:T=!0,fallbackPlacements:b,fallbackStrategy:_="bestFit",fallbackAxisSideDirection:w="none",flipAlignment:A=!0}=Te,C=on(Te,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=u.arrow)!=null&&r.alignmentOffset)return{};const I=Cr(a),R=hr(d),F=Cr(d)===d,z=yield h.isRTL==null?void 0:h.isRTL(m.floating),D=b||(F||!A?[ol(d)]:bP(d)),q=w!=="none";!b&&q&&D.push(...SP(d,A,w,z));const ce=[d,...D],be=yield oa(n,C),j=[];let ae=((o=u.flip)==null?void 0:o.overflows)||[];if(E&&j.push(be[I]),T){const Ne=TP(a,c,z);j.push(be[Ne[0]],be[Ne[1]])}if(ae=[...ae,{placement:a,overflows:j}],!j.every(Ne=>Ne<=0)){var he,ge;const Ne=(((he=u.flip)==null?void 0:he.index)||0)+1,fe=ce[Ne];if(fe&&(!(T==="alignment"?R!==hr(fe):!1)||ae.every(S=>hr(S.placement)===R?S.overflows[0]>0:!0)))return{data:{index:Ne,overflows:ae},reset:{placement:fe}};let K=(ge=ae.filter(te=>te.overflows[0]<=0).sort((te,S)=>te.overflows[1]-S.overflows[1])[0])==null?void 0:ge.placement;if(!K)switch(_){case"bestFit":{var ue;const te=(ue=ae.filter(S=>{if(q){const M=hr(S.placement);return M===R||M==="y"}return!0}).map(S=>[S.placement,S.overflows.filter(M=>M>0).reduce((M,X)=>M+X,0)]).sort((S,M)=>S[1]-M[1])[0])==null?void 0:ue[0];te&&(K=te);break}case"initialPlacement":K=d;break}if(a!==K)return{reset:{placement:K}}}return{}})}}};function $E(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function VE(e){return mP.some(t=>e[t]>=0)}const NP=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return et(this,null,function*(){const{rects:r}=n,u=vr(e,n),{strategy:o="referenceHidden"}=u,a=on(u,["strategy"]);switch(o){case"referenceHidden":{const c=yield oa(n,ne(U({},a),{elementContext:"reference"})),d=$E(c,r.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:VE(d)}}}case"escaped":{const c=yield oa(n,ne(U({},a),{altBoundary:!0})),d=$E(c,r.floating);return{data:{escapedOffsets:d,escaped:VE(d)}}}default:return{}}})}}},YE=new Set(["left","top"]);function OP(e,t){return et(this,null,function*(){const{placement:n,platform:r,elements:o}=e,a=yield r.isRTL==null?void 0:r.isRTL(o.floating),u=Cr(n),c=Bo(n),d=hr(n)==="y",h=YE.has(u)?-1:1,m=a&&d?-1:1,E=vr(t,e);let{mainAxis:T,crossAxis:b,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"&&(b=c==="end"?_*-1:_),d?{x:b*m,y:T*h}:{x:T*h,y:b*m}})}const IP=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(n){return et(this,null,function*(){var r,o;const{x:a,y:u,placement:c,middlewareData:d}=n,h=yield OP(n,e);return c===((r=d.offset)==null?void 0:r.placement)&&(o=d.arrow)!=null&&o.alignmentOffset?{}:{x:a+h.x,y:u+h.y,data:ne(U({},h),{placement:c})}})}}},RP=function(e){return e===void 0&&(e={}),{name:"shift",options:e,fn(n){return et(this,null,function*(){const{x:r,y:o,placement:a}=n,C=vr(e,n),{mainAxis:u=!0,crossAxis:c=!1,limiter:d={fn:I=>{let{x:R,y:F}=I;return{x:R,y:F}}}}=C,h=on(C,["mainAxis","crossAxis","limiter"]),m={x:r,y:o},E=yield oa(n,h),T=hr(Cr(a)),b=Lf(T);let _=m[b],w=m[T];if(u){const I=b==="y"?"top":"left",R=b==="y"?"bottom":"right",F=_+E[I],z=_-E[R];_=Pf(F,_,z)}if(c){const I=T==="y"?"top":"left",R=T==="y"?"bottom":"right",F=w+E[I],z=w-E[R];w=Pf(F,w,z)}const A=d.fn(ne(U({},n),{[b]:_,[T]:w}));return ne(U({},A),{data:{x:A.x-r,y:A.y-o,enabled:{[b]:u,[T]:c}}})})}}},PP=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:u}=t,{offset:c=0,mainAxis:d=!0,crossAxis:h=!0}=vr(e,t),m={x:n,y:r},E=hr(o),T=Lf(E);let b=m[T],_=m[E];const w=vr(c,t),A=typeof w=="number"?{mainAxis:w,crossAxis:0}:U({mainAxis:0,crossAxis:0},w);if(d){const R=T==="y"?"height":"width",F=a.reference[T]-a.floating[R]+A.mainAxis,z=a.reference[T]+a.reference[R]-A.mainAxis;b<F?b=F:b>z&&(b=z)}if(h){var C,I;const R=T==="y"?"width":"height",F=YE.has(Cr(o)),z=a.reference[E]-a.floating[R]+(F&&((C=u.offset)==null?void 0:C[E])||0)+(F?0:A.crossAxis),D=a.reference[E]+a.reference[R]+(F?0:((I=u.offset)==null?void 0:I[E])||0)-(F?A.crossAxis:0);_<z?_=z:_>D&&(_=D)}return{[T]:b,[E]:_}}}},LP=function(e){return e===void 0&&(e={}),{name:"size",options:e,fn(n){return et(this,null,function*(){var r,o;const{placement:a,rects:u,platform:c,elements:d}=n,ae=vr(e,n),{apply:h=()=>{}}=ae,m=on(ae,["apply"]),E=yield oa(n,m),T=Cr(a),b=Bo(a),_=hr(a)==="y",{width:w,height:A}=u.floating;let C,I;T==="top"||T==="bottom"?(C=T,I=b===((yield c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(I=T,C=b==="end"?"top":"bottom");const R=A-E.top-E.bottom,F=w-E.left-E.right,z=Kr(A-E[C],R),D=Kr(w-E[I],F),q=!n.middlewareData.shift;let ce=z,be=D;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(be=F),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(ce=R),q&&!b){const he=wn(E.left,0),ge=wn(E.right,0),ue=wn(E.top,0),Te=wn(E.bottom,0);_?be=w-2*(he!==0||ge!==0?he+ge:wn(E.left,E.right)):ce=A-2*(ue!==0||Te!==0?ue+Te:wn(E.top,E.bottom))}yield h(ne(U({},n),{availableWidth:be,availableHeight:ce}));const j=yield c.getDimensions(d.floating);return w!==j.width||A!==j.height?{reset:{rects:!0}}:{}})}}};function al(){return typeof window!="undefined"}function Uo(e){return WE(e)?(e.nodeName||"").toLowerCase():"#document"}function Sn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function pr(e){var t;return(t=(WE(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function WE(e){return al()?e instanceof Node||e instanceof Sn(e).Node:!1}function Kn(e){return al()?e instanceof Element||e instanceof Sn(e).Element:!1}function mr(e){return al()?e instanceof HTMLElement||e instanceof Sn(e).HTMLElement:!1}function qE(e){return!al()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof Sn(e).ShadowRoot}const DP=new Set(["inline","contents"]);function sa(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!DP.has(o)}const MP=new Set(["table","td","th"]);function FP(e){return MP.has(Uo(e))}const BP=[":popover-open",":modal"];function ul(e){return BP.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const UP=["transform","translate","scale","rotate","perspective"],HP=["transform","translate","scale","rotate","perspective","filter"],zP=["paint","layout","strict","content"];function Bf(e){const t=Uf(),n=Kn(e)?Qn(e):e;return UP.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)||HP.some(r=>(n.willChange||"").includes(r))||zP.some(r=>(n.contain||"").includes(r))}function jP(e){let t=Qr(e);for(;mr(t)&&!Ho(t);){if(Bf(t))return t;if(ul(t))return null;t=Qr(t)}return null}function Uf(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const $P=new Set(["html","body","#document"]);function Ho(e){return $P.has(Uo(e))}function Qn(e){return Sn(e).getComputedStyle(e)}function ll(e){return Kn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Qr(e){if(Uo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||qE(e)&&e.host||pr(e);return qE(t)?t.host:t}function GE(e){const t=Qr(e);return Ho(t)?e.ownerDocument?e.ownerDocument.body:e.body:mr(t)&&sa(t)?t:GE(t)}function aa(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=GE(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),u=Sn(o);if(a){const c=Hf(u);return t.concat(u,u.visualViewport||[],sa(o)?o:[],c&&n?aa(c):[])}return t.concat(o,aa(o,[],n))}function Hf(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function KE(e){const t=Qn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=mr(e),a=o?e.offsetWidth:n,u=o?e.offsetHeight:r,c=rl(n)!==a||rl(r)!==u;return c&&(n=a,r=u),{width:n,height:r,$:c}}function zf(e){return Kn(e)?e:e.contextElement}function zo(e){const t=zf(e);if(!mr(t))return fr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=KE(t);let u=(a?rl(n.width):n.width)/r,c=(a?rl(n.height):n.height)/o;return(!u||!Number.isFinite(u))&&(u=1),(!c||!Number.isFinite(c))&&(c=1),{x:u,y:c}}const VP=fr(0);function QE(e){const t=Sn(e);return!Uf()||!t.visualViewport?VP:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function YP(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Sn(e)?!1:t}function zi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=zf(e);let u=fr(1);t&&(r?Kn(r)&&(u=zo(r)):u=zo(e));const c=YP(a,n,r)?QE(a):fr(0);let d=(o.left+c.x)/u.x,h=(o.top+c.y)/u.y,m=o.width/u.x,E=o.height/u.y;if(a){const T=Sn(a),b=r&&Kn(r)?Sn(r):r;let _=T,w=Hf(_);for(;w&&r&&b!==_;){const A=zo(w),C=w.getBoundingClientRect(),I=Qn(w),R=C.left+(w.clientLeft+parseFloat(I.paddingLeft))*A.x,F=C.top+(w.clientTop+parseFloat(I.paddingTop))*A.y;d*=A.x,h*=A.y,m*=A.x,E*=A.y,d+=R,h+=F,_=Sn(w),w=Hf(_)}}return sl({width:m,height:E,x:d,y:h})}function cl(e,t){const n=ll(e).scrollLeft;return t?t.left+n:zi(pr(e)).left+n}function XE(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-cl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function WP(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",u=pr(r),c=t?ul(t.floating):!1;if(r===u||c&&a)return n;let d={scrollLeft:0,scrollTop:0},h=fr(1);const m=fr(0),E=mr(r);if((E||!E&&!a)&&((Uo(r)!=="body"||sa(u))&&(d=ll(r)),mr(r))){const b=zi(r);h=zo(r),m.x=b.x+r.clientLeft,m.y=b.y+r.clientTop}const T=u&&!E&&!a?XE(u,d):fr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+m.x+T.x,y:n.y*h.y-d.scrollTop*h.y+m.y+T.y}}function qP(e){return Array.from(e.getClientRects())}function GP(e){const t=pr(e),n=ll(e),r=e.ownerDocument.body,o=wn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=wn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let u=-n.scrollLeft+cl(e);const c=-n.scrollTop;return Qn(r).direction==="rtl"&&(u+=wn(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:u,y:c}}const JE=25;function KP(e,t){const n=Sn(e),r=pr(e),o=n.visualViewport;let a=r.clientWidth,u=r.clientHeight,c=0,d=0;if(o){a=o.width,u=o.height;const m=Uf();(!m||m&&t==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const h=cl(r);if(h<=0){const m=r.ownerDocument,E=m.body,T=getComputedStyle(E),b=m.compatMode==="CSS1Compat"&&parseFloat(T.marginLeft)+parseFloat(T.marginRight)||0,_=Math.abs(r.clientWidth-E.clientWidth-b);_<=JE&&(a-=_)}else h<=JE&&(a+=h);return{width:a,height:u,x:c,y:d}}const QP=new Set(["absolute","fixed"]);function XP(e,t){const n=zi(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=mr(e)?zo(e):fr(1),u=e.clientWidth*a.x,c=e.clientHeight*a.y,d=o*a.x,h=r*a.y;return{width:u,height:c,x:d,y:h}}function ZE(e,t,n){let r;if(t==="viewport")r=KP(e,n);else if(t==="document")r=GP(pr(e));else if(Kn(t))r=XP(t,n);else{const o=QE(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return sl(r)}function ey(e,t){const n=Qr(e);return n===t||!Kn(n)||Ho(n)?!1:Qn(n).position==="fixed"||ey(n,t)}function JP(e,t){const n=t.get(e);if(n)return n;let r=aa(e,[],!1).filter(c=>Kn(c)&&Uo(c)!=="body"),o=null;const a=Qn(e).position==="fixed";let u=a?Qr(e):e;for(;Kn(u)&&!Ho(u);){const c=Qn(u),d=Bf(u);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&QP.has(o.position)||sa(u)&&!d&&ey(e,u))?r=r.filter(m=>m!==u):o=c,u=Qr(u)}return t.set(e,r),r}function ZP(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const u=[...n==="clippingAncestors"?ul(t)?[]:JP(t,this._c):[].concat(n),r],c=u[0],d=u.reduce((h,m)=>{const E=ZE(t,m,o);return h.top=wn(E.top,h.top),h.right=Kr(E.right,h.right),h.bottom=Kr(E.bottom,h.bottom),h.left=wn(E.left,h.left),h},ZE(t,c,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function eL(e){const{width:t,height:n}=KE(e);return{width:t,height:n}}function tL(e,t,n){const r=mr(t),o=pr(t),a=n==="fixed",u=zi(e,!0,a,t);let c={scrollLeft:0,scrollTop:0};const d=fr(0);function h(){d.x=cl(o)}if(r||!r&&!a)if((Uo(t)!=="body"||sa(o))&&(c=ll(t)),r){const b=zi(t,!0,a,t);d.x=b.x+t.clientLeft,d.y=b.y+t.clientTop}else o&&h();a&&!r&&o&&h();const m=o&&!r&&!a?XE(o,c):fr(0),E=u.left+c.scrollLeft-d.x-m.x,T=u.top+c.scrollTop-d.y-m.y;return{x:E,y:T,width:u.width,height:u.height}}function jf(e){return Qn(e).position==="static"}function ty(e,t){if(!mr(e)||Qn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return pr(e)===n&&(n=n.ownerDocument.body),n}function ny(e,t){const n=Sn(e);if(ul(e))return n;if(!mr(e)){let o=Qr(e);for(;o&&!Ho(o);){if(Kn(o)&&!jf(o))return o;o=Qr(o)}return n}let r=ty(e,t);for(;r&&FP(r)&&jf(r);)r=ty(r,t);return r&&Ho(r)&&jf(r)&&!Bf(r)?n:r||jP(e)||n}const nL=function(e){return et(this,null,function*(){const t=this.getOffsetParent||ny,n=this.getDimensions,r=yield n(e.floating);return{reference:tL(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function rL(e){return Qn(e).direction==="rtl"}const iL={convertOffsetParentRelativeRectToViewportRelativeRect:WP,getDocumentElement:pr,getClippingRect:ZP,getOffsetParent:ny,getElementRects:nL,getClientRects:qP,getDimensions:eL,getScale:zo,isElement:Kn,isRTL:rL};function ry(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function oL(e,t){let n=null,r;const o=pr(e);function a(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function u(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),a();const h=e.getBoundingClientRect(),{left:m,top:E,width:T,height:b}=h;if(c||t(),!T||!b)return;const _=il(E),w=il(o.clientWidth-(m+T)),A=il(o.clientHeight-(E+b)),C=il(m),R={rootMargin:-_+"px "+-w+"px "+-A+"px "+-C+"px",threshold:wn(0,Kr(1,d))||1};let F=!0;function z(D){const q=D[0].intersectionRatio;if(q!==d){if(!F)return u();q?u(!1,q):r=setTimeout(()=>{u(!1,1e-7)},1e3)}q===1&&!ry(h,e.getBoundingClientRect())&&u(),F=!1}try{n=new IntersectionObserver(z,ne(U({},R),{root:o.ownerDocument}))}catch(D){n=new IntersectionObserver(z,R)}n.observe(e)}return u(!0),a}function sL(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:u=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:d=!1}=r,h=zf(e),m=o||a?[...h?aa(h):[],...aa(t)]:[];m.forEach(C=>{o&&C.addEventListener("scroll",n,{passive:!0}),a&&C.addEventListener("resize",n)});const E=h&&c?oL(h,n):null;let T=-1,b=null;u&&(b=new ResizeObserver(C=>{let[I]=C;I&&I.target===h&&b&&(b.unobserve(t),cancelAnimationFrame(T),T=requestAnimationFrame(()=>{var R;(R=b)==null||R.observe(t)})),n()}),h&&!d&&b.observe(h),b.observe(t));let _,w=d?zi(e):null;d&&A();function A(){const C=zi(e);w&&!ry(w,C)&&n(),w=C,_=requestAnimationFrame(A)}return n(),()=>{var C;m.forEach(I=>{o&&I.removeEventListener("scroll",n),a&&I.removeEventListener("resize",n)}),E==null||E(),(C=b)==null||C.disconnect(),b=null,d&&cancelAnimationFrame(_)}}const aL=IP,uL=RP,lL=kP,cL=LP,dL=NP,fL=CP,hL=PP,pL=(e,t,n)=>{const r=new Map,o=U({platform:iL},n),a=ne(U({},o.platform),{_c:r});return vP(e,t,ne(U({},o),{platform:a}))};function iy(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 ne(U({},o),{toJSON:()=>o})}function mL(e){if(!e)return iy();const{x:t,y:n,width:r,height:o}=e;return iy(t,n,r,o)}function gL(e,t){return{contextElement:Dt(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?mL(r):n.getBoundingClientRect()}}}var ua=e=>({variable:e,reference:`var(${e})`}),kr={arrowSize:ua("--arrow-size"),arrowSizeHalf:ua("--arrow-size-half"),arrowBg:ua("--arrow-background"),transformOrigin:ua("--transform-origin"),arrowOffset:ua("--arrow-offset")},EL=e=>e==="top"||e==="bottom"?"y":"x";function yL(e,t){return{name:"transformOrigin",fn(n){var be,j,ae,he,ge;const{elements:r,middlewareData:o,placement:a,rects:u,y:c}=n,d=a.split("-")[0],h=EL(d),m=((be=o.arrow)==null?void 0:be.x)||0,E=((j=o.arrow)==null?void 0:j.y)||0,T=(t==null?void 0:t.clientWidth)||0,b=(t==null?void 0:t.clientHeight)||0,_=m+T/2,w=E+b/2,A=Math.abs(((ae=o.shift)==null?void 0:ae.y)||0),C=u.reference.height/2,I=b/2,R=(ge=(he=e.offset)==null?void 0:he.mainAxis)!=null?ge:e.gutter,F=typeof R=="number"?R+I:R!=null?R:I,z=A>F,D={top:`${_}px calc(100% + ${F}px)`,bottom:`${_}px ${-F}px`,left:`calc(100% + ${F}px) ${w}px`,right:`${-F}px ${w}px`}[d],q=`${_}px ${u.reference.y+C-c}px`,ce=!!e.overlap&&h==="y"&&z;return r.floating.style.setProperty(kr.transformOrigin.variable,ce?q:D),{data:{transformOrigin:ce?q:D}}}}}var TL={name:"rects",fn({rects:e}){return{data:e}}},bL=e=>{if(e)return{name:"shiftArrow",fn({placement:t,middlewareData:n}){if(!n.arrow)return{};const{x:r,y:o}=n.arrow,a=t.split("-")[0];return Object.assign(e.style,{left:r!=null?`${r}px`:"",top:o!=null?`${o}px`:"",[a]:`calc(100% + ${kr.arrowOffset.reference})`}),{}}}};function xL(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var _L={strategy:"absolute",placement:"bottom",listeners:!0,gutter:8,flip:!0,slide:!0,overlap:!1,sameWidth:!1,fitViewport:!1,overflowPadding:8,arrowPadding:4};function oy(e,t){const n=e.devicePixelRatio||1;return Math.round(t*n)/n}function $f(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function wL(e,t,n){const r=e||t.createElement("div");return fL({element:r,padding:n.arrowPadding})}function SL(e,t){var n;if(!UI((n=t.offset)!=null?n:t.gutter))return aL(({placement:r})=>{var m,E,T,b;const o=((e==null?void 0:e.clientHeight)||0)/2,a=(E=(m=t.offset)==null?void 0:m.mainAxis)!=null?E:t.gutter,u=typeof a=="number"?a+o:a!=null?a:o,{hasAlign:c}=xL(r),d=c?void 0:t.shift,h=(b=(T=t.offset)==null?void 0:T.crossAxis)!=null?b:d;return Ef({crossAxis:h,mainAxis:u,alignmentAxis:t.shift})})}function AL(e){if(!e.flip)return;const t=$f(e.boundary);return lL(ne(U({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function vL(e){if(!e.slide&&!e.overlap)return;const t=$f(e.boundary);return uL(ne(U({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:hL()}))}function CL(e){return cL({padding:e.overflowPadding,apply({elements:t,rects:n,availableHeight:r,availableWidth:o}){const a=t.floating,u=Math.round(n.reference.width),c=Math.round(n.reference.height);o=Math.floor(o),r=Math.floor(r),a.style.setProperty("--reference-width",`${u}px`),a.style.setProperty("--reference-height",`${c}px`),a.style.setProperty("--available-width",`${o}px`),a.style.setProperty("--available-height",`${r}px`)}})}function kL(e){var t;if(e.hideWhenDetached)return dL({strategy:"referenceHidden",boundary:(t=$f(e.boundary))!=null?t:"clippingAncestors"})}function NL(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function OL(e,t,n={}){const r=gL(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},_L,n),a=t.querySelector("[data-part=arrow]"),u=[SL(a,o),AL(o),vL(o),wL(a,t.ownerDocument,o),bL(a),yL({gutter:o.gutter,offset:o.offset,overlap:o.overlap},a),CL(o),kL(o),TL],{placement:c,strategy:d,onComplete:h,onPositioned:m}=o,E=()=>et(null,null,function*(){var F;if(!r||!t)return;const w=yield pL(r,t,{placement:c,middleware:u,strategy:d});h==null||h(w),m==null||m({placed:!0});const A=Oo(t),C=oy(A,w.x),I=oy(A,w.y);t.style.setProperty("--x",`${C}px`),t.style.setProperty("--y",`${I}px`),o.hideWhenDetached&&(((F=w.middlewareData.hide)==null?void 0:F.referenceHidden)?(t.style.setProperty("visibility","hidden"),t.style.setProperty("pointer-events","none")):(t.style.removeProperty("visibility"),t.style.removeProperty("pointer-events")));const R=t.firstElementChild;if(R){const z=Ro(R);t.style.setProperty("--z-index",z.zIndex)}}),T=()=>et(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),m==null||m({placed:!0})):yield E()}),b=NL(o.listeners),_=o.listeners?sL(r,t,T,b):GI;return T(),()=>{_==null||_(),m==null||m({placed:!1})}}function sy(e,t,n={}){const c=n,{defer:r}=c,o=on(c,["defer"]),a=r?kt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof t=="function"?t():t;u.push(OL(d,h,o))})),()=>{u.forEach(d=>d==null?void 0:d())}}var IL={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function RL(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?IL[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 jo=new WeakMap,dl=new WeakMap,fl={},Vf=0,ay=e=>e&&(e.host||ay(e.parentNode)),PL=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=ay(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),LL=new Set(["script","output","status","next-route-announcer"]),DL=e=>LL.has(e.localName)||e.role==="status"||e.hasAttribute("aria-live")?!0:e.matches("[data-live-announcer]"),ML=(e,t)=>{const{parentNode:n,markerName:r,controlAttribute:o,followControlledElements:a=!0}=t,u=PL(n,Array.isArray(e)?e:[e]);fl[r]||(fl[r]=new WeakMap);const c=fl[r],d=[],h=new Set,m=new Set(u),E=b=>{!b||h.has(b)||(h.add(b),E(b.parentNode))};u.forEach(b=>{E(b),a&&Dt(b)&&bE(b,_=>{E(_)})});const T=b=>{!b||m.has(b)||Array.prototype.forEach.call(b.children,_=>{if(h.has(_))T(_);else try{if(DL(_))return;const A=_.getAttribute(o)==="true",C=(jo.get(_)||0)+1,I=(c.get(_)||0)+1;jo.set(_,C),c.set(_,I),d.push(_),C===1&&A&&dl.set(_,!0),I===1&&_.setAttribute(r,""),A||_.setAttribute(o,"true")}catch(w){console.error("[zag-js > ariaHidden] cannot operate on ",_,w)}})};return T(n),h.clear(),Vf++,()=>{d.forEach(b=>{const _=jo.get(b)-1,w=c.get(b)-1;jo.set(b,_),c.set(b,w),_||(dl.has(b)||b.removeAttribute(o),dl.delete(b)),w||b.removeAttribute(r)}),Vf--,Vf||(jo=new WeakMap,jo=new WeakMap,dl=new WeakMap,fl={})}},FL=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,BL=(e,t=FL(e),n="data-aria-hidden",r=!0)=>{if(t)return ML(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},UL=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function uy(e,t={}){const{defer:n=!0}=t,r=n?UL:a=>a(),o=[];return o.push(r(()=>{const u=(typeof e=="function"?e():e).filter(Boolean);u.length!==0&&o.push(BL(u))})),()=>{o.forEach(a=>a==null?void 0:a())}}function HL(e){const t={each(n){var r;for(let o=0;o<((r=e.frames)==null?void 0:r.length);o+=1){const a=e.frames[o];a&&n(a)}},addEventListener(n,r,o){return t.each(a=>{try{a.document.addEventListener(n,r,o)}catch(u){}}),()=>{try{t.removeEventListener(n,r,o)}catch(a){}}},removeEventListener(n,r,o){t.each(a=>{try{a.document.removeEventListener(n,r,o)}catch(u){}})}};return t}function zL(e){const t=e.frameElement!=null?e.parent:null;return{addEventListener:(n,r,o)=>{try{t==null||t.addEventListener(n,r,o)}catch(a){}return()=>{try{t==null||t.removeEventListener(n,r,o)}catch(a){}}},removeEventListener:(n,r,o)=>{try{t==null||t.removeEventListener(n,r,o)}catch(a){}}}}var ly="pointerdown.outside",cy="focus.outside";function jL(e){for(const t of e)if(Dt(t)&&dr(t))return!0;return!1}var dy=e=>"clientY"in e;function $L(e,t){if(!dy(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 VL(e,t){return e.y<=t.y&&t.y<=e.y+e.height&&e.x<=t.x&&t.x<=e.x+e.width}function fy(e,t){if(!t||!dy(e))return!1;const n=t.scrollHeight>t.clientHeight,r=n&&e.clientX>t.offsetLeft+t.clientWidth,o=t.scrollWidth>t.clientWidth,a=o&&e.clientY>t.offsetTop+t.clientHeight,u={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 VL(u,c)?r||a:!1}function YL(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:a,defer:u,followControlledElements:c=!0}=t;if(!e)return;const d=cr(e),h=Oo(e),m=HL(h),E=zL(h);function T(R,F){if(!Dt(F)||!F.isConnected||No(e,F)||$L(e,R)||c&&TE(e,F))return!1;const z=d.querySelector(`[aria-controls="${e.id}"]`);if(z){const q=vf(z);if(fy(R,q))return!1}const D=vf(e);return fy(R,D)?!1:!(n!=null&&n(F))}const b=new Set,_=Fi(e==null?void 0:e.getRootNode());function w(R){function F(z){var be,j;const D=u&&!xE()?kt:ae=>ae(),q=z!=null?z:R,ce=(j=(be=q==null?void 0:q.composedPath)==null?void 0:be.call(q))!=null?j:[q==null?void 0:q.target];D(()=>{const ae=_?ce[0]:Gn(R);if(!(!e||!T(R,ae))){if(o||a){const he=gf(o,a);e.addEventListener(ly,he,{once:!0})}hy(e,ly,{bubbles:!1,cancelable:!0,detail:{originalEvent:q,contextmenu:NR(q),focusable:jL(ce),target:ae}})}})}R.pointerType==="touch"?(b.forEach(z=>z()),b.add(Mt(d,"click",F,{once:!0})),b.add(E.addEventListener("click",F,{once:!0})),b.add(m.addEventListener("click",F,{once:!0}))):F()}const A=new Set,C=setTimeout(()=>{A.add(Mt(d,"pointerdown",w,!0)),A.add(E.addEventListener("pointerdown",w,!0)),A.add(m.addEventListener("pointerdown",w,!0))},0);function I(R){(u?kt:z=>z())(()=>{var q,ce;const z=(ce=(q=R==null?void 0:R.composedPath)==null?void 0:q.call(R))!=null?ce:[R==null?void 0:R.target],D=_?z[0]:Gn(R);if(!(!e||!T(R,D))){if(r||a){const be=gf(r,a);e.addEventListener(cy,be,{once:!0})}hy(e,cy,{bubbles:!1,cancelable:!0,detail:{originalEvent:R,contextmenu:!1,focusable:dr(D),target:D}})}})}return xE()||(A.add(Mt(d,"focusin",I,!0)),A.add(E.addEventListener("focusin",I,!0)),A.add(m.addEventListener("focusin",I,!0))),()=>{clearTimeout(C),b.forEach(R=>R()),A.forEach(R=>R())}}function WL(e,t){const{defer:n}=t,r=n?kt:a=>a(),o=[];return o.push(r(()=>{const a=typeof e=="function"?e():e;o.push(YL(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}function hy(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function qL(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return Mt(cr(e),"keydown",n,{capture:!0})}var py="layer:request-dismiss",Dn={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=>No(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>No(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=>Dn.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];KL(e,py,o=>{var a;(a=r.requestDismiss)==null||a.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),GL(e,py,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function GL(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 KL(e,t,n){e.addEventListener(t,n,{once:!0})}var my;function gy(){Dn.layers.forEach(({node:e})=>{e.style.pointerEvents=Dn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function QL(e){e.style.pointerEvents=""}function XL(e,t){const n=cr(e),r=[];return Dn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(my=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[a,u]=JR(()=>{const c=o();return Dt(c)?c:null},{timeout:1e3});a.then(c=>r.push(Ju(c,{pointerEvents:"auto"}))),r.push(u)}),()=>{Dn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=my,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function JL(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){yf("[@zag-js/dismissable] node is `null` or `undefined`");return}if(!e)return;const{onDismiss:r,onRequestDismiss:o,pointerBlocking:a,exclude:u,debug:c,type:d="dialog"}=t,h={dismiss:r,node:e,type:d,pointerBlocking:a,requestDismiss:o};Dn.add(h),gy();function m(w){var C,I;const A=Gn(w.detail.originalEvent);Dn.isBelowPointerBlockingLayer(e)||Dn.isInBranch(A)||((C=t.onPointerDownOutside)==null||C.call(t,w),(I=t.onInteractOutside)==null||I.call(t,w),!w.defaultPrevented&&(c&&console.log("onPointerDownOutside:",w.detail.originalEvent),r==null||r()))}function E(w){var C,I;const A=Gn(w.detail.originalEvent);Dn.isInBranch(A)||((C=t.onFocusOutside)==null||C.call(t,w),(I=t.onInteractOutside)==null||I.call(t,w),!w.defaultPrevented&&(c&&console.log("onFocusOutside:",w.detail.originalEvent),r==null||r()))}function T(w){var A;Dn.isTopMost(e)&&((A=t.onEscapeKeyDown)==null||A.call(t,w),!w.defaultPrevented&&r&&(w.preventDefault(),r()))}function b(w){var R;if(!e)return!1;const A=typeof u=="function"?u():u,C=Array.isArray(A)?A:[A],I=(R=t.persistentElements)==null?void 0:R.map(F=>F()).filter(Dt);return I&&C.push(...I),C.some(F=>No(F,w))||Dn.isInNestedLayer(e,w)}const _=[a?XL(e,t.persistentElements):void 0,qL(e,T),WL(e,{exclude:b,onFocusOutside:E,onPointerDownOutside:m,defer:t.defer})];return()=>{Dn.remove(e),gy(),QL(e),_.forEach(w=>w==null?void 0:w())}}function Ey(e,t){const{defer:n}=t,r=n?kt:a=>a(),o=[];return o.push(r(()=>{const a=Co(e)?e():e;o.push(JL(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}var ZL=Object.defineProperty,e6=(e,t,n)=>t in e?ZL(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ht=(e,t,n)=>e6(e,typeof t!="symbol"?t+"":t,n),yy={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()}},t6=[],n6=class{constructor(e,t){ht(this,"trapStack"),ht(this,"config"),ht(this,"doc"),ht(this,"state",{containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0}),ht(this,"portalContainers",new Set),ht(this,"listenerCleanups",[]),ht(this,"handleFocus",r=>{const o=Gn(r),a=this.findContainerIndex(o,r)>=0;if(a||Gu(o))a&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let u,c=!0;if(this.state.mostRecentlyFocusedNode)if(na(this.state.mostRecentlyFocusedNode)>0){const d=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:h}=this.state.containerGroups[d];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&&(u=h[m+1],c=!1):m-1>=0&&(u=h[m-1],c=!1))}}else this.state.containerGroups.some(d=>d.tabbableNodes.some(h=>na(h)>0))||(c=!1);else c=!1;c&&(u=this.findNextNavNode({target:this.state.mostRecentlyFocusedNode,isBackward:this.config.isKeyBackward(this.state.recentNavEvent)})),u?this.tryFocus(u):this.tryFocus(this.state.mostRecentlyFocusedNode||this.getInitialFocusNode())}this.state.recentNavEvent=void 0}),ht(this,"handlePointerDown",r=>{const o=Gn(r);if(!(this.findContainerIndex(o,r)>=0)){if(ca(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}ca(this.config.allowOutsideClick,r)||r.preventDefault()}}),ht(this,"handleClick",r=>{const o=Gn(r);this.findContainerIndex(o,r)>=0||ca(this.config.clickOutsideDeactivates,r)||ca(this.config.allowOutsideClick,r)||(r.preventDefault(),r.stopImmediatePropagation())}),ht(this,"handleTabKey",r=>{if(this.config.isKeyForward(r)||this.config.isKeyBackward(r)){this.state.recentNavEvent=r;const o=this.config.isKeyBackward(r),a=this.findNextNavNode({event:r,isBackward:o});if(!a)return;la(r)&&r.preventDefault(),this.tryFocus(a)}}),ht(this,"handleEscapeKey",r=>{r6(r)&&ca(this.config.escapeDeactivates,r)!==!1&&(r.preventDefault(),this.deactivate())}),ht(this,"_mutationObserver"),ht(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(d=>{if(d.nodeType!==Node.ELEMENT_NODE)return!1;const h=d;return bR(h)?!0:h.id&&!this.state.containers.some(m=>m.contains(h))?xR(h):!1}):!1)&&this.state.active&&!this.state.paused&&(this.updateTabbableNodes(),this.updatePortalContainers())})}),ht(this,"updateObservedNodes",()=>{var r;(r=this._mutationObserver)==null||r.disconnect(),this.state.active&&!this.state.paused&&(this.state.containers.map(o=>{var a;(a=this._mutationObserver)==null||a.observe(o,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}),this.portalContainers.forEach(o=>{this.observePortalContainer(o)}))}),ht(this,"getInitialFocusNode",()=>{let r=this.getNodeForOption("initialFocus",{hasFallback:!0});if(r===!1)return!1;if(r===void 0||r&&!dr(r)){const o=Io(this.doc);if(o&&this.findContainerIndex(o)>=0)r=o;else{const a=this.state.tabbableGroups[0];r=a&&a.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}),ht(this,"tryFocus",r=>{if(r!==!1&&r!==Io(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,i6(r)&&r.select()}}),ht(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(),yy.deactivateTrap(this.trapStack,this),this.portalContainers.clear();const a=this.getOption(o,"onDeactivate"),u=this.getOption(o,"onPostDeactivate"),c=this.getOption(o,"checkCanReturnFocus"),d=this.getOption(o,"returnFocus","returnFocusOnDeactivate");a==null||a();const h=()=>{Ty(()=>{if(d){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(m)}u==null||u()})};if(d&&c){const m=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);return c(m).then(h,h),this}return h(),this}),ht(this,"pause",r=>{if(this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onPause"),a=this.getOption(r,"onPostPause");return this.state.paused=!0,o==null||o(),this.removeListeners(),this.updateObservedNodes(),a==null||a(),this}),ht(this,"unpause",r=>{if(!this.state.paused||!this.state.active)return this;const o=this.getOption(r,"onUnpause"),a=this.getOption(r,"onPostUnpause");return this.state.paused=!1,o==null||o(),this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),a==null||a(),this}),ht(this,"updateContainerElements",r=>(this.state.containers=Array.isArray(r)?r.filter(Boolean):[r].filter(Boolean),this.state.active&&this.updateTabbableNodes(),this.updateObservedNodes(),this)),ht(this,"getReturnFocusNode",r=>{const o=this.getNodeForOption("setReturnFocus",{params:[r]});return o||(o===!1?!1:r)}),ht(this,"getOption",(r,o,a)=>r&&r[o]!==void 0?r[o]:this.config[a||o]),ht(this,"getNodeForOption",(r,{hasFallback:o=!1,params:a=[]}={})=>{let u=this.config[r];if(typeof u=="function"&&(u=u(...a)),u===!0&&(u=void 0),!u){if(u===void 0||u===!1)return u;throw new Error(`\`${r}\` was specified but was not a node, or did not return a node`)}let c=u;if(typeof u=="string"){try{c=this.doc.querySelector(u)}catch(d){throw new Error(`\`${r}\` appears to be an invalid selector; error="${d.message}"`)}if(!c&&!o)throw new Error(`\`${r}\` as selector refers to no known node`)}return c}),ht(this,"findNextNavNode",r=>{const{event:o,isBackward:a=!1}=r,u=r.target||Gn(o);this.updateTabbableNodes();let c=null;if(this.state.tabbableGroups.length>0){const d=this.findContainerIndex(u,o),h=d>=0?this.state.containerGroups[d]:void 0;if(d<0)a?c=this.state.tabbableGroups[this.state.tabbableGroups.length-1].lastTabbableNode:c=this.state.tabbableGroups[0].firstTabbableNode;else if(a){let m=this.state.tabbableGroups.findIndex(({firstTabbableNode:E})=>u===E);if(m<0&&((h==null?void 0:h.container)===u||dr(u)&&!Bi(u)&&!(h!=null&&h.nextTabbableNode(u,!1)))&&(m=d),m>=0){const E=m===0?this.state.tabbableGroups.length-1:m-1,T=this.state.tabbableGroups[E];c=na(u)>=0?T.lastTabbableNode:T.lastDomTabbableNode}else la(o)||(c=h==null?void 0:h.nextTabbableNode(u,!1))}else{let m=this.state.tabbableGroups.findIndex(({lastTabbableNode:E})=>u===E);if(m<0&&((h==null?void 0:h.container)===u||dr(u)&&!Bi(u)&&!(h!=null&&h.nextTabbableNode(u)))&&(m=d),m>=0){const E=m===this.state.tabbableGroups.length-1?0:m+1,T=this.state.tabbableGroups[E];c=na(u)>=0?T.firstTabbableNode:T.firstDomTabbableNode}else la(o)||(c=h==null?void 0:h.nextTabbableNode(u))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||t6;const n=U({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return la(r)&&!r.shiftKey},isKeyBackward(r){return la(r)&&r.shiftKey}},t);this.doc=n.document||cr(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=>{ER(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(a=>a===e)||this.isControlledElement(r,e))}isControlledElement(e,t){return this.config.followControlledElements?TE(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Po(e,{getShadowRoot:this.config.getShadowRoot}),n=kE(e,{getShadowRoot:this.config.getShadowRoot}),r=t[0],o=t[t.length-1],a=r,u=o;let c=!1;for(let h=0;h<t.length;h++)if(na(t[h])>0){c=!0;break}function d(h,m=!0){const E=t.indexOf(h);if(E>=0)return t[E+(m?1:-1)];const T=n.indexOf(h);if(!(T<0)){if(m){for(let b=T+1;b<n.length;b++)if(Bi(n[b]))return n[b]}else for(let b=T-1;b>=0;b--)if(Bi(n[b]))return n[b]}}return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:c,firstTabbableNode:r,lastTabbableNode:o,firstDomTabbableNode:a,lastDomTabbableNode:u,nextTabbableNode:d}}),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 yy.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Ty(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(Mt(this.doc,"focusin",this.handleFocus,!0),Mt(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),Mt(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),Mt(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),Mt(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),Mt(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=Io(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)}},la=e=>e.key==="Tab",ca=(e,...t)=>typeof e=="function"?e(...t):e,r6=e=>!e.isComposing&&e.key==="Escape",Ty=e=>setTimeout(e,0),i6=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function by(e,t={}){let n;const r=kt(()=>{const o=typeof e=="function"?e():e;if(o){n=new n6(o,ne(U({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:cr(o)}));try{n.activate()}catch(a){}}});return function(){n==null||n.deactivate(),r()}}var Yf="data-scroll-lock";function o6(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function xy(e){const t=Ro(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function _y(e){var b;const t=e!=null?e:document,n=(b=t.defaultView)!=null?b:window,{documentElement:r,body:o}=t;if(o.hasAttribute(Yf))return;const u=xy(r)||xy(o),c=n.innerWidth-r.clientWidth;o.setAttribute(Yf,"");const d=()=>QR(r,"--scrollbar-width",`${c}px`),h=o6(r),m=()=>{const _={overflow:"hidden"};return!u&&c>0&&(_[h]=`${c}px`),Ju(o,_)},E=()=>{var z,D;const{scrollX:_,scrollY:w,visualViewport:A}=n,C=(z=A==null?void 0:A.offsetLeft)!=null?z:0,I=(D=A==null?void 0:A.offsetTop)!=null?D:0,R={position:"fixed",overflow:"hidden",top:`${-(w-Math.floor(I))}px`,left:`${-(_-Math.floor(C))}px`,right:"0"};!u&&c>0&&(R[h]=`${c}px`);const F=Ju(o,R);return()=>{F==null||F(),n.scrollTo({left:_,top:w,behavior:"instant"})}},T=[d(),Ku()?E():m()];return()=>{T.forEach(_=>_==null?void 0:_()),o.removeAttribute(Yf)}}var s6=Hi("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),gr=s6.build(),wy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},Sy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},Wf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},Ay=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},a6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},qf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},Gf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},u6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},vy=e=>e.getById(wy(e)),$o=e=>e.getById(Sy(e)),Vo=e=>e.getById(Wf(e)),Cy=e=>e.getById(Ay(e)),l6=e=>e.getById(qf(e)),c6=e=>e.getById(Gf(e));function d6(e,t){const{state:n,context:r,send:o,computed:a,prop:u,scope:c}=e,d=n.matches("open"),h=r.get("currentPlacement"),m=a("currentPortalled"),E=r.get("renderedElements"),T=RL(ne(U({},u("positioning")),{placement:h}));return{portalled:m,open:d,setOpen(b){n.matches("open")!==b&&o({type:b?"OPEN":"CLOSE"})},reposition(b={}){o({type:"POSITIONING.SET",options:b})},getArrowProps(){return t.element(ne(U({id:a6(c)},gr.arrow.attrs),{dir:u("dir"),style:T.arrow}))},getArrowTipProps(){return t.element(ne(U({},gr.arrowTip.attrs),{dir:u("dir"),style:T.arrowTip}))},getAnchorProps(){return t.element(ne(U({},gr.anchor.attrs),{dir:u("dir"),id:wy(c)}))},getTriggerProps(){return t.button(ne(U({},gr.trigger.attrs),{dir:u("dir"),type:"button","data-placement":h,id:Sy(c),"aria-haspopup":"dialog","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":Wf(c),onPointerDown(b){_E(b)&&CR()&&b.currentTarget.focus()},onClick(b){b.defaultPrevented||o({type:"TOGGLE"})},onBlur(b){o({type:"TRIGGER_BLUR",target:b.relatedTarget})}}))},getIndicatorProps(){return t.element(ne(U({},gr.indicator.attrs),{dir:u("dir"),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ne(U({id:Ay(c)},gr.positioner.attrs),{dir:u("dir"),style:T.floating}))},getContentProps(){return t.element(ne(U({},gr.content.attrs),{dir:u("dir"),id:Wf(c),tabIndex:-1,role:"dialog","aria-modal":gE(u("modal")),hidden:!d,"data-state":d?"open":"closed","data-expanded":ko(d),"aria-labelledby":E.title?qf(c):void 0,"aria-describedby":E.description?Gf(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(ne(U({},gr.title.attrs),{id:qf(c),dir:u("dir")}))},getDescriptionProps(){return t.element(ne(U({},gr.description.attrs),{id:Gf(c),dir:u("dir")}))},getCloseTriggerProps(){return t.button(ne(U({},gr.closeTrigger.attrs),{dir:u("dir"),id:u6(c),type:"button","aria-label":"close",onClick(b){b.defaultPrevented||(b.stopPropagation(),o({type:"CLOSE"}))}}))}}}var f6={props({props:e}){return ne(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 a;e.set("currentPlacement",t("positioning").placement);const r=(a=vy(n))!=null?a:$o(n);return sy(r,()=>Cy(n),ne(U({},t("positioning")),{defer:!0,onComplete(u){e.set("currentPlacement",u.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Vo(n);let o=!0;return Ey(r,{type:"popover",pointerBlocking:t("modal"),exclude:$o(n),defer:!0,onEscapeKeyDown(a){var u;(u=t("onEscapeKeyDown"))==null||u(a),!t("closeOnEscape")&&a.preventDefault()},onInteractOutside(a){var u;(u=t("onInteractOutside"))==null||u(a),!a.defaultPrevented&&(o=!(a.detail.focusable||a.detail.contextmenu),t("closeOnInteractOutside")||a.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:GR(()=>Vo(t),{triggerElement:$o(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?uy(()=>[Vo(t),$o(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return _y(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?by(()=>Vo(t),{initialFocus:()=>NE({root:Vo(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")}),getShadowRoot:!0}):void 0}},actions:{reposition({event:e,prop:t,scope:n,context:r}){var u;const o=(u=vy(n))!=null?u:$o(n);sy(o,()=>Cy(n),ne(U(U({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){kt(()=>{Object.assign(e.get("renderedElements"),{title:!!l6(t),description:!!c6(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||kt(()=>{const n=NE({root:Vo(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||kt(()=>{const a=$o(t);a==null||a.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})}}}};Mo()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[pF,hl]=Ui({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[mF,Kf]=Ui({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),h6=e=>{const t=ee.useId(),{getRootNode:n}=hl(),{dir:r}=Kf(),o=U({id:t,dir:r,getRootNode:n},e),a=el(f6,o);return d6(a,Nf)},p6=e=>{const[t,u]=BE(e),c=u,{children:n}=c,r=on(c,["children"]),o=h6(r),a=Rf(Nt({present:o.open},t));return L.jsx(lP,{value:o,children:L.jsx(DE,{value:a,children:n})})},ky=ee.forwardRef((e,t)=>{const n=If(),r=ra(),o=Nt(ne(U({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return L.jsx(Gt.button,ne(U({},o),{ref:t}))});ky.displayName="PopoverTrigger";function m6(e){return ln({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 g6(e){return ln({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 E6(e){return ln({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0"},child:[]}]})(e)}function y6(e){return ln({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708"},child:[]}]})(e)}function T6(e){return ln({attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M9.5 13a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"},child:[]}]})(e)}const Ny=({className:e,componentType:t,children:n})=>{const[r,o]=ee.useState(!1),{globalClassName:a}=en(),u=h=>{o(h.open)},c=ee.useCallback(()=>{o(!1)},[]),d=ee.useMemo(()=>({closeMenu:c}),[c]);return L.jsxs(p6,{open:r,onOpenChange:u,positioning:{placement:"bottom-end"},children:[L.jsx(ky,{"aria-label":`Overflow menu for ${t}`,className:oe(`${J}-overflow-menu-button-trigger`,`${J}-icon-button`,a,e,`cim-${t}-component`),children:L.jsx(T6,{})}),L.jsx(FE,{children:L.jsx(ME,{className:oe(`${J}-overflow-menu-list`,a,`cim-${t}-component`),children:L.jsx(lE.Provider,{value:d,children:n})})})]})};function Oy(e){return ln({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 Iy(e){return ln({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[b6,ji]=Ui({name:"CarouselContext",hookName:"useCarouselContext",providerName:"<CarouselProvider />"}),Ry=ee.forwardRef((e,t)=>{const n=ji(),r=Nt(n.getControlProps(),e);return L.jsx(Gt.div,ne(U(U({},r),e),{ref:t}))});Ry.displayName="CarouselControl";const Py=ee.forwardRef((e,t)=>{const[n,r]=ia()(e,["readOnly","index"]),o=ji(),a=Nt(o.getIndicatorProps(n),r);return L.jsx(Gt.button,ne(U({},a),{ref:t}))});Py.displayName="CarouselIndicator";const Ly=ee.forwardRef((e,t)=>{const n=ji(),r=Nt(n.getIndicatorGroupProps(),e);return L.jsx(Gt.div,ne(U({},r),{ref:t}))});Ly.displayName="CarouselIndicatorGroup";const Dy=ee.forwardRef((e,t)=>{const[n,r]=ia()(e,["index","snapAlign"]),o=ji(),a=Nt(o.getItemProps(n),r);return L.jsx(Gt.div,ne(U({},a),{ref:t}))});Dy.displayName="CarouselItem";const My=ee.forwardRef((e,t)=>{const n=ji(),r=Nt(n.getItemGroupProps(),e);return L.jsx(Gt.div,ne(U({},r),{ref:t}))});My.displayName="CarouselItemGroup";const Fy=ee.forwardRef((e,t)=>{const n=ji(),r=Nt(n.getNextTriggerProps(),e);return L.jsx(Gt.button,ne(U({},r),{ref:t}))});Fy.displayName="CarouselNextTrigger";const By=ee.forwardRef((e,t)=>{const n=ji(),r=Nt(n.getPrevTriggerProps(),e);return L.jsx(Gt.button,ne(U({},r),{ref:t}))});By.displayName="CarouselPrevTrigger";function x6(e){const t=Ro(e),n=e.getBoundingClientRect();let r=t.getPropertyValue("scroll-padding-left").replace("auto","0px"),o=t.getPropertyValue("scroll-padding-top").replace("auto","0px"),a=t.getPropertyValue("scroll-padding-right").replace("auto","0px"),u=t.getPropertyValue("scroll-padding-bottom").replace("auto","0px");function c(T,b){let _=parseFloat(T);return/%/.test(T)&&(_/=100,_*=b),Number.isNaN(_)?0:_}let d=c(r,n.width),h=c(o,n.height),m=c(a,n.width),E=c(u,n.height);return{x:{before:d,after:m},y:{before:h,after:E}}}function _6(e,t,n="both"){return n==="x"&&e.right>=t.left&&e.left<=t.right||n==="y"&&e.bottom>=t.top&&e.top<=t.bottom||n==="both"&&e.right>=t.left&&e.left<=t.right&&e.bottom>=t.top&&e.top<=t.bottom}function Uy(e){let t=[];for(const n of e.children)t=t.concat(n,Uy(n));return t}function Hy(e,t=!1){const n=e.getBoundingClientRect(),r={x:{start:[],center:[],end:[]},y:{start:[],center:[],end:[]}},o=t?Uy(e):e.children;for(const a of["x","y"]){const u=a==="x"?"y":"x",c=a==="x"?"left":"top",d=a==="x"?"width":"height",h=a==="x"?"scrollLeft":"scrollTop";for(const m of o){const E=m.getBoundingClientRect();if(!_6(n,E,u))continue;const T=Ro(m);let[b,_]=T.getPropertyValue("scroll-snap-align").split(" ");typeof _=="undefined"&&(_=b);const w=a==="x"?_:b,A=E[c]-n[c]+e[h];switch(w){case"none":break;case"start":r[a].start.push({node:m,position:A});break;case"center":r[a].center.push({node:m,position:A+E[d]/2});break;case"end":r[a].end.push({node:m,position:A+E[d]});break}}}return r}function zy(e){const t=e.getBoundingClientRect(),n=x6(e),r=Hy(e),o={x:e.scrollWidth-e.offsetWidth,y:e.scrollHeight-e.offsetHeight};return{x:jy([...r.x.start.map(a=>a.position-n.x.before),...r.x.center.map(a=>a.position-t.width/2),...r.x.end.map(a=>a.position-t.width+n.x.after)].map($y(0,o.x))),y:jy([...r.y.start.map(a=>a.position-n.y.before),...r.y.center.map(a=>a.position-t.height/2),...r.y.end.map(a=>a.position-t.height+n.y.after)].map($y(0,o.y)))}}function w6(e,t,n){const r=Hy(e),o=[...r[t].start,...r[t].center,...r[t].end];for(const a of o)if(n(a.node))return a.position}var jy=e=>[...new Set(e)],$y=(e,t)=>n=>Math.max(e,Math.min(t,n)),S6=Hi("carousel").parts("root","itemGroup","item","control","nextTrigger","prevTrigger","indicatorGroup","indicator","autoplayTrigger"),Nr=S6.build(),A6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.root)!=null?n:`carousel:${e.id}`},v6=(e,t)=>{var n,r,o;return(o=(r=(n=e.ids)==null?void 0:n.item)==null?void 0:r.call(n,t))!=null?o:`carousel:${e.id}:item:${t}`},pl=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.itemGroup)!=null?n:`carousel:${e.id}:item-group`},C6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.nextTrigger)!=null?n:`carousel:${e.id}:next-trigger`},k6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.prevTrigger)!=null?n:`carousel:${e.id}:prev-trigger`},N6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.indicatorGroup)!=null?n:`carousel:${e.id}:indicator-group`},Vy=(e,t)=>{var n,r,o;return(o=(r=(n=e.ids)==null?void 0:n.indicator)==null?void 0:r.call(n,t))!=null?o:`carousel:${e.id}:indicator:${t}`},hn=e=>e.getById(pl(e)),Yy=e=>KR(hn(e),"[data-part=item]"),O6=(e,t)=>e.getById(Vy(e,t)),Wy=e=>{const t=hn(e);if(!t)return;const n=Po(t);t.setAttribute("tabindex",n.length>0?"-1":"0")};function I6(e,t){const{state:n,context:r,computed:o,send:a,scope:u,prop:c}=e,d=n.matches("autoplay"),h=n.matches("dragging"),m=o("canScrollNext"),E=o("canScrollPrev"),T=o("isHorizontal"),b=Array.from(r.get("pageSnapPoints")),_=r.get("page"),w=c("slidesPerPage"),A=c("padding"),C=c("translations");return{isPlaying:d,isDragging:h,page:_,pageSnapPoints:b,canScrollNext:m,canScrollPrev:E,getProgress(){return _/b.length},scrollToIndex(I,R){a({type:"INDEX.SET",index:I,instant:R})},scrollTo(I,R){a({type:"PAGE.SET",index:I,instant:R})},scrollNext(I){a({type:"PAGE.NEXT",instant:I})},scrollPrev(I){a({type:"PAGE.PREV",instant:I})},play(){a({type:"AUTOPLAY.START"})},pause(){a({type:"AUTOPLAY.PAUSE"})},isInView(I){return Array.from(r.get("slidesInView")).includes(I)},refresh(){a({type:"SNAP.REFRESH"})},getRootProps(){return t.element(ne(U({},Nr.root.attrs),{id:A6(u),role:"region","aria-roledescription":"carousel","data-orientation":c("orientation"),dir:c("dir"),style:{"--slides-per-page":w,"--slide-spacing":c("spacing"),"--slide-item-size":"calc(100% / var(--slides-per-page) - var(--slide-spacing) * (var(--slides-per-page) - 1) / var(--slides-per-page))"}}))},getItemGroupProps(){return t.element(ne(U({},Nr.itemGroup.attrs),{id:pl(u),"data-orientation":c("orientation"),"data-dragging":ko(h),dir:c("dir"),"aria-live":d?"off":"polite",onFocus(I){No(I.currentTarget,Gn(I))&&a({type:"VIEWPORT.FOCUS"})},onBlur(I){No(I.currentTarget,I.relatedTarget)||a({type:"VIEWPORT.BLUR"})},onMouseDown(I){if(I.defaultPrevented||!c("allowMouseDrag")||!_E(I))return;const R=Gn(I);dr(R)&&R!==I.currentTarget||(I.preventDefault(),a({type:"DRAGGING.START"}))},onWheel:KI(I=>{const R=c("orientation")==="horizontal"?"deltaX":"deltaY";I[R]<0&&!o("canScrollPrev")||I[R]>0&&!o("canScrollNext")||a({type:"USER.SCROLL"})},150),onTouchStart(){a({type:"USER.SCROLL"})},style:{display:"grid",gap:"var(--slide-spacing)",scrollSnapType:[T?"x":"y",c("snapType")].join(" "),gridAutoFlow:T?"column":"row",scrollbarWidth:"none",overscrollBehaviorX:"contain",[T?"gridAutoColumns":"gridAutoRows"]:"var(--slide-item-size)",[T?"scrollPaddingInline":"scrollPaddingBlock"]:A,[T?"paddingInline":"paddingBlock"]:A,[T?"overflowX":"overflowY"]:"auto"}}))},getItemProps(I){const R=r.get("slidesInView").includes(I.index);return t.element(ne(U({},Nr.item.attrs),{id:v6(u,I.index),dir:c("dir"),role:"group","data-index":I.index,"data-inview":ko(R),"aria-roledescription":"slide","data-orientation":c("orientation"),"aria-label":C.item(I.index,c("slideCount")),"aria-hidden":gE(!R),style:{scrollSnapAlign:(()=>{var ce;const F=(ce=I.snapAlign)!=null?ce:"start",z=c("slidesPerMove"),D=z==="auto"?Math.floor(c("slidesPerPage")):z;return(I.index+D)%D===0?F:void 0})()}}))},getControlProps(){return t.element(ne(U({},Nr.control.attrs),{"data-orientation":c("orientation")}))},getPrevTriggerProps(){return t.button(ne(U({},Nr.prevTrigger.attrs),{id:k6(u),type:"button",disabled:!E,dir:c("dir"),"aria-label":C.prevTrigger,"data-orientation":c("orientation"),"aria-controls":pl(u),onClick(I){I.defaultPrevented||a({type:"PAGE.PREV",src:"trigger"})}}))},getNextTriggerProps(){return t.button(ne(U({},Nr.nextTrigger.attrs),{dir:c("dir"),id:C6(u),type:"button","aria-label":C.nextTrigger,"data-orientation":c("orientation"),"aria-controls":pl(u),disabled:!m,onClick(I){I.defaultPrevented||a({type:"PAGE.NEXT",src:"trigger"})}}))},getIndicatorGroupProps(){return t.element(ne(U({},Nr.indicatorGroup.attrs),{dir:c("dir"),id:N6(u),"data-orientation":c("orientation"),onKeyDown(I){if(I.defaultPrevented)return;const R="indicator",F={ArrowDown(q){T||(a({type:"PAGE.NEXT",src:R}),q.preventDefault())},ArrowUp(q){T||(a({type:"PAGE.PREV",src:R}),q.preventDefault())},ArrowRight(q){T&&(a({type:"PAGE.NEXT",src:R}),q.preventDefault())},ArrowLeft(q){T&&(a({type:"PAGE.PREV",src:R}),q.preventDefault())},Home(q){a({type:"PAGE.SET",index:0,src:R}),q.preventDefault()},End(q){a({type:"PAGE.SET",index:b.length-1,src:R}),q.preventDefault()}},z=RR(I,{dir:c("dir"),orientation:c("orientation")}),D=F[z];D==null||D(I)}}))},getIndicatorProps(I){return t.button(ne(U({},Nr.indicator.attrs),{dir:c("dir"),id:Vy(u,I.index),type:"button","data-orientation":c("orientation"),"data-index":I.index,"data-readonly":ko(I.readOnly),"data-current":ko(I.index===_),"aria-label":C.indicator(I.index),onClick(R){R.defaultPrevented||I.readOnly||a({type:"PAGE.SET",index:I.index,src:"indicator"})}}))},getAutoplayTriggerProps(){return t.button(ne(U({},Nr.autoplayTrigger.attrs),{type:"button","data-orientation":c("orientation"),"data-pressed":ko(d),"aria-label":d?C.autoplayStop:C.autoplayStart,onClick(I){I.defaultPrevented||a({type:d?"AUTOPLAY.PAUSE":"AUTOPLAY.START"})}}))}}}var R6={props({props:e}){return tR(e,["slideCount"],"carousel"),ne(U({dir:"ltr",defaultPage:0,orientation:"horizontal",snapType:"mandatory",loop:!!e.autoplay,slidesPerPage:1,slidesPerMove:"auto",spacing:"0px",autoplay:!1,allowMouseDrag:!1,inViewThreshold:.6},e),{translations:U({nextTrigger:"Next slide",prevTrigger:"Previous slide",indicator:t=>`Go to slide ${t+1}`,item:(t,n)=>`${t+1} of ${n}`,autoplayStart:"Start slide rotation",autoplayStop:"Stop slide rotation"},e.translations)})},refs(){return{timeoutRef:void 0}},initialState({prop:e}){return e("autoplay")?"autoplay":"idle"},context({prop:e,bindable:t,getContext:n}){return{page:t(()=>({defaultValue:e("defaultPage"),value:e("page"),onChange(r){var u;const a=n().get("pageSnapPoints");(u=e("onPageChange"))==null||u({page:r,pageSnapPoint:a[r]})}})),pageSnapPoints:t(()=>({defaultValue:P6(e("slideCount"),e("slidesPerMove"),e("slidesPerPage"))})),slidesInView:t(()=>({defaultValue:[]}))}},computed:{isRtl:({prop:e})=>e("dir")==="rtl",isHorizontal:({prop:e})=>e("orientation")==="horizontal",canScrollNext:({prop:e,context:t})=>e("loop")||t.get("page")<t.get("pageSnapPoints").length-1,canScrollPrev:({prop:e,context:t})=>e("loop")||t.get("page")>0,autoplayInterval:({prop:e})=>{const t=e("autoplay");return BI(t)?t.delay:4e3}},watch({track:e,action:t,context:n,prop:r,send:o}){e([()=>r("slidesPerPage"),()=>r("slidesPerMove")],()=>{t(["setSnapPoints"])}),e([()=>n.get("page")],()=>{t(["scrollToPage","focusIndicatorEl"])}),e([()=>r("orientation")],()=>{t(["setSnapPoints","scrollToPage"])}),e([()=>r("slideCount")],()=>{o({type:"SNAP.REFRESH",src:"slide.count"})}),e([()=>!!r("autoplay")],()=>{o({type:r("autoplay")?"AUTOPLAY.START":"AUTOPLAY.PAUSE",src:"autoplay.prop.change"})})},on:{"PAGE.NEXT":{target:"idle",actions:["clearScrollEndTimer","setNextPage"]},"PAGE.PREV":{target:"idle",actions:["clearScrollEndTimer","setPrevPage"]},"PAGE.SET":{target:"idle",actions:["clearScrollEndTimer","setPage"]},"INDEX.SET":{target:"idle",actions:["clearScrollEndTimer","setMatchingPage"]},"SNAP.REFRESH":{actions:["setSnapPoints","clampPage"]},"PAGE.SCROLL":{actions:["scrollToPage"]}},effects:["trackSlideMutation","trackSlideIntersections","trackSlideResize"],entry:["setSnapPoints","setPage"],exit:["clearScrollEndTimer"],states:{idle:{on:{"DRAGGING.START":{target:"dragging",actions:["invokeDragStart"]},"AUTOPLAY.START":{target:"autoplay",actions:["invokeAutoplayStart"]},"USER.SCROLL":{target:"userScroll"},"VIEWPORT.FOCUS":{target:"focus"}}},focus:{effects:["trackKeyboardScroll"],on:{"VIEWPORT.BLUR":{target:"idle"},"PAGE.NEXT":{actions:["clearScrollEndTimer","setNextPage"]},"PAGE.PREV":{actions:["clearScrollEndTimer","setPrevPage"]},"PAGE.SET":{actions:["clearScrollEndTimer","setPage"]},"INDEX.SET":{actions:["clearScrollEndTimer","setMatchingPage"]},"USER.SCROLL":{target:"userScroll"}}},dragging:{effects:["trackPointerMove"],entry:["disableScrollSnap"],on:{DRAGGING:{actions:["scrollSlides","invokeDragging"]},"DRAGGING.END":{target:"idle",actions:["endDragging","invokeDraggingEnd"]}}},userScroll:{effects:["trackScroll"],on:{"SCROLL.END":[{guard:"isFocused",target:"focus",actions:["setClosestPage"]},{target:"idle",actions:["setClosestPage"]}]}},autoplay:{effects:["trackDocumentVisibility","trackScroll","autoUpdateSlide"],exit:["invokeAutoplayEnd"],on:{"AUTOPLAY.TICK":{actions:["setNextPage","invokeAutoplay"]},"DRAGGING.START":{target:"dragging",actions:["invokeDragStart"]},"AUTOPLAY.PAUSE":{target:"idle"}}}},implementations:{guards:{isFocused:({scope:e})=>e.isActiveElement(hn(e))},effects:{autoUpdateSlide({computed:e,send:t}){const n=setInterval(()=>{t({type:e("canScrollNext")?"AUTOPLAY.TICK":"AUTOPLAY.PAUSE",src:"autoplay.interval"})},e("autoplayInterval"));return()=>clearInterval(n)},trackSlideMutation({scope:e,send:t}){const n=hn(e);if(!n)return;const r=e.getWin(),o=new r.MutationObserver(()=>{t({type:"SNAP.REFRESH",src:"slide.mutation"}),Wy(e)});return Wy(e),o.observe(n,{childList:!0,subtree:!0}),()=>o.disconnect()},trackSlideResize({scope:e,send:t}){if(!hn(e))return;const r=e.getWin(),o=()=>{t({type:"SNAP.REFRESH",src:"slide.resize"})};kt(()=>{o(),kt(()=>{t({type:"PAGE.SCROLL",instant:!0})})});const a=new r.ResizeObserver(o);return Yy(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackSlideIntersections({scope:e,prop:t,context:n}){const r=hn(e),o=e.getWin(),a=new o.IntersectionObserver(u=>{const c=u.reduce((d,h)=>{var T;const m=h.target,E=Number((T=m.dataset.index)!=null?T:"-1");return E==null||Number.isNaN(E)||E===-1?d:h.isIntersecting?PI(d,E):LI(d,E)},n.get("slidesInView"));n.set("slidesInView",DI(c))},{root:r,threshold:t("inViewThreshold")});return Yy(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackScroll({send:e,refs:t,scope:n}){const r=hn(n);return r?Mt(r,"scroll",()=>{clearTimeout(t.get("timeoutRef")),t.set("timeoutRef",void 0),t.set("timeoutRef",setTimeout(()=>{e({type:"SCROLL.END"})},150))},{passive:!0}):void 0},trackDocumentVisibility({scope:e,send:t}){const n=e.getDoc();return Mt(n,"visibilitychange",()=>{n.visibilityState!=="visible"&&t({type:"AUTOPLAY.PAUSE",src:"doc.hidden"})})},trackPointerMove({scope:e,send:t}){const n=e.getDoc();return WR(n,{onPointerMove({event:r}){t({type:"DRAGGING",left:-r.movementX,top:-r.movementY})},onPointerUp(){t({type:"DRAGGING.END"})}})},trackKeyboardScroll({scope:e,send:t,context:n}){const r=e.getWin();return Mt(r,"keydown",a=>{switch(a.key){case"ArrowRight":a.preventDefault(),t({type:"PAGE.NEXT"});break;case"ArrowLeft":a.preventDefault(),t({type:"PAGE.PREV"});break;case"Home":a.preventDefault(),t({type:"PAGE.SET",index:0});break;case"End":a.preventDefault(),t({type:"PAGE.SET",index:n.get("pageSnapPoints").length-1})}},{capture:!0})}},actions:{clearScrollEndTimer({refs:e}){e.get("timeoutRef")!=null&&(clearTimeout(e.get("timeoutRef")),e.set("timeoutRef",void 0))},scrollToPage({context:e,event:t,scope:n,computed:r,flush:o}){var h;const a=t.instant?"instant":"smooth",u=pE((h=t.index)!=null?h:e.get("page"),0,e.get("pageSnapPoints").length-1),c=hn(n);if(!c)return;const d=r("isHorizontal")?"left":"top";o(()=>{c.scrollTo({[d]:e.get("pageSnapPoints")[u],behavior:a})})},setClosestPage({context:e,scope:t,computed:n}){const r=hn(t);if(!r)return;const o=n("isHorizontal")?r.scrollLeft:r.scrollTop,a=e.get("pageSnapPoints").findIndex(u=>Math.abs(u-o)<1);a!==-1&&e.set("page",a)},setNextPage({context:e,prop:t,state:n}){const r=n.matches("autoplay")||t("loop"),o=dE(e.get("pageSnapPoints"),e.get("page"),{loop:r});e.set("page",o)},setPrevPage({context:e,prop:t,state:n}){const r=n.matches("autoplay")||t("loop"),o=MI(e.get("pageSnapPoints"),e.get("page"),{loop:r});e.set("page",o)},setMatchingPage({context:e,event:t,computed:n,scope:r}){const o=hn(r);if(!o)return;const a=w6(o,n("isHorizontal")?"x":"y",c=>c.dataset.index===t.index.toString());if(a==null)return;const u=e.get("pageSnapPoints").findIndex(c=>Math.abs(c-a)<1);e.set("page",u)},setPage({context:e,event:t}){var r;const n=(r=t.index)!=null?r:e.get("page");e.set("page",n)},clampPage({context:e}){const t=pE(e.get("page"),0,e.get("pageSnapPoints").length-1);e.set("page",t)},setSnapPoints({context:e,computed:t,scope:n}){const r=hn(n);if(!r)return;const o=zy(r);e.set("pageSnapPoints",t("isHorizontal")?o.x:o.y)},disableScrollSnap({scope:e}){const t=hn(e);if(!t)return;const n=getComputedStyle(t);t.dataset.scrollSnapType=n.getPropertyValue("scroll-snap-type"),t.style.setProperty("scroll-snap-type","none")},scrollSlides({scope:e,event:t}){const n=hn(e);n==null||n.scrollBy({left:t.left,top:t.top,behavior:"instant"})},endDragging({scope:e,context:t,computed:n}){const r=hn(e);if(!r)return;const o=r.scrollLeft,a=r.scrollTop,u=zy(r),c=u.x.reduce((h,m)=>Math.abs(m-o)<Math.abs(h-o)?m:h,u.x[0]),d=u.y.reduce((h,m)=>Math.abs(m-a)<Math.abs(h-a)?m:h,u.y[0]);kt(()=>{r.scrollTo({left:c,top:d,behavior:"smooth"});const h=n("isHorizontal")?c:d;t.set("page",t.get("pageSnapPoints").indexOf(h));const m=r.dataset.scrollSnapType;m&&(r.style.setProperty("scroll-snap-type",m),delete r.dataset.scrollSnapType)})},focusIndicatorEl({context:e,event:t,scope:n}){if(t.src!=="indicator")return;const r=O6(n,e.get("page"));r&&kt(()=>r.focus({preventScroll:!0}))},invokeDragStart({context:e,prop:t}){var n;(n=t("onDragStatusChange"))==null||n({type:"dragging.start",isDragging:!0,page:e.get("page")})},invokeDragging({context:e,prop:t}){var n;(n=t("onDragStatusChange"))==null||n({type:"dragging",isDragging:!0,page:e.get("page")})},invokeDraggingEnd({context:e,prop:t}){var n;(n=t("onDragStatusChange"))==null||n({type:"dragging.end",isDragging:!1,page:e.get("page")})},invokeAutoplay({context:e,prop:t}){var n;(n=t("onAutoplayStatusChange"))==null||n({type:"autoplay",isPlaying:!0,page:e.get("page")})},invokeAutoplayStart({context:e,prop:t}){var n;(n=t("onAutoplayStatusChange"))==null||n({type:"autoplay.start",isPlaying:!0,page:e.get("page")})},invokeAutoplayEnd({context:e,prop:t}){var n;(n=t("onAutoplayStatusChange"))==null||n({type:"autoplay.stop",isPlaying:!1,page:e.get("page")})}}}};function P6(e,t,n){if(e==null||n<=0)return[];const r=[],o=t==="auto"?Math.floor(n):t;if(o<=0)return[];for(let a=0;a<e&&!(a+n>e);a+=o)r.push(a);return r}Mo()(["dir","getRootNode","id","ids","loop","page","defaultPage","onPageChange","orientation","slideCount","slidesPerPage","slidesPerMove","spacing","padding","autoplay","allowMouseDrag","inViewThreshold","translations","snapType","onDragStatusChange","onAutoplayStatusChange"]),Mo()(["index","readOnly"]),Mo()(["index","snapAlign"]);const L6=e=>{const t=ee.useId(),{getRootNode:n}=hl(),{dir:r}=Kf(),o=U({id:t,dir:r,getRootNode:n},e),a=el(R6,o);return I6(a,Nf)},qy=ee.forwardRef((e,t)=>{const[n,r]=ia()(e,["allowMouseDrag","autoplay","defaultPage","id","ids","inViewThreshold","loop","onAutoplayStatusChange","onDragStatusChange","onPageChange","orientation","padding","page","slideCount","slidesPerMove","slidesPerPage","snapType","spacing","translations"]),o=L6(n),a=Nt(o.getRootProps(),r);return L.jsx(b6,{value:o,children:L.jsx(Gt.div,ne(U({},a),{ref:t}))})});qy.displayName="CarouselRoot";const D6=180,M6=e=>{const t=e.trim(),n=parseFloat(t);return Number.isNaN(n)?0:t.endsWith("rem")?n*16:n},F6=({globalClassName:e,className:t,itemMinWidth:n=D6,spacing:r="0.5rem",loop:o=!1,allowMouseDrag:a=!0,showIndicators:u=!0,showNavigation:c=!0,onPageChange:d,ariaLabel:h="Product carousel",children:m})=>{const E=Array.from(m),T=E.length,b=ee.useRef(null),[_,w]=ee.useState(0),{width:A}=CS();ee.useLayoutEffect(()=>{b.current&&w(b.current.getBoundingClientRect().width)},[A,T]);const C=M6(r),I=n+C,R=_>0?(_+C)/I:1,F=Math.max(1,Math.floor(R));if(T===0)return null;const z=T>F,D=Math.ceil(T/F),q=z?Math.max(1,R):F;return L.jsxs(qy,{ref:b,className:oe(e,t,`${J}-carousel`),slidesPerPage:q,slidesPerMove:F,spacing:r,loop:o,allowMouseDrag:a,slideCount:T,onPageChange:d,"aria-label":h,children:[L.jsx(My,{className:oe(e,`${J}-carousel__item-group`,{"carousel-row-container":!z}),children:E.map((ce,be)=>L.jsx(Dy,{index:be,className:oe(e,`${J}-carousel__item`),children:ce},be))}),c&&z&&L.jsxs(Ry,{className:oe(e,`${J}-carousel__control`),children:[L.jsx(By,{className:oe(e,`${J}-carousel__prev-trigger`),"aria-label":"Previous slide",children:L.jsx(E6,{})}),L.jsx(Fy,{className:oe(e,`${J}-carousel__next-trigger`),"aria-label":"Next slide",children:L.jsx(y6,{})})]}),u&&z&&L.jsx(Ly,{className:oe(e,`${J}-carousel__indicator-group`),children:Array.from({length:D},(ce,be)=>L.jsx(Py,{index:be,className:oe(e,`${J}-carousel__indicator`),"aria-label":`Go to slide group ${be+1}`},be))})]})},B6=({className:e,label:t="Close",onClick:n,disabled:r=!1})=>L.jsx("button",{"aria-label":t,className:oe(e,`${J}-close-button`),disabled:r,onClick:n,children:L.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:L.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"})})}),[U6,H6]=Ui({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),z6=e=>ia()(e,["lazyMount","unmountOnExit"]),[j6,da]=Ui({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),Gy=ee.forwardRef((e,t)=>{const n=da(),r=H6(),o=Rf(ne(U({},r),{present:n.open})),a=Nt(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:L.jsx(Gt.div,ne(U({},a),{ref:tl(o.ref,t)}))});Gy.displayName="DialogBackdrop";const Qf=ee.forwardRef((e,t)=>{const n=da(),r=ra(),o=Nt(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:L.jsx(Gt.div,ne(U({},o),{ref:tl(r.ref,t)}))});Qf.displayName="DialogContent";const Xf=ee.forwardRef((e,t)=>{const n=da(),r=Nt(n.getDescriptionProps(),e);return L.jsx(Gt.div,ne(U({},r),{ref:t}))});Xf.displayName="DialogDescription";const Jf=ee.forwardRef((e,t)=>{const n=da(),r=Nt(n.getPositionerProps(),e);return ra().unmounted?null:L.jsx(Gt.div,ne(U({},r),{ref:t}))});Jf.displayName="DialogPositioner";var $6=Hi("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),$i=$6.build(),Ky=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},Qy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},Zf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},Xy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},eh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`dialog:${e.id}:title`},th=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`dialog:${e.id}:description`},Jy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},ml=e=>e.getById(Zf(e)),V6=e=>e.getById(Ky(e)),Y6=e=>e.getById(Qy(e)),W6=e=>e.getById(Xy(e)),q6=e=>e.getById(eh(e)),G6=e=>e.getById(th(e)),K6=e=>e.getById(Jy(e));function Q6(e,t){const{state:n,send:r,context:o,prop:a,scope:u}=e,c=a("aria-label"),d=n.matches("open");return{open:d,setOpen(h){n.matches("open")!==h&&r({type:h?"OPEN":"CLOSE"})},getTriggerProps(){return t.button(ne(U({},$i.trigger.attrs),{dir:a("dir"),id:Xy(u),"aria-haspopup":"dialog",type:"button","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":Zf(u),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(ne(U({},$i.backdrop.attrs),{dir:a("dir"),hidden:!d,id:Qy(u),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ne(U({},$i.positioner.attrs),{dir:a("dir"),id:Ky(u),style:{pointerEvents:d?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(ne(U({},$i.content.attrs),{dir:a("dir"),role:a("role"),hidden:!d,id:Zf(u),tabIndex:-1,"data-state":d?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:eh(u),"aria-describedby":h.description?th(u):void 0}))},getTitleProps(){return t.element(ne(U({},$i.title.attrs),{dir:a("dir"),id:eh(u)}))},getDescriptionProps(){return t.element(ne(U({},$i.description.attrs),{dir:a("dir"),id:th(u)}))},getCloseTriggerProps(){return t.button(ne(U({},$i.closeTrigger.attrs),{dir:a("dir"),id:Jy(u),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var X6={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>K6(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 Ey(()=>ml(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[W6(e)],onInteractOutside(o){var a;(a=n("onInteractOutside"))==null||a(o),n("closeOnInteractOutside")||o.preventDefault()},persistentElements:n("persistentElements"),onFocusOutside:n("onFocusOutside"),onPointerDownOutside:n("onPointerDownOutside"),onRequestDismiss:n("onRequestDismiss"),onEscapeKeyDown(o){var a;(a=n("onEscapeKeyDown"))==null||a(o),n("closeOnEscape")||o.preventDefault()},onDismiss(){t({type:"CLOSE",src:"interact-outside"})}})},preventScroll({scope:e,prop:t}){if(t("preventScroll"))return _y(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?by(()=>ml(e),{preventScroll:!0,returnFocusOnDeactivate:!!t("restoreFocus"),initialFocus:t("initialFocusEl"),setReturnFocus:r=>{var o,a;return(a=(o=t("finalFocusEl"))==null?void 0:o())!=null?a:r},getShadowRoot:!0}):void 0},hideContentBelow({scope:e,prop:t}){return t("modal")?uy(()=>[ml(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){kt(()=>{e.set("rendered",{title:!!q6(t),description:!!G6(t)})})},syncZIndex({scope:e}){kt(()=>{const t=ml(e);if(!t)return;const n=Ro(t);[V6(e),Y6(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})}}}};Mo()(["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 J6=e=>{const t=ee.useId(),{getRootNode:n}=hl(),{dir:r}=Kf(),o=U({id:t,getRootNode:n,dir:r},e),a=el(X6,o);return Q6(a,Nf)},Zy=e=>{const[t,c]=BE(e),d=c,{children:n}=d,r=on(d,["children"]),[o]=z6(t),a=J6(r),u=Rf(Nt({present:a.open},t));return L.jsx(j6,{value:a,children:L.jsx(U6,{value:o,children:L.jsx(DE,{value:u,children:n})})})},eT=ee.forwardRef((e,t)=>{const n=da(),r=Nt(n.getTitleProps(),e);return L.jsx(Gt.h2,ne(U({},r),{ref:t}))});eT.displayName="DialogTitle";const Z6=({componentType:e,isIcon:t})=>{const{globalClassName:n}=en(),{previousComponentType:r}=Ci(),o=ea(),a=()=>{Tu(r||"dialog"),o()};return t?L.jsx(jr,{className:oe(n,`${J}-toggle-dialog-button`,`cim-${e}-component`),ariaLabel:"Toggle Dialog",onClick:a,icon:L.jsx(Oy,{})}):L.jsxs("button",{className:oe(n,`${J}-overflow-menu-button`,`${J}-toggle-dialog-button`,`cim-${e}-component`),onClick:a,children:[L.jsx(Oy,{}),"Show ",r||"dialog"]})},e4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=en(),{isModalFullscreen:r}=Ci(),o=ea(),a=()=>{dd(!r),o()},u=r?KS:QS,c="Toggle Fullscreen";return t?L.jsx(jr,{ariaLabel:c,title:c,className:oe(n,`${J}-modal-fullscreen-button`,`cim-${e}-component`),icon:L.jsx(u,{}),onClick:a}):L.jsxs("button",{className:oe(n,`${J}-overflow-menu-button`,`${J}-modal-fullscreen-button`,`cim-${e}-component`),onClick:a,children:[L.jsx(u,{}),c]})},t4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=en(),{dialogPosition:r}=Ci(),o=ea(),a=r==="bottom-left",u=()=>{fd(a?"bottom-right":"bottom-left"),o()},c=a?g6:m6,d=a?"Move right":"Move left";return t?L.jsx(jr,{className:oe(n,`${J}-left-right-toggle-button`,`cim-${e}-component`),ariaLabel:d,onClick:u,icon:L.jsx(c,{})}):L.jsxs("button",{className:oe(n,`${J}-overflow-menu-button`,`${J}-left-right-toggle-button`,`cim-${e}-component`),onClick:u,children:[L.jsx(c,{}),d]})},tT=({componentType:e,onClearChat:t,onClose:n})=>{const{headerConfig:r,globalClassName:o}=en(),{mode:a}=Ci(),u=a==="standalone",c=e==="modal",d=c?Z6:nT,h=c?e4:t4,m=ee.useMemo(()=>r?qS(r):{},[r]);return L.jsxs("div",{className:oe(o,`${J}-${e}-header`,{standalone:u,embedded:!u}),style:m,children:[(r==null?void 0:r.logoUrl)&&L.jsx("img",{alt:"",role:"img",className:oe(o,`${J}-${e}-logo`,{standalone:u,embedded:!u}),src:r.logoUrl}),L.jsx(eT,{className:oe(o,`${J}-${e}-title`,{standalone:u,embedded:!u}),children:r==null?void 0:r.headerText}),L.jsxs("div",{className:oe(o,`${J}-${e}-controls`),children:[L.jsx(d,{componentType:e,isIcon:!0}),L.jsxs(Ny,{componentType:e,children:[L.jsx(h,{componentType:e}),L.jsx(r4,{componentType:e}),L.jsx(cE,{componentType:e,onClearChat:t})]}),L.jsx(B6,{className:oe(o,`cim-${e}-component`),onClick:n})]})]})},n4=({className:e,globalClassName:t,suggestions:n,disabled:r,isWidgetStandalone:o,onSuggestionClick:a})=>{const u=o?"standalone":"embedded",c=d=>()=>{a(d)};return L.jsx("div",{className:oe(t,`${J}-suggestion-container ${u}`,e),children:n.map(d=>o?L.jsx(x0,{disabled:r,className:oe(t,`${J}-suggestion-button standalone`),onClick:c(d),children:d},d):L.jsx("button",{disabled:r,className:oe(t,`${J}-suggestion-button embedded`),onClick:c(d),children:d},d))})},r4=({componentType:e,isIcon:t})=>{const{globalClassName:n,enableMinimize:r}=en();if(!r)return null;const o=()=>{vi(!1),yu(!0)};return t?L.jsx(jr,{className:oe(n,`${J}-toggle-minimize-button`,`cim-${e}-component`),ariaLabel:"Toggle Minimize",title:"Minimize",onClick:o,icon:L.jsx(T0,{})}):L.jsxs("button",{className:oe(n,`${J}-overflow-menu-button`,`${J}-toggle-minimize-button`,`cim-${e}-component`),onClick:o,children:[L.jsx(T0,{}),"Minimize"]})},nT=({componentType:e,isIcon:t})=>{const{globalClassName:n}=en(),r=ea(),o=()=>{Tu("modal"),r()};return t?L.jsx(jr,{className:oe(n,`${J}-toggle-modal-button`,`cim-${e}-component`),ariaLabel:"Toggle Modal",onClick:o,icon:L.jsx(Iy,{})}):L.jsxs("button",{className:oe(n,`${J}-overflow-menu-button`,`${J}-toggle-modal-button`,`cim-${e}-component`),onClick:o,children:[L.jsx(Iy,{}),"Show modal"]})};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 i4(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function o4(e,t,n){const o=Ru((n||{}).ignore||[]),a=s4(t);let u=-1;for(;++u<a.length;)Rg(e,"text",c);function c(h,m){let E=-1,T;for(;++E<m.length;){const b=m[E],_=T?T.children:void 0;if(o(b,_?_.indexOf(b):void 0,T))return;T=b}if(T)return d(h,m)}function d(h,m){const E=m[m.length-1],T=a[u][0],b=a[u][1];let _=0;const A=E.children.indexOf(h);let C=!1,I=[];T.lastIndex=0;let R=T.exec(h.value);for(;R;){const F=R.index,z={index:R.index,input:R.input,stack:[...m,h]};let D=b(...R,z);if(typeof D=="string"&&(D=D.length>0?{type:"text",value:D}:void 0),D===!1?T.lastIndex=F+1:(_!==F&&I.push({type:"text",value:h.value.slice(_,F)}),Array.isArray(D)?I.push(...D):D&&I.push(D),_=F+R[0].length,C=!0),!T.global)break;R=T.exec(h.value)}return C?(_<h.value.length&&I.push({type:"text",value:h.value.slice(_)}),E.children.splice(A,1,...I)):I=[h],A+I.length}}function s4(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([a4(o[0]),u4(o[1])])}return t}function a4(e){return typeof e=="string"?new RegExp(i4(e),"g"):e}function u4(e){return typeof e=="function"?e:function(){return e}}const nh="phrasing",rh=["autolink","link","image","label"];function l4(){return{transforms:[g4],enter:{literalAutolink:d4,literalAutolinkEmail:ih,literalAutolinkHttp:ih,literalAutolinkWww:ih},exit:{literalAutolink:m4,literalAutolinkEmail:p4,literalAutolinkHttp:f4,literalAutolinkWww:h4}}}function c4(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:nh,notInConstruct:rh},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:nh,notInConstruct:rh},{character:":",before:"[ps]",after:"\\/",inConstruct:nh,notInConstruct:rh}]}}function d4(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function ih(e){this.config.enter.autolinkProtocol.call(this,e)}function f4(e){this.config.exit.autolinkProtocol.call(this,e)}function h4(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 p4(e){this.config.exit.autolinkEmail.call(this,e)}function m4(e){this.exit(e)}function g4(e){o4(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,E4],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),y4]],{ignore:["link","linkReference"]})}function E4(e,t,n,r,o){let a="";if(!iT(o)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!T4(n)))return!1;const u=b4(n+r);if(!u[0])return!1;const c={type:"link",title:null,url:a+t+u[0],children:[{type:"text",value:t+u[0]}]};return u[1]?[c,{type:"text",value:u[1]}]:c}function y4(e,t,n,r){return!iT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function T4(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 b4(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 a=rT(e,")");for(;r!==-1&&o>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),a++;return[e,n]}function iT(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Oi(n)||Au(n))&&(!t||n!==47)}oT.peek=N4;function x4(){this.buffer()}function _4(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function w4(){this.buffer()}function S4(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function A4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Wn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function v4(e){this.exit(e)}function C4(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Wn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function k4(e){this.exit(e)}function N4(){return"["}function oT(e,t,n,r){const o=n.createTracker(r);let a=o.move("[^");const u=n.enter("footnoteReference"),c=n.enter("reference");return a+=o.move(n.safe(n.associationId(e),{after:"]",before:a})),c(),u(),a+=o.move("]"),a}function O4(){return{enter:{gfmFootnoteCallString:x4,gfmFootnoteCall:_4,gfmFootnoteDefinitionLabelString:w4,gfmFootnoteDefinition:S4},exit:{gfmFootnoteCallString:A4,gfmFootnoteCall:v4,gfmFootnoteDefinitionLabelString:C4,gfmFootnoteDefinition:k4}}}function I4(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:oT},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,o,a,u){const c=a.createTracker(u);let d=c.move("[^");const h=a.enter("footnoteDefinition"),m=a.enter("label");return d+=c.move(a.safe(a.associationId(r),{before:d,after:"]"})),m(),d+=c.move("]:"),r.children&&r.children.length>0&&(c.shift(4),d+=c.move((t?`
38
+ `:" ")+a.indentLines(a.containerFlow(r,c.current()),t?sT:R4))),h(),d}}function R4(e,t,n){return t===0?e:sT(e,t,n)}function sT(e,t,n){return(n?"":" ")+e}const P4=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];aT.peek=B4;function L4(){return{canContainEols:["delete"],enter:{strikethrough:M4},exit:{strikethrough:F4}}}function D4(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:P4}],handlers:{delete:aT}}}function M4(e){this.enter({type:"delete",children:[]},e)}function F4(e){this.exit(e)}function aT(e,t,n,r){const o=n.createTracker(r),a=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,ne(U({},o.current()),{before:u,after:"~"})),u+=o.move("~~"),a(),u}function B4(){return"~"}function U4(e){return e.length}function H4(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||U4,a=[],u=[],c=[],d=[];let h=0,m=-1;for(;++m<e.length;){const w=[],A=[];let C=-1;for(e[m].length>h&&(h=e[m].length);++C<e[m].length;){const I=z4(e[m][C]);if(n.alignDelimiters!==!1){const R=o(I);A[C]=R,(d[C]===void 0||R>d[C])&&(d[C]=R)}w.push(I)}u[m]=w,c[m]=A}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)a[E]=uT(r[E]);else{const w=uT(r);for(;++E<h;)a[E]=w}E=-1;const T=[],b=[];for(;++E<h;){const w=a[E];let A="",C="";w===99?(A=":",C=":"):w===108?A=":":w===114&&(C=":");let I=n.alignDelimiters===!1?1:Math.max(1,d[E]-A.length-C.length);const R=A+"-".repeat(I)+C;n.alignDelimiters!==!1&&(I=A.length+I+C.length,I>d[E]&&(d[E]=I),b[E]=I),T[E]=R}u.splice(1,0,T),c.splice(1,0,b),m=-1;const _=[];for(;++m<u.length;){const w=u[m],A=c[m];E=-1;const C=[];for(;++E<h;){const I=w[E]||"";let R="",F="";if(n.alignDelimiters!==!1){const z=d[E]-(A[E]||0),D=a[E];D===114?R=" ".repeat(z):D===99?z%2?(R=" ".repeat(z/2+.5),F=" ".repeat(z/2-.5)):(R=" ".repeat(z/2),F=R):F=" ".repeat(z)}n.delimiterStart!==!1&&!E&&C.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&I==="")&&(n.delimiterStart!==!1||E)&&C.push(" "),n.alignDelimiters!==!1&&C.push(R),C.push(I),n.alignDelimiters!==!1&&C.push(F),n.padding!==!1&&C.push(" "),(n.delimiterEnd!==!1||E!==h-1)&&C.push("|")}_.push(n.delimiterEnd===!1?C.join("").replace(/ +$/,""):C.join(""))}return _.join(`
39
+ `)}function z4(e){return e==null?"":String(e)}function uT(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 j4(e,t,n,r){const o=n.enter("blockquote"),a=n.createTracker(r);a.move("> "),a.shift(2);const u=n.indentLines(n.containerFlow(e,a.current()),$4);return o(),u}function $4(e,t,n){return">"+(n?"":" ")+e}function V4(e,t){return lT(e,t.inConstruct,!0)&&!lT(e,t.notInConstruct,!1)}function lT(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 cT(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if(n.unsafe[o].character===`
40
+ `&&V4(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return`\\
41
+ `}function Y4(e,t){const n=String(e);let r=n.indexOf(t),o=r,a=0,u=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===o?++a>u&&(u=a):a=1,o=r+t.length,r=n.indexOf(t,o);return u}function W4(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 q4(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 G4(e,t,n,r){const o=q4(n),a=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(W4(e,n)){const E=n.enter("codeIndented"),T=n.indentLines(a,K4);return E(),T}const c=n.createTracker(r),d=o.repeat(Math.max(Y4(a,o)+1,3)),h=n.enter("codeFenced");let m=c.move(d);if(e.lang){const E=n.enter(`codeFencedLang${u}`);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${u}`);m+=c.move(" "),m+=c.move(n.safe(e.meta,U({before:m,after:`
42
+ `,encode:["`"]},c.current()))),E()}return m+=c.move(`
43
43
  `),a&&(m+=c.move(a+`
44
- `)),m+=c.move(d),h(),m}function O4(e,t,n){return(n?"":" ")+e}function th(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 I4(e,t,n,r){const o=th(n),a=o==='"'?"Quote":"Apostrophe",u=n.enter("definition");let c=n.enter("label");const d=n.createTracker(r);let h=d.move("[");return h+=d.move(n.safe(n.associationId(e),U({before:h,after:"]"},d.current()))),h+=d.move("]: "),c(),!e.url||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=d.move("<"),h+=d.move(n.safe(e.url,U({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,U({before:h,after:e.title?" ":`
45
- `},d.current())))),c(),e.title&&(c=n.enter(`title${a}`),h+=d.move(" "+o),h+=d.move(n.safe(e.title,U({before:h,after:o},d.current()))),h+=d.move(o),c()),u(),h}function R4(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 da(e){return"&#x"+e.toString(16).toUpperCase()+";"}function ml(e,t,n){const r=yo(e),o=yo(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}}aT.peek=P4;function aT(e,t,n,r){const o=R4(n),a=n.enter("emphasis"),u=n.createTracker(r),c=u.move(o);let d=u.move(n.containerPhrasing(e,U({after:o,before:c},u.current())));const h=d.charCodeAt(0),m=ml(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(d=da(h)+d.slice(1));const g=d.charCodeAt(d.length-1),T=ml(r.after.charCodeAt(0),g,o);T.inside&&(d=d.slice(0,-1)+da(g));const b=u.move(o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:m.outside},c+d+b}function P4(e,t,n){return n.options.emphasis||"*"}function L4(e,t){let n=!1;return Lu(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Bd}),!!((!e.depth||e.depth<3)&&Cd(e)&&(t.options.setext||n))}function D4(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(L4(e,n)){const m=n.enter("headingSetext"),g=n.enter("phrasing"),T=n.containerPhrasing(e,ne(U({},a.current()),{before:`
44
+ `)),m+=c.move(d),h(),m}function K4(e,t,n){return(n?"":" ")+e}function oh(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 Q4(e,t,n,r){const o=oh(n),a=o==='"'?"Quote":"Apostrophe",u=n.enter("definition");let c=n.enter("label");const d=n.createTracker(r);let h=d.move("[");return h+=d.move(n.safe(n.associationId(e),U({before:h,after:"]"},d.current()))),h+=d.move("]: "),c(),!e.url||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=d.move("<"),h+=d.move(n.safe(e.url,U({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,U({before:h,after:e.title?" ":`
45
+ `},d.current())))),c(),e.title&&(c=n.enter(`title${a}`),h+=d.move(" "+o),h+=d.move(n.safe(e.title,U({before:h,after:o},d.current()))),h+=d.move(o),c()),u(),h}function X4(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 fa(e){return"&#x"+e.toString(16).toUpperCase()+";"}function gl(e,t,n){const r=yo(e),o=yo(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}}dT.peek=J4;function dT(e,t,n,r){const o=X4(n),a=n.enter("emphasis"),u=n.createTracker(r),c=u.move(o);let d=u.move(n.containerPhrasing(e,U({after:o,before:c},u.current())));const h=d.charCodeAt(0),m=gl(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(d=fa(h)+d.slice(1));const E=d.charCodeAt(d.length-1),T=gl(r.after.charCodeAt(0),E,o);T.inside&&(d=d.slice(0,-1)+fa(E));const b=u.move(o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:m.outside},c+d+b}function J4(e,t,n){return n.options.emphasis||"*"}function Z4(e,t){let n=!1;return Lu(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Bd}),!!((!e.depth||e.depth<3)&&Cd(e)&&(t.options.setext||n))}function eD(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(Z4(e,n)){const m=n.enter("headingSetext"),E=n.enter("phrasing"),T=n.containerPhrasing(e,ne(U({},a.current()),{before:`
46
46
  `,after:`
47
- `}));return g(),m(),T+`
47
+ `}));return E(),m(),T+`
48
48
  `+(o===1?"=":"-").repeat(T.length-(Math.max(T.lastIndexOf("\r"),T.lastIndexOf(`
49
49
  `))+1))}const u="#".repeat(o),c=n.enter("headingAtx"),d=n.enter("phrasing");a.move(u+" ");let h=n.containerPhrasing(e,U({before:"# ",after:`
50
- `},a.current()));return/^[\t ]/.test(h)&&(h=da(h.charCodeAt(0))+h.slice(1)),h=h?u+" "+h:u,n.options.closeAtx&&(h+=" "+u),d(),c(),h}uT.peek=M4;function uT(e){return e.value||""}function M4(){return"<"}lT.peek=F4;function lT(e,t,n,r){const o=th(n),a=o==='"'?"Quote":"Apostrophe",u=n.enter("image");let c=n.enter("label");const d=n.createTracker(r);let h=d.move("![");return h+=d.move(n.safe(e.alt,U({before:h,after:"]"},d.current()))),h+=d.move("]("),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=d.move("<"),h+=d.move(n.safe(e.url,U({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},d.current())))),c(),e.title&&(c=n.enter(`title${a}`),h+=d.move(" "+o),h+=d.move(n.safe(e.title,U({before:h,after:o},d.current()))),h+=d.move(o),c()),h+=d.move(")"),u(),h}function F4(){return"!"}cT.peek=B4;function cT(e,t,n,r){const o=e.referenceType,a=n.enter("imageReference");let u=n.enter("label");const c=n.createTracker(r);let d=c.move("![");const h=n.safe(e.alt,U({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const g=n.safe(n.associationId(e),U({before:d,after:"]"},c.current()));return u(),n.stack=m,a(),o==="full"||!h||h!==g?d+=c.move(g+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function B4(){return"!"}dT.peek=U4;function dT(e,t,n){let r=e.value||"",o="`",a=-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+" ");++a<n.unsafe.length;){const u=n.unsafe[a],c=n.compilePattern(u);let d;if(u.atBreak)for(;d=c.exec(r);){let h=d.index;r.charCodeAt(h)===10&&r.charCodeAt(h-1)===13&&h--,r=r.slice(0,h)+" "+r.slice(d.index+1)}}return o+r+o}function U4(){return"`"}function fT(e,t){const n=Cd(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))}hT.peek=H4;function hT(e,t,n,r){const o=th(n),a=o==='"'?"Quote":"Apostrophe",u=n.createTracker(r);let c,d;if(fT(e,n)){const m=n.stack;n.stack=[],c=n.enter("autolink");let g=u.move("<");return g+=u.move(n.containerPhrasing(e,U({before:g,after:">"},u.current()))),g+=u.move(">"),c(),n.stack=m,g}c=n.enter("link"),d=n.enter("label");let h=u.move("[");return h+=u.move(n.containerPhrasing(e,U({before:h,after:"]("},u.current()))),h+=u.move("]("),d(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(d=n.enter("destinationLiteral"),h+=u.move("<"),h+=u.move(n.safe(e.url,U({before:h,after:">"},u.current()))),h+=u.move(">")):(d=n.enter("destinationRaw"),h+=u.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},u.current())))),d(),e.title&&(d=n.enter(`title${a}`),h+=u.move(" "+o),h+=u.move(n.safe(e.title,U({before:h,after:o},u.current()))),h+=u.move(o),d()),h+=u.move(")"),c(),h}function H4(e,t,n){return fT(e,n)?"<":"["}pT.peek=z4;function pT(e,t,n,r){const o=e.referenceType,a=n.enter("linkReference");let u=n.enter("label");const c=n.createTracker(r);let d=c.move("[");const h=n.containerPhrasing(e,U({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const g=n.safe(n.associationId(e),U({before:d,after:"]"},c.current()));return u(),n.stack=m,a(),o==="full"||!h||h!==g?d+=c.move(g+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function z4(){return"["}function nh(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 j4(e){const t=nh(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 $4(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 mT(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 V4(e,t,n,r){const o=n.enter("list"),a=n.bulletCurrent;let u=e.ordered?$4(n):nh(n);const c=e.ordered?u==="."?")":".":j4(n);let d=t&&n.bulletLastUsed?u===n.bulletLastUsed:!1;if(!e.ordered){const m=e.children?e.children[0]:void 0;if((u==="*"||u==="-")&&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&&(d=!0),mT(n)===u&&m){let g=-1;for(;++g<e.children.length;){const T=e.children[g];if(T&&T.type==="listItem"&&T.children&&T.children[0]&&T.children[0].type==="thematicBreak"){d=!0;break}}}}d&&(u=c),n.bulletCurrent=u;const h=n.containerFlow(e,r);return n.bulletLastUsed=u,n.bulletCurrent=a,o(),h}function Y4(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 W4(e,t,n,r){const o=Y4(n);let a=n.bulletCurrent||nh(n);t&&t.type==="list"&&t.ordered&&(a=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let u=a.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(u=Math.ceil(u/4)*4);const c=n.createTracker(r);c.move(a+" ".repeat(u-a.length)),c.shift(u);const d=n.enter("listItem"),h=n.indentLines(n.containerFlow(e,c.current()),m);return d(),h;function m(g,T,b){return T?(b?"":" ".repeat(u))+g:(b?a:a+" ".repeat(u-a.length))+g}}function q4(e,t,n,r){const o=n.enter("paragraph"),a=n.enter("phrasing"),u=n.containerPhrasing(e,r);return a(),o(),u}const G4=Ru(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function K4(e,t,n,r){return(e.children.some(function(u){return G4(u)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function Q4(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}gT.peek=X4;function gT(e,t,n,r){const o=Q4(n),a=n.enter("strong"),u=n.createTracker(r),c=u.move(o+o);let d=u.move(n.containerPhrasing(e,U({after:o,before:c},u.current())));const h=d.charCodeAt(0),m=ml(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(d=da(h)+d.slice(1));const g=d.charCodeAt(d.length-1),T=ml(r.after.charCodeAt(0),g,o);T.inside&&(d=d.slice(0,-1)+da(g));const b=u.move(o+o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:m.outside},c+d+b}function X4(e,t,n){return n.options.strong||"*"}function J4(e,t,n,r){return n.safe(e.value,r)}function Z4(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 eD(e,t,n){const r=(mT(n)+(n.options.ruleSpaces?" ":"")).repeat(Z4(n));return n.options.ruleSpaces?r.slice(0,-1):r}const ET={blockquote:S4,break:sT,code:N4,definition:I4,emphasis:aT,hardBreak:sT,heading:D4,html:uT,image:lT,imageReference:cT,inlineCode:dT,link:hT,linkReference:pT,list:V4,listItem:W4,paragraph:q4,root:K4,strong:gT,text:J4,thematicBreak:eD};function tD(){return{enter:{table:nD,tableData:yT,tableHeader:yT,tableRow:iD},exit:{codeText:oD,table:rD,tableData:rh,tableHeader:rh,tableRow:rh}}}function nD(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 rD(e){this.exit(e),this.data.inTable=void 0}function iD(e){this.enter({type:"tableRow",children:[]},e)}function rh(e){this.exit(e)}function yT(e){this.enter({type:"tableCell",children:[]},e)}function oD(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,sD));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function sD(e,t){return t==="|"?t:e}function aD(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
51
- `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:T,table:u,tableCell:d,tableRow:c}};function u(b,x,S,A){return h(m(b,S,A),b.align)}function c(b,x,S,A){const C=g(b,S,A),O=h([C]);return O.slice(0,O.indexOf(`
52
- `))}function d(b,x,S,A){const C=S.enter("tableCell"),O=S.enter("phrasing"),R=S.containerPhrasing(b,ne(U({},A),{before:a,after:a}));return O(),C(),R}function h(b,x){return x4(b,{align:x,alignDelimiters:r,padding:n,stringLength:o})}function m(b,x,S){const A=b.children;let C=-1;const O=[],R=x.enter("table");for(;++C<A.length;)O[C]=g(A[C],x,S);return R(),O}function g(b,x,S){const A=b.children;let C=-1;const O=[],R=x.enter("tableRow");for(;++C<A.length;)O[C]=d(A[C],b,x,S);return R(),O}function T(b,x,S){let A=ET.inlineCode(b,x,S);return S.stack.includes("tableCell")&&(A=A.replace(/\|/g,"\\$&")),A}}function uD(){return{exit:{taskListCheckValueChecked:TT,taskListCheckValueUnchecked:TT,paragraph:cD}}}function lD(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:dD}}}function TT(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function cD(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 a=-1,u;for(;++a<o.length;){const c=o[a];if(c.type==="paragraph"){u=c;break}}u===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 dD(e,t,n,r){const o=e.children[0],a=typeof e.checked=="boolean"&&o&&o.type==="paragraph",u="["+(e.checked?"x":" ")+"] ",c=n.createTracker(r);a&&c.move(u);let d=ET.listItem(e,t,n,U(U({},r),c.current()));return a&&(d=d.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),d;function h(m){return m+u}}function fD(){return[V6(),d4(),m4(),tD(),uD()]}function hD(e){return{extensions:[Y6(),f4(e),g4(),aD(e),lD()]}}const pD={tokenize:bD,partial:!0},bT={tokenize:xD,partial:!0},xT={tokenize:_D,partial:!0},_T={tokenize:SD,partial:!0},mD={tokenize:wD,partial:!0},ST={name:"wwwAutolink",tokenize:yD,previous:AT},wT={name:"protocolAutolink",tokenize:TD,previous:vT},Nr={name:"emailAutolink",tokenize:ED,previous:CT},Er={};function gD(){return{text:Er}}let ji=48;for(;ji<123;)Er[ji]=Nr,ji++,ji===58?ji=65:ji===91&&(ji=97);Er[43]=Nr,Er[45]=Nr,Er[46]=Nr,Er[95]=Nr,Er[72]=[Nr,wT],Er[104]=[Nr,wT],Er[87]=[Nr,ST],Er[119]=[Nr,ST];function ED(e,t,n){const r=this;let o,a;return u;function u(g){return!ih(g)||!CT.call(r,r.previous)||oh(r.events)?n(g):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(g))}function c(g){return ih(g)?(e.consume(g),c):g===64?(e.consume(g),d):n(g)}function d(g){return g===46?e.check(mD,m,h)(g):g===45||g===95||Wt(g)?(a=!0,e.consume(g),d):m(g)}function h(g){return e.consume(g),o=!0,d}function m(g){return a&&o&&en(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(g)):n(g)}}function yD(e,t,n){const r=this;return o;function o(u){return u!==87&&u!==119||!AT.call(r,r.previous)||oh(r.events)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(pD,e.attempt(bT,e.attempt(xT,a),n),n)(u))}function a(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function TD(e,t,n){const r=this;let o="",a=!1;return u;function u(g){return(g===72||g===104)&&vT.call(r,r.previous)&&!oh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(g),e.consume(g),c):n(g)}function c(g){if(en(g)&&o.length<5)return o+=String.fromCodePoint(g),e.consume(g),c;if(g===58){const T=o.toLowerCase();if(T==="http"||T==="https")return e.consume(g),d}return n(g)}function d(g){return g===47?(e.consume(g),a?h:(a=!0,d)):n(g)}function h(g){return g===null||wu(g)||it(g)||Ni(g)||Au(g)?n(g):e.attempt(bT,e.attempt(xT,m),n)(g)}function m(g){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(g)}}function bD(e,t,n){let r=0;return o;function o(u){return(u===87||u===119)&&r<3?(r++,e.consume(u),o):u===46&&r===3?(e.consume(u),a):n(u)}function a(u){return u===null?n(u):t(u)}}function xD(e,t,n){let r,o,a;return u;function u(h){return h===46||h===95?e.check(_T,d,c)(h):h===null||it(h)||Ni(h)||h!==45&&Au(h)?d(h):(a=!0,e.consume(h),u)}function c(h){return h===95?r=!0:(o=r,r=void 0),e.consume(h),u}function d(h){return o||r||!a?n(h):t(h)}}function _D(e,t){let n=0,r=0;return o;function o(u){return u===40?(n++,e.consume(u),o):u===41&&r<n?a(u):u===33||u===34||u===38||u===39||u===41||u===42||u===44||u===46||u===58||u===59||u===60||u===63||u===93||u===95||u===126?e.check(_T,t,a)(u):u===null||it(u)||Ni(u)?t(u):(e.consume(u),o)}function a(u){return u===41&&r++,e.consume(u),o}}function SD(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),a):c===93?(e.consume(c),o):c===60||c===null||it(c)||Ni(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||it(c)||Ni(c)?t(c):r(c)}function a(c){return en(c)?u(c):n(c)}function u(c){return c===59?(e.consume(c),r):en(c)?(e.consume(c),u):n(c)}}function wD(e,t,n){return r;function r(a){return e.consume(a),o}function o(a){return Wt(a)?n(a):t(a)}}function AT(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||it(e)}function vT(e){return!en(e)}function CT(e){return!(e===47||ih(e))}function ih(e){return e===43||e===45||e===46||e===95||Wt(e)}function oh(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 AD={tokenize:PD,partial:!0};function vD(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:OD,continuation:{tokenize:ID},exit:RD}},text:{91:{name:"gfmFootnoteCall",tokenize:ND},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:CD,resolveTo:kD}}}}function CD(e,t,n){const r=this;let o=r.events.length;const a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u;for(;o--;){const d=r.events[o][1];if(d.type==="labelImage"){u=d;break}if(d.type==="gfmFootnoteCall"||d.type==="labelLink"||d.type==="label"||d.type==="image"||d.type==="link")break}return c;function c(d){if(!u||!u._balanced)return n(d);const h=Wn(r.sliceSerialize({start:u.end,end:r.now()}));return h.codePointAt(0)!==94||!a.includes(h.slice(1))?n(d):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),t(d))}}function kD(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 a={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},u={type:"chunkString",contentType:"string",start:Object.assign({},a.start),end:Object.assign({},a.end)},c=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",a,t],["enter",u,t],["exit",u,t],["exit",a,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...c),e}function ND(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a=0,u;return c;function c(g){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(g),e.exit("gfmFootnoteCallLabelMarker"),d}function d(g){return g!==94?n(g):(e.enter("gfmFootnoteCallMarker"),e.consume(g),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",h)}function h(g){if(a>999||g===93&&!u||g===null||g===91||it(g))return n(g);if(g===93){e.exit("chunkString");const T=e.exit("gfmFootnoteCallString");return o.includes(Wn(r.sliceSerialize(T)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(g),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(g)}return it(g)||(u=!0),a++,e.consume(g),g===92?m:h}function m(g){return g===91||g===92||g===93?(e.consume(g),a++,h):h(g)}}function OD(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a,u=0,c;return d;function d(x){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(x),e.exit("gfmFootnoteDefinitionLabelMarker"),h}function h(x){return x===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(x),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",m):n(x)}function m(x){if(u>999||x===93&&!c||x===null||x===91||it(x))return n(x);if(x===93){e.exit("chunkString");const S=e.exit("gfmFootnoteDefinitionLabelString");return a=Wn(r.sliceSerialize(S)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(x),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),T}return it(x)||(c=!0),u++,e.consume(x),x===92?g:m}function g(x){return x===91||x===92||x===93?(e.consume(x),u++,m):m(x)}function T(x){return x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),o.includes(a)||o.push(a),Ke(e,b,"gfmFootnoteDefinitionWhitespace")):n(x)}function b(x){return t(x)}}function ID(e,t,n){return e.check(Ds,t,e.attempt(AD,t,n))}function RD(e){e.exit("gfmFootnoteDefinition")}function PD(e,t,n){const r=this;return Ke(e,o,"gfmFootnoteDefinitionIndent",5);function o(a){const u=r.events[r.events.length-1];return u&&u[1].type==="gfmFootnoteDefinitionIndent"&&u[2].sliceSerialize(u[1],!0).length===4?t(a):n(a)}}function LD(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:a,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function o(u,c){let d=-1;for(;++d<u.length;)if(u[d][0]==="enter"&&u[d][1].type==="strikethroughSequenceTemporary"&&u[d][1]._close){let h=d;for(;h--;)if(u[h][0]==="exit"&&u[h][1].type==="strikethroughSequenceTemporary"&&u[h][1]._open&&u[d][1].end.offset-u[d][1].start.offset===u[h][1].end.offset-u[h][1].start.offset){u[d][1].type="strikethroughSequence",u[h][1].type="strikethroughSequence";const m={type:"strikethrough",start:Object.assign({},u[h][1].start),end:Object.assign({},u[d][1].end)},g={type:"strikethroughText",start:Object.assign({},u[h][1].end),end:Object.assign({},u[d][1].start)},T=[["enter",m,c],["enter",u[h][1],c],["exit",u[h][1],c],["enter",g,c]],b=c.parser.constructs.insideSpan.null;b&&xn(T,T.length,0,vu(b,u.slice(h+1,d),c)),xn(T,T.length,0,[["exit",g,c],["enter",u[d][1],c],["exit",u[d][1],c],["exit",m,c]]),xn(u,h-1,d-h+3,T),d=h+T.length-2;break}}for(d=-1;++d<u.length;)u[d][1].type==="strikethroughSequenceTemporary"&&(u[d][1].type="data");return u}function a(u,c,d){const h=this.previous,m=this.events;let g=0;return T;function T(x){return h===126&&m[m.length-1][1].type!=="characterEscape"?d(x):(u.enter("strikethroughSequenceTemporary"),b(x))}function b(x){const S=yo(h);if(x===126)return g>1?d(x):(u.consume(x),g++,b);if(g<2&&!n)return d(x);const A=u.exit("strikethroughSequenceTemporary"),C=yo(x);return A._open=!C||C===2&&!!S,A._close=!S||S===2&&!!C,c(x)}}}class DD{constructor(){this.map=[]}add(t,n,r){MD(this,t,n,r)}consume(t){if(this.map.sort(function(a,u){return a[0]-u[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 a of o)t.push(a);o=r.pop()}this.map.length=0}}function MD(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 FD(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 a=r.length-1;r[a]=r[a]==="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 BD(){return{flow:{null:{name:"table",tokenize:UD,resolveAll:HD}}}}function UD(e,t,n){const r=this;let o=0,a=0,u;return c;function c(j){let ae=r.events.length-1;for(;ae>-1;){const ue=r.events[ae][1].type;if(ue==="lineEnding"||ue==="linePrefix")ae--;else break}const he=ae>-1?r.events[ae][1].type:null,ge=he==="tableHead"||he==="tableRow"?D:d;return ge===D&&r.parser.lazy[r.now().line]?n(j):ge(j)}function d(j){return e.enter("tableHead"),e.enter("tableRow"),h(j)}function h(j){return j===124||(u=!0,a+=1),m(j)}function m(j){return j===null?n(j):Le(j)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(j),e.exit("lineEnding"),b):n(j):qe(j)?Ke(e,m,"whitespace")(j):(a+=1,u&&(u=!1,o+=1),j===124?(e.enter("tableCellDivider"),e.consume(j),e.exit("tableCellDivider"),u=!0,m):(e.enter("data"),g(j)))}function g(j){return j===null||j===124||it(j)?(e.exit("data"),m(j)):(e.consume(j),j===92?T:g)}function T(j){return j===92||j===124?(e.consume(j),g):g(j)}function b(j){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(j):(e.enter("tableDelimiterRow"),u=!1,qe(j)?Ke(e,x,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(j):x(j))}function x(j){return j===45||j===58?A(j):j===124?(u=!0,e.enter("tableCellDivider"),e.consume(j),e.exit("tableCellDivider"),S):z(j)}function S(j){return qe(j)?Ke(e,A,"whitespace")(j):A(j)}function A(j){return j===58?(a+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(j),e.exit("tableDelimiterMarker"),C):j===45?(a+=1,C(j)):j===null||Le(j)?F(j):z(j)}function C(j){return j===45?(e.enter("tableDelimiterFiller"),O(j)):z(j)}function O(j){return j===45?(e.consume(j),O):j===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(j),e.exit("tableDelimiterMarker"),R):(e.exit("tableDelimiterFiller"),R(j))}function R(j){return qe(j)?Ke(e,F,"whitespace")(j):F(j)}function F(j){return j===124?x(j):j===null||Le(j)?!u||o!==a?z(j):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(j)):z(j)}function z(j){return n(j)}function D(j){return e.enter("tableRow"),q(j)}function q(j){return j===124?(e.enter("tableCellDivider"),e.consume(j),e.exit("tableCellDivider"),q):j===null||Le(j)?(e.exit("tableRow"),t(j)):qe(j)?Ke(e,q,"whitespace")(j):(e.enter("data"),ce(j))}function ce(j){return j===null||j===124||it(j)?(e.exit("data"),q(j)):(e.consume(j),j===92?be:ce)}function be(j){return j===92||j===124?(e.consume(j),ce):ce(j)}}function HD(e,t){let n=-1,r=!0,o=0,a=[0,0,0,0],u=[0,0,0,0],c=!1,d=0,h,m,g;const T=new DD;for(;++n<e.length;){const b=e[n],x=b[1];b[0]==="enter"?x.type==="tableHead"?(c=!1,d!==0&&(kT(T,t,d,h,m),m=void 0,d=0),h={type:"table",start:Object.assign({},x.start),end:Object.assign({},x.end)},T.add(n,0,[["enter",h,t]])):x.type==="tableRow"||x.type==="tableDelimiterRow"?(r=!0,g=void 0,a=[0,0,0,0],u=[0,n+1,0,0],c&&(c=!1,m={type:"tableBody",start:Object.assign({},x.start),end:Object.assign({},x.end)},T.add(n,0,[["enter",m,t]])),o=x.type==="tableDelimiterRow"?2:m?3:1):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")?(r=!1,u[2]===0&&(a[1]!==0&&(u[0]=u[1],g=gl(T,t,a,o,void 0,g),a=[0,0,0,0]),u[2]=n)):x.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(u[0]=u[1],g=gl(T,t,a,o,void 0,g)),a=u,u=[a[1],n,0,0])):x.type==="tableHead"?(c=!0,d=n):x.type==="tableRow"||x.type==="tableDelimiterRow"?(d=n,a[1]!==0?(u[0]=u[1],g=gl(T,t,a,o,n,g)):u[1]!==0&&(g=gl(T,t,u,o,n,g)),o=0):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")&&(u[3]=n)}for(d!==0&&kT(T,t,d,h,m),T.consume(t.events),n=-1;++n<t.events.length;){const b=t.events[n];b[0]==="enter"&&b[1].type==="table"&&(b[1]._align=FD(t.events,n))}return e}function gl(e,t,n,r,o,a){const u=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(a.end=Object.assign({},Yo(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const d=Yo(t.events,n[1]);if(a={type:u,start:Object.assign({},d),end:Object.assign({},d)},e.add(n[1],0,[["enter",a,t]]),n[2]!==0){const h=Yo(t.events,n[2]),m=Yo(t.events,n[3]),g={type:c,start:Object.assign({},h),end:Object.assign({},m)};if(e.add(n[2],0,[["enter",g,t]]),r!==2){const T=t.events[n[2]],b=t.events[n[3]];if(T[1].end=Object.assign({},b[1].end),T[1].type="chunkText",T[1].contentType="text",n[3]>n[2]+1){const x=n[2]+1,S=n[3]-n[2]-1;e.add(x,S,[])}}e.add(n[3]+1,0,[["exit",g,t]])}return o!==void 0&&(a.end=Object.assign({},Yo(t.events,o)),e.add(o,0,[["exit",a,t]]),a=void 0),a}function kT(e,t,n,r,o){const a=[],u=Yo(t.events,n);o&&(o.end=Object.assign({},u),a.push(["exit",o,t])),r.end=Object.assign({},u),a.push(["exit",r,t]),e.add(n+1,0,a)}function Yo(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const zD={name:"tasklistCheck",tokenize:$D};function jD(){return{text:{91:zD}}}function $D(e,t,n){const r=this;return o;function o(d){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(d):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(d),e.exit("taskListCheckMarker"),a)}function a(d){return it(d)?(e.enter("taskListCheckValueUnchecked"),e.consume(d),e.exit("taskListCheckValueUnchecked"),u):d===88||d===120?(e.enter("taskListCheckValueChecked"),e.consume(d),e.exit("taskListCheckValueChecked"),u):n(d)}function u(d){return d===93?(e.enter("taskListCheckMarker"),e.consume(d),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),c):n(d)}function c(d){return Le(d)?t(d):qe(d)?e.check({tokenize:VD},t,n)(d):n(d)}}function VD(e,t,n){return Ke(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function YD(e){return rg([gD(),vD(),LD(e),BD(),jD()])}const WD={};function qD(e){const t=this,n=e||WD,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),u=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push(YD(n)),a.push(fD()),u.push(hD(n))}const GD=()=>P.jsx("span",{className:`${J}-blinking-cursor`,children:P.jsx("svg",{height:"16px",width:"16px",xmlns:"http://www.w3.org/2000/svg",children:P.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),sh=({globalClassName:e,openLinksInNewTab:t,showIsLoading:n,text:r})=>P.jsx(qg,{remarkPlugins:[qD],rehypePlugins:[oE],components:{h1:({children:o})=>P.jsx("h1",{className:re(e,`${J}-header h1`),children:o}),h2:({children:o})=>P.jsx("h2",{className:re(e,`${J}-header h2`),children:o}),h3:({children:o})=>P.jsx("h3",{className:re(e,`${J}-header h3`),children:o}),ul:({children:o})=>P.jsx("ul",{className:re(e,`${J}-ul`),children:o}),ol:({children:o})=>P.jsx("ol",{className:re(e,`${J}-ol`),children:o}),li:({children:o})=>P.jsx("li",{className:re(e,`${J}-li`),children:o}),a:({href:o,children:a})=>P.jsx(fE,{globalClassName:e,openLinksInNewTab:t,href:o,children:a}),table:({children:o})=>P.jsx("div",{className:re(e,`${J}-table-container`),children:P.jsx("table",{className:re(e,`${J}-table`),children:o})}),thead:({children:o})=>P.jsx("thead",{className:re(e,`${J}-thead`),children:o}),tbody:({children:o})=>P.jsx("tbody",{className:re(e,`${J}-tbody`),children:o}),tr:({children:o})=>P.jsx("tr",{className:re(e,`${J}-tr`),children:o}),th:({children:o})=>P.jsx("th",{className:re(e,`${J}-th`),children:o}),td:({children:o})=>P.jsx("td",{className:re(e,`${J}-td`),children:o}),span:({className:o,children:a})=>o===`${J}-blinking-cursor`?P.jsx(GD,{}):P.jsx("span",{children:a})},children:r+(n?`<span className='${J}-blinking-cursor'></span>`:"")}),KD=["Hey there! 👋 What can I find for you today?","Shopping for a gift? Tell me your budget and preferences","Need help? Connect to an agent"],QD=3e3,XD=400,JD=({globalClassName:e,isWidgetStandalone:t,messages:n=KD})=>{const[r,o]=ee.useState(0),[a,u]=ee.useState(!0);return ee.useEffect(()=>{let c;const d=setInterval(()=>{u(!1),c=setTimeout(()=>{o(h=>(h+1)%n.length),u(!0)},XD)},QD);return()=>{clearInterval(d),clearTimeout(c)}},[n.length]),P.jsxs("div",{className:re(e,`${J}-connecting-indicator`,t?"standalone":"embedded"),role:"status","aria-label":"Connecting to assistant",children:[P.jsxs("div",{className:`${J}-connecting-pulse-wrapper`,children:[P.jsx("div",{className:`${J}-connecting-pulse`}),P.jsx("div",{className:`${J}-connecting-ring`})]}),P.jsx("span",{className:re(`${J}-connecting-text`,a&&`${J}-connecting-text--visible`),children:n[r]})]})},ZD=({shouldShow:e,loadingText:t})=>e?P.jsx("span",{className:`${J}-processing-text`,children:t}):null,e5=({shouldShow:e})=>e?P.jsxs(P.Fragment,{children:[P.jsx("div",{className:`${J}-processing-shimmer-bar`}),P.jsx("div",{className:`${J}-processing-shimmer-bar`}),P.jsx("div",{className:`${J}-processing-shimmer-bar`})]}):null,t5=({globalClassName:e,isWidgetStandalone:t,loadingText:n})=>P.jsxs("div",{className:re(e,`${J}-processing-indicator`,t?"standalone":"embedded"),role:"status","aria-label":n||"Loading response",children:[P.jsx(ZD,{shouldShow:!!n,loadingText:n}),P.jsx(e5,{shouldShow:!n})]}),El=(e,t)=>{if(typeof e!="number")return null;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t||"USD"}).format(e)}catch(n){return`${e}`}},NT=({product:e,globalClassName:t,isFullWidth:n,openLinksInNewTab:r})=>{const{name:o,imageUrl:a,productPageUrl:u,price:c,discountPrice:d,compareAtPrice:h,currencyCode:m}=e,g=typeof d=="number"&&typeof c=="number"&&d<c,T=El(g?d:c,m),b=El(g?c:h,m);return P.jsxs("div",{className:re(t,`${J}-msg-product-card`,{"card-full-width":n}),children:[P.jsx("div",{className:re(t,`${J}-msg-product-card__image-wrapper`),children:a&&(u?P.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer","aria-label":`Go to product page for ${o}`,children:P.jsx("img",{className:re(t,`${J}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"})}):P.jsx("img",{className:re(t,`${J}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"}))}),P.jsxs("div",{className:re(t,`${J}-msg-product-card__content`),children:[u?P.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer",className:re(t,`${J}-msg-product-card__title-link`),"aria-label":`Go to product page for ${o}`,children:o}):P.jsx("p",{className:re(t,`${J}-msg-product-card__title`),children:o}),P.jsx("div",{className:re(t,`${J}-msg-product-card__price-row`),children:P.jsxs("div",{className:re(t,`${J}-msg-product-card__prices`),children:[T&&P.jsx("span",{className:re(t,`${J}-msg-product-card__price`),children:T}),b&&P.jsx("span",{className:re(t,`${J}-msg-product-card__compare-price`),children:b})]})})]})]})},n5=({content:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{sendMessage:o,loading:a}=Ci(),u=e.response.filter(c=>c.type==="product");return P.jsxs(P.Fragment,{children:[e.response.map((c,d)=>{var h;return c.type==="markdown"?P.jsx(sh,{text:c.content,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1},d):P.jsx(NT,{product:c,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r,isFullWidth:!r},(h=c.id)!=null?h:d)}),u.length>2&&P.jsx("div",{style:{marginTop:"1rem"},children:P.jsx(F6,{globalClassName:t,spacing:r?"0.5rem":"6px",ariaLabel:"Product recommendations",children:u.map((c,d)=>{var h;return P.jsx(NT,{product:c,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},(h=c.id)!=null?h:d)})})}),e.suggestions&&e.suggestions.length>0&&P.jsx("div",{style:{marginTop:"0.5rem"},children:P.jsx(B6,{disabled:a,suggestions:e.suggestions,globalClassName:t,isWidgetStandalone:r,onSuggestionClick:o})})]})},r5=({message:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const o=ee.useMemo(()=>{try{const a=JSON.parse(e.content);return Array.isArray(a==null?void 0:a.response)?a:null}catch(a){return null}},[e.content]);switch(e.role){case"user":return P.jsx("div",{className:re(t,`${J}-message`,r?"standalone":"embedded"),children:P.jsx("div",{className:re(t,`${J}-user-message`,r?"standalone":"embedded"),children:P.jsxs("div",{className:re(t,`${J}-user-message-row`,r?"standalone":"embedded"),children:[P.jsx("span",{className:re(t,`${J}-message-icon user-message-icon`,r?"standalone":"embedded"),children:P.jsx(Gw,{})}),P.jsx("p",{className:re(t,`${J}-user-message-text`,r?"standalone":"embedded"),children:e.content})]})})});case"agent":return P.jsx("div",{className:re(t,`${J}-message-group`,r?"standalone":"embedded"),children:P.jsx("div",{className:`${J}-message-group-child`,children:o?P.jsx(n5,{content:o,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r}):P.jsx(sh,{text:e.content,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})})});case"system":return P.jsx("div",{className:re(t,`${J}-message`,r?"standalone":"embedded"),children:P.jsx("p",{className:re(t,`${J}-reset-message`),children:e.content})})}},ah=({isWidgetStandalone:e})=>{const{globalClassName:t,openLinksInNewTab:n}=an(),{messages:r,streamingContent:o,isAgentTyping:a,loading:u,progressMessage:c}=Ci(),d=ee.useRef(null),h=r.length>0;return ee.useEffect(()=>{var m;(m=d.current)==null||m.scrollIntoView({behavior:"smooth"})},[r,o]),P.jsxs(P.Fragment,{children:[u&&!h&&P.jsx(JD,{globalClassName:t,isWidgetStandalone:e}),r.map(m=>P.jsx(r5,{message:m,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e},m.id)),o&&P.jsx("div",{className:re(t,`${J}-message-group`,e?"standalone":"embedded"),children:P.jsx(sh,{text:o,globalClassName:t,openLinksInNewTab:n,showIsLoading:!0})}),h&&(u||a)&&!o&&P.jsx(t5,{globalClassName:t,isWidgetStandalone:e,loadingText:c}),P.jsx("div",{ref:d})]})},OT=()=>{const{globalClassName:e,themeVariables:t}=an(),{isAgentTyping:n,sendMessage:r,resetConversation:o}=Ci(),a=n;return P.jsxs("div",{className:re(e,`${J}-container`,`${J}-embedded-chat`),style:t,children:[P.jsx("div",{className:re(e,`${J}-message-container`,"embedded"),children:P.jsx(ah,{isWidgetStandalone:!1})}),P.jsx(mf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:u=>r(u)}),P.jsx("div",{className:re(`${J}-embedded-chat-menu`),children:P.jsxs(Xf,{componentType:"chat",children:[P.jsx(Jy,{componentType:"chat"}),P.jsx(gf,{componentType:"chat",onClearChat:o})]})})]})},[i5,o5]=Bi({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),s5=e=>ia()(e,["lazyMount","unmountOnExit"]),[a5,fa]=Bi({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),IT=ee.forwardRef((e,t)=>{const n=fa(),r=o5(),o=Pf(ne(U({},r),{present:n.open})),a=Nt(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:P.jsx(Gt.div,ne(U({},a),{ref:tl(o.ref,t)}))});IT.displayName="DialogBackdrop";const uh=ee.forwardRef((e,t)=>{const n=fa(),r=ra(),o=Nt(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:P.jsx(Gt.div,ne(U({},o),{ref:tl(r.ref,t)}))});uh.displayName="DialogContent";const lh=ee.forwardRef((e,t)=>{const n=fa(),r=Nt(n.getDescriptionProps(),e);return P.jsx(Gt.div,ne(U({},r),{ref:t}))});lh.displayName="DialogDescription";const ch=ee.forwardRef((e,t)=>{const n=fa(),r=Nt(n.getPositionerProps(),e);return ra().unmounted?null:P.jsx(Gt.div,ne(U({},r),{ref:t}))});ch.displayName="DialogPositioner";var u5=Ui("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),$i=u5.build(),RT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},PT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},dh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},LT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},fh=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`},DT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},yl=e=>e.getById(dh(e)),l5=e=>e.getById(RT(e)),c5=e=>e.getById(PT(e)),d5=e=>e.getById(LT(e)),f5=e=>e.getById(fh(e)),h5=e=>e.getById(hh(e)),p5=e=>e.getById(DT(e));function m5(e,t){const{state:n,send:r,context:o,prop:a,scope:u}=e,c=a("aria-label"),d=n.matches("open");return{open:d,setOpen(h){n.matches("open")!==h&&r({type:h?"OPEN":"CLOSE"})},getTriggerProps(){return t.button(ne(U({},$i.trigger.attrs),{dir:a("dir"),id:LT(u),"aria-haspopup":"dialog",type:"button","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":dh(u),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(ne(U({},$i.backdrop.attrs),{dir:a("dir"),hidden:!d,id:PT(u),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ne(U({},$i.positioner.attrs),{dir:a("dir"),id:RT(u),style:{pointerEvents:d?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(ne(U({},$i.content.attrs),{dir:a("dir"),role:a("role"),hidden:!d,id:dh(u),tabIndex:-1,"data-state":d?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:fh(u),"aria-describedby":h.description?hh(u):void 0}))},getTitleProps(){return t.element(ne(U({},$i.title.attrs),{dir:a("dir"),id:fh(u)}))},getDescriptionProps(){return t.element(ne(U({},$i.description.attrs),{dir:a("dir"),id:hh(u)}))},getCloseTriggerProps(){return t.button(ne(U({},$i.closeTrigger.attrs),{dir:a("dir"),id:DT(u),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var g5={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>p5(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 by(()=>yl(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[d5(e)],onInteractOutside(o){var a;(a=n("onInteractOutside"))==null||a(o),n("closeOnInteractOutside")||o.preventDefault()},persistentElements:n("persistentElements"),onFocusOutside:n("onFocusOutside"),onPointerDownOutside:n("onPointerDownOutside"),onRequestDismiss:n("onRequestDismiss"),onEscapeKeyDown(o){var a;(a=n("onEscapeKeyDown"))==null||a(o),n("closeOnEscape")||o.preventDefault()},onDismiss(){t({type:"CLOSE",src:"interact-outside"})}})},preventScroll({scope:e,prop:t}){if(t("preventScroll"))return Ay(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?Sy(()=>yl(e),{preventScroll:!0,returnFocusOnDeactivate:!!t("restoreFocus"),initialFocus:t("initialFocusEl"),setReturnFocus:r=>{var o,a;return(a=(o=t("finalFocusEl"))==null?void 0:o())!=null?a:r},getShadowRoot:!0}):void 0},hideContentBelow({scope:e,prop:t}){return t("modal")?dy(()=>[yl(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){kt(()=>{e.set("rendered",{title:!!f5(t),description:!!h5(t)})})},syncZIndex({scope:e}){kt(()=>{const t=yl(e);if(!t)return;const n=Ro(t);[l5(e),c5(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})}}}};Mo()(["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 E5=e=>{const t=ee.useId(),{getRootNode:n}=hl(),{dir:r}=Qf(),o=U({id:t,getRootNode:n,dir:r},e),a=el(g5,o);return m5(a,Of)},MT=e=>{const[t,c]=zE(e),d=c,{children:n}=d,r=rn(d,["children"]),[o]=s5(t),a=E5(r),u=Pf(Nt({present:a.open},t));return P.jsx(a5,{value:a,children:P.jsx(i5,{value:o,children:P.jsx(BE,{value:u,children:n})})})},ph=ee.forwardRef((e,t)=>{const n=fa(),r=Nt(n.getTitleProps(),e);return P.jsx(Gt.h2,ne(U({},r),{ref:t}))});ph.displayName="DialogTitle";const FT=e=>{var d;const{children:t,disabled:n}=e,[r,o]=ee.useState((d=e.container)==null?void 0:d.current),a=ee.useSyncExternalStore(T5,()=>!1,()=>!0),{getRootNode:u}=hl();if(ee.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),a||n)return P.jsx(P.Fragment,{children:t});const c=r!=null?r:y5(u);return P.jsx(P.Fragment,{children:ee.Children.map(t,h=>ks.createPortal(h,c))})},y5=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Mi(n)?n:cr(t).body},T5=()=>()=>{},b5=({componentType:e,isIcon:t})=>{const{globalClassName:n}=an(),{dialogPosition:r}=fo(),o=ea(),a=r==="bottom-left",u=()=>{fd(a?"bottom-right":"bottom-left"),o()},c=a?g6:m6,d=a?"Move right":"Move left";return t?P.jsx(jr,{className:re(n,`${J}-left-right-toggle-button`,`cim-${e}-component`),ariaLabel:d,onClick:u,icon:P.jsx(c,{})}):P.jsxs("button",{className:re(n,`${J}-overflow-menu-button`,`${J}-left-right-toggle-button`,`cim-${e}-component`),onClick:u,children:[P.jsx(c,{}),d]})},BT=()=>{const{headerConfig:e,globalClassName:t,themeVariables:n}=an(),{mode:r,status:o,dialogPosition:a,isDialogFullHeight:u,dialogWidth:c}=fo(),{loading:d,isAgentTyping:h,sendMessage:m,resetConversation:g}=Ci(),{isOpen:T}=o||{},b=!!o.isOpen,x=r==="standalone",S=h||d,A=ee.useMemo(()=>e?_0(e):{},[e]),C=()=>{vi(!1)};return b?P.jsx(MT,{lazyMount:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:T,children:P.jsx(FT,{children:P.jsx(ch,{className:re(t,`${J}-container`,`${J}-dialog`,a,u&&"full-height"),style:U(U({},n),c&&{width:c}),children:P.jsxs(uh,{className:re(t,`${J}-dialog-content`,{standalone:x,embedded:!x}),children:[P.jsxs("div",{className:re(t,`${J}-dialog-header`,{standalone:x,embedded:!x}),style:A,children:[(e==null?void 0:e.logoUrl)&&P.jsx("img",{alt:"",role:"img",className:re(t,`${J}-dialog-logo`,{standalone:x,embedded:!x}),src:e.logoUrl}),P.jsx(ph,{className:re(t,`${J}-dialog-title`,{standalone:x,embedded:!x}),children:e==null?void 0:e.headerText}),P.jsxs("div",{className:re(t,`${J}-dialog-controls`),children:[P.jsx(Jy,{componentType:"dialog",isIcon:!0}),P.jsxs(Xf,{componentType:"dialog",children:[P.jsx(b5,{componentType:"dialog"}),P.jsx(Xy,{componentType:"dialog"}),P.jsx(gf,{componentType:"dialog",onClearChat:g})]}),P.jsx(Qy,{className:`dialog ${t}`,onClick:C})]})]}),P.jsx(lh,{className:re(t,`${J}-message-container`,{standalone:x,embedded:!x}),children:P.jsx(ah,{isWidgetStandalone:x,isOpen:T})}),P.jsx(mf,{componentType:"dialog",isLoading:S,onSubmit:O=>m(O)})]})})})}):null},x5=({componentType:e,isIcon:t})=>{const{globalClassName:n}=an(),{previousComponentType:r}=fo(),o=ea(),a=()=>{Tu(r||"dialog"),o()};return t?P.jsx(jr,{className:re(n,`${J}-toggle-dialog-button`,`cim-${e}-component`),ariaLabel:"Toggle Dialog",onClick:a,icon:P.jsx(Ry,{})}):P.jsxs("button",{className:re(n,`${J}-overflow-menu-button`,`${J}-toggle-dialog-button`,`cim-${e}-component`),onClick:a,children:[P.jsx(Ry,{}),"Show ",r||"dialog"]})},_5=({componentType:e,isIcon:t})=>{const{globalClassName:n}=an(),{isModalFullscreen:r}=fo(),o=ea(),a=()=>{dd(!r),o()},u=r?Kw:Qw,c="Toggle Fullscreen";return t?P.jsx(jr,{ariaLabel:c,title:c,className:re(n,`${J}-modal-fullscreen-button`,`cim-${e}-component`),icon:P.jsx(u,{}),onClick:a}):P.jsxs("button",{className:re(n,`${J}-overflow-menu-button`,`${J}-modal-fullscreen-button`,`cim-${e}-component`),onClick:a,children:[P.jsx(u,{}),c]})},UT=()=>{const{headerConfig:e,globalClassName:t,themeVariables:n}=an(),{mode:r,status:o,isModalFullscreen:a}=fo(),{isAgentTyping:u,sendMessage:c,resetConversation:d}=Ci(),{isOpen:h}=o||{},m=!!o.isOpen,g=r==="standalone",T=u,b=ee.useMemo(()=>e?_0(e):{},[e]),x=({open:A})=>{vi(A)},S=()=>{vi(!1)};return m?P.jsx(MT,{lazyMount:!0,open:h,onOpenChange:x,children:P.jsx(FT,{children:P.jsxs("div",{className:re(t,`${J}-modal-container`),style:n,children:[P.jsx(IT,{className:re(t,`${J}-modal-backdrop`)}),P.jsx(ch,{className:re(t,`${J}-container`,`${J}-modal`,{fullscreen:a,standalone:g,embedded:!g}),children:P.jsxs(uh,{className:re(t,`${J}-modal-content`,{standalone:g,embedded:!g}),children:[P.jsxs("div",{className:re(t,`${J}-modal-header`,{standalone:g,embedded:!g}),style:b,children:[(e==null?void 0:e.logoUrl)&&P.jsx("img",{alt:"",role:"img",className:re(t,`${J}-modal-logo`,{standalone:g,embedded:!g}),src:e.logoUrl}),P.jsx(ph,{className:re(t,`${J}-modal-title`,{standalone:g,embedded:!g}),children:e==null?void 0:e.headerText}),P.jsxs("div",{className:re(t,`${J}-modal-controls`),children:[P.jsx(x5,{componentType:"modal",isIcon:!0}),P.jsxs(Xf,{componentType:"modal",children:[P.jsx(_5,{componentType:"modal"}),P.jsx(Xy,{componentType:"modal"}),P.jsx(gf,{componentType:"modal",onClearChat:d})]}),P.jsx(Qy,{className:`modal ${t}`,onClick:S})]})]}),P.jsx(lh,{className:re(t,`${J}-message-container`,{standalone:g,embedded:!g}),children:P.jsx(ah,{isWidgetStandalone:g,isOpen:h})}),P.jsx(mf,{componentType:"modal",isLoading:T,onSubmit:A=>c(A)})]})})]})})}):null},S5=()=>{const e=fo(),{status:{type:t,isMinimized:n}}=e||{status:{}};return n?P.jsx(Uw,{}):t==="dialog"?P.jsx(BT,{}):t==="modal"?P.jsx(UT,{}):P.jsx(OT,{})},mh=e=>P.jsx(d0,ne(U({},e),{children:P.jsx(S5,{})}));var Tl={},HT;function w5(){if(HT)return Tl;HT=1;var e=g0();return Tl.createRoot=e.createRoot,Tl.hydrateRoot=e.hydrateRoot,Tl}var zT=w5();const A5=r=>{var o=r,{elementId:e,timeout:t=5e3}=o,n=rn(o,["elementId","timeout"]);let a;const u=(d,h)=>{var m;for(const g of d)if(g.type==="childList"&&g.addedNodes.length)for(const T of g.addedNodes)T.nodeType===Node.ELEMENT_NODE&&T.id===e&&(Ai(!0,"log","Target element found, rendering Messaging Widget"),h.disconnect(),clearTimeout(a),(m=zT.createRoot(T))==null||m.render(P.jsx(mh,ne(U({},n),{mode:"messaging"}))))},c=new MutationObserver(u);return c.observe(document.body,{childList:!0,subtree:!0}),a=setTimeout(()=>{c.disconnect(),Ai(!0,"error",`Element with id: ${e} not found within ${t} milliseconds, stopping observation`)},t),c},v5=r=>{var o=r,{timeout:e,elementId:t}=o,n=rn(o,["timeout","elementId"]);if(!n.messagingConfig){Ai(!0,"error","Messaging Widget requires messagingConfig");return}if(!n.messagingConfig.scrt2Url||!n.messagingConfig.orgId||!n.messagingConfig.esDeveloperName){Ai(!0,"error","Messaging Widget requires messagingConfig.scrt2Url, messagingConfig.orgId, and messagingConfig.esDeveloperName");return}const a=document.getElementById(t);if(!a){Ai(!0,"warn","Container element not found for id:",t),Ai(!0,"warn","Beginning observation for element"),A5(U({elementId:t,timeout:e},n));return}zT.createRoot(a).render(P.jsx(mh,ne(U({},n),{mode:"messaging"})))},C5={components:{setEntryType:l0,toggleWidgetOpen:vi,toggleWidgetMinimized:yu,toggleModalFullscreen:dd,setWidgetType:Tu,setWidgetDialogPosition:fd}};Ie.AgentForceWidget=mh,Ie.AgentforceWidgetProvider=d0,Ie.MessagingDialog=BT,Ie.MessagingEmbed=OT,Ie.MessagingModal=UT,Ie.MessagingProvider=u0,Ie.eventHandlers=C5,Ie.injectMessagingWidget=v5,Ie.useMessaging=Ci,Object.defineProperty(Ie,Symbol.toStringTag,{value:"Module"})}));
50
+ `},a.current()));return/^[\t ]/.test(h)&&(h=fa(h.charCodeAt(0))+h.slice(1)),h=h?u+" "+h:u,n.options.closeAtx&&(h+=" "+u),d(),c(),h}fT.peek=tD;function fT(e){return e.value||""}function tD(){return"<"}hT.peek=nD;function hT(e,t,n,r){const o=oh(n),a=o==='"'?"Quote":"Apostrophe",u=n.enter("image");let c=n.enter("label");const d=n.createTracker(r);let h=d.move("![");return h+=d.move(n.safe(e.alt,U({before:h,after:"]"},d.current()))),h+=d.move("]("),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),h+=d.move("<"),h+=d.move(n.safe(e.url,U({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},d.current())))),c(),e.title&&(c=n.enter(`title${a}`),h+=d.move(" "+o),h+=d.move(n.safe(e.title,U({before:h,after:o},d.current()))),h+=d.move(o),c()),h+=d.move(")"),u(),h}function nD(){return"!"}pT.peek=rD;function pT(e,t,n,r){const o=e.referenceType,a=n.enter("imageReference");let u=n.enter("label");const c=n.createTracker(r);let d=c.move("![");const h=n.safe(e.alt,U({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const E=n.safe(n.associationId(e),U({before:d,after:"]"},c.current()));return u(),n.stack=m,a(),o==="full"||!h||h!==E?d+=c.move(E+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function rD(){return"!"}mT.peek=iD;function mT(e,t,n){let r=e.value||"",o="`",a=-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+" ");++a<n.unsafe.length;){const u=n.unsafe[a],c=n.compilePattern(u);let d;if(u.atBreak)for(;d=c.exec(r);){let h=d.index;r.charCodeAt(h)===10&&r.charCodeAt(h-1)===13&&h--,r=r.slice(0,h)+" "+r.slice(d.index+1)}}return o+r+o}function iD(){return"`"}function gT(e,t){const n=Cd(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))}ET.peek=oD;function ET(e,t,n,r){const o=oh(n),a=o==='"'?"Quote":"Apostrophe",u=n.createTracker(r);let c,d;if(gT(e,n)){const m=n.stack;n.stack=[],c=n.enter("autolink");let E=u.move("<");return E+=u.move(n.containerPhrasing(e,U({before:E,after:">"},u.current()))),E+=u.move(">"),c(),n.stack=m,E}c=n.enter("link"),d=n.enter("label");let h=u.move("[");return h+=u.move(n.containerPhrasing(e,U({before:h,after:"]("},u.current()))),h+=u.move("]("),d(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(d=n.enter("destinationLiteral"),h+=u.move("<"),h+=u.move(n.safe(e.url,U({before:h,after:">"},u.current()))),h+=u.move(">")):(d=n.enter("destinationRaw"),h+=u.move(n.safe(e.url,U({before:h,after:e.title?" ":")"},u.current())))),d(),e.title&&(d=n.enter(`title${a}`),h+=u.move(" "+o),h+=u.move(n.safe(e.title,U({before:h,after:o},u.current()))),h+=u.move(o),d()),h+=u.move(")"),c(),h}function oD(e,t,n){return gT(e,n)?"<":"["}yT.peek=sD;function yT(e,t,n,r){const o=e.referenceType,a=n.enter("linkReference");let u=n.enter("label");const c=n.createTracker(r);let d=c.move("[");const h=n.containerPhrasing(e,U({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const E=n.safe(n.associationId(e),U({before:d,after:"]"},c.current()));return u(),n.stack=m,a(),o==="full"||!h||h!==E?d+=c.move(E+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function sD(){return"["}function sh(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 aD(e){const t=sh(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 uD(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 TT(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 lD(e,t,n,r){const o=n.enter("list"),a=n.bulletCurrent;let u=e.ordered?uD(n):sh(n);const c=e.ordered?u==="."?")":".":aD(n);let d=t&&n.bulletLastUsed?u===n.bulletLastUsed:!1;if(!e.ordered){const m=e.children?e.children[0]:void 0;if((u==="*"||u==="-")&&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&&(d=!0),TT(n)===u&&m){let E=-1;for(;++E<e.children.length;){const T=e.children[E];if(T&&T.type==="listItem"&&T.children&&T.children[0]&&T.children[0].type==="thematicBreak"){d=!0;break}}}}d&&(u=c),n.bulletCurrent=u;const h=n.containerFlow(e,r);return n.bulletLastUsed=u,n.bulletCurrent=a,o(),h}function cD(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 dD(e,t,n,r){const o=cD(n);let a=n.bulletCurrent||sh(n);t&&t.type==="list"&&t.ordered&&(a=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let u=a.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(u=Math.ceil(u/4)*4);const c=n.createTracker(r);c.move(a+" ".repeat(u-a.length)),c.shift(u);const d=n.enter("listItem"),h=n.indentLines(n.containerFlow(e,c.current()),m);return d(),h;function m(E,T,b){return T?(b?"":" ".repeat(u))+E:(b?a:a+" ".repeat(u-a.length))+E}}function fD(e,t,n,r){const o=n.enter("paragraph"),a=n.enter("phrasing"),u=n.containerPhrasing(e,r);return a(),o(),u}const hD=Ru(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function pD(e,t,n,r){return(e.children.some(function(u){return hD(u)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function mD(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}bT.peek=gD;function bT(e,t,n,r){const o=mD(n),a=n.enter("strong"),u=n.createTracker(r),c=u.move(o+o);let d=u.move(n.containerPhrasing(e,U({after:o,before:c},u.current())));const h=d.charCodeAt(0),m=gl(r.before.charCodeAt(r.before.length-1),h,o);m.inside&&(d=fa(h)+d.slice(1));const E=d.charCodeAt(d.length-1),T=gl(r.after.charCodeAt(0),E,o);T.inside&&(d=d.slice(0,-1)+fa(E));const b=u.move(o+o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:m.outside},c+d+b}function gD(e,t,n){return n.options.strong||"*"}function ED(e,t,n,r){return n.safe(e.value,r)}function yD(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 TD(e,t,n){const r=(TT(n)+(n.options.ruleSpaces?" ":"")).repeat(yD(n));return n.options.ruleSpaces?r.slice(0,-1):r}const xT={blockquote:j4,break:cT,code:G4,definition:Q4,emphasis:dT,hardBreak:cT,heading:eD,html:fT,image:hT,imageReference:pT,inlineCode:mT,link:ET,linkReference:yT,list:lD,listItem:dD,paragraph:fD,root:pD,strong:bT,text:ED,thematicBreak:TD};function bD(){return{enter:{table:xD,tableData:_T,tableHeader:_T,tableRow:wD},exit:{codeText:SD,table:_D,tableData:ah,tableHeader:ah,tableRow:ah}}}function xD(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 _D(e){this.exit(e),this.data.inTable=void 0}function wD(e){this.enter({type:"tableRow",children:[]},e)}function ah(e){this.exit(e)}function _T(e){this.enter({type:"tableCell",children:[]},e)}function SD(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,AD));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function AD(e,t){return t==="|"?t:e}function vD(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
51
+ `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:T,table:u,tableCell:d,tableRow:c}};function u(b,_,w,A){return h(m(b,w,A),b.align)}function c(b,_,w,A){const C=E(b,w,A),I=h([C]);return I.slice(0,I.indexOf(`
52
+ `))}function d(b,_,w,A){const C=w.enter("tableCell"),I=w.enter("phrasing"),R=w.containerPhrasing(b,ne(U({},A),{before:a,after:a}));return I(),C(),R}function h(b,_){return H4(b,{align:_,alignDelimiters:r,padding:n,stringLength:o})}function m(b,_,w){const A=b.children;let C=-1;const I=[],R=_.enter("table");for(;++C<A.length;)I[C]=E(A[C],_,w);return R(),I}function E(b,_,w){const A=b.children;let C=-1;const I=[],R=_.enter("tableRow");for(;++C<A.length;)I[C]=d(A[C],b,_,w);return R(),I}function T(b,_,w){let A=xT.inlineCode(b,_,w);return w.stack.includes("tableCell")&&(A=A.replace(/\|/g,"\\$&")),A}}function CD(){return{exit:{taskListCheckValueChecked:wT,taskListCheckValueUnchecked:wT,paragraph:ND}}}function kD(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:OD}}}function wT(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function ND(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 a=-1,u;for(;++a<o.length;){const c=o[a];if(c.type==="paragraph"){u=c;break}}u===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 OD(e,t,n,r){const o=e.children[0],a=typeof e.checked=="boolean"&&o&&o.type==="paragraph",u="["+(e.checked?"x":" ")+"] ",c=n.createTracker(r);a&&c.move(u);let d=xT.listItem(e,t,n,U(U({},r),c.current()));return a&&(d=d.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),d;function h(m){return m+u}}function ID(){return[l4(),O4(),L4(),bD(),CD()]}function RD(e){return{extensions:[c4(),I4(e),D4(),vD(e),kD()]}}const PD={tokenize:UD,partial:!0},ST={tokenize:HD,partial:!0},AT={tokenize:zD,partial:!0},vT={tokenize:jD,partial:!0},LD={tokenize:$D,partial:!0},CT={name:"wwwAutolink",tokenize:FD,previous:NT},kT={name:"protocolAutolink",tokenize:BD,previous:OT},Or={name:"emailAutolink",tokenize:MD,previous:IT},Er={};function DD(){return{text:Er}}let Vi=48;for(;Vi<123;)Er[Vi]=Or,Vi++,Vi===58?Vi=65:Vi===91&&(Vi=97);Er[43]=Or,Er[45]=Or,Er[46]=Or,Er[95]=Or,Er[72]=[Or,kT],Er[104]=[Or,kT],Er[87]=[Or,CT],Er[119]=[Or,CT];function MD(e,t,n){const r=this;let o,a;return u;function u(E){return!uh(E)||!IT.call(r,r.previous)||lh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return uh(E)?(e.consume(E),c):E===64?(e.consume(E),d):n(E)}function d(E){return E===46?e.check(LD,m,h)(E):E===45||E===95||Wt(E)?(a=!0,e.consume(E),d):m(E)}function h(E){return e.consume(E),o=!0,d}function m(E){return a&&o&&tn(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(E)):n(E)}}function FD(e,t,n){const r=this;return o;function o(u){return u!==87&&u!==119||!NT.call(r,r.previous)||lh(r.events)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(PD,e.attempt(ST,e.attempt(AT,a),n),n)(u))}function a(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function BD(e,t,n){const r=this;let o="",a=!1;return u;function u(E){return(E===72||E===104)&&OT.call(r,r.previous)&&!lh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(tn(E)&&o.length<5)return o+=String.fromCodePoint(E),e.consume(E),c;if(E===58){const T=o.toLowerCase();if(T==="http"||T==="https")return e.consume(E),d}return n(E)}function d(E){return E===47?(e.consume(E),a?h:(a=!0,d)):n(E)}function h(E){return E===null||Su(E)||it(E)||Oi(E)||Au(E)?n(E):e.attempt(ST,e.attempt(AT,m),n)(E)}function m(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function UD(e,t,n){let r=0;return o;function o(u){return(u===87||u===119)&&r<3?(r++,e.consume(u),o):u===46&&r===3?(e.consume(u),a):n(u)}function a(u){return u===null?n(u):t(u)}}function HD(e,t,n){let r,o,a;return u;function u(h){return h===46||h===95?e.check(vT,d,c)(h):h===null||it(h)||Oi(h)||h!==45&&Au(h)?d(h):(a=!0,e.consume(h),u)}function c(h){return h===95?r=!0:(o=r,r=void 0),e.consume(h),u}function d(h){return o||r||!a?n(h):t(h)}}function zD(e,t){let n=0,r=0;return o;function o(u){return u===40?(n++,e.consume(u),o):u===41&&r<n?a(u):u===33||u===34||u===38||u===39||u===41||u===42||u===44||u===46||u===58||u===59||u===60||u===63||u===93||u===95||u===126?e.check(vT,t,a)(u):u===null||it(u)||Oi(u)?t(u):(e.consume(u),o)}function a(u){return u===41&&r++,e.consume(u),o}}function jD(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),a):c===93?(e.consume(c),o):c===60||c===null||it(c)||Oi(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||it(c)||Oi(c)?t(c):r(c)}function a(c){return tn(c)?u(c):n(c)}function u(c){return c===59?(e.consume(c),r):tn(c)?(e.consume(c),u):n(c)}}function $D(e,t,n){return r;function r(a){return e.consume(a),o}function o(a){return Wt(a)?n(a):t(a)}}function NT(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||it(e)}function OT(e){return!tn(e)}function IT(e){return!(e===47||uh(e))}function uh(e){return e===43||e===45||e===46||e===95||Wt(e)}function lh(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 VD={tokenize:JD,partial:!0};function YD(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:KD,continuation:{tokenize:QD},exit:XD}},text:{91:{name:"gfmFootnoteCall",tokenize:GD},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:WD,resolveTo:qD}}}}function WD(e,t,n){const r=this;let o=r.events.length;const a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u;for(;o--;){const d=r.events[o][1];if(d.type==="labelImage"){u=d;break}if(d.type==="gfmFootnoteCall"||d.type==="labelLink"||d.type==="label"||d.type==="image"||d.type==="link")break}return c;function c(d){if(!u||!u._balanced)return n(d);const h=Wn(r.sliceSerialize({start:u.end,end:r.now()}));return h.codePointAt(0)!==94||!a.includes(h.slice(1))?n(d):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),t(d))}}function qD(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 a={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},u={type:"chunkString",contentType:"string",start:Object.assign({},a.start),end:Object.assign({},a.end)},c=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",a,t],["enter",u,t],["exit",u,t],["exit",a,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...c),e}function GD(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a=0,u;return c;function c(E){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(E),e.exit("gfmFootnoteCallLabelMarker"),d}function d(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(a>999||E===93&&!u||E===null||E===91||it(E))return n(E);if(E===93){e.exit("chunkString");const T=e.exit("gfmFootnoteCallString");return o.includes(Wn(r.sliceSerialize(T)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(E),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(E)}return it(E)||(u=!0),a++,e.consume(E),E===92?m:h}function m(E){return E===91||E===92||E===93?(e.consume(E),a++,h):h(E)}}function KD(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a,u=0,c;return d;function d(_){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(u>999||_===93&&!c||_===null||_===91||it(_))return n(_);if(_===93){e.exit("chunkString");const w=e.exit("gfmFootnoteDefinitionLabelString");return a=Wn(r.sliceSerialize(w)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(_),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),T}return it(_)||(c=!0),u++,e.consume(_),_===92?E:m}function E(_){return _===91||_===92||_===93?(e.consume(_),u++,m):m(_)}function T(_){return _===58?(e.enter("definitionMarker"),e.consume(_),e.exit("definitionMarker"),o.includes(a)||o.push(a),Ke(e,b,"gfmFootnoteDefinitionWhitespace")):n(_)}function b(_){return t(_)}}function QD(e,t,n){return e.check(Ds,t,e.attempt(VD,t,n))}function XD(e){e.exit("gfmFootnoteDefinition")}function JD(e,t,n){const r=this;return Ke(e,o,"gfmFootnoteDefinitionIndent",5);function o(a){const u=r.events[r.events.length-1];return u&&u[1].type==="gfmFootnoteDefinitionIndent"&&u[2].sliceSerialize(u[1],!0).length===4?t(a):n(a)}}function ZD(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:a,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function o(u,c){let d=-1;for(;++d<u.length;)if(u[d][0]==="enter"&&u[d][1].type==="strikethroughSequenceTemporary"&&u[d][1]._close){let h=d;for(;h--;)if(u[h][0]==="exit"&&u[h][1].type==="strikethroughSequenceTemporary"&&u[h][1]._open&&u[d][1].end.offset-u[d][1].start.offset===u[h][1].end.offset-u[h][1].start.offset){u[d][1].type="strikethroughSequence",u[h][1].type="strikethroughSequence";const m={type:"strikethrough",start:Object.assign({},u[h][1].start),end:Object.assign({},u[d][1].end)},E={type:"strikethroughText",start:Object.assign({},u[h][1].end),end:Object.assign({},u[d][1].start)},T=[["enter",m,c],["enter",u[h][1],c],["exit",u[h][1],c],["enter",E,c]],b=c.parser.constructs.insideSpan.null;b&&xn(T,T.length,0,vu(b,u.slice(h+1,d),c)),xn(T,T.length,0,[["exit",E,c],["enter",u[d][1],c],["exit",u[d][1],c],["exit",m,c]]),xn(u,h-1,d-h+3,T),d=h+T.length-2;break}}for(d=-1;++d<u.length;)u[d][1].type==="strikethroughSequenceTemporary"&&(u[d][1].type="data");return u}function a(u,c,d){const h=this.previous,m=this.events;let E=0;return T;function T(_){return h===126&&m[m.length-1][1].type!=="characterEscape"?d(_):(u.enter("strikethroughSequenceTemporary"),b(_))}function b(_){const w=yo(h);if(_===126)return E>1?d(_):(u.consume(_),E++,b);if(E<2&&!n)return d(_);const A=u.exit("strikethroughSequenceTemporary"),C=yo(_);return A._open=!C||C===2&&!!w,A._close=!w||w===2&&!!C,c(_)}}}class e5{constructor(){this.map=[]}add(t,n,r){t5(this,t,n,r)}consume(t){if(this.map.sort(function(a,u){return a[0]-u[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 a of o)t.push(a);o=r.pop()}this.map.length=0}}function t5(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 a=r.length-1;r[a]=r[a]==="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 r5(){return{flow:{null:{name:"table",tokenize:i5,resolveAll:o5}}}}function i5(e,t,n){const r=this;let o=0,a=0,u;return c;function c(j){let ae=r.events.length-1;for(;ae>-1;){const ue=r.events[ae][1].type;if(ue==="lineEnding"||ue==="linePrefix")ae--;else break}const he=ae>-1?r.events[ae][1].type:null,ge=he==="tableHead"||he==="tableRow"?D:d;return ge===D&&r.parser.lazy[r.now().line]?n(j):ge(j)}function d(j){return e.enter("tableHead"),e.enter("tableRow"),h(j)}function h(j){return j===124||(u=!0,a+=1),m(j)}function m(j){return j===null?n(j):Le(j)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(j),e.exit("lineEnding"),b):n(j):qe(j)?Ke(e,m,"whitespace")(j):(a+=1,u&&(u=!1,o+=1),j===124?(e.enter("tableCellDivider"),e.consume(j),e.exit("tableCellDivider"),u=!0,m):(e.enter("data"),E(j)))}function E(j){return j===null||j===124||it(j)?(e.exit("data"),m(j)):(e.consume(j),j===92?T:E)}function T(j){return j===92||j===124?(e.consume(j),E):E(j)}function b(j){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(j):(e.enter("tableDelimiterRow"),u=!1,qe(j)?Ke(e,_,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(j):_(j))}function _(j){return j===45||j===58?A(j):j===124?(u=!0,e.enter("tableCellDivider"),e.consume(j),e.exit("tableCellDivider"),w):z(j)}function w(j){return qe(j)?Ke(e,A,"whitespace")(j):A(j)}function A(j){return j===58?(a+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(j),e.exit("tableDelimiterMarker"),C):j===45?(a+=1,C(j)):j===null||Le(j)?F(j):z(j)}function C(j){return j===45?(e.enter("tableDelimiterFiller"),I(j)):z(j)}function I(j){return j===45?(e.consume(j),I):j===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(j),e.exit("tableDelimiterMarker"),R):(e.exit("tableDelimiterFiller"),R(j))}function R(j){return qe(j)?Ke(e,F,"whitespace")(j):F(j)}function F(j){return j===124?_(j):j===null||Le(j)?!u||o!==a?z(j):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(j)):z(j)}function z(j){return n(j)}function D(j){return e.enter("tableRow"),q(j)}function q(j){return j===124?(e.enter("tableCellDivider"),e.consume(j),e.exit("tableCellDivider"),q):j===null||Le(j)?(e.exit("tableRow"),t(j)):qe(j)?Ke(e,q,"whitespace")(j):(e.enter("data"),ce(j))}function ce(j){return j===null||j===124||it(j)?(e.exit("data"),q(j)):(e.consume(j),j===92?be:ce)}function be(j){return j===92||j===124?(e.consume(j),ce):ce(j)}}function o5(e,t){let n=-1,r=!0,o=0,a=[0,0,0,0],u=[0,0,0,0],c=!1,d=0,h,m,E;const T=new e5;for(;++n<e.length;){const b=e[n],_=b[1];b[0]==="enter"?_.type==="tableHead"?(c=!1,d!==0&&(RT(T,t,d,h,m),m=void 0,d=0),h={type:"table",start:Object.assign({},_.start),end:Object.assign({},_.end)},T.add(n,0,[["enter",h,t]])):_.type==="tableRow"||_.type==="tableDelimiterRow"?(r=!0,E=void 0,a=[0,0,0,0],u=[0,n+1,0,0],c&&(c=!1,m={type:"tableBody",start:Object.assign({},_.start),end:Object.assign({},_.end)},T.add(n,0,[["enter",m,t]])),o=_.type==="tableDelimiterRow"?2:m?3:1):o&&(_.type==="data"||_.type==="tableDelimiterMarker"||_.type==="tableDelimiterFiller")?(r=!1,u[2]===0&&(a[1]!==0&&(u[0]=u[1],E=El(T,t,a,o,void 0,E),a=[0,0,0,0]),u[2]=n)):_.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(u[0]=u[1],E=El(T,t,a,o,void 0,E)),a=u,u=[a[1],n,0,0])):_.type==="tableHead"?(c=!0,d=n):_.type==="tableRow"||_.type==="tableDelimiterRow"?(d=n,a[1]!==0?(u[0]=u[1],E=El(T,t,a,o,n,E)):u[1]!==0&&(E=El(T,t,u,o,n,E)),o=0):o&&(_.type==="data"||_.type==="tableDelimiterMarker"||_.type==="tableDelimiterFiller")&&(u[3]=n)}for(d!==0&&RT(T,t,d,h,m),T.consume(t.events),n=-1;++n<t.events.length;){const b=t.events[n];b[0]==="enter"&&b[1].type==="table"&&(b[1]._align=n5(t.events,n))}return e}function El(e,t,n,r,o,a){const u=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(a.end=Object.assign({},Yo(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const d=Yo(t.events,n[1]);if(a={type:u,start:Object.assign({},d),end:Object.assign({},d)},e.add(n[1],0,[["enter",a,t]]),n[2]!==0){const h=Yo(t.events,n[2]),m=Yo(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 T=t.events[n[2]],b=t.events[n[3]];if(T[1].end=Object.assign({},b[1].end),T[1].type="chunkText",T[1].contentType="text",n[3]>n[2]+1){const _=n[2]+1,w=n[3]-n[2]-1;e.add(_,w,[])}}e.add(n[3]+1,0,[["exit",E,t]])}return o!==void 0&&(a.end=Object.assign({},Yo(t.events,o)),e.add(o,0,[["exit",a,t]]),a=void 0),a}function RT(e,t,n,r,o){const a=[],u=Yo(t.events,n);o&&(o.end=Object.assign({},u),a.push(["exit",o,t])),r.end=Object.assign({},u),a.push(["exit",r,t]),e.add(n+1,0,a)}function Yo(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const s5={name:"tasklistCheck",tokenize:u5};function a5(){return{text:{91:s5}}}function u5(e,t,n){const r=this;return o;function o(d){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(d):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(d),e.exit("taskListCheckMarker"),a)}function a(d){return it(d)?(e.enter("taskListCheckValueUnchecked"),e.consume(d),e.exit("taskListCheckValueUnchecked"),u):d===88||d===120?(e.enter("taskListCheckValueChecked"),e.consume(d),e.exit("taskListCheckValueChecked"),u):n(d)}function u(d){return d===93?(e.enter("taskListCheckMarker"),e.consume(d),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),c):n(d)}function c(d){return Le(d)?t(d):qe(d)?e.check({tokenize:l5},t,n)(d):n(d)}}function l5(e,t,n){return Ke(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function c5(e){return Z0([DD(),YD(),ZD(e),r5(),a5()])}const d5={};function f5(e){const t=this,n=e||d5,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),u=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push(c5(n)),a.push(ID()),u.push(RD(n))}const h5=()=>L.jsx("span",{className:`${J}-blinking-cursor`,children:L.jsx("svg",{height:"16px",width:"16px",xmlns:"http://www.w3.org/2000/svg",children:L.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),ch=({globalClassName:e,openLinksInNewTab:t,showIsLoading:n,text:r})=>L.jsx($g,{remarkPlugins:[f5],rehypePlugins:[tE],components:{h1:({children:o})=>L.jsx("h1",{className:oe(e,`${J}-header h1`),children:o}),h2:({children:o})=>L.jsx("h2",{className:oe(e,`${J}-header h2`),children:o}),h3:({children:o})=>L.jsx("h3",{className:oe(e,`${J}-header h3`),children:o}),ul:({children:o})=>L.jsx("ul",{className:oe(e,`${J}-ul`),children:o}),ol:({children:o})=>L.jsx("ol",{className:oe(e,`${J}-ol`),children:o}),li:({children:o})=>L.jsx("li",{className:oe(e,`${J}-li`),children:o}),a:({href:o,children:a})=>L.jsx(uE,{globalClassName:e,openLinksInNewTab:t,href:o,children:a}),table:({children:o})=>L.jsx("div",{className:oe(e,`${J}-table-container`),children:L.jsx("table",{className:oe(e,`${J}-table`),children:o})}),thead:({children:o})=>L.jsx("thead",{className:oe(e,`${J}-thead`),children:o}),tbody:({children:o})=>L.jsx("tbody",{className:oe(e,`${J}-tbody`),children:o}),tr:({children:o})=>L.jsx("tr",{className:oe(e,`${J}-tr`),children:o}),th:({children:o})=>L.jsx("th",{className:oe(e,`${J}-th`),children:o}),td:({children:o})=>L.jsx("td",{className:oe(e,`${J}-td`),children:o}),span:({className:o,children:a})=>o===`${J}-blinking-cursor`?L.jsx(h5,{}):L.jsx("span",{children:a})},children:r+(n?`<span className='${J}-blinking-cursor'></span>`:"")}),p5=["Hey there! 👋 What can I find for you today?","Shopping for a gift? Tell me your budget and preferences","Need help? Connect to an agent"],m5=3e3,g5=400,E5=({globalClassName:e,isWidgetStandalone:t,messages:n=p5})=>{const[r,o]=ee.useState(0),[a,u]=ee.useState(!0);return ee.useEffect(()=>{let c;const d=setInterval(()=>{u(!1),c=setTimeout(()=>{o(h=>(h+1)%n.length),u(!0)},g5)},m5);return()=>{clearInterval(d),clearTimeout(c)}},[n.length]),L.jsxs("div",{className:oe(e,`${J}-connecting-indicator`,t?"standalone":"embedded"),role:"status","aria-label":"Connecting to assistant",children:[L.jsxs("div",{className:`${J}-connecting-pulse-wrapper`,children:[L.jsx("div",{className:`${J}-connecting-pulse`}),L.jsx("div",{className:`${J}-connecting-ring`})]}),L.jsx("span",{className:oe(`${J}-connecting-text`,a&&`${J}-connecting-text--visible`),children:n[r]})]})},y5=({shouldShow:e,loadingText:t})=>e?L.jsx("span",{className:`${J}-processing-text`,children:t}):null,T5=({shouldShow:e})=>e?L.jsxs(L.Fragment,{children:[L.jsx("div",{className:`${J}-processing-shimmer-bar`}),L.jsx("div",{className:`${J}-processing-shimmer-bar`}),L.jsx("div",{className:`${J}-processing-shimmer-bar`})]}):null,b5=({globalClassName:e,isWidgetStandalone:t,loadingText:n})=>L.jsxs("div",{className:oe(e,`${J}-processing-indicator`,t?"standalone":"embedded"),role:"status","aria-label":n||"Loading response",children:[L.jsx(y5,{shouldShow:!!n,loadingText:n}),L.jsx(T5,{shouldShow:!n})]}),yl=(e,t)=>{if(typeof e!="number")return null;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t||"USD"}).format(e)}catch(n){return`${e}`}},PT=({product:e,globalClassName:t,isFullWidth:n,openLinksInNewTab:r})=>{const{name:o,imageUrl:a,productPageUrl:u,price:c,discountPrice:d,compareAtPrice:h,currencyCode:m}=e,E=typeof d=="number"&&typeof c=="number"&&d<c,T=yl(E?d:c,m),b=yl(E?c:h,m);return L.jsxs("div",{className:oe(t,`${J}-msg-product-card`,{"card-full-width":n}),children:[L.jsx("div",{className:oe(t,`${J}-msg-product-card__image-wrapper`),children:a&&(u?L.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer","aria-label":`Go to product page for ${o}`,children:L.jsx("img",{className:oe(t,`${J}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"})}):L.jsx("img",{className:oe(t,`${J}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"}))}),L.jsxs("div",{className:oe(t,`${J}-msg-product-card__content`),children:[u?L.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer",className:oe(t,`${J}-msg-product-card__title-link`),"aria-label":`Go to product page for ${o}`,children:o}):L.jsx("p",{className:oe(t,`${J}-msg-product-card__title`),children:o}),L.jsx("div",{className:oe(t,`${J}-msg-product-card__price-row`),children:L.jsxs("div",{className:oe(t,`${J}-msg-product-card__prices`),children:[T&&L.jsx("span",{className:oe(t,`${J}-msg-product-card__price`),children:T}),b&&L.jsx("span",{className:oe(t,`${J}-msg-product-card__compare-price`),children:b})]})})]})]})},LT=e=>({id:e.id,name:e.data.name,label:e.caption,description:e.data.description,imageUrl:e.data.imageUrl,productPageUrl:e.data.productPageUrl,price:e.data.price,discountPrice:e.data.discountPrice,currencyCode:e.data.currencyCode}),x5=({title:e,products:t,globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o})=>{if(t.length===1){const a=t[0];return L.jsxs("div",{children:[e&&L.jsx("p",{className:oe(n,`${J}-product-carousel-title`),children:e}),L.jsx(PT,{product:LT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o,isFullWidth:!o})]})}return L.jsxs("div",{style:{marginBottom:"1rem"},children:[e&&L.jsx("p",{className:oe(n,`${J}-product-carousel-title`),children:e}),L.jsx(F6,{globalClassName:n,spacing:o?"0.5rem":"6px",ariaLabel:e||"Product recommendations",children:t.map(a=>L.jsx(PT,{product:LT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o},a.id))})]})},_5=({content:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{sendMessage:o,loading:a}=ki();return L.jsx(L.Fragment,{children:e.response.map((u,c)=>{var d,h;switch(u.type){case"markdown":return L.jsx(ch,{text:u.data.content,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1},`${u.type}-${c}`);case"product_carousel":return L.jsx(x5,{title:u.data.title,products:u.data.products,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(d=u.index)!=null?d:c}`);case"suggestions":return L.jsx("div",{style:{marginTop:"0.5rem"},children:L.jsx(n4,{disabled:a,suggestions:u.data.display_text,globalClassName:t,isWidgetStandalone:r,onSuggestionClick:o})},`${u.type}-${(h=u.index)!=null?h:c}`);default:return null}})})},w5=({message:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const o=ee.useMemo(()=>{try{const a=JSON.parse(e.content);return Array.isArray(a==null?void 0:a.response)?a:null}catch(a){return null}},[e.content]);switch(e.role){case"user":return L.jsx("div",{className:oe(t,`${J}-message`,r?"standalone":"embedded"),children:L.jsx("div",{className:oe(t,`${J}-user-message`,r?"standalone":"embedded"),children:L.jsxs("div",{className:oe(t,`${J}-user-message-row`,r?"standalone":"embedded"),children:[L.jsx("span",{className:oe(t,`${J}-message-icon user-message-icon`,r?"standalone":"embedded"),children:L.jsx(GS,{})}),L.jsx("p",{className:oe(t,`${J}-user-message-text`,r?"standalone":"embedded"),children:e.content})]})})});case"agent":return L.jsx("div",{className:oe(t,`${J}-message-group`,r?"standalone":"embedded"),children:L.jsx("div",{className:`${J}-message-group-child`,children:o?L.jsx(_5,{content:o,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r}):L.jsx(ch,{text:e.content,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})})});case"system":return L.jsx("div",{className:oe(t,`${J}-message`,r?"standalone":"embedded"),children:L.jsx("p",{className:oe(t,`${J}-reset-message`),children:e.content})})}},dh=({isWidgetStandalone:e})=>{const{globalClassName:t,openLinksInNewTab:n}=en(),{messages:r,streamingContent:o,isAgentTyping:a,loading:u,progressMessage:c}=ki(),d=ee.useRef(null),h=r.length>0;return ee.useEffect(()=>{var m;(m=d.current)==null||m.scrollIntoView({behavior:"smooth"})},[r,o]),L.jsxs(L.Fragment,{children:[u&&!h&&L.jsx(E5,{globalClassName:t,isWidgetStandalone:e}),r.map(m=>L.jsx(w5,{message:m,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e},m.id)),o&&L.jsx("div",{className:oe(t,`${J}-message-group`,e?"standalone":"embedded"),children:L.jsx(ch,{text:o,globalClassName:t,openLinksInNewTab:n,showIsLoading:!0})}),h&&(u||a)&&!o&&L.jsx(b5,{globalClassName:t,isWidgetStandalone:e,loadingText:c}),L.jsx("div",{ref:d})]})},DT=()=>{const{globalClassName:e,themeVariables:t}=en(),{isAgentTyping:n,sendMessage:r,resetConversation:o}=ki(),a=n;return L.jsxs("div",{className:oe(e,`${J}-container`,`${J}-embedded-chat`),style:t,children:[L.jsx("div",{className:oe(e,`${J}-message-container`,"embedded"),children:L.jsx(dh,{isWidgetStandalone:!1})}),L.jsx(mf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:u=>r(u)}),L.jsx("div",{className:oe(`${J}-embedded-chat-menu`),children:L.jsxs(Ny,{componentType:"chat",children:[L.jsx(nT,{componentType:"chat"}),L.jsx(cE,{componentType:"chat",onClearChat:o})]})})]})},MT=e=>{var d;const{children:t,disabled:n}=e,[r,o]=ee.useState((d=e.container)==null?void 0:d.current),a=ee.useSyncExternalStore(A5,()=>!1,()=>!0),{getRootNode:u}=hl();if(ee.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),a||n)return L.jsx(L.Fragment,{children:t});const c=r!=null?r:S5(u);return L.jsx(L.Fragment,{children:ee.Children.map(t,h=>ks.createPortal(h,c))})},S5=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Fi(n)?n:cr(t).body},A5=()=>()=>{},FT=()=>{const{globalClassName:e,themeVariables:t}=en(),{mode:n,status:r,dialogPosition:o,isDialogFullHeight:a,dialogWidth:u}=Ci(),{loading:c,isAgentTyping:d,sendMessage:h,resetConversation:m}=ki(),{isOpen:E}=r||{},T=!!r.isOpen,b=n==="standalone",_=d||c,w=()=>{vi(!1)};return L.jsx(Zy,{lazyMount:!0,unmountOnExit:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:T,children:L.jsx(MT,{children:L.jsx(Jf,{className:oe(e,`${J}-container`,`${J}-dialog`,o,a&&"full-height"),style:U(U({},t),u&&{width:u}),children:L.jsxs(Qf,{className:oe(e,`${J}-dialog-content`,{standalone:b,embedded:!b}),children:[L.jsx(tT,{componentType:"dialog",onClearChat:m,onClose:w}),L.jsx(Xf,{className:oe(e,`${J}-message-container`,{standalone:b,embedded:!b}),children:L.jsx(dh,{isWidgetStandalone:b,isOpen:E})}),L.jsx(mf,{componentType:"dialog",isLoading:_,onSubmit:A=>h(A)})]})})})})},BT=()=>{const{globalClassName:e,themeVariables:t}=en(),{mode:n,status:r,isModalFullscreen:o}=Ci(),{isAgentTyping:a,sendMessage:u,resetConversation:c}=ki(),{isOpen:d}=r||{},h=!!r.isOpen,m=n==="standalone",E=a,T=({open:_})=>{vi(_)},b=()=>{vi(!1)};return L.jsx(Zy,{lazyMount:!0,unmountOnExit:!0,open:h,onOpenChange:T,children:L.jsx(MT,{children:L.jsxs("div",{className:oe(e,`${J}-modal-container`),style:t,children:[L.jsx(Gy,{className:oe(e,`${J}-modal-backdrop`)}),L.jsx(Jf,{className:oe(e,`${J}-container`,`${J}-modal`,{fullscreen:o,standalone:m,embedded:!m}),children:L.jsxs(Qf,{className:oe(e,`${J}-modal-content`,{standalone:m,embedded:!m}),children:[L.jsx(tT,{componentType:"modal",onClearChat:c,onClose:b}),L.jsx(Xf,{className:oe(e,`${J}-message-container`,{standalone:m,embedded:!m}),children:L.jsx(dh,{isWidgetStandalone:m,isOpen:d})}),L.jsx(mf,{componentType:"modal",isLoading:E,onSubmit:_=>u(_)})]})})]})})})},v5=()=>{const e=Ci(),{status:{type:t,isMinimized:n}}=e||{status:{}};return n?L.jsx(BS,{}):t==="dialog"?L.jsx(FT,{}):t==="modal"?L.jsx(BT,{}):L.jsx(DT,{})},fh=e=>L.jsx(u0,ne(U({},e),{children:L.jsx(v5,{})}));var Tl={},UT;function C5(){if(UT)return Tl;UT=1;var e=h0();return Tl.createRoot=e.createRoot,Tl.hydrateRoot=e.hydrateRoot,Tl}var HT=C5();const k5=r=>{var o=r,{elementId:e,timeout:t=5e3}=o,n=on(o,["elementId","timeout"]);let a;const u=(d,h)=>{var m;for(const E of d)if(E.type==="childList"&&E.addedNodes.length)for(const T of E.addedNodes)T.nodeType===Node.ELEMENT_NODE&&T.id===e&&(Ai(!0,"log","Target element found, rendering Messaging Widget"),h.disconnect(),clearTimeout(a),(m=HT.createRoot(T))==null||m.render(L.jsx(fh,ne(U({},n),{mode:"messaging"}))))},c=new MutationObserver(u);return c.observe(document.body,{childList:!0,subtree:!0}),a=setTimeout(()=>{c.disconnect(),Ai(!0,"error",`Element with id: ${e} not found within ${t} milliseconds, stopping observation`)},t),c},N5=r=>{var o=r,{timeout:e,elementId:t}=o,n=on(o,["timeout","elementId"]);if(!n.messagingConfig){Ai(!0,"error","Messaging Widget requires messagingConfig");return}if(!n.messagingConfig.scrt2Url||!n.messagingConfig.orgId||!n.messagingConfig.esDeveloperName){Ai(!0,"error","Messaging Widget requires messagingConfig.scrt2Url, messagingConfig.orgId, and messagingConfig.esDeveloperName");return}const a=document.getElementById(t);if(!a){Ai(!0,"warn","Container element not found for id:",t),Ai(!0,"warn","Beginning observation for element"),k5(U({elementId:t,timeout:e},n));return}HT.createRoot(a).render(L.jsx(fh,ne(U({},n),{mode:"messaging"})))},O5={components:{setEntryType:s0,toggleWidgetOpen:vi,toggleWidgetMinimized:yu,toggleModalFullscreen:dd,setWidgetType:Tu,setWidgetDialogPosition:fd}};Ie.AgentForceWidget=fh,Ie.AgentforceWidgetProvider=u0,Ie.MessagingDialog=FT,Ie.MessagingEmbed=DT,Ie.MessagingModal=BT,Ie.MessagingProvider=o0,Ie.eventHandlers=O5,Ie.injectMessagingWidget=N5,Ie.useMessaging=ki,Object.defineProperty(Ie,Symbol.toStringTag,{value:"Module"})}));