@cimulate/copilot-widget 1.12.0 → 1.12.2

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(Re,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Re=typeof globalThis!="undefined"?globalThis:Re||self,Fe(Re.CimulateMessaging={}))})(this,(function(Re){"use strict";var L9=Object.defineProperty,D9=Object.defineProperties;var M9=Object.getOwnPropertyDescriptors;var Fc=Object.getOwnPropertySymbols;var X2=Object.prototype.hasOwnProperty,J2=Object.prototype.propertyIsEnumerable;var Ts=(Re,Fe)=>(Fe=Symbol[Re])?Fe:Symbol.for("Symbol."+Re),F9=Re=>{throw TypeError(Re)},nu=Math.pow,Tm=(Re,Fe,We)=>Fe in Re?L9(Re,Fe,{enumerable:!0,configurable:!0,writable:!0,value:We}):Re[Fe]=We,H=(Re,Fe)=>{for(var We in Fe||(Fe={}))X2.call(Fe,We)&&Tm(Re,We,Fe[We]);if(Fc)for(var We of Fc(Fe))J2.call(Fe,We)&&Tm(Re,We,Fe[We]);return Re},ae=(Re,Fe)=>D9(Re,M9(Fe));var sn=(Re,Fe)=>{var We={};for(var rt in Re)X2.call(Re,rt)&&Fe.indexOf(rt)<0&&(We[rt]=Re[rt]);if(Re!=null&&Fc)for(var rt of Fc(Re))Fe.indexOf(rt)<0&&J2.call(Re,rt)&&(We[rt]=Re[rt]);return We};var Ze=(Re,Fe,We)=>Tm(Re,typeof Fe!="symbol"?Fe+"":Fe,We);var $e=(Re,Fe,We)=>new Promise((rt,yt)=>{var dt=Tt=>{try{Lt(We.next(Tt))}catch(an){yt(an)}},Pe=Tt=>{try{Lt(We.throw(Tt))}catch(an){yt(an)}},Lt=Tt=>Tt.done?rt(Tt.value):Promise.resolve(Tt.value).then(dt,Pe);Lt((We=We.apply(Re,Fe)).next())}),uo=function(Re,Fe){this[0]=Re,this[1]=Fe},xm=(Re,Fe,We)=>{var rt=(Pe,Lt,Tt,an)=>{try{var lo=We[Pe](Lt),xs=(Lt=lo.value)instanceof uo,Bc=lo.done;Promise.resolve(xs?Lt[0]:Lt).then($n=>xs?rt(Pe==="return"?Pe:"next",Lt[1]?{done:$n.done,value:$n.value}:$n,Tt,an):Tt({value:$n,done:Bc})).catch($n=>rt("throw",$n,Tt,an))}catch($n){an($n)}},yt=Pe=>dt[Pe]=Lt=>new Promise((Tt,an)=>rt(Pe,Lt,Tt,an)),dt={};return We=We.apply(Re,Fe),dt[Ts("asyncIterator")]=()=>dt,yt("next"),yt("throw"),yt("return"),dt},wm=Re=>{var Fe=Re[Ts("asyncIterator")],We=!1,rt,yt={};return Fe==null?(Fe=Re[Ts("iterator")](),rt=dt=>yt[dt]=Pe=>Fe[dt](Pe)):(Fe=Fe.call(Re),rt=dt=>yt[dt]=Pe=>{if(We){if(We=!1,dt==="throw")throw Pe;return Pe}return We=!0,{done:!1,value:new uo(new Promise(Lt=>{var Tt=Fe[dt](Pe);Tt instanceof Object||F9("Object expected"),Lt(Tt)}),1)}}),yt[Ts("iterator")]=()=>yt,rt("next"),"throw"in Fe?rt("throw"):yt.throw=dt=>{throw dt},"return"in Fe&&rt("return"),yt},Z2=(Re,Fe,We)=>(Fe=Re[Ts("asyncIterator")])?Fe.call(Re):(Re=Re[Ts("iterator")](),Fe={},We=(rt,yt)=>(yt=Re[rt])&&(Fe[rt]=dt=>new Promise((Pe,Lt,Tt)=>(dt=yt.call(Re,dt),Tt=dt.done,Promise.resolve(dt.value).then(an=>Pe({value:an,done:Tt}),Lt)))),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;height:auto;line-height:normal;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:.25rem;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;height:auto;line-height:normal;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}input.cim-widget-search-input{width:100%;height:stretch;min-width:0;min-height:2rem;padding:0 8px;background-color:transparent;border:1px solid #00000040;border-radius:var(--cim-widget-border-radius)}@media(max-width:576px){input.cim-widget-search-input{font-size:16px}}.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;background-color:#f0f0f080;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;padding:1rem 0;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;&:hover{color:var(--cim-widget-font-color, #1a202c)}}.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;height:auto;line-height:normal;border-radius:var(--cim-widget-border-radius);border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-overflow-panel{position:absolute;top:100%;left:0;right:0;display:flex;flex-direction:column;gap:.5rem;padding:.5rem;background:#fff;border-bottom:1px solid var(--cim-widget-border-color);z-index:10}.cim-widget-overflow-panel .cim-widget-overflow-menu-button{width:100%;justify-content:center;gap:.75rem;font-size:.875rem}.cim-widget-left-right-toggle-button{display:none}@media(min-width:576px){.cim-widget-left-right-toggle-button{display:inline-flex}}.cim-widget-price{display:flex;align-items:baseline;gap:.4em;flex-wrap:wrap;font-family:var(--cim-widget-font-family, sans-serif)}.cim-widget-price__amount{font-weight:700;font-size:1em;line-height:1.2;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-price__compare{font-weight:400;font-size:.85em;line-height:1.2;color:var(--cim-widget-font-color, #3f3f46);opacity:.6;text-decoration:line-through}.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-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-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-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-cart{display:flex;flex-direction:column;gap:12px;width:100%;padding:16px;background-color:var(--cim-widget-background-color, #ffffff);border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);font-family:var(--cim-widget-font-family, sans-serif);color:var(--cim-widget-font-color, #3f3f46);box-sizing:border-box}.cim-widget-cart *{box-sizing:border-box}.cim-widget-cart-banner{display:flex;align-items:flex-start;gap:10px}.cim-widget-cart-banner-icon{flex:0 0 auto;display:flex;align-items:center;justify-content:center;width:24px;height:24px;border-radius:4px;background-color:#2e844a;color:#fff}.cim-widget-cart-banner-icon svg{width:16px;height:16px}.cim-widget-cart-banner-text{margin:0;font-size:.875rem;font-weight:500;line-height:1.4}.cim-widget-cart-summary{display:flex;align-items:center;justify-content:space-between;gap:8px;width:100%;padding:12px 16px;border:none;background-color:transparent;font-family:inherit;color:inherit;text-align:left;cursor:pointer}.cim-widget-cart-summary-text{flex:1 1 auto;min-width:0;font-size:.8125rem;line-height:1.4}.cim-widget-cart-summary-text p{margin:0}.cim-widget-cart-summary-toggle{flex:0 0 auto;display:flex;align-items:center;justify-content:center;opacity:.6}.cim-widget-cart-summary-toggle svg{width:20px;height:20px}.cim-widget-cart-box{display:flex;flex-direction:column;border:1px solid var(--cim-widget-border-color, #e4e4e7);border-radius:var(--cim-widget-border-radius)}.cim-widget-cart-expanded{display:flex;flex-direction:column;padding:0 16px;border-top:1px solid var(--cim-widget-border-color, #e4e4e7)}.cim-widget-cart-items{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}.cim-widget-cart-item{display:flex;align-items:flex-start;gap:12px;padding:12px 0;border-top:1px solid var(--cim-widget-border-color, #e4e4e7)}.cim-widget-cart-item:first-child{border-top:none}.cim-widget-cart-item-image{flex:0 0 auto;width:64px;height:64px;border-radius:4px;overflow:hidden;background-color:#f4f4f5}.cim-widget-cart-item-image img{width:100%;height:100%;object-fit:cover;display:block}.cim-widget-cart-item-details{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;gap:6px}.cim-widget-cart-item-name{margin:0;font-size:.875rem;font-weight:600;line-height:1.3;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical}.cim-widget-cart-item-attrs{display:flex;flex-direction:column;gap:6px;margin-top:-3px}.cim-widget-cart-item-attrs p.cim-widget-cart-item-attr,.cim-widget-cart-item-attr{margin:0;font-size:.75rem;line-height:1.3;opacity:.7}.cim-widget-cart-item-attrs p.cim-widget-cart-item-attr+p.cim-widget-cart-item-attr{margin-top:0}.cim-widget-cart-item-price{display:flex;align-items:baseline;gap:8px;white-space:nowrap}.cim-widget-cart-item-original-price{font-size:.875rem;opacity:.55;text-decoration:line-through}.cim-widget-cart-item-final-price{font-size:.875rem;font-weight:700}.cim-widget-cart-item-footer{display:flex;align-items:center;justify-content:space-between;gap:8px}.cim-widget-cart-item-qty{font-size:.75rem;font-weight:500;opacity:.85}.cim-widget-cart-item-remove{padding:0;border:none;background:none;font-family:inherit;font-size:.75rem;font-weight:500;color:var(--cim-widget-font-color, #3f3f46);text-decoration:underline;cursor:pointer}.cim-widget-cart-item-remove:hover:not(:disabled){opacity:.7}.cim-widget-cart-item-remove:disabled{opacity:.4;cursor:not-allowed}.cim-widget-cart-chips{display:flex;flex-wrap:wrap;gap:6px}.cim-widget-cart-applied-coupons{padding-top:12px;border-top:1px solid var(--cim-widget-border-color, #e4e4e7)}.cim-widget-cart-chip{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:4px;background-color:#f4f4f5;font-size:.6875rem;font-weight:500;line-height:1.2;letter-spacing:.02em}.cim-widget-cart-chip svg{width:12px;height:12px;opacity:.7}.cim-widget-cart-totals{display:flex;flex-direction:column;gap:6px;padding-top:12px;padding-bottom:16px}.cim-widget-cart-total-row{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:.8125rem;line-height:1.3}.cim-widget-cart-total-label{display:inline-flex;align-items:center;gap:8px;opacity:.85}.cim-widget-cart-total-badge{font-weight:700;opacity:1}.cim-widget-cart-total-row.emphasized{margin-top:4px;font-size:1rem;font-weight:700}.cim-widget-cart-total-row.emphasized .cim-widget-cart-total-label{opacity:1}.cim-widget-cart-coupon{display:flex;align-items:stretch;gap:8px}.cim-widget-cart-coupon-field{flex:1 1 auto;min-width:0;display:flex;align-items:center;gap:8px;padding:0 10px;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius)}.cim-widget-cart-coupon-icon{flex:0 0 auto;display:flex;align-items:center;opacity:.55}.cim-widget-cart-coupon-icon svg{width:16px;height:16px}.cim-widget-cart-coupon-input{flex:1 1 auto;min-width:0;padding:11px 0;border:none;outline:none;background:transparent;font-family:inherit;font-size:.8125rem;color:inherit}.cim-widget-cart-coupon-input::placeholder{opacity:.5}.cim-widget-cart-coupon-input:disabled{cursor:not-allowed}.cim-widget-cart-coupon-submit{flex:0 0 auto;display:flex;align-items:center;justify-content:center;width:44px;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);background-color:transparent;color:inherit;cursor:pointer;transition:background-color .15s ease}.cim-widget-cart-coupon-submit svg{width:16px;height:16px}.cim-widget-cart-coupon-submit:hover:not(:disabled){background-color:color-mix(in srgb,var(--cim-widget-font-color, #3f3f46) 8%,transparent)}.cim-widget-cart-coupon-submit:disabled{opacity:.4;cursor:not-allowed}.cim-widget-cart-checkout-button{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;padding:11px 16px;border:1px solid var(--cim-widget-font-color, #141415);border-radius:var(--cim-widget-border-radius);background-color:transparent;color:var(--cim-widget-font-color, #141415);font-family:inherit;font-size:.9375rem;font-weight:600;text-align:center;text-decoration:none;cursor:pointer;transition:background-color .15s ease}.cim-widget-cart-checkout-button svg{width:16px;height:16px}.cim-widget-cart-checkout-button:hover{background-color:color-mix(in srgb,var(--cim-widget-font-color, #141415) 6%,transparent);text-decoration:none}.cim-widget-cart-footer{margin:0;font-size:.75rem;line-height:1.3;opacity:.6;text-align:center}.cim-widget-pdp-gallery{position:relative;width:100%}.cim-widget-pdp-gallery__item-group{display:flex}.cim-widget-pdp-gallery__item{flex-shrink:0;width:100%}.cim-widget-pdp-gallery__image{width:100%;height:100%;aspect-ratio:1 / 1;object-fit:contain;display:block}.cim-widget-pdp-gallery__control{position:absolute;top:50%;left:0;right:0;transform:translateY(-50%);display:flex;justify-content:space-between;pointer-events:none;padding:0 8px}.cim-widget-pdp-gallery__prev-trigger,.cim-widget-pdp-gallery__next-trigger{pointer-events:auto;display:flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:50%;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 #00000026;transition:background-color .15s ease,box-shadow .15s ease}.cim-widget-pdp-gallery__prev-trigger:hover,.cim-widget-pdp-gallery__next-trigger:hover{box-shadow:0 2px 6px #0003}.cim-widget-pdp-gallery__indicator-group{display:flex;justify-content:center;gap:6px;padding-top:12px}.cim-widget-pdp-gallery__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-pdp-gallery__indicator[data-current]{background-color:var(--cim-widget-font-color, #1a202c);transform:scale(1.25)}.cim-widget-pdp-gallery__indicator:hover:not([data-current]){background-color:var(--cim-widget-font-color, #1a202c);opacity:.5}.cim-widget-msg-pdp{width:100%;margin:.5rem 0;font-family:var(--cim-widget-font-family, sans-serif);container:cim-pdp / inline-size}.cim-widget-msg-pdp__card{display:flex;flex-direction:column;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}.cim-widget-msg-pdp__content{display:flex;flex-direction:column;gap:1rem;padding:16px}.cim-widget-msg-pdp__title,.cim-widget-msg-pdp__title-link{font-weight:700;font-size:1rem;line-height:1.3;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46);margin:0}.cim-widget-msg-pdp__title-link{text-decoration:none}.cim-widget-msg-pdp__title-link:hover{text-decoration:underline}.cim-widget-msg-pdp__description{font-size:.75rem;line-height:1.4;color:var(--cim-widget-font-color, #3f3f46);opacity:.85;margin:0}.cim-widget-msg-pdp__variant{display:flex;flex-direction:column;gap:.75rem}.cim-widget-msg-pdp__variant-label{display:flex;align-items:baseline;gap:1rem;font-size:.875rem}.cim-widget-msg-pdp__variant-name{opacity:.7;color:var(--cim-widget-font-color, #3f3f46);white-space:nowrap}.cim-widget-msg-pdp__variant-value{color:var(--cim-widget-font-color, #3f3f46);font-weight:700}.cim-widget-msg-pdp__swatches,.cim-widget-msg-pdp__chips{display:flex;flex-wrap:wrap;gap:.25rem}button.cim-widget-msg-pdp__chip{min-width:34px;background-color:transparent;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);color:var(--cim-widget-font-color, #3f3f46);font-size:.875rem}button.cim-widget-msg-pdp__chip:hover:not(:disabled){background-color:#0000000a;border-color:var(--cim-widget-primary-color, #3182ce)}button.cim-widget-msg-pdp__chip.selected{background-color:var(--cim-widget-primary-color, #3182ce);border-color:var(--cim-widget-primary-color, #3182ce);color:#fff}button.cim-widget-msg-pdp__chip.selected:hover:not(:disabled){background-color:color-mix(in srgb,var(--cim-widget-primary-color, #3182ce),black 15%);border-color:color-mix(in srgb,var(--cim-widget-primary-color, #3182ce),black 15%);color:#fff}button.cim-widget-msg-pdp__chip.unavailable{opacity:.4;text-decoration:line-through}button.cim-widget-msg-pdp__chip:disabled{cursor:not-allowed}button.cim-widget-msg-pdp__swatch{width:36px;height:36px;min-width:36px;min-height:36px;padding:2px;border-radius:50%;background-color:transparent;border:1px solid var(--cim-widget-border-color, #d1d5db);overflow:hidden}button.cim-widget-msg-pdp__swatch:hover:not(:disabled){border-color:var(--cim-widget-font-color, #3f3f46)}button.cim-widget-msg-pdp__swatch.selected{border-width:2px;border-color:var(--cim-widget-font-color, #141415)}button.cim-widget-msg-pdp__swatch.unavailable{opacity:.3}button.cim-widget-msg-pdp__swatch:disabled{cursor:not-allowed}.cim-widget-msg-pdp__swatch-image{width:100%;height:100%;border-radius:50%;object-fit:cover;display:block}.cim-widget-msg-pdp__stepper{display:flex;align-items:center;gap:.25rem}button.cim-widget-msg-pdp__stepper-btn{border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-pdp__quantity{min-width:1.5rem;text-align:center;font-size:.95rem;font-weight:700;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-pdp__actions{display:flex;flex-direction:column;gap:.5rem;margin-top:.25rem}button.cim-widget-msg-pdp__express-pay{display:flex;align-items:center;justify-content:center;gap:.4rem;min-height:34px;background-color:var(--cim-widget-primary-color, #3182ce);border-color:var(--cim-widget-primary-color, #3182ce);color:#fff;font-weight:700}button.cim-widget-msg-pdp__add-to-cart{min-height:34px;background-color:transparent;border:1px solid var(--cim-widget-primary-color, #3182ce);color:var(--cim-widget-primary-color, #3182ce);font-weight:700;&:hover:disabled{background-color:transparent}}button.cim-widget-msg-pdp__add-to-cart:hover:not(:disabled){background-color:#0000000a}@container cim-pdp (max-width: 340px){.cim-widget-msg-pdp__content{padding:12px}.cim-widget-msg-pdp__title,.cim-widget-msg-pdp__title-link{font-size:.95rem}button.cim-widget-msg-pdp__chip{font-size:.75rem}button.cim-widget-msg-pdp__swatch,button.cim-widget-msg-pdp__stepper-btn{width:28px;height:28px;min-width:28px;min-height:28px}.cim-widget-msg-pdp__quantity{font-size:.85rem}button.cim-widget-msg-pdp__express-pay,button.cim-widget-msg-pdp__add-to-cart{min-height:36px;height:36px;font-size:.8rem}}@container cim-pdp (min-width: 480px){.cim-widget-msg-pdp__card{flex-direction:row;align-items:center;gap:.5rem}.cim-widget-msg-pdp__gallery{flex:0 0 50%;min-width:0;padding-bottom:1.5rem}.cim-widget-msg-pdp__content{flex:1 1 0;min-width:0}}.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);background-color:#fff}.cim-widget-overflow-menu-button.cim-chat-component{background-color:#fff;border-radius:var(--cim-widget-border-radius);&:hover{background-color:#f0f0f0}}.cim-widget-dialog{box-sizing:border-box;position:fixed;width:35dvw;max-width:100dvw;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;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;line-height:normal;font-size:var(--cim-widget-header-text-font-size)}@media(min-width:576px)and (max-width:768px){.cim-widget-dialog{width:50%}}@media(max-width:576px){.cim-widget-dialog{height:100%;width:100dvw!important;max-width:100dvw;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;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;line-height:normal;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;min-width:0;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;overflow-wrap:anywhere;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;line-height:normal;text-transform:none;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;line-height:normal;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:{}},yt={},dt={exports:{}},Pe={};var Lt;function Tt(){if(Lt)return Pe;Lt=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"),p=Symbol.for("react.lazy"),E=Symbol.iterator;function T(F){return F===null||typeof F!="object"?null:(F=E&&F[E]||F["@@iterator"],typeof F=="function"?F:null)}var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,_={};function S(F,te,k){this.props=F,this.context=te,this.refs=_,this.updater=k||y}S.prototype.isReactComponent={},S.prototype.setState=function(F,te){if(typeof F!="object"&&typeof F!="function"&&F!=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,F,te,"setState")},S.prototype.forceUpdate=function(F){this.updater.enqueueForceUpdate(this,F,"forceUpdate")};function A(){}A.prototype=S.prototype;function O(F,te,k){this.props=F,this.context=te,this.refs=_,this.updater=k||y}var R=O.prototype=new A;R.constructor=O,x(R,S.prototype),R.isPureReactComponent=!0;var z=Array.isArray,W=Object.prototype.hasOwnProperty,M={current:null},K={key:!0,ref:!0,__self:!0,__source:!0};function de(F,te,k){var pe,Se={},Ae=null,Be=null;if(te!=null)for(pe in te.ref!==void 0&&(Be=te.ref),te.key!==void 0&&(Ae=""+te.key),te)W.call(te,pe)&&!K.hasOwnProperty(pe)&&(Se[pe]=te[pe]);var ve=arguments.length-2;if(ve===1)Se.children=k;else if(1<ve){for(var qe=Array(ve),ut=0;ut<ve;ut++)qe[ut]=arguments[ut+2];Se.children=qe}if(F&&F.defaultProps)for(pe in ve=F.defaultProps,ve)Se[pe]===void 0&&(Se[pe]=ve[pe]);return{$$typeof:e,type:F,key:Ae,ref:Be,props:Se,_owner:M.current}}function xe(F,te){return{$$typeof:e,type:F.type,key:te,ref:F.ref,props:F.props,_owner:F._owner}}function D(F){return typeof F=="object"&&F!==null&&F.$$typeof===e}function ne(F){var te={"=":"=0",":":"=2"};return"$"+F.replace(/[=:]/g,function(k){return te[k]})}var J=/\/+/g;function re(F,te){return typeof F=="object"&&F!==null&&F.key!=null?ne(""+F.key):te.toString(36)}function oe(F,te,k,pe,Se){var Ae=typeof F;(Ae==="undefined"||Ae==="boolean")&&(F=null);var Be=!1;if(F===null)Be=!0;else switch(Ae){case"string":case"number":Be=!0;break;case"object":switch(F.$$typeof){case e:case t:Be=!0}}if(Be)return Be=F,Se=Se(Be),F=pe===""?"."+re(Be,0):pe,z(Se)?(k="",F!=null&&(k=F.replace(J,"$&/")+"/"),oe(Se,te,k,"",function(ut){return ut})):Se!=null&&(D(Se)&&(Se=xe(Se,k+(!Se.key||Be&&Be.key===Se.key?"":(""+Se.key).replace(J,"$&/")+"/")+F)),te.push(Se)),1;if(Be=0,pe=pe===""?".":pe+":",z(F))for(var ve=0;ve<F.length;ve++){Ae=F[ve];var qe=pe+re(Ae,ve);Be+=oe(Ae,te,k,qe,Se)}else if(qe=T(F),typeof qe=="function")for(F=qe.call(F),ve=0;!(Ae=F.next()).done;)Ae=Ae.value,qe=pe+re(Ae,ve++),Be+=oe(Ae,te,k,qe,Se);else if(Ae==="object")throw te=String(F),Error("Objects are not valid as a React child (found: "+(te==="[object Object]"?"object with keys {"+Object.keys(F).join(", ")+"}":te)+"). If you meant to render a collection of children, use an array instead.");return Be}function be(F,te,k){if(F==null)return F;var pe=[],Se=0;return oe(F,pe,"","",function(Ae){return te.call(k,Ae,Se++)}),pe}function Ie(F){if(F._status===-1){var te=F._result;te=te(),te.then(function(k){(F._status===0||F._status===-1)&&(F._status=1,F._result=k)},function(k){(F._status===0||F._status===-1)&&(F._status=2,F._result=k)}),F._status===-1&&(F._status=0,F._result=te)}if(F._status===1)return F._result.default;throw F._result}var fe={current:null},Q={transition:null},se={ReactCurrentDispatcher:fe,ReactCurrentBatchConfig:Q,ReactCurrentOwner:M};function C(){throw Error("act(...) is not supported in production builds of React.")}return Pe.Children={map:be,forEach:function(F,te,k){be(F,function(){te.apply(this,arguments)},k)},count:function(F){var te=0;return be(F,function(){te++}),te},toArray:function(F){return be(F,function(te){return te})||[]},only:function(F){if(!D(F))throw Error("React.Children.only expected to receive a single React element child.");return F}},Pe.Component=S,Pe.Fragment=n,Pe.Profiler=o,Pe.PureComponent=O,Pe.StrictMode=r,Pe.Suspense=d,Pe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=se,Pe.act=C,Pe.cloneElement=function(F,te,k){if(F==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+F+".");var pe=x({},F.props),Se=F.key,Ae=F.ref,Be=F._owner;if(te!=null){if(te.ref!==void 0&&(Ae=te.ref,Be=M.current),te.key!==void 0&&(Se=""+te.key),F.type&&F.type.defaultProps)var ve=F.type.defaultProps;for(qe in te)W.call(te,qe)&&!K.hasOwnProperty(qe)&&(pe[qe]=te[qe]===void 0&&ve!==void 0?ve[qe]:te[qe])}var qe=arguments.length-2;if(qe===1)pe.children=k;else if(1<qe){ve=Array(qe);for(var ut=0;ut<qe;ut++)ve[ut]=arguments[ut+2];pe.children=ve}return{$$typeof:e,type:F.type,key:Se,ref:Ae,props:pe,_owner:Be}},Pe.createContext=function(F){return F={$$typeof:u,_currentValue:F,_currentValue2:F,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},F.Provider={$$typeof:a,_context:F},F.Consumer=F},Pe.createElement=de,Pe.createFactory=function(F){var te=de.bind(null,F);return te.type=F,te},Pe.createRef=function(){return{current:null}},Pe.forwardRef=function(F){return{$$typeof:c,render:F}},Pe.isValidElement=D,Pe.lazy=function(F){return{$$typeof:p,_payload:{_status:-1,_result:F},_init:Ie}},Pe.memo=function(F,te){return{$$typeof:h,type:F,compare:te===void 0?null:te}},Pe.startTransition=function(F){var te=Q.transition;Q.transition={};try{F()}finally{Q.transition=te}},Pe.unstable_act=C,Pe.useCallback=function(F,te){return fe.current.useCallback(F,te)},Pe.useContext=function(F){return fe.current.useContext(F)},Pe.useDebugValue=function(){},Pe.useDeferredValue=function(F){return fe.current.useDeferredValue(F)},Pe.useEffect=function(F,te){return fe.current.useEffect(F,te)},Pe.useId=function(){return fe.current.useId()},Pe.useImperativeHandle=function(F,te,k){return fe.current.useImperativeHandle(F,te,k)},Pe.useInsertionEffect=function(F,te){return fe.current.useInsertionEffect(F,te)},Pe.useLayoutEffect=function(F,te){return fe.current.useLayoutEffect(F,te)},Pe.useMemo=function(F,te){return fe.current.useMemo(F,te)},Pe.useReducer=function(F,te,k){return fe.current.useReducer(F,te,k)},Pe.useRef=function(F){return fe.current.useRef(F)},Pe.useState=function(F){return fe.current.useState(F)},Pe.useSyncExternalStore=function(F,te,k){return fe.current.useSyncExternalStore(F,te,k)},Pe.useTransition=function(){return fe.current.useTransition()},Pe.version="18.3.1",Pe}var an;function lo(){return an||(an=1,dt.exports=Tt()),dt.exports}var xs;function Bc(){if(xs)return yt;xs=1;var e=lo(),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 p,E={},T=null,y=null;h!==void 0&&(T=""+h),d.key!==void 0&&(T=""+d.key),d.ref!==void 0&&(y=d.ref);for(p in d)r.call(d,p)&&!a.hasOwnProperty(p)&&(E[p]=d[p]);if(c&&c.defaultProps)for(p in d=c.defaultProps,d)E[p]===void 0&&(E[p]=d[p]);return{$$typeof:t,type:c,key:T,ref:y,props:E,_owner:o.current}}return yt.Fragment=n,yt.jsx=u,yt.jsxs=u,yt}var $n;function rw(){return $n||($n=1,rt.exports=Bc()),rt.exports}var v=rw();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 ru=Object.create(null);Object.keys(or).forEach(e=>{ru[or[e]]=e});const Uc={type:"error",data:"parser error"},_m=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",vm=typeof ArrayBuffer=="function",Sm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Hc=({type:e,data:t},n,r)=>_m&&t instanceof Blob?n?r(t):Am(t,r):vm&&(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 Cm(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let zc;function iw(e,t){if(_m&&e.data instanceof Blob)return e.data.arrayBuffer().then(Cm).then(t);if(vm&&(e.data instanceof ArrayBuffer||Sm(e.data)))return t(Cm(e.data));Hc(e,!1,n=>{zc||(zc=new TextEncoder),t(zc.encode(n))})}const km="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ws=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<km.length;e++)ws[km.charCodeAt(e)]=e;const ow=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),p=new Uint8Array(h);for(r=0;r<n;r+=4)a=ws[e.charCodeAt(r)],u=ws[e.charCodeAt(r+1)],c=ws[e.charCodeAt(r+2)],d=ws[e.charCodeAt(r+3)],p[o++]=a<<2|u>>4,p[o++]=(u&15)<<4|c>>2,p[o++]=(c&3)<<6|d&63;return h},sw=typeof ArrayBuffer=="function",jc=(e,t)=>{if(typeof e!="string")return{type:"message",data:Nm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:aw(e.substring(1),t)}:ru[n]?e.length>1?{type:ru[n],data:e.substring(1)}:{type:ru[n]}:Uc},aw=(e,t)=>{if(sw){const n=ow(e);return Nm(n,t)}else return{base64:!0,data:e}},Nm=(e,t)=>t==="blob"?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,Om="",uw=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((a,u)=>{Hc(a,!1,c=>{r[u]=c,++o===n&&t(r.join(Om))})})},lw=(e,t)=>{const n=e.split(Om),r=[];for(let o=0;o<n.length;o++){const a=jc(n[o],t);if(r.push(a),a.type==="error")break}return r};function cw(){return new TransformStream({transform(e,t){iw(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 $c;function iu(e){return e.reduce((t,n)=>t+n.length,0)}function ou(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 dw(e,t){$c||($c=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(iu(n)<1)break;const d=ou(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(iu(n)<2)break;const d=ou(n,2);o=new DataView(d.buffer,d.byteOffset,d.length).getUint16(0),r=3}else if(r===2){if(iu(n)<8)break;const d=ou(n,8),h=new DataView(d.buffer,d.byteOffset,d.length),p=h.getUint32(0);if(p>Math.pow(2,21)-1){c.enqueue(Uc);break}o=p*Math.pow(2,32)+h.getUint32(4),r=3}else{if(iu(n)<o)break;const d=ou(n,o);c.enqueue(jc(a?d:$c.decode(d),t)),r=0}if(o===0||o>e){c.enqueue(Uc);break}}}})}const Im=4;function St(e){if(e)return fw(e)}function fw(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 su=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")(),hw="arraybuffer";function B9(){}function Rm(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const pw=On.setTimeout,mw=On.clearTimeout;function au(e,t){t.useNativeTimers?(e.setTimeoutFn=pw.bind(On),e.clearTimeoutFn=mw.bind(On)):(e.setTimeoutFn=On.setTimeout.bind(On),e.clearTimeoutFn=On.clearTimeout.bind(On))}const gw=1.33;function Ew(e){return typeof e=="string"?yw(e):Math.ceil((e.byteLength||e.size)*gw)}function yw(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 bw(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function Tw(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 xw extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Vc extends St{constructor(t){super(),this.writable=!1,au(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 xw(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=jc(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=bw(t);return n.length?"?"+n:""}}class ww extends Vc{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)};lw(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,uw(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 Lm=!1;try{Lm=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const _w=Lm;function vw(){}class Sw extends ww{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,au(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=Rm(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=vw,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",Dm);else if(typeof addEventListener=="function"){const e="onpagehide"in On?"pagehide":"unload";addEventListener(e,Dm,!1)}}function Dm(){for(let e in sr.requests)sr.requests.hasOwnProperty(e)&&sr.requests[e].abort()}const Aw=(function(){const e=Mm({xdomain:!1});return e&&e.responseType!==null})();class Cw extends Sw{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=Aw&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new sr(Mm,this.uri(),t)}}function Mm(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||_w))return new XMLHttpRequest}catch(n){}if(!t)try{return new On[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const Fm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class kw extends Vc{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=Fm?{}:Rm(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;Hc(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch(u){}o&&su(()=>{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 qc=On.WebSocket||On.MozWebSocket;class Nw extends kw{createSocket(t,n,r){return Fm?new qc(t,n,r):n?new qc(t,n):new qc(t)}doWrite(t,n){this.ws.send(n)}}class Ow extends Vc{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=dw(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=cw();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&&su(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const Iw={websocket:Nw,webtransport:Ow,polling:Cw},Rw=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Pw=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Yc(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=Rw.exec(e||""),a={},u=14;for(;u--;)a[Pw[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=Lw(a,a.path),a.queryKey=Dw(a,a.query),a}function Lw(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 Dw(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,a){o&&(n[o]=a)}),n}const Wc=typeof addEventListener=="function"&&typeof removeEventListener=="function",uu=[];Wc&&addEventListener("offline",()=>{uu.forEach(e=>e())},!1);class zr extends St{constructor(t,n){if(super(),this.binaryType=hw,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=Yc(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=Yc(n.host).host);au(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=Tw(this.opts.query)),Wc&&(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"})},uu.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=Im,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&&zr.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",zr.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+=Ew(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,su(()=>{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(zr.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(),Wc&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=uu.indexOf(this._offlineEventListener);r!==-1&&uu.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}zr.protocol=Im;class Mw extends zr{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;zr.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;zr.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(p(),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,p(),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 p=()=>{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 Fw=class extends Mw{constructor(t,n={}){const r=typeof t=="object",o=r?H({},t):H({},n);(!o.transports||o.transports&&typeof o.transports[0]=="string")&&(o.transports=(o.transports||["polling","websocket","webtransport"]).map(a=>Iw[a]).filter(a=>!!a)),super(r?o:t,o)}};function Bw(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=Yc(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 Uw=typeof ArrayBuffer=="function",Hw=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,Bm=Object.prototype.toString,zw=typeof Blob=="function"||typeof Blob!="undefined"&&Bm.call(Blob)==="[object BlobConstructor]",jw=typeof File=="function"||typeof File!="undefined"&&Bm.call(File)==="[object FileConstructor]";function Gc(e){return Uw&&(e instanceof ArrayBuffer||Hw(e))||zw&&e instanceof Blob||jw&&e instanceof File}function lu(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(lu(e[n]))return!0;return!1}if(Gc(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return lu(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&lu(e[n]))return!0;return!1}function $w(e){const t=[],n=e.data,r=e;return r.data=Kc(n,t),r.attachments=t.length,{packet:r,buffers:t}}function Kc(e,t){if(!e)return e;if(Gc(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]=Kc(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]=Kc(e[r],t));return n}return e}function Vw(e,t){return e.data=Qc(e.data,t),delete e.attachments,e}function Qc(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]=Qc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Qc(e[n],t));return e}const qw=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var Ke;(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"})(Ke||(Ke={}));class Yw{constructor(t){this.replacer=t}encode(t){return(t.type===Ke.EVENT||t.type===Ke.ACK)&&lu(t)?this.encodeAsBinary({type:t.type===Ke.EVENT?Ke.BINARY_EVENT:Ke.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Ke.BINARY_EVENT||t.type===Ke.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=$w(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class Xc 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===Ke.BINARY_EVENT;r||n.type===Ke.BINARY_ACK?(n.type=r?Ke.EVENT:Ke.ACK,this.reconstructor=new Ww(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Gc(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(Ke[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Ke.BINARY_EVENT||r.type===Ke.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(!Gw(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(Xc.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 Ke.CONNECT:return Um(n);case Ke.DISCONNECT:return n===void 0;case Ke.CONNECT_ERROR:return typeof n=="string"||Um(n);case Ke.EVENT:case Ke.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&qw.indexOf(n[0])===-1);case Ke.ACK:case Ke.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class Ww{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=Vw(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Gw=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e};function Um(e){return Object.prototype.toString.call(e)==="[object Object]"}const Kw=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Xc,Encoder:Yw,get PacketType(){return Ke}},Symbol.toStringTag,{value:"Module"}));function Vn(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Qw=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class Hm 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(Qw.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:Ke.EVENT,data:n};if(u.options={},u.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const p=this.ids++,E=n.pop();this._registerAckCallback(p,E),u.id=p}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)=>(this._queue[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:Ke.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 Ke.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 Ke.EVENT:case Ke.BINARY_EVENT:this.onevent(t);break;case Ke.ACK:case Ke.BINARY_ACK:this.onack(t);break;case Ke.DISCONNECT:this.ondisconnect();break;case Ke.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:Ke.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._drainQueue(!0),this.emitReserved("connect")}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:Ke.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 co(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}co.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},co.prototype.reset=function(){this.attempts=0},co.prototype.setMin=function(e){this.ms=e},co.prototype.setMax=function(e){this.max=e},co.prototype.setJitter=function(e){this.jitter=e};class Jc 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,au(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 co({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||Kw;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 Fw(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){su(()=>{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 Hm(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 _s={};function Zc(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=Bw(e,t.path||"/socket.io"),r=n.source,o=n.id,a=n.path,u=_s[o]&&a in _s[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||u;let d;return c?d=new Jc(r,t):(_s[o]||(_s[o]=new Jc(r,t)),d=_s[o]),n.query&&!t.query&&(t.query=n.queryKey),d.socket(n.path,t)}Object.assign(Zc,{Manager:Jc,Socket:Hm,io:Zc,connect:Zc});const zm=Object.prototype.toString;typeof Blob=="function"||typeof Blob!="undefined"&&zm.call(Blob),typeof File=="function"||typeof File!="undefined"&&zm.call(File);var jm;(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"})(jm||(jm={}));var Z=lo();const wi=We(Z);class Xw{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 Jw{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 $e(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:ae(H({},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 $e(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(Re,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Re=typeof globalThis!="undefined"?globalThis:Re||self,Fe(Re.CimulateMessaging={}))})(this,(function(Re){"use strict";var L9=Object.defineProperty,D9=Object.defineProperties;var M9=Object.getOwnPropertyDescriptors;var Fc=Object.getOwnPropertySymbols;var X2=Object.prototype.hasOwnProperty,J2=Object.prototype.propertyIsEnumerable;var Ts=(Re,Fe)=>(Fe=Symbol[Re])?Fe:Symbol.for("Symbol."+Re),F9=Re=>{throw TypeError(Re)},nu=Math.pow,Tm=(Re,Fe,We)=>Fe in Re?L9(Re,Fe,{enumerable:!0,configurable:!0,writable:!0,value:We}):Re[Fe]=We,B=(Re,Fe)=>{for(var We in Fe||(Fe={}))X2.call(Fe,We)&&Tm(Re,We,Fe[We]);if(Fc)for(var We of Fc(Fe))J2.call(Fe,We)&&Tm(Re,We,Fe[We]);return Re},ae=(Re,Fe)=>D9(Re,M9(Fe));var sn=(Re,Fe)=>{var We={};for(var rt in Re)X2.call(Re,rt)&&Fe.indexOf(rt)<0&&(We[rt]=Re[rt]);if(Re!=null&&Fc)for(var rt of Fc(Re))Fe.indexOf(rt)<0&&J2.call(Re,rt)&&(We[rt]=Re[rt]);return We};var Ze=(Re,Fe,We)=>Tm(Re,typeof Fe!="symbol"?Fe+"":Fe,We);var $e=(Re,Fe,We)=>new Promise((rt,yt)=>{var dt=Tt=>{try{Lt(We.next(Tt))}catch(an){yt(an)}},Pe=Tt=>{try{Lt(We.throw(Tt))}catch(an){yt(an)}},Lt=Tt=>Tt.done?rt(Tt.value):Promise.resolve(Tt.value).then(dt,Pe);Lt((We=We.apply(Re,Fe)).next())}),uo=function(Re,Fe){this[0]=Re,this[1]=Fe},xm=(Re,Fe,We)=>{var rt=(Pe,Lt,Tt,an)=>{try{var lo=We[Pe](Lt),xs=(Lt=lo.value)instanceof uo,Bc=lo.done;Promise.resolve(xs?Lt[0]:Lt).then($n=>xs?rt(Pe==="return"?Pe:"next",Lt[1]?{done:$n.done,value:$n.value}:$n,Tt,an):Tt({value:$n,done:Bc})).catch($n=>rt("throw",$n,Tt,an))}catch($n){an($n)}},yt=Pe=>dt[Pe]=Lt=>new Promise((Tt,an)=>rt(Pe,Lt,Tt,an)),dt={};return We=We.apply(Re,Fe),dt[Ts("asyncIterator")]=()=>dt,yt("next"),yt("throw"),yt("return"),dt},wm=Re=>{var Fe=Re[Ts("asyncIterator")],We=!1,rt,yt={};return Fe==null?(Fe=Re[Ts("iterator")](),rt=dt=>yt[dt]=Pe=>Fe[dt](Pe)):(Fe=Fe.call(Re),rt=dt=>yt[dt]=Pe=>{if(We){if(We=!1,dt==="throw")throw Pe;return Pe}return We=!0,{done:!1,value:new uo(new Promise(Lt=>{var Tt=Fe[dt](Pe);Tt instanceof Object||F9("Object expected"),Lt(Tt)}),1)}}),yt[Ts("iterator")]=()=>yt,rt("next"),"throw"in Fe?rt("throw"):yt.throw=dt=>{throw dt},"return"in Fe&&rt("return"),yt},Z2=(Re,Fe,We)=>(Fe=Re[Ts("asyncIterator")])?Fe.call(Re):(Re=Re[Ts("iterator")](),Fe={},We=(rt,yt)=>(yt=Re[rt])&&(Fe[rt]=dt=>new Promise((Pe,Lt,Tt)=>(dt=yt.call(Re,dt),Tt=dt.done,Promise.resolve(dt.value).then(an=>Pe({value:an,done:Tt}),Lt)))),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;height:auto;line-height:normal;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:.25rem;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;height:auto;line-height:normal;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}input.cim-widget-search-input{width:100%;height:stretch;min-width:0;min-height:2rem;padding:0 8px;background-color:transparent;border:1px solid #00000040;border-radius:var(--cim-widget-border-radius)}@media(max-width:576px){input.cim-widget-search-input{font-size:16px}}.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;background-color:#f0f0f080;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;padding:1rem 0;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;&:hover{color:var(--cim-widget-font-color, #1a202c)}}.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;height:auto;line-height:normal;border-radius:var(--cim-widget-border-radius);border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-overflow-panel{position:absolute;top:100%;left:0;right:0;display:flex;flex-direction:column;gap:.5rem;padding:.5rem;background:#fff;border-bottom:1px solid var(--cim-widget-border-color);z-index:10}.cim-widget-overflow-panel .cim-widget-overflow-menu-button{width:100%;justify-content:center;gap:.75rem;font-size:.875rem}.cim-widget-left-right-toggle-button{display:none}@media(min-width:576px){.cim-widget-left-right-toggle-button{display:inline-flex}}.cim-widget-price{display:flex;align-items:baseline;gap:.4em;flex-wrap:wrap;font-family:var(--cim-widget-font-family, sans-serif)}.cim-widget-price__amount{font-weight:700;font-size:1em;line-height:1.2;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-price__compare{font-weight:400;font-size:.85em;line-height:1.2;color:var(--cim-widget-font-color, #3f3f46);opacity:.6;text-decoration:line-through}.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-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-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-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-cart{display:flex;flex-direction:column;gap:12px;width:100%;padding:16px;background-color:var(--cim-widget-background-color, #ffffff);border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);font-family:var(--cim-widget-font-family, sans-serif);color:var(--cim-widget-font-color, #3f3f46);box-sizing:border-box}.cim-widget-cart *{box-sizing:border-box}.cim-widget-cart-banner{display:flex;align-items:flex-start;gap:10px}.cim-widget-cart-banner-icon{flex:0 0 auto;display:flex;align-items:center;justify-content:center;width:24px;height:24px;border-radius:4px;background-color:#2e844a;color:#fff}.cim-widget-cart-banner-icon svg{width:16px;height:16px}.cim-widget-cart-banner-text{margin:0;font-size:.875rem;font-weight:500;line-height:1.4}.cim-widget-cart-summary{display:flex;align-items:center;justify-content:space-between;gap:8px;width:100%;padding:12px 16px;border:none;background-color:transparent;font-family:inherit;color:inherit;text-align:left;cursor:pointer}.cim-widget-cart-summary-text{flex:1 1 auto;min-width:0;font-size:.8125rem;line-height:1.4}.cim-widget-cart-summary-text p{margin:0}.cim-widget-cart-summary-toggle{flex:0 0 auto;display:flex;align-items:center;justify-content:center;opacity:.6}.cim-widget-cart-summary-toggle svg{width:20px;height:20px}.cim-widget-cart-box{display:flex;flex-direction:column;border:1px solid var(--cim-widget-border-color, #e4e4e7);border-radius:var(--cim-widget-border-radius)}.cim-widget-cart-expanded{display:flex;flex-direction:column;padding:0 16px;border-top:1px solid var(--cim-widget-border-color, #e4e4e7)}.cim-widget-cart-items{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}.cim-widget-cart-item{display:flex;align-items:flex-start;gap:12px;padding:12px 0;border-top:1px solid var(--cim-widget-border-color, #e4e4e7)}.cim-widget-cart-item:first-child{border-top:none}.cim-widget-cart-item-image{flex:0 0 auto;width:64px;height:64px;border-radius:4px;overflow:hidden;background-color:#f4f4f5}.cim-widget-cart-item-image img{width:100%;height:100%;object-fit:cover;display:block}.cim-widget-cart-item-details{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;gap:6px}.cim-widget-cart-item-name{margin:0;font-size:.875rem;font-weight:600;line-height:1.3;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical}.cim-widget-cart-item-attrs{display:flex;flex-direction:column;gap:6px;margin-top:-3px}.cim-widget-cart-item-attrs p.cim-widget-cart-item-attr,.cim-widget-cart-item-attr{margin:0;font-size:.75rem;line-height:1.3;opacity:.7}.cim-widget-cart-item-attrs p.cim-widget-cart-item-attr+p.cim-widget-cart-item-attr{margin-top:0}.cim-widget-cart-item-price{display:flex;align-items:baseline;gap:8px;white-space:nowrap}.cim-widget-cart-item-original-price{font-size:.875rem;opacity:.55;text-decoration:line-through}.cim-widget-cart-item-final-price{font-size:.875rem;font-weight:700}.cim-widget-cart-item-footer{display:flex;align-items:center;justify-content:space-between;gap:8px}.cim-widget-cart-item-qty{font-size:.75rem;font-weight:500;opacity:.85}.cim-widget-cart-item-remove{padding:0;border:none;background:none;font-family:inherit;font-size:.75rem;font-weight:500;color:var(--cim-widget-font-color, #3f3f46);text-decoration:underline;cursor:pointer}.cim-widget-cart-item-remove:hover:not(:disabled){opacity:.7}.cim-widget-cart-item-remove:disabled{opacity:.4;cursor:not-allowed}.cim-widget-cart-chips{display:flex;flex-wrap:wrap;gap:6px}.cim-widget-cart-applied-coupons{padding-top:12px;border-top:1px solid var(--cim-widget-border-color, #e4e4e7)}.cim-widget-cart-chip{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:4px;background-color:#f4f4f5;font-size:.6875rem;font-weight:500;line-height:1.2;letter-spacing:.02em}.cim-widget-cart-chip svg{width:12px;height:12px;opacity:.7}.cim-widget-cart-totals{display:flex;flex-direction:column;gap:6px;padding-top:12px;padding-bottom:16px}.cim-widget-cart-total-row{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:.8125rem;line-height:1.3}.cim-widget-cart-total-label{display:inline-flex;align-items:center;gap:8px;opacity:.85}.cim-widget-cart-total-badge{font-weight:700;opacity:1}.cim-widget-cart-total-row.emphasized{margin-top:4px;font-size:1rem;font-weight:700}.cim-widget-cart-total-row.emphasized .cim-widget-cart-total-label{opacity:1}.cim-widget-cart-coupon{display:flex;align-items:stretch;gap:8px}.cim-widget-cart-coupon-field{flex:1 1 auto;min-width:0;display:flex;align-items:center;gap:8px;padding:0 10px;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius)}.cim-widget-cart-coupon-icon{flex:0 0 auto;display:flex;align-items:center;opacity:.55}.cim-widget-cart-coupon-icon svg{width:16px;height:16px}.cim-widget-cart-coupon-input{flex:1 1 auto;min-width:0;padding:11px 0;border:none;outline:none;background:transparent;font-family:inherit;font-size:.8125rem;color:inherit}.cim-widget-cart-coupon-input::placeholder{opacity:.5}.cim-widget-cart-coupon-input:disabled{cursor:not-allowed}.cim-widget-cart-coupon-submit{flex:0 0 auto;display:flex;align-items:center;justify-content:center;width:44px;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);background-color:transparent;color:inherit;cursor:pointer;transition:background-color .15s ease}.cim-widget-cart-coupon-submit svg{width:16px;height:16px}.cim-widget-cart-coupon-submit:hover:not(:disabled){background-color:color-mix(in srgb,var(--cim-widget-font-color, #3f3f46) 8%,transparent)}.cim-widget-cart-coupon-submit:disabled{opacity:.4;cursor:not-allowed}.cim-widget-cart-checkout-button{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;padding:11px 16px;border:1px solid var(--cim-widget-font-color, #141415);border-radius:var(--cim-widget-border-radius);background-color:transparent;color:var(--cim-widget-font-color, #141415);font-family:inherit;font-size:.9375rem;font-weight:600;text-align:center;text-decoration:none;cursor:pointer;transition:background-color .15s ease}.cim-widget-cart-checkout-button svg{width:16px;height:16px}.cim-widget-cart-checkout-button:hover{background-color:color-mix(in srgb,var(--cim-widget-font-color, #141415) 6%,transparent);text-decoration:none}.cim-widget-cart-footer{margin:0;font-size:.75rem;line-height:1.3;opacity:.6;text-align:center}.cim-widget-pdp-gallery{position:relative;width:100%}.cim-widget-pdp-gallery__item-group{display:flex}.cim-widget-pdp-gallery__item{flex-shrink:0;width:100%}.cim-widget-pdp-gallery__image{width:100%;height:100%;aspect-ratio:1 / 1;object-fit:contain;display:block}.cim-widget-pdp-gallery__control{position:absolute;top:50%;left:0;right:0;transform:translateY(-50%);display:flex;justify-content:space-between;pointer-events:none;padding:0 8px}.cim-widget-pdp-gallery__prev-trigger,.cim-widget-pdp-gallery__next-trigger{pointer-events:auto;display:flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:50%;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 #00000026;transition:background-color .15s ease,box-shadow .15s ease}.cim-widget-pdp-gallery__prev-trigger:hover,.cim-widget-pdp-gallery__next-trigger:hover{box-shadow:0 2px 6px #0003}.cim-widget-pdp-gallery__indicator-group{display:flex;justify-content:center;gap:6px;padding-top:12px}.cim-widget-pdp-gallery__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-pdp-gallery__indicator[data-current]{background-color:var(--cim-widget-font-color, #1a202c);transform:scale(1.25)}.cim-widget-pdp-gallery__indicator:hover:not([data-current]){background-color:var(--cim-widget-font-color, #1a202c);opacity:.5}.cim-widget-msg-pdp{width:100%;margin:.5rem 0;font-family:var(--cim-widget-font-family, sans-serif);container:cim-pdp / inline-size}.cim-widget-msg-pdp__card{display:flex;flex-direction:column;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}.cim-widget-msg-pdp__content{display:flex;flex-direction:column;gap:1rem;padding:16px}.cim-widget-msg-pdp__title,.cim-widget-msg-pdp__title-link{font-weight:700;font-size:1rem;line-height:1.3;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46);margin:0}.cim-widget-msg-pdp__title-link{text-decoration:none}.cim-widget-msg-pdp__title-link:hover{text-decoration:underline}.cim-widget-msg-pdp__description{font-size:.75rem;line-height:1.4;color:var(--cim-widget-font-color, #3f3f46);opacity:.85;margin:0}.cim-widget-msg-pdp__variant{display:flex;flex-direction:column;gap:.75rem}.cim-widget-msg-pdp__variant-label{display:flex;align-items:baseline;gap:1rem;font-size:.875rem}.cim-widget-msg-pdp__variant-name{opacity:.7;color:var(--cim-widget-font-color, #3f3f46);white-space:nowrap}.cim-widget-msg-pdp__variant-value{color:var(--cim-widget-font-color, #3f3f46);font-weight:700}.cim-widget-msg-pdp__swatches,.cim-widget-msg-pdp__chips{display:flex;flex-wrap:wrap;gap:.25rem}button.cim-widget-msg-pdp__chip{min-width:34px;background-color:transparent;border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);color:var(--cim-widget-font-color, #3f3f46);font-size:.875rem}button.cim-widget-msg-pdp__chip:hover:not(:disabled){background-color:#0000000a;border-color:var(--cim-widget-primary-color, #3182ce)}button.cim-widget-msg-pdp__chip.selected{background-color:var(--cim-widget-primary-color, #3182ce);border-color:var(--cim-widget-primary-color, #3182ce);color:#fff}button.cim-widget-msg-pdp__chip.selected:hover:not(:disabled){background-color:color-mix(in srgb,var(--cim-widget-primary-color, #3182ce),black 15%);border-color:color-mix(in srgb,var(--cim-widget-primary-color, #3182ce),black 15%);color:#fff}button.cim-widget-msg-pdp__chip.unavailable{opacity:.4;text-decoration:line-through}button.cim-widget-msg-pdp__chip:disabled{cursor:not-allowed}button.cim-widget-msg-pdp__swatch{width:36px;height:36px;min-width:36px;min-height:36px;padding:2px;border-radius:50%;background-color:transparent;border:1px solid var(--cim-widget-border-color, #d1d5db);overflow:hidden}button.cim-widget-msg-pdp__swatch:hover:not(:disabled){border-color:var(--cim-widget-font-color, #3f3f46)}button.cim-widget-msg-pdp__swatch.selected{border-width:2px;border-color:var(--cim-widget-font-color, #141415)}button.cim-widget-msg-pdp__swatch.unavailable{opacity:.3}button.cim-widget-msg-pdp__swatch:disabled{cursor:not-allowed}.cim-widget-msg-pdp__swatch-image{width:100%;height:100%;border-radius:50%;object-fit:cover;display:block}.cim-widget-msg-pdp__stepper{display:flex;align-items:center;gap:.25rem}button.cim-widget-msg-pdp__stepper-btn{border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-pdp__quantity{min-width:1.5rem;text-align:center;font-size:.95rem;font-weight:700;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-pdp__actions{display:flex;flex-direction:column;gap:.5rem;margin-top:.25rem}button.cim-widget-msg-pdp__express-pay{display:flex;align-items:center;justify-content:center;gap:.4rem;min-height:34px;background-color:var(--cim-widget-primary-color, #3182ce);border-color:var(--cim-widget-primary-color, #3182ce);color:#fff;font-weight:700}button.cim-widget-msg-pdp__add-to-cart{min-height:34px;background-color:transparent;border:1px solid var(--cim-widget-primary-color, #3182ce);color:var(--cim-widget-primary-color, #3182ce);font-weight:700;&:hover:disabled{background-color:transparent}}button.cim-widget-msg-pdp__add-to-cart:hover:not(:disabled){background-color:#0000000a}@container cim-pdp (max-width: 340px){.cim-widget-msg-pdp__content{padding:12px}.cim-widget-msg-pdp__title,.cim-widget-msg-pdp__title-link{font-size:.95rem}button.cim-widget-msg-pdp__chip{font-size:.75rem}button.cim-widget-msg-pdp__swatch,button.cim-widget-msg-pdp__stepper-btn{width:28px;height:28px;min-width:28px;min-height:28px}.cim-widget-msg-pdp__quantity{font-size:.85rem}button.cim-widget-msg-pdp__express-pay,button.cim-widget-msg-pdp__add-to-cart{min-height:36px;height:36px;font-size:.8rem}}@container cim-pdp (min-width: 480px){.cim-widget-msg-pdp__card{flex-direction:row;align-items:center;gap:.5rem}.cim-widget-msg-pdp__gallery{flex:0 0 50%;min-width:0;padding-bottom:1.5rem}.cim-widget-msg-pdp__content{flex:1 1 0;min-width:0}}.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);background-color:#fff}.cim-widget-overflow-menu-button.cim-chat-component{background-color:#fff;border-radius:var(--cim-widget-border-radius);&:hover{background-color:#f0f0f0}}.cim-widget-dialog{box-sizing:border-box;position:fixed;width:35dvw;max-width:100dvw;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;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;line-height:normal;font-size:var(--cim-widget-header-text-font-size)}@media(min-width:576px)and (max-width:768px){.cim-widget-dialog{width:50%}}@media(max-width:576px){.cim-widget-dialog{height:100%;width:100dvw!important;max-width:100dvw;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;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;line-height:normal;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;min-width:0;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;overflow-wrap:anywhere;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;line-height:normal;text-transform:none;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;line-height:normal;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:{}},yt={},dt={exports:{}},Pe={};var Lt;function Tt(){if(Lt)return Pe;Lt=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"),p=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 y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,_={};function S(M,ne,k){this.props=M,this.context=ne,this.refs=_,this.updater=k||y}S.prototype.isReactComponent={},S.prototype.setState=function(M,ne){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,ne,"setState")},S.prototype.forceUpdate=function(M){this.updater.enqueueForceUpdate(this,M,"forceUpdate")};function A(){}A.prototype=S.prototype;function O(M,ne,k){this.props=M,this.context=ne,this.refs=_,this.updater=k||y}var R=O.prototype=new A;R.constructor=O,x(R,S.prototype),R.isPureReactComponent=!0;var H=Array.isArray,W=Object.prototype.hasOwnProperty,D={current:null},K={key:!0,ref:!0,__self:!0,__source:!0};function fe(M,ne,k){var me,Se={},Ae=null,Be=null;if(ne!=null)for(me in ne.ref!==void 0&&(Be=ne.ref),ne.key!==void 0&&(Ae=""+ne.key),ne)W.call(ne,me)&&!K.hasOwnProperty(me)&&(Se[me]=ne[me]);var ve=arguments.length-2;if(ve===1)Se.children=k;else if(1<ve){for(var qe=Array(ve),ut=0;ut<ve;ut++)qe[ut]=arguments[ut+2];Se.children=qe}if(M&&M.defaultProps)for(me in ve=M.defaultProps,ve)Se[me]===void 0&&(Se[me]=ve[me]);return{$$typeof:e,type:M,key:Ae,ref:Be,props:Se,_owner:D.current}}function Te(M,ne){return{$$typeof:e,type:M.type,key:ne,ref:M.ref,props:M.props,_owner:M._owner}}function z(M){return typeof M=="object"&&M!==null&&M.$$typeof===e}function X(M){var ne={"=":"=0",":":"=2"};return"$"+M.replace(/[=:]/g,function(k){return ne[k]})}var se=/\/+/g;function ee(M,ne){return typeof M=="object"&&M!==null&&M.key!=null?X(""+M.key):ne.toString(36)}function re(M,ne,k,me,Se){var Ae=typeof M;(Ae==="undefined"||Ae==="boolean")&&(M=null);var Be=!1;if(M===null)Be=!0;else switch(Ae){case"string":case"number":Be=!0;break;case"object":switch(M.$$typeof){case e:case t:Be=!0}}if(Be)return Be=M,Se=Se(Be),M=me===""?"."+ee(Be,0):me,H(Se)?(k="",M!=null&&(k=M.replace(se,"$&/")+"/"),re(Se,ne,k,"",function(ut){return ut})):Se!=null&&(z(Se)&&(Se=Te(Se,k+(!Se.key||Be&&Be.key===Se.key?"":(""+Se.key).replace(se,"$&/")+"/")+M)),ne.push(Se)),1;if(Be=0,me=me===""?".":me+":",H(M))for(var ve=0;ve<M.length;ve++){Ae=M[ve];var qe=me+ee(Ae,ve);Be+=re(Ae,ne,k,qe,Se)}else if(qe=T(M),typeof qe=="function")for(M=qe.call(M),ve=0;!(Ae=M.next()).done;)Ae=Ae.value,qe=me+ee(Ae,ve++),Be+=re(Ae,ne,k,qe,Se);else if(Ae==="object")throw ne=String(M),Error("Objects are not valid as a React child (found: "+(ne==="[object Object]"?"object with keys {"+Object.keys(M).join(", ")+"}":ne)+"). If you meant to render a collection of children, use an array instead.");return Be}function de(M,ne,k){if(M==null)return M;var me=[],Se=0;return re(M,me,"","",function(Ae){return ne.call(k,Ae,Se++)}),me}function Oe(M){if(M._status===-1){var ne=M._result;ne=ne(),ne.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=ne)}if(M._status===1)return M._result.default;throw M._result}var he={current:null},Q={transition:null},oe={ReactCurrentDispatcher:he,ReactCurrentBatchConfig:Q,ReactCurrentOwner:D};function C(){throw Error("act(...) is not supported in production builds of React.")}return Pe.Children={map:de,forEach:function(M,ne,k){de(M,function(){ne.apply(this,arguments)},k)},count:function(M){var ne=0;return de(M,function(){ne++}),ne},toArray:function(M){return de(M,function(ne){return ne})||[]},only:function(M){if(!z(M))throw Error("React.Children.only expected to receive a single React element child.");return M}},Pe.Component=S,Pe.Fragment=n,Pe.Profiler=o,Pe.PureComponent=O,Pe.StrictMode=r,Pe.Suspense=d,Pe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=oe,Pe.act=C,Pe.cloneElement=function(M,ne,k){if(M==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+M+".");var me=x({},M.props),Se=M.key,Ae=M.ref,Be=M._owner;if(ne!=null){if(ne.ref!==void 0&&(Ae=ne.ref,Be=D.current),ne.key!==void 0&&(Se=""+ne.key),M.type&&M.type.defaultProps)var ve=M.type.defaultProps;for(qe in ne)W.call(ne,qe)&&!K.hasOwnProperty(qe)&&(me[qe]=ne[qe]===void 0&&ve!==void 0?ve[qe]:ne[qe])}var qe=arguments.length-2;if(qe===1)me.children=k;else if(1<qe){ve=Array(qe);for(var ut=0;ut<qe;ut++)ve[ut]=arguments[ut+2];me.children=ve}return{$$typeof:e,type:M.type,key:Se,ref:Ae,props:me,_owner:Be}},Pe.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},Pe.createElement=fe,Pe.createFactory=function(M){var ne=fe.bind(null,M);return ne.type=M,ne},Pe.createRef=function(){return{current:null}},Pe.forwardRef=function(M){return{$$typeof:c,render:M}},Pe.isValidElement=z,Pe.lazy=function(M){return{$$typeof:p,_payload:{_status:-1,_result:M},_init:Oe}},Pe.memo=function(M,ne){return{$$typeof:h,type:M,compare:ne===void 0?null:ne}},Pe.startTransition=function(M){var ne=Q.transition;Q.transition={};try{M()}finally{Q.transition=ne}},Pe.unstable_act=C,Pe.useCallback=function(M,ne){return he.current.useCallback(M,ne)},Pe.useContext=function(M){return he.current.useContext(M)},Pe.useDebugValue=function(){},Pe.useDeferredValue=function(M){return he.current.useDeferredValue(M)},Pe.useEffect=function(M,ne){return he.current.useEffect(M,ne)},Pe.useId=function(){return he.current.useId()},Pe.useImperativeHandle=function(M,ne,k){return he.current.useImperativeHandle(M,ne,k)},Pe.useInsertionEffect=function(M,ne){return he.current.useInsertionEffect(M,ne)},Pe.useLayoutEffect=function(M,ne){return he.current.useLayoutEffect(M,ne)},Pe.useMemo=function(M,ne){return he.current.useMemo(M,ne)},Pe.useReducer=function(M,ne,k){return he.current.useReducer(M,ne,k)},Pe.useRef=function(M){return he.current.useRef(M)},Pe.useState=function(M){return he.current.useState(M)},Pe.useSyncExternalStore=function(M,ne,k){return he.current.useSyncExternalStore(M,ne,k)},Pe.useTransition=function(){return he.current.useTransition()},Pe.version="18.3.1",Pe}var an;function lo(){return an||(an=1,dt.exports=Tt()),dt.exports}var xs;function Bc(){if(xs)return yt;xs=1;var e=lo(),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 p,E={},T=null,y=null;h!==void 0&&(T=""+h),d.key!==void 0&&(T=""+d.key),d.ref!==void 0&&(y=d.ref);for(p in d)r.call(d,p)&&!a.hasOwnProperty(p)&&(E[p]=d[p]);if(c&&c.defaultProps)for(p in d=c.defaultProps,d)E[p]===void 0&&(E[p]=d[p]);return{$$typeof:t,type:c,key:T,ref:y,props:E,_owner:o.current}}return yt.Fragment=n,yt.jsx=u,yt.jsxs=u,yt}var $n;function rw(){return $n||($n=1,rt.exports=Bc()),rt.exports}var v=rw();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 ru=Object.create(null);Object.keys(or).forEach(e=>{ru[or[e]]=e});const Uc={type:"error",data:"parser error"},_m=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",vm=typeof ArrayBuffer=="function",Sm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Hc=({type:e,data:t},n,r)=>_m&&t instanceof Blob?n?r(t):Am(t,r):vm&&(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 Cm(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let zc;function iw(e,t){if(_m&&e.data instanceof Blob)return e.data.arrayBuffer().then(Cm).then(t);if(vm&&(e.data instanceof ArrayBuffer||Sm(e.data)))return t(Cm(e.data));Hc(e,!1,n=>{zc||(zc=new TextEncoder),t(zc.encode(n))})}const km="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ws=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<km.length;e++)ws[km.charCodeAt(e)]=e;const ow=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),p=new Uint8Array(h);for(r=0;r<n;r+=4)a=ws[e.charCodeAt(r)],u=ws[e.charCodeAt(r+1)],c=ws[e.charCodeAt(r+2)],d=ws[e.charCodeAt(r+3)],p[o++]=a<<2|u>>4,p[o++]=(u&15)<<4|c>>2,p[o++]=(c&3)<<6|d&63;return h},sw=typeof ArrayBuffer=="function",jc=(e,t)=>{if(typeof e!="string")return{type:"message",data:Nm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:aw(e.substring(1),t)}:ru[n]?e.length>1?{type:ru[n],data:e.substring(1)}:{type:ru[n]}:Uc},aw=(e,t)=>{if(sw){const n=ow(e);return Nm(n,t)}else return{base64:!0,data:e}},Nm=(e,t)=>t==="blob"?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,Om="",uw=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((a,u)=>{Hc(a,!1,c=>{r[u]=c,++o===n&&t(r.join(Om))})})},lw=(e,t)=>{const n=e.split(Om),r=[];for(let o=0;o<n.length;o++){const a=jc(n[o],t);if(r.push(a),a.type==="error")break}return r};function cw(){return new TransformStream({transform(e,t){iw(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 $c;function iu(e){return e.reduce((t,n)=>t+n.length,0)}function ou(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 dw(e,t){$c||($c=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(iu(n)<1)break;const d=ou(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(iu(n)<2)break;const d=ou(n,2);o=new DataView(d.buffer,d.byteOffset,d.length).getUint16(0),r=3}else if(r===2){if(iu(n)<8)break;const d=ou(n,8),h=new DataView(d.buffer,d.byteOffset,d.length),p=h.getUint32(0);if(p>Math.pow(2,21)-1){c.enqueue(Uc);break}o=p*Math.pow(2,32)+h.getUint32(4),r=3}else{if(iu(n)<o)break;const d=ou(n,o);c.enqueue(jc(a?d:$c.decode(d),t)),r=0}if(o===0||o>e){c.enqueue(Uc);break}}}})}const Im=4;function St(e){if(e)return fw(e)}function fw(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 su=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")(),hw="arraybuffer";function B9(){}function Rm(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const pw=On.setTimeout,mw=On.clearTimeout;function au(e,t){t.useNativeTimers?(e.setTimeoutFn=pw.bind(On),e.clearTimeoutFn=mw.bind(On)):(e.setTimeoutFn=On.setTimeout.bind(On),e.clearTimeoutFn=On.clearTimeout.bind(On))}const gw=1.33;function Ew(e){return typeof e=="string"?yw(e):Math.ceil((e.byteLength||e.size)*gw)}function yw(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 bw(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function Tw(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 xw extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Vc extends St{constructor(t){super(),this.writable=!1,au(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 xw(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=jc(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=bw(t);return n.length?"?"+n:""}}class ww extends Vc{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)};lw(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,uw(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 Lm=!1;try{Lm=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const _w=Lm;function vw(){}class Sw extends ww{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,au(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=Rm(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=vw,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",Dm);else if(typeof addEventListener=="function"){const e="onpagehide"in On?"pagehide":"unload";addEventListener(e,Dm,!1)}}function Dm(){for(let e in sr.requests)sr.requests.hasOwnProperty(e)&&sr.requests[e].abort()}const Aw=(function(){const e=Mm({xdomain:!1});return e&&e.responseType!==null})();class Cw extends Sw{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=Aw&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new sr(Mm,this.uri(),t)}}function Mm(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||_w))return new XMLHttpRequest}catch(n){}if(!t)try{return new On[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const Fm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class kw extends Vc{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=Fm?{}:Rm(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;Hc(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch(u){}o&&su(()=>{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 qc=On.WebSocket||On.MozWebSocket;class Nw extends kw{createSocket(t,n,r){return Fm?new qc(t,n,r):n?new qc(t,n):new qc(t)}doWrite(t,n){this.ws.send(n)}}class Ow extends Vc{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=dw(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=cw();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&&su(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const Iw={websocket:Nw,webtransport:Ow,polling:Cw},Rw=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Pw=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Yc(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=Rw.exec(e||""),a={},u=14;for(;u--;)a[Pw[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=Lw(a,a.path),a.queryKey=Dw(a,a.query),a}function Lw(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 Dw(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,a){o&&(n[o]=a)}),n}const Wc=typeof addEventListener=="function"&&typeof removeEventListener=="function",uu=[];Wc&&addEventListener("offline",()=>{uu.forEach(e=>e())},!1);class zr extends St{constructor(t,n){if(super(),this.binaryType=hw,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=Yc(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=Yc(n.host).host);au(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=Tw(this.opts.query)),Wc&&(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"})},uu.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=Im,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&&zr.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",zr.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+=Ew(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,su(()=>{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(zr.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(),Wc&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=uu.indexOf(this._offlineEventListener);r!==-1&&uu.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}zr.protocol=Im;class Mw extends zr{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;zr.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;zr.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(p(),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,p(),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 p=()=>{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 Fw=class extends Mw{constructor(t,n={}){const r=typeof t=="object",o=r?B({},t):B({},n);(!o.transports||o.transports&&typeof o.transports[0]=="string")&&(o.transports=(o.transports||["polling","websocket","webtransport"]).map(a=>Iw[a]).filter(a=>!!a)),super(r?o:t,o)}};function Bw(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=Yc(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 Uw=typeof ArrayBuffer=="function",Hw=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,Bm=Object.prototype.toString,zw=typeof Blob=="function"||typeof Blob!="undefined"&&Bm.call(Blob)==="[object BlobConstructor]",jw=typeof File=="function"||typeof File!="undefined"&&Bm.call(File)==="[object FileConstructor]";function Gc(e){return Uw&&(e instanceof ArrayBuffer||Hw(e))||zw&&e instanceof Blob||jw&&e instanceof File}function lu(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(lu(e[n]))return!0;return!1}if(Gc(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return lu(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&lu(e[n]))return!0;return!1}function $w(e){const t=[],n=e.data,r=e;return r.data=Kc(n,t),r.attachments=t.length,{packet:r,buffers:t}}function Kc(e,t){if(!e)return e;if(Gc(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]=Kc(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]=Kc(e[r],t));return n}return e}function Vw(e,t){return e.data=Qc(e.data,t),delete e.attachments,e}function Qc(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]=Qc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Qc(e[n],t));return e}const qw=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var Ke;(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"})(Ke||(Ke={}));class Yw{constructor(t){this.replacer=t}encode(t){return(t.type===Ke.EVENT||t.type===Ke.ACK)&&lu(t)?this.encodeAsBinary({type:t.type===Ke.EVENT?Ke.BINARY_EVENT:Ke.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Ke.BINARY_EVENT||t.type===Ke.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=$w(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class Xc 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===Ke.BINARY_EVENT;r||n.type===Ke.BINARY_ACK?(n.type=r?Ke.EVENT:Ke.ACK,this.reconstructor=new Ww(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Gc(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(Ke[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Ke.BINARY_EVENT||r.type===Ke.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(!Gw(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(Xc.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 Ke.CONNECT:return Um(n);case Ke.DISCONNECT:return n===void 0;case Ke.CONNECT_ERROR:return typeof n=="string"||Um(n);case Ke.EVENT:case Ke.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&qw.indexOf(n[0])===-1);case Ke.ACK:case Ke.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class Ww{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=Vw(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Gw=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e};function Um(e){return Object.prototype.toString.call(e)==="[object Object]"}const Kw=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Xc,Encoder:Yw,get PacketType(){return Ke}},Symbol.toStringTag,{value:"Module"}));function Vn(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Qw=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class Hm 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(Qw.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:Ke.EVENT,data:n};if(u.options={},u.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const p=this.ids++,E=n.pop();this._registerAckCallback(p,E),u.id=p}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)=>(this._queue[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:Ke.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 Ke.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 Ke.EVENT:case Ke.BINARY_EVENT:this.onevent(t);break;case Ke.ACK:case Ke.BINARY_ACK:this.onack(t);break;case Ke.DISCONNECT:this.ondisconnect();break;case Ke.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:Ke.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._drainQueue(!0),this.emitReserved("connect")}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:Ke.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 co(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}co.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},co.prototype.reset=function(){this.attempts=0},co.prototype.setMin=function(e){this.ms=e},co.prototype.setMax=function(e){this.max=e},co.prototype.setJitter=function(e){this.jitter=e};class Jc 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,au(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 co({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||Kw;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 Fw(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){su(()=>{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 Hm(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 _s={};function Zc(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=Bw(e,t.path||"/socket.io"),r=n.source,o=n.id,a=n.path,u=_s[o]&&a in _s[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||u;let d;return c?d=new Jc(r,t):(_s[o]||(_s[o]=new Jc(r,t)),d=_s[o]),n.query&&!t.query&&(t.query=n.queryKey),d.socket(n.path,t)}Object.assign(Zc,{Manager:Jc,Socket:Hm,io:Zc,connect:Zc});const zm=Object.prototype.toString;typeof Blob=="function"||typeof Blob!="undefined"&&zm.call(Blob),typeof File=="function"||typeof File!="undefined"&&zm.call(File);var jm;(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"})(jm||(jm={}));var Z=lo();const wi=We(Z);class Xw{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 Jw{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 $e(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:ae(B({},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 $e(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 jr extends Error{constructor(t,n="unknown",r){super(t,r),this.name="AgentforceClientError",this.type=n}}let Zw=class extends jr{constructor(t,n,r,o){super(t,"api",o),this.name="AgentforceApiError",this.statusCode=n,this.responseBody=r}};class $m extends jr{constructor(t,n=1,r){super(t,"network",r),this.name="AgentforceNetworkError",this.attemptsMade=n}}let ed=class extends jr{constructor(t,n){super(t,"auth",n),this.name="AgentforceAuthError"}};class e_{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 t_ extends Xw{constructor({baseURL:t,orgId:n,esDeveloperName:r,options:o={}}){var u,c,d,h,p,E,T;super(),this._accessToken=null,this._tokenExpiresAt=0,this._conversationId=null,this._isConnected=!1,this._usingContinuationToken=!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:(p=o.enableLogging)!=null?p:!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 e_(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(t){return $e(this,null,function*(){this.intentionalDisconnect=!1,this.reconnectAttempts=0,this.logger.info("Connecting..."),t!=null&&t.continuationToken?(this._accessToken=t.continuationToken,this._tokenExpiresAt=this.getTokenExpiry(t.continuationToken),this._usingContinuationToken=!0,this.logger.info("Using continuation token")):(this._accessToken=yield this.fetchAccessToken(),this._usingContinuationToken=!1,this.logger.info("Access token acquired")),yield this.openSSE(t==null?void 0:t.lastEventId)})}disconnect(){this.intentionalDisconnect=!0,this.clearReconnectTimer(),this.closeSSE(),this._isConnected=!1,this.logger.info("Disconnected")}reconnect(){this._isConnected||(this.intentionalDisconnect=!1,this.reconnectAttempts=0,this.attemptReconnect())}createConversation(t){return $e(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 $e(this,null,function*(){if(this.assertConnected(),!this._conversationId)throw new jr("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 $e(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)}`)}})}listConversations(t){return $e(this,null,function*(){var u,c,d;this.assertConnected();const n=new URLSearchParams;(t==null?void 0:t.inclClosedConvs)!=null&&n.set("inclClosedConvs",String(t.inclClosedConvs)),(t==null?void 0:t.limit)!=null&&n.set("limit",String(t.limit)),t!=null&&t.conversationId&&n.set("conversationId",t.conversationId),(t==null?void 0:t.startTimestamp)!=null&&n.set("startTimestamp",String(t.startTimestamp)),(t==null?void 0:t.endTimestamp)!=null&&n.set("endTimestamp",String(t.endTimestamp));const r=n.toString(),o="/iamessage/api/v2/conversation/list"+(r?`?${r}`:""),a=yield this.executeRequest("GET",o);return{conversations:(u=a.conversations)!=null?u:[],openConversationsFound:(c=a.openConversationsFound)!=null?c:0,closedConversationsFound:(d=a.closedConversationsFound)!=null?d:0}})}listConversationEntries(t,n){return $e(this,null,function*(){var u;this.assertConnected();const r=new URLSearchParams;(n==null?void 0:n.limit)!=null&&r.set("limit",String(n.limit)),(n==null?void 0:n.startTimestamp)!=null&&r.set("startTimestamp",String(n.startTimestamp)),(n==null?void 0:n.endTimestamp)!=null&&r.set("endTimestamp",String(n.endTimestamp)),n!=null&&n.direction&&r.set("direction",n.direction),n!=null&&n.entryTypeFilter&&n.entryTypeFilter.length>0&&r.set("entryTypeFilter",n.entryTypeFilter.join(","));const o=r.toString(),a=`/iamessage/api/v2/conversation/${t}/entries${o?`?${o}`:""}`;return{conversationEntries:(u=(yield this.executeRequest("GET",a)).conversationEntries)!=null?u:[]}})}resumeConversation(t){if(this.assertConnected(),!t)throw new jr("conversationId is required to resume a conversation.","unknown");this._conversationId=t,this.logger.info(`Conversation resumed: ${t}`)}generateContinuationToken(){return $e(this,null,function*(){this.assertConnected();const t=yield this.executeRequest("GET","/iamessage/api/v2/authorization/continuation-access-token");return this.logger.info("Continuation token generated"),t})}openSSE(t){return $e(this,null,function*(){this.closeSSE();const n=`${this.baseURL}/eventrouter/v1/sse`,r={Authorization:`Bearer ${this._accessToken}`,"X-Org-Id":this.orgId};t&&(r["Last-Event-ID"]=t),this.sseReader=new Jw(n,r,(o,a)=>this.handleSSEEvent(o,a),o=>this.handleSSEClose(o),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(()=>$e(this,null,function*(){try{if(this.intentionalDisconnect)return;if(!(this._accessToken&&Date.now()<this._tokenExpiresAt))return this.logger.error("Access token expired — session cannot be resumed"),this.emit("error",{code:"SESSION_EXPIRED",message:"Session expired. Call connect() to start a new session.",recoverable:!1}),void(this._conversationId=null);if(this.logger.info("Reusing existing access token for SSE reconnection"),this.intentionalDisconnect)return;yield this.openSSE(),this.reconnectAttempts=0,this.logger.info("Reconnected successfully")}catch(r){if(this.intentionalDisconnect)return;const o=r instanceof Error?r.message:String(r);if(o.includes("(401)"))return this.logger.error("SSE rejected token (401) — session expired"),this.emit("error",{code:"SESSION_EXPIRED",message:"Session expired. Call connect() to start a new session.",recoverable:!1}),void(this._conversationId=null);this.logger.error(`Reconnect attempt ${this.reconnectAttempts} failed: ${o}`),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(`Unhandled SSE event type: ${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){let n,r,o,a="";if(t.conversationEntry){const u=this.parseEntryPayload(t.conversationEntry),c=this.getNestedValue(u,"streamingToken");a=this.getNestedString(c,"token","text")||this.getNestedString(c,"token","content")||"";const d=this.getNestedValue(c,"sequenceNumber");typeof d=="number"&&(n=d);const h=this.getNestedString(c,"targetMessageIdentifier");h&&(r=h);const p=this.getNestedString(c,"tokenType");p&&(o=p)}a||(a=t.token||t.text||""),a?this.emit("streaming_token",H(H(H({conversationId:this._conversationId||"",token:String(a)},n!==void 0?{sequenceNumber:n}:{}),r?{targetMessageId:r}:{}),o?{tokenType:o}:{})):this.logger.warn("STREAMING_TOKEN received but no token text could be extracted — payload shape may have changed")}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,p;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,y=E.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)||"",_=E.operation||E.event||"";this.emit("participant_changed",{conversationId:this._conversationId||"",participant:{role:x,name:y},action:this.normalizeParticipantAction(_)})}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:((p=(h=t.conversationEntry)==null?void 0:h.sender)==null?void 0:p.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 $e(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 ed("Token response missing accessToken field");return this._tokenExpiresAt=this.getTokenExpiry(n.accessToken),n.accessToken})}executeRequest(t,n,r,o){return $e(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=H({"Content-Type":"application/json"},o==null?void 0:o.headers);a&&this._accessToken&&(h.Authorization=`Bearer ${this._accessToken}`);const p={method:t,headers:h,signal:(o==null?void 0:o.signal)||d.signal};r&&t==="POST"&&(p.body=JSON.stringify(r));const E=yield fetch(`${this.baseURL}${n}`,p);if(clearTimeout(c),!E.ok){const T=yield E.text().catch(()=>E.statusText);if(E.status===401&&a&&u===0){if(this._usingContinuationToken)throw this.logger.warn("Got 401 with continuation token — cannot auto-refresh"),new ed(`Request ${t} ${n} failed (401): continuation token expired or invalid. Reconnect without a continuation token to create a new session.`);if(this._conversationId)throw this.logger.warn("Got 401 with active conversation — cannot auto-refresh (would orphan conversation)"),new ed(`Request ${t} ${n} failed (401): session expired. Call connect() to start a new session.`);this.logger.info("Got 401 — refreshing token and retrying..."),this._accessToken=yield this.fetchAccessToken(),u++;continue}throw new Zw(`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 jr)throw d;if(d instanceof DOMException&&d.name==="AbortError")throw new $m("Request timeout exceeded",u+1,{cause:d});if(d instanceof TypeError){if(u<this.maxRetries){u++;const h=100*Math.random(),p=300*Math.pow(2,u-1)+h;this.logger.info(`Network error, retrying (${u}/${this.maxRetries}) in ${p.toFixed(0)}ms...`),yield new Promise(E=>setTimeout(E,p));continue}throw new $m(`Network error: ${d.message}`,u,{cause:d})}throw new jr(`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 jr("Client is not connected. Call connect() first.","unknown")}getTokenExpiry(t){var n;try{const r=t.split(".")[1];return 1e3*((n=JSON.parse(atob(r)).exp)!=null?n:0)}catch(r){return 0}}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 U="cim-widget",Sr=`--${U}`,$r={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd",borderRadius:"0.25rem"},n_=(e=$r)=>({[`${Sr}-primary-color`]:e.primaryColor||$r.primaryColor,[`${Sr}-secondary-color`]:e.secondaryColor||$r.secondaryColor,[`${Sr}-font-color`]:e.fontColor||$r.fontColor,[`${Sr}-font-family`]:e.fontFamily||$r.fontFamily,[`${Sr}-background-color`]:e.backgroundColor||$r.backgroundColor,[`${Sr}-border-color`]:e.borderColor||$r.borderColor,[`${Sr}-border-radius`]:e.borderRadius||$r.borderRadius});function Vm(e,t){return function(){return e.apply(t,arguments)}}const{toString:r_}=Object.prototype,{getPrototypeOf:cu}=Object,{iterator:du,toStringTag:qm}=Symbol,fu=(e=>t=>{const n=r_.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),qn=e=>(e=e.toLowerCase(),t=>fu(t)===e),hu=e=>t=>typeof t===e,{isArray:fo}=Array,ho=hu("undefined");function vs(e){return e!==null&&!ho(e)&&e.constructor!==null&&!ho(e.constructor)&&un(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Ym=qn("ArrayBuffer");function i_(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Ym(e.buffer),t}const o_=hu("string"),un=hu("function"),Wm=hu("number"),Ss=e=>e!==null&&typeof e=="object",s_=e=>e===!0||e===!1,pu=e=>{if(fu(e)!=="object")return!1;const t=cu(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(qm in e)&&!(du in e)},a_=e=>{if(!Ss(e)||vs(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},u_=qn("Date"),l_=qn("File"),c_=e=>!!(e&&typeof e.uri!="undefined"),d_=e=>e&&typeof e.getParts!="undefined",f_=qn("Blob"),h_=qn("FileList"),p_=e=>Ss(e)&&un(e.pipe);function m_(){return typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:{}}const Gm=m_(),Km=typeof Gm.FormData!="undefined"?Gm.FormData:void 0,g_=e=>{if(!e)return!1;if(Km&&e instanceof Km)return!0;const t=cu(e);if(!t||t===Object.prototype||!un(e.append))return!1;const n=fu(e);return n==="formdata"||n==="object"&&un(e.toString)&&e.toString()==="[object FormData]"},E_=qn("URLSearchParams"),[y_,b_,T_,x_]=["ReadableStream","Request","Response","Headers"].map(qn),w_=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function As(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),fo(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(vs(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 Qm(e,t){if(vs(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,Xm=e=>!ho(e)&&e!==_i;function td(...e){const{caseless:t,skipUndefined:n}=Xm(this)&&this||{},r={},o=(a,u)=>{if(u==="__proto__"||u==="constructor"||u==="prototype")return;const c=t&&Qm(r,u)||u,d=nd(r,c)?r[c]:void 0;pu(d)&&pu(a)?r[c]=td(d,a):pu(a)?r[c]=td({},a):fo(a)?r[c]=a.slice():(!n||!ho(a))&&(r[c]=a)};for(let a=0,u=e.length;a<u;a++)e[a]&&As(e[a],o);return r}const __=(e,t,n,{allOwnKeys:r}={})=>(As(t,(o,a)=>{n&&un(o)?Object.defineProperty(e,a,{__proto__:null,value:Vm(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),v_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),S_=(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)},A_=(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&&cu(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},C_=(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},k_=e=>{if(!e)return null;if(fo(e))return e;let t=e.length;if(!Wm(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},N_=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&cu(Uint8Array)),O_=(e,t)=>{const r=(e&&e[du]).call(e);let o;for(;(o=r.next())&&!o.done;){const a=o.value;t.call(e,a[0],a[1])}},I_=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},R_=qn("HTMLFormElement"),P_=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),nd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),L_=qn("RegExp"),Jm=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};As(n,(o,a)=>{let u;(u=t(o,a,e))!==!1&&(r[a]=u||o)}),Object.defineProperties(e,r)},D_=e=>{Jm(e,(t,n)=>{if(un(e)&&["arguments","caller","callee"].includes(n))return!1;const r=e[n];if(un(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+"'")})}})},M_=(e,t)=>{const n={},r=o=>{o.forEach(a=>{n[a]=!0})};return fo(e)?r(e):r(String(e).split(t)),n},F_=()=>{},B_=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function U_(e){return!!(e&&un(e.append)&&e[qm]==="FormData"&&e[du])}const H_=e=>{const t=new WeakSet,n=r=>{if(Ss(r)){if(t.has(r))return;if(vs(r))return r;if(!("toJSON"in r)){t.add(r);const o=fo(r)?[]:{};return As(r,(a,u)=>{const c=n(a);!ho(c)&&(o[u]=c)}),t.delete(r),o}}return r};return n(e)},z_=qn("AsyncFunction"),j_=e=>e&&(Ss(e)||un(e))&&un(e.then)&&un(e.catch),Zm=((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",un(_i.postMessage)),$_=typeof queueMicrotask!="undefined"?queueMicrotask.bind(_i):typeof process!="undefined"&&process.nextTick||Zm,V={isArray:fo,isArrayBuffer:Ym,isBuffer:vs,isFormData:g_,isArrayBufferView:i_,isString:o_,isNumber:Wm,isBoolean:s_,isObject:Ss,isPlainObject:pu,isEmptyObject:a_,isReadableStream:y_,isRequest:b_,isResponse:T_,isHeaders:x_,isUndefined:ho,isDate:u_,isFile:l_,isReactNativeBlob:c_,isReactNative:d_,isBlob:f_,isRegExp:L_,isFunction:un,isStream:p_,isURLSearchParams:E_,isTypedArray:N_,isFileList:h_,forEach:As,merge:td,extend:__,trim:w_,stripBOM:v_,inherits:S_,toFlatObject:A_,kindOf:fu,kindOfTest:qn,endsWith:C_,toArray:k_,forEachEntry:O_,matchAll:I_,isHTMLForm:R_,hasOwnProperty:nd,hasOwnProp:nd,reduceDescriptors:Jm,freezeMethods:D_,toObjectSet:M_,toCamelCase:P_,noop:F_,toFiniteNumber:B_,findKey:Qm,global:_i,isContextDefined:Xm,isSpecCompliantForm:U_,toJSONObject:H_,isAsyncFn:z_,isThenable:j_,setImmediate:Zm,asap:$_,isIterable:e=>e!=null&&un(e[du])},V_=V.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"]),q_=e=>{const t={};let n,r,o;return e&&e.split(`
8
+ `);this.logger.debug(`SSE event: ${n}`,o.slice(0,200)),this.onEvent(n,o)}}class jr extends Error{constructor(t,n="unknown",r){super(t,r),this.name="AgentforceClientError",this.type=n}}let Zw=class extends jr{constructor(t,n,r,o){super(t,"api",o),this.name="AgentforceApiError",this.statusCode=n,this.responseBody=r}};class $m extends jr{constructor(t,n=1,r){super(t,"network",r),this.name="AgentforceNetworkError",this.attemptsMade=n}}let ed=class extends jr{constructor(t,n){super(t,"auth",n),this.name="AgentforceAuthError"}};class e_{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 t_ extends Xw{constructor({baseURL:t,orgId:n,esDeveloperName:r,options:o={}}){var u,c,d,h,p,E,T;super(),this._accessToken=null,this._tokenExpiresAt=0,this._conversationId=null,this._isConnected=!1,this._usingContinuationToken=!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:(p=o.enableLogging)!=null?p:!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 e_(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(t){return $e(this,null,function*(){this.intentionalDisconnect=!1,this.reconnectAttempts=0,this.logger.info("Connecting..."),t!=null&&t.continuationToken?(this._accessToken=t.continuationToken,this._tokenExpiresAt=this.getTokenExpiry(t.continuationToken),this._usingContinuationToken=!0,this.logger.info("Using continuation token")):(this._accessToken=yield this.fetchAccessToken(),this._usingContinuationToken=!1,this.logger.info("Access token acquired")),yield this.openSSE(t==null?void 0:t.lastEventId)})}disconnect(){this.intentionalDisconnect=!0,this.clearReconnectTimer(),this.closeSSE(),this._isConnected=!1,this.logger.info("Disconnected")}reconnect(){this._isConnected||(this.intentionalDisconnect=!1,this.reconnectAttempts=0,this.attemptReconnect())}createConversation(t){return $e(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 $e(this,null,function*(){if(this.assertConnected(),!this._conversationId)throw new jr("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 $e(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)}`)}})}listConversations(t){return $e(this,null,function*(){var u,c,d;this.assertConnected();const n=new URLSearchParams;(t==null?void 0:t.inclClosedConvs)!=null&&n.set("inclClosedConvs",String(t.inclClosedConvs)),(t==null?void 0:t.limit)!=null&&n.set("limit",String(t.limit)),t!=null&&t.conversationId&&n.set("conversationId",t.conversationId),(t==null?void 0:t.startTimestamp)!=null&&n.set("startTimestamp",String(t.startTimestamp)),(t==null?void 0:t.endTimestamp)!=null&&n.set("endTimestamp",String(t.endTimestamp));const r=n.toString(),o="/iamessage/api/v2/conversation/list"+(r?`?${r}`:""),a=yield this.executeRequest("GET",o);return{conversations:(u=a.conversations)!=null?u:[],openConversationsFound:(c=a.openConversationsFound)!=null?c:0,closedConversationsFound:(d=a.closedConversationsFound)!=null?d:0}})}listConversationEntries(t,n){return $e(this,null,function*(){var u;this.assertConnected();const r=new URLSearchParams;(n==null?void 0:n.limit)!=null&&r.set("limit",String(n.limit)),(n==null?void 0:n.startTimestamp)!=null&&r.set("startTimestamp",String(n.startTimestamp)),(n==null?void 0:n.endTimestamp)!=null&&r.set("endTimestamp",String(n.endTimestamp)),n!=null&&n.direction&&r.set("direction",n.direction),n!=null&&n.entryTypeFilter&&n.entryTypeFilter.length>0&&r.set("entryTypeFilter",n.entryTypeFilter.join(","));const o=r.toString(),a=`/iamessage/api/v2/conversation/${t}/entries${o?`?${o}`:""}`;return{conversationEntries:(u=(yield this.executeRequest("GET",a)).conversationEntries)!=null?u:[]}})}resumeConversation(t){if(this.assertConnected(),!t)throw new jr("conversationId is required to resume a conversation.","unknown");this._conversationId=t,this.logger.info(`Conversation resumed: ${t}`)}generateContinuationToken(){return $e(this,null,function*(){this.assertConnected();const t=yield this.executeRequest("GET","/iamessage/api/v2/authorization/continuation-access-token");return this.logger.info("Continuation token generated"),t})}openSSE(t){return $e(this,null,function*(){this.closeSSE();const n=`${this.baseURL}/eventrouter/v1/sse`,r={Authorization:`Bearer ${this._accessToken}`,"X-Org-Id":this.orgId};t&&(r["Last-Event-ID"]=t),this.sseReader=new Jw(n,r,(o,a)=>this.handleSSEEvent(o,a),o=>this.handleSSEClose(o),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(()=>$e(this,null,function*(){try{if(this.intentionalDisconnect)return;if(!(this._accessToken&&Date.now()<this._tokenExpiresAt))return this.logger.error("Access token expired — session cannot be resumed"),this.emit("error",{code:"SESSION_EXPIRED",message:"Session expired. Call connect() to start a new session.",recoverable:!1}),void(this._conversationId=null);if(this.logger.info("Reusing existing access token for SSE reconnection"),this.intentionalDisconnect)return;yield this.openSSE(),this.reconnectAttempts=0,this.logger.info("Reconnected successfully")}catch(r){if(this.intentionalDisconnect)return;const o=r instanceof Error?r.message:String(r);if(o.includes("(401)"))return this.logger.error("SSE rejected token (401) — session expired"),this.emit("error",{code:"SESSION_EXPIRED",message:"Session expired. Call connect() to start a new session.",recoverable:!1}),void(this._conversationId=null);this.logger.error(`Reconnect attempt ${this.reconnectAttempts} failed: ${o}`),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(`Unhandled SSE event type: ${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){let n,r,o,a="";if(t.conversationEntry){const u=this.parseEntryPayload(t.conversationEntry),c=this.getNestedValue(u,"streamingToken");a=this.getNestedString(c,"token","text")||this.getNestedString(c,"token","content")||"";const d=this.getNestedValue(c,"sequenceNumber");typeof d=="number"&&(n=d);const h=this.getNestedString(c,"targetMessageIdentifier");h&&(r=h);const p=this.getNestedString(c,"tokenType");p&&(o=p)}a||(a=t.token||t.text||""),a?this.emit("streaming_token",B(B(B({conversationId:this._conversationId||"",token:String(a)},n!==void 0?{sequenceNumber:n}:{}),r?{targetMessageId:r}:{}),o?{tokenType:o}:{})):this.logger.warn("STREAMING_TOKEN received but no token text could be extracted — payload shape may have changed")}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,p;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,y=E.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)||"",_=E.operation||E.event||"";this.emit("participant_changed",{conversationId:this._conversationId||"",participant:{role:x,name:y},action:this.normalizeParticipantAction(_)})}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:((p=(h=t.conversationEntry)==null?void 0:h.sender)==null?void 0:p.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 $e(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 ed("Token response missing accessToken field");return this._tokenExpiresAt=this.getTokenExpiry(n.accessToken),n.accessToken})}executeRequest(t,n,r,o){return $e(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=B({"Content-Type":"application/json"},o==null?void 0:o.headers);a&&this._accessToken&&(h.Authorization=`Bearer ${this._accessToken}`);const p={method:t,headers:h,signal:(o==null?void 0:o.signal)||d.signal};r&&t==="POST"&&(p.body=JSON.stringify(r));const E=yield fetch(`${this.baseURL}${n}`,p);if(clearTimeout(c),!E.ok){const T=yield E.text().catch(()=>E.statusText);if(E.status===401&&a&&u===0){if(this._usingContinuationToken)throw this.logger.warn("Got 401 with continuation token — cannot auto-refresh"),new ed(`Request ${t} ${n} failed (401): continuation token expired or invalid. Reconnect without a continuation token to create a new session.`);if(this._conversationId)throw this.logger.warn("Got 401 with active conversation — cannot auto-refresh (would orphan conversation)"),new ed(`Request ${t} ${n} failed (401): session expired. Call connect() to start a new session.`);this.logger.info("Got 401 — refreshing token and retrying..."),this._accessToken=yield this.fetchAccessToken(),u++;continue}throw new Zw(`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 jr)throw d;if(d instanceof DOMException&&d.name==="AbortError")throw new $m("Request timeout exceeded",u+1,{cause:d});if(d instanceof TypeError){if(u<this.maxRetries){u++;const h=100*Math.random(),p=300*Math.pow(2,u-1)+h;this.logger.info(`Network error, retrying (${u}/${this.maxRetries}) in ${p.toFixed(0)}ms...`),yield new Promise(E=>setTimeout(E,p));continue}throw new $m(`Network error: ${d.message}`,u,{cause:d})}throw new jr(`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 jr("Client is not connected. Call connect() first.","unknown")}getTokenExpiry(t){var n;try{const r=t.split(".")[1];return 1e3*((n=JSON.parse(atob(r)).exp)!=null?n:0)}catch(r){return 0}}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 U="cim-widget",Sr=`--${U}`,$r={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd",borderRadius:"0.25rem"},n_=(e=$r)=>({[`${Sr}-primary-color`]:e.primaryColor||$r.primaryColor,[`${Sr}-secondary-color`]:e.secondaryColor||$r.secondaryColor,[`${Sr}-font-color`]:e.fontColor||$r.fontColor,[`${Sr}-font-family`]:e.fontFamily||$r.fontFamily,[`${Sr}-background-color`]:e.backgroundColor||$r.backgroundColor,[`${Sr}-border-color`]:e.borderColor||$r.borderColor,[`${Sr}-border-radius`]:e.borderRadius||$r.borderRadius});function Vm(e,t){return function(){return e.apply(t,arguments)}}const{toString:r_}=Object.prototype,{getPrototypeOf:cu}=Object,{iterator:du,toStringTag:qm}=Symbol,fu=(e=>t=>{const n=r_.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),qn=e=>(e=e.toLowerCase(),t=>fu(t)===e),hu=e=>t=>typeof t===e,{isArray:fo}=Array,ho=hu("undefined");function vs(e){return e!==null&&!ho(e)&&e.constructor!==null&&!ho(e.constructor)&&un(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Ym=qn("ArrayBuffer");function i_(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Ym(e.buffer),t}const o_=hu("string"),un=hu("function"),Wm=hu("number"),Ss=e=>e!==null&&typeof e=="object",s_=e=>e===!0||e===!1,pu=e=>{if(fu(e)!=="object")return!1;const t=cu(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(qm in e)&&!(du in e)},a_=e=>{if(!Ss(e)||vs(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},u_=qn("Date"),l_=qn("File"),c_=e=>!!(e&&typeof e.uri!="undefined"),d_=e=>e&&typeof e.getParts!="undefined",f_=qn("Blob"),h_=qn("FileList"),p_=e=>Ss(e)&&un(e.pipe);function m_(){return typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:{}}const Gm=m_(),Km=typeof Gm.FormData!="undefined"?Gm.FormData:void 0,g_=e=>{if(!e)return!1;if(Km&&e instanceof Km)return!0;const t=cu(e);if(!t||t===Object.prototype||!un(e.append))return!1;const n=fu(e);return n==="formdata"||n==="object"&&un(e.toString)&&e.toString()==="[object FormData]"},E_=qn("URLSearchParams"),[y_,b_,T_,x_]=["ReadableStream","Request","Response","Headers"].map(qn),w_=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function As(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),fo(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(vs(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 Qm(e,t){if(vs(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,Xm=e=>!ho(e)&&e!==_i;function td(...e){const{caseless:t,skipUndefined:n}=Xm(this)&&this||{},r={},o=(a,u)=>{if(u==="__proto__"||u==="constructor"||u==="prototype")return;const c=t&&Qm(r,u)||u,d=nd(r,c)?r[c]:void 0;pu(d)&&pu(a)?r[c]=td(d,a):pu(a)?r[c]=td({},a):fo(a)?r[c]=a.slice():(!n||!ho(a))&&(r[c]=a)};for(let a=0,u=e.length;a<u;a++)e[a]&&As(e[a],o);return r}const __=(e,t,n,{allOwnKeys:r}={})=>(As(t,(o,a)=>{n&&un(o)?Object.defineProperty(e,a,{__proto__:null,value:Vm(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),v_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),S_=(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)},A_=(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&&cu(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},C_=(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},k_=e=>{if(!e)return null;if(fo(e))return e;let t=e.length;if(!Wm(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},N_=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&cu(Uint8Array)),O_=(e,t)=>{const r=(e&&e[du]).call(e);let o;for(;(o=r.next())&&!o.done;){const a=o.value;t.call(e,a[0],a[1])}},I_=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},R_=qn("HTMLFormElement"),P_=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),nd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),L_=qn("RegExp"),Jm=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};As(n,(o,a)=>{let u;(u=t(o,a,e))!==!1&&(r[a]=u||o)}),Object.defineProperties(e,r)},D_=e=>{Jm(e,(t,n)=>{if(un(e)&&["arguments","caller","callee"].includes(n))return!1;const r=e[n];if(un(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+"'")})}})},M_=(e,t)=>{const n={},r=o=>{o.forEach(a=>{n[a]=!0})};return fo(e)?r(e):r(String(e).split(t)),n},F_=()=>{},B_=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function U_(e){return!!(e&&un(e.append)&&e[qm]==="FormData"&&e[du])}const H_=e=>{const t=new WeakSet,n=r=>{if(Ss(r)){if(t.has(r))return;if(vs(r))return r;if(!("toJSON"in r)){t.add(r);const o=fo(r)?[]:{};return As(r,(a,u)=>{const c=n(a);!ho(c)&&(o[u]=c)}),t.delete(r),o}}return r};return n(e)},z_=qn("AsyncFunction"),j_=e=>e&&(Ss(e)||un(e))&&un(e.then)&&un(e.catch),Zm=((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",un(_i.postMessage)),$_=typeof queueMicrotask!="undefined"?queueMicrotask.bind(_i):typeof process!="undefined"&&process.nextTick||Zm,V={isArray:fo,isArrayBuffer:Ym,isBuffer:vs,isFormData:g_,isArrayBufferView:i_,isString:o_,isNumber:Wm,isBoolean:s_,isObject:Ss,isPlainObject:pu,isEmptyObject:a_,isReadableStream:y_,isRequest:b_,isResponse:T_,isHeaders:x_,isUndefined:ho,isDate:u_,isFile:l_,isReactNativeBlob:c_,isReactNative:d_,isBlob:f_,isRegExp:L_,isFunction:un,isStream:p_,isURLSearchParams:E_,isTypedArray:N_,isFileList:h_,forEach:As,merge:td,extend:__,trim:w_,stripBOM:v_,inherits:S_,toFlatObject:A_,kindOf:fu,kindOfTest:qn,endsWith:C_,toArray:k_,forEachEntry:O_,matchAll:I_,isHTMLForm:R_,hasOwnProperty:nd,hasOwnProp:nd,reduceDescriptors:Jm,freezeMethods:D_,toObjectSet:M_,toCamelCase:P_,noop:F_,toFiniteNumber:B_,findKey:Qm,global:_i,isContextDefined:Xm,isSpecCompliantForm:U_,toJSONObject:H_,isAsyncFn:z_,isThenable:j_,setImmediate:Zm,asap:$_,isIterable:e=>e!=null&&un(e[du])},V_=V.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"]),q_=e=>{const t={};let n,r,o;return e&&e.split(`
9
9
  `).forEach(function(u){o=u.indexOf(":"),n=u.substring(0,o).trim().toLowerCase(),r=u.substring(o+1).trim(),!(!n||t[n]&&V_[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t};function Y_(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 W_=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),G_=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function rd(e,t){return V.isArray(e)?e.map(n=>rd(n,t)):Y_(String(e).replace(t,""))}const K_=e=>rd(e,W_),Q_=e=>rd(e,G_);function e0(e){const t=Object.create(null);return V.forEach(e.toJSON(),(n,r)=>{t[r]=Q_(n)}),t}const t0=Symbol("internals");function Cs(e){return e&&String(e).trim().toLowerCase()}function mu(e){return e===!1||e==null?e:V.isArray(e)?e.map(mu):K_(String(e))}function X_(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 J_=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function id(e,t,n,r,o){if(V.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!V.isString(t)){if(V.isString(r))return t.indexOf(r)!==-1;if(V.isRegExp(r))return r.test(t)}}function Z_(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function ev(e,t){const n=V.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 tn=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function a(c,d,h){const p=Cs(d);if(!p)throw new Error("header name must be a non-empty string");const E=V.findKey(o,p);(!E||o[E]===void 0||h===!0||h===void 0&&o[E]!==!1)&&(o[E||d]=mu(c))}const u=(c,d)=>V.forEach(c,(h,p)=>a(h,p,d));if(V.isPlainObject(t)||t instanceof this.constructor)u(t,n);else if(V.isString(t)&&(t=t.trim())&&!J_(t))u(q_(t),n);else if(V.isObject(t)&&V.isIterable(t)){let c={},d,h;for(const p of t){if(!V.isArray(p))throw TypeError("Object iterator must return a key-value pair");c[h=p[0]]=(d=c[h])?V.isArray(d)?[...d,p[1]]:[d,p[1]]:p[1]}u(c,n)}else t!=null&&a(n,t,r);return this}get(t,n){if(t=Cs(t),t){const r=V.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return X_(o);if(V.isFunction(n))return n.call(this,o,r);if(V.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Cs(t),t){const r=V.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||id(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function a(u){if(u=Cs(u),u){const c=V.findKey(r,u);c&&(!n||id(r,r[c],c,n))&&(delete r[c],o=!0)}}return V.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||id(this,this[a],a,t,!0))&&(delete this[a],o=!0)}return o}normalize(t){const n=this,r={};return V.forEach(this,(o,a)=>{const u=V.findKey(r,a);if(u){n[u]=mu(o),delete n[a];return}const c=t?Z_(a):String(a).trim();c!==a&&delete n[a],n[c]=mu(o),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return V.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&V.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[t0]=this[t0]={accessors:{}}).accessors,o=this.prototype;function a(u){const c=Cs(u);r[c]||(ev(o,u),r[c]=!0)}return V.isArray(t)?t.forEach(a):a(t),this}};tn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),V.reduceDescriptors(tn.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),V.freezeMethods(tn);const tv="[REDACTED ****]";function nv(e){if(V.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(V.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function rv(e,t){const n=new Set(t.map(a=>String(a).toLowerCase())),r=[],o=a=>{if(a===null||typeof a!="object"||V.isBuffer(a))return a;if(r.indexOf(a)!==-1)return;a instanceof tn&&(a=a.toJSON()),r.push(a);let u;if(V.isArray(a))u=[],a.forEach((c,d)=>{const h=o(c);V.isUndefined(h)||(u[d]=h)});else{if(!V.isPlainObject(a)&&nv(a))return r.pop(),a;u=Object.create(null);for(const[c,d]of Object.entries(a)){const h=n.has(c.toLowerCase())?tv:o(d);V.isUndefined(h)||(u[c]=h)}}return r.pop(),u};return o(e)}let ke=class ew extends Error{static from(t,n,r,o,a,u){const c=new ew(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&&V.hasOwnProp(t,"redact")?t.redact:void 0,r=V.isArray(n)&&n.length>0?rv(t,n):V.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}}};ke.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",ke.ERR_BAD_OPTION="ERR_BAD_OPTION",ke.ECONNABORTED="ECONNABORTED",ke.ETIMEDOUT="ETIMEDOUT",ke.ECONNREFUSED="ECONNREFUSED",ke.ERR_NETWORK="ERR_NETWORK",ke.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",ke.ERR_DEPRECATED="ERR_DEPRECATED",ke.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",ke.ERR_BAD_REQUEST="ERR_BAD_REQUEST",ke.ERR_CANCELED="ERR_CANCELED",ke.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",ke.ERR_INVALID_URL="ERR_INVALID_URL",ke.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const iv=null;function od(e){return V.isPlainObject(e)||V.isArray(e)}function n0(e){return V.endsWith(e,"[]")?e.slice(0,-2):e}function sd(e,t,n){return e?e.concat(t).map(function(o,a){return o=n0(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function ov(e){return V.isArray(e)&&!e.some(od)}const sv=V.toFlatObject(V,{},null,function(t){return/^is[A-Z]/.test(t)});function gu(e,t,n){if(!V.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=V.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,A){return!V.isUndefined(A[S])});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&&V.isSpecCompliantForm(t);if(!V.isFunction(o))throw new TypeError("visitor must be a function");function p(_){if(_===null)return"";if(V.isDate(_))return _.toISOString();if(V.isBoolean(_))return _.toString();if(!h&&V.isBlob(_))throw new ke("Blob is not supported. Use a Buffer instead.");return V.isArrayBuffer(_)||V.isTypedArray(_)?h&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function E(_,S,A){let O=_;if(V.isReactNative(t)&&V.isReactNativeBlob(_))return t.append(sd(A,S,a),p(_)),!1;if(_&&!A&&typeof _=="object"){if(V.endsWith(S,"{}"))S=r?S:S.slice(0,-2),_=JSON.stringify(_);else if(V.isArray(_)&&ov(_)||(V.isFileList(_)||V.endsWith(S,"[]"))&&(O=V.toArray(_)))return S=n0(S),O.forEach(function(z,W){!(V.isUndefined(z)||z===null)&&t.append(u===!0?sd([S],W,a):u===null?S:S+"[]",p(z))}),!1}return od(_)?!0:(t.append(sd(A,S,a),p(_)),!1)}const T=[],y=Object.assign(sv,{defaultVisitor:E,convertValue:p,isVisitable:od});function x(_,S,A=0){if(!V.isUndefined(_)){if(A>d)throw new ke("Object is too deeply nested ("+A+" levels). Max depth: "+d,ke.ERR_FORM_DATA_DEPTH_EXCEEDED);if(T.indexOf(_)!==-1)throw Error("Circular reference detected in "+S.join("."));T.push(_),V.forEach(_,function(R,z){(!(V.isUndefined(R)||R===null)&&o.call(t,R,V.isString(z)?z.trim():z,S,y))===!0&&x(R,S?S.concat(z):[z],A+1)}),T.pop()}}if(!V.isObject(e))throw new TypeError("data must be an object");return x(e),t}function r0(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function ad(e,t){this._pairs=[],e&&gu(e,this,t)}const i0=ad.prototype;i0.append=function(t,n){this._pairs.push([t,n])},i0.toString=function(t){const n=t?function(r){return t.call(this,r,r0)}:r0;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function av(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function o0(e,t,n){if(!t)return e;const r=n&&n.encode||av,o=V.isFunction(n)?{serialize:n}:n,a=o&&o.serialize;let u;if(a?u=a(t,o):u=V.isURLSearchParams(t)?t.toString():new ad(t,o).toString(r),u){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class s0{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){V.forEach(this.handlers,function(r){r!==null&&t(r)})}}const ud={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},uv={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:ad,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},ld=typeof window!="undefined"&&typeof document!="undefined",cd=typeof navigator=="object"&&navigator||void 0,lv=ld&&(!cd||["ReactNative","NativeScript","NS"].indexOf(cd.product)<0),cv=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",dv=ld&&window.location.href||"http://localhost",Yt=H(H({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:ld,hasStandardBrowserEnv:lv,hasStandardBrowserWebWorkerEnv:cv,navigator:cd,origin:dv},Symbol.toStringTag,{value:"Module"}))),uv);function fv(e,t){return gu(e,new Yt.classes.URLSearchParams,H({visitor:function(n,r,o,a){return Yt.isNode&&V.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function hv(e){return V.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function pv(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 a0(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&&V.isArray(o)?o.length:u,d?(V.hasOwnProp(o,u)?o[u]=V.isArray(o[u])?o[u].concat(r):[o[u],r]:o[u]=r,!c):((!V.hasOwnProp(o,u)||!V.isObject(o[u]))&&(o[u]=[]),t(n,r,o[u],a)&&V.isArray(o[u])&&(o[u]=pv(o[u])),!c)}if(V.isFormData(e)&&V.isFunction(e.entries)){const n={};return V.forEachEntry(e,(r,o)=>{t(hv(r),o,n,0)}),n}return null}const po=(e,t)=>e!=null&&V.hasOwnProp(e,t)?e[t]:void 0;function mv(e,t,n){if(V.isString(e))try{return(t||JSON.parse)(e),V.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const ks={transitional:ud,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=V.isObject(t);if(a&&V.isHTMLForm(t)&&(t=new FormData(t)),V.isFormData(t))return o?JSON.stringify(a0(t)):t;if(V.isArrayBuffer(t)||V.isBuffer(t)||V.isStream(t)||V.isFile(t)||V.isBlob(t)||V.isReadableStream(t))return t;if(V.isArrayBufferView(t))return t.buffer;if(V.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(a){const d=po(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return fv(t,d).toString();if((c=V.isFileList(t))||r.indexOf("multipart/form-data")>-1){const h=po(this,"env"),p=h&&h.FormData;return gu(c?{"files[]":t}:t,p&&new p,d)}}return a||o?(n.setContentType("application/json",!1),mv(t)):t}],transformResponse:[function(t){const n=po(this,"transitional")||ks.transitional,r=n&&n.forcedJSONParsing,o=po(this,"responseType"),a=o==="json";if(V.isResponse(t)||V.isReadableStream(t))return t;if(t&&V.isString(t)&&(r&&!o||a)){const c=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(t,po(this,"parseReviver"))}catch(d){if(c)throw d.name==="SyntaxError"?ke.from(d,ke.ERR_BAD_RESPONSE,this,null,po(this,"response")):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Yt.classes.FormData,Blob:Yt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};V.forEach(["delete","get","head","post","put","patch","query"],e=>{ks.headers[e]={}});function dd(e,t){const n=this||ks,r=t||n,o=tn.from(r.headers);let a=r.data;return V.forEach(e,function(c){a=c.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function u0(e){return!!(e&&e.__CANCEL__)}let Ns=class extends ke{constructor(t,n,r){super(t==null?"canceled":t,ke.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function l0(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ke("Request failed with status code "+n.status,n.status>=400&&n.status<500?ke.ERR_BAD_REQUEST:ke.ERR_BAD_RESPONSE,n.config,n.request,n))}function gv(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function Ev(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(),p=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 y=p&&h-p;return y?Math.round(T*1e3/y):void 0}}function yv(e,t){let n=0,r=1e3/t,o,a;const u=(h,p=Date.now())=>{n=p,o=null,a&&(clearTimeout(a),a=null),e(...h)};return[(...h)=>{const p=Date.now(),E=p-n;E>=r?u(h,p):(o=h,a||(a=setTimeout(()=>{a=null,u(o)},r-E)))},()=>o&&u(o)]}const Eu=(e,t,n=3)=>{let r=0;const o=Ev(50,250);return yv(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),p=o(h);r=Math.max(r,d);const E={loaded:d,total:c,progress:c?d/c:void 0,bytes:h,rate:p||void 0,estimated:p&&c?(c-d)/p:void 0,event:a,lengthComputable:c!=null,[t?"download":"upload"]:!0};e(E)},n)},c0=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},d0=e=>(...t)=>V.asap(()=>e(...t)),bv=Yt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Yt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Yt.origin),Yt.navigator&&/(msie|trident)/i.test(Yt.navigator.userAgent)):()=>!0,Tv=Yt.hasStandardBrowserEnv?{write(e,t,n,r,o,a,u){if(typeof document=="undefined")return;const c=[`${e}=${encodeURIComponent(t)}`];V.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),V.isString(r)&&c.push(`path=${r}`),V.isString(o)&&c.push(`domain=${o}`),a===!0&&c.push("secure"),V.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 xv(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function wv(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function f0(e,t,n){let r=!xv(t);return e&&(r||n===!1)?wv(e,t):t}const h0=e=>e instanceof tn?H({},e):e;function vi(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,p,E,T){return V.isPlainObject(h)&&V.isPlainObject(p)?V.merge.call({caseless:T},h,p):V.isPlainObject(p)?V.merge({},p):V.isArray(p)?p.slice():p}function o(h,p,E,T){if(V.isUndefined(p)){if(!V.isUndefined(h))return r(void 0,h,E,T)}else return r(h,p,E,T)}function a(h,p){if(!V.isUndefined(p))return r(void 0,p)}function u(h,p){if(V.isUndefined(p)){if(!V.isUndefined(h))return r(void 0,h)}else return r(void 0,p)}function c(h,p,E){if(V.hasOwnProp(t,E))return r(h,p);if(V.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,p,E)=>o(h0(h),h0(p),E,!0)};return V.forEach(Object.keys(H(H({},e),t)),function(p){if(p==="__proto__"||p==="constructor"||p==="prototype")return;const E=V.hasOwnProp(d,p)?d[p]:o,T=V.hasOwnProp(e,p)?e[p]:void 0,y=V.hasOwnProp(t,p)?t[p]:void 0,x=E(T,y,p);V.isUndefined(x)&&E!==c||(n[p]=x)}),n}const _v=["content-type","content-length"];function vv(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,o])=>{_v.includes(r.toLowerCase())&&e.set(r,o)})}const Sv=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),p0=e=>{const t=vi({},e),n=T=>V.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"),p=n("allowAbsoluteUrls"),E=n("url");if(t.headers=c=tn.from(c),t.url=o0(f0(h,E,p),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?Sv(d.password):""))),V.isFormData(r)&&(Yt.hasStandardBrowserEnv||Yt.hasStandardBrowserWebWorkerEnv?c.setContentType(void 0):V.isFunction(r.getHeaders)&&vv(c,r.getHeaders(),n("formDataHeaderPolicy"))),Yt.hasStandardBrowserEnv&&(V.isFunction(o)&&(o=o(t)),o===!0||o==null&&bv(t.url))){const y=a&&u&&Tv.read(u);y&&c.set(a,y)}return t},Av=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=p0(e);let a=o.data;const u=tn.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:h}=o,p,E,T,y,x;function _(){y&&y(),x&&x(),o.cancelToken&&o.cancelToken.unsubscribe(p),o.signal&&o.signal.removeEventListener("abort",p)}let S=new XMLHttpRequest;S.open(o.method.toUpperCase(),o.url,!0),S.timeout=o.timeout;function A(){if(!S)return;const R=tn.from("getAllResponseHeaders"in S&&S.getAllResponseHeaders()),W={data:!c||c==="text"||c==="json"?S.responseText:S.response,status:S.status,statusText:S.statusText,headers:R,config:e,request:S};l0(function(K){n(K),_()},function(K){r(K),_()},W),S=null}"onloadend"in S?S.onloadend=A:S.onreadystatechange=function(){!S||S.readyState!==4||S.status===0&&!(S.responseURL&&S.responseURL.startsWith("file:"))||setTimeout(A)},S.onabort=function(){S&&(r(new ke("Request aborted",ke.ECONNABORTED,e,S)),_(),S=null)},S.onerror=function(z){const W=z&&z.message?z.message:"Network Error",M=new ke(W,ke.ERR_NETWORK,e,S);M.event=z||null,r(M),_(),S=null},S.ontimeout=function(){let z=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const W=o.transitional||ud;o.timeoutErrorMessage&&(z=o.timeoutErrorMessage),r(new ke(z,W.clarifyTimeoutError?ke.ETIMEDOUT:ke.ECONNABORTED,e,S)),_(),S=null},a===void 0&&u.setContentType(null),"setRequestHeader"in S&&V.forEach(e0(u),function(z,W){S.setRequestHeader(W,z)}),V.isUndefined(o.withCredentials)||(S.withCredentials=!!o.withCredentials),c&&c!=="json"&&(S.responseType=o.responseType),h&&([T,x]=Eu(h,!0),S.addEventListener("progress",T)),d&&S.upload&&([E,y]=Eu(d),S.upload.addEventListener("progress",E),S.upload.addEventListener("loadend",y)),(o.cancelToken||o.signal)&&(p=R=>{S&&(r(!R||R.type?new Ns(null,e,S):R),S.abort(),_(),S=null)},o.cancelToken&&o.cancelToken.subscribe(p),o.signal&&(o.signal.aborted?p():o.signal.addEventListener("abort",p)));const O=gv(o.url);if(O&&!Yt.protocols.includes(O)){r(new ke("Unsupported protocol "+O+":",ke.ERR_BAD_REQUEST,e));return}S.send(a||null)})},Cv=(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 ke?h:new Ns(h instanceof Error?h.message:h))}};let a=t&&setTimeout(()=>{a=null,o(new ke(`timeout of ${t}ms exceeded`,ke.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=()=>V.asap(u),c},kv=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},Nv=function(e,t){return xm(this,null,function*(){try{for(var n=Z2(Ov(e)),r,o,a;r=!(o=yield new uo(n.next())).done;r=!1){const u=o.value;yield*wm(kv(u,t))}}catch(o){a=[o]}finally{try{r&&(o=n.return)&&(yield new uo(o.call(n)))}finally{if(a)throw a[0]}}})},Ov=function(e){return xm(this,null,function*(){if(e[Symbol.asyncIterator]){yield*wm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new uo(t.read());if(n)break;yield r}}finally{yield new uo(t.cancel())}})},m0=(e,t,n,r)=>{const o=Nv(e,t);let a=0,u,c=h=>{u||(u=!0,r&&r(h))};return new ReadableStream({pull(h){return $e(this,null,function*(){try{const{done:p,value:E}=yield o.next();if(p){c(),h.close();return}let T=E.byteLength;if(n){let y=a+=T;n(y)}h.enqueue(new Uint8Array(E))}catch(p){throw c(p),p}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})};function Iv(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 y=0;y<c;y++)if(r.charCodeAt(y)===37&&y+2<c){const x=r.charCodeAt(y+1),_=r.charCodeAt(y+2);(x>=48&&x<=57||x>=65&&x<=70||x>=97&&x<=102)&&(_>=48&&_<=57||_>=65&&_<=70||_>=97&&_<=102)&&(u-=2,y+=2)}let d=0,h=c-1;const p=y=>y>=2&&r.charCodeAt(y-2)===37&&r.charCodeAt(y-1)===51&&(r.charCodeAt(y)===68||r.charCodeAt(y)===100);h>=0&&(r.charCodeAt(h)===61?(d++,h--):p(h)&&(d++,h-=3)),d===1&&h>=0&&(r.charCodeAt(h)===61||p(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 fd="1.16.1",g0=64*1024,{isFunction:yu}=V,E0=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},Rv=e=>{const t=V.global!==void 0&&V.global!==null?V.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=V.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:o,Request:a,Response:u}=e,c=o?yu(o):typeof fetch=="function",d=yu(a),h=yu(u);if(!c)return!1;const p=c&&yu(n),E=c&&(typeof r=="function"?(A=>O=>A.encode(O))(new r):A=>$e(null,null,function*(){return new Uint8Array(yield new a(A).arrayBuffer())})),T=d&&p&&E0(()=>{let A=!1;const O=new a(Yt.origin,{body:new n,method:"POST",get duplex(){return A=!0,"half"}}),R=O.headers.has("Content-Type");return O.body!=null&&O.body.cancel(),A&&!R}),y=h&&p&&E0(()=>V.isReadableStream(new u("").body)),x={stream:y&&(A=>A.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(A=>{!x[A]&&(x[A]=(O,R)=>{let z=O&&O[A];if(z)return z.call(O);throw new ke(`Response type '${A}' is not supported`,ke.ERR_NOT_SUPPORT,R)})});const _=A=>$e(null,null,function*(){if(A==null)return 0;if(V.isBlob(A))return A.size;if(V.isSpecCompliantForm(A))return(yield new a(Yt.origin,{method:"POST",body:A}).arrayBuffer()).byteLength;if(V.isArrayBufferView(A)||V.isArrayBuffer(A))return A.byteLength;if(V.isURLSearchParams(A)&&(A=A+""),V.isString(A))return(yield E(A)).byteLength}),S=(A,O)=>$e(null,null,function*(){const R=V.toFiniteNumber(A.getContentLength());return R==null?_(O):R});return A=>$e(null,null,function*(){let{url:O,method:R,data:z,signal:W,cancelToken:M,timeout:K,onDownloadProgress:de,onUploadProgress:xe,responseType:D,headers:ne,withCredentials:J="same-origin",fetchOptions:re,maxContentLength:oe,maxBodyLength:be}=p0(A);const Ie=V.isNumber(oe)&&oe>-1,fe=V.isNumber(be)&&be>-1;let Q=o||fetch;D=D?(D+"").toLowerCase():"text";let se=Cv([W,M&&M.toAbortSignal()],K),C=null;const F=se&&se.unsubscribe&&(()=>{se.unsubscribe()});let te;try{if(Ie&&typeof O=="string"&&O.startsWith("data:")&&Iv(O)>oe)throw new ke("maxContentLength size of "+oe+" exceeded",ke.ERR_BAD_RESPONSE,A,C);if(fe&&R!=="get"&&R!=="head"){const ve=yield S(ne,z);if(typeof ve=="number"&&isFinite(ve)&&ve>be)throw new ke("Request body larger than maxBodyLength limit",ke.ERR_BAD_REQUEST,A,C)}if(xe&&T&&R!=="get"&&R!=="head"&&(te=yield S(ne,z))!==0){let ve=new a(O,{method:"POST",body:z,duplex:"half"}),qe;if(V.isFormData(z)&&(qe=ve.headers.get("content-type"))&&ne.setContentType(qe),ve.body){const[ut,pn]=c0(te,Eu(d0(xe)));z=m0(ve.body,g0,ut,pn)}}V.isString(J)||(J=J?"include":"omit");const k=d&&"credentials"in a.prototype;if(V.isFormData(z)){const ve=ne.getContentType();ve&&/^multipart\/form-data/i.test(ve)&&!/boundary=/i.test(ve)&&ne.delete("content-type")}ne.set("User-Agent","axios/"+fd,!1);const pe=ae(H({},re),{signal:se,method:R.toUpperCase(),headers:e0(ne.normalize()),body:z,duplex:"half",credentials:k?J:void 0});C=d&&new a(O,pe);let Se=yield d?Q(C,re):Q(O,pe);if(Ie){const ve=V.toFiniteNumber(Se.headers.get("content-length"));if(ve!=null&&ve>oe)throw new ke("maxContentLength size of "+oe+" exceeded",ke.ERR_BAD_RESPONSE,A,C)}const Ae=y&&(D==="stream"||D==="response");if(y&&Se.body&&(de||Ie||Ae&&F)){const ve={};["status","statusText","headers"].forEach(Xn=>{ve[Xn]=Se[Xn]});const qe=V.toFiniteNumber(Se.headers.get("content-length")),[ut,pn]=de&&c0(qe,Eu(d0(de),!0))||[];let Wi=0;const Zr=Xn=>{if(Ie&&(Wi=Xn,Wi>oe))throw new ke("maxContentLength size of "+oe+" exceeded",ke.ERR_BAD_RESPONSE,A,C);ut&&ut(Xn)};Se=new u(m0(Se.body,g0,Zr,()=>{pn&&pn(),F&&F()}),ve)}D=D||"text";let Be=yield x[V.findKey(x,D)||"text"](Se,A);if(Ie&&!y&&!Ae){let ve;if(Be!=null&&(typeof Be.byteLength=="number"?ve=Be.byteLength:typeof Be.size=="number"?ve=Be.size:typeof Be=="string"&&(ve=typeof r=="function"?new r().encode(Be).byteLength:Be.length)),typeof ve=="number"&&ve>oe)throw new ke("maxContentLength size of "+oe+" exceeded",ke.ERR_BAD_RESPONSE,A,C)}return!Ae&&F&&F(),yield new Promise((ve,qe)=>{l0(ve,qe,{data:Be,headers:tn.from(Se.headers),status:Se.status,statusText:Se.statusText,config:A,request:C})})}catch(k){if(F&&F(),se&&se.aborted&&se.reason instanceof ke){const pe=se.reason;throw pe.config=A,C&&(pe.request=C),k!==pe&&(pe.cause=k),pe}throw k&&k.name==="TypeError"&&/Load failed|fetch/i.test(k.message)?Object.assign(new ke("Network Error",ke.ERR_NETWORK,A,C,k&&k.response),{cause:k.cause||k}):ke.from(k,k&&k.code,A,C,k&&k.response)}})},Pv=new Map,y0=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,p=Pv;for(;c--;)d=a[c],h=p.get(d),h===void 0&&p.set(d,h=c?new Map:Rv(t)),p=h;return h};y0();const hd={http:iv,xhr:Av,fetch:{get:y0}};V.forEach(hd,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(n){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const b0=e=>`- ${e}`,Lv=e=>V.isFunction(e)||e===null||e===!1;function Dv(e,t){e=V.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,!Lv(r)&&(o=hd[(c=String(r)).toLowerCase()],o===void 0))throw new ke(`Unknown adapter '${c}'`);if(o&&(V.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 :
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[t0]=this[t0]={accessors:{}}).accessors,o=this.prototype;function a(u){const c=Cs(u);r[c]||(ev(o,u),r[c]=!0)}return V.isArray(t)?t.forEach(a):a(t),this}};tn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),V.reduceDescriptors(tn.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),V.freezeMethods(tn);const tv="[REDACTED ****]";function nv(e){if(V.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(V.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function rv(e,t){const n=new Set(t.map(a=>String(a).toLowerCase())),r=[],o=a=>{if(a===null||typeof a!="object"||V.isBuffer(a))return a;if(r.indexOf(a)!==-1)return;a instanceof tn&&(a=a.toJSON()),r.push(a);let u;if(V.isArray(a))u=[],a.forEach((c,d)=>{const h=o(c);V.isUndefined(h)||(u[d]=h)});else{if(!V.isPlainObject(a)&&nv(a))return r.pop(),a;u=Object.create(null);for(const[c,d]of Object.entries(a)){const h=n.has(c.toLowerCase())?tv:o(d);V.isUndefined(h)||(u[c]=h)}}return r.pop(),u};return o(e)}let ke=class ew extends Error{static from(t,n,r,o,a,u){const c=new ew(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&&V.hasOwnProp(t,"redact")?t.redact:void 0,r=V.isArray(n)&&n.length>0?rv(t,n):V.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}}};ke.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",ke.ERR_BAD_OPTION="ERR_BAD_OPTION",ke.ECONNABORTED="ECONNABORTED",ke.ETIMEDOUT="ETIMEDOUT",ke.ECONNREFUSED="ECONNREFUSED",ke.ERR_NETWORK="ERR_NETWORK",ke.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",ke.ERR_DEPRECATED="ERR_DEPRECATED",ke.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",ke.ERR_BAD_REQUEST="ERR_BAD_REQUEST",ke.ERR_CANCELED="ERR_CANCELED",ke.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",ke.ERR_INVALID_URL="ERR_INVALID_URL",ke.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const iv=null;function od(e){return V.isPlainObject(e)||V.isArray(e)}function n0(e){return V.endsWith(e,"[]")?e.slice(0,-2):e}function sd(e,t,n){return e?e.concat(t).map(function(o,a){return o=n0(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function ov(e){return V.isArray(e)&&!e.some(od)}const sv=V.toFlatObject(V,{},null,function(t){return/^is[A-Z]/.test(t)});function gu(e,t,n){if(!V.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=V.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,A){return!V.isUndefined(A[S])});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&&V.isSpecCompliantForm(t);if(!V.isFunction(o))throw new TypeError("visitor must be a function");function p(_){if(_===null)return"";if(V.isDate(_))return _.toISOString();if(V.isBoolean(_))return _.toString();if(!h&&V.isBlob(_))throw new ke("Blob is not supported. Use a Buffer instead.");return V.isArrayBuffer(_)||V.isTypedArray(_)?h&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function E(_,S,A){let O=_;if(V.isReactNative(t)&&V.isReactNativeBlob(_))return t.append(sd(A,S,a),p(_)),!1;if(_&&!A&&typeof _=="object"){if(V.endsWith(S,"{}"))S=r?S:S.slice(0,-2),_=JSON.stringify(_);else if(V.isArray(_)&&ov(_)||(V.isFileList(_)||V.endsWith(S,"[]"))&&(O=V.toArray(_)))return S=n0(S),O.forEach(function(H,W){!(V.isUndefined(H)||H===null)&&t.append(u===!0?sd([S],W,a):u===null?S:S+"[]",p(H))}),!1}return od(_)?!0:(t.append(sd(A,S,a),p(_)),!1)}const T=[],y=Object.assign(sv,{defaultVisitor:E,convertValue:p,isVisitable:od});function x(_,S,A=0){if(!V.isUndefined(_)){if(A>d)throw new ke("Object is too deeply nested ("+A+" levels). Max depth: "+d,ke.ERR_FORM_DATA_DEPTH_EXCEEDED);if(T.indexOf(_)!==-1)throw Error("Circular reference detected in "+S.join("."));T.push(_),V.forEach(_,function(R,H){(!(V.isUndefined(R)||R===null)&&o.call(t,R,V.isString(H)?H.trim():H,S,y))===!0&&x(R,S?S.concat(H):[H],A+1)}),T.pop()}}if(!V.isObject(e))throw new TypeError("data must be an object");return x(e),t}function r0(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function ad(e,t){this._pairs=[],e&&gu(e,this,t)}const i0=ad.prototype;i0.append=function(t,n){this._pairs.push([t,n])},i0.toString=function(t){const n=t?function(r){return t.call(this,r,r0)}:r0;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function av(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function o0(e,t,n){if(!t)return e;const r=n&&n.encode||av,o=V.isFunction(n)?{serialize:n}:n,a=o&&o.serialize;let u;if(a?u=a(t,o):u=V.isURLSearchParams(t)?t.toString():new ad(t,o).toString(r),u){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class s0{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){V.forEach(this.handlers,function(r){r!==null&&t(r)})}}const ud={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},uv={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:ad,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},ld=typeof window!="undefined"&&typeof document!="undefined",cd=typeof navigator=="object"&&navigator||void 0,lv=ld&&(!cd||["ReactNative","NativeScript","NS"].indexOf(cd.product)<0),cv=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",dv=ld&&window.location.href||"http://localhost",Yt=B(B({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:ld,hasStandardBrowserEnv:lv,hasStandardBrowserWebWorkerEnv:cv,navigator:cd,origin:dv},Symbol.toStringTag,{value:"Module"}))),uv);function fv(e,t){return gu(e,new Yt.classes.URLSearchParams,B({visitor:function(n,r,o,a){return Yt.isNode&&V.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function hv(e){return V.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function pv(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 a0(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&&V.isArray(o)?o.length:u,d?(V.hasOwnProp(o,u)?o[u]=V.isArray(o[u])?o[u].concat(r):[o[u],r]:o[u]=r,!c):((!V.hasOwnProp(o,u)||!V.isObject(o[u]))&&(o[u]=[]),t(n,r,o[u],a)&&V.isArray(o[u])&&(o[u]=pv(o[u])),!c)}if(V.isFormData(e)&&V.isFunction(e.entries)){const n={};return V.forEachEntry(e,(r,o)=>{t(hv(r),o,n,0)}),n}return null}const po=(e,t)=>e!=null&&V.hasOwnProp(e,t)?e[t]:void 0;function mv(e,t,n){if(V.isString(e))try{return(t||JSON.parse)(e),V.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const ks={transitional:ud,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=V.isObject(t);if(a&&V.isHTMLForm(t)&&(t=new FormData(t)),V.isFormData(t))return o?JSON.stringify(a0(t)):t;if(V.isArrayBuffer(t)||V.isBuffer(t)||V.isStream(t)||V.isFile(t)||V.isBlob(t)||V.isReadableStream(t))return t;if(V.isArrayBufferView(t))return t.buffer;if(V.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(a){const d=po(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return fv(t,d).toString();if((c=V.isFileList(t))||r.indexOf("multipart/form-data")>-1){const h=po(this,"env"),p=h&&h.FormData;return gu(c?{"files[]":t}:t,p&&new p,d)}}return a||o?(n.setContentType("application/json",!1),mv(t)):t}],transformResponse:[function(t){const n=po(this,"transitional")||ks.transitional,r=n&&n.forcedJSONParsing,o=po(this,"responseType"),a=o==="json";if(V.isResponse(t)||V.isReadableStream(t))return t;if(t&&V.isString(t)&&(r&&!o||a)){const c=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(t,po(this,"parseReviver"))}catch(d){if(c)throw d.name==="SyntaxError"?ke.from(d,ke.ERR_BAD_RESPONSE,this,null,po(this,"response")):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Yt.classes.FormData,Blob:Yt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};V.forEach(["delete","get","head","post","put","patch","query"],e=>{ks.headers[e]={}});function dd(e,t){const n=this||ks,r=t||n,o=tn.from(r.headers);let a=r.data;return V.forEach(e,function(c){a=c.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function u0(e){return!!(e&&e.__CANCEL__)}let Ns=class extends ke{constructor(t,n,r){super(t==null?"canceled":t,ke.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function l0(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ke("Request failed with status code "+n.status,n.status>=400&&n.status<500?ke.ERR_BAD_REQUEST:ke.ERR_BAD_RESPONSE,n.config,n.request,n))}function gv(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function Ev(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(),p=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 y=p&&h-p;return y?Math.round(T*1e3/y):void 0}}function yv(e,t){let n=0,r=1e3/t,o,a;const u=(h,p=Date.now())=>{n=p,o=null,a&&(clearTimeout(a),a=null),e(...h)};return[(...h)=>{const p=Date.now(),E=p-n;E>=r?u(h,p):(o=h,a||(a=setTimeout(()=>{a=null,u(o)},r-E)))},()=>o&&u(o)]}const Eu=(e,t,n=3)=>{let r=0;const o=Ev(50,250);return yv(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),p=o(h);r=Math.max(r,d);const E={loaded:d,total:c,progress:c?d/c:void 0,bytes:h,rate:p||void 0,estimated:p&&c?(c-d)/p:void 0,event:a,lengthComputable:c!=null,[t?"download":"upload"]:!0};e(E)},n)},c0=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},d0=e=>(...t)=>V.asap(()=>e(...t)),bv=Yt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Yt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Yt.origin),Yt.navigator&&/(msie|trident)/i.test(Yt.navigator.userAgent)):()=>!0,Tv=Yt.hasStandardBrowserEnv?{write(e,t,n,r,o,a,u){if(typeof document=="undefined")return;const c=[`${e}=${encodeURIComponent(t)}`];V.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),V.isString(r)&&c.push(`path=${r}`),V.isString(o)&&c.push(`domain=${o}`),a===!0&&c.push("secure"),V.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 xv(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function wv(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function f0(e,t,n){let r=!xv(t);return e&&(r||n===!1)?wv(e,t):t}const h0=e=>e instanceof tn?B({},e):e;function vi(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,p,E,T){return V.isPlainObject(h)&&V.isPlainObject(p)?V.merge.call({caseless:T},h,p):V.isPlainObject(p)?V.merge({},p):V.isArray(p)?p.slice():p}function o(h,p,E,T){if(V.isUndefined(p)){if(!V.isUndefined(h))return r(void 0,h,E,T)}else return r(h,p,E,T)}function a(h,p){if(!V.isUndefined(p))return r(void 0,p)}function u(h,p){if(V.isUndefined(p)){if(!V.isUndefined(h))return r(void 0,h)}else return r(void 0,p)}function c(h,p,E){if(V.hasOwnProp(t,E))return r(h,p);if(V.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,p,E)=>o(h0(h),h0(p),E,!0)};return V.forEach(Object.keys(B(B({},e),t)),function(p){if(p==="__proto__"||p==="constructor"||p==="prototype")return;const E=V.hasOwnProp(d,p)?d[p]:o,T=V.hasOwnProp(e,p)?e[p]:void 0,y=V.hasOwnProp(t,p)?t[p]:void 0,x=E(T,y,p);V.isUndefined(x)&&E!==c||(n[p]=x)}),n}const _v=["content-type","content-length"];function vv(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,o])=>{_v.includes(r.toLowerCase())&&e.set(r,o)})}const Sv=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),p0=e=>{const t=vi({},e),n=T=>V.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"),p=n("allowAbsoluteUrls"),E=n("url");if(t.headers=c=tn.from(c),t.url=o0(f0(h,E,p),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?Sv(d.password):""))),V.isFormData(r)&&(Yt.hasStandardBrowserEnv||Yt.hasStandardBrowserWebWorkerEnv?c.setContentType(void 0):V.isFunction(r.getHeaders)&&vv(c,r.getHeaders(),n("formDataHeaderPolicy"))),Yt.hasStandardBrowserEnv&&(V.isFunction(o)&&(o=o(t)),o===!0||o==null&&bv(t.url))){const y=a&&u&&Tv.read(u);y&&c.set(a,y)}return t},Av=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=p0(e);let a=o.data;const u=tn.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:h}=o,p,E,T,y,x;function _(){y&&y(),x&&x(),o.cancelToken&&o.cancelToken.unsubscribe(p),o.signal&&o.signal.removeEventListener("abort",p)}let S=new XMLHttpRequest;S.open(o.method.toUpperCase(),o.url,!0),S.timeout=o.timeout;function A(){if(!S)return;const R=tn.from("getAllResponseHeaders"in S&&S.getAllResponseHeaders()),W={data:!c||c==="text"||c==="json"?S.responseText:S.response,status:S.status,statusText:S.statusText,headers:R,config:e,request:S};l0(function(K){n(K),_()},function(K){r(K),_()},W),S=null}"onloadend"in S?S.onloadend=A:S.onreadystatechange=function(){!S||S.readyState!==4||S.status===0&&!(S.responseURL&&S.responseURL.startsWith("file:"))||setTimeout(A)},S.onabort=function(){S&&(r(new ke("Request aborted",ke.ECONNABORTED,e,S)),_(),S=null)},S.onerror=function(H){const W=H&&H.message?H.message:"Network Error",D=new ke(W,ke.ERR_NETWORK,e,S);D.event=H||null,r(D),_(),S=null},S.ontimeout=function(){let H=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const W=o.transitional||ud;o.timeoutErrorMessage&&(H=o.timeoutErrorMessage),r(new ke(H,W.clarifyTimeoutError?ke.ETIMEDOUT:ke.ECONNABORTED,e,S)),_(),S=null},a===void 0&&u.setContentType(null),"setRequestHeader"in S&&V.forEach(e0(u),function(H,W){S.setRequestHeader(W,H)}),V.isUndefined(o.withCredentials)||(S.withCredentials=!!o.withCredentials),c&&c!=="json"&&(S.responseType=o.responseType),h&&([T,x]=Eu(h,!0),S.addEventListener("progress",T)),d&&S.upload&&([E,y]=Eu(d),S.upload.addEventListener("progress",E),S.upload.addEventListener("loadend",y)),(o.cancelToken||o.signal)&&(p=R=>{S&&(r(!R||R.type?new Ns(null,e,S):R),S.abort(),_(),S=null)},o.cancelToken&&o.cancelToken.subscribe(p),o.signal&&(o.signal.aborted?p():o.signal.addEventListener("abort",p)));const O=gv(o.url);if(O&&!Yt.protocols.includes(O)){r(new ke("Unsupported protocol "+O+":",ke.ERR_BAD_REQUEST,e));return}S.send(a||null)})},Cv=(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 ke?h:new Ns(h instanceof Error?h.message:h))}};let a=t&&setTimeout(()=>{a=null,o(new ke(`timeout of ${t}ms exceeded`,ke.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=()=>V.asap(u),c},kv=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},Nv=function(e,t){return xm(this,null,function*(){try{for(var n=Z2(Ov(e)),r,o,a;r=!(o=yield new uo(n.next())).done;r=!1){const u=o.value;yield*wm(kv(u,t))}}catch(o){a=[o]}finally{try{r&&(o=n.return)&&(yield new uo(o.call(n)))}finally{if(a)throw a[0]}}})},Ov=function(e){return xm(this,null,function*(){if(e[Symbol.asyncIterator]){yield*wm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new uo(t.read());if(n)break;yield r}}finally{yield new uo(t.cancel())}})},m0=(e,t,n,r)=>{const o=Nv(e,t);let a=0,u,c=h=>{u||(u=!0,r&&r(h))};return new ReadableStream({pull(h){return $e(this,null,function*(){try{const{done:p,value:E}=yield o.next();if(p){c(),h.close();return}let T=E.byteLength;if(n){let y=a+=T;n(y)}h.enqueue(new Uint8Array(E))}catch(p){throw c(p),p}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})};function Iv(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 y=0;y<c;y++)if(r.charCodeAt(y)===37&&y+2<c){const x=r.charCodeAt(y+1),_=r.charCodeAt(y+2);(x>=48&&x<=57||x>=65&&x<=70||x>=97&&x<=102)&&(_>=48&&_<=57||_>=65&&_<=70||_>=97&&_<=102)&&(u-=2,y+=2)}let d=0,h=c-1;const p=y=>y>=2&&r.charCodeAt(y-2)===37&&r.charCodeAt(y-1)===51&&(r.charCodeAt(y)===68||r.charCodeAt(y)===100);h>=0&&(r.charCodeAt(h)===61?(d++,h--):p(h)&&(d++,h-=3)),d===1&&h>=0&&(r.charCodeAt(h)===61||p(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 fd="1.16.1",g0=64*1024,{isFunction:yu}=V,E0=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},Rv=e=>{const t=V.global!==void 0&&V.global!==null?V.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=V.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:o,Request:a,Response:u}=e,c=o?yu(o):typeof fetch=="function",d=yu(a),h=yu(u);if(!c)return!1;const p=c&&yu(n),E=c&&(typeof r=="function"?(A=>O=>A.encode(O))(new r):A=>$e(null,null,function*(){return new Uint8Array(yield new a(A).arrayBuffer())})),T=d&&p&&E0(()=>{let A=!1;const O=new a(Yt.origin,{body:new n,method:"POST",get duplex(){return A=!0,"half"}}),R=O.headers.has("Content-Type");return O.body!=null&&O.body.cancel(),A&&!R}),y=h&&p&&E0(()=>V.isReadableStream(new u("").body)),x={stream:y&&(A=>A.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(A=>{!x[A]&&(x[A]=(O,R)=>{let H=O&&O[A];if(H)return H.call(O);throw new ke(`Response type '${A}' is not supported`,ke.ERR_NOT_SUPPORT,R)})});const _=A=>$e(null,null,function*(){if(A==null)return 0;if(V.isBlob(A))return A.size;if(V.isSpecCompliantForm(A))return(yield new a(Yt.origin,{method:"POST",body:A}).arrayBuffer()).byteLength;if(V.isArrayBufferView(A)||V.isArrayBuffer(A))return A.byteLength;if(V.isURLSearchParams(A)&&(A=A+""),V.isString(A))return(yield E(A)).byteLength}),S=(A,O)=>$e(null,null,function*(){const R=V.toFiniteNumber(A.getContentLength());return R==null?_(O):R});return A=>$e(null,null,function*(){let{url:O,method:R,data:H,signal:W,cancelToken:D,timeout:K,onDownloadProgress:fe,onUploadProgress:Te,responseType:z,headers:X,withCredentials:se="same-origin",fetchOptions:ee,maxContentLength:re,maxBodyLength:de}=p0(A);const Oe=V.isNumber(re)&&re>-1,he=V.isNumber(de)&&de>-1;let Q=o||fetch;z=z?(z+"").toLowerCase():"text";let oe=Cv([W,D&&D.toAbortSignal()],K),C=null;const M=oe&&oe.unsubscribe&&(()=>{oe.unsubscribe()});let ne;try{if(Oe&&typeof O=="string"&&O.startsWith("data:")&&Iv(O)>re)throw new ke("maxContentLength size of "+re+" exceeded",ke.ERR_BAD_RESPONSE,A,C);if(he&&R!=="get"&&R!=="head"){const ve=yield S(X,H);if(typeof ve=="number"&&isFinite(ve)&&ve>de)throw new ke("Request body larger than maxBodyLength limit",ke.ERR_BAD_REQUEST,A,C)}if(Te&&T&&R!=="get"&&R!=="head"&&(ne=yield S(X,H))!==0){let ve=new a(O,{method:"POST",body:H,duplex:"half"}),qe;if(V.isFormData(H)&&(qe=ve.headers.get("content-type"))&&X.setContentType(qe),ve.body){const[ut,pn]=c0(ne,Eu(d0(Te)));H=m0(ve.body,g0,ut,pn)}}V.isString(se)||(se=se?"include":"omit");const k=d&&"credentials"in a.prototype;if(V.isFormData(H)){const ve=X.getContentType();ve&&/^multipart\/form-data/i.test(ve)&&!/boundary=/i.test(ve)&&X.delete("content-type")}X.set("User-Agent","axios/"+fd,!1);const me=ae(B({},ee),{signal:oe,method:R.toUpperCase(),headers:e0(X.normalize()),body:H,duplex:"half",credentials:k?se:void 0});C=d&&new a(O,me);let Se=yield d?Q(C,ee):Q(O,me);if(Oe){const ve=V.toFiniteNumber(Se.headers.get("content-length"));if(ve!=null&&ve>re)throw new ke("maxContentLength size of "+re+" exceeded",ke.ERR_BAD_RESPONSE,A,C)}const Ae=y&&(z==="stream"||z==="response");if(y&&Se.body&&(fe||Oe||Ae&&M)){const ve={};["status","statusText","headers"].forEach(Xn=>{ve[Xn]=Se[Xn]});const qe=V.toFiniteNumber(Se.headers.get("content-length")),[ut,pn]=fe&&c0(qe,Eu(d0(fe),!0))||[];let Wi=0;const Zr=Xn=>{if(Oe&&(Wi=Xn,Wi>re))throw new ke("maxContentLength size of "+re+" exceeded",ke.ERR_BAD_RESPONSE,A,C);ut&&ut(Xn)};Se=new u(m0(Se.body,g0,Zr,()=>{pn&&pn(),M&&M()}),ve)}z=z||"text";let Be=yield x[V.findKey(x,z)||"text"](Se,A);if(Oe&&!y&&!Ae){let ve;if(Be!=null&&(typeof Be.byteLength=="number"?ve=Be.byteLength:typeof Be.size=="number"?ve=Be.size:typeof Be=="string"&&(ve=typeof r=="function"?new r().encode(Be).byteLength:Be.length)),typeof ve=="number"&&ve>re)throw new ke("maxContentLength size of "+re+" exceeded",ke.ERR_BAD_RESPONSE,A,C)}return!Ae&&M&&M(),yield new Promise((ve,qe)=>{l0(ve,qe,{data:Be,headers:tn.from(Se.headers),status:Se.status,statusText:Se.statusText,config:A,request:C})})}catch(k){if(M&&M(),oe&&oe.aborted&&oe.reason instanceof ke){const me=oe.reason;throw me.config=A,C&&(me.request=C),k!==me&&(me.cause=k),me}throw k&&k.name==="TypeError"&&/Load failed|fetch/i.test(k.message)?Object.assign(new ke("Network Error",ke.ERR_NETWORK,A,C,k&&k.response),{cause:k.cause||k}):ke.from(k,k&&k.code,A,C,k&&k.response)}})},Pv=new Map,y0=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,p=Pv;for(;c--;)d=a[c],h=p.get(d),h===void 0&&p.set(d,h=c?new Map:Rv(t)),p=h;return h};y0();const hd={http:iv,xhr:Av,fetch:{get:y0}};V.forEach(hd,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(n){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const b0=e=>`- ${e}`,Lv=e=>V.isFunction(e)||e===null||e===!1;function Dv(e,t){e=V.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,!Lv(r)&&(o=hd[(c=String(r)).toLowerCase()],o===void 0))throw new ke(`Unknown adapter '${c}'`);if(o&&(V.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
11
  `+u.map(b0).join(`
12
12
  `):" "+b0(u[0]):"as no adapter specified";throw new ke("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return o}const T0={getAdapter:Dv,adapters:hd};function pd(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ns(null,e)}function x0(e){return pd(e),e.headers=tn.from(e.headers),e.data=dd.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),T0.getAdapter(e.adapter||ks.adapter,e)(e).then(function(r){pd(e),e.response=r;try{r.data=dd.call(e,e.transformResponse,r)}finally{delete e.response}return r.headers=tn.from(r.headers),r},function(r){if(!u0(r)&&(pd(e),r&&r.response)){e.response=r.response;try{r.response.data=dd.call(e,e.transformResponse,r.response)}finally{delete e.response}r.response.headers=tn.from(r.response.headers)}return Promise.reject(r)})}const bu={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{bu[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const w0={};bu.transitional=function(t,n,r){function o(a,u){return"[Axios v"+fd+"] Transitional option '"+a+"'"+u+(r?". "+r:"")}return(a,u,c)=>{if(t===!1)throw new ke(o(u," has been removed"+(n?" in "+n:"")),ke.ERR_DEPRECATED);return n&&!w0[u]&&(w0[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}},bu.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function Mv(e,t,n){if(typeof e!="object")throw new ke("options must be an object",ke.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 ke("option "+a+" must be "+d,ke.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ke("Unknown option "+a,ke.ERR_BAD_OPTION)}}const Tu={assertOptions:Mv,validators:bu},In=Tu.validators;let Si=class{constructor(t){this.defaults=t||{},this.interceptors={request:new s0,response:new s0}}request(t,n){return $e(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=vi(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&Tu.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&&(V.isFunction(o)?n.paramsSerializer={serialize:o}:Tu.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),Tu.assertOptions(n,{baseUrl:In.spelling("baseURL"),withXsrfToken:In.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&V.merge(a.common,a[n.method]);a&&V.forEach(["delete","get","head","post","put","patch","query","common"],x=>{delete a[x]}),n.headers=tn.concat(u,a);const c=[];let d=!0;this.interceptors.request.forEach(function(_){if(typeof _.runWhen=="function"&&_.runWhen(n)===!1)return;d=d&&_.synchronous;const S=n.transitional||ud;S&&S.legacyInterceptorReqResOrdering?c.unshift(_.fulfilled,_.rejected):c.push(_.fulfilled,_.rejected)});const h=[];this.interceptors.response.forEach(function(_){h.push(_.fulfilled,_.rejected)});let p,E=0,T;if(!d){const x=[x0.bind(this),void 0];for(x.unshift(...c),x.push(...h),T=x.length,p=Promise.resolve(n);E<T;)p=p.then(x[E++],x[E++]);return p}T=c.length;let y=n;for(;E<T;){const x=c[E++],_=c[E++];try{y=x(y)}catch(S){_.call(this,S);break}}try{p=x0.call(this,y)}catch(x){return Promise.reject(x)}for(E=0,T=h.length;E<T;)p=p.then(h[E++],h[E++]);return p}getUri(t){t=vi(this.defaults,t);const n=f0(t.baseURL,t.url,t.allowAbsoluteUrls);return o0(n,t.params,t.paramsSerializer)}};V.forEach(["delete","get","head","options"],function(t){Si.prototype[t]=function(n,r){return this.request(vi(r||{},{method:t,url:n,data:(r||{}).data}))}}),V.forEach(["post","put","patch","query"],function(t){function n(r){return function(a,u,c){return this.request(vi(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 Fv=class tw{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 Ns(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 tw(function(o){t=o}),cancel:t}}};function Bv(e){return function(n){return e.apply(null,n)}}function Uv(e){return V.isObject(e)&&e.isAxiosError===!0}const md={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(md).forEach(([e,t])=>{md[t]=e});function _0(e){const t=new Si(e),n=Vm(Si.prototype.request,t);return V.extend(n,Si.prototype,t,{allOwnKeys:!0}),V.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return _0(vi(e,o))},n}const xt=_0(ks);xt.Axios=Si,xt.CanceledError=Ns,xt.CancelToken=Fv,xt.isCancel=u0,xt.VERSION=fd,xt.toFormData=gu,xt.AxiosError=ke,xt.Cancel=xt.CanceledError,xt.all=function(t){return Promise.all(t)},xt.spread=Bv,xt.isAxiosError=Uv,xt.mergeConfig=vi,xt.AxiosHeaders=tn,xt.formToJSON=e=>a0(V.isHTMLForm(e)?new FormData(e):e),xt.getAdapter=T0.getAdapter,xt.HttpStatusCode=md,xt.default=xt;const{Axios:q9,AxiosError:Y9,CanceledError:W9,isCancel:G9,CancelToken:K9,VERSION:Q9,all:X9,Cancel:J9,isAxiosError:Z9,spread:eF,toFormData:tF,AxiosHeaders:nF,HttpStatusCode:rF,formToJSON:iF,getAdapter:oF,mergeConfig:sF,create:aF}=xt;class Hv{constructor(t,n,r,o=!1,a,u){Ze(this,"CIMULATE_API_HEADER","x-cimulate-api-key");Ze(this,"CIMULATE_SEARCH_API_HOST","search.cimulate");Ze(this,"CIMULATE_SEARCH_API_PATH","api/v1");Ze(this,"baseApiUrl");Ze(this,"headers",{});Ze(this,"fetchConfig",()=>$e(this,null,function*(){try{const t=yield xt.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}}));Ze(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}`),a&&(this.headers["x-cimulate-customer-id"]=a),u&&(this.headers["Tenant-ID"]=u),this.baseApiUrl=this._mapCopilotUrlToSearchUrl(t,o)}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}class zv{constructor(t,n,r,o=!1,a,u){Ze(this,"apiService");Ze(this,"config",null);Ze(this,"getConfig",()=>$e(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}}));Ze(this,"getPid",t=>this.getProductFieldValue(t,"pidCol"));Ze(this,"getName",t=>this.getProductFieldValue(t,"nameCol"));Ze(this,"getDescription",t=>this.getProductFieldValue(t,"description"));Ze(this,"getBrand",t=>this.getProductFieldValue(t,"productBrandCol"));Ze(this,"getPrice",t=>this.getProductFieldValue(t,"priceCol"));Ze(this,"getRelativePdp",t=>this.getProductFieldValue(t,"relativePdpCol"));Ze(this,"getPdp",t=>this.getProductFieldValue(t,"pdpCol"));Ze(this,"getImage",t=>this.getProductFieldValue(t,"imageCol"));Ze(this,"getProductHiddenFields",()=>{const t=this.getProductField("productHiddenFields");return Array.isArray(t)?t:[]});Ze(this,"getProductField",t=>this.config?this.config[t]:"");Ze(this,"getProductFieldValue",(t,n)=>{const r=this.getProductField(n);return r&&t[r]||""});this.apiService=new Hv(t,n,r,o,a,u)}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 jv{constructor(t=!1){Ze(this,"isDevelopment");Ze(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 $v={copilot:"Your Search Assistant",messaging:"Commerce Client"},v0=Z.createContext(null),Vv=({mode:e,logoUrl:t,headerText:n="Your Search Assistant",headerConfig:r,globalClassName:o="",entryMessage:a,openLinksInNewTab:u=!1,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,baseCatalogParams:p,searchPlaceholder:E,searchButtonLabel:T,searchConfig:y,componentConfig:x,conversationHistory:_,resetConversationMessage:S="",apiKey:A,apiToken:O,baseUrl:R,customerId:z,tenantId:W,theme:M,isDevelopment:K,__features:de,children:xe})=>{const D=e==="messaging",ne=Z.useMemo(()=>D?{config:null}:new zv(R,A,O,K,z,W),[D,R,A,O,K,z,W]),J=Z.useMemo(()=>new jv(K),[K]);Z.useEffect(()=>{D||!ne||ne.config||ne.getConfig()},[ne,D]);const re=Z.useMemo(()=>n_(M),[M]),oe=Z.useMemo(()=>{const fe=(y==null?void 0:y.placeholder)||E,Q=(y==null?void 0:y.buttonLabel)||T;let se="icon";return y!=null&&y.buttonType?se=y.buttonType:T&&(se="text"),ae(H({},y||{}),{placeholder:fe,buttonLabel:Q,buttonType:se})},[y,E,T]),be=Z.useMemo(()=>ae(H({},r||{}),{logoUrl:t||(r==null?void 0:r.logoUrl),headerText:n||$v[e!=null?e:"copilot"]}),[r,t,n,e]),Ie=Z.useMemo(()=>({configModule:ne,mode:e!=null?e:"copilot",headerConfig:be,entryMessage:a,globalClassName:o,openLinksInNewTab:u,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,baseCatalogParams:p,themeVariables:re,logger:J,searchConfig:oe,enableMinimize:!!(x!=null&&x.enableMinimize),resetConversationMessage:S,conversationHistory:{sinceHours:typeof(_==null?void 0:_.sinceHours)=="number"?_.sinceHours:1,limit:_==null?void 0:_.limit},features:de}),[ne,e,be,a,o,h,p,c,d,u,oe,x,S,J,re,_,de]);return v.jsx(v0.Provider,{value:Ie,children:xe})},At=()=>{const e=Z.useContext(v0);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e},qv=["markdown","product_carousel","suggestions"],xu=-1;function Yv(e){if(!e||!e.trim())return null;try{const t=JSON.parse(e);if(t&&typeof t=="object"&&typeof t.type=="string"&&typeof t.index=="number")return qv.includes(t.type)?t:null}catch(t){}return{type:"markdown",index:xu,data:{content:e}}}function Wv(e,t){if(t.index===xu){const o=e[e.length-1];if(o&&o.type==="markdown"&&o.index===xu&&t.type==="markdown"){const a={type:"markdown",index:xu,data:{content:o.data.content+t.data.content}};return[...e.slice(0,-1),a]}return[...e,t]}const n=e.findIndex(o=>o.index===t.index);return[...n>=0?e.map((o,a)=>a===n?t:o):[...e,t]].sort((o,a)=>o.index-a.index)}const S0={connectionStatus:"disconnected",loading:!0,conversationId:null,messages:[],streamingBlocks:[],isAgentTyping:!1,progressMessage:"",routingResult:null,error:null};function Gv(e,t){switch(t.type){case"SET_CONNECTION_STATUS":return H(ae(H({},e),{connectionStatus:t.status}),t.status==="connected"||t.status==="connecting"?{error:null}:{});case"SET_LOADING":return ae(H({},e),{loading:t.isLoading});case"SET_CONVERSATION_ID":return ae(H({},e),{conversationId:t.id});case"ADD_MESSAGE":return ae(H({},e),{messages:[...e.messages,ae(H({},t.message),{type:"ADD_MESSAGE"})]});case"APPEND_STREAMING_TOKEN":{const n=Yv(t.token);return n?ae(H({},e),{streamingBlocks:Wv(e.streamingBlocks,n)}):e}case"FLUSH_STREAMING":return ae(H({},e),{messages:[...e.messages,ae(H({},t.message),{type:"FLUSH_STREAMING"})],streamingBlocks:[],isAgentTyping:!1,loading:!1,progressMessage:""});case"SET_AGENT_TYPING":return ae(H({},e),{isAgentTyping:t.isTyping,loading:t.isTyping});case"SET_PROGRESS_MESSAGE":return ae(H({},e),{progressMessage:t.message});case"SET_ROUTING_RESULT":return ae(H({},e),{routingResult:t.result});case"SET_ERROR":return ae(H({},e),{error:t.error,loading:!1,progressMessage:""});case"LOAD_HISTORY":return ae(H({},e),{messages:t.messages,loading:!1});case"RESET":return ae(H({},S0),{connectionStatus:e.connectionStatus,loading:!0});default:return e}}const A0=Z.createContext({connectionStatus:"disconnected",isConnected:!1,isAgentTyping:!1,conversationId:null,messages:[],streamingBlocks:[],progressMessage:"",loading:!0,error:null,sendMessage:()=>{},resetConversation:()=>{}});function gd(e,t){return`cim_af_conv_${e}_${t}`}function Ed(e,t){return Date.now()-e>t}function Kv(e,t,n){try{const r=gd(e,t),o=sessionStorage.getItem(r);if(!o)return null;const a=JSON.parse(o);if(!a||typeof a!="object"||!("conversationId"in a)||!("storedAt"in a))return null;const u=a;return typeof u.conversationId!="string"||!u.conversationId?null:typeof u.storedAt!="number"||Ed(u.storedAt,n)?(sessionStorage.removeItem(r),null):u}catch(r){return null}}function Os(e,t,n){try{const r=gd(e,t),o={conversationId:n,storedAt:Date.now()};sessionStorage.setItem(r,JSON.stringify(o))}catch(r){}}function wu(e,t){try{const n=gd(e,t);sessionStorage.removeItem(n)}catch(n){}}function yd(e,t){return`cim_af_ct_${e}_${t}`}function C0(e,t,n){try{const r=yd(e,t),o=sessionStorage.getItem(r);if(!o)return null;const a=JSON.parse(o);if(!a||typeof a!="object"||!("accessToken"in a)||!("lastEventId"in a)||!("storedAt"in a))return null;const u=a;return typeof u.accessToken!="string"||!u.accessToken||typeof u.lastEventId!="string"||!u.lastEventId?null:typeof u.storedAt!="number"||Date.now()-u.storedAt>n?(sessionStorage.removeItem(r),null):u}catch(r){return null}}function Qv(e,t,n,r){try{const o=yd(e,t),a={accessToken:n,lastEventId:r,storedAt:Date.now()};sessionStorage.setItem(o,JSON.stringify(a))}catch(o){}}function Xv(e,t){try{const n=yd(e,t);sessionStorage.removeItem(n)}catch(n){}}function Jv(e,t){return`cim_af_conv_${e}_${t}`}function Zv(e,t){try{if(typeof BroadcastChannel=="undefined")return null;const n=Jv(e,t);return new BroadcastChannel(n)}catch(n){return null}}function eS(e,t=500){return e?new Promise(n=>{let r=!1;const o=setTimeout(()=>{r||(r=!0,e.removeEventListener("message",a),n(null))},t);function a(u){var c;r||((c=u.data)==null?void 0:c.type)==="conversation_response"&&(r=!0,clearTimeout(o),e.removeEventListener("message",a),n({conversationId:u.data.conversationId,storedAt:u.data.storedAt,continuationToken:u.data.continuationToken,lastEventId:u.data.lastEventId}))}e.addEventListener("message",a);try{e.postMessage({type:"request_conversation"})}catch(u){r||(r=!0,clearTimeout(o),e.removeEventListener("message",a),n(null))}}):Promise.resolve(null)}function tS(e,t,n){if(!e)return()=>{};function r(o){var a;if((a=o.data)!=null&&a.type)switch(o.data.type){case"request_conversation":{const u=t();if(u!=null&&u.conversationId)try{e.postMessage({type:"conversation_response",conversationId:u.conversationId,storedAt:Date.now(),continuationToken:u.continuationToken,lastEventId:u.lastEventId})}catch(c){}break}case"conversation_cleared":{n==null||n();break}}}return e.addEventListener("message",r),()=>{e.removeEventListener("message",r)}}function nS(e){if(e)try{e.postMessage({type:"conversation_cleared"})}catch(t){}}function rS(e){if(e)try{e.close()}catch(t){}}function iS(e){switch(e){case"EndUser":case"Customer":return"user";case"Agent":case"Chatbot":return"agent";default:return"system"}}function oS(e){if(!e)return{};if(typeof e=="string")try{return JSON.parse(e)}catch(t){return{}}return e}function k0(e,...t){let n=e;for(const r of t){if(n==null||typeof n!="object")return"";n=n[r]}return typeof n=="string"?n:""}function sS(e){if(e.entryType!=="Message")return null;const n=oS(e.entryPayload).abstractMessage;if(!n)return null;const r=k0(n,"staticContent","text")||k0(n,"content","text")||"";if(!r)return null;const o=iS(e.sender.role);return{id:e.identifier,role:o,content:r,timestamp:new Date(e.transcriptedTimestamp).toISOString(),sender:{role:e.sender.role,name:e.senderDisplayName}}}function aS(e){const t=[];for(const n of e){const r=sS(n);r&&t.push(r)}return t}function uS(e){const{orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:o}=e,a=Z.useRef(null),u=Z.useRef(null),c=Z.useRef(null),d=o.sinceHours*60*60*1e3,h=Z.useCallback(()=>(c.current||(c.current=eS(a.current)),c.current),[]);Z.useEffect(()=>{const S=Zv(t,n);a.current=S,c.current=null;const A=tS(S,()=>{const O=u.current;if(!O)return null;const R=C0(t,n,d);return{conversationId:O,continuationToken:R==null?void 0:R.accessToken,lastEventId:R==null?void 0:R.lastEventId}},()=>{wu(t,n),u.current=null});return()=>{A(),rS(S),a.current=null}},[t,n,d]);const p=Z.useCallback(S=>$e(null,null,function*(){let A=Kv(t,n,d);if(!A){const O=yield h();O&&!Ed(O.storedAt,d)&&(A=O)}if(!A){const O=yield S.createConversation(r);return Os(t,n,O),u.current=O,{conversationId:O,restoredMessages:[],resumed:!1}}try{const O=Date.now()-d,z=(yield S.listConversations({conversationId:A.conversationId,startTimestamp:O})).conversations.find(M=>M.conversationId===A.conversationId&&!M.isConversationClosed);if(!z){wu(t,n);const M=yield S.createConversation(r);return Os(t,n,M),u.current=M,{conversationId:M,restoredMessages:[],resumed:!1}}S.resumeConversation(z.conversationId),u.current=z.conversationId,Os(t,n,z.conversationId);let W=[];try{const M=yield S.listConversationEntries(z.conversationId,{limit:o.limit,startTimestamp:O,direction:"FromStart"});W=aS(M.conversationEntries)}catch(M){}return{conversationId:z.conversationId,restoredMessages:W,resumed:!0}}catch(O){wu(t,n);const R=yield S.createConversation(r);return Os(t,n,R),u.current=R,{conversationId:R,restoredMessages:[],resumed:!1}}}),[t,n,r,o,d,h]),E=Z.useCallback(S=>{Os(t,n,S),u.current=S},[t,n]),T=Z.useCallback(()=>{wu(t,n),Xv(t,n),nS(a.current),u.current=null},[t,n]),y=Z.useCallback(()=>{const S=C0(t,n,d);return S?{continuationToken:S.accessToken,lastEventId:S.lastEventId}:null},[t,n,d]),x=Z.useCallback(()=>$e(null,null,function*(){const S=yield h();return!(S!=null&&S.continuationToken)||Ed(S.storedAt,d)?null:{continuationToken:S.continuationToken,lastEventId:S.lastEventId}}),[d,h]),_=Z.useCallback(S=>$e(null,null,function*(){try{const{accessToken:A,lastEventId:O}=yield S.generateContinuationToken();Qv(t,n,A,O)}catch(A){}}),[t,n]);return{initializeConversation:p,persistConversationId:E,clearPersistedConversation:T,getStoredConnectOptions:y,getPeerConnectOptions:x,persistContinuationToken:_}}const lS="Your session ended due to inactivity. Starting a new session…";function cS(e){if(!e||typeof e!="object")return!1;const t=e;return t.type==="auth"?!0:t.type==="api"&&(t.statusCode===401||t.statusCode===403)}const N0=({scrt2Url:e,orgId:t,esDeveloperName:n,routingAttributes:r,capabilitiesVersion:o,enableLogging:a=!1,onConnect:u,onMessage:c,onError:d,children:h})=>{const{logger:p,conversationHistory:E}=At(),[T,y]=Z.useReducer(Gv,S0),x=uS({orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:E}),_=Z.useRef(null),S=Z.useRef(c),A=Z.useRef(d),O=Z.useRef(u),R=Z.useRef(!1),z=Z.useRef(0);S.current=c,A.current=d,O.current=u,Z.useEffect(()=>{const D=new t_({baseURL:e,orgId:t,esDeveloperName:n,options:H({enableLogging:a},o?{capabilitiesVersion:o}:{})});return _.current=D,D.on("connected",()=>{var J;y({type:"SET_CONNECTION_STATUS",status:"connected"}),(J=O.current)==null||J.call(O)}),D.on("disconnected",()=>{y({type:"SET_CONNECTION_STATUS",status:"disconnected"})}),D.on("reconnecting",()=>{y({type:"SET_CONNECTION_STATUS",status:"reconnecting"})}),D.on("message",J=>{var oe;const re={id:J.messageId||crypto.randomUUID(),role:"agent",content:J.content,timestamp:J.timestamp,sender:J.sender,raw:J};p==null||p.log("🦜 MessagingProvider message received (FLUSH_STREAMING)",{messageId:re.id,tokensBeforeFlush:z.current,streamedFinalOnly:z.current===0}),z.current=0,y({type:"FLUSH_STREAMING",message:re}),(oe=S.current)==null||oe.call(S,re)}),D.on("streaming_token",J=>{z.current+=1,y({type:"APPEND_STREAMING_TOKEN",token:J.token})}),D.on("typing_started",()=>{y({type:"SET_AGENT_TYPING",isTyping:!0})}),D.on("typing_stopped",()=>{y({type:"SET_AGENT_TYPING",isTyping:!1})}),D.on("progress_indicator",J=>{y({type:"SET_PROGRESS_MESSAGE",message:J.message})}),D.on("routing_result",J=>{var re;if(y({type:"SET_ROUTING_RESULT",result:J}),!J.isSuccessful){const oe=`Routing failed: ${J.failureType||"unknown"}`;y({type:"SET_ERROR",error:oe}),(re=A.current)==null||re.call(A,oe)}}),D.on("participant_changed",J=>{if(J.participant.name==="Automated Process")return;const re={id:crypto.randomUUID(),role:"system",content:J.action==="add"?`${J.participant.name||"Agent"} joined the conversation`:`${J.participant.name||"Agent"} left the conversation`,timestamp:new Date().toISOString()};p==null||p.log("🦜 MessagingProvider participant_changed event received",{event:J}),y({type:"ADD_MESSAGE",message:re})}),D.on("conversation_closed",()=>{const J={id:crypto.randomUUID(),role:"system",content:"Conversation reset",timestamp:new Date().toISOString()};y({type:"ADD_MESSAGE",message:J}),y({type:"SET_CONVERSATION_ID",id:null}),x.clearPersistedConversation()}),D.on("error",J=>{var re;if(p==null||p.log("🦜 MessagingProvider ERROR event received",{event:J}),J.code==="SESSION_EXPIRED"){M.current();return}y({type:"SET_ERROR",error:J.message}),J.recoverable||y({type:"SET_CONNECTION_STATUS",status:"error"}),(re=A.current)==null||re.call(A,J.message)}),y({type:"SET_CONNECTION_STATUS",status:"connecting"}),$e(null,null,function*(){let J=x.getStoredConnectOptions(),re=!1;J||(J=yield x.getPeerConnectOptions(),re=!!J);try{yield D.connect(J!=null?J:void 0)}catch(be){if(J)p==null||p.log("Continuation token failed, falling back to fresh connect"),re||x.clearPersistedConversation(),yield D.connect();else throw be}yield x.persistContinuationToken(D);const oe=yield x.initializeConversation(D);y({type:"SET_CONVERSATION_ID",id:oe.conversationId}),oe.resumed&&oe.restoredMessages.length>0&&y({type:"LOAD_HISTORY",messages:oe.restoredMessages})}).catch(J=>{var re;y({type:"SET_CONNECTION_STATUS",status:"error"}),y({type:"SET_ERROR",error:J.message}),(re=A.current)==null||re.call(A,J.message)}),()=>{D.disconnect(),D.off(),_.current=null}},[e,t,n,o]),Z.useEffect(()=>{const D=()=>{document.visibilityState==="visible"&&_.current&&_.current.reconnect()};return document.addEventListener("visibilitychange",D),()=>{document.removeEventListener("visibilitychange",D)}},[]);const W=Z.useCallback(D=>$e(null,null,function*(){var J;const ne=_.current;if(!(!ne||R.current)){R.current=!0,y({type:"ADD_MESSAGE",message:{id:crypto.randomUUID(),role:"system",content:lS,timestamp:new Date().toISOString()}}),x.clearPersistedConversation(),y({type:"SET_CONNECTION_STATUS",status:"connecting"});try{ne.disconnect(),yield ne.connect(),yield x.persistContinuationToken(ne);const re=yield ne.createConversation(r);y({type:"SET_CONVERSATION_ID",id:re}),y({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(re),D&&(y({type:"SET_LOADING",isLoading:!0}),y({type:"SET_PROGRESS_MESSAGE",message:""}),yield ne.sendMessage(D))}catch(re){const oe=re instanceof Error?re.message:String(re);y({type:"SET_ERROR",error:oe}),y({type:"SET_CONNECTION_STATUS",status:"error"}),(J=A.current)==null||J.call(A,oe)}finally{R.current=!1}}}),[r,x]),M=Z.useRef(W);M.current=W;const K=Z.useCallback(D=>{if(!D.trim())return;const ne=_.current;if(!ne)return;const J={id:crypto.randomUUID(),role:"user",content:D,timestamp:new Date().toISOString()};y({type:"ADD_MESSAGE",message:J}),y({type:"SET_LOADING",isLoading:!0}),y({type:"SET_PROGRESS_MESSAGE",message:""}),ne.sendMessage(D).catch(re=>{var oe;if(cS(re)){M.current(D);return}y({type:"SET_ERROR",error:re.message}),(oe=A.current)==null||oe.call(A,re.message)})},[]),de=Z.useCallback(()=>{const D=_.current;D&&(x.clearPersistedConversation(),y({type:"RESET"}),y({type:"SET_CONNECTION_STATUS",status:"connecting"}),D.endConversation().then(()=>(D.disconnect(),D.connect())).then(()=>$e(null,null,function*(){return yield x.persistContinuationToken(D),D.createConversation(r)})).then(ne=>{y({type:"SET_CONVERSATION_ID",id:ne}),y({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(ne)}).catch(ne=>{var J;y({type:"SET_ERROR",error:ne.message}),y({type:"SET_CONNECTION_STATUS",status:"error"}),(J=A.current)==null||J.call(A,ne.message)}))},[r,x]),xe=Z.useMemo(()=>({connectionStatus:T.connectionStatus,isConnected:T.connectionStatus==="connected"&&T.conversationId!==null,isAgentTyping:T.isAgentTyping,conversationId:T.conversationId,messages:T.messages,streamingBlocks:T.streamingBlocks,progressMessage:T.progressMessage,error:T.error,loading:T.loading,sendMessage:K,resetConversation:de}),[T,K,de]);return v.jsx(A0.Provider,{value:xe,children:h})};function dS(){var e=Z.useRef(!0);return e.current?(e.current=!1,!0):e.current}function fS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.addEventListener&&e.addEventListener.apply(e,t)}function hS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.removeEventListener&&e.removeEventListener.apply(e,t)}var bd=typeof window!="undefined",_u=function(e){Z.useEffect(e,[])},pS=function(e){var t=Z.useRef(e);t.current=e,_u(function(){return function(){return t.current()}})},mS=function(e){var t=Z.useRef(0),n=Z.useState(e),r=n[0],o=n[1],a=Z.useCallback(function(u){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(u)})},[]);return pS(function(){cancelAnimationFrame(t.current)}),[r,a]},gS=function(e,t){return e===t};function ES(e,t){t===void 0&&(t=gS);var n=Z.useRef(),r=Z.useRef(e),o=dS();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var yS=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=mS({width:bd?window.innerWidth:r,height:bd?window.innerHeight:a}),d=c[0],h=c[1];return Z.useEffect(function(){if(bd){var p=function(){var E=window.innerWidth,T=window.innerHeight;h({width:E,height:T}),u&&u(E,T)};return fS(window,"resize",p),function(){hS(window,"resize",p)}}},[]),d};const Td="cimulate:ui-state-update",bS=e=>{window.addEventListener(Td,e)},TS=e=>{window.removeEventListener(Td,e)},xS=(e,t)=>{const n=new CustomEvent(Td,{detail:{property:e,value:t}});window.dispatchEvent(n)},O0=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},Ci=e=>{const t=tt.statusProxy.isOpen,n=typeof e=="boolean"?e:!t;tt.statusProxy.isOpen=n,n&&(tt.statusProxy.isMinimized=!1)},vu=e=>{const t=tt.statusProxy.isMinimized,n=typeof e=="boolean"?e:!t;tt.statusProxy.isMinimized=n,n&&(tt.statusProxy.isOpen=!1)},xd=e=>{tt.modalProxy.isFullscreen=e},Su=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"},wd=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},wS=e=>{const t=tt.dialogProxy.isFullHeight,n=typeof e=="boolean"?e:!t;tt.dialogProxy.isFullHeight=n};class _S{constructor(){Ze(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}});Ze(this,"connectedProxy");Ze(this,"modeProxy");Ze(this,"entryTypeProxy");Ze(this,"statusProxy");Ze(this,"dialogProxy");Ze(this,"modalProxy",{isFullscreen:!1});Ze(this,"_fullGet",(t,n)=>Reflect.get(t,n));Ze(this,"_fullSet",(t,n,r)=>{if(!(n in t))throw new Error(`Property ${n} does not exist on UIState`);return xS(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 _S,I0=Z.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}),vS=({entryType:e,componentConfig:t,componentType:n,children:r})=>{const[o,a]=Z.useState(e!=null?e:tt.entryTypeProxy.entryType),[u,c]=Z.useState(tt.modeProxy.mode),[d,h]=Z.useState({type:n||tt.statusProxy.type,isOpen:tt.statusProxy.isOpen,isMinimized:tt.statusProxy.isMinimized}),[p,E]=Z.useState(tt.dialogProxy.position),[T,y]=Z.useState(tt.dialogProxy.isFullHeight),[x,_]=Z.useState(tt.dialogProxy.width),[S,A]=Z.useState(tt.modalProxy.isFullscreen),O=ES(d.type);Z.useEffect(()=>{const z=W=>{const{property:M,value:K}=W.detail||{};if(!(!M||K===void 0)){if(M==="mode"){c(K);return}if(M==="entryType"){a(K);return}if(M==="isMinimized"){h(de=>ae(H({},de),{isMinimized:K}));return}if(M==="isOpen"){h(de=>ae(H({},de),{isOpen:K}));return}if(M==="type"){h(de=>ae(H({},de),{type:K}));return}if(M==="position"){E(K);return}if(M==="isFullHeight"){y(K);return}if(M==="width"){_(K);return}if(M==="isFullscreen"){A(K);return}}};return bS(z),()=>{TS(z)}},[]),_u(()=>{e&&O0(e)}),_u(()=>{const z=n||(t==null?void 0:t.type);z&&Su(z),t&&"isOpen"in t&&Ci(!!t.isOpen),t&&"isMinimized"in t&&vu(!!t.isMinimized)}),_u(()=>{if(!(t!=null&&t.options))return;const{dialogPosition:z}=t.options;z&&wd(z),"dialogFullHeight"in t.options&&wS(!!t.options.dialogFullHeight),"dialogWidth"in t.options&&t.options.dialogWidth&&_(t.options.dialogWidth),"isModalFullscreen"in t.options&&xd(!!t.options.isModalFullscreen)});const R=Z.useMemo(()=>({mode:u,entryType:o,status:d,previousComponentType:O||"dialog",dialogPosition:p,isDialogFullHeight:T,dialogWidth:x,isModalFullscreen:S}),[u,o,d,O,p,T,x,S]);return v.jsx(I0.Provider,{value:R,children:r})},R0=({mode:e,apiKey:t,apiToken:n,baseUrl:r,logoUrl:o,headerText:a,headerConfig:u,theme:c,openLinksInNewTab:d,globalClassName:h,isDevelopment:p=!1,componentType:E,componentConfig:T,entryType:y,entryMessage:x,disclaimerText:_,disclaimerMarkdown:S,clientContext:A,searchPlaceholder:O,searchButtonLabel:R,searchConfig:z,resetConversationMessage:W,conversationHistory:M,messagingConfig:K,__features:de,children:xe})=>v.jsx(Vv,{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:z,componentConfig:T,clientContext:A,disclaimerMarkdown:S,disclaimerText:_,resetConversationMessage:W,conversationHistory:M,isDevelopment:p,__features:de,children:v.jsx(vS,{entryType:y,componentConfig:T,componentType:E,children:v.jsx(N0,{scrt2Url:(K==null?void 0:K.scrt2Url)||"",orgId:(K==null?void 0:K.orgId)||"",esDeveloperName:(K==null?void 0:K.esDeveloperName)||"",routingAttributes:(K==null?void 0:K.routingAttributes)||{},capabilitiesVersion:K==null?void 0:K.capabilitiesVersion,enableLogging:p,children:xe})})}),ki=()=>{const e=Z.useContext(I0);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};var _d={exports:{}},ln={},vd={exports:{}},Sd={};var P0;function SS(){return P0||(P0=1,(function(e){function t(Q,se){var C=Q.length;Q.push(se);e:for(;0<C;){var F=C-1>>>1,te=Q[F];if(0<o(te,se))Q[F]=se,Q[C]=te,C=F;else break e}}function n(Q){return Q.length===0?null:Q[0]}function r(Q){if(Q.length===0)return null;var se=Q[0],C=Q.pop();if(C!==se){Q[0]=C;e:for(var F=0,te=Q.length,k=te>>>1;F<k;){var pe=2*(F+1)-1,Se=Q[pe],Ae=pe+1,Be=Q[Ae];if(0>o(Se,C))Ae<te&&0>o(Be,Se)?(Q[F]=Be,Q[Ae]=C,F=Ae):(Q[F]=Se,Q[pe]=C,F=pe);else if(Ae<te&&0>o(Be,C))Q[F]=Be,Q[Ae]=C,F=Ae;else break e}}return se}function o(Q,se){var C=Q.sortIndex-se.sortIndex;return C!==0?C:Q.id-se.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=[],p=1,E=null,T=3,y=!1,x=!1,_=!1,S=typeof setTimeout=="function"?setTimeout:null,A=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(Q){for(var se=n(h);se!==null;){if(se.callback===null)r(h);else if(se.startTime<=Q)r(h),se.sortIndex=se.expirationTime,t(d,se);else break;se=n(h)}}function z(Q){if(_=!1,R(Q),!x)if(n(d)!==null)x=!0,Ie(W);else{var se=n(h);se!==null&&fe(z,se.startTime-Q)}}function W(Q,se){x=!1,_&&(_=!1,A(de),de=-1),y=!0;var C=T;try{for(R(se),E=n(d);E!==null&&(!(E.expirationTime>se)||Q&&!ne());){var F=E.callback;if(typeof F=="function"){E.callback=null,T=E.priorityLevel;var te=F(E.expirationTime<=se);se=e.unstable_now(),typeof te=="function"?E.callback=te:E===n(d)&&r(d),R(se)}else r(d);E=n(d)}if(E!==null)var k=!0;else{var pe=n(h);pe!==null&&fe(z,pe.startTime-se),k=!1}return k}finally{E=null,T=C,y=!1}}var M=!1,K=null,de=-1,xe=5,D=-1;function ne(){return!(e.unstable_now()-D<xe)}function J(){if(K!==null){var Q=e.unstable_now();D=Q;var se=!0;try{se=K(!0,Q)}finally{se?re():(M=!1,K=null)}}else M=!1}var re;if(typeof O=="function")re=function(){O(J)};else if(typeof MessageChannel!="undefined"){var oe=new MessageChannel,be=oe.port2;oe.port1.onmessage=J,re=function(){be.postMessage(null)}}else re=function(){S(J,0)};function Ie(Q){K=Q,M||(M=!0,re())}function fe(Q,se){de=S(function(){Q(e.unstable_now())},se)}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(Q){Q.callback=null},e.unstable_continueExecution=function(){x||y||(x=!0,Ie(W))},e.unstable_forceFrameRate=function(Q){0>Q||125<Q?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):xe=0<Q?Math.floor(1e3/Q):5},e.unstable_getCurrentPriorityLevel=function(){return T},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(Q){switch(T){case 1:case 2:case 3:var se=3;break;default:se=T}var C=T;T=se;try{return Q()}finally{T=C}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(Q,se){switch(Q){case 1:case 2:case 3:case 4:case 5:break;default:Q=3}var C=T;T=Q;try{return se()}finally{T=C}},e.unstable_scheduleCallback=function(Q,se,C){var F=e.unstable_now();switch(typeof C=="object"&&C!==null?(C=C.delay,C=typeof C=="number"&&0<C?F+C:F):C=F,Q){case 1:var te=-1;break;case 2:te=250;break;case 5:te=1073741823;break;case 4:te=1e4;break;default:te=5e3}return te=C+te,Q={id:p++,callback:se,priorityLevel:Q,startTime:C,expirationTime:te,sortIndex:-1},C>F?(Q.sortIndex=C,t(h,Q),n(d)===null&&Q===n(h)&&(_?(A(de),de=-1):_=!0,fe(z,C-F))):(Q.sortIndex=te,t(d,Q),x||y||(x=!0,Ie(W))),Q},e.unstable_shouldYield=ne,e.unstable_wrapCallback=function(Q){var se=T;return function(){var C=T;T=se;try{return Q.apply(this,arguments)}finally{T=C}}}})(Sd)),Sd}var L0;function AS(){return L0||(L0=1,vd.exports=SS()),vd.exports}var D0;function CS(){if(D0)return ln;D0=1;var e=lo(),t=AS();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]*$/,p={},E={};function T(i){return d.call(E,i)?!0:d.call(p,i)?!1:h.test(i)?E[i]=!0:(p[i]=!0,!1)}function y(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"||y(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 _(i,s,l,f,g,b,w){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=b,this.removeEmptyString=w}var S={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){S[i]=new _(i,0,!1,i,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(i){var s=i[0];S[s]=new _(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){S[i]=new _(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){S[i]=new _(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){S[i]=new _(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){S[i]=new _(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){S[i]=new _(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){S[i]=new _(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){S[i]=new _(i,5,!1,i.toLowerCase(),null,!1,!1)});var A=/[\-:]([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(A,O);S[s]=new _(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(A,O);S[s]=new _(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(A,O);S[s]=new _(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){S[i]=new _(i,1,!1,i.toLowerCase(),null,!1,!1)}),S.xlinkHref=new _("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){S[i]=new _(i,1,!1,i.toLowerCase(),null,!0,!0)});function R(i,s,l,f){var g=S.hasOwnProperty(s)?S[s]:null;(g!==null?g.type!==0:f||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(x(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 z=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,W=Symbol.for("react.element"),M=Symbol.for("react.portal"),K=Symbol.for("react.fragment"),de=Symbol.for("react.strict_mode"),xe=Symbol.for("react.profiler"),D=Symbol.for("react.provider"),ne=Symbol.for("react.context"),J=Symbol.for("react.forward_ref"),re=Symbol.for("react.suspense"),oe=Symbol.for("react.suspense_list"),be=Symbol.for("react.memo"),Ie=Symbol.for("react.lazy"),fe=Symbol.for("react.offscreen"),Q=Symbol.iterator;function se(i){return i===null||typeof i!="object"?null:(i=Q&&i[Q]||i["@@iterator"],typeof i=="function"?i:null)}var C=Object.assign,F;function te(i){if(F===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);F=s&&s[1]||""}return`
17
- `+F+i}var k=!1;function pe(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(X){var f=X}Reflect.construct(i,[],s)}else{try{s.call()}catch(X){f=X}i.call(s.prototype)}else{try{throw Error()}catch(X){f=X}i()}}catch(X){if(X&&f&&typeof X.stack=="string"){for(var g=X.stack.split(`
16
+ `+a)}}catch(u){}}throw r}})}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=vi(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&Tu.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&&(V.isFunction(o)?n.paramsSerializer={serialize:o}:Tu.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),Tu.assertOptions(n,{baseUrl:In.spelling("baseURL"),withXsrfToken:In.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&V.merge(a.common,a[n.method]);a&&V.forEach(["delete","get","head","post","put","patch","query","common"],x=>{delete a[x]}),n.headers=tn.concat(u,a);const c=[];let d=!0;this.interceptors.request.forEach(function(_){if(typeof _.runWhen=="function"&&_.runWhen(n)===!1)return;d=d&&_.synchronous;const S=n.transitional||ud;S&&S.legacyInterceptorReqResOrdering?c.unshift(_.fulfilled,_.rejected):c.push(_.fulfilled,_.rejected)});const h=[];this.interceptors.response.forEach(function(_){h.push(_.fulfilled,_.rejected)});let p,E=0,T;if(!d){const x=[x0.bind(this),void 0];for(x.unshift(...c),x.push(...h),T=x.length,p=Promise.resolve(n);E<T;)p=p.then(x[E++],x[E++]);return p}T=c.length;let y=n;for(;E<T;){const x=c[E++],_=c[E++];try{y=x(y)}catch(S){_.call(this,S);break}}try{p=x0.call(this,y)}catch(x){return Promise.reject(x)}for(E=0,T=h.length;E<T;)p=p.then(h[E++],h[E++]);return p}getUri(t){t=vi(this.defaults,t);const n=f0(t.baseURL,t.url,t.allowAbsoluteUrls);return o0(n,t.params,t.paramsSerializer)}};V.forEach(["delete","get","head","options"],function(t){Si.prototype[t]=function(n,r){return this.request(vi(r||{},{method:t,url:n,data:(r||{}).data}))}}),V.forEach(["post","put","patch","query"],function(t){function n(r){return function(a,u,c){return this.request(vi(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 Fv=class tw{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 Ns(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 tw(function(o){t=o}),cancel:t}}};function Bv(e){return function(n){return e.apply(null,n)}}function Uv(e){return V.isObject(e)&&e.isAxiosError===!0}const md={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(md).forEach(([e,t])=>{md[t]=e});function _0(e){const t=new Si(e),n=Vm(Si.prototype.request,t);return V.extend(n,Si.prototype,t,{allOwnKeys:!0}),V.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return _0(vi(e,o))},n}const xt=_0(ks);xt.Axios=Si,xt.CanceledError=Ns,xt.CancelToken=Fv,xt.isCancel=u0,xt.VERSION=fd,xt.toFormData=gu,xt.AxiosError=ke,xt.Cancel=xt.CanceledError,xt.all=function(t){return Promise.all(t)},xt.spread=Bv,xt.isAxiosError=Uv,xt.mergeConfig=vi,xt.AxiosHeaders=tn,xt.formToJSON=e=>a0(V.isHTMLForm(e)?new FormData(e):e),xt.getAdapter=T0.getAdapter,xt.HttpStatusCode=md,xt.default=xt;const{Axios:q9,AxiosError:Y9,CanceledError:W9,isCancel:G9,CancelToken:K9,VERSION:Q9,all:X9,Cancel:J9,isAxiosError:Z9,spread:eF,toFormData:tF,AxiosHeaders:nF,HttpStatusCode:rF,formToJSON:iF,getAdapter:oF,mergeConfig:sF,create:aF}=xt;class Hv{constructor(t,n,r,o=!1,a,u){Ze(this,"CIMULATE_API_HEADER","x-cimulate-api-key");Ze(this,"CIMULATE_SEARCH_API_HOST","search.cimulate");Ze(this,"CIMULATE_SEARCH_API_PATH","api/v1");Ze(this,"baseApiUrl");Ze(this,"headers",{});Ze(this,"fetchConfig",()=>$e(this,null,function*(){try{const t=yield xt.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}}));Ze(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}`),a&&(this.headers["x-cimulate-customer-id"]=a),u&&(this.headers["Tenant-ID"]=u),this.baseApiUrl=this._mapCopilotUrlToSearchUrl(t,o)}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}class zv{constructor(t,n,r,o=!1,a,u){Ze(this,"apiService");Ze(this,"config",null);Ze(this,"getConfig",()=>$e(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}}));Ze(this,"getPid",t=>this.getProductFieldValue(t,"pidCol"));Ze(this,"getName",t=>this.getProductFieldValue(t,"nameCol"));Ze(this,"getDescription",t=>this.getProductFieldValue(t,"description"));Ze(this,"getBrand",t=>this.getProductFieldValue(t,"productBrandCol"));Ze(this,"getPrice",t=>this.getProductFieldValue(t,"priceCol"));Ze(this,"getRelativePdp",t=>this.getProductFieldValue(t,"relativePdpCol"));Ze(this,"getPdp",t=>this.getProductFieldValue(t,"pdpCol"));Ze(this,"getImage",t=>this.getProductFieldValue(t,"imageCol"));Ze(this,"getProductHiddenFields",()=>{const t=this.getProductField("productHiddenFields");return Array.isArray(t)?t:[]});Ze(this,"getProductField",t=>this.config?this.config[t]:"");Ze(this,"getProductFieldValue",(t,n)=>{const r=this.getProductField(n);return r&&t[r]||""});this.apiService=new Hv(t,n,r,o,a,u)}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 jv{constructor(t=!1){Ze(this,"isDevelopment");Ze(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 $v={copilot:"Your Search Assistant",messaging:"Commerce Client"},v0=Z.createContext(null),Vv=({mode:e,logoUrl:t,headerText:n="Your Search Assistant",headerConfig:r,globalClassName:o="",entryMessage:a,openLinksInNewTab:u=!1,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,baseCatalogParams:p,searchPlaceholder:E,searchButtonLabel:T,searchConfig:y,componentConfig:x,conversationHistory:_,resetConversationMessage:S="",apiKey:A,apiToken:O,baseUrl:R,customerId:H,tenantId:W,theme:D,isDevelopment:K,__features:fe,children:Te})=>{const z=e==="messaging",X=Z.useMemo(()=>z?{config:null}:new zv(R,A,O,K,H,W),[z,R,A,O,K,H,W]),se=Z.useMemo(()=>new jv(K),[K]);Z.useEffect(()=>{z||!X||X.config||X.getConfig()},[X,z]);const ee=Z.useMemo(()=>n_(D),[D]),re=Z.useMemo(()=>{const he=(y==null?void 0:y.placeholder)||E,Q=(y==null?void 0:y.buttonLabel)||T;let oe="icon";return y!=null&&y.buttonType?oe=y.buttonType:T&&(oe="text"),ae(B({},y||{}),{placeholder:he,buttonLabel:Q,buttonType:oe})},[y,E,T]),de=Z.useMemo(()=>ae(B({},r||{}),{logoUrl:t||(r==null?void 0:r.logoUrl),headerText:n||$v[e!=null?e:"copilot"]}),[r,t,n,e]),Oe=Z.useMemo(()=>({configModule:X,mode:e!=null?e:"copilot",headerConfig:de,entryMessage:a,globalClassName:o,openLinksInNewTab:u,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,baseCatalogParams:p,themeVariables:ee,logger:se,searchConfig:re,enableMinimize:!!(x!=null&&x.enableMinimize),resetConversationMessage:S,conversationHistory:{sinceHours:typeof(_==null?void 0:_.sinceHours)=="number"?_.sinceHours:1,limit:_==null?void 0:_.limit},features:fe}),[X,e,de,a,o,h,p,c,d,u,re,x,S,se,ee,_,fe]);return v.jsx(v0.Provider,{value:Oe,children:Te})},At=()=>{const e=Z.useContext(v0);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e},qv=["markdown","product_carousel","suggestions","cart"],xu=-1;function Yv(e){if(!e||!e.trim())return null;try{const t=JSON.parse(e);if(t&&typeof t=="object"&&typeof t.type=="string"&&typeof t.index=="number")return qv.includes(t.type)?t:null}catch(t){}return{type:"markdown",index:xu,data:{content:e}}}function Wv(e,t){if(t.index===xu){const o=e[e.length-1];if(o&&o.type==="markdown"&&o.index===xu&&t.type==="markdown"){const a={type:"markdown",index:xu,data:{content:o.data.content+t.data.content}};return[...e.slice(0,-1),a]}return[...e,t]}const n=e.findIndex(o=>o.index===t.index);return[...n>=0?e.map((o,a)=>a===n?t:o):[...e,t]].sort((o,a)=>o.index-a.index)}const S0={connectionStatus:"disconnected",loading:!0,conversationId:null,messages:[],streamingBlocks:[],isAgentTyping:!1,progressMessage:"",routingResult:null,error:null,sessionExpired:!1};function Gv(e,t){switch(t.type){case"SET_CONNECTION_STATUS":return B(ae(B({},e),{connectionStatus:t.status}),t.status==="connected"||t.status==="connecting"?{error:null}:{});case"SET_LOADING":return ae(B({},e),{loading:t.isLoading});case"SET_CONVERSATION_ID":return ae(B({},e),{conversationId:t.id});case"ADD_MESSAGE":return ae(B({},e),{messages:[...e.messages,ae(B({},t.message),{type:"ADD_MESSAGE"})]});case"APPEND_STREAMING_TOKEN":{const n=Yv(t.token);return n?ae(B({},e),{streamingBlocks:Wv(e.streamingBlocks,n)}):e}case"FLUSH_STREAMING":return ae(B({},e),{messages:[...e.messages,ae(B({},t.message),{type:"FLUSH_STREAMING"})],streamingBlocks:[],isAgentTyping:!1,loading:!1,progressMessage:""});case"SET_AGENT_TYPING":return ae(B({},e),{isAgentTyping:t.isTyping,loading:t.isTyping});case"SET_PROGRESS_MESSAGE":return ae(B({},e),{progressMessage:t.message});case"SET_ROUTING_RESULT":return ae(B({},e),{routingResult:t.result});case"SET_ERROR":return ae(B({},e),{error:t.error,loading:!1,progressMessage:""});case"LOAD_HISTORY":return ae(B({},e),{messages:t.messages,loading:!1});case"SET_SESSION_EXPIRED":return ae(B({},e),{sessionExpired:t.expired});case"RESET":return ae(B({},S0),{connectionStatus:e.connectionStatus,loading:!0});default:return e}}const A0=Z.createContext({connectionStatus:"disconnected",isConnected:!1,isAgentTyping:!1,conversationId:null,messages:[],streamingBlocks:[],progressMessage:"",loading:!0,error:null,sessionExpired:!1,sendMessage:()=>{},resetConversation:()=>{}});function gd(e,t){return`cim_af_conv_${e}_${t}`}function Ed(e,t){return Date.now()-e>t}function Kv(e,t,n){try{const r=gd(e,t),o=sessionStorage.getItem(r);if(!o)return null;const a=JSON.parse(o);if(!a||typeof a!="object"||!("conversationId"in a)||!("storedAt"in a))return null;const u=a;return typeof u.conversationId!="string"||!u.conversationId?null:typeof u.storedAt!="number"||Ed(u.storedAt,n)?(sessionStorage.removeItem(r),null):u}catch(r){return null}}function Os(e,t,n){try{const r=gd(e,t),o={conversationId:n,storedAt:Date.now()};sessionStorage.setItem(r,JSON.stringify(o))}catch(r){}}function wu(e,t){try{const n=gd(e,t);sessionStorage.removeItem(n)}catch(n){}}function yd(e,t){return`cim_af_ct_${e}_${t}`}function C0(e,t,n){try{const r=yd(e,t),o=sessionStorage.getItem(r);if(!o)return null;const a=JSON.parse(o);if(!a||typeof a!="object"||!("accessToken"in a)||!("lastEventId"in a)||!("storedAt"in a))return null;const u=a;return typeof u.accessToken!="string"||!u.accessToken||typeof u.lastEventId!="string"||!u.lastEventId?null:typeof u.storedAt!="number"||Date.now()-u.storedAt>n?(sessionStorage.removeItem(r),null):u}catch(r){return null}}function Qv(e,t,n,r){try{const o=yd(e,t),a={accessToken:n,lastEventId:r,storedAt:Date.now()};sessionStorage.setItem(o,JSON.stringify(a))}catch(o){}}function Xv(e,t){try{const n=yd(e,t);sessionStorage.removeItem(n)}catch(n){}}function Jv(e,t){return`cim_af_conv_${e}_${t}`}function Zv(e,t){try{if(typeof BroadcastChannel=="undefined")return null;const n=Jv(e,t);return new BroadcastChannel(n)}catch(n){return null}}function eS(e,t=500){return e?new Promise(n=>{let r=!1;const o=setTimeout(()=>{r||(r=!0,e.removeEventListener("message",a),n(null))},t);function a(u){var c;r||((c=u.data)==null?void 0:c.type)==="conversation_response"&&(r=!0,clearTimeout(o),e.removeEventListener("message",a),n({conversationId:u.data.conversationId,storedAt:u.data.storedAt,continuationToken:u.data.continuationToken,lastEventId:u.data.lastEventId}))}e.addEventListener("message",a);try{e.postMessage({type:"request_conversation"})}catch(u){r||(r=!0,clearTimeout(o),e.removeEventListener("message",a),n(null))}}):Promise.resolve(null)}function tS(e,t,n){if(!e)return()=>{};function r(o){var a;if((a=o.data)!=null&&a.type)switch(o.data.type){case"request_conversation":{const u=t();if(u!=null&&u.conversationId)try{e.postMessage({type:"conversation_response",conversationId:u.conversationId,storedAt:Date.now(),continuationToken:u.continuationToken,lastEventId:u.lastEventId})}catch(c){}break}case"conversation_cleared":{n==null||n();break}}}return e.addEventListener("message",r),()=>{e.removeEventListener("message",r)}}function nS(e){if(e)try{e.postMessage({type:"conversation_cleared"})}catch(t){}}function rS(e){if(e)try{e.close()}catch(t){}}function iS(e){switch(e){case"EndUser":case"Customer":return"user";case"Agent":case"Chatbot":return"agent";default:return"system"}}function oS(e){if(!e)return{};if(typeof e=="string")try{return JSON.parse(e)}catch(t){return{}}return e}function k0(e,...t){let n=e;for(const r of t){if(n==null||typeof n!="object")return"";n=n[r]}return typeof n=="string"?n:""}function sS(e){if(e.entryType!=="Message")return null;const n=oS(e.entryPayload).abstractMessage;if(!n)return null;const r=k0(n,"staticContent","text")||k0(n,"content","text")||"";if(!r)return null;const o=iS(e.sender.role);return{id:e.identifier,role:o,content:r,timestamp:new Date(e.transcriptedTimestamp).toISOString(),sender:{role:e.sender.role,name:e.senderDisplayName}}}function aS(e){const t=[];for(const n of e){const r=sS(n);r&&t.push(r)}return t}function uS(e){const{orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:o}=e,a=Z.useRef(null),u=Z.useRef(null),c=Z.useRef(null),d=o.sinceHours*60*60*1e3,h=Z.useCallback(()=>(c.current||(c.current=eS(a.current)),c.current),[]);Z.useEffect(()=>{const S=Zv(t,n);a.current=S,c.current=null;const A=tS(S,()=>{const O=u.current;if(!O)return null;const R=C0(t,n,d);return{conversationId:O,continuationToken:R==null?void 0:R.accessToken,lastEventId:R==null?void 0:R.lastEventId}},()=>{wu(t,n),u.current=null});return()=>{A(),rS(S),a.current=null}},[t,n,d]);const p=Z.useCallback(S=>$e(null,null,function*(){let A=Kv(t,n,d);if(!A){const O=yield h();O&&!Ed(O.storedAt,d)&&(A=O)}if(!A){const O=yield S.createConversation(r);return Os(t,n,O),u.current=O,{conversationId:O,restoredMessages:[],resumed:!1}}try{const O=Date.now()-d,H=(yield S.listConversations({conversationId:A.conversationId,startTimestamp:O})).conversations.find(D=>D.conversationId===A.conversationId&&!D.isConversationClosed);if(!H){wu(t,n);const D=yield S.createConversation(r);return Os(t,n,D),u.current=D,{conversationId:D,restoredMessages:[],resumed:!1}}S.resumeConversation(H.conversationId),u.current=H.conversationId,Os(t,n,H.conversationId);let W=[];try{const D=yield S.listConversationEntries(H.conversationId,{limit:o.limit,startTimestamp:O,direction:"FromStart"});W=aS(D.conversationEntries)}catch(D){}return{conversationId:H.conversationId,restoredMessages:W,resumed:!0}}catch(O){wu(t,n);const R=yield S.createConversation(r);return Os(t,n,R),u.current=R,{conversationId:R,restoredMessages:[],resumed:!1}}}),[t,n,r,o,d,h]),E=Z.useCallback(S=>{Os(t,n,S),u.current=S},[t,n]),T=Z.useCallback(()=>{wu(t,n),Xv(t,n),nS(a.current),u.current=null},[t,n]),y=Z.useCallback(()=>{const S=C0(t,n,d);return S?{continuationToken:S.accessToken,lastEventId:S.lastEventId}:null},[t,n,d]),x=Z.useCallback(()=>$e(null,null,function*(){const S=yield h();return!(S!=null&&S.continuationToken)||Ed(S.storedAt,d)?null:{continuationToken:S.continuationToken,lastEventId:S.lastEventId}}),[d,h]),_=Z.useCallback(S=>$e(null,null,function*(){try{const{accessToken:A,lastEventId:O}=yield S.generateContinuationToken();Qv(t,n,A,O)}catch(A){}}),[t,n]);return{initializeConversation:p,persistConversationId:E,clearPersistedConversation:T,getStoredConnectOptions:y,getPeerConnectOptions:x,persistContinuationToken:_}}const lS="Your session ended due to inactivity. Starting a new session…";function cS(e){if(!e||typeof e!="object")return!1;const t=e;return t.type==="auth"?!0:t.type==="api"&&(t.statusCode===401||t.statusCode===403)}const N0=({scrt2Url:e,orgId:t,esDeveloperName:n,routingAttributes:r,capabilitiesVersion:o,enableLogging:a=!1,onConnect:u,onMessage:c,onError:d,children:h})=>{const{logger:p,conversationHistory:E}=At(),[T,y]=Z.useReducer(Gv,S0),x=uS({orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:E}),_=Z.useRef(null),S=Z.useRef(c),A=Z.useRef(d),O=Z.useRef(u),R=Z.useRef(!1),H=Z.useRef(!1),W=Z.useRef(0);S.current=c,A.current=d,O.current=u,Z.useEffect(()=>{const X=new t_({baseURL:e,orgId:t,esDeveloperName:n,options:B({enableLogging:a},o?{capabilitiesVersion:o}:{})});return _.current=X,X.on("connected",()=>{var ee;y({type:"SET_CONNECTION_STATUS",status:"connected"}),(ee=O.current)==null||ee.call(O)}),X.on("disconnected",()=>{y({type:"SET_CONNECTION_STATUS",status:"disconnected"})}),X.on("reconnecting",()=>{y({type:"SET_CONNECTION_STATUS",status:"reconnecting"})}),X.on("message",ee=>{var de;const re={id:ee.messageId||crypto.randomUUID(),role:"agent",content:ee.content,timestamp:ee.timestamp,sender:ee.sender,raw:ee};p==null||p.log("🦜 MessagingProvider message received (FLUSH_STREAMING)",{messageId:re.id,tokensBeforeFlush:W.current,streamedFinalOnly:W.current===0}),W.current=0,y({type:"FLUSH_STREAMING",message:re}),(de=S.current)==null||de.call(S,re)}),X.on("streaming_token",ee=>{W.current+=1,y({type:"APPEND_STREAMING_TOKEN",token:ee.token})}),X.on("typing_started",()=>{y({type:"SET_AGENT_TYPING",isTyping:!0})}),X.on("typing_stopped",()=>{y({type:"SET_AGENT_TYPING",isTyping:!1})}),X.on("progress_indicator",ee=>{y({type:"SET_PROGRESS_MESSAGE",message:ee.message})}),X.on("routing_result",ee=>{var re;if(y({type:"SET_ROUTING_RESULT",result:ee}),!ee.isSuccessful){const de=`Routing failed: ${ee.failureType||"unknown"}`;y({type:"SET_ERROR",error:de}),(re=A.current)==null||re.call(A,de)}}),X.on("participant_changed",ee=>{if(ee.participant.name==="Automated Process")return;const re={id:crypto.randomUUID(),role:"system",content:ee.action==="add"?`${ee.participant.name||"Agent"} joined the conversation`:`${ee.participant.name||"Agent"} left the conversation`,timestamp:new Date().toISOString()};p==null||p.log("🦜 MessagingProvider participant_changed event received",{event:ee}),y({type:"ADD_MESSAGE",message:re})}),X.on("conversation_closed",()=>{const ee={id:crypto.randomUUID(),role:"system",content:"Conversation reset",timestamp:new Date().toISOString()};y({type:"ADD_MESSAGE",message:ee}),y({type:"SET_CONVERSATION_ID",id:null}),x.clearPersistedConversation()}),X.on("error",ee=>{var re;if(p==null||p.log("🦜 MessagingProvider ERROR event received",{event:ee}),ee.code==="SESSION_EXPIRED"){H.current=!0,y({type:"SET_SESSION_EXPIRED",expired:!0}),y({type:"SET_CONNECTION_STATUS",status:"disconnected"}),y({type:"SET_LOADING",isLoading:!1});return}y({type:"SET_ERROR",error:ee.message}),ee.recoverable||y({type:"SET_CONNECTION_STATUS",status:"error"}),(re=A.current)==null||re.call(A,ee.message)}),y({type:"SET_CONNECTION_STATUS",status:"connecting"}),$e(null,null,function*(){let ee=x.getStoredConnectOptions(),re=!1;ee||(ee=yield x.getPeerConnectOptions(),re=!!ee);try{yield X.connect(ee!=null?ee:void 0)}catch(Oe){if(ee)p==null||p.log("Continuation token failed, falling back to fresh connect"),re||x.clearPersistedConversation(),yield X.connect();else throw Oe}yield x.persistContinuationToken(X);const de=yield x.initializeConversation(X);y({type:"SET_CONVERSATION_ID",id:de.conversationId}),de.resumed&&de.restoredMessages.length>0&&y({type:"LOAD_HISTORY",messages:de.restoredMessages})}).catch(ee=>{var re;y({type:"SET_CONNECTION_STATUS",status:"error"}),y({type:"SET_ERROR",error:ee.message}),(re=A.current)==null||re.call(A,ee.message)}),()=>{X.disconnect(),X.off(),_.current=null}},[e,t,n,o]),Z.useEffect(()=>{const X=()=>{document.visibilityState==="visible"&&_.current&&!H.current&&_.current.reconnect()};return document.addEventListener("visibilitychange",X),()=>{document.removeEventListener("visibilitychange",X)}},[]);const D=Z.useCallback(X=>$e(null,null,function*(){var ee;const se=_.current;if(!(!se||R.current)){R.current=!0,H.current=!1,y({type:"SET_SESSION_EXPIRED",expired:!1}),y({type:"ADD_MESSAGE",message:{id:crypto.randomUUID(),role:"system",content:lS,timestamp:new Date().toISOString()}}),x.clearPersistedConversation(),y({type:"SET_CONNECTION_STATUS",status:"connecting"});try{se.disconnect(),yield se.connect(),yield x.persistContinuationToken(se);const re=yield se.createConversation(r);y({type:"SET_CONVERSATION_ID",id:re}),y({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(re),X&&(y({type:"SET_LOADING",isLoading:!0}),y({type:"SET_PROGRESS_MESSAGE",message:""}),yield se.sendMessage(X))}catch(re){const de=re instanceof Error?re.message:String(re);y({type:"SET_ERROR",error:de}),y({type:"SET_CONNECTION_STATUS",status:"error"}),(ee=A.current)==null||ee.call(A,de)}finally{R.current=!1}}}),[r,x]),K=Z.useRef(D);K.current=D;const fe=Z.useCallback(X=>{if(!X.trim())return;const se=_.current;if(!se)return;const ee={id:crypto.randomUUID(),role:"user",content:X,timestamp:new Date().toISOString()};if(y({type:"ADD_MESSAGE",message:ee}),y({type:"SET_LOADING",isLoading:!0}),y({type:"SET_PROGRESS_MESSAGE",message:""}),H.current){K.current(X);return}se.sendMessage(X).catch(re=>{var de;if(cS(re)){K.current(X);return}y({type:"SET_ERROR",error:re.message}),(de=A.current)==null||de.call(A,re.message)})},[]),Te=Z.useCallback(()=>{const X=_.current;X&&(H.current=!1,x.clearPersistedConversation(),y({type:"RESET"}),y({type:"SET_CONNECTION_STATUS",status:"connecting"}),X.endConversation().then(()=>(X.disconnect(),X.connect())).then(()=>$e(null,null,function*(){return yield x.persistContinuationToken(X),X.createConversation(r)})).then(se=>{y({type:"SET_CONVERSATION_ID",id:se}),y({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(se)}).catch(se=>{var ee;y({type:"SET_ERROR",error:se.message}),y({type:"SET_CONNECTION_STATUS",status:"error"}),(ee=A.current)==null||ee.call(A,se.message)}))},[r,x]),z=Z.useMemo(()=>({connectionStatus:T.connectionStatus,isConnected:T.connectionStatus==="connected"&&T.conversationId!==null,isAgentTyping:T.isAgentTyping,conversationId:T.conversationId,messages:T.messages,streamingBlocks:T.streamingBlocks,progressMessage:T.progressMessage,error:T.error,loading:T.loading,sessionExpired:T.sessionExpired,sendMessage:fe,resetConversation:Te}),[T,fe,Te]);return v.jsx(A0.Provider,{value:z,children:h})};function dS(){var e=Z.useRef(!0);return e.current?(e.current=!1,!0):e.current}function fS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.addEventListener&&e.addEventListener.apply(e,t)}function hS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.removeEventListener&&e.removeEventListener.apply(e,t)}var bd=typeof window!="undefined",_u=function(e){Z.useEffect(e,[])},pS=function(e){var t=Z.useRef(e);t.current=e,_u(function(){return function(){return t.current()}})},mS=function(e){var t=Z.useRef(0),n=Z.useState(e),r=n[0],o=n[1],a=Z.useCallback(function(u){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(u)})},[]);return pS(function(){cancelAnimationFrame(t.current)}),[r,a]},gS=function(e,t){return e===t};function ES(e,t){t===void 0&&(t=gS);var n=Z.useRef(),r=Z.useRef(e),o=dS();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var yS=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=mS({width:bd?window.innerWidth:r,height:bd?window.innerHeight:a}),d=c[0],h=c[1];return Z.useEffect(function(){if(bd){var p=function(){var E=window.innerWidth,T=window.innerHeight;h({width:E,height:T}),u&&u(E,T)};return fS(window,"resize",p),function(){hS(window,"resize",p)}}},[]),d};const Td="cimulate:ui-state-update",bS=e=>{window.addEventListener(Td,e)},TS=e=>{window.removeEventListener(Td,e)},xS=(e,t)=>{const n=new CustomEvent(Td,{detail:{property:e,value:t}});window.dispatchEvent(n)},O0=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},Ci=e=>{const t=tt.statusProxy.isOpen,n=typeof e=="boolean"?e:!t;tt.statusProxy.isOpen=n,n&&(tt.statusProxy.isMinimized=!1)},vu=e=>{const t=tt.statusProxy.isMinimized,n=typeof e=="boolean"?e:!t;tt.statusProxy.isMinimized=n,n&&(tt.statusProxy.isOpen=!1)},xd=e=>{tt.modalProxy.isFullscreen=e},Su=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"},wd=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},wS=e=>{const t=tt.dialogProxy.isFullHeight,n=typeof e=="boolean"?e:!t;tt.dialogProxy.isFullHeight=n};class _S{constructor(){Ze(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}});Ze(this,"connectedProxy");Ze(this,"modeProxy");Ze(this,"entryTypeProxy");Ze(this,"statusProxy");Ze(this,"dialogProxy");Ze(this,"modalProxy",{isFullscreen:!1});Ze(this,"_fullGet",(t,n)=>Reflect.get(t,n));Ze(this,"_fullSet",(t,n,r)=>{if(!(n in t))throw new Error(`Property ${n} does not exist on UIState`);return xS(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 _S,I0=Z.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}),vS=({entryType:e,componentConfig:t,componentType:n,children:r})=>{const[o,a]=Z.useState(e!=null?e:tt.entryTypeProxy.entryType),[u,c]=Z.useState(tt.modeProxy.mode),[d,h]=Z.useState({type:n||tt.statusProxy.type,isOpen:tt.statusProxy.isOpen,isMinimized:tt.statusProxy.isMinimized}),[p,E]=Z.useState(tt.dialogProxy.position),[T,y]=Z.useState(tt.dialogProxy.isFullHeight),[x,_]=Z.useState(tt.dialogProxy.width),[S,A]=Z.useState(tt.modalProxy.isFullscreen),O=ES(d.type);Z.useEffect(()=>{const H=W=>{const{property:D,value:K}=W.detail||{};if(!(!D||K===void 0)){if(D==="mode"){c(K);return}if(D==="entryType"){a(K);return}if(D==="isMinimized"){h(fe=>ae(B({},fe),{isMinimized:K}));return}if(D==="isOpen"){h(fe=>ae(B({},fe),{isOpen:K}));return}if(D==="type"){h(fe=>ae(B({},fe),{type:K}));return}if(D==="position"){E(K);return}if(D==="isFullHeight"){y(K);return}if(D==="width"){_(K);return}if(D==="isFullscreen"){A(K);return}}};return bS(H),()=>{TS(H)}},[]),_u(()=>{e&&O0(e)}),_u(()=>{const H=n||(t==null?void 0:t.type);H&&Su(H),t&&"isOpen"in t&&Ci(!!t.isOpen),t&&"isMinimized"in t&&vu(!!t.isMinimized)}),_u(()=>{if(!(t!=null&&t.options))return;const{dialogPosition:H}=t.options;H&&wd(H),"dialogFullHeight"in t.options&&wS(!!t.options.dialogFullHeight),"dialogWidth"in t.options&&t.options.dialogWidth&&_(t.options.dialogWidth),"isModalFullscreen"in t.options&&xd(!!t.options.isModalFullscreen)});const R=Z.useMemo(()=>({mode:u,entryType:o,status:d,previousComponentType:O||"dialog",dialogPosition:p,isDialogFullHeight:T,dialogWidth:x,isModalFullscreen:S}),[u,o,d,O,p,T,x,S]);return v.jsx(I0.Provider,{value:R,children:r})},R0=({mode:e,apiKey:t,apiToken:n,baseUrl:r,logoUrl:o,headerText:a,headerConfig:u,theme:c,openLinksInNewTab:d,globalClassName:h,isDevelopment:p=!1,componentType:E,componentConfig:T,entryType:y,entryMessage:x,disclaimerText:_,disclaimerMarkdown:S,clientContext:A,searchPlaceholder:O,searchButtonLabel:R,searchConfig:H,resetConversationMessage:W,conversationHistory:D,messagingConfig:K,__features:fe,children:Te})=>v.jsx(Vv,{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:H,componentConfig:T,clientContext:A,disclaimerMarkdown:S,disclaimerText:_,resetConversationMessage:W,conversationHistory:D,isDevelopment:p,__features:fe,children:v.jsx(vS,{entryType:y,componentConfig:T,componentType:E,children:v.jsx(N0,{scrt2Url:(K==null?void 0:K.scrt2Url)||"",orgId:(K==null?void 0:K.orgId)||"",esDeveloperName:(K==null?void 0:K.esDeveloperName)||"",routingAttributes:(K==null?void 0:K.routingAttributes)||{},capabilitiesVersion:K==null?void 0:K.capabilitiesVersion,enableLogging:p,children:Te})})}),ki=()=>{const e=Z.useContext(I0);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};var _d={exports:{}},ln={},vd={exports:{}},Sd={};var P0;function SS(){return P0||(P0=1,(function(e){function t(Q,oe){var C=Q.length;Q.push(oe);e:for(;0<C;){var M=C-1>>>1,ne=Q[M];if(0<o(ne,oe))Q[M]=oe,Q[C]=ne,C=M;else break e}}function n(Q){return Q.length===0?null:Q[0]}function r(Q){if(Q.length===0)return null;var oe=Q[0],C=Q.pop();if(C!==oe){Q[0]=C;e:for(var M=0,ne=Q.length,k=ne>>>1;M<k;){var me=2*(M+1)-1,Se=Q[me],Ae=me+1,Be=Q[Ae];if(0>o(Se,C))Ae<ne&&0>o(Be,Se)?(Q[M]=Be,Q[Ae]=C,M=Ae):(Q[M]=Se,Q[me]=C,M=me);else if(Ae<ne&&0>o(Be,C))Q[M]=Be,Q[Ae]=C,M=Ae;else break e}}return oe}function o(Q,oe){var C=Q.sortIndex-oe.sortIndex;return C!==0?C:Q.id-oe.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=[],p=1,E=null,T=3,y=!1,x=!1,_=!1,S=typeof setTimeout=="function"?setTimeout:null,A=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(Q){for(var oe=n(h);oe!==null;){if(oe.callback===null)r(h);else if(oe.startTime<=Q)r(h),oe.sortIndex=oe.expirationTime,t(d,oe);else break;oe=n(h)}}function H(Q){if(_=!1,R(Q),!x)if(n(d)!==null)x=!0,Oe(W);else{var oe=n(h);oe!==null&&he(H,oe.startTime-Q)}}function W(Q,oe){x=!1,_&&(_=!1,A(fe),fe=-1),y=!0;var C=T;try{for(R(oe),E=n(d);E!==null&&(!(E.expirationTime>oe)||Q&&!X());){var M=E.callback;if(typeof M=="function"){E.callback=null,T=E.priorityLevel;var ne=M(E.expirationTime<=oe);oe=e.unstable_now(),typeof ne=="function"?E.callback=ne:E===n(d)&&r(d),R(oe)}else r(d);E=n(d)}if(E!==null)var k=!0;else{var me=n(h);me!==null&&he(H,me.startTime-oe),k=!1}return k}finally{E=null,T=C,y=!1}}var D=!1,K=null,fe=-1,Te=5,z=-1;function X(){return!(e.unstable_now()-z<Te)}function se(){if(K!==null){var Q=e.unstable_now();z=Q;var oe=!0;try{oe=K(!0,Q)}finally{oe?ee():(D=!1,K=null)}}else D=!1}var ee;if(typeof O=="function")ee=function(){O(se)};else if(typeof MessageChannel!="undefined"){var re=new MessageChannel,de=re.port2;re.port1.onmessage=se,ee=function(){de.postMessage(null)}}else ee=function(){S(se,0)};function Oe(Q){K=Q,D||(D=!0,ee())}function he(Q,oe){fe=S(function(){Q(e.unstable_now())},oe)}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(Q){Q.callback=null},e.unstable_continueExecution=function(){x||y||(x=!0,Oe(W))},e.unstable_forceFrameRate=function(Q){0>Q||125<Q?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Te=0<Q?Math.floor(1e3/Q):5},e.unstable_getCurrentPriorityLevel=function(){return T},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(Q){switch(T){case 1:case 2:case 3:var oe=3;break;default:oe=T}var C=T;T=oe;try{return Q()}finally{T=C}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(Q,oe){switch(Q){case 1:case 2:case 3:case 4:case 5:break;default:Q=3}var C=T;T=Q;try{return oe()}finally{T=C}},e.unstable_scheduleCallback=function(Q,oe,C){var M=e.unstable_now();switch(typeof C=="object"&&C!==null?(C=C.delay,C=typeof C=="number"&&0<C?M+C:M):C=M,Q){case 1:var ne=-1;break;case 2:ne=250;break;case 5:ne=1073741823;break;case 4:ne=1e4;break;default:ne=5e3}return ne=C+ne,Q={id:p++,callback:oe,priorityLevel:Q,startTime:C,expirationTime:ne,sortIndex:-1},C>M?(Q.sortIndex=C,t(h,Q),n(d)===null&&Q===n(h)&&(_?(A(fe),fe=-1):_=!0,he(H,C-M))):(Q.sortIndex=ne,t(d,Q),x||y||(x=!0,Oe(W))),Q},e.unstable_shouldYield=X,e.unstable_wrapCallback=function(Q){var oe=T;return function(){var C=T;T=oe;try{return Q.apply(this,arguments)}finally{T=C}}}})(Sd)),Sd}var L0;function AS(){return L0||(L0=1,vd.exports=SS()),vd.exports}var D0;function CS(){if(D0)return ln;D0=1;var e=lo(),t=AS();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]*$/,p={},E={};function T(i){return d.call(E,i)?!0:d.call(p,i)?!1:h.test(i)?E[i]=!0:(p[i]=!0,!1)}function y(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"||y(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 _(i,s,l,f,g,b,w){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=b,this.removeEmptyString=w}var S={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(i){S[i]=new _(i,0,!1,i,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(i){var s=i[0];S[s]=new _(s,1,!1,i[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(i){S[i]=new _(i,2,!1,i.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(i){S[i]=new _(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){S[i]=new _(i,3,!1,i.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(i){S[i]=new _(i,3,!0,i,null,!1,!1)}),["capture","download"].forEach(function(i){S[i]=new _(i,4,!1,i,null,!1,!1)}),["cols","rows","size","span"].forEach(function(i){S[i]=new _(i,6,!1,i,null,!1,!1)}),["rowSpan","start"].forEach(function(i){S[i]=new _(i,5,!1,i.toLowerCase(),null,!1,!1)});var A=/[\-:]([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(A,O);S[s]=new _(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(A,O);S[s]=new _(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(A,O);S[s]=new _(s,1,!1,i,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(i){S[i]=new _(i,1,!1,i.toLowerCase(),null,!1,!1)}),S.xlinkHref=new _("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(i){S[i]=new _(i,1,!1,i.toLowerCase(),null,!0,!0)});function R(i,s,l,f){var g=S.hasOwnProperty(s)?S[s]:null;(g!==null?g.type!==0:f||!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(x(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 H=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,W=Symbol.for("react.element"),D=Symbol.for("react.portal"),K=Symbol.for("react.fragment"),fe=Symbol.for("react.strict_mode"),Te=Symbol.for("react.profiler"),z=Symbol.for("react.provider"),X=Symbol.for("react.context"),se=Symbol.for("react.forward_ref"),ee=Symbol.for("react.suspense"),re=Symbol.for("react.suspense_list"),de=Symbol.for("react.memo"),Oe=Symbol.for("react.lazy"),he=Symbol.for("react.offscreen"),Q=Symbol.iterator;function oe(i){return i===null||typeof i!="object"?null:(i=Q&&i[Q]||i["@@iterator"],typeof i=="function"?i:null)}var C=Object.assign,M;function ne(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 me(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(J){var f=J}Reflect.construct(i,[],s)}else{try{s.call()}catch(J){f=J}i.call(s.prototype)}else{try{throw Error()}catch(J){f=J}i()}}catch(J){if(J&&f&&typeof J.stack=="string"){for(var g=J.stack.split(`
18
18
  `),b=f.stack.split(`
19
- `),w=g.length-1,P=b.length-1;1<=w&&0<=P&&g[w]!==b[P];)P--;for(;1<=w&&0<=P;w--,P--)if(g[w]!==b[P]){if(w!==1||P!==1)do if(w--,P--,0>P||g[w]!==b[P]){var B=`
20
- `+g[w].replace(" at new "," at ");return i.displayName&&B.includes("<anonymous>")&&(B=B.replace("<anonymous>",i.displayName)),B}while(1<=w&&0<=P);break}}}finally{k=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?te(i):""}function Se(i){switch(i.tag){case 5:return te(i.type);case 16:return te("Lazy");case 13:return te("Suspense");case 19:return te("SuspenseList");case 0:case 2:case 15:return i=pe(i.type,!1),i;case 11:return i=pe(i.type.render,!1),i;case 1:return i=pe(i.type,!0),i;default:return""}}function Ae(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 K:return"Fragment";case M:return"Portal";case xe:return"Profiler";case de:return"StrictMode";case re:return"Suspense";case oe:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case ne:return(i.displayName||"Context")+".Consumer";case D:return(i._context.displayName||"Context")+".Provider";case J:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case be:return s=i.displayName||null,s!==null?s:Ae(i.type)||"Memo";case Ie:s=i._payload,i=i._init;try{return Ae(i(s))}catch(l){}}return null}function Be(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 Ae(s);case 8:return s===de?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function ve(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function qe(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function ut(i){var s=qe(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,b=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return g.call(this)},set:function(w){f=""+w,b.call(this,w)}}),Object.defineProperty(i,s,{enumerable:l.enumerable}),{getValue:function(){return f},setValue:function(w){f=""+w},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function pn(i){i._valueTracker||(i._valueTracker=ut(i))}function Wi(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var l=s.getValue(),f="";return i&&(f=qe(i)?i.checked?"true":"false":i.value),i=f,i!==l?(s.setValue(i),!0):!1}function Zr(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 C({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function Ea(i,s){var l=s.defaultValue==null?"":s.defaultValue,f=s.checked!=null?s.checked:s.defaultChecked;l=ve(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 ya(i,s){s=s.checked,s!=null&&R(i,"checked",s,!1)}function Go(i,s){ya(i,s);var l=ve(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")?Ko(i,s.type,l):s.hasOwnProperty("defaultValue")&&Ko(i,s.type,ve(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function Al(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 Ko(i,s,l){(s!=="number"||Zr(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var ei=Array.isArray;function ti(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=""+ve(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 ba(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return C({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function Cl(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(ei(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:ve(l)}}function kl(i,s){var l=ve(s.value),f=ve(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 Nl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function ie(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 Te(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?ie(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Ue,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(Ue=Ue||document.createElement("div"),Ue.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=Ue.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function Xe(i,s){if(s){var l=i.firstChild;if(l&&l===i.lastChild&&l.nodeType===3){l.nodeValue=s;return}}i.textContent=s}var jt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Rr=["Webkit","ms","Moz","O"];Object.keys(jt).forEach(function(i){Rr.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),jt[s]=jt[i]})});function Mn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||jt.hasOwnProperty(i)&&jt[i]?(""+s).trim():s+"px"}function ni(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 Gi=C({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 $t(i,s){if(s){if(Gi[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 br(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 Sn=null;function Dh(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var Mh=null,Qo=null,Xo=null;function pT(i){if(i=za(i)){if(typeof Mh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=Jl(s),Mh(i.stateNode,i.type,s))}}function mT(i){Qo?Xo?Xo.push(i):Xo=[i]:Qo=i}function gT(){if(Qo){var i=Qo,s=Xo;if(Xo=Qo=null,pT(i),s)for(i=0;i<s.length;i++)pT(s[i])}}function ET(i,s){return i(s)}function yT(){}var Fh=!1;function bT(i,s,l){if(Fh)return i(s,l);Fh=!0;try{return ET(i,s,l)}finally{Fh=!1,(Qo!==null||Xo!==null)&&(yT(),gT())}}function Ta(i,s){var l=i.stateNode;if(l===null)return null;var f=Jl(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 Bh=!1;if(c)try{var xa={};Object.defineProperty(xa,"passive",{get:function(){Bh=!0}}),window.addEventListener("test",xa,xa),window.removeEventListener("test",xa,xa)}catch(i){Bh=!1}function H8(i,s,l,f,g,b,w,P,B){var X=Array.prototype.slice.call(arguments,3);try{s.apply(l,X)}catch(ce){this.onError(ce)}}var wa=!1,Ol=null,Il=!1,Uh=null,z8={onError:function(i){wa=!0,Ol=i}};function j8(i,s,l,f,g,b,w,P,B){wa=!1,Ol=null,H8.apply(z8,arguments)}function $8(i,s,l,f,g,b,w,P,B){if(j8.apply(this,arguments),wa){if(wa){var X=Ol;wa=!1,Ol=null}else throw Error(n(198));Il||(Il=!0,Uh=X)}}function Ki(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 TT(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 xT(i){if(Ki(i)!==i)throw Error(n(188))}function V8(i){var s=i.alternate;if(!s){if(s=Ki(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 b=g.alternate;if(b===null){if(f=g.return,f!==null){l=f;continue}break}if(g.child===b.child){for(b=g.child;b;){if(b===l)return xT(g),i;if(b===f)return xT(g),s;b=b.sibling}throw Error(n(188))}if(l.return!==f.return)l=g,f=b;else{for(var w=!1,P=g.child;P;){if(P===l){w=!0,l=g,f=b;break}if(P===f){w=!0,f=g,l=b;break}P=P.sibling}if(!w){for(P=b.child;P;){if(P===l){w=!0,l=b,f=g;break}if(P===f){w=!0,f=b,l=g;break}P=P.sibling}if(!w)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 wT(i){return i=V8(i),i!==null?_T(i):null}function _T(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=_T(i);if(s!==null)return s;i=i.sibling}return null}var vT=t.unstable_scheduleCallback,ST=t.unstable_cancelCallback,q8=t.unstable_shouldYield,Y8=t.unstable_requestPaint,_t=t.unstable_now,W8=t.unstable_getCurrentPriorityLevel,Hh=t.unstable_ImmediatePriority,AT=t.unstable_UserBlockingPriority,Rl=t.unstable_NormalPriority,G8=t.unstable_LowPriority,CT=t.unstable_IdlePriority,Pl=null,Tr=null;function K8(i){if(Tr&&typeof Tr.onCommitFiberRoot=="function")try{Tr.onCommitFiberRoot(Pl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var Jn=Math.clz32?Math.clz32:J8,Q8=Math.log,X8=Math.LN2;function J8(i){return i>>>=0,i===0?32:31-(Q8(i)/X8|0)|0}var Ll=64,Dl=4194304;function _a(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 Ml(i,s){var l=i.pendingLanes;if(l===0)return 0;var f=0,g=i.suspendedLanes,b=i.pingedLanes,w=l&268435455;if(w!==0){var P=w&~g;P!==0?f=_a(P):(b&=w,b!==0&&(f=_a(b)))}else w=l&~g,w!==0?f=_a(w):b!==0&&(f=_a(b));if(f===0)return 0;if(s!==0&&s!==f&&(s&g)===0&&(g=f&-f,b=s&-s,g>=b||g===16&&(b&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 Z8(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 eM(i,s){for(var l=i.suspendedLanes,f=i.pingedLanes,g=i.expirationTimes,b=i.pendingLanes;0<b;){var w=31-Jn(b),P=1<<w,B=g[w];B===-1?((P&l)===0||(P&f)!==0)&&(g[w]=Z8(P,s)):B<=s&&(i.expiredLanes|=P),b&=~P}}function zh(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function kT(){var i=Ll;return Ll<<=1,(Ll&4194240)===0&&(Ll=64),i}function jh(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function va(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 tM(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),b=1<<g;s[g]=0,f[g]=-1,i[g]=-1,l&=~b}}function $h(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 NT(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var OT,Vh,IT,RT,PT,qh=!1,Fl=[],ri=null,ii=null,oi=null,Sa=new Map,Aa=new Map,si=[],nM="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 LT(i,s){switch(i){case"focusin":case"focusout":ri=null;break;case"dragenter":case"dragleave":ii=null;break;case"mouseover":case"mouseout":oi=null;break;case"pointerover":case"pointerout":Sa.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":Aa.delete(s.pointerId)}}function Ca(i,s,l,f,g,b){return i===null||i.nativeEvent!==b?(i={blockedOn:s,domEventName:l,eventSystemFlags:f,nativeEvent:b,targetContainers:[g]},s!==null&&(s=za(s),s!==null&&Vh(s)),i):(i.eventSystemFlags|=f,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function rM(i,s,l,f,g){switch(s){case"focusin":return ri=Ca(ri,i,s,l,f,g),!0;case"dragenter":return ii=Ca(ii,i,s,l,f,g),!0;case"mouseover":return oi=Ca(oi,i,s,l,f,g),!0;case"pointerover":var b=g.pointerId;return Sa.set(b,Ca(Sa.get(b)||null,i,s,l,f,g)),!0;case"gotpointercapture":return b=g.pointerId,Aa.set(b,Ca(Aa.get(b)||null,i,s,l,f,g)),!0}return!1}function DT(i){var s=Qi(i.target);if(s!==null){var l=Ki(s);if(l!==null){if(s=l.tag,s===13){if(s=TT(l),s!==null){i.blockedOn=s,PT(i.priority,function(){IT(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 Bl(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=Wh(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var f=new l.constructor(l.type,l);Sn=f,l.target.dispatchEvent(f),Sn=null}else return s=za(l),s!==null&&Vh(s),i.blockedOn=l,!1;s.shift()}return!0}function MT(i,s,l){Bl(i)&&l.delete(s)}function iM(){qh=!1,ri!==null&&Bl(ri)&&(ri=null),ii!==null&&Bl(ii)&&(ii=null),oi!==null&&Bl(oi)&&(oi=null),Sa.forEach(MT),Aa.forEach(MT)}function ka(i,s){i.blockedOn===s&&(i.blockedOn=null,qh||(qh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,iM)))}function Na(i){function s(g){return ka(g,i)}if(0<Fl.length){ka(Fl[0],i);for(var l=1;l<Fl.length;l++){var f=Fl[l];f.blockedOn===i&&(f.blockedOn=null)}}for(ri!==null&&ka(ri,i),ii!==null&&ka(ii,i),oi!==null&&ka(oi,i),Sa.forEach(s),Aa.forEach(s),l=0;l<si.length;l++)f=si[l],f.blockedOn===i&&(f.blockedOn=null);for(;0<si.length&&(l=si[0],l.blockedOn===null);)DT(l),l.blockedOn===null&&si.shift()}var Jo=z.ReactCurrentBatchConfig,Ul=!0;function oM(i,s,l,f){var g=nt,b=Jo.transition;Jo.transition=null;try{nt=1,Yh(i,s,l,f)}finally{nt=g,Jo.transition=b}}function sM(i,s,l,f){var g=nt,b=Jo.transition;Jo.transition=null;try{nt=4,Yh(i,s,l,f)}finally{nt=g,Jo.transition=b}}function Yh(i,s,l,f){if(Ul){var g=Wh(i,s,l,f);if(g===null)cp(i,s,f,Hl,l),LT(i,f);else if(rM(g,i,s,l,f))f.stopPropagation();else if(LT(i,f),s&4&&-1<nM.indexOf(i)){for(;g!==null;){var b=za(g);if(b!==null&&OT(b),b=Wh(i,s,l,f),b===null&&cp(i,s,f,Hl,l),b===g)break;g=b}g!==null&&f.stopPropagation()}else cp(i,s,f,null,l)}}var Hl=null;function Wh(i,s,l,f){if(Hl=null,i=Dh(f),i=Qi(i),i!==null)if(s=Ki(i),s===null)i=null;else if(l=s.tag,l===13){if(i=TT(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 Hl=i,null}function FT(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(W8()){case Hh:return 1;case AT:return 4;case Rl:case G8:return 16;case CT:return 536870912;default:return 16}default:return 16}}var ai=null,Gh=null,zl=null;function BT(){if(zl)return zl;var i,s=Gh,l=s.length,f,g="value"in ai?ai.value:ai.textContent,b=g.length;for(i=0;i<l&&s[i]===g[i];i++);var w=l-i;for(f=1;f<=w&&s[l-f]===g[b-f];f++);return zl=g.slice(i,1<f?1-f:void 0)}function jl(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 $l(){return!0}function UT(){return!1}function An(i){function s(l,f,g,b,w){this._reactName=l,this._targetInst=g,this.type=f,this.nativeEvent=b,this.target=w,this.currentTarget=null;for(var P in i)i.hasOwnProperty(P)&&(l=i[P],this[P]=l?l(b):b[P]);return this.isDefaultPrevented=(b.defaultPrevented!=null?b.defaultPrevented:b.returnValue===!1)?$l:UT,this.isPropagationStopped=UT,this}return C(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=$l)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=$l)},persist:function(){},isPersistent:$l}),s}var Zo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Kh=An(Zo),Oa=C({},Zo,{view:0,detail:0}),aM=An(Oa),Qh,Xh,Ia,Vl=C({},Oa,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Zh,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!==Ia&&(Ia&&i.type==="mousemove"?(Qh=i.screenX-Ia.screenX,Xh=i.screenY-Ia.screenY):Xh=Qh=0,Ia=i),Qh)},movementY:function(i){return"movementY"in i?i.movementY:Xh}}),HT=An(Vl),uM=C({},Vl,{dataTransfer:0}),lM=An(uM),cM=C({},Oa,{relatedTarget:0}),Jh=An(cM),dM=C({},Zo,{animationName:0,elapsedTime:0,pseudoElement:0}),fM=An(dM),hM=C({},Zo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),pM=An(hM),mM=C({},Zo,{data:0}),zT=An(mM),gM={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},EM={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"},yM={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function bM(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=yM[i])?!!s[i]:!1}function Zh(){return bM}var TM=C({},Oa,{key:function(i){if(i.key){var s=gM[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=jl(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?EM[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Zh,charCode:function(i){return i.type==="keypress"?jl(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?jl(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),xM=An(TM),wM=C({},Vl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),jT=An(wM),_M=C({},Oa,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Zh}),vM=An(_M),SM=C({},Zo,{propertyName:0,elapsedTime:0,pseudoElement:0}),AM=An(SM),CM=C({},Vl,{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}),kM=An(CM),NM=[9,13,27,32],ep=c&&"CompositionEvent"in window,Ra=null;c&&"documentMode"in document&&(Ra=document.documentMode);var OM=c&&"TextEvent"in window&&!Ra,$T=c&&(!ep||Ra&&8<Ra&&11>=Ra),VT=" ",qT=!1;function YT(i,s){switch(i){case"keyup":return NM.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function WT(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var es=!1;function IM(i,s){switch(i){case"compositionend":return WT(s);case"keypress":return s.which!==32?null:(qT=!0,VT);case"textInput":return i=s.data,i===VT&&qT?null:i;default:return null}}function RM(i,s){if(es)return i==="compositionend"||!ep&&YT(i,s)?(i=BT(),zl=Gh=ai=null,es=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return $T&&s.locale!=="ko"?null:s.data;default:return null}}var PM={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 GT(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!PM[i.type]:s==="textarea"}function KT(i,s,l,f){mT(f),s=Kl(s,"onChange"),0<s.length&&(l=new Kh("onChange","change",null,l,f),i.push({event:l,listeners:s}))}var Pa=null,La=null;function LM(i){hx(i,0)}function ql(i){var s=os(i);if(Wi(s))return i}function DM(i,s){if(i==="change")return s}var QT=!1;if(c){var tp;if(c){var np="oninput"in document;if(!np){var XT=document.createElement("div");XT.setAttribute("oninput","return;"),np=typeof XT.oninput=="function"}tp=np}else tp=!1;QT=tp&&(!document.documentMode||9<document.documentMode)}function JT(){Pa&&(Pa.detachEvent("onpropertychange",ZT),La=Pa=null)}function ZT(i){if(i.propertyName==="value"&&ql(La)){var s=[];KT(s,La,i,Dh(i)),bT(LM,s)}}function MM(i,s,l){i==="focusin"?(JT(),Pa=s,La=l,Pa.attachEvent("onpropertychange",ZT)):i==="focusout"&&JT()}function FM(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return ql(La)}function BM(i,s){if(i==="click")return ql(s)}function UM(i,s){if(i==="input"||i==="change")return ql(s)}function HM(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var Zn=typeof Object.is=="function"?Object.is:HM;function Da(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 ex(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function tx(i,s){var l=ex(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=ex(l)}}function nx(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?nx(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function rx(){for(var i=window,s=Zr();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=Zr(i.document)}return s}function rp(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 zM(i){var s=rx(),l=i.focusedElem,f=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&nx(l.ownerDocument.documentElement,l)){if(f!==null&&rp(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,b=Math.min(f.start,g);f=f.end===void 0?b:Math.min(f.end,g),!i.extend&&b>f&&(g=f,f=b,b=g),g=tx(l,b);var w=tx(l,f);g&&w&&(i.rangeCount!==1||i.anchorNode!==g.node||i.anchorOffset!==g.offset||i.focusNode!==w.node||i.focusOffset!==w.offset)&&(s=s.createRange(),s.setStart(g.node,g.offset),i.removeAllRanges(),b>f?(i.addRange(s),i.extend(w.node,w.offset)):(s.setEnd(w.node,w.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 jM=c&&"documentMode"in document&&11>=document.documentMode,ts=null,ip=null,Ma=null,op=!1;function ix(i,s,l){var f=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;op||ts==null||ts!==Zr(f)||(f=ts,"selectionStart"in f&&rp(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}),Ma&&Da(Ma,f)||(Ma=f,f=Kl(ip,"onSelect"),0<f.length&&(s=new Kh("onSelect","select",null,s,l),i.push({event:s,listeners:f}),s.target=ts)))}function Yl(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var ns={animationend:Yl("Animation","AnimationEnd"),animationiteration:Yl("Animation","AnimationIteration"),animationstart:Yl("Animation","AnimationStart"),transitionend:Yl("Transition","TransitionEnd")},sp={},ox={};c&&(ox=document.createElement("div").style,"AnimationEvent"in window||(delete ns.animationend.animation,delete ns.animationiteration.animation,delete ns.animationstart.animation),"TransitionEvent"in window||delete ns.transitionend.transition);function Wl(i){if(sp[i])return sp[i];if(!ns[i])return i;var s=ns[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in ox)return sp[i]=s[l];return i}var sx=Wl("animationend"),ax=Wl("animationiteration"),ux=Wl("animationstart"),lx=Wl("transitionend"),cx=new Map,dx="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 ui(i,s){cx.set(i,s),a(s,[i])}for(var ap=0;ap<dx.length;ap++){var up=dx[ap],$M=up.toLowerCase(),VM=up[0].toUpperCase()+up.slice(1);ui($M,"on"+VM)}ui(sx,"onAnimationEnd"),ui(ax,"onAnimationIteration"),ui(ux,"onAnimationStart"),ui("dblclick","onDoubleClick"),ui("focusin","onFocus"),ui("focusout","onBlur"),ui(lx,"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 Fa="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(" "),qM=new Set("cancel close invalid load scroll toggle".split(" ").concat(Fa));function fx(i,s,l){var f=i.type||"unknown-event";i.currentTarget=l,$8(f,s,void 0,i),i.currentTarget=null}function hx(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 b=void 0;if(s)for(var w=f.length-1;0<=w;w--){var P=f[w],B=P.instance,X=P.currentTarget;if(P=P.listener,B!==b&&g.isPropagationStopped())break e;fx(g,P,X),b=B}else for(w=0;w<f.length;w++){if(P=f[w],B=P.instance,X=P.currentTarget,P=P.listener,B!==b&&g.isPropagationStopped())break e;fx(g,P,X),b=B}}}if(Il)throw i=Uh,Il=!1,Uh=null,i}function lt(i,s){var l=s[gp];l===void 0&&(l=s[gp]=new Set);var f=i+"__bubble";l.has(f)||(px(s,i,2,!1),l.add(f))}function lp(i,s,l){var f=0;s&&(f|=4),px(l,i,f,s)}var Gl="_reactListening"+Math.random().toString(36).slice(2);function Ba(i){if(!i[Gl]){i[Gl]=!0,r.forEach(function(l){l!=="selectionchange"&&(qM.has(l)||lp(l,!1,i),lp(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[Gl]||(s[Gl]=!0,lp("selectionchange",!1,s))}}function px(i,s,l,f){switch(FT(s)){case 1:var g=oM;break;case 4:g=sM;break;default:g=Yh}l=g.bind(null,s,l,i),g=void 0,!Bh||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 cp(i,s,l,f,g){var b=f;if((s&1)===0&&(s&2)===0&&f!==null)e:for(;;){if(f===null)return;var w=f.tag;if(w===3||w===4){var P=f.stateNode.containerInfo;if(P===g||P.nodeType===8&&P.parentNode===g)break;if(w===4)for(w=f.return;w!==null;){var B=w.tag;if((B===3||B===4)&&(B=w.stateNode.containerInfo,B===g||B.nodeType===8&&B.parentNode===g))return;w=w.return}for(;P!==null;){if(w=Qi(P),w===null)return;if(B=w.tag,B===5||B===6){f=b=w;continue e}P=P.parentNode}}f=f.return}bT(function(){var X=b,ce=Dh(l),me=[];e:{var ue=cx.get(i);if(ue!==void 0){var we=Kh,Ce=i;switch(i){case"keypress":if(jl(l)===0)break e;case"keydown":case"keyup":we=xM;break;case"focusin":Ce="focus",we=Jh;break;case"focusout":Ce="blur",we=Jh;break;case"beforeblur":case"afterblur":we=Jh;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":we=HT;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":we=lM;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":we=vM;break;case sx:case ax:case ux:we=fM;break;case lx:we=AM;break;case"scroll":we=aM;break;case"wheel":we=kM;break;case"copy":case"cut":case"paste":we=pM;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":we=jT}var Ne=(s&4)!==0,vt=!Ne&&i==="scroll",q=Ne?ue!==null?ue+"Capture":null:ue;Ne=[];for(var j=X,G;j!==null;){G=j;var ye=G.stateNode;if(G.tag===5&&ye!==null&&(G=ye,q!==null&&(ye=Ta(j,q),ye!=null&&Ne.push(Ua(j,ye,G)))),vt)break;j=j.return}0<Ne.length&&(ue=new we(ue,Ce,null,l,ce),me.push({event:ue,listeners:Ne}))}}if((s&7)===0){e:{if(ue=i==="mouseover"||i==="pointerover",we=i==="mouseout"||i==="pointerout",ue&&l!==Sn&&(Ce=l.relatedTarget||l.fromElement)&&(Qi(Ce)||Ce[Pr]))break e;if((we||ue)&&(ue=ce.window===ce?ce:(ue=ce.ownerDocument)?ue.defaultView||ue.parentWindow:window,we?(Ce=l.relatedTarget||l.toElement,we=X,Ce=Ce?Qi(Ce):null,Ce!==null&&(vt=Ki(Ce),Ce!==vt||Ce.tag!==5&&Ce.tag!==6)&&(Ce=null)):(we=null,Ce=X),we!==Ce)){if(Ne=HT,ye="onMouseLeave",q="onMouseEnter",j="mouse",(i==="pointerout"||i==="pointerover")&&(Ne=jT,ye="onPointerLeave",q="onPointerEnter",j="pointer"),vt=we==null?ue:os(we),G=Ce==null?ue:os(Ce),ue=new Ne(ye,j+"leave",we,l,ce),ue.target=vt,ue.relatedTarget=G,ye=null,Qi(ce)===X&&(Ne=new Ne(q,j+"enter",Ce,l,ce),Ne.target=G,Ne.relatedTarget=vt,ye=Ne),vt=ye,we&&Ce)t:{for(Ne=we,q=Ce,j=0,G=Ne;G;G=rs(G))j++;for(G=0,ye=q;ye;ye=rs(ye))G++;for(;0<j-G;)Ne=rs(Ne),j--;for(;0<G-j;)q=rs(q),G--;for(;j--;){if(Ne===q||q!==null&&Ne===q.alternate)break t;Ne=rs(Ne),q=rs(q)}Ne=null}else Ne=null;we!==null&&mx(me,ue,we,Ne,!1),Ce!==null&&vt!==null&&mx(me,vt,Ce,Ne,!0)}}e:{if(ue=X?os(X):window,we=ue.nodeName&&ue.nodeName.toLowerCase(),we==="select"||we==="input"&&ue.type==="file")var Oe=DM;else if(GT(ue))if(QT)Oe=UM;else{Oe=FM;var De=MM}else(we=ue.nodeName)&&we.toLowerCase()==="input"&&(ue.type==="checkbox"||ue.type==="radio")&&(Oe=BM);if(Oe&&(Oe=Oe(i,X))){KT(me,Oe,l,ce);break e}De&&De(i,ue,X),i==="focusout"&&(De=ue._wrapperState)&&De.controlled&&ue.type==="number"&&Ko(ue,"number",ue.value)}switch(De=X?os(X):window,i){case"focusin":(GT(De)||De.contentEditable==="true")&&(ts=De,ip=X,Ma=null);break;case"focusout":Ma=ip=ts=null;break;case"mousedown":op=!0;break;case"contextmenu":case"mouseup":case"dragend":op=!1,ix(me,l,ce);break;case"selectionchange":if(jM)break;case"keydown":case"keyup":ix(me,l,ce)}var Me;if(ep)e:{switch(i){case"compositionstart":var He="onCompositionStart";break e;case"compositionend":He="onCompositionEnd";break e;case"compositionupdate":He="onCompositionUpdate";break e}He=void 0}else es?YT(i,l)&&(He="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(He="onCompositionStart");He&&($T&&l.locale!=="ko"&&(es||He!=="onCompositionStart"?He==="onCompositionEnd"&&es&&(Me=BT()):(ai=ce,Gh="value"in ai?ai.value:ai.textContent,es=!0)),De=Kl(X,He),0<De.length&&(He=new zT(He,i,null,l,ce),me.push({event:He,listeners:De}),Me?He.data=Me:(Me=WT(l),Me!==null&&(He.data=Me)))),(Me=OM?IM(i,l):RM(i,l))&&(X=Kl(X,"onBeforeInput"),0<X.length&&(ce=new zT("onBeforeInput","beforeinput",null,l,ce),me.push({event:ce,listeners:X}),ce.data=Me))}hx(me,s)})}function Ua(i,s,l){return{instance:i,listener:s,currentTarget:l}}function Kl(i,s){for(var l=s+"Capture",f=[];i!==null;){var g=i,b=g.stateNode;g.tag===5&&b!==null&&(g=b,b=Ta(i,l),b!=null&&f.unshift(Ua(i,b,g)),b=Ta(i,s),b!=null&&f.push(Ua(i,b,g))),i=i.return}return f}function rs(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function mx(i,s,l,f,g){for(var b=s._reactName,w=[];l!==null&&l!==f;){var P=l,B=P.alternate,X=P.stateNode;if(B!==null&&B===f)break;P.tag===5&&X!==null&&(P=X,g?(B=Ta(l,b),B!=null&&w.unshift(Ua(l,B,P))):g||(B=Ta(l,b),B!=null&&w.push(Ua(l,B,P)))),l=l.return}w.length!==0&&i.push({event:s,listeners:w})}var YM=/\r\n?/g,WM=/\u0000|\uFFFD/g;function gx(i){return(typeof i=="string"?i:""+i).replace(YM,`
21
- `).replace(WM,"")}function Ql(i,s,l){if(s=gx(s),gx(i)!==s&&l)throw Error(n(425))}function Xl(){}var dp=null,fp=null;function hp(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 pp=typeof setTimeout=="function"?setTimeout:void 0,GM=typeof clearTimeout=="function"?clearTimeout:void 0,Ex=typeof Promise=="function"?Promise:void 0,KM=typeof queueMicrotask=="function"?queueMicrotask:typeof Ex!="undefined"?function(i){return Ex.resolve(null).then(i).catch(QM)}:pp;function QM(i){setTimeout(function(){throw i})}function mp(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),Na(s);return}f--}else l!=="$"&&l!=="$?"&&l!=="$!"||f++;l=g}while(l);Na(s)}function li(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 yx(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 is=Math.random().toString(36).slice(2),xr="__reactFiber$"+is,Ha="__reactProps$"+is,Pr="__reactContainer$"+is,gp="__reactEvents$"+is,XM="__reactListeners$"+is,JM="__reactHandles$"+is;function Qi(i){var s=i[xr];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Pr]||l[xr]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=yx(i);i!==null;){if(l=i[xr])return l;i=yx(i)}return s}i=l,l=i.parentNode}return null}function za(i){return i=i[xr]||i[Pr],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function os(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function Jl(i){return i[Ha]||null}var Ep=[],ss=-1;function ci(i){return{current:i}}function ct(i){0>ss||(i.current=Ep[ss],Ep[ss]=null,ss--)}function at(i,s){ss++,Ep[ss]=i.current,i.current=s}var di={},Xt=ci(di),mn=ci(!1),Xi=di;function as(i,s){var l=i.type.contextTypes;if(!l)return di;var f=i.stateNode;if(f&&f.__reactInternalMemoizedUnmaskedChildContext===s)return f.__reactInternalMemoizedMaskedChildContext;var g={},b;for(b in l)g[b]=s[b];return f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function gn(i){return i=i.childContextTypes,i!=null}function Zl(){ct(mn),ct(Xt)}function bx(i,s,l){if(Xt.current!==di)throw Error(n(168));at(Xt,s),at(mn,l)}function Tx(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,Be(i)||"Unknown",g));return C({},l,f)}function ec(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||di,Xi=Xt.current,at(Xt,i),at(mn,mn.current),!0}function xx(i,s,l){var f=i.stateNode;if(!f)throw Error(n(169));l?(i=Tx(i,s,Xi),f.__reactInternalMemoizedMergedChildContext=i,ct(mn),ct(Xt),at(Xt,i)):ct(mn),at(mn,l)}var Lr=null,tc=!1,yp=!1;function wx(i){Lr===null?Lr=[i]:Lr.push(i)}function ZM(i){tc=!0,wx(i)}function fi(){if(!yp&&Lr!==null){yp=!0;var i=0,s=nt;try{var l=Lr;for(nt=1;i<l.length;i++){var f=l[i];do f=f(!0);while(f!==null)}Lr=null,tc=!1}catch(g){throw Lr!==null&&(Lr=Lr.slice(i+1)),vT(Hh,fi),g}finally{nt=s,yp=!1}}return null}var us=[],ls=0,nc=null,rc=0,Fn=[],Bn=0,Ji=null,Dr=1,Mr="";function Zi(i,s){us[ls++]=rc,us[ls++]=nc,nc=i,rc=s}function _x(i,s,l){Fn[Bn++]=Dr,Fn[Bn++]=Mr,Fn[Bn++]=Ji,Ji=i;var f=Dr;i=Mr;var g=32-Jn(f)-1;f&=~(1<<g),l+=1;var b=32-Jn(s)+g;if(30<b){var w=g-g%5;b=(f&(1<<w)-1).toString(32),f>>=w,g-=w,Dr=1<<32-Jn(s)+g|l<<g|f,Mr=b+i}else Dr=1<<b|l<<g|f,Mr=i}function bp(i){i.return!==null&&(Zi(i,1),_x(i,1,0))}function Tp(i){for(;i===nc;)nc=us[--ls],us[ls]=null,rc=us[--ls],us[ls]=null;for(;i===Ji;)Ji=Fn[--Bn],Fn[Bn]=null,Mr=Fn[--Bn],Fn[Bn]=null,Dr=Fn[--Bn],Fn[Bn]=null}var Cn=null,kn=null,pt=!1,er=null;function vx(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 Sx(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=li(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=Ji!==null?{id:Dr,overflow:Mr}: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 xp(i){return(i.mode&1)!==0&&(i.flags&128)===0}function wp(i){if(pt){var s=kn;if(s){var l=s;if(!Sx(i,s)){if(xp(i))throw Error(n(418));s=li(l.nextSibling);var f=Cn;s&&Sx(i,s)?vx(f,l):(i.flags=i.flags&-4097|2,pt=!1,Cn=i)}}else{if(xp(i))throw Error(n(418));i.flags=i.flags&-4097|2,pt=!1,Cn=i}}}function Ax(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Cn=i}function ic(i){if(i!==Cn)return!1;if(!pt)return Ax(i),pt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!hp(i.type,i.memoizedProps)),s&&(s=kn)){if(xp(i))throw Cx(),Error(n(418));for(;s;)vx(i,s),s=li(s.nextSibling)}if(Ax(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=li(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}kn=null}}else kn=Cn?li(i.stateNode.nextSibling):null;return!0}function Cx(){for(var i=kn;i;)i=li(i.nextSibling)}function cs(){kn=Cn=null,pt=!1}function _p(i){er===null?er=[i]:er.push(i)}var e9=z.ReactCurrentBatchConfig;function ja(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,b=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===b?s.ref:(s=function(w){var P=g.refs;w===null?delete P[b]:P[b]=w},s._stringRef=b,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function oc(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function kx(i){var s=i._init;return s(i._payload)}function Nx(i){function s(q,j){if(i){var G=q.deletions;G===null?(q.deletions=[j],q.flags|=16):G.push(j)}}function l(q,j){if(!i)return null;for(;j!==null;)s(q,j),j=j.sibling;return null}function f(q,j){for(q=new Map;j!==null;)j.key!==null?q.set(j.key,j):q.set(j.index,j),j=j.sibling;return q}function g(q,j){return q=Ti(q,j),q.index=0,q.sibling=null,q}function b(q,j,G){return q.index=G,i?(G=q.alternate,G!==null?(G=G.index,G<j?(q.flags|=2,j):G):(q.flags|=2,j)):(q.flags|=1048576,j)}function w(q){return i&&q.alternate===null&&(q.flags|=2),q}function P(q,j,G,ye){return j===null||j.tag!==6?(j=pm(G,q.mode,ye),j.return=q,j):(j=g(j,G),j.return=q,j)}function B(q,j,G,ye){var Oe=G.type;return Oe===K?ce(q,j,G.props.children,ye,G.key):j!==null&&(j.elementType===Oe||typeof Oe=="object"&&Oe!==null&&Oe.$$typeof===Ie&&kx(Oe)===j.type)?(ye=g(j,G.props),ye.ref=ja(q,j,G),ye.return=q,ye):(ye=Nc(G.type,G.key,G.props,null,q.mode,ye),ye.ref=ja(q,j,G),ye.return=q,ye)}function X(q,j,G,ye){return j===null||j.tag!==4||j.stateNode.containerInfo!==G.containerInfo||j.stateNode.implementation!==G.implementation?(j=mm(G,q.mode,ye),j.return=q,j):(j=g(j,G.children||[]),j.return=q,j)}function ce(q,j,G,ye,Oe){return j===null||j.tag!==7?(j=ao(G,q.mode,ye,Oe),j.return=q,j):(j=g(j,G),j.return=q,j)}function me(q,j,G){if(typeof j=="string"&&j!==""||typeof j=="number")return j=pm(""+j,q.mode,G),j.return=q,j;if(typeof j=="object"&&j!==null){switch(j.$$typeof){case W:return G=Nc(j.type,j.key,j.props,null,q.mode,G),G.ref=ja(q,null,j),G.return=q,G;case M:return j=mm(j,q.mode,G),j.return=q,j;case Ie:var ye=j._init;return me(q,ye(j._payload),G)}if(ei(j)||se(j))return j=ao(j,q.mode,G,null),j.return=q,j;oc(q,j)}return null}function ue(q,j,G,ye){var Oe=j!==null?j.key:null;if(typeof G=="string"&&G!==""||typeof G=="number")return Oe!==null?null:P(q,j,""+G,ye);if(typeof G=="object"&&G!==null){switch(G.$$typeof){case W:return G.key===Oe?B(q,j,G,ye):null;case M:return G.key===Oe?X(q,j,G,ye):null;case Ie:return Oe=G._init,ue(q,j,Oe(G._payload),ye)}if(ei(G)||se(G))return Oe!==null?null:ce(q,j,G,ye,null);oc(q,G)}return null}function we(q,j,G,ye,Oe){if(typeof ye=="string"&&ye!==""||typeof ye=="number")return q=q.get(G)||null,P(j,q,""+ye,Oe);if(typeof ye=="object"&&ye!==null){switch(ye.$$typeof){case W:return q=q.get(ye.key===null?G:ye.key)||null,B(j,q,ye,Oe);case M:return q=q.get(ye.key===null?G:ye.key)||null,X(j,q,ye,Oe);case Ie:var De=ye._init;return we(q,j,G,De(ye._payload),Oe)}if(ei(ye)||se(ye))return q=q.get(G)||null,ce(j,q,ye,Oe,null);oc(j,ye)}return null}function Ce(q,j,G,ye){for(var Oe=null,De=null,Me=j,He=j=0,zt=null;Me!==null&&He<G.length;He++){Me.index>He?(zt=Me,Me=null):zt=Me.sibling;var et=ue(q,Me,G[He],ye);if(et===null){Me===null&&(Me=zt);break}i&&Me&&et.alternate===null&&s(q,Me),j=b(et,j,He),De===null?Oe=et:De.sibling=et,De=et,Me=zt}if(He===G.length)return l(q,Me),pt&&Zi(q,He),Oe;if(Me===null){for(;He<G.length;He++)Me=me(q,G[He],ye),Me!==null&&(j=b(Me,j,He),De===null?Oe=Me:De.sibling=Me,De=Me);return pt&&Zi(q,He),Oe}for(Me=f(q,Me);He<G.length;He++)zt=we(Me,q,He,G[He],ye),zt!==null&&(i&&zt.alternate!==null&&Me.delete(zt.key===null?He:zt.key),j=b(zt,j,He),De===null?Oe=zt:De.sibling=zt,De=zt);return i&&Me.forEach(function(xi){return s(q,xi)}),pt&&Zi(q,He),Oe}function Ne(q,j,G,ye){var Oe=se(G);if(typeof Oe!="function")throw Error(n(150));if(G=Oe.call(G),G==null)throw Error(n(151));for(var De=Oe=null,Me=j,He=j=0,zt=null,et=G.next();Me!==null&&!et.done;He++,et=G.next()){Me.index>He?(zt=Me,Me=null):zt=Me.sibling;var xi=ue(q,Me,et.value,ye);if(xi===null){Me===null&&(Me=zt);break}i&&Me&&xi.alternate===null&&s(q,Me),j=b(xi,j,He),De===null?Oe=xi:De.sibling=xi,De=xi,Me=zt}if(et.done)return l(q,Me),pt&&Zi(q,He),Oe;if(Me===null){for(;!et.done;He++,et=G.next())et=me(q,et.value,ye),et!==null&&(j=b(et,j,He),De===null?Oe=et:De.sibling=et,De=et);return pt&&Zi(q,He),Oe}for(Me=f(q,Me);!et.done;He++,et=G.next())et=we(Me,q,He,et.value,ye),et!==null&&(i&&et.alternate!==null&&Me.delete(et.key===null?He:et.key),j=b(et,j,He),De===null?Oe=et:De.sibling=et,De=et);return i&&Me.forEach(function(P9){return s(q,P9)}),pt&&Zi(q,He),Oe}function vt(q,j,G,ye){if(typeof G=="object"&&G!==null&&G.type===K&&G.key===null&&(G=G.props.children),typeof G=="object"&&G!==null){switch(G.$$typeof){case W:e:{for(var Oe=G.key,De=j;De!==null;){if(De.key===Oe){if(Oe=G.type,Oe===K){if(De.tag===7){l(q,De.sibling),j=g(De,G.props.children),j.return=q,q=j;break e}}else if(De.elementType===Oe||typeof Oe=="object"&&Oe!==null&&Oe.$$typeof===Ie&&kx(Oe)===De.type){l(q,De.sibling),j=g(De,G.props),j.ref=ja(q,De,G),j.return=q,q=j;break e}l(q,De);break}else s(q,De);De=De.sibling}G.type===K?(j=ao(G.props.children,q.mode,ye,G.key),j.return=q,q=j):(ye=Nc(G.type,G.key,G.props,null,q.mode,ye),ye.ref=ja(q,j,G),ye.return=q,q=ye)}return w(q);case M:e:{for(De=G.key;j!==null;){if(j.key===De)if(j.tag===4&&j.stateNode.containerInfo===G.containerInfo&&j.stateNode.implementation===G.implementation){l(q,j.sibling),j=g(j,G.children||[]),j.return=q,q=j;break e}else{l(q,j);break}else s(q,j);j=j.sibling}j=mm(G,q.mode,ye),j.return=q,q=j}return w(q);case Ie:return De=G._init,vt(q,j,De(G._payload),ye)}if(ei(G))return Ce(q,j,G,ye);if(se(G))return Ne(q,j,G,ye);oc(q,G)}return typeof G=="string"&&G!==""||typeof G=="number"?(G=""+G,j!==null&&j.tag===6?(l(q,j.sibling),j=g(j,G),j.return=q,q=j):(l(q,j),j=pm(G,q.mode,ye),j.return=q,q=j),w(q)):l(q,j)}return vt}var ds=Nx(!0),Ox=Nx(!1),sc=ci(null),ac=null,fs=null,vp=null;function Sp(){vp=fs=ac=null}function Ap(i){var s=sc.current;ct(sc),i._currentValue=s}function Cp(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 hs(i,s){ac=i,vp=fs=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(vp!==i)if(i={context:i,memoizedValue:s,next:null},fs===null){if(ac===null)throw Error(n(308));fs=i,ac.dependencies={lanes:0,firstContext:i}}else fs=fs.next=i;return s}var eo=null;function kp(i){eo===null?eo=[i]:eo.push(i)}function Ix(i,s,l,f){var g=s.interleaved;return g===null?(l.next=l,kp(s)):(l.next=g.next,g.next=l),s.interleaved=l,Fr(i,f)}function Fr(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 hi=!1;function Np(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Rx(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 Br(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function pi(i,s,l){var f=i.updateQueue;if(f===null)return null;if(f=f.shared,(Je&2)!==0){var g=f.pending;return g===null?s.next=s:(s.next=g.next,g.next=s),f.pending=s,Fr(i,l)}return g=f.interleaved,g===null?(s.next=s,kp(f)):(s.next=g.next,g.next=s),f.interleaved=s,Fr(i,l)}function uc(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,$h(i,l)}}function Px(i,s){var l=i.updateQueue,f=i.alternate;if(f!==null&&(f=f.updateQueue,l===f)){var g=null,b=null;if(l=l.firstBaseUpdate,l!==null){do{var w={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};b===null?g=b=w:b=b.next=w,l=l.next}while(l!==null);b===null?g=b=s:b=b.next=s}else g=b=s;l={baseState:f.baseState,firstBaseUpdate:g,lastBaseUpdate:b,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 lc(i,s,l,f){var g=i.updateQueue;hi=!1;var b=g.firstBaseUpdate,w=g.lastBaseUpdate,P=g.shared.pending;if(P!==null){g.shared.pending=null;var B=P,X=B.next;B.next=null,w===null?b=X:w.next=X,w=B;var ce=i.alternate;ce!==null&&(ce=ce.updateQueue,P=ce.lastBaseUpdate,P!==w&&(P===null?ce.firstBaseUpdate=X:P.next=X,ce.lastBaseUpdate=B))}if(b!==null){var me=g.baseState;w=0,ce=X=B=null,P=b;do{var ue=P.lane,we=P.eventTime;if((f&ue)===ue){ce!==null&&(ce=ce.next={eventTime:we,lane:0,tag:P.tag,payload:P.payload,callback:P.callback,next:null});e:{var Ce=i,Ne=P;switch(ue=s,we=l,Ne.tag){case 1:if(Ce=Ne.payload,typeof Ce=="function"){me=Ce.call(we,me,ue);break e}me=Ce;break e;case 3:Ce.flags=Ce.flags&-65537|128;case 0:if(Ce=Ne.payload,ue=typeof Ce=="function"?Ce.call(we,me,ue):Ce,ue==null)break e;me=C({},me,ue);break e;case 2:hi=!0}}P.callback!==null&&P.lane!==0&&(i.flags|=64,ue=g.effects,ue===null?g.effects=[P]:ue.push(P))}else we={eventTime:we,lane:ue,tag:P.tag,payload:P.payload,callback:P.callback,next:null},ce===null?(X=ce=we,B=me):ce=ce.next=we,w|=ue;if(P=P.next,P===null){if(P=g.shared.pending,P===null)break;ue=P,P=ue.next,ue.next=null,g.lastBaseUpdate=ue,g.shared.pending=null}}while(!0);if(ce===null&&(B=me),g.baseState=B,g.firstBaseUpdate=X,g.lastBaseUpdate=ce,s=g.shared.interleaved,s!==null){g=s;do w|=g.lane,g=g.next;while(g!==s)}else b===null&&(g.shared.lanes=0);ro|=w,i.lanes=w,i.memoizedState=me}}function Lx(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 $a={},wr=ci($a),Va=ci($a),qa=ci($a);function to(i){if(i===$a)throw Error(n(174));return i}function Op(i,s){switch(at(qa,s),at(Va,i),at(wr,$a),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:Te(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=Te(s,i)}ct(wr),at(wr,s)}function ps(){ct(wr),ct(Va),ct(qa)}function Dx(i){to(qa.current);var s=to(wr.current),l=Te(s,i.type);s!==l&&(at(Va,i),at(wr,l))}function Ip(i){Va.current===i&&(ct(wr),ct(Va))}var gt=ci(0);function cc(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 Rp=[];function Pp(){for(var i=0;i<Rp.length;i++)Rp[i]._workInProgressVersionPrimary=null;Rp.length=0}var dc=z.ReactCurrentDispatcher,Lp=z.ReactCurrentBatchConfig,no=0,Et=null,Rt=null,Ut=null,fc=!1,Ya=!1,Wa=0,t9=0;function Jt(){throw Error(n(321))}function Dp(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 Mp(i,s,l,f,g,b){if(no=b,Et=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,dc.current=i===null||i.memoizedState===null?o9:s9,i=l(f,g),Ya){b=0;do{if(Ya=!1,Wa=0,25<=b)throw Error(n(301));b+=1,Ut=Rt=null,s.updateQueue=null,dc.current=a9,i=l(f,g)}while(Ya)}if(dc.current=mc,s=Rt!==null&&Rt.next!==null,no=0,Ut=Rt=Et=null,fc=!1,s)throw Error(n(300));return i}function Fp(){var i=Wa!==0;return Wa=0,i}function _r(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ut===null?Et.memoizedState=Ut=i:Ut=Ut.next=i,Ut}function Hn(){if(Rt===null){var i=Et.alternate;i=i!==null?i.memoizedState:null}else i=Rt.next;var s=Ut===null?Et.memoizedState:Ut.next;if(s!==null)Ut=s,Rt=i;else{if(i===null)throw Error(n(310));Rt=i,i={memoizedState:Rt.memoizedState,baseState:Rt.baseState,baseQueue:Rt.baseQueue,queue:Rt.queue,next:null},Ut===null?Et.memoizedState=Ut=i:Ut=Ut.next=i}return Ut}function Ga(i,s){return typeof s=="function"?s(i):s}function Bp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=Rt,g=f.baseQueue,b=l.pending;if(b!==null){if(g!==null){var w=g.next;g.next=b.next,b.next=w}f.baseQueue=g=b,l.pending=null}if(g!==null){b=g.next,f=f.baseState;var P=w=null,B=null,X=b;do{var ce=X.lane;if((no&ce)===ce)B!==null&&(B=B.next={lane:0,action:X.action,hasEagerState:X.hasEagerState,eagerState:X.eagerState,next:null}),f=X.hasEagerState?X.eagerState:i(f,X.action);else{var me={lane:ce,action:X.action,hasEagerState:X.hasEagerState,eagerState:X.eagerState,next:null};B===null?(P=B=me,w=f):B=B.next=me,Et.lanes|=ce,ro|=ce}X=X.next}while(X!==null&&X!==b);B===null?w=f:B.next=P,Zn(f,s.memoizedState)||(En=!0),s.memoizedState=f,s.baseState=w,s.baseQueue=B,l.lastRenderedState=f}if(i=l.interleaved,i!==null){g=i;do b=g.lane,Et.lanes|=b,ro|=b,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function Up(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=l.dispatch,g=l.pending,b=s.memoizedState;if(g!==null){l.pending=null;var w=g=g.next;do b=i(b,w.action),w=w.next;while(w!==g);Zn(b,s.memoizedState)||(En=!0),s.memoizedState=b,s.baseQueue===null&&(s.baseState=b),l.lastRenderedState=b}return[b,f]}function Mx(){}function Fx(i,s){var l=Et,f=Hn(),g=s(),b=!Zn(f.memoizedState,g);if(b&&(f.memoizedState=g,En=!0),f=f.queue,Hp(Hx.bind(null,l,f,i),[i]),f.getSnapshot!==s||b||Ut!==null&&Ut.memoizedState.tag&1){if(l.flags|=2048,Ka(9,Ux.bind(null,l,f,g,s),void 0,null),Ht===null)throw Error(n(349));(no&30)!==0||Bx(l,s,g)}return g}function Bx(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=Et.updateQueue,s===null?(s={lastEffect:null,stores:null},Et.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function Ux(i,s,l,f){s.value=l,s.getSnapshot=f,zx(s)&&jx(i)}function Hx(i,s,l){return l(function(){zx(s)&&jx(i)})}function zx(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!Zn(i,l)}catch(f){return!0}}function jx(i){var s=Fr(i,1);s!==null&&ir(s,i,1,-1)}function $x(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:Ga,lastRenderedState:i},s.queue=i,i=i.dispatch=i9.bind(null,Et,i),[s.memoizedState,i]}function Ka(i,s,l,f){return i={tag:i,create:s,destroy:l,deps:f,next:null},s=Et.updateQueue,s===null?(s={lastEffect:null,stores:null},Et.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 Vx(){return Hn().memoizedState}function hc(i,s,l,f){var g=_r();Et.flags|=i,g.memoizedState=Ka(1|s,l,void 0,f===void 0?null:f)}function pc(i,s,l,f){var g=Hn();f=f===void 0?null:f;var b=void 0;if(Rt!==null){var w=Rt.memoizedState;if(b=w.destroy,f!==null&&Dp(f,w.deps)){g.memoizedState=Ka(s,l,b,f);return}}Et.flags|=i,g.memoizedState=Ka(1|s,l,b,f)}function qx(i,s){return hc(8390656,8,i,s)}function Hp(i,s){return pc(2048,8,i,s)}function Yx(i,s){return pc(4,2,i,s)}function Wx(i,s){return pc(4,4,i,s)}function Gx(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 Kx(i,s,l){return l=l!=null?l.concat([i]):null,pc(4,4,Gx.bind(null,s,i),l)}function zp(){}function Qx(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Dp(s,f[1])?f[0]:(l.memoizedState=[i,s],i)}function Xx(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Dp(s,f[1])?f[0]:(i=i(),l.memoizedState=[i,s],i)}function Jx(i,s,l){return(no&21)===0?(i.baseState&&(i.baseState=!1,En=!0),i.memoizedState=l):(Zn(l,s)||(l=kT(),Et.lanes|=l,ro|=l,i.baseState=!0),s)}function n9(i,s){var l=nt;nt=l!==0&&4>l?l:4,i(!0);var f=Lp.transition;Lp.transition={};try{i(!1),s()}finally{nt=l,Lp.transition=f}}function Zx(){return Hn().memoizedState}function r9(i,s,l){var f=yi(i);if(l={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null},e2(i))t2(s,l);else if(l=Ix(i,s,l,f),l!==null){var g=on();ir(l,i,f,g),n2(l,s,f)}}function i9(i,s,l){var f=yi(i),g={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null};if(e2(i))t2(s,g);else{var b=i.alternate;if(i.lanes===0&&(b===null||b.lanes===0)&&(b=s.lastRenderedReducer,b!==null))try{var w=s.lastRenderedState,P=b(w,l);if(g.hasEagerState=!0,g.eagerState=P,Zn(P,w)){var B=s.interleaved;B===null?(g.next=g,kp(s)):(g.next=B.next,B.next=g),s.interleaved=g;return}}catch(X){}l=Ix(i,s,g,f),l!==null&&(g=on(),ir(l,i,f,g),n2(l,s,f))}}function e2(i){var s=i.alternate;return i===Et||s!==null&&s===Et}function t2(i,s){Ya=fc=!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,$h(i,l)}}var mc={readContext:Un,useCallback:Jt,useContext:Jt,useEffect:Jt,useImperativeHandle:Jt,useInsertionEffect:Jt,useLayoutEffect:Jt,useMemo:Jt,useReducer:Jt,useRef:Jt,useState:Jt,useDebugValue:Jt,useDeferredValue:Jt,useTransition:Jt,useMutableSource:Jt,useSyncExternalStore:Jt,useId:Jt,unstable_isNewReconciler:!1},o9={readContext:Un,useCallback:function(i,s){return _r().memoizedState=[i,s===void 0?null:s],i},useContext:Un,useEffect:qx,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,hc(4194308,4,Gx.bind(null,s,i),l)},useLayoutEffect:function(i,s){return hc(4194308,4,i,s)},useInsertionEffect:function(i,s){return hc(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=r9.bind(null,Et,i),[f.memoizedState,i]},useRef:function(i){var s=_r();return i={current:i},s.memoizedState=i},useState:$x,useDebugValue:zp,useDeferredValue:function(i){return _r().memoizedState=i},useTransition:function(){var i=$x(!1),s=i[0];return i=n9.bind(null,i[1]),_r().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var f=Et,g=_r();if(pt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Ht===null)throw Error(n(349));(no&30)!==0||Bx(f,s,l)}g.memoizedState=l;var b={value:l,getSnapshot:s};return g.queue=b,qx(Hx.bind(null,f,b,i),[i]),f.flags|=2048,Ka(9,Ux.bind(null,f,b,l,s),void 0,null),l},useId:function(){var i=_r(),s=Ht.identifierPrefix;if(pt){var l=Mr,f=Dr;l=(f&~(1<<32-Jn(f)-1)).toString(32)+l,s=":"+s+"R"+l,l=Wa++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=t9++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},s9={readContext:Un,useCallback:Qx,useContext:Un,useEffect:Hp,useImperativeHandle:Kx,useInsertionEffect:Yx,useLayoutEffect:Wx,useMemo:Xx,useReducer:Bp,useRef:Vx,useState:function(){return Bp(Ga)},useDebugValue:zp,useDeferredValue:function(i){var s=Hn();return Jx(s,Rt.memoizedState,i)},useTransition:function(){var i=Bp(Ga)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:Mx,useSyncExternalStore:Fx,useId:Zx,unstable_isNewReconciler:!1},a9={readContext:Un,useCallback:Qx,useContext:Un,useEffect:Hp,useImperativeHandle:Kx,useInsertionEffect:Yx,useLayoutEffect:Wx,useMemo:Xx,useReducer:Up,useRef:Vx,useState:function(){return Up(Ga)},useDebugValue:zp,useDeferredValue:function(i){var s=Hn();return Rt===null?s.memoizedState=i:Jx(s,Rt.memoizedState,i)},useTransition:function(){var i=Up(Ga)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:Mx,useSyncExternalStore:Fx,useId:Zx,unstable_isNewReconciler:!1};function tr(i,s){if(i&&i.defaultProps){s=C({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function jp(i,s,l,f){s=i.memoizedState,l=l(f,s),l=l==null?s:C({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var gc={isMounted:function(i){return(i=i._reactInternals)?Ki(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var f=on(),g=yi(i),b=Br(f,g);b.payload=s,l!=null&&(b.callback=l),s=pi(i,b,g),s!==null&&(ir(s,i,g,f),uc(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var f=on(),g=yi(i),b=Br(f,g);b.tag=1,b.payload=s,l!=null&&(b.callback=l),s=pi(i,b,g),s!==null&&(ir(s,i,g,f),uc(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=on(),f=yi(i),g=Br(l,f);g.tag=2,s!=null&&(g.callback=s),s=pi(i,g,f),s!==null&&(ir(s,i,f,l),uc(s,i,f))}};function r2(i,s,l,f,g,b,w){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(f,b,w):s.prototype&&s.prototype.isPureReactComponent?!Da(l,f)||!Da(g,b):!0}function i2(i,s,l){var f=!1,g=di,b=s.contextType;return typeof b=="object"&&b!==null?b=Un(b):(g=gn(s)?Xi:Xt.current,f=s.contextTypes,b=(f=f!=null)?as(i,g):di),s=new s(l,b),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=gc,i.stateNode=s,s._reactInternals=i,f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=b),s}function o2(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&&gc.enqueueReplaceState(s,s.state,null)}function $p(i,s,l,f){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},Np(i);var b=s.contextType;typeof b=="object"&&b!==null?g.context=Un(b):(b=gn(s)?Xi:Xt.current,g.context=as(i,b)),g.state=i.memoizedState,b=s.getDerivedStateFromProps,typeof b=="function"&&(jp(i,s,b,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&&gc.enqueueReplaceState(g,g.state,null),lc(i,l,g,f),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function ms(i,s){try{var l="",f=s;do l+=Se(f),f=f.return;while(f);var g=l}catch(b){g=`
19
+ `),w=g.length-1,P=b.length-1;1<=w&&0<=P&&g[w]!==b[P];)P--;for(;1<=w&&0<=P;w--,P--)if(g[w]!==b[P]){if(w!==1||P!==1)do if(w--,P--,0>P||g[w]!==b[P]){var F=`
20
+ `+g[w].replace(" at new "," at ");return i.displayName&&F.includes("<anonymous>")&&(F=F.replace("<anonymous>",i.displayName)),F}while(1<=w&&0<=P);break}}}finally{k=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?ne(i):""}function Se(i){switch(i.tag){case 5:return ne(i.type);case 16:return ne("Lazy");case 13:return ne("Suspense");case 19:return ne("SuspenseList");case 0:case 2:case 15:return i=me(i.type,!1),i;case 11:return i=me(i.type.render,!1),i;case 1:return i=me(i.type,!0),i;default:return""}}function Ae(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 K:return"Fragment";case D:return"Portal";case Te:return"Profiler";case fe:return"StrictMode";case ee:return"Suspense";case re:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case X:return(i.displayName||"Context")+".Consumer";case z:return(i._context.displayName||"Context")+".Provider";case se:var s=i.render;return i=i.displayName,i||(i=s.displayName||s.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case de:return s=i.displayName||null,s!==null?s:Ae(i.type)||"Memo";case Oe:s=i._payload,i=i._init;try{return Ae(i(s))}catch(l){}}return null}function Be(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 Ae(s);case 8:return s===fe?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function ve(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function qe(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function ut(i){var s=qe(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,b=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return g.call(this)},set:function(w){f=""+w,b.call(this,w)}}),Object.defineProperty(i,s,{enumerable:l.enumerable}),{getValue:function(){return f},setValue:function(w){f=""+w},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function pn(i){i._valueTracker||(i._valueTracker=ut(i))}function Wi(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var l=s.getValue(),f="";return i&&(f=qe(i)?i.checked?"true":"false":i.value),i=f,i!==l?(s.setValue(i),!0):!1}function Zr(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 C({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function Ea(i,s){var l=s.defaultValue==null?"":s.defaultValue,f=s.checked!=null?s.checked:s.defaultChecked;l=ve(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 ya(i,s){s=s.checked,s!=null&&R(i,"checked",s,!1)}function Go(i,s){ya(i,s);var l=ve(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")?Ko(i,s.type,l):s.hasOwnProperty("defaultValue")&&Ko(i,s.type,ve(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function Al(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 Ko(i,s,l){(s!=="number"||Zr(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var ei=Array.isArray;function ti(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=""+ve(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 ba(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return C({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function Cl(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(ei(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:ve(l)}}function kl(i,s){var l=ve(s.value),f=ve(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 Nl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function ie(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 xe(i,s){return i==null||i==="http://www.w3.org/1999/xhtml"?ie(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Ue,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(Ue=Ue||document.createElement("div"),Ue.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=Ue.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function Xe(i,s){if(s){var l=i.firstChild;if(l&&l===i.lastChild&&l.nodeType===3){l.nodeValue=s;return}}i.textContent=s}var jt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Rr=["Webkit","ms","Moz","O"];Object.keys(jt).forEach(function(i){Rr.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),jt[s]=jt[i]})});function Mn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||jt.hasOwnProperty(i)&&jt[i]?(""+s).trim():s+"px"}function ni(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 Gi=C({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 $t(i,s){if(s){if(Gi[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 br(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 Sn=null;function Dh(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var Mh=null,Qo=null,Xo=null;function pT(i){if(i=za(i)){if(typeof Mh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=Jl(s),Mh(i.stateNode,i.type,s))}}function mT(i){Qo?Xo?Xo.push(i):Xo=[i]:Qo=i}function gT(){if(Qo){var i=Qo,s=Xo;if(Xo=Qo=null,pT(i),s)for(i=0;i<s.length;i++)pT(s[i])}}function ET(i,s){return i(s)}function yT(){}var Fh=!1;function bT(i,s,l){if(Fh)return i(s,l);Fh=!0;try{return ET(i,s,l)}finally{Fh=!1,(Qo!==null||Xo!==null)&&(yT(),gT())}}function Ta(i,s){var l=i.stateNode;if(l===null)return null;var f=Jl(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 Bh=!1;if(c)try{var xa={};Object.defineProperty(xa,"passive",{get:function(){Bh=!0}}),window.addEventListener("test",xa,xa),window.removeEventListener("test",xa,xa)}catch(i){Bh=!1}function H8(i,s,l,f,g,b,w,P,F){var J=Array.prototype.slice.call(arguments,3);try{s.apply(l,J)}catch(ce){this.onError(ce)}}var wa=!1,Ol=null,Il=!1,Uh=null,z8={onError:function(i){wa=!0,Ol=i}};function j8(i,s,l,f,g,b,w,P,F){wa=!1,Ol=null,H8.apply(z8,arguments)}function $8(i,s,l,f,g,b,w,P,F){if(j8.apply(this,arguments),wa){if(wa){var J=Ol;wa=!1,Ol=null}else throw Error(n(198));Il||(Il=!0,Uh=J)}}function Ki(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 TT(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 xT(i){if(Ki(i)!==i)throw Error(n(188))}function V8(i){var s=i.alternate;if(!s){if(s=Ki(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 b=g.alternate;if(b===null){if(f=g.return,f!==null){l=f;continue}break}if(g.child===b.child){for(b=g.child;b;){if(b===l)return xT(g),i;if(b===f)return xT(g),s;b=b.sibling}throw Error(n(188))}if(l.return!==f.return)l=g,f=b;else{for(var w=!1,P=g.child;P;){if(P===l){w=!0,l=g,f=b;break}if(P===f){w=!0,f=g,l=b;break}P=P.sibling}if(!w){for(P=b.child;P;){if(P===l){w=!0,l=b,f=g;break}if(P===f){w=!0,f=b,l=g;break}P=P.sibling}if(!w)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 wT(i){return i=V8(i),i!==null?_T(i):null}function _T(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=_T(i);if(s!==null)return s;i=i.sibling}return null}var vT=t.unstable_scheduleCallback,ST=t.unstable_cancelCallback,q8=t.unstable_shouldYield,Y8=t.unstable_requestPaint,_t=t.unstable_now,W8=t.unstable_getCurrentPriorityLevel,Hh=t.unstable_ImmediatePriority,AT=t.unstable_UserBlockingPriority,Rl=t.unstable_NormalPriority,G8=t.unstable_LowPriority,CT=t.unstable_IdlePriority,Pl=null,Tr=null;function K8(i){if(Tr&&typeof Tr.onCommitFiberRoot=="function")try{Tr.onCommitFiberRoot(Pl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var Jn=Math.clz32?Math.clz32:J8,Q8=Math.log,X8=Math.LN2;function J8(i){return i>>>=0,i===0?32:31-(Q8(i)/X8|0)|0}var Ll=64,Dl=4194304;function _a(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 Ml(i,s){var l=i.pendingLanes;if(l===0)return 0;var f=0,g=i.suspendedLanes,b=i.pingedLanes,w=l&268435455;if(w!==0){var P=w&~g;P!==0?f=_a(P):(b&=w,b!==0&&(f=_a(b)))}else w=l&~g,w!==0?f=_a(w):b!==0&&(f=_a(b));if(f===0)return 0;if(s!==0&&s!==f&&(s&g)===0&&(g=f&-f,b=s&-s,g>=b||g===16&&(b&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 Z8(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 eM(i,s){for(var l=i.suspendedLanes,f=i.pingedLanes,g=i.expirationTimes,b=i.pendingLanes;0<b;){var w=31-Jn(b),P=1<<w,F=g[w];F===-1?((P&l)===0||(P&f)!==0)&&(g[w]=Z8(P,s)):F<=s&&(i.expiredLanes|=P),b&=~P}}function zh(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function kT(){var i=Ll;return Ll<<=1,(Ll&4194240)===0&&(Ll=64),i}function jh(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function va(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 tM(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),b=1<<g;s[g]=0,f[g]=-1,i[g]=-1,l&=~b}}function $h(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 NT(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var OT,Vh,IT,RT,PT,qh=!1,Fl=[],ri=null,ii=null,oi=null,Sa=new Map,Aa=new Map,si=[],nM="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 LT(i,s){switch(i){case"focusin":case"focusout":ri=null;break;case"dragenter":case"dragleave":ii=null;break;case"mouseover":case"mouseout":oi=null;break;case"pointerover":case"pointerout":Sa.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":Aa.delete(s.pointerId)}}function Ca(i,s,l,f,g,b){return i===null||i.nativeEvent!==b?(i={blockedOn:s,domEventName:l,eventSystemFlags:f,nativeEvent:b,targetContainers:[g]},s!==null&&(s=za(s),s!==null&&Vh(s)),i):(i.eventSystemFlags|=f,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function rM(i,s,l,f,g){switch(s){case"focusin":return ri=Ca(ri,i,s,l,f,g),!0;case"dragenter":return ii=Ca(ii,i,s,l,f,g),!0;case"mouseover":return oi=Ca(oi,i,s,l,f,g),!0;case"pointerover":var b=g.pointerId;return Sa.set(b,Ca(Sa.get(b)||null,i,s,l,f,g)),!0;case"gotpointercapture":return b=g.pointerId,Aa.set(b,Ca(Aa.get(b)||null,i,s,l,f,g)),!0}return!1}function DT(i){var s=Qi(i.target);if(s!==null){var l=Ki(s);if(l!==null){if(s=l.tag,s===13){if(s=TT(l),s!==null){i.blockedOn=s,PT(i.priority,function(){IT(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 Bl(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=Wh(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var f=new l.constructor(l.type,l);Sn=f,l.target.dispatchEvent(f),Sn=null}else return s=za(l),s!==null&&Vh(s),i.blockedOn=l,!1;s.shift()}return!0}function MT(i,s,l){Bl(i)&&l.delete(s)}function iM(){qh=!1,ri!==null&&Bl(ri)&&(ri=null),ii!==null&&Bl(ii)&&(ii=null),oi!==null&&Bl(oi)&&(oi=null),Sa.forEach(MT),Aa.forEach(MT)}function ka(i,s){i.blockedOn===s&&(i.blockedOn=null,qh||(qh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,iM)))}function Na(i){function s(g){return ka(g,i)}if(0<Fl.length){ka(Fl[0],i);for(var l=1;l<Fl.length;l++){var f=Fl[l];f.blockedOn===i&&(f.blockedOn=null)}}for(ri!==null&&ka(ri,i),ii!==null&&ka(ii,i),oi!==null&&ka(oi,i),Sa.forEach(s),Aa.forEach(s),l=0;l<si.length;l++)f=si[l],f.blockedOn===i&&(f.blockedOn=null);for(;0<si.length&&(l=si[0],l.blockedOn===null);)DT(l),l.blockedOn===null&&si.shift()}var Jo=H.ReactCurrentBatchConfig,Ul=!0;function oM(i,s,l,f){var g=nt,b=Jo.transition;Jo.transition=null;try{nt=1,Yh(i,s,l,f)}finally{nt=g,Jo.transition=b}}function sM(i,s,l,f){var g=nt,b=Jo.transition;Jo.transition=null;try{nt=4,Yh(i,s,l,f)}finally{nt=g,Jo.transition=b}}function Yh(i,s,l,f){if(Ul){var g=Wh(i,s,l,f);if(g===null)cp(i,s,f,Hl,l),LT(i,f);else if(rM(g,i,s,l,f))f.stopPropagation();else if(LT(i,f),s&4&&-1<nM.indexOf(i)){for(;g!==null;){var b=za(g);if(b!==null&&OT(b),b=Wh(i,s,l,f),b===null&&cp(i,s,f,Hl,l),b===g)break;g=b}g!==null&&f.stopPropagation()}else cp(i,s,f,null,l)}}var Hl=null;function Wh(i,s,l,f){if(Hl=null,i=Dh(f),i=Qi(i),i!==null)if(s=Ki(i),s===null)i=null;else if(l=s.tag,l===13){if(i=TT(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 Hl=i,null}function FT(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(W8()){case Hh:return 1;case AT:return 4;case Rl:case G8:return 16;case CT:return 536870912;default:return 16}default:return 16}}var ai=null,Gh=null,zl=null;function BT(){if(zl)return zl;var i,s=Gh,l=s.length,f,g="value"in ai?ai.value:ai.textContent,b=g.length;for(i=0;i<l&&s[i]===g[i];i++);var w=l-i;for(f=1;f<=w&&s[l-f]===g[b-f];f++);return zl=g.slice(i,1<f?1-f:void 0)}function jl(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 $l(){return!0}function UT(){return!1}function An(i){function s(l,f,g,b,w){this._reactName=l,this._targetInst=g,this.type=f,this.nativeEvent=b,this.target=w,this.currentTarget=null;for(var P in i)i.hasOwnProperty(P)&&(l=i[P],this[P]=l?l(b):b[P]);return this.isDefaultPrevented=(b.defaultPrevented!=null?b.defaultPrevented:b.returnValue===!1)?$l:UT,this.isPropagationStopped=UT,this}return C(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=$l)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=$l)},persist:function(){},isPersistent:$l}),s}var Zo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Kh=An(Zo),Oa=C({},Zo,{view:0,detail:0}),aM=An(Oa),Qh,Xh,Ia,Vl=C({},Oa,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Zh,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!==Ia&&(Ia&&i.type==="mousemove"?(Qh=i.screenX-Ia.screenX,Xh=i.screenY-Ia.screenY):Xh=Qh=0,Ia=i),Qh)},movementY:function(i){return"movementY"in i?i.movementY:Xh}}),HT=An(Vl),uM=C({},Vl,{dataTransfer:0}),lM=An(uM),cM=C({},Oa,{relatedTarget:0}),Jh=An(cM),dM=C({},Zo,{animationName:0,elapsedTime:0,pseudoElement:0}),fM=An(dM),hM=C({},Zo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),pM=An(hM),mM=C({},Zo,{data:0}),zT=An(mM),gM={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},EM={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"},yM={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function bM(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=yM[i])?!!s[i]:!1}function Zh(){return bM}var TM=C({},Oa,{key:function(i){if(i.key){var s=gM[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=jl(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?EM[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Zh,charCode:function(i){return i.type==="keypress"?jl(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?jl(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),xM=An(TM),wM=C({},Vl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),jT=An(wM),_M=C({},Oa,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Zh}),vM=An(_M),SM=C({},Zo,{propertyName:0,elapsedTime:0,pseudoElement:0}),AM=An(SM),CM=C({},Vl,{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}),kM=An(CM),NM=[9,13,27,32],ep=c&&"CompositionEvent"in window,Ra=null;c&&"documentMode"in document&&(Ra=document.documentMode);var OM=c&&"TextEvent"in window&&!Ra,$T=c&&(!ep||Ra&&8<Ra&&11>=Ra),VT=" ",qT=!1;function YT(i,s){switch(i){case"keyup":return NM.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function WT(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var es=!1;function IM(i,s){switch(i){case"compositionend":return WT(s);case"keypress":return s.which!==32?null:(qT=!0,VT);case"textInput":return i=s.data,i===VT&&qT?null:i;default:return null}}function RM(i,s){if(es)return i==="compositionend"||!ep&&YT(i,s)?(i=BT(),zl=Gh=ai=null,es=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return $T&&s.locale!=="ko"?null:s.data;default:return null}}var PM={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 GT(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!PM[i.type]:s==="textarea"}function KT(i,s,l,f){mT(f),s=Kl(s,"onChange"),0<s.length&&(l=new Kh("onChange","change",null,l,f),i.push({event:l,listeners:s}))}var Pa=null,La=null;function LM(i){hx(i,0)}function ql(i){var s=os(i);if(Wi(s))return i}function DM(i,s){if(i==="change")return s}var QT=!1;if(c){var tp;if(c){var np="oninput"in document;if(!np){var XT=document.createElement("div");XT.setAttribute("oninput","return;"),np=typeof XT.oninput=="function"}tp=np}else tp=!1;QT=tp&&(!document.documentMode||9<document.documentMode)}function JT(){Pa&&(Pa.detachEvent("onpropertychange",ZT),La=Pa=null)}function ZT(i){if(i.propertyName==="value"&&ql(La)){var s=[];KT(s,La,i,Dh(i)),bT(LM,s)}}function MM(i,s,l){i==="focusin"?(JT(),Pa=s,La=l,Pa.attachEvent("onpropertychange",ZT)):i==="focusout"&&JT()}function FM(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return ql(La)}function BM(i,s){if(i==="click")return ql(s)}function UM(i,s){if(i==="input"||i==="change")return ql(s)}function HM(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var Zn=typeof Object.is=="function"?Object.is:HM;function Da(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 ex(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function tx(i,s){var l=ex(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=ex(l)}}function nx(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?nx(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function rx(){for(var i=window,s=Zr();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=Zr(i.document)}return s}function rp(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 zM(i){var s=rx(),l=i.focusedElem,f=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&nx(l.ownerDocument.documentElement,l)){if(f!==null&&rp(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,b=Math.min(f.start,g);f=f.end===void 0?b:Math.min(f.end,g),!i.extend&&b>f&&(g=f,f=b,b=g),g=tx(l,b);var w=tx(l,f);g&&w&&(i.rangeCount!==1||i.anchorNode!==g.node||i.anchorOffset!==g.offset||i.focusNode!==w.node||i.focusOffset!==w.offset)&&(s=s.createRange(),s.setStart(g.node,g.offset),i.removeAllRanges(),b>f?(i.addRange(s),i.extend(w.node,w.offset)):(s.setEnd(w.node,w.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 jM=c&&"documentMode"in document&&11>=document.documentMode,ts=null,ip=null,Ma=null,op=!1;function ix(i,s,l){var f=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;op||ts==null||ts!==Zr(f)||(f=ts,"selectionStart"in f&&rp(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}),Ma&&Da(Ma,f)||(Ma=f,f=Kl(ip,"onSelect"),0<f.length&&(s=new Kh("onSelect","select",null,s,l),i.push({event:s,listeners:f}),s.target=ts)))}function Yl(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var ns={animationend:Yl("Animation","AnimationEnd"),animationiteration:Yl("Animation","AnimationIteration"),animationstart:Yl("Animation","AnimationStart"),transitionend:Yl("Transition","TransitionEnd")},sp={},ox={};c&&(ox=document.createElement("div").style,"AnimationEvent"in window||(delete ns.animationend.animation,delete ns.animationiteration.animation,delete ns.animationstart.animation),"TransitionEvent"in window||delete ns.transitionend.transition);function Wl(i){if(sp[i])return sp[i];if(!ns[i])return i;var s=ns[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in ox)return sp[i]=s[l];return i}var sx=Wl("animationend"),ax=Wl("animationiteration"),ux=Wl("animationstart"),lx=Wl("transitionend"),cx=new Map,dx="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 ui(i,s){cx.set(i,s),a(s,[i])}for(var ap=0;ap<dx.length;ap++){var up=dx[ap],$M=up.toLowerCase(),VM=up[0].toUpperCase()+up.slice(1);ui($M,"on"+VM)}ui(sx,"onAnimationEnd"),ui(ax,"onAnimationIteration"),ui(ux,"onAnimationStart"),ui("dblclick","onDoubleClick"),ui("focusin","onFocus"),ui("focusout","onBlur"),ui(lx,"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 Fa="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(" "),qM=new Set("cancel close invalid load scroll toggle".split(" ").concat(Fa));function fx(i,s,l){var f=i.type||"unknown-event";i.currentTarget=l,$8(f,s,void 0,i),i.currentTarget=null}function hx(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 b=void 0;if(s)for(var w=f.length-1;0<=w;w--){var P=f[w],F=P.instance,J=P.currentTarget;if(P=P.listener,F!==b&&g.isPropagationStopped())break e;fx(g,P,J),b=F}else for(w=0;w<f.length;w++){if(P=f[w],F=P.instance,J=P.currentTarget,P=P.listener,F!==b&&g.isPropagationStopped())break e;fx(g,P,J),b=F}}}if(Il)throw i=Uh,Il=!1,Uh=null,i}function lt(i,s){var l=s[gp];l===void 0&&(l=s[gp]=new Set);var f=i+"__bubble";l.has(f)||(px(s,i,2,!1),l.add(f))}function lp(i,s,l){var f=0;s&&(f|=4),px(l,i,f,s)}var Gl="_reactListening"+Math.random().toString(36).slice(2);function Ba(i){if(!i[Gl]){i[Gl]=!0,r.forEach(function(l){l!=="selectionchange"&&(qM.has(l)||lp(l,!1,i),lp(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[Gl]||(s[Gl]=!0,lp("selectionchange",!1,s))}}function px(i,s,l,f){switch(FT(s)){case 1:var g=oM;break;case 4:g=sM;break;default:g=Yh}l=g.bind(null,s,l,i),g=void 0,!Bh||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 cp(i,s,l,f,g){var b=f;if((s&1)===0&&(s&2)===0&&f!==null)e:for(;;){if(f===null)return;var w=f.tag;if(w===3||w===4){var P=f.stateNode.containerInfo;if(P===g||P.nodeType===8&&P.parentNode===g)break;if(w===4)for(w=f.return;w!==null;){var F=w.tag;if((F===3||F===4)&&(F=w.stateNode.containerInfo,F===g||F.nodeType===8&&F.parentNode===g))return;w=w.return}for(;P!==null;){if(w=Qi(P),w===null)return;if(F=w.tag,F===5||F===6){f=b=w;continue e}P=P.parentNode}}f=f.return}bT(function(){var J=b,ce=Dh(l),ge=[];e:{var ue=cx.get(i);if(ue!==void 0){var we=Kh,Ce=i;switch(i){case"keypress":if(jl(l)===0)break e;case"keydown":case"keyup":we=xM;break;case"focusin":Ce="focus",we=Jh;break;case"focusout":Ce="blur",we=Jh;break;case"beforeblur":case"afterblur":we=Jh;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":we=HT;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":we=lM;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":we=vM;break;case sx:case ax:case ux:we=fM;break;case lx:we=AM;break;case"scroll":we=aM;break;case"wheel":we=kM;break;case"copy":case"cut":case"paste":we=pM;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":we=jT}var Ne=(s&4)!==0,vt=!Ne&&i==="scroll",q=Ne?ue!==null?ue+"Capture":null:ue;Ne=[];for(var j=J,G;j!==null;){G=j;var be=G.stateNode;if(G.tag===5&&be!==null&&(G=be,q!==null&&(be=Ta(j,q),be!=null&&Ne.push(Ua(j,be,G)))),vt)break;j=j.return}0<Ne.length&&(ue=new we(ue,Ce,null,l,ce),ge.push({event:ue,listeners:Ne}))}}if((s&7)===0){e:{if(ue=i==="mouseover"||i==="pointerover",we=i==="mouseout"||i==="pointerout",ue&&l!==Sn&&(Ce=l.relatedTarget||l.fromElement)&&(Qi(Ce)||Ce[Pr]))break e;if((we||ue)&&(ue=ce.window===ce?ce:(ue=ce.ownerDocument)?ue.defaultView||ue.parentWindow:window,we?(Ce=l.relatedTarget||l.toElement,we=J,Ce=Ce?Qi(Ce):null,Ce!==null&&(vt=Ki(Ce),Ce!==vt||Ce.tag!==5&&Ce.tag!==6)&&(Ce=null)):(we=null,Ce=J),we!==Ce)){if(Ne=HT,be="onMouseLeave",q="onMouseEnter",j="mouse",(i==="pointerout"||i==="pointerover")&&(Ne=jT,be="onPointerLeave",q="onPointerEnter",j="pointer"),vt=we==null?ue:os(we),G=Ce==null?ue:os(Ce),ue=new Ne(be,j+"leave",we,l,ce),ue.target=vt,ue.relatedTarget=G,be=null,Qi(ce)===J&&(Ne=new Ne(q,j+"enter",Ce,l,ce),Ne.target=G,Ne.relatedTarget=vt,be=Ne),vt=be,we&&Ce)t:{for(Ne=we,q=Ce,j=0,G=Ne;G;G=rs(G))j++;for(G=0,be=q;be;be=rs(be))G++;for(;0<j-G;)Ne=rs(Ne),j--;for(;0<G-j;)q=rs(q),G--;for(;j--;){if(Ne===q||q!==null&&Ne===q.alternate)break t;Ne=rs(Ne),q=rs(q)}Ne=null}else Ne=null;we!==null&&mx(ge,ue,we,Ne,!1),Ce!==null&&vt!==null&&mx(ge,vt,Ce,Ne,!0)}}e:{if(ue=J?os(J):window,we=ue.nodeName&&ue.nodeName.toLowerCase(),we==="select"||we==="input"&&ue.type==="file")var Ie=DM;else if(GT(ue))if(QT)Ie=UM;else{Ie=FM;var De=MM}else(we=ue.nodeName)&&we.toLowerCase()==="input"&&(ue.type==="checkbox"||ue.type==="radio")&&(Ie=BM);if(Ie&&(Ie=Ie(i,J))){KT(ge,Ie,l,ce);break e}De&&De(i,ue,J),i==="focusout"&&(De=ue._wrapperState)&&De.controlled&&ue.type==="number"&&Ko(ue,"number",ue.value)}switch(De=J?os(J):window,i){case"focusin":(GT(De)||De.contentEditable==="true")&&(ts=De,ip=J,Ma=null);break;case"focusout":Ma=ip=ts=null;break;case"mousedown":op=!0;break;case"contextmenu":case"mouseup":case"dragend":op=!1,ix(ge,l,ce);break;case"selectionchange":if(jM)break;case"keydown":case"keyup":ix(ge,l,ce)}var Me;if(ep)e:{switch(i){case"compositionstart":var He="onCompositionStart";break e;case"compositionend":He="onCompositionEnd";break e;case"compositionupdate":He="onCompositionUpdate";break e}He=void 0}else es?YT(i,l)&&(He="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(He="onCompositionStart");He&&($T&&l.locale!=="ko"&&(es||He!=="onCompositionStart"?He==="onCompositionEnd"&&es&&(Me=BT()):(ai=ce,Gh="value"in ai?ai.value:ai.textContent,es=!0)),De=Kl(J,He),0<De.length&&(He=new zT(He,i,null,l,ce),ge.push({event:He,listeners:De}),Me?He.data=Me:(Me=WT(l),Me!==null&&(He.data=Me)))),(Me=OM?IM(i,l):RM(i,l))&&(J=Kl(J,"onBeforeInput"),0<J.length&&(ce=new zT("onBeforeInput","beforeinput",null,l,ce),ge.push({event:ce,listeners:J}),ce.data=Me))}hx(ge,s)})}function Ua(i,s,l){return{instance:i,listener:s,currentTarget:l}}function Kl(i,s){for(var l=s+"Capture",f=[];i!==null;){var g=i,b=g.stateNode;g.tag===5&&b!==null&&(g=b,b=Ta(i,l),b!=null&&f.unshift(Ua(i,b,g)),b=Ta(i,s),b!=null&&f.push(Ua(i,b,g))),i=i.return}return f}function rs(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function mx(i,s,l,f,g){for(var b=s._reactName,w=[];l!==null&&l!==f;){var P=l,F=P.alternate,J=P.stateNode;if(F!==null&&F===f)break;P.tag===5&&J!==null&&(P=J,g?(F=Ta(l,b),F!=null&&w.unshift(Ua(l,F,P))):g||(F=Ta(l,b),F!=null&&w.push(Ua(l,F,P)))),l=l.return}w.length!==0&&i.push({event:s,listeners:w})}var YM=/\r\n?/g,WM=/\u0000|\uFFFD/g;function gx(i){return(typeof i=="string"?i:""+i).replace(YM,`
21
+ `).replace(WM,"")}function Ql(i,s,l){if(s=gx(s),gx(i)!==s&&l)throw Error(n(425))}function Xl(){}var dp=null,fp=null;function hp(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 pp=typeof setTimeout=="function"?setTimeout:void 0,GM=typeof clearTimeout=="function"?clearTimeout:void 0,Ex=typeof Promise=="function"?Promise:void 0,KM=typeof queueMicrotask=="function"?queueMicrotask:typeof Ex!="undefined"?function(i){return Ex.resolve(null).then(i).catch(QM)}:pp;function QM(i){setTimeout(function(){throw i})}function mp(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),Na(s);return}f--}else l!=="$"&&l!=="$?"&&l!=="$!"||f++;l=g}while(l);Na(s)}function li(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 yx(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 is=Math.random().toString(36).slice(2),xr="__reactFiber$"+is,Ha="__reactProps$"+is,Pr="__reactContainer$"+is,gp="__reactEvents$"+is,XM="__reactListeners$"+is,JM="__reactHandles$"+is;function Qi(i){var s=i[xr];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Pr]||l[xr]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=yx(i);i!==null;){if(l=i[xr])return l;i=yx(i)}return s}i=l,l=i.parentNode}return null}function za(i){return i=i[xr]||i[Pr],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function os(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function Jl(i){return i[Ha]||null}var Ep=[],ss=-1;function ci(i){return{current:i}}function ct(i){0>ss||(i.current=Ep[ss],Ep[ss]=null,ss--)}function at(i,s){ss++,Ep[ss]=i.current,i.current=s}var di={},Xt=ci(di),mn=ci(!1),Xi=di;function as(i,s){var l=i.type.contextTypes;if(!l)return di;var f=i.stateNode;if(f&&f.__reactInternalMemoizedUnmaskedChildContext===s)return f.__reactInternalMemoizedMaskedChildContext;var g={},b;for(b in l)g[b]=s[b];return f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function gn(i){return i=i.childContextTypes,i!=null}function Zl(){ct(mn),ct(Xt)}function bx(i,s,l){if(Xt.current!==di)throw Error(n(168));at(Xt,s),at(mn,l)}function Tx(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,Be(i)||"Unknown",g));return C({},l,f)}function ec(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||di,Xi=Xt.current,at(Xt,i),at(mn,mn.current),!0}function xx(i,s,l){var f=i.stateNode;if(!f)throw Error(n(169));l?(i=Tx(i,s,Xi),f.__reactInternalMemoizedMergedChildContext=i,ct(mn),ct(Xt),at(Xt,i)):ct(mn),at(mn,l)}var Lr=null,tc=!1,yp=!1;function wx(i){Lr===null?Lr=[i]:Lr.push(i)}function ZM(i){tc=!0,wx(i)}function fi(){if(!yp&&Lr!==null){yp=!0;var i=0,s=nt;try{var l=Lr;for(nt=1;i<l.length;i++){var f=l[i];do f=f(!0);while(f!==null)}Lr=null,tc=!1}catch(g){throw Lr!==null&&(Lr=Lr.slice(i+1)),vT(Hh,fi),g}finally{nt=s,yp=!1}}return null}var us=[],ls=0,nc=null,rc=0,Fn=[],Bn=0,Ji=null,Dr=1,Mr="";function Zi(i,s){us[ls++]=rc,us[ls++]=nc,nc=i,rc=s}function _x(i,s,l){Fn[Bn++]=Dr,Fn[Bn++]=Mr,Fn[Bn++]=Ji,Ji=i;var f=Dr;i=Mr;var g=32-Jn(f)-1;f&=~(1<<g),l+=1;var b=32-Jn(s)+g;if(30<b){var w=g-g%5;b=(f&(1<<w)-1).toString(32),f>>=w,g-=w,Dr=1<<32-Jn(s)+g|l<<g|f,Mr=b+i}else Dr=1<<b|l<<g|f,Mr=i}function bp(i){i.return!==null&&(Zi(i,1),_x(i,1,0))}function Tp(i){for(;i===nc;)nc=us[--ls],us[ls]=null,rc=us[--ls],us[ls]=null;for(;i===Ji;)Ji=Fn[--Bn],Fn[Bn]=null,Mr=Fn[--Bn],Fn[Bn]=null,Dr=Fn[--Bn],Fn[Bn]=null}var Cn=null,kn=null,pt=!1,er=null;function vx(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 Sx(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=li(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=Ji!==null?{id:Dr,overflow:Mr}: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 xp(i){return(i.mode&1)!==0&&(i.flags&128)===0}function wp(i){if(pt){var s=kn;if(s){var l=s;if(!Sx(i,s)){if(xp(i))throw Error(n(418));s=li(l.nextSibling);var f=Cn;s&&Sx(i,s)?vx(f,l):(i.flags=i.flags&-4097|2,pt=!1,Cn=i)}}else{if(xp(i))throw Error(n(418));i.flags=i.flags&-4097|2,pt=!1,Cn=i}}}function Ax(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Cn=i}function ic(i){if(i!==Cn)return!1;if(!pt)return Ax(i),pt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!hp(i.type,i.memoizedProps)),s&&(s=kn)){if(xp(i))throw Cx(),Error(n(418));for(;s;)vx(i,s),s=li(s.nextSibling)}if(Ax(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=li(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}kn=null}}else kn=Cn?li(i.stateNode.nextSibling):null;return!0}function Cx(){for(var i=kn;i;)i=li(i.nextSibling)}function cs(){kn=Cn=null,pt=!1}function _p(i){er===null?er=[i]:er.push(i)}var e9=H.ReactCurrentBatchConfig;function ja(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,b=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===b?s.ref:(s=function(w){var P=g.refs;w===null?delete P[b]:P[b]=w},s._stringRef=b,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function oc(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function kx(i){var s=i._init;return s(i._payload)}function Nx(i){function s(q,j){if(i){var G=q.deletions;G===null?(q.deletions=[j],q.flags|=16):G.push(j)}}function l(q,j){if(!i)return null;for(;j!==null;)s(q,j),j=j.sibling;return null}function f(q,j){for(q=new Map;j!==null;)j.key!==null?q.set(j.key,j):q.set(j.index,j),j=j.sibling;return q}function g(q,j){return q=Ti(q,j),q.index=0,q.sibling=null,q}function b(q,j,G){return q.index=G,i?(G=q.alternate,G!==null?(G=G.index,G<j?(q.flags|=2,j):G):(q.flags|=2,j)):(q.flags|=1048576,j)}function w(q){return i&&q.alternate===null&&(q.flags|=2),q}function P(q,j,G,be){return j===null||j.tag!==6?(j=pm(G,q.mode,be),j.return=q,j):(j=g(j,G),j.return=q,j)}function F(q,j,G,be){var Ie=G.type;return Ie===K?ce(q,j,G.props.children,be,G.key):j!==null&&(j.elementType===Ie||typeof Ie=="object"&&Ie!==null&&Ie.$$typeof===Oe&&kx(Ie)===j.type)?(be=g(j,G.props),be.ref=ja(q,j,G),be.return=q,be):(be=Nc(G.type,G.key,G.props,null,q.mode,be),be.ref=ja(q,j,G),be.return=q,be)}function J(q,j,G,be){return j===null||j.tag!==4||j.stateNode.containerInfo!==G.containerInfo||j.stateNode.implementation!==G.implementation?(j=mm(G,q.mode,be),j.return=q,j):(j=g(j,G.children||[]),j.return=q,j)}function ce(q,j,G,be,Ie){return j===null||j.tag!==7?(j=ao(G,q.mode,be,Ie),j.return=q,j):(j=g(j,G),j.return=q,j)}function ge(q,j,G){if(typeof j=="string"&&j!==""||typeof j=="number")return j=pm(""+j,q.mode,G),j.return=q,j;if(typeof j=="object"&&j!==null){switch(j.$$typeof){case W:return G=Nc(j.type,j.key,j.props,null,q.mode,G),G.ref=ja(q,null,j),G.return=q,G;case D:return j=mm(j,q.mode,G),j.return=q,j;case Oe:var be=j._init;return ge(q,be(j._payload),G)}if(ei(j)||oe(j))return j=ao(j,q.mode,G,null),j.return=q,j;oc(q,j)}return null}function ue(q,j,G,be){var Ie=j!==null?j.key:null;if(typeof G=="string"&&G!==""||typeof G=="number")return Ie!==null?null:P(q,j,""+G,be);if(typeof G=="object"&&G!==null){switch(G.$$typeof){case W:return G.key===Ie?F(q,j,G,be):null;case D:return G.key===Ie?J(q,j,G,be):null;case Oe:return Ie=G._init,ue(q,j,Ie(G._payload),be)}if(ei(G)||oe(G))return Ie!==null?null:ce(q,j,G,be,null);oc(q,G)}return null}function we(q,j,G,be,Ie){if(typeof be=="string"&&be!==""||typeof be=="number")return q=q.get(G)||null,P(j,q,""+be,Ie);if(typeof be=="object"&&be!==null){switch(be.$$typeof){case W:return q=q.get(be.key===null?G:be.key)||null,F(j,q,be,Ie);case D:return q=q.get(be.key===null?G:be.key)||null,J(j,q,be,Ie);case Oe:var De=be._init;return we(q,j,G,De(be._payload),Ie)}if(ei(be)||oe(be))return q=q.get(G)||null,ce(j,q,be,Ie,null);oc(j,be)}return null}function Ce(q,j,G,be){for(var Ie=null,De=null,Me=j,He=j=0,zt=null;Me!==null&&He<G.length;He++){Me.index>He?(zt=Me,Me=null):zt=Me.sibling;var et=ue(q,Me,G[He],be);if(et===null){Me===null&&(Me=zt);break}i&&Me&&et.alternate===null&&s(q,Me),j=b(et,j,He),De===null?Ie=et:De.sibling=et,De=et,Me=zt}if(He===G.length)return l(q,Me),pt&&Zi(q,He),Ie;if(Me===null){for(;He<G.length;He++)Me=ge(q,G[He],be),Me!==null&&(j=b(Me,j,He),De===null?Ie=Me:De.sibling=Me,De=Me);return pt&&Zi(q,He),Ie}for(Me=f(q,Me);He<G.length;He++)zt=we(Me,q,He,G[He],be),zt!==null&&(i&&zt.alternate!==null&&Me.delete(zt.key===null?He:zt.key),j=b(zt,j,He),De===null?Ie=zt:De.sibling=zt,De=zt);return i&&Me.forEach(function(xi){return s(q,xi)}),pt&&Zi(q,He),Ie}function Ne(q,j,G,be){var Ie=oe(G);if(typeof Ie!="function")throw Error(n(150));if(G=Ie.call(G),G==null)throw Error(n(151));for(var De=Ie=null,Me=j,He=j=0,zt=null,et=G.next();Me!==null&&!et.done;He++,et=G.next()){Me.index>He?(zt=Me,Me=null):zt=Me.sibling;var xi=ue(q,Me,et.value,be);if(xi===null){Me===null&&(Me=zt);break}i&&Me&&xi.alternate===null&&s(q,Me),j=b(xi,j,He),De===null?Ie=xi:De.sibling=xi,De=xi,Me=zt}if(et.done)return l(q,Me),pt&&Zi(q,He),Ie;if(Me===null){for(;!et.done;He++,et=G.next())et=ge(q,et.value,be),et!==null&&(j=b(et,j,He),De===null?Ie=et:De.sibling=et,De=et);return pt&&Zi(q,He),Ie}for(Me=f(q,Me);!et.done;He++,et=G.next())et=we(Me,q,He,et.value,be),et!==null&&(i&&et.alternate!==null&&Me.delete(et.key===null?He:et.key),j=b(et,j,He),De===null?Ie=et:De.sibling=et,De=et);return i&&Me.forEach(function(P9){return s(q,P9)}),pt&&Zi(q,He),Ie}function vt(q,j,G,be){if(typeof G=="object"&&G!==null&&G.type===K&&G.key===null&&(G=G.props.children),typeof G=="object"&&G!==null){switch(G.$$typeof){case W:e:{for(var Ie=G.key,De=j;De!==null;){if(De.key===Ie){if(Ie=G.type,Ie===K){if(De.tag===7){l(q,De.sibling),j=g(De,G.props.children),j.return=q,q=j;break e}}else if(De.elementType===Ie||typeof Ie=="object"&&Ie!==null&&Ie.$$typeof===Oe&&kx(Ie)===De.type){l(q,De.sibling),j=g(De,G.props),j.ref=ja(q,De,G),j.return=q,q=j;break e}l(q,De);break}else s(q,De);De=De.sibling}G.type===K?(j=ao(G.props.children,q.mode,be,G.key),j.return=q,q=j):(be=Nc(G.type,G.key,G.props,null,q.mode,be),be.ref=ja(q,j,G),be.return=q,q=be)}return w(q);case D:e:{for(De=G.key;j!==null;){if(j.key===De)if(j.tag===4&&j.stateNode.containerInfo===G.containerInfo&&j.stateNode.implementation===G.implementation){l(q,j.sibling),j=g(j,G.children||[]),j.return=q,q=j;break e}else{l(q,j);break}else s(q,j);j=j.sibling}j=mm(G,q.mode,be),j.return=q,q=j}return w(q);case Oe:return De=G._init,vt(q,j,De(G._payload),be)}if(ei(G))return Ce(q,j,G,be);if(oe(G))return Ne(q,j,G,be);oc(q,G)}return typeof G=="string"&&G!==""||typeof G=="number"?(G=""+G,j!==null&&j.tag===6?(l(q,j.sibling),j=g(j,G),j.return=q,q=j):(l(q,j),j=pm(G,q.mode,be),j.return=q,q=j),w(q)):l(q,j)}return vt}var ds=Nx(!0),Ox=Nx(!1),sc=ci(null),ac=null,fs=null,vp=null;function Sp(){vp=fs=ac=null}function Ap(i){var s=sc.current;ct(sc),i._currentValue=s}function Cp(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 hs(i,s){ac=i,vp=fs=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(vp!==i)if(i={context:i,memoizedValue:s,next:null},fs===null){if(ac===null)throw Error(n(308));fs=i,ac.dependencies={lanes:0,firstContext:i}}else fs=fs.next=i;return s}var eo=null;function kp(i){eo===null?eo=[i]:eo.push(i)}function Ix(i,s,l,f){var g=s.interleaved;return g===null?(l.next=l,kp(s)):(l.next=g.next,g.next=l),s.interleaved=l,Fr(i,f)}function Fr(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 hi=!1;function Np(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Rx(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 Br(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function pi(i,s,l){var f=i.updateQueue;if(f===null)return null;if(f=f.shared,(Je&2)!==0){var g=f.pending;return g===null?s.next=s:(s.next=g.next,g.next=s),f.pending=s,Fr(i,l)}return g=f.interleaved,g===null?(s.next=s,kp(f)):(s.next=g.next,g.next=s),f.interleaved=s,Fr(i,l)}function uc(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,$h(i,l)}}function Px(i,s){var l=i.updateQueue,f=i.alternate;if(f!==null&&(f=f.updateQueue,l===f)){var g=null,b=null;if(l=l.firstBaseUpdate,l!==null){do{var w={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};b===null?g=b=w:b=b.next=w,l=l.next}while(l!==null);b===null?g=b=s:b=b.next=s}else g=b=s;l={baseState:f.baseState,firstBaseUpdate:g,lastBaseUpdate:b,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 lc(i,s,l,f){var g=i.updateQueue;hi=!1;var b=g.firstBaseUpdate,w=g.lastBaseUpdate,P=g.shared.pending;if(P!==null){g.shared.pending=null;var F=P,J=F.next;F.next=null,w===null?b=J:w.next=J,w=F;var ce=i.alternate;ce!==null&&(ce=ce.updateQueue,P=ce.lastBaseUpdate,P!==w&&(P===null?ce.firstBaseUpdate=J:P.next=J,ce.lastBaseUpdate=F))}if(b!==null){var ge=g.baseState;w=0,ce=J=F=null,P=b;do{var ue=P.lane,we=P.eventTime;if((f&ue)===ue){ce!==null&&(ce=ce.next={eventTime:we,lane:0,tag:P.tag,payload:P.payload,callback:P.callback,next:null});e:{var Ce=i,Ne=P;switch(ue=s,we=l,Ne.tag){case 1:if(Ce=Ne.payload,typeof Ce=="function"){ge=Ce.call(we,ge,ue);break e}ge=Ce;break e;case 3:Ce.flags=Ce.flags&-65537|128;case 0:if(Ce=Ne.payload,ue=typeof Ce=="function"?Ce.call(we,ge,ue):Ce,ue==null)break e;ge=C({},ge,ue);break e;case 2:hi=!0}}P.callback!==null&&P.lane!==0&&(i.flags|=64,ue=g.effects,ue===null?g.effects=[P]:ue.push(P))}else we={eventTime:we,lane:ue,tag:P.tag,payload:P.payload,callback:P.callback,next:null},ce===null?(J=ce=we,F=ge):ce=ce.next=we,w|=ue;if(P=P.next,P===null){if(P=g.shared.pending,P===null)break;ue=P,P=ue.next,ue.next=null,g.lastBaseUpdate=ue,g.shared.pending=null}}while(!0);if(ce===null&&(F=ge),g.baseState=F,g.firstBaseUpdate=J,g.lastBaseUpdate=ce,s=g.shared.interleaved,s!==null){g=s;do w|=g.lane,g=g.next;while(g!==s)}else b===null&&(g.shared.lanes=0);ro|=w,i.lanes=w,i.memoizedState=ge}}function Lx(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 $a={},wr=ci($a),Va=ci($a),qa=ci($a);function to(i){if(i===$a)throw Error(n(174));return i}function Op(i,s){switch(at(qa,s),at(Va,i),at(wr,$a),i=s.nodeType,i){case 9:case 11:s=(s=s.documentElement)?s.namespaceURI:xe(null,"");break;default:i=i===8?s.parentNode:s,s=i.namespaceURI||null,i=i.tagName,s=xe(s,i)}ct(wr),at(wr,s)}function ps(){ct(wr),ct(Va),ct(qa)}function Dx(i){to(qa.current);var s=to(wr.current),l=xe(s,i.type);s!==l&&(at(Va,i),at(wr,l))}function Ip(i){Va.current===i&&(ct(wr),ct(Va))}var gt=ci(0);function cc(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 Rp=[];function Pp(){for(var i=0;i<Rp.length;i++)Rp[i]._workInProgressVersionPrimary=null;Rp.length=0}var dc=H.ReactCurrentDispatcher,Lp=H.ReactCurrentBatchConfig,no=0,Et=null,Rt=null,Ut=null,fc=!1,Ya=!1,Wa=0,t9=0;function Jt(){throw Error(n(321))}function Dp(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 Mp(i,s,l,f,g,b){if(no=b,Et=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,dc.current=i===null||i.memoizedState===null?o9:s9,i=l(f,g),Ya){b=0;do{if(Ya=!1,Wa=0,25<=b)throw Error(n(301));b+=1,Ut=Rt=null,s.updateQueue=null,dc.current=a9,i=l(f,g)}while(Ya)}if(dc.current=mc,s=Rt!==null&&Rt.next!==null,no=0,Ut=Rt=Et=null,fc=!1,s)throw Error(n(300));return i}function Fp(){var i=Wa!==0;return Wa=0,i}function _r(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ut===null?Et.memoizedState=Ut=i:Ut=Ut.next=i,Ut}function Hn(){if(Rt===null){var i=Et.alternate;i=i!==null?i.memoizedState:null}else i=Rt.next;var s=Ut===null?Et.memoizedState:Ut.next;if(s!==null)Ut=s,Rt=i;else{if(i===null)throw Error(n(310));Rt=i,i={memoizedState:Rt.memoizedState,baseState:Rt.baseState,baseQueue:Rt.baseQueue,queue:Rt.queue,next:null},Ut===null?Et.memoizedState=Ut=i:Ut=Ut.next=i}return Ut}function Ga(i,s){return typeof s=="function"?s(i):s}function Bp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=Rt,g=f.baseQueue,b=l.pending;if(b!==null){if(g!==null){var w=g.next;g.next=b.next,b.next=w}f.baseQueue=g=b,l.pending=null}if(g!==null){b=g.next,f=f.baseState;var P=w=null,F=null,J=b;do{var ce=J.lane;if((no&ce)===ce)F!==null&&(F=F.next={lane:0,action:J.action,hasEagerState:J.hasEagerState,eagerState:J.eagerState,next:null}),f=J.hasEagerState?J.eagerState:i(f,J.action);else{var ge={lane:ce,action:J.action,hasEagerState:J.hasEagerState,eagerState:J.eagerState,next:null};F===null?(P=F=ge,w=f):F=F.next=ge,Et.lanes|=ce,ro|=ce}J=J.next}while(J!==null&&J!==b);F===null?w=f:F.next=P,Zn(f,s.memoizedState)||(En=!0),s.memoizedState=f,s.baseState=w,s.baseQueue=F,l.lastRenderedState=f}if(i=l.interleaved,i!==null){g=i;do b=g.lane,Et.lanes|=b,ro|=b,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function Up(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=l.dispatch,g=l.pending,b=s.memoizedState;if(g!==null){l.pending=null;var w=g=g.next;do b=i(b,w.action),w=w.next;while(w!==g);Zn(b,s.memoizedState)||(En=!0),s.memoizedState=b,s.baseQueue===null&&(s.baseState=b),l.lastRenderedState=b}return[b,f]}function Mx(){}function Fx(i,s){var l=Et,f=Hn(),g=s(),b=!Zn(f.memoizedState,g);if(b&&(f.memoizedState=g,En=!0),f=f.queue,Hp(Hx.bind(null,l,f,i),[i]),f.getSnapshot!==s||b||Ut!==null&&Ut.memoizedState.tag&1){if(l.flags|=2048,Ka(9,Ux.bind(null,l,f,g,s),void 0,null),Ht===null)throw Error(n(349));(no&30)!==0||Bx(l,s,g)}return g}function Bx(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=Et.updateQueue,s===null?(s={lastEffect:null,stores:null},Et.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function Ux(i,s,l,f){s.value=l,s.getSnapshot=f,zx(s)&&jx(i)}function Hx(i,s,l){return l(function(){zx(s)&&jx(i)})}function zx(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!Zn(i,l)}catch(f){return!0}}function jx(i){var s=Fr(i,1);s!==null&&ir(s,i,1,-1)}function $x(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:Ga,lastRenderedState:i},s.queue=i,i=i.dispatch=i9.bind(null,Et,i),[s.memoizedState,i]}function Ka(i,s,l,f){return i={tag:i,create:s,destroy:l,deps:f,next:null},s=Et.updateQueue,s===null?(s={lastEffect:null,stores:null},Et.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 Vx(){return Hn().memoizedState}function hc(i,s,l,f){var g=_r();Et.flags|=i,g.memoizedState=Ka(1|s,l,void 0,f===void 0?null:f)}function pc(i,s,l,f){var g=Hn();f=f===void 0?null:f;var b=void 0;if(Rt!==null){var w=Rt.memoizedState;if(b=w.destroy,f!==null&&Dp(f,w.deps)){g.memoizedState=Ka(s,l,b,f);return}}Et.flags|=i,g.memoizedState=Ka(1|s,l,b,f)}function qx(i,s){return hc(8390656,8,i,s)}function Hp(i,s){return pc(2048,8,i,s)}function Yx(i,s){return pc(4,2,i,s)}function Wx(i,s){return pc(4,4,i,s)}function Gx(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 Kx(i,s,l){return l=l!=null?l.concat([i]):null,pc(4,4,Gx.bind(null,s,i),l)}function zp(){}function Qx(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Dp(s,f[1])?f[0]:(l.memoizedState=[i,s],i)}function Xx(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Dp(s,f[1])?f[0]:(i=i(),l.memoizedState=[i,s],i)}function Jx(i,s,l){return(no&21)===0?(i.baseState&&(i.baseState=!1,En=!0),i.memoizedState=l):(Zn(l,s)||(l=kT(),Et.lanes|=l,ro|=l,i.baseState=!0),s)}function n9(i,s){var l=nt;nt=l!==0&&4>l?l:4,i(!0);var f=Lp.transition;Lp.transition={};try{i(!1),s()}finally{nt=l,Lp.transition=f}}function Zx(){return Hn().memoizedState}function r9(i,s,l){var f=yi(i);if(l={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null},e2(i))t2(s,l);else if(l=Ix(i,s,l,f),l!==null){var g=on();ir(l,i,f,g),n2(l,s,f)}}function i9(i,s,l){var f=yi(i),g={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null};if(e2(i))t2(s,g);else{var b=i.alternate;if(i.lanes===0&&(b===null||b.lanes===0)&&(b=s.lastRenderedReducer,b!==null))try{var w=s.lastRenderedState,P=b(w,l);if(g.hasEagerState=!0,g.eagerState=P,Zn(P,w)){var F=s.interleaved;F===null?(g.next=g,kp(s)):(g.next=F.next,F.next=g),s.interleaved=g;return}}catch(J){}l=Ix(i,s,g,f),l!==null&&(g=on(),ir(l,i,f,g),n2(l,s,f))}}function e2(i){var s=i.alternate;return i===Et||s!==null&&s===Et}function t2(i,s){Ya=fc=!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,$h(i,l)}}var mc={readContext:Un,useCallback:Jt,useContext:Jt,useEffect:Jt,useImperativeHandle:Jt,useInsertionEffect:Jt,useLayoutEffect:Jt,useMemo:Jt,useReducer:Jt,useRef:Jt,useState:Jt,useDebugValue:Jt,useDeferredValue:Jt,useTransition:Jt,useMutableSource:Jt,useSyncExternalStore:Jt,useId:Jt,unstable_isNewReconciler:!1},o9={readContext:Un,useCallback:function(i,s){return _r().memoizedState=[i,s===void 0?null:s],i},useContext:Un,useEffect:qx,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,hc(4194308,4,Gx.bind(null,s,i),l)},useLayoutEffect:function(i,s){return hc(4194308,4,i,s)},useInsertionEffect:function(i,s){return hc(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=r9.bind(null,Et,i),[f.memoizedState,i]},useRef:function(i){var s=_r();return i={current:i},s.memoizedState=i},useState:$x,useDebugValue:zp,useDeferredValue:function(i){return _r().memoizedState=i},useTransition:function(){var i=$x(!1),s=i[0];return i=n9.bind(null,i[1]),_r().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var f=Et,g=_r();if(pt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Ht===null)throw Error(n(349));(no&30)!==0||Bx(f,s,l)}g.memoizedState=l;var b={value:l,getSnapshot:s};return g.queue=b,qx(Hx.bind(null,f,b,i),[i]),f.flags|=2048,Ka(9,Ux.bind(null,f,b,l,s),void 0,null),l},useId:function(){var i=_r(),s=Ht.identifierPrefix;if(pt){var l=Mr,f=Dr;l=(f&~(1<<32-Jn(f)-1)).toString(32)+l,s=":"+s+"R"+l,l=Wa++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=t9++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},s9={readContext:Un,useCallback:Qx,useContext:Un,useEffect:Hp,useImperativeHandle:Kx,useInsertionEffect:Yx,useLayoutEffect:Wx,useMemo:Xx,useReducer:Bp,useRef:Vx,useState:function(){return Bp(Ga)},useDebugValue:zp,useDeferredValue:function(i){var s=Hn();return Jx(s,Rt.memoizedState,i)},useTransition:function(){var i=Bp(Ga)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:Mx,useSyncExternalStore:Fx,useId:Zx,unstable_isNewReconciler:!1},a9={readContext:Un,useCallback:Qx,useContext:Un,useEffect:Hp,useImperativeHandle:Kx,useInsertionEffect:Yx,useLayoutEffect:Wx,useMemo:Xx,useReducer:Up,useRef:Vx,useState:function(){return Up(Ga)},useDebugValue:zp,useDeferredValue:function(i){var s=Hn();return Rt===null?s.memoizedState=i:Jx(s,Rt.memoizedState,i)},useTransition:function(){var i=Up(Ga)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:Mx,useSyncExternalStore:Fx,useId:Zx,unstable_isNewReconciler:!1};function tr(i,s){if(i&&i.defaultProps){s=C({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function jp(i,s,l,f){s=i.memoizedState,l=l(f,s),l=l==null?s:C({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var gc={isMounted:function(i){return(i=i._reactInternals)?Ki(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var f=on(),g=yi(i),b=Br(f,g);b.payload=s,l!=null&&(b.callback=l),s=pi(i,b,g),s!==null&&(ir(s,i,g,f),uc(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var f=on(),g=yi(i),b=Br(f,g);b.tag=1,b.payload=s,l!=null&&(b.callback=l),s=pi(i,b,g),s!==null&&(ir(s,i,g,f),uc(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=on(),f=yi(i),g=Br(l,f);g.tag=2,s!=null&&(g.callback=s),s=pi(i,g,f),s!==null&&(ir(s,i,f,l),uc(s,i,f))}};function r2(i,s,l,f,g,b,w){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(f,b,w):s.prototype&&s.prototype.isPureReactComponent?!Da(l,f)||!Da(g,b):!0}function i2(i,s,l){var f=!1,g=di,b=s.contextType;return typeof b=="object"&&b!==null?b=Un(b):(g=gn(s)?Xi:Xt.current,f=s.contextTypes,b=(f=f!=null)?as(i,g):di),s=new s(l,b),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=gc,i.stateNode=s,s._reactInternals=i,f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=b),s}function o2(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&&gc.enqueueReplaceState(s,s.state,null)}function $p(i,s,l,f){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},Np(i);var b=s.contextType;typeof b=="object"&&b!==null?g.context=Un(b):(b=gn(s)?Xi:Xt.current,g.context=as(i,b)),g.state=i.memoizedState,b=s.getDerivedStateFromProps,typeof b=="function"&&(jp(i,s,b,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&&gc.enqueueReplaceState(g,g.state,null),lc(i,l,g,f),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function ms(i,s){try{var l="",f=s;do l+=Se(f),f=f.return;while(f);var g=l}catch(b){g=`
22
22
  Error generating stack: `+b.message+`
23
- `+b.stack}return{value:i,source:s,stack:g,digest:null}}function Vp(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function qp(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var u9=typeof WeakMap=="function"?WeakMap:Map;function s2(i,s,l){l=Br(-1,l),l.tag=3,l.payload={element:null};var f=s.value;return l.callback=function(){_c||(_c=!0,sm=f),qp(i,s)},l}function a2(i,s,l){l=Br(-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(){qp(i,s)}}var b=i.stateNode;return b!==null&&typeof b.componentDidCatch=="function"&&(l.callback=function(){qp(i,s),typeof f!="function"&&(gi===null?gi=new Set([this]):gi.add(this));var w=s.stack;this.componentDidCatch(s.value,{componentStack:w!==null?w:""})}),l}function u2(i,s,l){var f=i.pingCache;if(f===null){f=i.pingCache=new u9;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=w9.bind(null,i,s,l),s.then(i,i))}function l2(i){do{var s;if((s=i.tag===13)&&(s=i.memoizedState,s=s!==null?s.dehydrated!==null:!0),s)return i;i=i.return}while(i!==null);return null}function c2(i,s,l,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=Br(-1,1),s.tag=2,pi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var l9=z.ReactCurrentOwner,En=!1;function rn(i,s,l,f){s.child=i===null?Ox(s,null,l,f):ds(s,i.child,l,f)}function d2(i,s,l,f,g){l=l.render;var b=s.ref;return hs(s,g),f=Mp(i,s,l,f,b,g),l=Fp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Ur(i,s,g)):(pt&&l&&bp(s),s.flags|=1,rn(i,s,f,g),s.child)}function f2(i,s,l,f,g){if(i===null){var b=l.type;return typeof b=="function"&&!hm(b)&&b.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=b,h2(i,s,b,f,g)):(i=Nc(l.type,null,f,s,s.mode,g),i.ref=s.ref,i.return=s,s.child=i)}if(b=i.child,(i.lanes&g)===0){var w=b.memoizedProps;if(l=l.compare,l=l!==null?l:Da,l(w,f)&&i.ref===s.ref)return Ur(i,s,g)}return s.flags|=1,i=Ti(b,f),i.ref=s.ref,i.return=s,s.child=i}function h2(i,s,l,f,g){if(i!==null){var b=i.memoizedProps;if(Da(b,f)&&i.ref===s.ref)if(En=!1,s.pendingProps=f=b,(i.lanes&g)!==0)(i.flags&131072)!==0&&(En=!0);else return s.lanes=i.lanes,Ur(i,s,g)}return Yp(i,s,l,f,g)}function p2(i,s,l){var f=s.pendingProps,g=f.children,b=i!==null?i.memoizedState:null;if(f.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},at(Es,Nn),Nn|=l;else{if((l&1073741824)===0)return i=b!==null?b.baseLanes|l:l,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,at(Es,Nn),Nn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},f=b!==null?b.baseLanes:l,at(Es,Nn),Nn|=f}else b!==null?(f=b.baseLanes|l,s.memoizedState=null):f=l,at(Es,Nn),Nn|=f;return rn(i,s,g,l),s.child}function m2(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function Yp(i,s,l,f,g){var b=gn(l)?Xi:Xt.current;return b=as(s,b),hs(s,g),l=Mp(i,s,l,f,b,g),f=Fp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Ur(i,s,g)):(pt&&f&&bp(s),s.flags|=1,rn(i,s,l,g),s.child)}function g2(i,s,l,f,g){if(gn(l)){var b=!0;ec(s)}else b=!1;if(hs(s,g),s.stateNode===null)yc(i,s),i2(s,l,f),$p(s,l,f,g),f=!0;else if(i===null){var w=s.stateNode,P=s.memoizedProps;w.props=P;var B=w.context,X=l.contextType;typeof X=="object"&&X!==null?X=Un(X):(X=gn(l)?Xi:Xt.current,X=as(s,X));var ce=l.getDerivedStateFromProps,me=typeof ce=="function"||typeof w.getSnapshotBeforeUpdate=="function";me||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(P!==f||B!==X)&&o2(s,w,f,X),hi=!1;var ue=s.memoizedState;w.state=ue,lc(s,f,w,g),B=s.memoizedState,P!==f||ue!==B||mn.current||hi?(typeof ce=="function"&&(jp(s,l,ce,f),B=s.memoizedState),(P=hi||r2(s,l,P,f,ue,B,X))?(me||typeof w.UNSAFE_componentWillMount!="function"&&typeof w.componentWillMount!="function"||(typeof w.componentWillMount=="function"&&w.componentWillMount(),typeof w.UNSAFE_componentWillMount=="function"&&w.UNSAFE_componentWillMount()),typeof w.componentDidMount=="function"&&(s.flags|=4194308)):(typeof w.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=f,s.memoizedState=B),w.props=f,w.state=B,w.context=X,f=P):(typeof w.componentDidMount=="function"&&(s.flags|=4194308),f=!1)}else{w=s.stateNode,Rx(i,s),P=s.memoizedProps,X=s.type===s.elementType?P:tr(s.type,P),w.props=X,me=s.pendingProps,ue=w.context,B=l.contextType,typeof B=="object"&&B!==null?B=Un(B):(B=gn(l)?Xi:Xt.current,B=as(s,B));var we=l.getDerivedStateFromProps;(ce=typeof we=="function"||typeof w.getSnapshotBeforeUpdate=="function")||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(P!==me||ue!==B)&&o2(s,w,f,B),hi=!1,ue=s.memoizedState,w.state=ue,lc(s,f,w,g);var Ce=s.memoizedState;P!==me||ue!==Ce||mn.current||hi?(typeof we=="function"&&(jp(s,l,we,f),Ce=s.memoizedState),(X=hi||r2(s,l,X,f,ue,Ce,B)||!1)?(ce||typeof w.UNSAFE_componentWillUpdate!="function"&&typeof w.componentWillUpdate!="function"||(typeof w.componentWillUpdate=="function"&&w.componentWillUpdate(f,Ce,B),typeof w.UNSAFE_componentWillUpdate=="function"&&w.UNSAFE_componentWillUpdate(f,Ce,B)),typeof w.componentDidUpdate=="function"&&(s.flags|=4),typeof w.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof w.componentDidUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),s.memoizedProps=f,s.memoizedState=Ce),w.props=f,w.state=Ce,w.context=B,f=X):(typeof w.componentDidUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),f=!1)}return Wp(i,s,l,f,b,g)}function Wp(i,s,l,f,g,b){m2(i,s);var w=(s.flags&128)!==0;if(!f&&!w)return g&&xx(s,l,!1),Ur(i,s,b);f=s.stateNode,l9.current=s;var P=w&&typeof l.getDerivedStateFromError!="function"?null:f.render();return s.flags|=1,i!==null&&w?(s.child=ds(s,i.child,null,b),s.child=ds(s,null,P,b)):rn(i,s,P,b),s.memoizedState=f.state,g&&xx(s,l,!0),s.child}function E2(i){var s=i.stateNode;s.pendingContext?bx(i,s.pendingContext,s.pendingContext!==s.context):s.context&&bx(i,s.context,!1),Op(i,s.containerInfo)}function y2(i,s,l,f,g){return cs(),_p(g),s.flags|=256,rn(i,s,l,f),s.child}var Gp={dehydrated:null,treeContext:null,retryLane:0};function Kp(i){return{baseLanes:i,cachePool:null,transitions:null}}function b2(i,s,l){var f=s.pendingProps,g=gt.current,b=!1,w=(s.flags&128)!==0,P;if((P=w)||(P=i!==null&&i.memoizedState===null?!1:(g&2)!==0),P?(b=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(g|=1),at(gt,g&1),i===null)return wp(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):(w=f.children,i=f.fallback,b?(f=s.mode,b=s.child,w={mode:"hidden",children:w},(f&1)===0&&b!==null?(b.childLanes=0,b.pendingProps=w):b=Oc(w,f,0,null),i=ao(i,f,l,null),b.return=s,i.return=s,b.sibling=i,s.child=b,s.child.memoizedState=Kp(l),s.memoizedState=Gp,i):Qp(s,w));if(g=i.memoizedState,g!==null&&(P=g.dehydrated,P!==null))return c9(i,s,w,f,P,g,l);if(b){b=f.fallback,w=s.mode,g=i.child,P=g.sibling;var B={mode:"hidden",children:f.children};return(w&1)===0&&s.child!==g?(f=s.child,f.childLanes=0,f.pendingProps=B,s.deletions=null):(f=Ti(g,B),f.subtreeFlags=g.subtreeFlags&14680064),P!==null?b=Ti(P,b):(b=ao(b,w,l,null),b.flags|=2),b.return=s,f.return=s,f.sibling=b,s.child=f,f=b,b=s.child,w=i.child.memoizedState,w=w===null?Kp(l):{baseLanes:w.baseLanes|l,cachePool:null,transitions:w.transitions},b.memoizedState=w,b.childLanes=i.childLanes&~l,s.memoizedState=Gp,f}return b=i.child,i=b.sibling,f=Ti(b,{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 Qp(i,s){return s=Oc({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function Ec(i,s,l,f){return f!==null&&_p(f),ds(s,i.child,null,l),i=Qp(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function c9(i,s,l,f,g,b,w){if(l)return s.flags&256?(s.flags&=-257,f=Vp(Error(n(422))),Ec(i,s,w,f)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(b=f.fallback,g=s.mode,f=Oc({mode:"visible",children:f.children},g,0,null),b=ao(b,g,w,null),b.flags|=2,f.return=s,b.return=s,f.sibling=b,s.child=f,(s.mode&1)!==0&&ds(s,i.child,null,w),s.child.memoizedState=Kp(w),s.memoizedState=Gp,b);if((s.mode&1)===0)return Ec(i,s,w,null);if(g.data==="$!"){if(f=g.nextSibling&&g.nextSibling.dataset,f)var P=f.dgst;return f=P,b=Error(n(419)),f=Vp(b,f,void 0),Ec(i,s,w,f)}if(P=(w&i.childLanes)!==0,En||P){if(f=Ht,f!==null){switch(w&-w){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|w))!==0?0:g,g!==0&&g!==b.retryLane&&(b.retryLane=g,Fr(i,g),ir(f,i,g,-1))}return fm(),f=Vp(Error(n(421))),Ec(i,s,w,f)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=_9.bind(null,i),g._reactRetry=s,null):(i=b.treeContext,kn=li(g.nextSibling),Cn=s,pt=!0,er=null,i!==null&&(Fn[Bn++]=Dr,Fn[Bn++]=Mr,Fn[Bn++]=Ji,Dr=i.id,Mr=i.overflow,Ji=s),s=Qp(s,f.children),s.flags|=4096,s)}function T2(i,s,l){i.lanes|=s;var f=i.alternate;f!==null&&(f.lanes|=s),Cp(i.return,s,l)}function Xp(i,s,l,f,g){var b=i.memoizedState;b===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:f,tail:l,tailMode:g}:(b.isBackwards=s,b.rendering=null,b.renderingStartTime=0,b.last=f,b.tail=l,b.tailMode=g)}function x2(i,s,l){var f=s.pendingProps,g=f.revealOrder,b=f.tail;if(rn(i,s,f.children,l),f=gt.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&&T2(i,l,s);else if(i.tag===19)T2(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(gt,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&&cc(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),Xp(s,!1,g,l,b);break;case"backwards":for(l=null,g=s.child,s.child=null;g!==null;){if(i=g.alternate,i!==null&&cc(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}Xp(s,!0,l,null,b);break;case"together":Xp(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function yc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function Ur(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),ro|=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=Ti(i,i.pendingProps),s.child=l,l.return=s;i.sibling!==null;)i=i.sibling,l=l.sibling=Ti(i,i.pendingProps),l.return=s;l.sibling=null}return s.child}function d9(i,s,l){switch(s.tag){case 3:E2(s),cs();break;case 5:Dx(s);break;case 1:gn(s.type)&&ec(s);break;case 4:Op(s,s.stateNode.containerInfo);break;case 10:var f=s.type._context,g=s.memoizedProps.value;at(sc,f._currentValue),f._currentValue=g;break;case 13:if(f=s.memoizedState,f!==null)return f.dehydrated!==null?(at(gt,gt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?b2(i,s,l):(at(gt,gt.current&1),i=Ur(i,s,l),i!==null?i.sibling:null);at(gt,gt.current&1);break;case 19:if(f=(l&s.childLanes)!==0,(i.flags&128)!==0){if(f)return x2(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),at(gt,gt.current),f)break;return null;case 22:case 23:return s.lanes=0,p2(i,s,l)}return Ur(i,s,l)}var w2,Jp,_2,v2;w2=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}},Jp=function(){},_2=function(i,s,l,f){var g=i.memoizedProps;if(g!==f){i=s.stateNode,to(wr.current);var b=null;switch(l){case"input":g=Xn(i,g),f=Xn(i,f),b=[];break;case"select":g=C({},g,{value:void 0}),f=C({},f,{value:void 0}),b=[];break;case"textarea":g=ba(i,g),f=ba(i,f),b=[];break;default:typeof g.onClick!="function"&&typeof f.onClick=="function"&&(i.onclick=Xl)}$t(l,f);var w;l=null;for(X in g)if(!f.hasOwnProperty(X)&&g.hasOwnProperty(X)&&g[X]!=null)if(X==="style"){var P=g[X];for(w in P)P.hasOwnProperty(w)&&(l||(l={}),l[w]="")}else X!=="dangerouslySetInnerHTML"&&X!=="children"&&X!=="suppressContentEditableWarning"&&X!=="suppressHydrationWarning"&&X!=="autoFocus"&&(o.hasOwnProperty(X)?b||(b=[]):(b=b||[]).push(X,null));for(X in f){var B=f[X];if(P=g!=null?g[X]:void 0,f.hasOwnProperty(X)&&B!==P&&(B!=null||P!=null))if(X==="style")if(P){for(w in P)!P.hasOwnProperty(w)||B&&B.hasOwnProperty(w)||(l||(l={}),l[w]="");for(w in B)B.hasOwnProperty(w)&&P[w]!==B[w]&&(l||(l={}),l[w]=B[w])}else l||(b||(b=[]),b.push(X,l)),l=B;else X==="dangerouslySetInnerHTML"?(B=B?B.__html:void 0,P=P?P.__html:void 0,B!=null&&P!==B&&(b=b||[]).push(X,B)):X==="children"?typeof B!="string"&&typeof B!="number"||(b=b||[]).push(X,""+B):X!=="suppressContentEditableWarning"&&X!=="suppressHydrationWarning"&&(o.hasOwnProperty(X)?(B!=null&&X==="onScroll"&&lt("scroll",i),b||P===B||(b=[])):(b=b||[]).push(X,B))}l&&(b=b||[]).push("style",l);var X=b;(s.updateQueue=X)&&(s.flags|=4)}},v2=function(i,s,l,f){l!==f&&(s.flags|=4)};function Qa(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 Zt(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 f9(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 Zt(s),null;case 1:return gn(s.type)&&Zl(),Zt(s),null;case 3:return f=s.stateNode,ps(),ct(mn),ct(Xt),Pp(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(i===null||i.child===null)&&(ic(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,er!==null&&(lm(er),er=null))),Jp(i,s),Zt(s),null;case 5:Ip(s);var g=to(qa.current);if(l=s.type,i!==null&&s.stateNode!=null)_2(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 Zt(s),null}if(i=to(wr.current),ic(s)){f=s.stateNode,l=s.type;var b=s.memoizedProps;switch(f[xr]=s,f[Ha]=b,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<Fa.length;g++)lt(Fa[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":Ea(f,b),lt("invalid",f);break;case"select":f._wrapperState={wasMultiple:!!b.multiple},lt("invalid",f);break;case"textarea":Cl(f,b),lt("invalid",f)}$t(l,b),g=null;for(var w in b)if(b.hasOwnProperty(w)){var P=b[w];w==="children"?typeof P=="string"?f.textContent!==P&&(b.suppressHydrationWarning!==!0&&Ql(f.textContent,P,i),g=["children",P]):typeof P=="number"&&f.textContent!==""+P&&(b.suppressHydrationWarning!==!0&&Ql(f.textContent,P,i),g=["children",""+P]):o.hasOwnProperty(w)&&P!=null&&w==="onScroll"&&lt("scroll",f)}switch(l){case"input":pn(f),Al(f,b,!0);break;case"textarea":pn(f),Nl(f);break;case"select":case"option":break;default:typeof b.onClick=="function"&&(f.onclick=Xl)}f=g,s.updateQueue=f,f!==null&&(s.flags|=4)}else{w=g.nodeType===9?g:g.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=ie(l)),i==="http://www.w3.org/1999/xhtml"?l==="script"?(i=w.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof f.is=="string"?i=w.createElement(l,{is:f.is}):(i=w.createElement(l),l==="select"&&(w=i,f.multiple?w.multiple=!0:f.size&&(w.size=f.size))):i=w.createElementNS(i,l),i[xr]=s,i[Ha]=f,w2(i,s,!1,!1),s.stateNode=i;e:{switch(w=br(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<Fa.length;g++)lt(Fa[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":Ea(i,f),g=Xn(i,f),lt("invalid",i);break;case"option":g=f;break;case"select":i._wrapperState={wasMultiple:!!f.multiple},g=C({},f,{value:void 0}),lt("invalid",i);break;case"textarea":Cl(i,f),g=ba(i,f),lt("invalid",i);break;default:g=f}$t(l,g),P=g;for(b in P)if(P.hasOwnProperty(b)){var B=P[b];b==="style"?ni(i,B):b==="dangerouslySetInnerHTML"?(B=B?B.__html:void 0,B!=null&&Ye(i,B)):b==="children"?typeof B=="string"?(l!=="textarea"||B!=="")&&Xe(i,B):typeof B=="number"&&Xe(i,""+B):b!=="suppressContentEditableWarning"&&b!=="suppressHydrationWarning"&&b!=="autoFocus"&&(o.hasOwnProperty(b)?B!=null&&b==="onScroll"&&lt("scroll",i):B!=null&&R(i,b,B,w))}switch(l){case"input":pn(i),Al(i,f,!1);break;case"textarea":pn(i),Nl(i);break;case"option":f.value!=null&&i.setAttribute("value",""+ve(f.value));break;case"select":i.multiple=!!f.multiple,b=f.value,b!=null?ti(i,!!f.multiple,b,!1):f.defaultValue!=null&&ti(i,!!f.multiple,f.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=Xl)}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 Zt(s),null;case 6:if(i&&s.stateNode!=null)v2(i,s,i.memoizedProps,f);else{if(typeof f!="string"&&s.stateNode===null)throw Error(n(166));if(l=to(qa.current),to(wr.current),ic(s)){if(f=s.stateNode,l=s.memoizedProps,f[xr]=s,(b=f.nodeValue!==l)&&(i=Cn,i!==null))switch(i.tag){case 3:Ql(f.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Ql(f.nodeValue,l,(i.mode&1)!==0)}b&&(s.flags|=4)}else f=(l.nodeType===9?l:l.ownerDocument).createTextNode(f),f[xr]=s,s.stateNode=f}return Zt(s),null;case 13:if(ct(gt),f=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(pt&&kn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)Cx(),cs(),s.flags|=98560,b=!1;else if(b=ic(s),f!==null&&f.dehydrated!==null){if(i===null){if(!b)throw Error(n(318));if(b=s.memoizedState,b=b!==null?b.dehydrated:null,!b)throw Error(n(317));b[xr]=s}else cs(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;Zt(s),b=!1}else er!==null&&(lm(er),er=null),b=!0;if(!b)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||(gt.current&1)!==0?Pt===0&&(Pt=3):fm())),s.updateQueue!==null&&(s.flags|=4),Zt(s),null);case 4:return ps(),Jp(i,s),i===null&&Ba(s.stateNode.containerInfo),Zt(s),null;case 10:return Ap(s.type._context),Zt(s),null;case 17:return gn(s.type)&&Zl(),Zt(s),null;case 19:if(ct(gt),b=s.memoizedState,b===null)return Zt(s),null;if(f=(s.flags&128)!==0,w=b.rendering,w===null)if(f)Qa(b,!1);else{if(Pt!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(w=cc(i),w!==null){for(s.flags|=128,Qa(b,!1),f=w.updateQueue,f!==null&&(s.updateQueue=f,s.flags|=4),s.subtreeFlags=0,f=l,l=s.child;l!==null;)b=l,i=f,b.flags&=14680066,w=b.alternate,w===null?(b.childLanes=0,b.lanes=i,b.child=null,b.subtreeFlags=0,b.memoizedProps=null,b.memoizedState=null,b.updateQueue=null,b.dependencies=null,b.stateNode=null):(b.childLanes=w.childLanes,b.lanes=w.lanes,b.child=w.child,b.subtreeFlags=0,b.deletions=null,b.memoizedProps=w.memoizedProps,b.memoizedState=w.memoizedState,b.updateQueue=w.updateQueue,b.type=w.type,i=w.dependencies,b.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return at(gt,gt.current&1|2),s.child}i=i.sibling}b.tail!==null&&_t()>ys&&(s.flags|=128,f=!0,Qa(b,!1),s.lanes=4194304)}else{if(!f)if(i=cc(w),i!==null){if(s.flags|=128,f=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),Qa(b,!0),b.tail===null&&b.tailMode==="hidden"&&!w.alternate&&!pt)return Zt(s),null}else 2*_t()-b.renderingStartTime>ys&&l!==1073741824&&(s.flags|=128,f=!0,Qa(b,!1),s.lanes=4194304);b.isBackwards?(w.sibling=s.child,s.child=w):(l=b.last,l!==null?l.sibling=w:s.child=w,b.last=w)}return b.tail!==null?(s=b.tail,b.rendering=s,b.tail=s.sibling,b.renderingStartTime=_t(),s.sibling=null,l=gt.current,at(gt,f?l&1|2:l&1),s):(Zt(s),null);case 22:case 23:return dm(),f=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==f&&(s.flags|=8192),f&&(s.mode&1)!==0?(Nn&1073741824)!==0&&(Zt(s),s.subtreeFlags&6&&(s.flags|=8192)):Zt(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function h9(i,s){switch(Tp(s),s.tag){case 1:return gn(s.type)&&Zl(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return ps(),ct(mn),ct(Xt),Pp(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return Ip(s),null;case 13:if(ct(gt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));cs()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ct(gt),null;case 4:return ps(),null;case 10:return Ap(s.type._context),null;case 22:case 23:return dm(),null;case 24:return null;default:return null}}var bc=!1,en=!1,p9=typeof WeakSet=="function"?WeakSet:Set,_e=null;function gs(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(f){bt(i,s,f)}else l.current=null}function Zp(i,s,l){try{l()}catch(f){bt(i,s,f)}}var S2=!1;function m9(i,s){if(dp=Ul,i=rx(),rp(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,b=f.focusNode;f=f.focusOffset;try{l.nodeType,b.nodeType}catch(ye){l=null;break e}var w=0,P=-1,B=-1,X=0,ce=0,me=i,ue=null;t:for(;;){for(var we;me!==l||g!==0&&me.nodeType!==3||(P=w+g),me!==b||f!==0&&me.nodeType!==3||(B=w+f),me.nodeType===3&&(w+=me.nodeValue.length),(we=me.firstChild)!==null;)ue=me,me=we;for(;;){if(me===i)break t;if(ue===l&&++X===g&&(P=w),ue===b&&++ce===f&&(B=w),(we=me.nextSibling)!==null)break;me=ue,ue=me.parentNode}me=we}l=P===-1||B===-1?null:{start:P,end:B}}else l=null}l=l||{start:0,end:0}}else l=null;for(fp={focusedElem:i,selectionRange:l},Ul=!1,_e=s;_e!==null;)if(s=_e,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,_e=i;else for(;_e!==null;){s=_e;try{var Ce=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(Ce!==null){var Ne=Ce.memoizedProps,vt=Ce.memoizedState,q=s.stateNode,j=q.getSnapshotBeforeUpdate(s.elementType===s.type?Ne:tr(s.type,Ne),vt);q.__reactInternalSnapshotBeforeUpdate=j}break;case 3:var G=s.stateNode.containerInfo;G.nodeType===1?G.textContent="":G.nodeType===9&&G.documentElement&&G.removeChild(G.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(ye){bt(s,s.return,ye)}if(i=s.sibling,i!==null){i.return=s.return,_e=i;break}_e=s.return}return Ce=S2,S2=!1,Ce}function Xa(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 b=g.destroy;g.destroy=void 0,b!==void 0&&Zp(s,l,b)}g=g.next}while(g!==f)}}function Tc(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 em(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 A2(i){var s=i.alternate;s!==null&&(i.alternate=null,A2(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[xr],delete s[Ha],delete s[gp],delete s[XM],delete s[JM])),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 C2(i){return i.tag===5||i.tag===3||i.tag===4}function k2(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||C2(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 tm(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=Xl));else if(f!==4&&(i=i.child,i!==null))for(tm(i,s,l),i=i.sibling;i!==null;)tm(i,s,l),i=i.sibling}function nm(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(nm(i,s,l),i=i.sibling;i!==null;)nm(i,s,l),i=i.sibling}var Vt=null,nr=!1;function mi(i,s,l){for(l=l.child;l!==null;)N2(i,s,l),l=l.sibling}function N2(i,s,l){if(Tr&&typeof Tr.onCommitFiberUnmount=="function")try{Tr.onCommitFiberUnmount(Pl,l)}catch(P){}switch(l.tag){case 5:en||gs(l,s);case 6:var f=Vt,g=nr;Vt=null,mi(i,s,l),Vt=f,nr=g,Vt!==null&&(nr?(i=Vt,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):Vt.removeChild(l.stateNode));break;case 18:Vt!==null&&(nr?(i=Vt,l=l.stateNode,i.nodeType===8?mp(i.parentNode,l):i.nodeType===1&&mp(i,l),Na(i)):mp(Vt,l.stateNode));break;case 4:f=Vt,g=nr,Vt=l.stateNode.containerInfo,nr=!0,mi(i,s,l),Vt=f,nr=g;break;case 0:case 11:case 14:case 15:if(!en&&(f=l.updateQueue,f!==null&&(f=f.lastEffect,f!==null))){g=f=f.next;do{var b=g,w=b.destroy;b=b.tag,w!==void 0&&((b&2)!==0||(b&4)!==0)&&Zp(l,s,w),g=g.next}while(g!==f)}mi(i,s,l);break;case 1:if(!en&&(gs(l,s),f=l.stateNode,typeof f.componentWillUnmount=="function"))try{f.props=l.memoizedProps,f.state=l.memoizedState,f.componentWillUnmount()}catch(P){bt(l,s,P)}mi(i,s,l);break;case 21:mi(i,s,l);break;case 22:l.mode&1?(en=(f=en)||l.memoizedState!==null,mi(i,s,l),en=f):mi(i,s,l);break;default:mi(i,s,l)}}function O2(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new p9),s.forEach(function(f){var g=v9.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 b=i,w=s,P=w;e:for(;P!==null;){switch(P.tag){case 5:Vt=P.stateNode,nr=!1;break e;case 3:Vt=P.stateNode.containerInfo,nr=!0;break e;case 4:Vt=P.stateNode.containerInfo,nr=!0;break e}P=P.return}if(Vt===null)throw Error(n(160));N2(b,w,g),Vt=null,nr=!1;var B=g.alternate;B!==null&&(B.return=null),g.return=null}catch(X){bt(g,s,X)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)I2(s,i),s=s.sibling}function I2(i,s){var l=i.alternate,f=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(rr(s,i),vr(i),f&4){try{Xa(3,i,i.return),Tc(3,i)}catch(Ne){bt(i,i.return,Ne)}try{Xa(5,i,i.return)}catch(Ne){bt(i,i.return,Ne)}}break;case 1:rr(s,i),vr(i),f&512&&l!==null&&gs(l,l.return);break;case 5:if(rr(s,i),vr(i),f&512&&l!==null&&gs(l,l.return),i.flags&32){var g=i.stateNode;try{Xe(g,"")}catch(Ne){bt(i,i.return,Ne)}}if(f&4&&(g=i.stateNode,g!=null)){var b=i.memoizedProps,w=l!==null?l.memoizedProps:b,P=i.type,B=i.updateQueue;if(i.updateQueue=null,B!==null)try{P==="input"&&b.type==="radio"&&b.name!=null&&ya(g,b),br(P,w);var X=br(P,b);for(w=0;w<B.length;w+=2){var ce=B[w],me=B[w+1];ce==="style"?ni(g,me):ce==="dangerouslySetInnerHTML"?Ye(g,me):ce==="children"?Xe(g,me):R(g,ce,me,X)}switch(P){case"input":Go(g,b);break;case"textarea":kl(g,b);break;case"select":var ue=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!b.multiple;var we=b.value;we!=null?ti(g,!!b.multiple,we,!1):ue!==!!b.multiple&&(b.defaultValue!=null?ti(g,!!b.multiple,b.defaultValue,!0):ti(g,!!b.multiple,b.multiple?[]:"",!1))}g[Ha]=b}catch(Ne){bt(i,i.return,Ne)}}break;case 6:if(rr(s,i),vr(i),f&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,b=i.memoizedProps;try{g.nodeValue=b}catch(Ne){bt(i,i.return,Ne)}}break;case 3:if(rr(s,i),vr(i),f&4&&l!==null&&l.memoizedState.isDehydrated)try{Na(s.containerInfo)}catch(Ne){bt(i,i.return,Ne)}break;case 4:rr(s,i),vr(i);break;case 13:rr(s,i),vr(i),g=i.child,g.flags&8192&&(b=g.memoizedState!==null,g.stateNode.isHidden=b,!b||g.alternate!==null&&g.alternate.memoizedState!==null||(om=_t())),f&4&&O2(i);break;case 22:if(ce=l!==null&&l.memoizedState!==null,i.mode&1?(en=(X=en)||ce,rr(s,i),en=X):rr(s,i),vr(i),f&8192){if(X=i.memoizedState!==null,(i.stateNode.isHidden=X)&&!ce&&(i.mode&1)!==0)for(_e=i,ce=i.child;ce!==null;){for(me=_e=ce;_e!==null;){switch(ue=_e,we=ue.child,ue.tag){case 0:case 11:case 14:case 15:Xa(4,ue,ue.return);break;case 1:gs(ue,ue.return);var Ce=ue.stateNode;if(typeof Ce.componentWillUnmount=="function"){f=ue,l=ue.return;try{s=f,Ce.props=s.memoizedProps,Ce.state=s.memoizedState,Ce.componentWillUnmount()}catch(Ne){bt(f,l,Ne)}}break;case 5:gs(ue,ue.return);break;case 22:if(ue.memoizedState!==null){L2(me);continue}}we!==null?(we.return=ue,_e=we):L2(me)}ce=ce.sibling}e:for(ce=null,me=i;;){if(me.tag===5){if(ce===null){ce=me;try{g=me.stateNode,X?(b=g.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none"):(P=me.stateNode,B=me.memoizedProps.style,w=B!=null&&B.hasOwnProperty("display")?B.display:null,P.style.display=Mn("display",w))}catch(Ne){bt(i,i.return,Ne)}}}else if(me.tag===6){if(ce===null)try{me.stateNode.nodeValue=X?"":me.memoizedProps}catch(Ne){bt(i,i.return,Ne)}}else if((me.tag!==22&&me.tag!==23||me.memoizedState===null||me===i)&&me.child!==null){me.child.return=me,me=me.child;continue}if(me===i)break e;for(;me.sibling===null;){if(me.return===null||me.return===i)break e;ce===me&&(ce=null),me=me.return}ce===me&&(ce=null),me.sibling.return=me.return,me=me.sibling}}break;case 19:rr(s,i),vr(i),f&4&&O2(i);break;case 21:break;default:rr(s,i),vr(i)}}function vr(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(C2(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&&(Xe(g,""),f.flags&=-33);var b=k2(i);nm(i,b,g);break;case 3:case 4:var w=f.stateNode.containerInfo,P=k2(i);tm(i,P,w);break;default:throw Error(n(161))}}catch(B){bt(i,i.return,B)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function g9(i,s,l){_e=i,R2(i)}function R2(i,s,l){for(var f=(i.mode&1)!==0;_e!==null;){var g=_e,b=g.child;if(g.tag===22&&f){var w=g.memoizedState!==null||bc;if(!w){var P=g.alternate,B=P!==null&&P.memoizedState!==null||en;P=bc;var X=en;if(bc=w,(en=B)&&!X)for(_e=g;_e!==null;)w=_e,B=w.child,w.tag===22&&w.memoizedState!==null?D2(g):B!==null?(B.return=w,_e=B):D2(g);for(;b!==null;)_e=b,R2(b),b=b.sibling;_e=g,bc=P,en=X}P2(i)}else(g.subtreeFlags&8772)!==0&&b!==null?(b.return=g,_e=b):P2(i)}}function P2(i){for(;_e!==null;){var s=_e;if((s.flags&8772)!==0){var l=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:en||Tc(5,s);break;case 1:var f=s.stateNode;if(s.flags&4&&!en)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 b=s.updateQueue;b!==null&&Lx(s,b,f);break;case 3:var w=s.updateQueue;if(w!==null){if(l=null,s.child!==null)switch(s.child.tag){case 5:l=s.child.stateNode;break;case 1:l=s.child.stateNode}Lx(s,w,l)}break;case 5:var P=s.stateNode;if(l===null&&s.flags&4){l=P;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 X=s.alternate;if(X!==null){var ce=X.memoizedState;if(ce!==null){var me=ce.dehydrated;me!==null&&Na(me)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}en||s.flags&512&&em(s)}catch(ue){bt(s,s.return,ue)}}if(s===i){_e=null;break}if(l=s.sibling,l!==null){l.return=s.return,_e=l;break}_e=s.return}}function L2(i){for(;_e!==null;){var s=_e;if(s===i){_e=null;break}var l=s.sibling;if(l!==null){l.return=s.return,_e=l;break}_e=s.return}}function D2(i){for(;_e!==null;){var s=_e;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{Tc(4,s)}catch(B){bt(s,l,B)}break;case 1:var f=s.stateNode;if(typeof f.componentDidMount=="function"){var g=s.return;try{f.componentDidMount()}catch(B){bt(s,g,B)}}var b=s.return;try{em(s)}catch(B){bt(s,b,B)}break;case 5:var w=s.return;try{em(s)}catch(B){bt(s,w,B)}}}catch(B){bt(s,s.return,B)}if(s===i){_e=null;break}var P=s.sibling;if(P!==null){P.return=s.return,_e=P;break}_e=s.return}}var E9=Math.ceil,xc=z.ReactCurrentDispatcher,rm=z.ReactCurrentOwner,zn=z.ReactCurrentBatchConfig,Je=0,Ht=null,Nt=null,qt=0,Nn=0,Es=ci(0),Pt=0,Ja=null,ro=0,wc=0,im=0,Za=null,yn=null,om=0,ys=1/0,Hr=null,_c=!1,sm=null,gi=null,vc=!1,Ei=null,Sc=0,eu=0,am=null,Ac=-1,Cc=0;function on(){return(Je&6)!==0?_t():Ac!==-1?Ac:Ac=_t()}function yi(i){return(i.mode&1)===0?1:(Je&2)!==0&&qt!==0?qt&-qt:e9.transition!==null?(Cc===0&&(Cc=kT()),Cc):(i=nt,i!==0||(i=window.event,i=i===void 0?16:FT(i.type)),i)}function ir(i,s,l,f){if(50<eu)throw eu=0,am=null,Error(n(185));va(i,l,f),((Je&2)===0||i!==Ht)&&(i===Ht&&((Je&2)===0&&(wc|=l),Pt===4&&bi(i,qt)),bn(i,f),l===1&&Je===0&&(s.mode&1)===0&&(ys=_t()+500,tc&&fi()))}function bn(i,s){var l=i.callbackNode;eM(i,s);var f=Ml(i,i===Ht?qt:0);if(f===0)l!==null&&ST(l),i.callbackNode=null,i.callbackPriority=0;else if(s=f&-f,i.callbackPriority!==s){if(l!=null&&ST(l),s===1)i.tag===0?ZM(F2.bind(null,i)):wx(F2.bind(null,i)),KM(function(){(Je&6)===0&&fi()}),l=null;else{switch(NT(f)){case 1:l=Hh;break;case 4:l=AT;break;case 16:l=Rl;break;case 536870912:l=CT;break;default:l=Rl}l=q2(l,M2.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function M2(i,s){if(Ac=-1,Cc=0,(Je&6)!==0)throw Error(n(327));var l=i.callbackNode;if(bs()&&i.callbackNode!==l)return null;var f=Ml(i,i===Ht?qt:0);if(f===0)return null;if((f&30)!==0||(f&i.expiredLanes)!==0||s)s=kc(i,f);else{s=f;var g=Je;Je|=2;var b=U2();(Ht!==i||qt!==s)&&(Hr=null,ys=_t()+500,oo(i,s));do try{T9();break}catch(P){B2(i,P)}while(!0);Sp(),xc.current=b,Je=g,Nt!==null?s=0:(Ht=null,qt=0,s=Pt)}if(s!==0){if(s===2&&(g=zh(i),g!==0&&(f=g,s=um(i,g))),s===1)throw l=Ja,oo(i,0),bi(i,f),bn(i,_t()),l;if(s===6)bi(i,f);else{if(g=i.current.alternate,(f&30)===0&&!y9(g)&&(s=kc(i,f),s===2&&(b=zh(i),b!==0&&(f=b,s=um(i,b))),s===1))throw l=Ja,oo(i,0),bi(i,f),bn(i,_t()),l;switch(i.finishedWork=g,i.finishedLanes=f,s){case 0:case 1:throw Error(n(345));case 2:so(i,yn,Hr);break;case 3:if(bi(i,f),(f&130023424)===f&&(s=om+500-_t(),10<s)){if(Ml(i,0)!==0)break;if(g=i.suspendedLanes,(g&f)!==f){on(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=pp(so.bind(null,i,yn,Hr),s);break}so(i,yn,Hr);break;case 4:if(bi(i,f),(f&4194240)===f)break;for(s=i.eventTimes,g=-1;0<f;){var w=31-Jn(f);b=1<<w,w=s[w],w>g&&(g=w),f&=~b}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*E9(f/1960))-f,10<f){i.timeoutHandle=pp(so.bind(null,i,yn,Hr),f);break}so(i,yn,Hr);break;case 5:so(i,yn,Hr);break;default:throw Error(n(329))}}}return bn(i,_t()),i.callbackNode===l?M2.bind(null,i):null}function um(i,s){var l=Za;return i.current.memoizedState.isDehydrated&&(oo(i,s).flags|=256),i=kc(i,s),i!==2&&(s=yn,yn=l,s!==null&&lm(s)),i}function lm(i){yn===null?yn=i:yn.push.apply(yn,i)}function y9(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],b=g.getSnapshot;g=g.value;try{if(!Zn(b(),g))return!1}catch(w){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 bi(i,s){for(s&=~im,s&=~wc,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 F2(i){if((Je&6)!==0)throw Error(n(327));bs();var s=Ml(i,0);if((s&1)===0)return bn(i,_t()),null;var l=kc(i,s);if(i.tag!==0&&l===2){var f=zh(i);f!==0&&(s=f,l=um(i,f))}if(l===1)throw l=Ja,oo(i,0),bi(i,s),bn(i,_t()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,so(i,yn,Hr),bn(i,_t()),null}function cm(i,s){var l=Je;Je|=1;try{return i(s)}finally{Je=l,Je===0&&(ys=_t()+500,tc&&fi())}}function io(i){Ei!==null&&Ei.tag===0&&(Je&6)===0&&bs();var s=Je;Je|=1;var l=zn.transition,f=nt;try{if(zn.transition=null,nt=1,i)return i()}finally{nt=f,zn.transition=l,Je=s,(Je&6)===0&&fi()}}function dm(){Nn=Es.current,ct(Es)}function oo(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,GM(l)),Nt!==null)for(l=Nt.return;l!==null;){var f=l;switch(Tp(f),f.tag){case 1:f=f.type.childContextTypes,f!=null&&Zl();break;case 3:ps(),ct(mn),ct(Xt),Pp();break;case 5:Ip(f);break;case 4:ps();break;case 13:ct(gt);break;case 19:ct(gt);break;case 10:Ap(f.type._context);break;case 22:case 23:dm()}l=l.return}if(Ht=i,Nt=i=Ti(i.current,null),qt=Nn=s,Pt=0,Ja=null,im=wc=ro=0,yn=Za=null,eo!==null){for(s=0;s<eo.length;s++)if(l=eo[s],f=l.interleaved,f!==null){l.interleaved=null;var g=f.next,b=l.pending;if(b!==null){var w=b.next;b.next=g,f.next=w}l.pending=f}eo=null}return i}function B2(i,s){do{var l=Nt;try{if(Sp(),dc.current=mc,fc){for(var f=Et.memoizedState;f!==null;){var g=f.queue;g!==null&&(g.pending=null),f=f.next}fc=!1}if(no=0,Ut=Rt=Et=null,Ya=!1,Wa=0,rm.current=null,l===null||l.return===null){Pt=1,Ja=s,Nt=null;break}e:{var b=i,w=l.return,P=l,B=s;if(s=qt,P.flags|=32768,B!==null&&typeof B=="object"&&typeof B.then=="function"){var X=B,ce=P,me=ce.tag;if((ce.mode&1)===0&&(me===0||me===11||me===15)){var ue=ce.alternate;ue?(ce.updateQueue=ue.updateQueue,ce.memoizedState=ue.memoizedState,ce.lanes=ue.lanes):(ce.updateQueue=null,ce.memoizedState=null)}var we=l2(w);if(we!==null){we.flags&=-257,c2(we,w,P,b,s),we.mode&1&&u2(b,X,s),s=we,B=X;var Ce=s.updateQueue;if(Ce===null){var Ne=new Set;Ne.add(B),s.updateQueue=Ne}else Ce.add(B);break e}else{if((s&1)===0){u2(b,X,s),fm();break e}B=Error(n(426))}}else if(pt&&P.mode&1){var vt=l2(w);if(vt!==null){(vt.flags&65536)===0&&(vt.flags|=256),c2(vt,w,P,b,s),_p(ms(B,P));break e}}b=B=ms(B,P),Pt!==4&&(Pt=2),Za===null?Za=[b]:Za.push(b),b=w;do{switch(b.tag){case 3:b.flags|=65536,s&=-s,b.lanes|=s;var q=s2(b,B,s);Px(b,q);break e;case 1:P=B;var j=b.type,G=b.stateNode;if((b.flags&128)===0&&(typeof j.getDerivedStateFromError=="function"||G!==null&&typeof G.componentDidCatch=="function"&&(gi===null||!gi.has(G)))){b.flags|=65536,s&=-s,b.lanes|=s;var ye=a2(b,P,s);Px(b,ye);break e}}b=b.return}while(b!==null)}z2(l)}catch(Oe){s=Oe,Nt===l&&l!==null&&(Nt=l=l.return);continue}break}while(!0)}function U2(){var i=xc.current;return xc.current=mc,i===null?mc:i}function fm(){(Pt===0||Pt===3||Pt===2)&&(Pt=4),Ht===null||(ro&268435455)===0&&(wc&268435455)===0||bi(Ht,qt)}function kc(i,s){var l=Je;Je|=2;var f=U2();(Ht!==i||qt!==s)&&(Hr=null,oo(i,s));do try{b9();break}catch(g){B2(i,g)}while(!0);if(Sp(),Je=l,xc.current=f,Nt!==null)throw Error(n(261));return Ht=null,qt=0,Pt}function b9(){for(;Nt!==null;)H2(Nt)}function T9(){for(;Nt!==null&&!q8();)H2(Nt)}function H2(i){var s=V2(i.alternate,i,Nn);i.memoizedProps=i.pendingProps,s===null?z2(i):Nt=s,rm.current=null}function z2(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=f9(l,s,Nn),l!==null){Nt=l;return}}else{if(l=h9(l,s),l!==null){l.flags&=32767,Nt=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{Pt=6,Nt=null;return}}if(s=s.sibling,s!==null){Nt=s;return}Nt=s=i}while(s!==null);Pt===0&&(Pt=5)}function so(i,s,l){var f=nt,g=zn.transition;try{zn.transition=null,nt=1,x9(i,s,l,f)}finally{zn.transition=g,nt=f}return null}function x9(i,s,l,f){do bs();while(Ei!==null);if((Je&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 b=l.lanes|l.childLanes;if(tM(i,b),i===Ht&&(Nt=Ht=null,qt=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||vc||(vc=!0,q2(Rl,function(){return bs(),null})),b=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||b){b=zn.transition,zn.transition=null;var w=nt;nt=1;var P=Je;Je|=4,rm.current=null,m9(i,l),I2(l,i),zM(fp),Ul=!!dp,fp=dp=null,i.current=l,g9(l),Y8(),Je=P,nt=w,zn.transition=b}else i.current=l;if(vc&&(vc=!1,Ei=i,Sc=g),b=i.pendingLanes,b===0&&(gi=null),K8(l.stateNode),bn(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(_c)throw _c=!1,i=sm,sm=null,i;return(Sc&1)!==0&&i.tag!==0&&bs(),b=i.pendingLanes,(b&1)!==0?i===am?eu++:(eu=0,am=i):eu=0,fi(),null}function bs(){if(Ei!==null){var i=NT(Sc),s=zn.transition,l=nt;try{if(zn.transition=null,nt=16>i?16:i,Ei===null)var f=!1;else{if(i=Ei,Ei=null,Sc=0,(Je&6)!==0)throw Error(n(331));var g=Je;for(Je|=4,_e=i.current;_e!==null;){var b=_e,w=b.child;if((_e.flags&16)!==0){var P=b.deletions;if(P!==null){for(var B=0;B<P.length;B++){var X=P[B];for(_e=X;_e!==null;){var ce=_e;switch(ce.tag){case 0:case 11:case 15:Xa(8,ce,b)}var me=ce.child;if(me!==null)me.return=ce,_e=me;else for(;_e!==null;){ce=_e;var ue=ce.sibling,we=ce.return;if(A2(ce),ce===X){_e=null;break}if(ue!==null){ue.return=we,_e=ue;break}_e=we}}}var Ce=b.alternate;if(Ce!==null){var Ne=Ce.child;if(Ne!==null){Ce.child=null;do{var vt=Ne.sibling;Ne.sibling=null,Ne=vt}while(Ne!==null)}}_e=b}}if((b.subtreeFlags&2064)!==0&&w!==null)w.return=b,_e=w;else e:for(;_e!==null;){if(b=_e,(b.flags&2048)!==0)switch(b.tag){case 0:case 11:case 15:Xa(9,b,b.return)}var q=b.sibling;if(q!==null){q.return=b.return,_e=q;break e}_e=b.return}}var j=i.current;for(_e=j;_e!==null;){w=_e;var G=w.child;if((w.subtreeFlags&2064)!==0&&G!==null)G.return=w,_e=G;else e:for(w=j;_e!==null;){if(P=_e,(P.flags&2048)!==0)try{switch(P.tag){case 0:case 11:case 15:Tc(9,P)}}catch(Oe){bt(P,P.return,Oe)}if(P===w){_e=null;break e}var ye=P.sibling;if(ye!==null){ye.return=P.return,_e=ye;break e}_e=P.return}}if(Je=g,fi(),Tr&&typeof Tr.onPostCommitFiberRoot=="function")try{Tr.onPostCommitFiberRoot(Pl,i)}catch(Oe){}f=!0}return f}finally{nt=l,zn.transition=s}}return!1}function j2(i,s,l){s=ms(l,s),s=s2(i,s,1),i=pi(i,s,1),s=on(),i!==null&&(va(i,1,s),bn(i,s))}function bt(i,s,l){if(i.tag===3)j2(i,i,l);else for(;s!==null;){if(s.tag===3){j2(s,i,l);break}else if(s.tag===1){var f=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof f.componentDidCatch=="function"&&(gi===null||!gi.has(f))){i=ms(l,i),i=a2(s,i,1),s=pi(s,i,1),i=on(),s!==null&&(va(s,1,i),bn(s,i));break}}s=s.return}}function w9(i,s,l){var f=i.pingCache;f!==null&&f.delete(s),s=on(),i.pingedLanes|=i.suspendedLanes&l,Ht===i&&(qt&l)===l&&(Pt===4||Pt===3&&(qt&130023424)===qt&&500>_t()-om?oo(i,0):im|=l),bn(i,s)}function $2(i,s){s===0&&((i.mode&1)===0?s=1:(s=Dl,Dl<<=1,(Dl&130023424)===0&&(Dl=4194304)));var l=on();i=Fr(i,s),i!==null&&(va(i,s,l),bn(i,l))}function _9(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),$2(i,l)}function v9(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),$2(i,l)}var V2;V2=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,d9(i,s,l);En=(i.flags&131072)!==0}else En=!1,pt&&(s.flags&1048576)!==0&&_x(s,rc,s.index);switch(s.lanes=0,s.tag){case 2:var f=s.type;yc(i,s),i=s.pendingProps;var g=as(s,Xt.current);hs(s,l),g=Mp(null,s,f,i,g,l);var b=Fp();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)?(b=!0,ec(s)):b=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,Np(s),g.updater=gc,s.stateNode=g,g._reactInternals=s,$p(s,f,i,l),s=Wp(null,s,f,!0,b,l)):(s.tag=0,pt&&b&&bp(s),rn(null,s,g,l),s=s.child),s;case 16:f=s.elementType;e:{switch(yc(i,s),i=s.pendingProps,g=f._init,f=g(f._payload),s.type=f,g=s.tag=A9(f),i=tr(f,i),g){case 0:s=Yp(null,s,f,i,l);break e;case 1:s=g2(null,s,f,i,l);break e;case 11:s=d2(null,s,f,i,l);break e;case 14:s=f2(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),Yp(i,s,f,g,l);case 1:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),g2(i,s,f,g,l);case 3:e:{if(E2(s),i===null)throw Error(n(387));f=s.pendingProps,b=s.memoizedState,g=b.element,Rx(i,s),lc(s,f,null,l);var w=s.memoizedState;if(f=w.element,b.isDehydrated)if(b={element:f,isDehydrated:!1,cache:w.cache,pendingSuspenseBoundaries:w.pendingSuspenseBoundaries,transitions:w.transitions},s.updateQueue.baseState=b,s.memoizedState=b,s.flags&256){g=ms(Error(n(423)),s),s=y2(i,s,f,l,g);break e}else if(f!==g){g=ms(Error(n(424)),s),s=y2(i,s,f,l,g);break e}else for(kn=li(s.stateNode.containerInfo.firstChild),Cn=s,pt=!0,er=null,l=Ox(s,null,f,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(cs(),f===g){s=Ur(i,s,l);break e}rn(i,s,f,l)}s=s.child}return s;case 5:return Dx(s),i===null&&wp(s),f=s.type,g=s.pendingProps,b=i!==null?i.memoizedProps:null,w=g.children,hp(f,g)?w=null:b!==null&&hp(f,b)&&(s.flags|=32),m2(i,s),rn(i,s,w,l),s.child;case 6:return i===null&&wp(s),null;case 13:return b2(i,s,l);case 4:return Op(s,s.stateNode.containerInfo),f=s.pendingProps,i===null?s.child=ds(s,null,f,l):rn(i,s,f,l),s.child;case 11:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),d2(i,s,f,g,l);case 7:return rn(i,s,s.pendingProps,l),s.child;case 8:return rn(i,s,s.pendingProps.children,l),s.child;case 12:return rn(i,s,s.pendingProps.children,l),s.child;case 10:e:{if(f=s.type._context,g=s.pendingProps,b=s.memoizedProps,w=g.value,at(sc,f._currentValue),f._currentValue=w,b!==null)if(Zn(b.value,w)){if(b.children===g.children&&!mn.current){s=Ur(i,s,l);break e}}else for(b=s.child,b!==null&&(b.return=s);b!==null;){var P=b.dependencies;if(P!==null){w=b.child;for(var B=P.firstContext;B!==null;){if(B.context===f){if(b.tag===1){B=Br(-1,l&-l),B.tag=2;var X=b.updateQueue;if(X!==null){X=X.shared;var ce=X.pending;ce===null?B.next=B:(B.next=ce.next,ce.next=B),X.pending=B}}b.lanes|=l,B=b.alternate,B!==null&&(B.lanes|=l),Cp(b.return,l,s),P.lanes|=l;break}B=B.next}}else if(b.tag===10)w=b.type===s.type?null:b.child;else if(b.tag===18){if(w=b.return,w===null)throw Error(n(341));w.lanes|=l,P=w.alternate,P!==null&&(P.lanes|=l),Cp(w,l,s),w=b.sibling}else w=b.child;if(w!==null)w.return=b;else for(w=b;w!==null;){if(w===s){w=null;break}if(b=w.sibling,b!==null){b.return=w.return,w=b;break}w=w.return}b=w}rn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,f=s.pendingProps.children,hs(s,l),g=Un(g),f=f(g),s.flags|=1,rn(i,s,f,l),s.child;case 14:return f=s.type,g=tr(f,s.pendingProps),g=tr(f.type,g),f2(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),yc(i,s),s.tag=1,gn(f)?(i=!0,ec(s)):i=!1,hs(s,l),i2(s,f,g),$p(s,f,g,l),Wp(null,s,f,!0,i,l);case 19:return x2(i,s,l);case 22:return p2(i,s,l)}throw Error(n(156,s.tag))};function q2(i,s){return vT(i,s)}function S9(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 S9(i,s,l,f)}function hm(i){return i=i.prototype,!(!i||!i.isReactComponent)}function A9(i){if(typeof i=="function")return hm(i)?1:0;if(i!=null){if(i=i.$$typeof,i===J)return 11;if(i===be)return 14}return 2}function Ti(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 Nc(i,s,l,f,g,b){var w=2;if(f=i,typeof i=="function")hm(i)&&(w=1);else if(typeof i=="string")w=5;else e:switch(i){case K:return ao(l.children,g,b,s);case de:w=8,g|=8;break;case xe:return i=jn(12,l,s,g|2),i.elementType=xe,i.lanes=b,i;case re:return i=jn(13,l,s,g),i.elementType=re,i.lanes=b,i;case oe:return i=jn(19,l,s,g),i.elementType=oe,i.lanes=b,i;case fe:return Oc(l,g,b,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case D:w=10;break e;case ne:w=9;break e;case J:w=11;break e;case be:w=14;break e;case Ie:w=16,f=null;break e}throw Error(n(130,i==null?i:typeof i,""))}return s=jn(w,l,s,g),s.elementType=i,s.type=f,s.lanes=b,s}function ao(i,s,l,f){return i=jn(7,i,f,s),i.lanes=l,i}function Oc(i,s,l,f){return i=jn(22,i,f,s),i.elementType=fe,i.lanes=l,i.stateNode={isHidden:!1},i}function pm(i,s,l){return i=jn(6,i,null,s),i.lanes=l,i}function mm(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 C9(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=jh(0),this.expirationTimes=jh(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=jh(0),this.identifierPrefix=f,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function gm(i,s,l,f,g,b,w,P,B){return i=new C9(i,s,l,P,B),s===1?(s=1,b===!0&&(s|=8)):s=0,b=jn(3,null,null,s),i.current=b,b.stateNode=i,b.memoizedState={element:f,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},Np(b),i}function k9(i,s,l){var f=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:M,key:f==null?null:""+f,children:i,containerInfo:s,implementation:l}}function Y2(i){if(!i)return di;i=i._reactInternals;e:{if(Ki(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 Tx(i,l,s)}return s}function W2(i,s,l,f,g,b,w,P,B){return i=gm(l,f,!0,i,g,b,w,P,B),i.context=Y2(null),l=i.current,f=on(),g=yi(l),b=Br(f,g),b.callback=s!=null?s:null,pi(l,b,g),i.current.lanes=g,va(i,g,f),bn(i,f),i}function Ic(i,s,l,f){var g=s.current,b=on(),w=yi(g);return l=Y2(l),s.context===null?s.context=l:s.pendingContext=l,s=Br(b,w),s.payload={element:i},f=f===void 0?null:f,f!==null&&(s.callback=f),i=pi(g,s,w),i!==null&&(ir(i,g,w,b),uc(i,g,w)),w}function Rc(i){return i=i.current,i.child?(i.child.tag===5,i.child.stateNode):null}function G2(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function Em(i,s){G2(i,s),(i=i.alternate)&&G2(i,s)}function N9(){return null}var K2=typeof reportError=="function"?reportError:function(i){console.error(i)};function ym(i){this._internalRoot=i}Pc.prototype.render=ym.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Ic(i,s,null,null)},Pc.prototype.unmount=ym.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;io(function(){Ic(null,i,null,null)}),s[Pr]=null}};function Pc(i){this._internalRoot=i}Pc.prototype.unstable_scheduleHydration=function(i){if(i){var s=RT();i={blockedOn:null,target:i,priority:s};for(var l=0;l<si.length&&s!==0&&s<si[l].priority;l++);si.splice(l,0,i),l===0&&DT(i)}};function bm(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function Lc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function Q2(){}function O9(i,s,l,f,g){if(g){if(typeof f=="function"){var b=f;f=function(){var X=Rc(w);b.call(X)}}var w=W2(s,f,i,0,null,!1,!1,"",Q2);return i._reactRootContainer=w,i[Pr]=w.current,Ba(i.nodeType===8?i.parentNode:i),io(),w}for(;g=i.lastChild;)i.removeChild(g);if(typeof f=="function"){var P=f;f=function(){var X=Rc(B);P.call(X)}}var B=gm(i,0,!1,null,null,!1,!1,"",Q2);return i._reactRootContainer=B,i[Pr]=B.current,Ba(i.nodeType===8?i.parentNode:i),io(function(){Ic(s,B,l,f)}),B}function Dc(i,s,l,f,g){var b=l._reactRootContainer;if(b){var w=b;if(typeof g=="function"){var P=g;g=function(){var B=Rc(w);P.call(B)}}Ic(s,w,i,g)}else w=O9(l,s,i,g,f);return Rc(w)}OT=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=_a(s.pendingLanes);l!==0&&($h(s,l|1),bn(s,_t()),(Je&6)===0&&(ys=_t()+500,fi()))}break;case 13:io(function(){var f=Fr(i,1);if(f!==null){var g=on();ir(f,i,1,g)}}),Em(i,1)}},Vh=function(i){if(i.tag===13){var s=Fr(i,134217728);if(s!==null){var l=on();ir(s,i,134217728,l)}Em(i,134217728)}},IT=function(i){if(i.tag===13){var s=yi(i),l=Fr(i,s);if(l!==null){var f=on();ir(l,i,s,f)}Em(i,s)}},RT=function(){return nt},PT=function(i,s){var l=nt;try{return nt=i,s()}finally{nt=l}},Mh=function(i,s,l){switch(s){case"input":if(Go(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=Jl(f);if(!g)throw Error(n(90));Wi(f),Go(f,g)}}}break;case"textarea":kl(i,l);break;case"select":s=l.value,s!=null&&ti(i,!!l.multiple,s,!1)}},ET=cm,yT=io;var I9={usingClientEntryPoint:!1,Events:[za,os,Jl,mT,gT,cm]},tu={findFiberByHostInstance:Qi,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},R9={bundleType:tu.bundleType,version:tu.version,rendererPackageName:tu.rendererPackageName,rendererConfig:tu.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:z.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=wT(i),i===null?null:i.stateNode},findFiberByHostInstance:tu.findFiberByHostInstance||N9,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 Mc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Mc.isDisabled&&Mc.supportsFiber)try{Pl=Mc.inject(R9),Tr=Mc}catch(i){}}return ln.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=I9,ln.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!bm(s))throw Error(n(200));return k9(i,s,null,l)},ln.createRoot=function(i,s){if(!bm(i))throw Error(n(299));var l=!1,f="",g=K2;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(f=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=gm(i,1,!1,null,null,l,!1,f,g),i[Pr]=s.current,Ba(i.nodeType===8?i.parentNode:i),new ym(s)},ln.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=wT(s),i=i===null?null:i.stateNode,i},ln.flushSync=function(i){return io(i)},ln.hydrate=function(i,s,l){if(!Lc(s))throw Error(n(200));return Dc(null,i,s,!0,l)},ln.hydrateRoot=function(i,s,l){if(!bm(i))throw Error(n(405));var f=l!=null&&l.hydratedSources||null,g=!1,b="",w=K2;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(b=l.identifierPrefix),l.onRecoverableError!==void 0&&(w=l.onRecoverableError)),s=W2(s,null,i,1,l!=null?l:null,g,!1,b,w),i[Pr]=s.current,Ba(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 Pc(s)},ln.render=function(i,s,l){if(!Lc(s))throw Error(n(200));return Dc(null,i,s,!1,l)},ln.unmountComponentAtNode=function(i){if(!Lc(i))throw Error(n(40));return i._reactRootContainer?(io(function(){Dc(null,null,i,!1,function(){i._reactRootContainer=null,i[Pr]=null})}),!0):!1},ln.unstable_batchedUpdates=cm,ln.unstable_renderSubtreeIntoContainer=function(i,s,l,f){if(!Lc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Dc(i,s,l,!1,f)},ln.version="18.3.1-next-f1338f8080-20240426",ln}var M0;function F0(){if(M0)return _d.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(),_d.exports=CS(),_d.exports}var Is=F0();function B0(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=B0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function $(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=B0(e))&&(r&&(r+=" "),r+=t);return r}var U0={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},H0=wi.createContext&&wi.createContext(U0),kS=["attr","size","title"];function NS(e,t){if(e==null)return{};var n=OS(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 OS(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 Au(){return Au=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},Au.apply(this,arguments)}function z0(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 Cu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?z0(Object(n),!0).forEach(function(r){IS(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):z0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function IS(e,t,n){return t=RS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function RS(e){var t=PS(e,"string");return typeof t=="symbol"?t:t+""}function PS(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 j0(e){return e&&e.map((t,n)=>wi.createElement(t.tag,Cu({key:n},t.attr),j0(t.child)))}function mt(e){return t=>wi.createElement(LS,Au({attr:Cu({},e.attr)},t),j0(e.child))}function LS(e){var t=n=>{var{attr:r,size:o,title:a}=e,u=NS(e,kS),c=o||n.size||"1em",d;return n.className&&(d=n.className),e.className&&(d=(d?d+" ":"")+e.className),wi.createElement("svg",Au({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,u,{className:d,style:Cu(Cu({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&wi.createElement("title",null,a),e.children)};return H0!==void 0?wi.createElement(H0.Consumer,null,n=>t(n)):t(U0)}function DS(e){return mt({attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M5.25 12a.75.75 0 0 1 .75-.75h12a.75.75 0 0 1 0 1.5H6a.75.75 0 0 1-.75-.75Z",clipRule:"evenodd"},child:[]}]})(e)}function MS(e){return mt({attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M12 5.25a.75.75 0 0 1 .75.75v5.25H18a.75.75 0 0 1 0 1.5h-5.25V18a.75.75 0 0 1-1.5 0v-5.25H6a.75.75 0 0 1 0-1.5h5.25V6a.75.75 0 0 1 .75-.75Z",clipRule:"evenodd"},child:[]}]})(e)}function FS(e){return mt({attr:{fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",d:"M9.813 15.904 9 18.75l-.813-2.846a4.5 4.5 0 0 0-3.09-3.09L2.25 12l2.846-.813a4.5 4.5 0 0 0 3.09-3.09L9 5.25l.813 2.846a4.5 4.5 0 0 0 3.09 3.09L15.75 12l-2.846.813a4.5 4.5 0 0 0-3.09 3.09ZM18.259 8.715 18 9.75l-.259-1.035a3.375 3.375 0 0 0-2.455-2.456L14.25 6l1.036-.259a3.375 3.375 0 0 0 2.455-2.456L18 2.25l.259 1.035a3.375 3.375 0 0 0 2.456 2.456L21.75 6l-1.035.259a3.375 3.375 0 0 0-2.456 2.456ZM16.894 20.567 16.5 21.75l-.394-1.183a2.25 2.25 0 0 0-1.423-1.423L13.5 18.75l1.183-.394a2.25 2.25 0 0 0 1.423-1.423l.394-1.183.394 1.183a2.25 2.25 0 0 0 1.423 1.423l1.183.394-1.183.394a2.25 2.25 0 0 0-1.423 1.423Z"},child:[]}]})(e)}const ar=({className:e,iconUrl:t,icon:n,type:r="button",ariaLabel:o,title:a,disabled:u=!1,onClick:c})=>!n&&!t?null:v.jsx("button",{className:$(e,`${U}-icon-button`),type:r,"aria-label":o,title:a,onClick:c,disabled:u,children:t?v.jsx("img",{className:$(`${U}-icon-image`),src:t,alt:o,loading:"lazy"}):n}),BS="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",US=({onClick:e})=>{const{globalClassName:t,headerConfig:n,mode:r}=At(),o=r==="messaging",a=o?"Open Commerce Client":"Open Copilot",u=o?v.jsx(FS,{className:$(t,`${U}-minimized-icon`)}):v.jsx("img",{src:(n==null?void 0:n.logoUrl)||BS,alt:"Copilot",className:$(t,`${U}-minimized-icon-img`)});return v.jsx(ar,{className:$(t,`${U}-minimized-button`),ariaLabel:a,title:a,icon:u,onClick:e})},HS=()=>{const{globalClassName:e,themeVariables:t}=At(),n=()=>{vu(!1),Ci(!0)};return Is.createPortal(v.jsx("div",{className:$(e,`${U}-minimized-container`),style:t,children:v.jsx(US,{onClick:n})}),document.body)};function zS(e){return mt({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 Vr(){const e=Z.useContext(A0);if(!e)throw new Error("useMessaging must be used within a MessagingProvider");return e}const jS=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 $0(e){return mt({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 $S(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M19 19H5V5h7V3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"},child:[]}]})(e)}function V0(e){return mt({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 VS(e){return mt({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 qS(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12 4-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8z"},child:[]}]})(e)}function YS(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12 8-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"},child:[]}]})(e)}function WS(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"},child:[]}]})(e)}function GS(e){return mt({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 KS(e){return mt({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)}function q0(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"m21.41 11.58-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58s1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41s-.23-1.06-.59-1.42zM13 20.01 4 11V4h7v-.01l9 9-7 7.02z"},child:[]},{tag:"circle",attr:{cx:"6.5",cy:"6.5",r:"1.5"},child:[]}]})(e)}const Ni=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>v.jsx("button",{className:$(`${U}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),QS=({searchConfig:e,globalClassName:t})=>{const n=e.buttonIconUrl;return n?v.jsx("img",{className:$(`${U}-search-button-icon-image`,t),src:n,alt:"",loading:"lazy"}):v.jsx(V0,{size:"16px"})},XS=({className:e,searchConfig:t,globalClassName:n,componentType:r,isLoading:o})=>{if((t==null?void 0:t.buttonType)==="icon")return v.jsx(ar,{className:$(e,n,`cim-${r}-component`,`${U}-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:v.jsx(V0,{size:"16px"}),iconUrl:t==null?void 0:t.buttonIconUrl});const a=(t==null?void 0:t.buttonType)==="icon-text";return v.jsxs(Ni,{className:$(e,n,`cim-${r}-component`,`${U}-search-button`),type:"submit","aria-label":(t==null?void 0:t.buttonAriaLabel)||"",disabled:o,children:[a&&v.jsx(QS,{globalClassName:n,searchConfig:t}),(t==null?void 0:t.buttonLabel)||"Search"]})};function lF(){}function cF(){}function Y0(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 JS=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,ZS=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,eA={};function G0(e,t){return(eA.jsx?ZS:JS).test(e)}const tA=/[ \t\n\f\r]/g;function nA(e){return typeof e=="object"?e.type==="text"?K0(e.value):!1:K0(e)}function K0(e){return e.replace(tA,"")===""}let Rs=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Rs.prototype.normal={},Rs.prototype.property={},Rs.prototype.space=void 0;function Q0(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Rs(n,r,t)}function Ps(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 rA=0;const je=Oi(),Ct=Oi(),Ad=Oi(),ge=Oi(),ot=Oi(),mo=Oi(),Tn=Oi();function Oi(){return nu(2,++rA)}const Cd=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:Ct,commaOrSpaceSeparated:Tn,commaSeparated:mo,number:ge,overloadedBoolean:Ad,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),kd=Object.keys(Cd);let Nd=class extends cn{constructor(t,n,r,o){let a=-1;if(super(t,n),X0(this,"space",o),typeof r=="number")for(;++a<kd.length;){const u=kd[a];X0(this,kd[a],(r&Cd[u])===Cd[u])}}};Nd.prototype.defined=!0;function X0(e,t,n){n&&(e[t]=n)}function go(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const a=new Nd(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Ps(r)]=r,n[Ps(a.attribute)]=r}return new Rs(t,n,e.space)}const J0=go({properties:{ariaActiveDescendant:null,ariaAtomic:Ct,ariaAutoComplete:null,ariaBusy:Ct,ariaChecked:Ct,ariaColCount:ge,ariaColIndex:ge,ariaColSpan:ge,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:Ct,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:Ct,ariaFlowTo:ot,ariaGrabbed:Ct,ariaHasPopup:null,ariaHidden:Ct,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:ge,ariaLive:null,ariaModal:Ct,ariaMultiLine:Ct,ariaMultiSelectable:Ct,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:ge,ariaPressed:Ct,ariaReadOnly:Ct,ariaRelevant:null,ariaRequired:Ct,ariaRoleDescription:ot,ariaRowCount:ge,ariaRowIndex:ge,ariaRowSpan:ge,ariaSelected:Ct,ariaSetSize:ge,ariaSort:null,ariaValueMax:ge,ariaValueMin:ge,ariaValueNow:ge,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Z0(e,t){return t in e?e[t]:t}function eg(e,t){return Z0(e,t.toLowerCase())}const iA=go({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:mo,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:ge,colSpan:null,content:null,contentEditable:Ct,controls:je,controlsList:ot,coords:ge|mo,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:Ad,draggable:Ct,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:ot,height:ge,hidden:Ad,high:ge,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:ge,manifest:null,max:null,maxLength:ge,media:null,method:null,min:null,minLength:ge,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:ge,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:ge,rowSpan:ge,sandbox:ot,scope:null,scoped:je,seamless:je,selected:je,shadowRootClonable:je,shadowRootDelegatesFocus:je,shadowRootMode:null,shape:null,size:ge,sizes:null,slot:null,span:ge,spellCheck:Ct,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ge,step:null,style:null,tabIndex:ge,target:null,title:null,translate:null,type:null,typeMustMatch:je,useMap:null,value:Ct,width:ge,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ot,axis:null,background:null,bgColor:null,border:ge,borderColor:null,bottomMargin:ge,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:ge,leftMargin:ge,link:null,longDesc:null,lowSrc:null,marginHeight:ge,marginWidth:ge,noResize:je,noHref:je,noShade:je,noWrap:je,object:null,profile:null,prompt:null,rev:null,rightMargin:ge,rules:null,scheme:null,scrolling:Ct,standby:null,summary:null,text:null,topMargin:ge,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ge,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:je,disableRemotePlayback:je,prefix:null,property:null,results:ge,security:null,unselectable:null},space:"html",transform:eg}),oA=go({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:Tn,accentHeight:ge,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ge,amplitude:ge,arabicForm:null,ascent:ge,attributeName:null,attributeType:null,azimuth:ge,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ge,by:null,calcMode:null,capHeight:ge,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:ge,diffuseConstant:ge,direction:null,display:null,dur:null,divisor:ge,dominantBaseline:null,download:je,dx:null,dy:null,edgeMode:null,editable:null,elevation:ge,enableBackground:null,end:null,event:null,exponent:ge,externalResourcesRequired:null,fill:null,fillOpacity:ge,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:mo,g2:mo,glyphName:mo,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ge,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ge,horizOriginX:ge,horizOriginY:ge,id:null,ideographic:ge,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ge,k:ge,k1:ge,k2:ge,k3:ge,k4:ge,kernelMatrix:Tn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ge,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:ge,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:ge,overlineThickness:ge,paintOrder:null,panose1:null,path:null,pathLength:ge,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ge,pointsAtY:ge,pointsAtZ:ge,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Tn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Tn,rev:Tn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Tn,requiredFeatures:Tn,requiredFonts:Tn,requiredFormats:Tn,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:ge,specularExponent:ge,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ge,strikethroughThickness:ge,string:null,stroke:null,strokeDashArray:Tn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ge,strokeOpacity:ge,strokeWidth:null,style:null,surfaceScale:ge,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Tn,tabIndex:ge,tableValues:null,target:null,targetX:ge,targetY:ge,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Tn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ge,underlineThickness:ge,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ge,values:null,vAlphabetic:ge,vMathematical:ge,vectorEffect:null,vHanging:ge,vIdeographic:ge,version:null,vertAdvY:ge,vertOriginX:ge,vertOriginY:ge,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ge,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Z0}),tg=go({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()}}),ng=go({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:eg}),rg=go({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),sA={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"},aA=/[A-Z]/g,ig=/-[a-z]/g,uA=/^data[-\w.:]+$/i;function Od(e,t){const n=Ps(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"&&uA.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(ig,cA);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!ig.test(a)){let u=a.replace(aA,lA);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Nd}return new o(r,t)}function lA(e){return"-"+e.toLowerCase()}function cA(e){return e.charAt(1).toUpperCase()}const ku=Q0([J0,iA,tg,ng,rg],"html"),Eo=Q0([J0,oA,tg,ng,rg],"svg");function og(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function sg(e){return e.join(" ").trim()}var yo={},Id,ag;function dA(){if(ag)return Id;ag=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="/",p="*",E="",T="comment",y="declaration";Id=function(_,S){if(typeof _!="string")throw new TypeError("First argument must be a string");if(!_)return[];S=S||{};var A=1,O=1;function R(re){var oe=re.match(t);oe&&(A+=oe.length);var be=re.lastIndexOf(d);O=~be?re.length-be:O+re.length}function z(){var re={line:A,column:O};return function(oe){return oe.position=new W(re),de(),oe}}function W(re){this.start=re,this.end={line:A,column:O},this.source=S.source}W.prototype.content=_;function M(re){var oe=new Error(S.source+":"+A+":"+O+": "+re);if(oe.reason=re,oe.filename=S.source,oe.line=A,oe.column=O,oe.source=_,!S.silent)throw oe}function K(re){var oe=re.exec(_);if(oe){var be=oe[0];return R(be),_=_.slice(be.length),oe}}function de(){K(n)}function xe(re){var oe;for(re=re||[];oe=D();)oe!==!1&&re.push(oe);return re}function D(){var re=z();if(!(h!=_.charAt(0)||p!=_.charAt(1))){for(var oe=2;E!=_.charAt(oe)&&(p!=_.charAt(oe)||h!=_.charAt(oe+1));)++oe;if(oe+=2,E===_.charAt(oe-1))return M("End of comment missing");var be=_.slice(2,oe-2);return O+=2,R(be),_=_.slice(oe),O+=2,re({type:T,comment:be})}}function ne(){var re=z(),oe=K(r);if(oe){if(D(),!K(o))return M("property missing ':'");var be=K(a),Ie=re({type:y,property:x(oe[0].replace(e,E)),value:be?x(be[0].replace(e,E)):E});return K(u),Ie}}function J(){var re=[];xe(re);for(var oe;oe=ne();)oe!==!1&&(re.push(oe),xe(re));return re}return de(),J()};function x(_){return _?_.replace(c,E):E}return Id}var ug;function fA(){if(ug)return yo;ug=1;var e=yo&&yo.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(yo,"__esModule",{value:!0}),yo.default=n;var t=e(dA());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,p=d.value;c?o(h,p,d):p&&(a=a||{},a[h]=p)}}),a}return yo}var Ls={},lg;function hA(){if(lg)return Ls;lg=1,Object.defineProperty(Ls,"__esModule",{value:!0}),Ls.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,p){return p.toUpperCase()},c=function(h,p){return"".concat(p,"-")},d=function(h,p){return p===void 0&&(p={}),a(h)?h:(h=h.toLowerCase(),p.reactCompat?h=h.replace(o,c):h=h.replace(r,c),h.replace(t,u))};return Ls.camelCase=d,Ls}var Ds,cg;function pA(){if(cg)return Ds;cg=1;var e=Ds&&Ds.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(fA()),n=hA();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,Ds=r,Ds}var mA=pA();const gA=We(mA),Nu=dg("end"),ur=dg("start");function dg(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 fg(e){const t=ur(e),n=Nu(e);if(t&&n)return{start:t,end:n}}function Ms(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?hg(e.position):"start"in e||"end"in e?hg(e):"line"in e||"column"in e?Rd(e):""}function Rd(e){return pg(e&&e.line)+":"+pg(e&&e.column)}function hg(e){return Rd(e&&e.start)+"-"+Rd(e&&e.end)}function pg(e){return e&&typeof e=="number"?e:1}class Wt 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=H({},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=Ms(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}}Wt.prototype.file="",Wt.prototype.name="",Wt.prototype.reason="",Wt.prototype.message="",Wt.prototype.stack="",Wt.prototype.column=void 0,Wt.prototype.line=void 0,Wt.prototype.ancestors=void 0,Wt.prototype.cause=void 0,Wt.prototype.fatal=void 0,Wt.prototype.place=void 0,Wt.prototype.ruleId=void 0,Wt.prototype.source=void 0;const Pd={}.hasOwnProperty,EA=new Map,yA=/[A-Z]/g,bA=new Set(["table","tbody","thead","tfoot","tr"]),TA=new Set(["td","th"]),mg="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function xA(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=NA(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=kA(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"?Eo:ku,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=gg(o,e,void 0);return a&&typeof a!="string"?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function gg(e,t,n){if(t.type==="element")return wA(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return _A(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return SA(e,t,n);if(t.type==="mdxjsEsm")return vA(e,t);if(t.type==="root")return AA(e,t,n);if(t.type==="text")return CA(e,t)}function wA(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=Eo,e.schema=o),e.ancestors.push(t);const a=yg(e,t.tagName,!1),u=OA(e,t);let c=Dd(e,t);return bA.has(t.tagName)&&(c=c.filter(function(d){return typeof d=="string"?!nA(d):!0})),Eg(e,u,a,t),Ld(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function _A(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)}Fs(e,t.position)}function vA(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Fs(e,t.position)}function SA(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=Eo,e.schema=o),e.ancestors.push(t);const a=t.name===null?e.Fragment:yg(e,t.name,!0),u=IA(e,t),c=Dd(e,t);return Eg(e,u,a,t),Ld(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function AA(e,t,n){const r={};return Ld(r,Dd(e,t)),e.create(t,e.Fragment,r,n)}function CA(e,t){return t.value}function Eg(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Ld(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function kA(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 NA(e,t){return n;function n(r,o,a,u){const c=Array.isArray(a.children),d=ur(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 OA(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&Pd.call(t.properties,o)){const a=RA(e,o,t.properties[o]);if(a){const[u,c]=a;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&TA.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 IA(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 Fs(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 Fs(e,t.position);else a=r.value===null?!0:r.value;n[o]=a}return n}function Dd(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:EA;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=gg(e,a,u);c!==void 0&&n.push(c)}return n}function RA(e,t,n){const r=Od(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?W0(n):sg(n)),r.property==="style"){let o=typeof n=="object"?n:PA(e,String(n));return e.stylePropertyNameCase==="css"&&(o=LA(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?sA[r.property]||r.property:r.attribute,n]}}function PA(e,t){try{return gA(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new Wt("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=mg+"#cannot-parse-style-attribute",o}}function yg(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=G0(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=G0(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return Pd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);Fs(e)}function Fs(e,t){const n=new Wt("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=mg+"#cannot-handle-mdx-estrees-without-createevaluater",n}function LA(e){const t={};let n;for(n in e)Pd.call(e,n)&&(t[DA(n)]=e[n]);return t}function DA(e){let t=e.replace(yA,MA);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function MA(e){return"-"+e.toLowerCase()}const Md={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"]},FA={};function Fd(e,t){const n=FA,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return bg(e,r,o)}function bg(e,t,n){if(BA(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 Tg(e.children,t,n)}return Array.isArray(e)?Tg(e,t,n):""}function Tg(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=bg(e[o],t,n);return r.join("")}function BA(e){return!!(e&&typeof e=="object")}const xg=document.createElement("i");function Bd(e){const t="&"+e+";";xg.innerHTML=t;const n=xg.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 wg={}.hasOwnProperty;function _g(e){const t={};let n=-1;for(;++n<e.length;)UA(t,e[n]);return t}function UA(e,t){let n;for(n in t){const o=(wg.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let u;if(a)for(u in a){wg.call(o,u)||(o[u]=[]);const c=a[u];HA(o[u],Array.isArray(c)?c:c?[c]:[])}}}function HA(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 vg(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 Yn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const nn=qr(/[A-Za-z]/),Gt=qr(/[\dA-Za-z]/),zA=qr(/[#-'*+\--9=?A-Z^-~]/);function Ou(e){return e!==null&&(e<32||e===127)}const Ud=qr(/\d/),jA=qr(/[\dA-Fa-f]/),$A=qr(/[!-/:-@[-`{-~]/);function Le(e){return e!==null&&e<-2}function it(e){return e!==null&&(e<0||e===32)}function Ge(e){return e===-2||e===-1||e===32}const Iu=qr(new RegExp("\\p{P}|\\p{S}","u")),Ii=qr(/\s/);function qr(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function bo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let u="";if(a===37&&Gt(e.charCodeAt(n+1))&&Gt(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 Qe(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let a=0;return u;function u(d){return Ge(d)?(e.enter(n),c(d)):t(d)}function c(d){return Ge(d)&&a++<o?(e.consume(d),c):(e.exit(n),t(d))}}const VA={tokenize:qA};function qA(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"),Qe(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 YA={tokenize:WA},Sg={tokenize:GA};function WA(e){const t=this,n=[];let r=0,o,a,u;return c;function c(R){if(r<n.length){const z=n[r];return t.containerState=z[1],e.attempt(z[0].continuation,d,h)(R)}return h(R)}function d(R){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&O();const z=t.events.length;let W=z,M;for(;W--;)if(t.events[W][0]==="exit"&&t.events[W][1].type==="chunkFlow"){M=t.events[W][1].end;break}A(r);let K=z;for(;K<t.events.length;)t.events[K][1].end=H({},M),K++;return xn(t.events,W+1,0,t.events.slice(z)),t.events.length=K,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(Sg,p,E)(R)}function p(R){return o&&O(),A(r),T(R)}function E(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(Sg,y,x)(R)}function y(R){return r++,n.push([t.currentConstruct,t.containerState]),T(R)}function x(R){if(R===null){o&&O(),A(0),e.consume(R);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:a}),_(R)}function _(R){if(R===null){S(e.exit("chunkFlow"),!0),A(0),e.consume(R);return}return Le(R)?(e.consume(R),S(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(R),_)}function S(R,z){const W=t.sliceStream(R);if(z&&W.push(null),R.previous=a,a&&(a.next=R),a=R,o.defineSkip(R.start),o.write(W),t.parser.lazy[R.start.line]){let M=o.events.length;for(;M--;)if(o.events[M][1].start.offset<u&&(!o.events[M][1].end||o.events[M][1].end.offset>u))return;const K=t.events.length;let de=K,xe,D;for(;de--;)if(t.events[de][0]==="exit"&&t.events[de][1].type==="chunkFlow"){if(xe){D=t.events[de][1].end;break}xe=!0}for(A(r),M=K;M<t.events.length;)t.events[M][1].end=H({},D),M++;xn(t.events,de+1,0,t.events.slice(K)),t.events.length=M}}function A(R){let z=n.length;for(;z-- >R;){const W=n[z];t.containerState=W[1],W[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 GA(e,t,n){return Qe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function To(e){if(e===null||it(e)||Ii(e))return 1;if(Iu(e))return 2}function Ru(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 Hd={name:"attention",resolveAll:KA,tokenize:QA};function KA(e,t){let n=-1,r,o,a,u,c,d,h,p;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=H({},e[r][1].end),T=H({},e[n][1].start);Ag(E,-d),Ag(T,d),u={type:d>1?"strongSequence":"emphasisSequence",start:E,end:H({},e[r][1].end)},c={type:d>1?"strongSequence":"emphasisSequence",start:H({},e[n][1].start),end:T},a={type:d>1?"strongText":"emphasisText",start:H({},e[r][1].end),end:H({},e[n][1].start)},o={type:d>1?"strong":"emphasis",start:H({},u.start),end:H({},c.end)},e[r][1].end=H({},u.start),e[n][1].start=H({},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,Ru(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?(p=2,h=Rn(h,[["enter",e[n][1],t],["exit",e[n][1],t]])):p=0,xn(e,r-1,n-r+3,h),n=r+h.length-p-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function QA(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=To(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"),p=To(d),E=!p||p===2&&o||n.includes(d),T=!o||o===2&&p||n.includes(r);return h._open=!!(a===42?E:E&&(o||!T)),h._close=!!(a===42?T:T&&(p||!E)),t(d)}}function Ag(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const XA={name:"autolink",tokenize:JA};function JA(e,t,n){let r=0;return o;function o(y){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(y){return nn(y)?(e.consume(y),u):y===64?n(y):h(y)}function u(y){return y===43||y===45||y===46||Gt(y)?(r=1,c(y)):h(y)}function c(y){return y===58?(e.consume(y),r=0,d):(y===43||y===45||y===46||Gt(y))&&r++<32?(e.consume(y),c):(r=0,h(y))}function d(y){return y===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.exit("autolink"),t):y===null||y===32||y===60||Ou(y)?n(y):(e.consume(y),d)}function h(y){return y===64?(e.consume(y),p):zA(y)?(e.consume(y),h):n(y)}function p(y){return Gt(y)?E(y):n(y)}function E(y){return y===46?(e.consume(y),r=0,p):y===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.exit("autolink"),t):T(y)}function T(y){if((y===45||Gt(y))&&r++<63){const x=y===45?T:E;return e.consume(y),x}return n(y)}}const Bs={partial:!0,tokenize:ZA};function ZA(e,t,n){return r;function r(a){return Ge(a)?Qe(e,o,"linePrefix")(a):o(a)}function o(a){return a===null||Le(a)?t(a):n(a)}}const Cg={continuation:{tokenize:tC},exit:nC,name:"blockQuote",tokenize:eC};function eC(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 Ge(u)?(e.enter("blockQuotePrefixWhitespace"),e.consume(u),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(u))}}function tC(e,t,n){const r=this;return o;function o(u){return Ge(u)?Qe(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(u):a(u)}function a(u){return e.attempt(Cg,t,n)(u)}}function nC(e){e.exit("blockQuote")}const kg={name:"characterEscape",tokenize:rC};function rC(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 $A(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const Ng={name:"characterReference",tokenize:iC};function iC(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=Gt,p(E))}function h(E){return E===88||E===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(E),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,u=jA,p):(e.enter("characterReferenceValue"),a=7,u=Ud,p(E))}function p(E){if(E===59&&o){const T=e.exit("characterReferenceValue");return u===Gt&&!Bd(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),p):n(E)}}const Og={partial:!0,tokenize:sC},Ig={concrete:!0,name:"codeFenced",tokenize:oC};function oC(e,t,n){const r=this,o={partial:!0,tokenize:W};let a=0,u=0,c;return d;function d(M){return h(M)}function h(M){const K=r.events[r.events.length-1];return a=K&&K[1].type==="linePrefix"?K[2].sliceSerialize(K[1],!0).length:0,c=M,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),p(M)}function p(M){return M===c?(u++,e.consume(M),p):u<3?n(M):(e.exit("codeFencedFenceSequence"),Ge(M)?Qe(e,E,"whitespace")(M):E(M))}function E(M){return M===null||Le(M)?(e.exit("codeFencedFence"),r.interrupt?t(M):e.check(Og,_,z)(M)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),T(M))}function T(M){return M===null||Le(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),E(M)):Ge(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Qe(e,y,"whitespace")(M)):M===96&&M===c?n(M):(e.consume(M),T)}function y(M){return M===null||Le(M)?E(M):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),x(M))}function x(M){return M===null||Le(M)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),E(M)):M===96&&M===c?n(M):(e.consume(M),x)}function _(M){return e.attempt(o,z,S)(M)}function S(M){return e.enter("lineEnding"),e.consume(M),e.exit("lineEnding"),A}function A(M){return a>0&&Ge(M)?Qe(e,O,"linePrefix",a+1)(M):O(M)}function O(M){return M===null||Le(M)?e.check(Og,_,z)(M):(e.enter("codeFlowValue"),R(M))}function R(M){return M===null||Le(M)?(e.exit("codeFlowValue"),O(M)):(e.consume(M),R)}function z(M){return e.exit("codeFenced"),t(M)}function W(M,K,de){let xe=0;return D;function D(be){return M.enter("lineEnding"),M.consume(be),M.exit("lineEnding"),ne}function ne(be){return M.enter("codeFencedFence"),Ge(be)?Qe(M,J,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(be):J(be)}function J(be){return be===c?(M.enter("codeFencedFenceSequence"),re(be)):de(be)}function re(be){return be===c?(xe++,M.consume(be),re):xe>=u?(M.exit("codeFencedFenceSequence"),Ge(be)?Qe(M,oe,"whitespace")(be):oe(be)):de(be)}function oe(be){return be===null||Le(be)?(M.exit("codeFencedFence"),K(be)):de(be)}}}function sC(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 zd={name:"codeIndented",tokenize:uC},aC={partial:!0,tokenize:lC};function uC(e,t,n){const r=this;return o;function o(h){return e.enter("codeIndented"),Qe(e,a,"linePrefix",5)(h)}function a(h){const p=r.events[r.events.length-1];return p&&p[1].type==="linePrefix"&&p[2].sliceSerialize(p[1],!0).length>=4?u(h):n(h)}function u(h){return h===null?d(h):Le(h)?e.attempt(aC,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 lC(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):Qe(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 cC={name:"codeText",previous:fC,resolve:dC,tokenize:hC};function dC(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 fC(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function hC(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,p(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 p(E){return E===96?(e.consume(E),o++,p):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(E)):(a.type="codeTextData",h(E))}}class pC{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&&Us(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),Us(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Us(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);Us(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Us(this.left,n.reverse())}}}function Us(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 Rg(e){const t={};let n=-1,r,o,a,u,c,d,h;const p=new pC(e);for(;++n<p.length;){for(;n in t;)n=t[n];if(r=p.get(n),n&&r[1].type==="chunkFlow"&&p.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,mC(p,n)),n=t[n],h=!0);else if(r[1]._container){for(a=n,o=void 0;a--;)if(u=p.get(a),u[1].type==="lineEnding"||u[1].type==="lineEndingBlank")u[0]==="enter"&&(o&&(p.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=H({},p.get(o)[1].start),c=p.slice(o,n),c.unshift(r),p.splice(o,n-o+1,c))}}return xn(e,0,Number.POSITIVE_INFINITY,p.slice(0)),!h}function mC(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 p,E,T=-1,y=n,x=0,_=0;const S=[_];for(;y;){for(;e.get(++o)[1]!==y;);a.push(o),y._tokenizer||(p=r.sliceStream(y),y.next||p.push(null),E&&u.defineSkip(y.start),y._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=!0),u.write(p),y._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=void 0)),E=y,y=y.next}for(y=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&&(_=T+1,S.push(_),y._tokenizer=void 0,y.previous=void 0,y=y.next);for(u.events=[],y?(y._tokenizer=void 0,y.previous=void 0):S.pop(),T=S.length;T--;){const A=c.slice(S[T],S[T+1]),O=a.pop();d.push([O,O+A.length-1]),e.splice(O,2,A)}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 gC={resolve:yC,tokenize:bC},EC={partial:!0,tokenize:TC};function yC(e){return Rg(e),e}function bC(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(EC,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 TC(e,t,n){const r=this;return o;function o(u){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),Qe(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 Pg(e,t,n,r,o,a,u,c,d){const h=d||Number.POSITIVE_INFINITY;let p=0;return E;function E(A){return A===60?(e.enter(r),e.enter(o),e.enter(a),e.consume(A),e.exit(a),T):A===null||A===32||A===41||Ou(A)?n(A):(e.enter(r),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),_(A))}function T(A){return A===62?(e.enter(a),e.consume(A),e.exit(a),e.exit(o),e.exit(r),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),y(A))}function y(A){return A===62?(e.exit("chunkString"),e.exit(c),T(A)):A===null||A===60||Le(A)?n(A):(e.consume(A),A===92?x:y)}function x(A){return A===60||A===62||A===92?(e.consume(A),y):y(A)}function _(A){return!p&&(A===null||A===41||it(A))?(e.exit("chunkString"),e.exit(c),e.exit(u),e.exit(r),t(A)):p<h&&A===40?(e.consume(A),p++,_):A===41?(e.consume(A),p--,_):A===null||A===32||A===40||Ou(A)?n(A):(e.consume(A),A===92?S:_)}function S(A){return A===40||A===41||A===92?(e.consume(A),_):_(A)}}function Lg(e,t,n,r,o,a){const u=this;let c=0,d;return h;function h(y){return e.enter(r),e.enter(o),e.consume(y),e.exit(o),e.enter(a),p}function p(y){return c>999||y===null||y===91||y===93&&!d||y===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(y):y===93?(e.exit(a),e.enter(o),e.consume(y),e.exit(o),e.exit(r),t):Le(y)?(e.enter("lineEnding"),e.consume(y),e.exit("lineEnding"),p):(e.enter("chunkString",{contentType:"string"}),E(y))}function E(y){return y===null||y===91||y===93||Le(y)||c++>999?(e.exit("chunkString"),p(y)):(e.consume(y),d||(d=!Ge(y)),y===92?T:E)}function T(y){return y===91||y===92||y===93?(e.consume(y),c++,E):E(y)}}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"),Qe(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),p(T))}function p(T){return T===u||T===null||Le(T)?(e.exit("chunkString"),h(T)):(e.consume(T),T===92?E:p)}function E(T){return T===u||T===92?(e.consume(T),p):p(T)}}function Hs(e,t){let n;return r;function r(o){return Le(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):Ge(o)?Qe(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}const xC={name:"definition",tokenize:_C},wC={partial:!0,tokenize:vC};function _C(e,t,n){const r=this;let o;return a;function a(y){return e.enter("definition"),u(y)}function u(y){return Lg.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(y)}function c(y){return o=Yn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),y===58?(e.enter("definitionMarker"),e.consume(y),e.exit("definitionMarker"),d):n(y)}function d(y){return it(y)?Hs(e,h)(y):h(y)}function h(y){return Pg(e,p,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(y)}function p(y){return e.attempt(wC,E,E)(y)}function E(y){return Ge(y)?Qe(e,T,"whitespace")(y):T(y)}function T(y){return y===null||Le(y)?(e.exit("definition"),r.parser.defined.push(o),t(y)):n(y)}}function vC(e,t,n){return r;function r(c){return it(c)?Hs(e,o)(c):n(c)}function o(c){return Dg(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function a(c){return Ge(c)?Qe(e,u,"whitespace")(c):u(c)}function u(c){return c===null||Le(c)?t(c):n(c)}}const SC={name:"hardBreakEscape",tokenize:AC};function AC(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 CC={name:"headingAtx",resolve:kC,tokenize:NC};function kC(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 NC(e,t,n){let r=0;return o;function o(p){return e.enter("atxHeading"),a(p)}function a(p){return e.enter("atxHeadingSequence"),u(p)}function u(p){return p===35&&r++<6?(e.consume(p),u):p===null||it(p)?(e.exit("atxHeadingSequence"),c(p)):n(p)}function c(p){return p===35?(e.enter("atxHeadingSequence"),d(p)):p===null||Le(p)?(e.exit("atxHeading"),t(p)):Ge(p)?Qe(e,c,"whitespace")(p):(e.enter("atxHeadingText"),h(p))}function d(p){return p===35?(e.consume(p),d):(e.exit("atxHeadingSequence"),c(p))}function h(p){return p===null||p===35||it(p)?(e.exit("atxHeadingText"),c(p)):(e.consume(p),h)}}const OC=["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"],Mg=["pre","script","style","textarea"],IC={concrete:!0,name:"htmlFlow",resolveTo:LC,tokenize:DC},RC={partial:!0,tokenize:FC},PC={partial:!0,tokenize:MC};function LC(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 DC(e,t,n){const r=this;let o,a,u,c,d;return h;function h(k){return p(k)}function p(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,_):k===63?(e.consume(k),o=3,r.interrupt?t:C):nn(k)?(e.consume(k),u=String.fromCharCode(k),S):n(k)}function T(k){return k===45?(e.consume(k),o=2,y):k===91?(e.consume(k),o=5,c=0,x):nn(k)?(e.consume(k),o=4,r.interrupt?t:C):n(k)}function y(k){return k===45?(e.consume(k),r.interrupt?t:C):n(k)}function x(k){const pe="CDATA[";return k===pe.charCodeAt(c++)?(e.consume(k),c===pe.length?r.interrupt?t:J:x):n(k)}function _(k){return nn(k)?(e.consume(k),u=String.fromCharCode(k),S):n(k)}function S(k){if(k===null||k===47||k===62||it(k)){const pe=k===47,Se=u.toLowerCase();return!pe&&!a&&Mg.includes(Se)?(o=1,r.interrupt?t(k):J(k)):OC.includes(u.toLowerCase())?(o=6,pe?(e.consume(k),A):r.interrupt?t(k):J(k)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?O(k):R(k))}return k===45||Gt(k)?(e.consume(k),u+=String.fromCharCode(k),S):n(k)}function A(k){return k===62?(e.consume(k),r.interrupt?t:J):n(k)}function O(k){return Ge(k)?(e.consume(k),O):D(k)}function R(k){return k===47?(e.consume(k),D):k===58||k===95||nn(k)?(e.consume(k),z):Ge(k)?(e.consume(k),R):D(k)}function z(k){return k===45||k===46||k===58||k===95||Gt(k)?(e.consume(k),z):W(k)}function W(k){return k===61?(e.consume(k),M):Ge(k)?(e.consume(k),W):R(k)}function M(k){return k===null||k===60||k===61||k===62||k===96?n(k):k===34||k===39?(e.consume(k),d=k,K):Ge(k)?(e.consume(k),M):de(k)}function K(k){return k===d?(e.consume(k),d=null,xe):k===null||Le(k)?n(k):(e.consume(k),K)}function de(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||it(k)?W(k):(e.consume(k),de)}function xe(k){return k===47||k===62||Ge(k)?R(k):n(k)}function D(k){return k===62?(e.consume(k),ne):n(k)}function ne(k){return k===null||Le(k)?J(k):Ge(k)?(e.consume(k),ne):n(k)}function J(k){return k===45&&o===2?(e.consume(k),Ie):k===60&&o===1?(e.consume(k),fe):k===62&&o===4?(e.consume(k),F):k===63&&o===3?(e.consume(k),C):k===93&&o===5?(e.consume(k),se):Le(k)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(RC,te,re)(k)):k===null||Le(k)?(e.exit("htmlFlowData"),re(k)):(e.consume(k),J)}function re(k){return e.check(PC,oe,te)(k)}function oe(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),be}function be(k){return k===null||Le(k)?re(k):(e.enter("htmlFlowData"),J(k))}function Ie(k){return k===45?(e.consume(k),C):J(k)}function fe(k){return k===47?(e.consume(k),u="",Q):J(k)}function Q(k){if(k===62){const pe=u.toLowerCase();return Mg.includes(pe)?(e.consume(k),F):J(k)}return nn(k)&&u.length<8?(e.consume(k),u+=String.fromCharCode(k),Q):J(k)}function se(k){return k===93?(e.consume(k),C):J(k)}function C(k){return k===62?(e.consume(k),F):k===45&&o===2?(e.consume(k),C):J(k)}function F(k){return k===null||Le(k)?(e.exit("htmlFlowData"),te(k)):(e.consume(k),F)}function te(k){return e.exit("htmlFlow"),t(k)}}function MC(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 FC(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Bs,t,n)}}const BC={name:"htmlText",tokenize:UC};function UC(e,t,n){const r=this;let o,a,u;return c;function c(C){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(C),d}function d(C){return C===33?(e.consume(C),h):C===47?(e.consume(C),W):C===63?(e.consume(C),R):nn(C)?(e.consume(C),de):n(C)}function h(C){return C===45?(e.consume(C),p):C===91?(e.consume(C),a=0,x):nn(C)?(e.consume(C),O):n(C)}function p(C){return C===45?(e.consume(C),y):n(C)}function E(C){return C===null?n(C):C===45?(e.consume(C),T):Le(C)?(u=E,fe(C)):(e.consume(C),E)}function T(C){return C===45?(e.consume(C),y):E(C)}function y(C){return C===62?Ie(C):C===45?T(C):E(C)}function x(C){const F="CDATA[";return C===F.charCodeAt(a++)?(e.consume(C),a===F.length?_:x):n(C)}function _(C){return C===null?n(C):C===93?(e.consume(C),S):Le(C)?(u=_,fe(C)):(e.consume(C),_)}function S(C){return C===93?(e.consume(C),A):_(C)}function A(C){return C===62?Ie(C):C===93?(e.consume(C),A):_(C)}function O(C){return C===null||C===62?Ie(C):Le(C)?(u=O,fe(C)):(e.consume(C),O)}function R(C){return C===null?n(C):C===63?(e.consume(C),z):Le(C)?(u=R,fe(C)):(e.consume(C),R)}function z(C){return C===62?Ie(C):R(C)}function W(C){return nn(C)?(e.consume(C),M):n(C)}function M(C){return C===45||Gt(C)?(e.consume(C),M):K(C)}function K(C){return Le(C)?(u=K,fe(C)):Ge(C)?(e.consume(C),K):Ie(C)}function de(C){return C===45||Gt(C)?(e.consume(C),de):C===47||C===62||it(C)?xe(C):n(C)}function xe(C){return C===47?(e.consume(C),Ie):C===58||C===95||nn(C)?(e.consume(C),D):Le(C)?(u=xe,fe(C)):Ge(C)?(e.consume(C),xe):Ie(C)}function D(C){return C===45||C===46||C===58||C===95||Gt(C)?(e.consume(C),D):ne(C)}function ne(C){return C===61?(e.consume(C),J):Le(C)?(u=ne,fe(C)):Ge(C)?(e.consume(C),ne):xe(C)}function J(C){return C===null||C===60||C===61||C===62||C===96?n(C):C===34||C===39?(e.consume(C),o=C,re):Le(C)?(u=J,fe(C)):Ge(C)?(e.consume(C),J):(e.consume(C),oe)}function re(C){return C===o?(e.consume(C),o=void 0,be):C===null?n(C):Le(C)?(u=re,fe(C)):(e.consume(C),re)}function oe(C){return C===null||C===34||C===39||C===60||C===61||C===96?n(C):C===47||C===62||it(C)?xe(C):(e.consume(C),oe)}function be(C){return C===47||C===62||it(C)?xe(C):n(C)}function Ie(C){return C===62?(e.consume(C),e.exit("htmlTextData"),e.exit("htmlText"),t):n(C)}function fe(C){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),Q}function Q(C){return Ge(C)?Qe(e,se,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(C):se(C)}function se(C){return e.enter("htmlTextData"),u(C)}}const jd={name:"labelEnd",resolveAll:$C,resolveTo:VC,tokenize:qC},HC={tokenize:YC},zC={tokenize:WC},jC={tokenize:GC};function $C(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 VC(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:H({},e[a][1].start),end:H({},e[e.length-1][1].end)},h={type:"label",start:H({},e[a][1].start),end:H({},e[u][1].end)},p={type:"labelText",start:H({},e[a+r+2][1].end),end:H({},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",p,t]]),c=Rn(c,Ru(t.parser.constructs.insideSpan.null,e.slice(a+r+4,u-3),t)),c=Rn(c,[["exit",p,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 qC(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(Yn(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(HC,p,u?p:E)(T):T===91?e.attempt(zC,p,u?h:E)(T):u?p(T):E(T)}function h(T){return e.attempt(jC,p,E)(T)}function p(T){return t(T)}function E(T){return a._balanced=!0,n(T)}}function YC(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)?Hs(e,a)(E):a(E)}function a(E){return E===41?p(E):Pg(e,u,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function u(E){return it(E)?Hs(e,d)(E):p(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):p(E)}function h(E){return it(E)?Hs(e,p)(E):p(E)}function p(E){return E===41?(e.enter("resourceMarker"),e.consume(E),e.exit("resourceMarker"),e.exit("resource"),t):n(E)}}function WC(e,t,n){const r=this;return o;function o(c){return Lg.call(r,e,a,u,"reference","referenceMarker","referenceString")(c)}function a(c){return r.parser.defined.includes(Yn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(c):n(c)}function u(c){return n(c)}}function GC(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 KC={name:"labelStartImage",resolveAll:jd.resolveAll,tokenize:QC};function QC(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 XC={name:"labelStartLink",resolveAll:jd.resolveAll,tokenize:JC};function JC(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 $d={name:"lineEnding",tokenize:ZC};function ZC(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Qe(e,t,"linePrefix")}}const Pu={name:"thematicBreak",tokenize:ek};function ek(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"),Ge(h)?Qe(e,c,"whitespace")(h):c(h))}}const dn={continuation:{tokenize:ik},exit:sk,name:"list",tokenize:rk},tk={partial:!0,tokenize:ak},nk={partial:!0,tokenize:ok};function rk(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(y){const x=r.containerState.type||(y===42||y===43||y===45?"listUnordered":"listOrdered");if(x==="listUnordered"?!r.containerState.marker||y===r.containerState.marker:Ud(y)){if(r.containerState.type||(r.containerState.type=x,e.enter(x,{_container:!0})),x==="listUnordered")return e.enter("listItemPrefix"),y===42||y===45?e.check(Pu,n,h)(y):h(y);if(!r.interrupt||y===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),d(y)}return n(y)}function d(y){return Ud(y)&&++u<10?(e.consume(y),d):(!r.interrupt||u<2)&&(r.containerState.marker?y===r.containerState.marker:y===41||y===46)?(e.exit("listItemValue"),h(y)):n(y)}function h(y){return e.enter("listItemMarker"),e.consume(y),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||y,e.check(Bs,r.interrupt?n:p,e.attempt(tk,T,E))}function p(y){return r.containerState.initialBlankLine=!0,a++,T(y)}function E(y){return Ge(y)?(e.enter("listItemPrefixWhitespace"),e.consume(y),e.exit("listItemPrefixWhitespace"),T):n(y)}function T(y){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(y)}}function ik(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Bs,o,a);function o(c){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Qe(e,t,"listItemIndent",r.containerState.size+1)(c)}function a(c){return r.containerState.furtherBlankLines||!Ge(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(nk,t,u)(c))}function u(c){return r.containerState._closeFlow=!0,r.interrupt=void 0,Qe(e,e.attempt(dn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function ok(e,t,n){const r=this;return Qe(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 sk(e){e.exit(this.containerState.type)}function ak(e,t,n){const r=this;return Qe(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!Ge(a)&&u&&u[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const Fg={name:"setextUnderline",resolveTo:uk,tokenize:lk};function uk(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:H({},e[r][1].start),end:H({},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=H({},e[a][1].end)):e[r][1]=u,e.push(["exit",u,t]),e}function lk(e,t,n){const r=this;let o;return a;function a(h){let p=r.events.length,E;for(;p--;)if(r.events[p][1].type!=="lineEnding"&&r.events[p][1].type!=="linePrefix"&&r.events[p][1].type!=="content"){E=r.events[p][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"),Ge(h)?Qe(e,d,"lineSuffix")(h):d(h))}function d(h){return h===null||Le(h)?(e.exit("setextHeadingLine"),t(h)):n(h)}}const ck={tokenize:dk};function dk(e){const t=this,n=e.attempt(Bs,r,e.attempt(this.parser.constructs.flowInitial,o,Qe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(gC,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 fk={resolveAll:Ug()},hk=Bg("string"),pk=Bg("text");function Bg(e){return{resolveAll:Ug(e==="text"?mk: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(p){return h(p)?a(p):c(p)}function c(p){if(p===null){n.consume(p);return}return n.enter("data"),n.consume(p),d}function d(p){return h(p)?(n.exit("data"),a(p)):(n.consume(p),d)}function h(p){if(p===null)return!0;const E=o[p];let T=-1;if(E)for(;++T<E.length;){const y=E[T];if(!y.previous||y.previous.call(r,r.previous))return!0}return!1}}}function Ug(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 mk(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:H({},r.end)};r.end=H({},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 gk=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:xC},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:Cg},flow:{35:CC,42:Pu,45:[Fg,Pu],60:IC,61:Fg,95:Pu,96:Ig,126:Ig},flowInitial:{[-2]:zd,[-1]:zd,32:zd},insideSpan:{null:[Hd,fk]},string:{38:Ng,92:kg},text:{[-5]:$d,[-4]:$d,[-3]:$d,33:KC,38:Ng,42:Hd,60:[XA,BC],91:XC,92:[SC,kg],93:jd,95:Hd,96:cC}},Symbol.toStringTag,{value:"Module"}));function Ek(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:K(W),check:K(M),consume:O,enter:R,exit:z,interrupt:K(M,{interrupt:!0})},h={code:null,containerState:{},defineSkip:_,events:[],now:x,parser:e,previous:null,sliceSerialize:T,sliceStream:y,write:E};let p=t.tokenize.call(h,d);return t.resolveAll&&a.push(t),h;function E(ne){return u=Rn(u,ne),S(),u[u.length-1]!==null?[]:(de(t,0),h.events=Ru(a,h.events,h),h.events)}function T(ne,J){return bk(y(ne),J)}function y(ne){return yk(u,ne)}function x(){const{_bufferIndex:ne,_index:J,line:re,column:oe,offset:be}=r;return{_bufferIndex:ne,_index:J,line:re,column:oe,offset:be}}function _(ne){o[ne.line]=ne.column,D()}function S(){let ne;for(;r._index<u.length;){const J=u[r._index];if(typeof J=="string")for(ne=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===ne&&r._bufferIndex<J.length;)A(J.charCodeAt(r._bufferIndex));else A(J)}}function A(ne){p=p(ne)}function O(ne){Le(ne)?(r.line++,r.column=1,r.offset+=ne===-3?2:1,D()):ne!==-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=ne}function R(ne,J){const re=J||{};return re.type=ne,re.start=x(),h.events.push(["enter",re,h]),c.push(re),re}function z(ne){const J=c.pop();return J.end=x(),h.events.push(["exit",J,h]),J}function W(ne,J){de(ne,J.from)}function M(ne,J){J.restore()}function K(ne,J){return re;function re(oe,be,Ie){let fe,Q,se,C;return Array.isArray(oe)?te(oe):"tokenize"in oe?te([oe]):F(oe);function F(Ae){return Be;function Be(ve){const qe=ve!==null&&Ae[ve],ut=ve!==null&&Ae.null,pn=[...Array.isArray(qe)?qe:qe?[qe]:[],...Array.isArray(ut)?ut:ut?[ut]:[]];return te(pn)(ve)}}function te(Ae){return fe=Ae,Q=0,Ae.length===0?Ie:k(Ae[Q])}function k(Ae){return Be;function Be(ve){return C=xe(),se=Ae,Ae.partial||(h.currentConstruct=Ae),Ae.name&&h.parser.constructs.disable.null.includes(Ae.name)?Se():Ae.tokenize.call(J?Object.assign(Object.create(h),J):h,d,pe,Se)(ve)}}function pe(Ae){return ne(se,C),be}function Se(Ae){return C.restore(),++Q<fe.length?k(fe[Q]):Ie}}}function de(ne,J){ne.resolveAll&&!a.includes(ne)&&a.push(ne),ne.resolve&&xn(h.events,J,h.events.length-J,ne.resolve(h.events.slice(J),h)),ne.resolveTo&&(h.events=ne.resolveTo(h.events,h))}function xe(){const ne=x(),J=h.previous,re=h.currentConstruct,oe=h.events.length,be=Array.from(c);return{from:oe,restore:Ie};function Ie(){r=ne,h.previous=J,h.currentConstruct=re,h.events.length=oe,c=be,D()}}function D(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function yk(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 bk(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
+ `+b.stack}return{value:i,source:s,stack:g,digest:null}}function Vp(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function qp(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var u9=typeof WeakMap=="function"?WeakMap:Map;function s2(i,s,l){l=Br(-1,l),l.tag=3,l.payload={element:null};var f=s.value;return l.callback=function(){_c||(_c=!0,sm=f),qp(i,s)},l}function a2(i,s,l){l=Br(-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(){qp(i,s)}}var b=i.stateNode;return b!==null&&typeof b.componentDidCatch=="function"&&(l.callback=function(){qp(i,s),typeof f!="function"&&(gi===null?gi=new Set([this]):gi.add(this));var w=s.stack;this.componentDidCatch(s.value,{componentStack:w!==null?w:""})}),l}function u2(i,s,l){var f=i.pingCache;if(f===null){f=i.pingCache=new u9;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=w9.bind(null,i,s,l),s.then(i,i))}function l2(i){do{var s;if((s=i.tag===13)&&(s=i.memoizedState,s=s!==null?s.dehydrated!==null:!0),s)return i;i=i.return}while(i!==null);return null}function c2(i,s,l,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=Br(-1,1),s.tag=2,pi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var l9=H.ReactCurrentOwner,En=!1;function rn(i,s,l,f){s.child=i===null?Ox(s,null,l,f):ds(s,i.child,l,f)}function d2(i,s,l,f,g){l=l.render;var b=s.ref;return hs(s,g),f=Mp(i,s,l,f,b,g),l=Fp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Ur(i,s,g)):(pt&&l&&bp(s),s.flags|=1,rn(i,s,f,g),s.child)}function f2(i,s,l,f,g){if(i===null){var b=l.type;return typeof b=="function"&&!hm(b)&&b.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=b,h2(i,s,b,f,g)):(i=Nc(l.type,null,f,s,s.mode,g),i.ref=s.ref,i.return=s,s.child=i)}if(b=i.child,(i.lanes&g)===0){var w=b.memoizedProps;if(l=l.compare,l=l!==null?l:Da,l(w,f)&&i.ref===s.ref)return Ur(i,s,g)}return s.flags|=1,i=Ti(b,f),i.ref=s.ref,i.return=s,s.child=i}function h2(i,s,l,f,g){if(i!==null){var b=i.memoizedProps;if(Da(b,f)&&i.ref===s.ref)if(En=!1,s.pendingProps=f=b,(i.lanes&g)!==0)(i.flags&131072)!==0&&(En=!0);else return s.lanes=i.lanes,Ur(i,s,g)}return Yp(i,s,l,f,g)}function p2(i,s,l){var f=s.pendingProps,g=f.children,b=i!==null?i.memoizedState:null;if(f.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},at(Es,Nn),Nn|=l;else{if((l&1073741824)===0)return i=b!==null?b.baseLanes|l:l,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,at(Es,Nn),Nn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},f=b!==null?b.baseLanes:l,at(Es,Nn),Nn|=f}else b!==null?(f=b.baseLanes|l,s.memoizedState=null):f=l,at(Es,Nn),Nn|=f;return rn(i,s,g,l),s.child}function m2(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function Yp(i,s,l,f,g){var b=gn(l)?Xi:Xt.current;return b=as(s,b),hs(s,g),l=Mp(i,s,l,f,b,g),f=Fp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Ur(i,s,g)):(pt&&f&&bp(s),s.flags|=1,rn(i,s,l,g),s.child)}function g2(i,s,l,f,g){if(gn(l)){var b=!0;ec(s)}else b=!1;if(hs(s,g),s.stateNode===null)yc(i,s),i2(s,l,f),$p(s,l,f,g),f=!0;else if(i===null){var w=s.stateNode,P=s.memoizedProps;w.props=P;var F=w.context,J=l.contextType;typeof J=="object"&&J!==null?J=Un(J):(J=gn(l)?Xi:Xt.current,J=as(s,J));var ce=l.getDerivedStateFromProps,ge=typeof ce=="function"||typeof w.getSnapshotBeforeUpdate=="function";ge||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(P!==f||F!==J)&&o2(s,w,f,J),hi=!1;var ue=s.memoizedState;w.state=ue,lc(s,f,w,g),F=s.memoizedState,P!==f||ue!==F||mn.current||hi?(typeof ce=="function"&&(jp(s,l,ce,f),F=s.memoizedState),(P=hi||r2(s,l,P,f,ue,F,J))?(ge||typeof w.UNSAFE_componentWillMount!="function"&&typeof w.componentWillMount!="function"||(typeof w.componentWillMount=="function"&&w.componentWillMount(),typeof w.UNSAFE_componentWillMount=="function"&&w.UNSAFE_componentWillMount()),typeof w.componentDidMount=="function"&&(s.flags|=4194308)):(typeof w.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=f,s.memoizedState=F),w.props=f,w.state=F,w.context=J,f=P):(typeof w.componentDidMount=="function"&&(s.flags|=4194308),f=!1)}else{w=s.stateNode,Rx(i,s),P=s.memoizedProps,J=s.type===s.elementType?P:tr(s.type,P),w.props=J,ge=s.pendingProps,ue=w.context,F=l.contextType,typeof F=="object"&&F!==null?F=Un(F):(F=gn(l)?Xi:Xt.current,F=as(s,F));var we=l.getDerivedStateFromProps;(ce=typeof we=="function"||typeof w.getSnapshotBeforeUpdate=="function")||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(P!==ge||ue!==F)&&o2(s,w,f,F),hi=!1,ue=s.memoizedState,w.state=ue,lc(s,f,w,g);var Ce=s.memoizedState;P!==ge||ue!==Ce||mn.current||hi?(typeof we=="function"&&(jp(s,l,we,f),Ce=s.memoizedState),(J=hi||r2(s,l,J,f,ue,Ce,F)||!1)?(ce||typeof w.UNSAFE_componentWillUpdate!="function"&&typeof w.componentWillUpdate!="function"||(typeof w.componentWillUpdate=="function"&&w.componentWillUpdate(f,Ce,F),typeof w.UNSAFE_componentWillUpdate=="function"&&w.UNSAFE_componentWillUpdate(f,Ce,F)),typeof w.componentDidUpdate=="function"&&(s.flags|=4),typeof w.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof w.componentDidUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),s.memoizedProps=f,s.memoizedState=Ce),w.props=f,w.state=Ce,w.context=F,f=J):(typeof w.componentDidUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||P===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),f=!1)}return Wp(i,s,l,f,b,g)}function Wp(i,s,l,f,g,b){m2(i,s);var w=(s.flags&128)!==0;if(!f&&!w)return g&&xx(s,l,!1),Ur(i,s,b);f=s.stateNode,l9.current=s;var P=w&&typeof l.getDerivedStateFromError!="function"?null:f.render();return s.flags|=1,i!==null&&w?(s.child=ds(s,i.child,null,b),s.child=ds(s,null,P,b)):rn(i,s,P,b),s.memoizedState=f.state,g&&xx(s,l,!0),s.child}function E2(i){var s=i.stateNode;s.pendingContext?bx(i,s.pendingContext,s.pendingContext!==s.context):s.context&&bx(i,s.context,!1),Op(i,s.containerInfo)}function y2(i,s,l,f,g){return cs(),_p(g),s.flags|=256,rn(i,s,l,f),s.child}var Gp={dehydrated:null,treeContext:null,retryLane:0};function Kp(i){return{baseLanes:i,cachePool:null,transitions:null}}function b2(i,s,l){var f=s.pendingProps,g=gt.current,b=!1,w=(s.flags&128)!==0,P;if((P=w)||(P=i!==null&&i.memoizedState===null?!1:(g&2)!==0),P?(b=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(g|=1),at(gt,g&1),i===null)return wp(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):(w=f.children,i=f.fallback,b?(f=s.mode,b=s.child,w={mode:"hidden",children:w},(f&1)===0&&b!==null?(b.childLanes=0,b.pendingProps=w):b=Oc(w,f,0,null),i=ao(i,f,l,null),b.return=s,i.return=s,b.sibling=i,s.child=b,s.child.memoizedState=Kp(l),s.memoizedState=Gp,i):Qp(s,w));if(g=i.memoizedState,g!==null&&(P=g.dehydrated,P!==null))return c9(i,s,w,f,P,g,l);if(b){b=f.fallback,w=s.mode,g=i.child,P=g.sibling;var F={mode:"hidden",children:f.children};return(w&1)===0&&s.child!==g?(f=s.child,f.childLanes=0,f.pendingProps=F,s.deletions=null):(f=Ti(g,F),f.subtreeFlags=g.subtreeFlags&14680064),P!==null?b=Ti(P,b):(b=ao(b,w,l,null),b.flags|=2),b.return=s,f.return=s,f.sibling=b,s.child=f,f=b,b=s.child,w=i.child.memoizedState,w=w===null?Kp(l):{baseLanes:w.baseLanes|l,cachePool:null,transitions:w.transitions},b.memoizedState=w,b.childLanes=i.childLanes&~l,s.memoizedState=Gp,f}return b=i.child,i=b.sibling,f=Ti(b,{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 Qp(i,s){return s=Oc({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function Ec(i,s,l,f){return f!==null&&_p(f),ds(s,i.child,null,l),i=Qp(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function c9(i,s,l,f,g,b,w){if(l)return s.flags&256?(s.flags&=-257,f=Vp(Error(n(422))),Ec(i,s,w,f)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(b=f.fallback,g=s.mode,f=Oc({mode:"visible",children:f.children},g,0,null),b=ao(b,g,w,null),b.flags|=2,f.return=s,b.return=s,f.sibling=b,s.child=f,(s.mode&1)!==0&&ds(s,i.child,null,w),s.child.memoizedState=Kp(w),s.memoizedState=Gp,b);if((s.mode&1)===0)return Ec(i,s,w,null);if(g.data==="$!"){if(f=g.nextSibling&&g.nextSibling.dataset,f)var P=f.dgst;return f=P,b=Error(n(419)),f=Vp(b,f,void 0),Ec(i,s,w,f)}if(P=(w&i.childLanes)!==0,En||P){if(f=Ht,f!==null){switch(w&-w){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|w))!==0?0:g,g!==0&&g!==b.retryLane&&(b.retryLane=g,Fr(i,g),ir(f,i,g,-1))}return fm(),f=Vp(Error(n(421))),Ec(i,s,w,f)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=_9.bind(null,i),g._reactRetry=s,null):(i=b.treeContext,kn=li(g.nextSibling),Cn=s,pt=!0,er=null,i!==null&&(Fn[Bn++]=Dr,Fn[Bn++]=Mr,Fn[Bn++]=Ji,Dr=i.id,Mr=i.overflow,Ji=s),s=Qp(s,f.children),s.flags|=4096,s)}function T2(i,s,l){i.lanes|=s;var f=i.alternate;f!==null&&(f.lanes|=s),Cp(i.return,s,l)}function Xp(i,s,l,f,g){var b=i.memoizedState;b===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:f,tail:l,tailMode:g}:(b.isBackwards=s,b.rendering=null,b.renderingStartTime=0,b.last=f,b.tail=l,b.tailMode=g)}function x2(i,s,l){var f=s.pendingProps,g=f.revealOrder,b=f.tail;if(rn(i,s,f.children,l),f=gt.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&&T2(i,l,s);else if(i.tag===19)T2(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(gt,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&&cc(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),Xp(s,!1,g,l,b);break;case"backwards":for(l=null,g=s.child,s.child=null;g!==null;){if(i=g.alternate,i!==null&&cc(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}Xp(s,!0,l,null,b);break;case"together":Xp(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function yc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function Ur(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),ro|=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=Ti(i,i.pendingProps),s.child=l,l.return=s;i.sibling!==null;)i=i.sibling,l=l.sibling=Ti(i,i.pendingProps),l.return=s;l.sibling=null}return s.child}function d9(i,s,l){switch(s.tag){case 3:E2(s),cs();break;case 5:Dx(s);break;case 1:gn(s.type)&&ec(s);break;case 4:Op(s,s.stateNode.containerInfo);break;case 10:var f=s.type._context,g=s.memoizedProps.value;at(sc,f._currentValue),f._currentValue=g;break;case 13:if(f=s.memoizedState,f!==null)return f.dehydrated!==null?(at(gt,gt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?b2(i,s,l):(at(gt,gt.current&1),i=Ur(i,s,l),i!==null?i.sibling:null);at(gt,gt.current&1);break;case 19:if(f=(l&s.childLanes)!==0,(i.flags&128)!==0){if(f)return x2(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),at(gt,gt.current),f)break;return null;case 22:case 23:return s.lanes=0,p2(i,s,l)}return Ur(i,s,l)}var w2,Jp,_2,v2;w2=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}},Jp=function(){},_2=function(i,s,l,f){var g=i.memoizedProps;if(g!==f){i=s.stateNode,to(wr.current);var b=null;switch(l){case"input":g=Xn(i,g),f=Xn(i,f),b=[];break;case"select":g=C({},g,{value:void 0}),f=C({},f,{value:void 0}),b=[];break;case"textarea":g=ba(i,g),f=ba(i,f),b=[];break;default:typeof g.onClick!="function"&&typeof f.onClick=="function"&&(i.onclick=Xl)}$t(l,f);var w;l=null;for(J in g)if(!f.hasOwnProperty(J)&&g.hasOwnProperty(J)&&g[J]!=null)if(J==="style"){var P=g[J];for(w in P)P.hasOwnProperty(w)&&(l||(l={}),l[w]="")}else J!=="dangerouslySetInnerHTML"&&J!=="children"&&J!=="suppressContentEditableWarning"&&J!=="suppressHydrationWarning"&&J!=="autoFocus"&&(o.hasOwnProperty(J)?b||(b=[]):(b=b||[]).push(J,null));for(J in f){var F=f[J];if(P=g!=null?g[J]:void 0,f.hasOwnProperty(J)&&F!==P&&(F!=null||P!=null))if(J==="style")if(P){for(w in P)!P.hasOwnProperty(w)||F&&F.hasOwnProperty(w)||(l||(l={}),l[w]="");for(w in F)F.hasOwnProperty(w)&&P[w]!==F[w]&&(l||(l={}),l[w]=F[w])}else l||(b||(b=[]),b.push(J,l)),l=F;else J==="dangerouslySetInnerHTML"?(F=F?F.__html:void 0,P=P?P.__html:void 0,F!=null&&P!==F&&(b=b||[]).push(J,F)):J==="children"?typeof F!="string"&&typeof F!="number"||(b=b||[]).push(J,""+F):J!=="suppressContentEditableWarning"&&J!=="suppressHydrationWarning"&&(o.hasOwnProperty(J)?(F!=null&&J==="onScroll"&&lt("scroll",i),b||P===F||(b=[])):(b=b||[]).push(J,F))}l&&(b=b||[]).push("style",l);var J=b;(s.updateQueue=J)&&(s.flags|=4)}},v2=function(i,s,l,f){l!==f&&(s.flags|=4)};function Qa(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 Zt(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 f9(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 Zt(s),null;case 1:return gn(s.type)&&Zl(),Zt(s),null;case 3:return f=s.stateNode,ps(),ct(mn),ct(Xt),Pp(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(i===null||i.child===null)&&(ic(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,er!==null&&(lm(er),er=null))),Jp(i,s),Zt(s),null;case 5:Ip(s);var g=to(qa.current);if(l=s.type,i!==null&&s.stateNode!=null)_2(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 Zt(s),null}if(i=to(wr.current),ic(s)){f=s.stateNode,l=s.type;var b=s.memoizedProps;switch(f[xr]=s,f[Ha]=b,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<Fa.length;g++)lt(Fa[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":Ea(f,b),lt("invalid",f);break;case"select":f._wrapperState={wasMultiple:!!b.multiple},lt("invalid",f);break;case"textarea":Cl(f,b),lt("invalid",f)}$t(l,b),g=null;for(var w in b)if(b.hasOwnProperty(w)){var P=b[w];w==="children"?typeof P=="string"?f.textContent!==P&&(b.suppressHydrationWarning!==!0&&Ql(f.textContent,P,i),g=["children",P]):typeof P=="number"&&f.textContent!==""+P&&(b.suppressHydrationWarning!==!0&&Ql(f.textContent,P,i),g=["children",""+P]):o.hasOwnProperty(w)&&P!=null&&w==="onScroll"&&lt("scroll",f)}switch(l){case"input":pn(f),Al(f,b,!0);break;case"textarea":pn(f),Nl(f);break;case"select":case"option":break;default:typeof b.onClick=="function"&&(f.onclick=Xl)}f=g,s.updateQueue=f,f!==null&&(s.flags|=4)}else{w=g.nodeType===9?g:g.ownerDocument,i==="http://www.w3.org/1999/xhtml"&&(i=ie(l)),i==="http://www.w3.org/1999/xhtml"?l==="script"?(i=w.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild)):typeof f.is=="string"?i=w.createElement(l,{is:f.is}):(i=w.createElement(l),l==="select"&&(w=i,f.multiple?w.multiple=!0:f.size&&(w.size=f.size))):i=w.createElementNS(i,l),i[xr]=s,i[Ha]=f,w2(i,s,!1,!1),s.stateNode=i;e:{switch(w=br(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<Fa.length;g++)lt(Fa[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":Ea(i,f),g=Xn(i,f),lt("invalid",i);break;case"option":g=f;break;case"select":i._wrapperState={wasMultiple:!!f.multiple},g=C({},f,{value:void 0}),lt("invalid",i);break;case"textarea":Cl(i,f),g=ba(i,f),lt("invalid",i);break;default:g=f}$t(l,g),P=g;for(b in P)if(P.hasOwnProperty(b)){var F=P[b];b==="style"?ni(i,F):b==="dangerouslySetInnerHTML"?(F=F?F.__html:void 0,F!=null&&Ye(i,F)):b==="children"?typeof F=="string"?(l!=="textarea"||F!=="")&&Xe(i,F):typeof F=="number"&&Xe(i,""+F):b!=="suppressContentEditableWarning"&&b!=="suppressHydrationWarning"&&b!=="autoFocus"&&(o.hasOwnProperty(b)?F!=null&&b==="onScroll"&&lt("scroll",i):F!=null&&R(i,b,F,w))}switch(l){case"input":pn(i),Al(i,f,!1);break;case"textarea":pn(i),Nl(i);break;case"option":f.value!=null&&i.setAttribute("value",""+ve(f.value));break;case"select":i.multiple=!!f.multiple,b=f.value,b!=null?ti(i,!!f.multiple,b,!1):f.defaultValue!=null&&ti(i,!!f.multiple,f.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=Xl)}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 Zt(s),null;case 6:if(i&&s.stateNode!=null)v2(i,s,i.memoizedProps,f);else{if(typeof f!="string"&&s.stateNode===null)throw Error(n(166));if(l=to(qa.current),to(wr.current),ic(s)){if(f=s.stateNode,l=s.memoizedProps,f[xr]=s,(b=f.nodeValue!==l)&&(i=Cn,i!==null))switch(i.tag){case 3:Ql(f.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Ql(f.nodeValue,l,(i.mode&1)!==0)}b&&(s.flags|=4)}else f=(l.nodeType===9?l:l.ownerDocument).createTextNode(f),f[xr]=s,s.stateNode=f}return Zt(s),null;case 13:if(ct(gt),f=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(pt&&kn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)Cx(),cs(),s.flags|=98560,b=!1;else if(b=ic(s),f!==null&&f.dehydrated!==null){if(i===null){if(!b)throw Error(n(318));if(b=s.memoizedState,b=b!==null?b.dehydrated:null,!b)throw Error(n(317));b[xr]=s}else cs(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;Zt(s),b=!1}else er!==null&&(lm(er),er=null),b=!0;if(!b)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||(gt.current&1)!==0?Pt===0&&(Pt=3):fm())),s.updateQueue!==null&&(s.flags|=4),Zt(s),null);case 4:return ps(),Jp(i,s),i===null&&Ba(s.stateNode.containerInfo),Zt(s),null;case 10:return Ap(s.type._context),Zt(s),null;case 17:return gn(s.type)&&Zl(),Zt(s),null;case 19:if(ct(gt),b=s.memoizedState,b===null)return Zt(s),null;if(f=(s.flags&128)!==0,w=b.rendering,w===null)if(f)Qa(b,!1);else{if(Pt!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(w=cc(i),w!==null){for(s.flags|=128,Qa(b,!1),f=w.updateQueue,f!==null&&(s.updateQueue=f,s.flags|=4),s.subtreeFlags=0,f=l,l=s.child;l!==null;)b=l,i=f,b.flags&=14680066,w=b.alternate,w===null?(b.childLanes=0,b.lanes=i,b.child=null,b.subtreeFlags=0,b.memoizedProps=null,b.memoizedState=null,b.updateQueue=null,b.dependencies=null,b.stateNode=null):(b.childLanes=w.childLanes,b.lanes=w.lanes,b.child=w.child,b.subtreeFlags=0,b.deletions=null,b.memoizedProps=w.memoizedProps,b.memoizedState=w.memoizedState,b.updateQueue=w.updateQueue,b.type=w.type,i=w.dependencies,b.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return at(gt,gt.current&1|2),s.child}i=i.sibling}b.tail!==null&&_t()>ys&&(s.flags|=128,f=!0,Qa(b,!1),s.lanes=4194304)}else{if(!f)if(i=cc(w),i!==null){if(s.flags|=128,f=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),Qa(b,!0),b.tail===null&&b.tailMode==="hidden"&&!w.alternate&&!pt)return Zt(s),null}else 2*_t()-b.renderingStartTime>ys&&l!==1073741824&&(s.flags|=128,f=!0,Qa(b,!1),s.lanes=4194304);b.isBackwards?(w.sibling=s.child,s.child=w):(l=b.last,l!==null?l.sibling=w:s.child=w,b.last=w)}return b.tail!==null?(s=b.tail,b.rendering=s,b.tail=s.sibling,b.renderingStartTime=_t(),s.sibling=null,l=gt.current,at(gt,f?l&1|2:l&1),s):(Zt(s),null);case 22:case 23:return dm(),f=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==f&&(s.flags|=8192),f&&(s.mode&1)!==0?(Nn&1073741824)!==0&&(Zt(s),s.subtreeFlags&6&&(s.flags|=8192)):Zt(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function h9(i,s){switch(Tp(s),s.tag){case 1:return gn(s.type)&&Zl(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return ps(),ct(mn),ct(Xt),Pp(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return Ip(s),null;case 13:if(ct(gt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));cs()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ct(gt),null;case 4:return ps(),null;case 10:return Ap(s.type._context),null;case 22:case 23:return dm(),null;case 24:return null;default:return null}}var bc=!1,en=!1,p9=typeof WeakSet=="function"?WeakSet:Set,_e=null;function gs(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(f){bt(i,s,f)}else l.current=null}function Zp(i,s,l){try{l()}catch(f){bt(i,s,f)}}var S2=!1;function m9(i,s){if(dp=Ul,i=rx(),rp(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,b=f.focusNode;f=f.focusOffset;try{l.nodeType,b.nodeType}catch(be){l=null;break e}var w=0,P=-1,F=-1,J=0,ce=0,ge=i,ue=null;t:for(;;){for(var we;ge!==l||g!==0&&ge.nodeType!==3||(P=w+g),ge!==b||f!==0&&ge.nodeType!==3||(F=w+f),ge.nodeType===3&&(w+=ge.nodeValue.length),(we=ge.firstChild)!==null;)ue=ge,ge=we;for(;;){if(ge===i)break t;if(ue===l&&++J===g&&(P=w),ue===b&&++ce===f&&(F=w),(we=ge.nextSibling)!==null)break;ge=ue,ue=ge.parentNode}ge=we}l=P===-1||F===-1?null:{start:P,end:F}}else l=null}l=l||{start:0,end:0}}else l=null;for(fp={focusedElem:i,selectionRange:l},Ul=!1,_e=s;_e!==null;)if(s=_e,i=s.child,(s.subtreeFlags&1028)!==0&&i!==null)i.return=s,_e=i;else for(;_e!==null;){s=_e;try{var Ce=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(Ce!==null){var Ne=Ce.memoizedProps,vt=Ce.memoizedState,q=s.stateNode,j=q.getSnapshotBeforeUpdate(s.elementType===s.type?Ne:tr(s.type,Ne),vt);q.__reactInternalSnapshotBeforeUpdate=j}break;case 3:var G=s.stateNode.containerInfo;G.nodeType===1?G.textContent="":G.nodeType===9&&G.documentElement&&G.removeChild(G.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(be){bt(s,s.return,be)}if(i=s.sibling,i!==null){i.return=s.return,_e=i;break}_e=s.return}return Ce=S2,S2=!1,Ce}function Xa(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 b=g.destroy;g.destroy=void 0,b!==void 0&&Zp(s,l,b)}g=g.next}while(g!==f)}}function Tc(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 em(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 A2(i){var s=i.alternate;s!==null&&(i.alternate=null,A2(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[xr],delete s[Ha],delete s[gp],delete s[XM],delete s[JM])),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 C2(i){return i.tag===5||i.tag===3||i.tag===4}function k2(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||C2(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 tm(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=Xl));else if(f!==4&&(i=i.child,i!==null))for(tm(i,s,l),i=i.sibling;i!==null;)tm(i,s,l),i=i.sibling}function nm(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(nm(i,s,l),i=i.sibling;i!==null;)nm(i,s,l),i=i.sibling}var Vt=null,nr=!1;function mi(i,s,l){for(l=l.child;l!==null;)N2(i,s,l),l=l.sibling}function N2(i,s,l){if(Tr&&typeof Tr.onCommitFiberUnmount=="function")try{Tr.onCommitFiberUnmount(Pl,l)}catch(P){}switch(l.tag){case 5:en||gs(l,s);case 6:var f=Vt,g=nr;Vt=null,mi(i,s,l),Vt=f,nr=g,Vt!==null&&(nr?(i=Vt,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):Vt.removeChild(l.stateNode));break;case 18:Vt!==null&&(nr?(i=Vt,l=l.stateNode,i.nodeType===8?mp(i.parentNode,l):i.nodeType===1&&mp(i,l),Na(i)):mp(Vt,l.stateNode));break;case 4:f=Vt,g=nr,Vt=l.stateNode.containerInfo,nr=!0,mi(i,s,l),Vt=f,nr=g;break;case 0:case 11:case 14:case 15:if(!en&&(f=l.updateQueue,f!==null&&(f=f.lastEffect,f!==null))){g=f=f.next;do{var b=g,w=b.destroy;b=b.tag,w!==void 0&&((b&2)!==0||(b&4)!==0)&&Zp(l,s,w),g=g.next}while(g!==f)}mi(i,s,l);break;case 1:if(!en&&(gs(l,s),f=l.stateNode,typeof f.componentWillUnmount=="function"))try{f.props=l.memoizedProps,f.state=l.memoizedState,f.componentWillUnmount()}catch(P){bt(l,s,P)}mi(i,s,l);break;case 21:mi(i,s,l);break;case 22:l.mode&1?(en=(f=en)||l.memoizedState!==null,mi(i,s,l),en=f):mi(i,s,l);break;default:mi(i,s,l)}}function O2(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new p9),s.forEach(function(f){var g=v9.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 b=i,w=s,P=w;e:for(;P!==null;){switch(P.tag){case 5:Vt=P.stateNode,nr=!1;break e;case 3:Vt=P.stateNode.containerInfo,nr=!0;break e;case 4:Vt=P.stateNode.containerInfo,nr=!0;break e}P=P.return}if(Vt===null)throw Error(n(160));N2(b,w,g),Vt=null,nr=!1;var F=g.alternate;F!==null&&(F.return=null),g.return=null}catch(J){bt(g,s,J)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)I2(s,i),s=s.sibling}function I2(i,s){var l=i.alternate,f=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(rr(s,i),vr(i),f&4){try{Xa(3,i,i.return),Tc(3,i)}catch(Ne){bt(i,i.return,Ne)}try{Xa(5,i,i.return)}catch(Ne){bt(i,i.return,Ne)}}break;case 1:rr(s,i),vr(i),f&512&&l!==null&&gs(l,l.return);break;case 5:if(rr(s,i),vr(i),f&512&&l!==null&&gs(l,l.return),i.flags&32){var g=i.stateNode;try{Xe(g,"")}catch(Ne){bt(i,i.return,Ne)}}if(f&4&&(g=i.stateNode,g!=null)){var b=i.memoizedProps,w=l!==null?l.memoizedProps:b,P=i.type,F=i.updateQueue;if(i.updateQueue=null,F!==null)try{P==="input"&&b.type==="radio"&&b.name!=null&&ya(g,b),br(P,w);var J=br(P,b);for(w=0;w<F.length;w+=2){var ce=F[w],ge=F[w+1];ce==="style"?ni(g,ge):ce==="dangerouslySetInnerHTML"?Ye(g,ge):ce==="children"?Xe(g,ge):R(g,ce,ge,J)}switch(P){case"input":Go(g,b);break;case"textarea":kl(g,b);break;case"select":var ue=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!b.multiple;var we=b.value;we!=null?ti(g,!!b.multiple,we,!1):ue!==!!b.multiple&&(b.defaultValue!=null?ti(g,!!b.multiple,b.defaultValue,!0):ti(g,!!b.multiple,b.multiple?[]:"",!1))}g[Ha]=b}catch(Ne){bt(i,i.return,Ne)}}break;case 6:if(rr(s,i),vr(i),f&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,b=i.memoizedProps;try{g.nodeValue=b}catch(Ne){bt(i,i.return,Ne)}}break;case 3:if(rr(s,i),vr(i),f&4&&l!==null&&l.memoizedState.isDehydrated)try{Na(s.containerInfo)}catch(Ne){bt(i,i.return,Ne)}break;case 4:rr(s,i),vr(i);break;case 13:rr(s,i),vr(i),g=i.child,g.flags&8192&&(b=g.memoizedState!==null,g.stateNode.isHidden=b,!b||g.alternate!==null&&g.alternate.memoizedState!==null||(om=_t())),f&4&&O2(i);break;case 22:if(ce=l!==null&&l.memoizedState!==null,i.mode&1?(en=(J=en)||ce,rr(s,i),en=J):rr(s,i),vr(i),f&8192){if(J=i.memoizedState!==null,(i.stateNode.isHidden=J)&&!ce&&(i.mode&1)!==0)for(_e=i,ce=i.child;ce!==null;){for(ge=_e=ce;_e!==null;){switch(ue=_e,we=ue.child,ue.tag){case 0:case 11:case 14:case 15:Xa(4,ue,ue.return);break;case 1:gs(ue,ue.return);var Ce=ue.stateNode;if(typeof Ce.componentWillUnmount=="function"){f=ue,l=ue.return;try{s=f,Ce.props=s.memoizedProps,Ce.state=s.memoizedState,Ce.componentWillUnmount()}catch(Ne){bt(f,l,Ne)}}break;case 5:gs(ue,ue.return);break;case 22:if(ue.memoizedState!==null){L2(ge);continue}}we!==null?(we.return=ue,_e=we):L2(ge)}ce=ce.sibling}e:for(ce=null,ge=i;;){if(ge.tag===5){if(ce===null){ce=ge;try{g=ge.stateNode,J?(b=g.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none"):(P=ge.stateNode,F=ge.memoizedProps.style,w=F!=null&&F.hasOwnProperty("display")?F.display:null,P.style.display=Mn("display",w))}catch(Ne){bt(i,i.return,Ne)}}}else if(ge.tag===6){if(ce===null)try{ge.stateNode.nodeValue=J?"":ge.memoizedProps}catch(Ne){bt(i,i.return,Ne)}}else if((ge.tag!==22&&ge.tag!==23||ge.memoizedState===null||ge===i)&&ge.child!==null){ge.child.return=ge,ge=ge.child;continue}if(ge===i)break e;for(;ge.sibling===null;){if(ge.return===null||ge.return===i)break e;ce===ge&&(ce=null),ge=ge.return}ce===ge&&(ce=null),ge.sibling.return=ge.return,ge=ge.sibling}}break;case 19:rr(s,i),vr(i),f&4&&O2(i);break;case 21:break;default:rr(s,i),vr(i)}}function vr(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(C2(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&&(Xe(g,""),f.flags&=-33);var b=k2(i);nm(i,b,g);break;case 3:case 4:var w=f.stateNode.containerInfo,P=k2(i);tm(i,P,w);break;default:throw Error(n(161))}}catch(F){bt(i,i.return,F)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function g9(i,s,l){_e=i,R2(i)}function R2(i,s,l){for(var f=(i.mode&1)!==0;_e!==null;){var g=_e,b=g.child;if(g.tag===22&&f){var w=g.memoizedState!==null||bc;if(!w){var P=g.alternate,F=P!==null&&P.memoizedState!==null||en;P=bc;var J=en;if(bc=w,(en=F)&&!J)for(_e=g;_e!==null;)w=_e,F=w.child,w.tag===22&&w.memoizedState!==null?D2(g):F!==null?(F.return=w,_e=F):D2(g);for(;b!==null;)_e=b,R2(b),b=b.sibling;_e=g,bc=P,en=J}P2(i)}else(g.subtreeFlags&8772)!==0&&b!==null?(b.return=g,_e=b):P2(i)}}function P2(i){for(;_e!==null;){var s=_e;if((s.flags&8772)!==0){var l=s.alternate;try{if((s.flags&8772)!==0)switch(s.tag){case 0:case 11:case 15:en||Tc(5,s);break;case 1:var f=s.stateNode;if(s.flags&4&&!en)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 b=s.updateQueue;b!==null&&Lx(s,b,f);break;case 3:var w=s.updateQueue;if(w!==null){if(l=null,s.child!==null)switch(s.child.tag){case 5:l=s.child.stateNode;break;case 1:l=s.child.stateNode}Lx(s,w,l)}break;case 5:var P=s.stateNode;if(l===null&&s.flags&4){l=P;var F=s.memoizedProps;switch(s.type){case"button":case"input":case"select":case"textarea":F.autoFocus&&l.focus();break;case"img":F.src&&(l.src=F.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(s.memoizedState===null){var J=s.alternate;if(J!==null){var ce=J.memoizedState;if(ce!==null){var ge=ce.dehydrated;ge!==null&&Na(ge)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}en||s.flags&512&&em(s)}catch(ue){bt(s,s.return,ue)}}if(s===i){_e=null;break}if(l=s.sibling,l!==null){l.return=s.return,_e=l;break}_e=s.return}}function L2(i){for(;_e!==null;){var s=_e;if(s===i){_e=null;break}var l=s.sibling;if(l!==null){l.return=s.return,_e=l;break}_e=s.return}}function D2(i){for(;_e!==null;){var s=_e;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{Tc(4,s)}catch(F){bt(s,l,F)}break;case 1:var f=s.stateNode;if(typeof f.componentDidMount=="function"){var g=s.return;try{f.componentDidMount()}catch(F){bt(s,g,F)}}var b=s.return;try{em(s)}catch(F){bt(s,b,F)}break;case 5:var w=s.return;try{em(s)}catch(F){bt(s,w,F)}}}catch(F){bt(s,s.return,F)}if(s===i){_e=null;break}var P=s.sibling;if(P!==null){P.return=s.return,_e=P;break}_e=s.return}}var E9=Math.ceil,xc=H.ReactCurrentDispatcher,rm=H.ReactCurrentOwner,zn=H.ReactCurrentBatchConfig,Je=0,Ht=null,Nt=null,qt=0,Nn=0,Es=ci(0),Pt=0,Ja=null,ro=0,wc=0,im=0,Za=null,yn=null,om=0,ys=1/0,Hr=null,_c=!1,sm=null,gi=null,vc=!1,Ei=null,Sc=0,eu=0,am=null,Ac=-1,Cc=0;function on(){return(Je&6)!==0?_t():Ac!==-1?Ac:Ac=_t()}function yi(i){return(i.mode&1)===0?1:(Je&2)!==0&&qt!==0?qt&-qt:e9.transition!==null?(Cc===0&&(Cc=kT()),Cc):(i=nt,i!==0||(i=window.event,i=i===void 0?16:FT(i.type)),i)}function ir(i,s,l,f){if(50<eu)throw eu=0,am=null,Error(n(185));va(i,l,f),((Je&2)===0||i!==Ht)&&(i===Ht&&((Je&2)===0&&(wc|=l),Pt===4&&bi(i,qt)),bn(i,f),l===1&&Je===0&&(s.mode&1)===0&&(ys=_t()+500,tc&&fi()))}function bn(i,s){var l=i.callbackNode;eM(i,s);var f=Ml(i,i===Ht?qt:0);if(f===0)l!==null&&ST(l),i.callbackNode=null,i.callbackPriority=0;else if(s=f&-f,i.callbackPriority!==s){if(l!=null&&ST(l),s===1)i.tag===0?ZM(F2.bind(null,i)):wx(F2.bind(null,i)),KM(function(){(Je&6)===0&&fi()}),l=null;else{switch(NT(f)){case 1:l=Hh;break;case 4:l=AT;break;case 16:l=Rl;break;case 536870912:l=CT;break;default:l=Rl}l=q2(l,M2.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function M2(i,s){if(Ac=-1,Cc=0,(Je&6)!==0)throw Error(n(327));var l=i.callbackNode;if(bs()&&i.callbackNode!==l)return null;var f=Ml(i,i===Ht?qt:0);if(f===0)return null;if((f&30)!==0||(f&i.expiredLanes)!==0||s)s=kc(i,f);else{s=f;var g=Je;Je|=2;var b=U2();(Ht!==i||qt!==s)&&(Hr=null,ys=_t()+500,oo(i,s));do try{T9();break}catch(P){B2(i,P)}while(!0);Sp(),xc.current=b,Je=g,Nt!==null?s=0:(Ht=null,qt=0,s=Pt)}if(s!==0){if(s===2&&(g=zh(i),g!==0&&(f=g,s=um(i,g))),s===1)throw l=Ja,oo(i,0),bi(i,f),bn(i,_t()),l;if(s===6)bi(i,f);else{if(g=i.current.alternate,(f&30)===0&&!y9(g)&&(s=kc(i,f),s===2&&(b=zh(i),b!==0&&(f=b,s=um(i,b))),s===1))throw l=Ja,oo(i,0),bi(i,f),bn(i,_t()),l;switch(i.finishedWork=g,i.finishedLanes=f,s){case 0:case 1:throw Error(n(345));case 2:so(i,yn,Hr);break;case 3:if(bi(i,f),(f&130023424)===f&&(s=om+500-_t(),10<s)){if(Ml(i,0)!==0)break;if(g=i.suspendedLanes,(g&f)!==f){on(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=pp(so.bind(null,i,yn,Hr),s);break}so(i,yn,Hr);break;case 4:if(bi(i,f),(f&4194240)===f)break;for(s=i.eventTimes,g=-1;0<f;){var w=31-Jn(f);b=1<<w,w=s[w],w>g&&(g=w),f&=~b}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*E9(f/1960))-f,10<f){i.timeoutHandle=pp(so.bind(null,i,yn,Hr),f);break}so(i,yn,Hr);break;case 5:so(i,yn,Hr);break;default:throw Error(n(329))}}}return bn(i,_t()),i.callbackNode===l?M2.bind(null,i):null}function um(i,s){var l=Za;return i.current.memoizedState.isDehydrated&&(oo(i,s).flags|=256),i=kc(i,s),i!==2&&(s=yn,yn=l,s!==null&&lm(s)),i}function lm(i){yn===null?yn=i:yn.push.apply(yn,i)}function y9(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],b=g.getSnapshot;g=g.value;try{if(!Zn(b(),g))return!1}catch(w){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 bi(i,s){for(s&=~im,s&=~wc,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 F2(i){if((Je&6)!==0)throw Error(n(327));bs();var s=Ml(i,0);if((s&1)===0)return bn(i,_t()),null;var l=kc(i,s);if(i.tag!==0&&l===2){var f=zh(i);f!==0&&(s=f,l=um(i,f))}if(l===1)throw l=Ja,oo(i,0),bi(i,s),bn(i,_t()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,so(i,yn,Hr),bn(i,_t()),null}function cm(i,s){var l=Je;Je|=1;try{return i(s)}finally{Je=l,Je===0&&(ys=_t()+500,tc&&fi())}}function io(i){Ei!==null&&Ei.tag===0&&(Je&6)===0&&bs();var s=Je;Je|=1;var l=zn.transition,f=nt;try{if(zn.transition=null,nt=1,i)return i()}finally{nt=f,zn.transition=l,Je=s,(Je&6)===0&&fi()}}function dm(){Nn=Es.current,ct(Es)}function oo(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,GM(l)),Nt!==null)for(l=Nt.return;l!==null;){var f=l;switch(Tp(f),f.tag){case 1:f=f.type.childContextTypes,f!=null&&Zl();break;case 3:ps(),ct(mn),ct(Xt),Pp();break;case 5:Ip(f);break;case 4:ps();break;case 13:ct(gt);break;case 19:ct(gt);break;case 10:Ap(f.type._context);break;case 22:case 23:dm()}l=l.return}if(Ht=i,Nt=i=Ti(i.current,null),qt=Nn=s,Pt=0,Ja=null,im=wc=ro=0,yn=Za=null,eo!==null){for(s=0;s<eo.length;s++)if(l=eo[s],f=l.interleaved,f!==null){l.interleaved=null;var g=f.next,b=l.pending;if(b!==null){var w=b.next;b.next=g,f.next=w}l.pending=f}eo=null}return i}function B2(i,s){do{var l=Nt;try{if(Sp(),dc.current=mc,fc){for(var f=Et.memoizedState;f!==null;){var g=f.queue;g!==null&&(g.pending=null),f=f.next}fc=!1}if(no=0,Ut=Rt=Et=null,Ya=!1,Wa=0,rm.current=null,l===null||l.return===null){Pt=1,Ja=s,Nt=null;break}e:{var b=i,w=l.return,P=l,F=s;if(s=qt,P.flags|=32768,F!==null&&typeof F=="object"&&typeof F.then=="function"){var J=F,ce=P,ge=ce.tag;if((ce.mode&1)===0&&(ge===0||ge===11||ge===15)){var ue=ce.alternate;ue?(ce.updateQueue=ue.updateQueue,ce.memoizedState=ue.memoizedState,ce.lanes=ue.lanes):(ce.updateQueue=null,ce.memoizedState=null)}var we=l2(w);if(we!==null){we.flags&=-257,c2(we,w,P,b,s),we.mode&1&&u2(b,J,s),s=we,F=J;var Ce=s.updateQueue;if(Ce===null){var Ne=new Set;Ne.add(F),s.updateQueue=Ne}else Ce.add(F);break e}else{if((s&1)===0){u2(b,J,s),fm();break e}F=Error(n(426))}}else if(pt&&P.mode&1){var vt=l2(w);if(vt!==null){(vt.flags&65536)===0&&(vt.flags|=256),c2(vt,w,P,b,s),_p(ms(F,P));break e}}b=F=ms(F,P),Pt!==4&&(Pt=2),Za===null?Za=[b]:Za.push(b),b=w;do{switch(b.tag){case 3:b.flags|=65536,s&=-s,b.lanes|=s;var q=s2(b,F,s);Px(b,q);break e;case 1:P=F;var j=b.type,G=b.stateNode;if((b.flags&128)===0&&(typeof j.getDerivedStateFromError=="function"||G!==null&&typeof G.componentDidCatch=="function"&&(gi===null||!gi.has(G)))){b.flags|=65536,s&=-s,b.lanes|=s;var be=a2(b,P,s);Px(b,be);break e}}b=b.return}while(b!==null)}z2(l)}catch(Ie){s=Ie,Nt===l&&l!==null&&(Nt=l=l.return);continue}break}while(!0)}function U2(){var i=xc.current;return xc.current=mc,i===null?mc:i}function fm(){(Pt===0||Pt===3||Pt===2)&&(Pt=4),Ht===null||(ro&268435455)===0&&(wc&268435455)===0||bi(Ht,qt)}function kc(i,s){var l=Je;Je|=2;var f=U2();(Ht!==i||qt!==s)&&(Hr=null,oo(i,s));do try{b9();break}catch(g){B2(i,g)}while(!0);if(Sp(),Je=l,xc.current=f,Nt!==null)throw Error(n(261));return Ht=null,qt=0,Pt}function b9(){for(;Nt!==null;)H2(Nt)}function T9(){for(;Nt!==null&&!q8();)H2(Nt)}function H2(i){var s=V2(i.alternate,i,Nn);i.memoizedProps=i.pendingProps,s===null?z2(i):Nt=s,rm.current=null}function z2(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=f9(l,s,Nn),l!==null){Nt=l;return}}else{if(l=h9(l,s),l!==null){l.flags&=32767,Nt=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{Pt=6,Nt=null;return}}if(s=s.sibling,s!==null){Nt=s;return}Nt=s=i}while(s!==null);Pt===0&&(Pt=5)}function so(i,s,l){var f=nt,g=zn.transition;try{zn.transition=null,nt=1,x9(i,s,l,f)}finally{zn.transition=g,nt=f}return null}function x9(i,s,l,f){do bs();while(Ei!==null);if((Je&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 b=l.lanes|l.childLanes;if(tM(i,b),i===Ht&&(Nt=Ht=null,qt=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||vc||(vc=!0,q2(Rl,function(){return bs(),null})),b=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||b){b=zn.transition,zn.transition=null;var w=nt;nt=1;var P=Je;Je|=4,rm.current=null,m9(i,l),I2(l,i),zM(fp),Ul=!!dp,fp=dp=null,i.current=l,g9(l),Y8(),Je=P,nt=w,zn.transition=b}else i.current=l;if(vc&&(vc=!1,Ei=i,Sc=g),b=i.pendingLanes,b===0&&(gi=null),K8(l.stateNode),bn(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(_c)throw _c=!1,i=sm,sm=null,i;return(Sc&1)!==0&&i.tag!==0&&bs(),b=i.pendingLanes,(b&1)!==0?i===am?eu++:(eu=0,am=i):eu=0,fi(),null}function bs(){if(Ei!==null){var i=NT(Sc),s=zn.transition,l=nt;try{if(zn.transition=null,nt=16>i?16:i,Ei===null)var f=!1;else{if(i=Ei,Ei=null,Sc=0,(Je&6)!==0)throw Error(n(331));var g=Je;for(Je|=4,_e=i.current;_e!==null;){var b=_e,w=b.child;if((_e.flags&16)!==0){var P=b.deletions;if(P!==null){for(var F=0;F<P.length;F++){var J=P[F];for(_e=J;_e!==null;){var ce=_e;switch(ce.tag){case 0:case 11:case 15:Xa(8,ce,b)}var ge=ce.child;if(ge!==null)ge.return=ce,_e=ge;else for(;_e!==null;){ce=_e;var ue=ce.sibling,we=ce.return;if(A2(ce),ce===J){_e=null;break}if(ue!==null){ue.return=we,_e=ue;break}_e=we}}}var Ce=b.alternate;if(Ce!==null){var Ne=Ce.child;if(Ne!==null){Ce.child=null;do{var vt=Ne.sibling;Ne.sibling=null,Ne=vt}while(Ne!==null)}}_e=b}}if((b.subtreeFlags&2064)!==0&&w!==null)w.return=b,_e=w;else e:for(;_e!==null;){if(b=_e,(b.flags&2048)!==0)switch(b.tag){case 0:case 11:case 15:Xa(9,b,b.return)}var q=b.sibling;if(q!==null){q.return=b.return,_e=q;break e}_e=b.return}}var j=i.current;for(_e=j;_e!==null;){w=_e;var G=w.child;if((w.subtreeFlags&2064)!==0&&G!==null)G.return=w,_e=G;else e:for(w=j;_e!==null;){if(P=_e,(P.flags&2048)!==0)try{switch(P.tag){case 0:case 11:case 15:Tc(9,P)}}catch(Ie){bt(P,P.return,Ie)}if(P===w){_e=null;break e}var be=P.sibling;if(be!==null){be.return=P.return,_e=be;break e}_e=P.return}}if(Je=g,fi(),Tr&&typeof Tr.onPostCommitFiberRoot=="function")try{Tr.onPostCommitFiberRoot(Pl,i)}catch(Ie){}f=!0}return f}finally{nt=l,zn.transition=s}}return!1}function j2(i,s,l){s=ms(l,s),s=s2(i,s,1),i=pi(i,s,1),s=on(),i!==null&&(va(i,1,s),bn(i,s))}function bt(i,s,l){if(i.tag===3)j2(i,i,l);else for(;s!==null;){if(s.tag===3){j2(s,i,l);break}else if(s.tag===1){var f=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof f.componentDidCatch=="function"&&(gi===null||!gi.has(f))){i=ms(l,i),i=a2(s,i,1),s=pi(s,i,1),i=on(),s!==null&&(va(s,1,i),bn(s,i));break}}s=s.return}}function w9(i,s,l){var f=i.pingCache;f!==null&&f.delete(s),s=on(),i.pingedLanes|=i.suspendedLanes&l,Ht===i&&(qt&l)===l&&(Pt===4||Pt===3&&(qt&130023424)===qt&&500>_t()-om?oo(i,0):im|=l),bn(i,s)}function $2(i,s){s===0&&((i.mode&1)===0?s=1:(s=Dl,Dl<<=1,(Dl&130023424)===0&&(Dl=4194304)));var l=on();i=Fr(i,s),i!==null&&(va(i,s,l),bn(i,l))}function _9(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),$2(i,l)}function v9(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),$2(i,l)}var V2;V2=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,d9(i,s,l);En=(i.flags&131072)!==0}else En=!1,pt&&(s.flags&1048576)!==0&&_x(s,rc,s.index);switch(s.lanes=0,s.tag){case 2:var f=s.type;yc(i,s),i=s.pendingProps;var g=as(s,Xt.current);hs(s,l),g=Mp(null,s,f,i,g,l);var b=Fp();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)?(b=!0,ec(s)):b=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,Np(s),g.updater=gc,s.stateNode=g,g._reactInternals=s,$p(s,f,i,l),s=Wp(null,s,f,!0,b,l)):(s.tag=0,pt&&b&&bp(s),rn(null,s,g,l),s=s.child),s;case 16:f=s.elementType;e:{switch(yc(i,s),i=s.pendingProps,g=f._init,f=g(f._payload),s.type=f,g=s.tag=A9(f),i=tr(f,i),g){case 0:s=Yp(null,s,f,i,l);break e;case 1:s=g2(null,s,f,i,l);break e;case 11:s=d2(null,s,f,i,l);break e;case 14:s=f2(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),Yp(i,s,f,g,l);case 1:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),g2(i,s,f,g,l);case 3:e:{if(E2(s),i===null)throw Error(n(387));f=s.pendingProps,b=s.memoizedState,g=b.element,Rx(i,s),lc(s,f,null,l);var w=s.memoizedState;if(f=w.element,b.isDehydrated)if(b={element:f,isDehydrated:!1,cache:w.cache,pendingSuspenseBoundaries:w.pendingSuspenseBoundaries,transitions:w.transitions},s.updateQueue.baseState=b,s.memoizedState=b,s.flags&256){g=ms(Error(n(423)),s),s=y2(i,s,f,l,g);break e}else if(f!==g){g=ms(Error(n(424)),s),s=y2(i,s,f,l,g);break e}else for(kn=li(s.stateNode.containerInfo.firstChild),Cn=s,pt=!0,er=null,l=Ox(s,null,f,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(cs(),f===g){s=Ur(i,s,l);break e}rn(i,s,f,l)}s=s.child}return s;case 5:return Dx(s),i===null&&wp(s),f=s.type,g=s.pendingProps,b=i!==null?i.memoizedProps:null,w=g.children,hp(f,g)?w=null:b!==null&&hp(f,b)&&(s.flags|=32),m2(i,s),rn(i,s,w,l),s.child;case 6:return i===null&&wp(s),null;case 13:return b2(i,s,l);case 4:return Op(s,s.stateNode.containerInfo),f=s.pendingProps,i===null?s.child=ds(s,null,f,l):rn(i,s,f,l),s.child;case 11:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),d2(i,s,f,g,l);case 7:return rn(i,s,s.pendingProps,l),s.child;case 8:return rn(i,s,s.pendingProps.children,l),s.child;case 12:return rn(i,s,s.pendingProps.children,l),s.child;case 10:e:{if(f=s.type._context,g=s.pendingProps,b=s.memoizedProps,w=g.value,at(sc,f._currentValue),f._currentValue=w,b!==null)if(Zn(b.value,w)){if(b.children===g.children&&!mn.current){s=Ur(i,s,l);break e}}else for(b=s.child,b!==null&&(b.return=s);b!==null;){var P=b.dependencies;if(P!==null){w=b.child;for(var F=P.firstContext;F!==null;){if(F.context===f){if(b.tag===1){F=Br(-1,l&-l),F.tag=2;var J=b.updateQueue;if(J!==null){J=J.shared;var ce=J.pending;ce===null?F.next=F:(F.next=ce.next,ce.next=F),J.pending=F}}b.lanes|=l,F=b.alternate,F!==null&&(F.lanes|=l),Cp(b.return,l,s),P.lanes|=l;break}F=F.next}}else if(b.tag===10)w=b.type===s.type?null:b.child;else if(b.tag===18){if(w=b.return,w===null)throw Error(n(341));w.lanes|=l,P=w.alternate,P!==null&&(P.lanes|=l),Cp(w,l,s),w=b.sibling}else w=b.child;if(w!==null)w.return=b;else for(w=b;w!==null;){if(w===s){w=null;break}if(b=w.sibling,b!==null){b.return=w.return,w=b;break}w=w.return}b=w}rn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,f=s.pendingProps.children,hs(s,l),g=Un(g),f=f(g),s.flags|=1,rn(i,s,f,l),s.child;case 14:return f=s.type,g=tr(f,s.pendingProps),g=tr(f.type,g),f2(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),yc(i,s),s.tag=1,gn(f)?(i=!0,ec(s)):i=!1,hs(s,l),i2(s,f,g),$p(s,f,g,l),Wp(null,s,f,!0,i,l);case 19:return x2(i,s,l);case 22:return p2(i,s,l)}throw Error(n(156,s.tag))};function q2(i,s){return vT(i,s)}function S9(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 S9(i,s,l,f)}function hm(i){return i=i.prototype,!(!i||!i.isReactComponent)}function A9(i){if(typeof i=="function")return hm(i)?1:0;if(i!=null){if(i=i.$$typeof,i===se)return 11;if(i===de)return 14}return 2}function Ti(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 Nc(i,s,l,f,g,b){var w=2;if(f=i,typeof i=="function")hm(i)&&(w=1);else if(typeof i=="string")w=5;else e:switch(i){case K:return ao(l.children,g,b,s);case fe:w=8,g|=8;break;case Te:return i=jn(12,l,s,g|2),i.elementType=Te,i.lanes=b,i;case ee:return i=jn(13,l,s,g),i.elementType=ee,i.lanes=b,i;case re:return i=jn(19,l,s,g),i.elementType=re,i.lanes=b,i;case he:return Oc(l,g,b,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case z:w=10;break e;case X:w=9;break e;case se:w=11;break e;case de:w=14;break e;case Oe:w=16,f=null;break e}throw Error(n(130,i==null?i:typeof i,""))}return s=jn(w,l,s,g),s.elementType=i,s.type=f,s.lanes=b,s}function ao(i,s,l,f){return i=jn(7,i,f,s),i.lanes=l,i}function Oc(i,s,l,f){return i=jn(22,i,f,s),i.elementType=he,i.lanes=l,i.stateNode={isHidden:!1},i}function pm(i,s,l){return i=jn(6,i,null,s),i.lanes=l,i}function mm(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 C9(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=jh(0),this.expirationTimes=jh(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=jh(0),this.identifierPrefix=f,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function gm(i,s,l,f,g,b,w,P,F){return i=new C9(i,s,l,P,F),s===1?(s=1,b===!0&&(s|=8)):s=0,b=jn(3,null,null,s),i.current=b,b.stateNode=i,b.memoizedState={element:f,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},Np(b),i}function k9(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 Y2(i){if(!i)return di;i=i._reactInternals;e:{if(Ki(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 Tx(i,l,s)}return s}function W2(i,s,l,f,g,b,w,P,F){return i=gm(l,f,!0,i,g,b,w,P,F),i.context=Y2(null),l=i.current,f=on(),g=yi(l),b=Br(f,g),b.callback=s!=null?s:null,pi(l,b,g),i.current.lanes=g,va(i,g,f),bn(i,f),i}function Ic(i,s,l,f){var g=s.current,b=on(),w=yi(g);return l=Y2(l),s.context===null?s.context=l:s.pendingContext=l,s=Br(b,w),s.payload={element:i},f=f===void 0?null:f,f!==null&&(s.callback=f),i=pi(g,s,w),i!==null&&(ir(i,g,w,b),uc(i,g,w)),w}function Rc(i){return i=i.current,i.child?(i.child.tag===5,i.child.stateNode):null}function G2(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function Em(i,s){G2(i,s),(i=i.alternate)&&G2(i,s)}function N9(){return null}var K2=typeof reportError=="function"?reportError:function(i){console.error(i)};function ym(i){this._internalRoot=i}Pc.prototype.render=ym.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Ic(i,s,null,null)},Pc.prototype.unmount=ym.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;io(function(){Ic(null,i,null,null)}),s[Pr]=null}};function Pc(i){this._internalRoot=i}Pc.prototype.unstable_scheduleHydration=function(i){if(i){var s=RT();i={blockedOn:null,target:i,priority:s};for(var l=0;l<si.length&&s!==0&&s<si[l].priority;l++);si.splice(l,0,i),l===0&&DT(i)}};function bm(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function Lc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function Q2(){}function O9(i,s,l,f,g){if(g){if(typeof f=="function"){var b=f;f=function(){var J=Rc(w);b.call(J)}}var w=W2(s,f,i,0,null,!1,!1,"",Q2);return i._reactRootContainer=w,i[Pr]=w.current,Ba(i.nodeType===8?i.parentNode:i),io(),w}for(;g=i.lastChild;)i.removeChild(g);if(typeof f=="function"){var P=f;f=function(){var J=Rc(F);P.call(J)}}var F=gm(i,0,!1,null,null,!1,!1,"",Q2);return i._reactRootContainer=F,i[Pr]=F.current,Ba(i.nodeType===8?i.parentNode:i),io(function(){Ic(s,F,l,f)}),F}function Dc(i,s,l,f,g){var b=l._reactRootContainer;if(b){var w=b;if(typeof g=="function"){var P=g;g=function(){var F=Rc(w);P.call(F)}}Ic(s,w,i,g)}else w=O9(l,s,i,g,f);return Rc(w)}OT=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=_a(s.pendingLanes);l!==0&&($h(s,l|1),bn(s,_t()),(Je&6)===0&&(ys=_t()+500,fi()))}break;case 13:io(function(){var f=Fr(i,1);if(f!==null){var g=on();ir(f,i,1,g)}}),Em(i,1)}},Vh=function(i){if(i.tag===13){var s=Fr(i,134217728);if(s!==null){var l=on();ir(s,i,134217728,l)}Em(i,134217728)}},IT=function(i){if(i.tag===13){var s=yi(i),l=Fr(i,s);if(l!==null){var f=on();ir(l,i,s,f)}Em(i,s)}},RT=function(){return nt},PT=function(i,s){var l=nt;try{return nt=i,s()}finally{nt=l}},Mh=function(i,s,l){switch(s){case"input":if(Go(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=Jl(f);if(!g)throw Error(n(90));Wi(f),Go(f,g)}}}break;case"textarea":kl(i,l);break;case"select":s=l.value,s!=null&&ti(i,!!l.multiple,s,!1)}},ET=cm,yT=io;var I9={usingClientEntryPoint:!1,Events:[za,os,Jl,mT,gT,cm]},tu={findFiberByHostInstance:Qi,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},R9={bundleType:tu.bundleType,version:tu.version,rendererPackageName:tu.rendererPackageName,rendererConfig:tu.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:H.ReactCurrentDispatcher,findHostInstanceByFiber:function(i){return i=wT(i),i===null?null:i.stateNode},findFiberByHostInstance:tu.findFiberByHostInstance||N9,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 Mc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Mc.isDisabled&&Mc.supportsFiber)try{Pl=Mc.inject(R9),Tr=Mc}catch(i){}}return ln.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=I9,ln.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!bm(s))throw Error(n(200));return k9(i,s,null,l)},ln.createRoot=function(i,s){if(!bm(i))throw Error(n(299));var l=!1,f="",g=K2;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(f=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=gm(i,1,!1,null,null,l,!1,f,g),i[Pr]=s.current,Ba(i.nodeType===8?i.parentNode:i),new ym(s)},ln.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=wT(s),i=i===null?null:i.stateNode,i},ln.flushSync=function(i){return io(i)},ln.hydrate=function(i,s,l){if(!Lc(s))throw Error(n(200));return Dc(null,i,s,!0,l)},ln.hydrateRoot=function(i,s,l){if(!bm(i))throw Error(n(405));var f=l!=null&&l.hydratedSources||null,g=!1,b="",w=K2;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(b=l.identifierPrefix),l.onRecoverableError!==void 0&&(w=l.onRecoverableError)),s=W2(s,null,i,1,l!=null?l:null,g,!1,b,w),i[Pr]=s.current,Ba(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 Pc(s)},ln.render=function(i,s,l){if(!Lc(s))throw Error(n(200));return Dc(null,i,s,!1,l)},ln.unmountComponentAtNode=function(i){if(!Lc(i))throw Error(n(40));return i._reactRootContainer?(io(function(){Dc(null,null,i,!1,function(){i._reactRootContainer=null,i[Pr]=null})}),!0):!1},ln.unstable_batchedUpdates=cm,ln.unstable_renderSubtreeIntoContainer=function(i,s,l,f){if(!Lc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Dc(i,s,l,!1,f)},ln.version="18.3.1-next-f1338f8080-20240426",ln}var M0;function F0(){if(M0)return _d.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(),_d.exports=CS(),_d.exports}var Is=F0();function B0(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=B0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function $(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=B0(e))&&(r&&(r+=" "),r+=t);return r}var U0={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},H0=wi.createContext&&wi.createContext(U0),kS=["attr","size","title"];function NS(e,t){if(e==null)return{};var n=OS(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 OS(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 Au(){return Au=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},Au.apply(this,arguments)}function z0(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 Cu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?z0(Object(n),!0).forEach(function(r){IS(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):z0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function IS(e,t,n){return t=RS(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function RS(e){var t=PS(e,"string");return typeof t=="symbol"?t:t+""}function PS(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 j0(e){return e&&e.map((t,n)=>wi.createElement(t.tag,Cu({key:n},t.attr),j0(t.child)))}function mt(e){return t=>wi.createElement(LS,Au({attr:Cu({},e.attr)},t),j0(e.child))}function LS(e){var t=n=>{var{attr:r,size:o,title:a}=e,u=NS(e,kS),c=o||n.size||"1em",d;return n.className&&(d=n.className),e.className&&(d=(d?d+" ":"")+e.className),wi.createElement("svg",Au({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,u,{className:d,style:Cu(Cu({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&wi.createElement("title",null,a),e.children)};return H0!==void 0?wi.createElement(H0.Consumer,null,n=>t(n)):t(U0)}function DS(e){return mt({attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M5.25 12a.75.75 0 0 1 .75-.75h12a.75.75 0 0 1 0 1.5H6a.75.75 0 0 1-.75-.75Z",clipRule:"evenodd"},child:[]}]})(e)}function MS(e){return mt({attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M12 5.25a.75.75 0 0 1 .75.75v5.25H18a.75.75 0 0 1 0 1.5h-5.25V18a.75.75 0 0 1-1.5 0v-5.25H6a.75.75 0 0 1 0-1.5h5.25V6a.75.75 0 0 1 .75-.75Z",clipRule:"evenodd"},child:[]}]})(e)}function FS(e){return mt({attr:{fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",d:"M9.813 15.904 9 18.75l-.813-2.846a4.5 4.5 0 0 0-3.09-3.09L2.25 12l2.846-.813a4.5 4.5 0 0 0 3.09-3.09L9 5.25l.813 2.846a4.5 4.5 0 0 0 3.09 3.09L15.75 12l-2.846.813a4.5 4.5 0 0 0-3.09 3.09ZM18.259 8.715 18 9.75l-.259-1.035a3.375 3.375 0 0 0-2.455-2.456L14.25 6l1.036-.259a3.375 3.375 0 0 0 2.455-2.456L18 2.25l.259 1.035a3.375 3.375 0 0 0 2.456 2.456L21.75 6l-1.035.259a3.375 3.375 0 0 0-2.456 2.456ZM16.894 20.567 16.5 21.75l-.394-1.183a2.25 2.25 0 0 0-1.423-1.423L13.5 18.75l1.183-.394a2.25 2.25 0 0 0 1.423-1.423l.394-1.183.394 1.183a2.25 2.25 0 0 0 1.423 1.423l1.183.394-1.183.394a2.25 2.25 0 0 0-1.423 1.423Z"},child:[]}]})(e)}const ar=({className:e,iconUrl:t,icon:n,type:r="button",ariaLabel:o,title:a,disabled:u=!1,onClick:c})=>!n&&!t?null:v.jsx("button",{className:$(e,`${U}-icon-button`),type:r,"aria-label":o,title:a,onClick:c,disabled:u,children:t?v.jsx("img",{className:$(`${U}-icon-image`),src:t,alt:o,loading:"lazy"}):n}),BS="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",US=({onClick:e})=>{const{globalClassName:t,headerConfig:n,mode:r}=At(),o=r==="messaging",a=o?"Open Commerce Client":"Open Copilot",u=o?v.jsx(FS,{className:$(t,`${U}-minimized-icon`)}):v.jsx("img",{src:(n==null?void 0:n.logoUrl)||BS,alt:"Copilot",className:$(t,`${U}-minimized-icon-img`)});return v.jsx(ar,{className:$(t,`${U}-minimized-button`),ariaLabel:a,title:a,icon:u,onClick:e})},HS=()=>{const{globalClassName:e,themeVariables:t}=At(),n=()=>{vu(!1),Ci(!0)};return Is.createPortal(v.jsx("div",{className:$(e,`${U}-minimized-container`),style:t,children:v.jsx(US,{onClick:n})}),document.body)};function zS(e){return mt({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 Vr(){const e=Z.useContext(A0);if(!e)throw new Error("useMessaging must be used within a MessagingProvider");return e}const jS=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 $0(e){return mt({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 $S(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M19 19H5V5h7V3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"},child:[]}]})(e)}function V0(e){return mt({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 VS(e){return mt({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 qS(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12 4-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8z"},child:[]}]})(e)}function YS(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"m12 8-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"},child:[]}]})(e)}function WS(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"},child:[]}]})(e)}function GS(e){return mt({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 KS(e){return mt({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)}function q0(e){return mt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"m21.41 11.58-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58s1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41s-.23-1.06-.59-1.42zM13 20.01 4 11V4h7v-.01l9 9-7 7.02z"},child:[]},{tag:"circle",attr:{cx:"6.5",cy:"6.5",r:"1.5"},child:[]}]})(e)}const Ni=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>v.jsx("button",{className:$(`${U}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),QS=({searchConfig:e,globalClassName:t})=>{const n=e.buttonIconUrl;return n?v.jsx("img",{className:$(`${U}-search-button-icon-image`,t),src:n,alt:"",loading:"lazy"}):v.jsx(V0,{size:"16px"})},XS=({className:e,searchConfig:t,globalClassName:n,componentType:r,isLoading:o})=>{if((t==null?void 0:t.buttonType)==="icon")return v.jsx(ar,{className:$(e,n,`cim-${r}-component`,`${U}-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:v.jsx(V0,{size:"16px"}),iconUrl:t==null?void 0:t.buttonIconUrl});const a=(t==null?void 0:t.buttonType)==="icon-text";return v.jsxs(Ni,{className:$(e,n,`cim-${r}-component`,`${U}-search-button`),type:"submit","aria-label":(t==null?void 0:t.buttonAriaLabel)||"",disabled:o,children:[a&&v.jsx(QS,{globalClassName:n,searchConfig:t}),(t==null?void 0:t.buttonLabel)||"Search"]})};function lF(){}function cF(){}function Y0(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 JS=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,ZS=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,eA={};function G0(e,t){return(eA.jsx?ZS:JS).test(e)}const tA=/[ \t\n\f\r]/g;function nA(e){return typeof e=="object"?e.type==="text"?K0(e.value):!1:K0(e)}function K0(e){return e.replace(tA,"")===""}let Rs=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Rs.prototype.normal={},Rs.prototype.property={},Rs.prototype.space=void 0;function Q0(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Rs(n,r,t)}function Ps(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 rA=0;const je=Oi(),Ct=Oi(),Ad=Oi(),Ee=Oi(),ot=Oi(),mo=Oi(),Tn=Oi();function Oi(){return nu(2,++rA)}const Cd=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:Ct,commaOrSpaceSeparated:Tn,commaSeparated:mo,number:Ee,overloadedBoolean:Ad,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),kd=Object.keys(Cd);let Nd=class extends cn{constructor(t,n,r,o){let a=-1;if(super(t,n),X0(this,"space",o),typeof r=="number")for(;++a<kd.length;){const u=kd[a];X0(this,kd[a],(r&Cd[u])===Cd[u])}}};Nd.prototype.defined=!0;function X0(e,t,n){n&&(e[t]=n)}function go(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const a=new Nd(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Ps(r)]=r,n[Ps(a.attribute)]=r}return new Rs(t,n,e.space)}const J0=go({properties:{ariaActiveDescendant:null,ariaAtomic:Ct,ariaAutoComplete:null,ariaBusy:Ct,ariaChecked:Ct,ariaColCount:Ee,ariaColIndex:Ee,ariaColSpan:Ee,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:Ct,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:Ct,ariaFlowTo:ot,ariaGrabbed:Ct,ariaHasPopup:null,ariaHidden:Ct,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:Ee,ariaLive:null,ariaModal:Ct,ariaMultiLine:Ct,ariaMultiSelectable:Ct,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:Ee,ariaPressed:Ct,ariaReadOnly:Ct,ariaRelevant:null,ariaRequired:Ct,ariaRoleDescription:ot,ariaRowCount:Ee,ariaRowIndex:Ee,ariaRowSpan:Ee,ariaSelected:Ct,ariaSetSize:Ee,ariaSort:null,ariaValueMax:Ee,ariaValueMin:Ee,ariaValueNow:Ee,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Z0(e,t){return t in e?e[t]:t}function eg(e,t){return Z0(e,t.toLowerCase())}const iA=go({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:mo,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:Ee,colSpan:null,content:null,contentEditable:Ct,controls:je,controlsList:ot,coords:Ee|mo,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:Ad,draggable:Ct,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:ot,height:Ee,hidden:Ad,high:Ee,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:Ee,manifest:null,max:null,maxLength:Ee,media:null,method:null,min:null,minLength:Ee,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:Ee,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:Ee,rowSpan:Ee,sandbox:ot,scope:null,scoped:je,seamless:je,selected:je,shadowRootClonable:je,shadowRootDelegatesFocus:je,shadowRootMode:null,shape:null,size:Ee,sizes:null,slot:null,span:Ee,spellCheck:Ct,src:null,srcDoc:null,srcLang:null,srcSet:null,start:Ee,step:null,style:null,tabIndex:Ee,target:null,title:null,translate:null,type:null,typeMustMatch:je,useMap:null,value:Ct,width:Ee,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ot,axis:null,background:null,bgColor:null,border:Ee,borderColor:null,bottomMargin:Ee,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:Ee,leftMargin:Ee,link:null,longDesc:null,lowSrc:null,marginHeight:Ee,marginWidth:Ee,noResize:je,noHref:je,noShade:je,noWrap:je,object:null,profile:null,prompt:null,rev:null,rightMargin:Ee,rules:null,scheme:null,scrolling:Ct,standby:null,summary:null,text:null,topMargin:Ee,valueType:null,version:null,vAlign:null,vLink:null,vSpace:Ee,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:je,disableRemotePlayback:je,prefix:null,property:null,results:Ee,security:null,unselectable:null},space:"html",transform:eg}),oA=go({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:Tn,accentHeight:Ee,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:Ee,amplitude:Ee,arabicForm:null,ascent:Ee,attributeName:null,attributeType:null,azimuth:Ee,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:Ee,by:null,calcMode:null,capHeight:Ee,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:Ee,diffuseConstant:Ee,direction:null,display:null,dur:null,divisor:Ee,dominantBaseline:null,download:je,dx:null,dy:null,edgeMode:null,editable:null,elevation:Ee,enableBackground:null,end:null,event:null,exponent:Ee,externalResourcesRequired:null,fill:null,fillOpacity:Ee,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:mo,g2:mo,glyphName:mo,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:Ee,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:Ee,horizOriginX:Ee,horizOriginY:Ee,id:null,ideographic:Ee,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:Ee,k:Ee,k1:Ee,k2:Ee,k3:Ee,k4:Ee,kernelMatrix:Tn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:Ee,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:Ee,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:Ee,overlineThickness:Ee,paintOrder:null,panose1:null,path:null,pathLength:Ee,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:Ee,pointsAtY:Ee,pointsAtZ:Ee,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Tn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Tn,rev:Tn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Tn,requiredFeatures:Tn,requiredFonts:Tn,requiredFormats:Tn,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:Ee,specularExponent:Ee,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:Ee,strikethroughThickness:Ee,string:null,stroke:null,strokeDashArray:Tn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:Ee,strokeOpacity:Ee,strokeWidth:null,style:null,surfaceScale:Ee,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Tn,tabIndex:Ee,tableValues:null,target:null,targetX:Ee,targetY:Ee,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Tn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:Ee,underlineThickness:Ee,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:Ee,values:null,vAlphabetic:Ee,vMathematical:Ee,vectorEffect:null,vHanging:Ee,vIdeographic:Ee,version:null,vertAdvY:Ee,vertOriginX:Ee,vertOriginY:Ee,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:Ee,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Z0}),tg=go({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()}}),ng=go({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:eg}),rg=go({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),sA={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"},aA=/[A-Z]/g,ig=/-[a-z]/g,uA=/^data[-\w.:]+$/i;function Od(e,t){const n=Ps(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"&&uA.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(ig,cA);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!ig.test(a)){let u=a.replace(aA,lA);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Nd}return new o(r,t)}function lA(e){return"-"+e.toLowerCase()}function cA(e){return e.charAt(1).toUpperCase()}const ku=Q0([J0,iA,tg,ng,rg],"html"),Eo=Q0([J0,oA,tg,ng,rg],"svg");function og(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function sg(e){return e.join(" ").trim()}var yo={},Id,ag;function dA(){if(ag)return Id;ag=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="/",p="*",E="",T="comment",y="declaration";Id=function(_,S){if(typeof _!="string")throw new TypeError("First argument must be a string");if(!_)return[];S=S||{};var A=1,O=1;function R(ee){var re=ee.match(t);re&&(A+=re.length);var de=ee.lastIndexOf(d);O=~de?ee.length-de:O+ee.length}function H(){var ee={line:A,column:O};return function(re){return re.position=new W(ee),fe(),re}}function W(ee){this.start=ee,this.end={line:A,column:O},this.source=S.source}W.prototype.content=_;function D(ee){var re=new Error(S.source+":"+A+":"+O+": "+ee);if(re.reason=ee,re.filename=S.source,re.line=A,re.column=O,re.source=_,!S.silent)throw re}function K(ee){var re=ee.exec(_);if(re){var de=re[0];return R(de),_=_.slice(de.length),re}}function fe(){K(n)}function Te(ee){var re;for(ee=ee||[];re=z();)re!==!1&&ee.push(re);return ee}function z(){var ee=H();if(!(h!=_.charAt(0)||p!=_.charAt(1))){for(var re=2;E!=_.charAt(re)&&(p!=_.charAt(re)||h!=_.charAt(re+1));)++re;if(re+=2,E===_.charAt(re-1))return D("End of comment missing");var de=_.slice(2,re-2);return O+=2,R(de),_=_.slice(re),O+=2,ee({type:T,comment:de})}}function X(){var ee=H(),re=K(r);if(re){if(z(),!K(o))return D("property missing ':'");var de=K(a),Oe=ee({type:y,property:x(re[0].replace(e,E)),value:de?x(de[0].replace(e,E)):E});return K(u),Oe}}function se(){var ee=[];Te(ee);for(var re;re=X();)re!==!1&&(ee.push(re),Te(ee));return ee}return fe(),se()};function x(_){return _?_.replace(c,E):E}return Id}var ug;function fA(){if(ug)return yo;ug=1;var e=yo&&yo.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(yo,"__esModule",{value:!0}),yo.default=n;var t=e(dA());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,p=d.value;c?o(h,p,d):p&&(a=a||{},a[h]=p)}}),a}return yo}var Ls={},lg;function hA(){if(lg)return Ls;lg=1,Object.defineProperty(Ls,"__esModule",{value:!0}),Ls.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,p){return p.toUpperCase()},c=function(h,p){return"".concat(p,"-")},d=function(h,p){return p===void 0&&(p={}),a(h)?h:(h=h.toLowerCase(),p.reactCompat?h=h.replace(o,c):h=h.replace(r,c),h.replace(t,u))};return Ls.camelCase=d,Ls}var Ds,cg;function pA(){if(cg)return Ds;cg=1;var e=Ds&&Ds.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(fA()),n=hA();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,Ds=r,Ds}var mA=pA();const gA=We(mA),Nu=dg("end"),ur=dg("start");function dg(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 fg(e){const t=ur(e),n=Nu(e);if(t&&n)return{start:t,end:n}}function Ms(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?hg(e.position):"start"in e||"end"in e?hg(e):"line"in e||"column"in e?Rd(e):""}function Rd(e){return pg(e&&e.line)+":"+pg(e&&e.column)}function hg(e){return Rd(e&&e.start)+"-"+Rd(e&&e.end)}function pg(e){return e&&typeof e=="number"?e:1}class Wt 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=B({},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=Ms(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}}Wt.prototype.file="",Wt.prototype.name="",Wt.prototype.reason="",Wt.prototype.message="",Wt.prototype.stack="",Wt.prototype.column=void 0,Wt.prototype.line=void 0,Wt.prototype.ancestors=void 0,Wt.prototype.cause=void 0,Wt.prototype.fatal=void 0,Wt.prototype.place=void 0,Wt.prototype.ruleId=void 0,Wt.prototype.source=void 0;const Pd={}.hasOwnProperty,EA=new Map,yA=/[A-Z]/g,bA=new Set(["table","tbody","thead","tfoot","tr"]),TA=new Set(["td","th"]),mg="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function xA(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=NA(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=kA(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"?Eo:ku,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=gg(o,e,void 0);return a&&typeof a!="string"?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function gg(e,t,n){if(t.type==="element")return wA(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return _A(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return SA(e,t,n);if(t.type==="mdxjsEsm")return vA(e,t);if(t.type==="root")return AA(e,t,n);if(t.type==="text")return CA(e,t)}function wA(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=Eo,e.schema=o),e.ancestors.push(t);const a=yg(e,t.tagName,!1),u=OA(e,t);let c=Dd(e,t);return bA.has(t.tagName)&&(c=c.filter(function(d){return typeof d=="string"?!nA(d):!0})),Eg(e,u,a,t),Ld(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function _A(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)}Fs(e,t.position)}function vA(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Fs(e,t.position)}function SA(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=Eo,e.schema=o),e.ancestors.push(t);const a=t.name===null?e.Fragment:yg(e,t.name,!0),u=IA(e,t),c=Dd(e,t);return Eg(e,u,a,t),Ld(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function AA(e,t,n){const r={};return Ld(r,Dd(e,t)),e.create(t,e.Fragment,r,n)}function CA(e,t){return t.value}function Eg(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Ld(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function kA(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 NA(e,t){return n;function n(r,o,a,u){const c=Array.isArray(a.children),d=ur(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 OA(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&Pd.call(t.properties,o)){const a=RA(e,o,t.properties[o]);if(a){const[u,c]=a;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&TA.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 IA(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 Fs(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 Fs(e,t.position);else a=r.value===null?!0:r.value;n[o]=a}return n}function Dd(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:EA;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=gg(e,a,u);c!==void 0&&n.push(c)}return n}function RA(e,t,n){const r=Od(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?W0(n):sg(n)),r.property==="style"){let o=typeof n=="object"?n:PA(e,String(n));return e.stylePropertyNameCase==="css"&&(o=LA(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?sA[r.property]||r.property:r.attribute,n]}}function PA(e,t){try{return gA(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new Wt("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=mg+"#cannot-parse-style-attribute",o}}function yg(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=G0(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=G0(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return Pd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);Fs(e)}function Fs(e,t){const n=new Wt("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=mg+"#cannot-handle-mdx-estrees-without-createevaluater",n}function LA(e){const t={};let n;for(n in e)Pd.call(e,n)&&(t[DA(n)]=e[n]);return t}function DA(e){let t=e.replace(yA,MA);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function MA(e){return"-"+e.toLowerCase()}const Md={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"]},FA={};function Fd(e,t){const n=FA,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return bg(e,r,o)}function bg(e,t,n){if(BA(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 Tg(e.children,t,n)}return Array.isArray(e)?Tg(e,t,n):""}function Tg(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=bg(e[o],t,n);return r.join("")}function BA(e){return!!(e&&typeof e=="object")}const xg=document.createElement("i");function Bd(e){const t="&"+e+";";xg.innerHTML=t;const n=xg.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 wg={}.hasOwnProperty;function _g(e){const t={};let n=-1;for(;++n<e.length;)UA(t,e[n]);return t}function UA(e,t){let n;for(n in t){const o=(wg.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let u;if(a)for(u in a){wg.call(o,u)||(o[u]=[]);const c=a[u];HA(o[u],Array.isArray(c)?c:c?[c]:[])}}}function HA(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 vg(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 Yn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const nn=qr(/[A-Za-z]/),Gt=qr(/[\dA-Za-z]/),zA=qr(/[#-'*+\--9=?A-Z^-~]/);function Ou(e){return e!==null&&(e<32||e===127)}const Ud=qr(/\d/),jA=qr(/[\dA-Fa-f]/),$A=qr(/[!-/:-@[-`{-~]/);function Le(e){return e!==null&&e<-2}function it(e){return e!==null&&(e<0||e===32)}function Ge(e){return e===-2||e===-1||e===32}const Iu=qr(new RegExp("\\p{P}|\\p{S}","u")),Ii=qr(/\s/);function qr(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function bo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let u="";if(a===37&&Gt(e.charCodeAt(n+1))&&Gt(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 Qe(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let a=0;return u;function u(d){return Ge(d)?(e.enter(n),c(d)):t(d)}function c(d){return Ge(d)&&a++<o?(e.consume(d),c):(e.exit(n),t(d))}}const VA={tokenize:qA};function qA(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"),Qe(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 YA={tokenize:WA},Sg={tokenize:GA};function WA(e){const t=this,n=[];let r=0,o,a,u;return c;function c(R){if(r<n.length){const H=n[r];return t.containerState=H[1],e.attempt(H[0].continuation,d,h)(R)}return h(R)}function d(R){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&O();const H=t.events.length;let W=H,D;for(;W--;)if(t.events[W][0]==="exit"&&t.events[W][1].type==="chunkFlow"){D=t.events[W][1].end;break}A(r);let K=H;for(;K<t.events.length;)t.events[K][1].end=B({},D),K++;return xn(t.events,W+1,0,t.events.slice(H)),t.events.length=K,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(Sg,p,E)(R)}function p(R){return o&&O(),A(r),T(R)}function E(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(Sg,y,x)(R)}function y(R){return r++,n.push([t.currentConstruct,t.containerState]),T(R)}function x(R){if(R===null){o&&O(),A(0),e.consume(R);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:a}),_(R)}function _(R){if(R===null){S(e.exit("chunkFlow"),!0),A(0),e.consume(R);return}return Le(R)?(e.consume(R),S(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(R),_)}function S(R,H){const W=t.sliceStream(R);if(H&&W.push(null),R.previous=a,a&&(a.next=R),a=R,o.defineSkip(R.start),o.write(W),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 K=t.events.length;let fe=K,Te,z;for(;fe--;)if(t.events[fe][0]==="exit"&&t.events[fe][1].type==="chunkFlow"){if(Te){z=t.events[fe][1].end;break}Te=!0}for(A(r),D=K;D<t.events.length;)t.events[D][1].end=B({},z),D++;xn(t.events,fe+1,0,t.events.slice(K)),t.events.length=D}}function A(R){let H=n.length;for(;H-- >R;){const W=n[H];t.containerState=W[1],W[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 GA(e,t,n){return Qe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function To(e){if(e===null||it(e)||Ii(e))return 1;if(Iu(e))return 2}function Ru(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 Hd={name:"attention",resolveAll:KA,tokenize:QA};function KA(e,t){let n=-1,r,o,a,u,c,d,h,p;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=B({},e[r][1].end),T=B({},e[n][1].start);Ag(E,-d),Ag(T,d),u={type:d>1?"strongSequence":"emphasisSequence",start:E,end:B({},e[r][1].end)},c={type:d>1?"strongSequence":"emphasisSequence",start:B({},e[n][1].start),end:T},a={type:d>1?"strongText":"emphasisText",start:B({},e[r][1].end),end:B({},e[n][1].start)},o={type:d>1?"strong":"emphasis",start:B({},u.start),end:B({},c.end)},e[r][1].end=B({},u.start),e[n][1].start=B({},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,Ru(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?(p=2,h=Rn(h,[["enter",e[n][1],t],["exit",e[n][1],t]])):p=0,xn(e,r-1,n-r+3,h),n=r+h.length-p-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function QA(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=To(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"),p=To(d),E=!p||p===2&&o||n.includes(d),T=!o||o===2&&p||n.includes(r);return h._open=!!(a===42?E:E&&(o||!T)),h._close=!!(a===42?T:T&&(p||!E)),t(d)}}function Ag(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const XA={name:"autolink",tokenize:JA};function JA(e,t,n){let r=0;return o;function o(y){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(y){return nn(y)?(e.consume(y),u):y===64?n(y):h(y)}function u(y){return y===43||y===45||y===46||Gt(y)?(r=1,c(y)):h(y)}function c(y){return y===58?(e.consume(y),r=0,d):(y===43||y===45||y===46||Gt(y))&&r++<32?(e.consume(y),c):(r=0,h(y))}function d(y){return y===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.exit("autolink"),t):y===null||y===32||y===60||Ou(y)?n(y):(e.consume(y),d)}function h(y){return y===64?(e.consume(y),p):zA(y)?(e.consume(y),h):n(y)}function p(y){return Gt(y)?E(y):n(y)}function E(y){return y===46?(e.consume(y),r=0,p):y===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(y),e.exit("autolinkMarker"),e.exit("autolink"),t):T(y)}function T(y){if((y===45||Gt(y))&&r++<63){const x=y===45?T:E;return e.consume(y),x}return n(y)}}const Bs={partial:!0,tokenize:ZA};function ZA(e,t,n){return r;function r(a){return Ge(a)?Qe(e,o,"linePrefix")(a):o(a)}function o(a){return a===null||Le(a)?t(a):n(a)}}const Cg={continuation:{tokenize:tC},exit:nC,name:"blockQuote",tokenize:eC};function eC(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 Ge(u)?(e.enter("blockQuotePrefixWhitespace"),e.consume(u),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(u))}}function tC(e,t,n){const r=this;return o;function o(u){return Ge(u)?Qe(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(u):a(u)}function a(u){return e.attempt(Cg,t,n)(u)}}function nC(e){e.exit("blockQuote")}const kg={name:"characterEscape",tokenize:rC};function rC(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 $A(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const Ng={name:"characterReference",tokenize:iC};function iC(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=Gt,p(E))}function h(E){return E===88||E===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(E),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,u=jA,p):(e.enter("characterReferenceValue"),a=7,u=Ud,p(E))}function p(E){if(E===59&&o){const T=e.exit("characterReferenceValue");return u===Gt&&!Bd(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),p):n(E)}}const Og={partial:!0,tokenize:sC},Ig={concrete:!0,name:"codeFenced",tokenize:oC};function oC(e,t,n){const r=this,o={partial:!0,tokenize:W};let a=0,u=0,c;return d;function d(D){return h(D)}function h(D){const K=r.events[r.events.length-1];return a=K&&K[1].type==="linePrefix"?K[2].sliceSerialize(K[1],!0).length:0,c=D,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),p(D)}function p(D){return D===c?(u++,e.consume(D),p):u<3?n(D):(e.exit("codeFencedFenceSequence"),Ge(D)?Qe(e,E,"whitespace")(D):E(D))}function E(D){return D===null||Le(D)?(e.exit("codeFencedFence"),r.interrupt?t(D):e.check(Og,_,H)(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)):Ge(D)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Qe(e,y,"whitespace")(D)):D===96&&D===c?n(D):(e.consume(D),T)}function y(D){return D===null||Le(D)?E(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"),E(D)):D===96&&D===c?n(D):(e.consume(D),x)}function _(D){return e.attempt(o,H,S)(D)}function S(D){return e.enter("lineEnding"),e.consume(D),e.exit("lineEnding"),A}function A(D){return a>0&&Ge(D)?Qe(e,O,"linePrefix",a+1)(D):O(D)}function O(D){return D===null||Le(D)?e.check(Og,_,H)(D):(e.enter("codeFlowValue"),R(D))}function R(D){return D===null||Le(D)?(e.exit("codeFlowValue"),O(D)):(e.consume(D),R)}function H(D){return e.exit("codeFenced"),t(D)}function W(D,K,fe){let Te=0;return z;function z(de){return D.enter("lineEnding"),D.consume(de),D.exit("lineEnding"),X}function X(de){return D.enter("codeFencedFence"),Ge(de)?Qe(D,se,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(de):se(de)}function se(de){return de===c?(D.enter("codeFencedFenceSequence"),ee(de)):fe(de)}function ee(de){return de===c?(Te++,D.consume(de),ee):Te>=u?(D.exit("codeFencedFenceSequence"),Ge(de)?Qe(D,re,"whitespace")(de):re(de)):fe(de)}function re(de){return de===null||Le(de)?(D.exit("codeFencedFence"),K(de)):fe(de)}}}function sC(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 zd={name:"codeIndented",tokenize:uC},aC={partial:!0,tokenize:lC};function uC(e,t,n){const r=this;return o;function o(h){return e.enter("codeIndented"),Qe(e,a,"linePrefix",5)(h)}function a(h){const p=r.events[r.events.length-1];return p&&p[1].type==="linePrefix"&&p[2].sliceSerialize(p[1],!0).length>=4?u(h):n(h)}function u(h){return h===null?d(h):Le(h)?e.attempt(aC,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 lC(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):Qe(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 cC={name:"codeText",previous:fC,resolve:dC,tokenize:hC};function dC(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 fC(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function hC(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,p(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 p(E){return E===96?(e.consume(E),o++,p):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(E)):(a.type="codeTextData",h(E))}}class pC{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&&Us(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),Us(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Us(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);Us(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Us(this.left,n.reverse())}}}function Us(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 Rg(e){const t={};let n=-1,r,o,a,u,c,d,h;const p=new pC(e);for(;++n<p.length;){for(;n in t;)n=t[n];if(r=p.get(n),n&&r[1].type==="chunkFlow"&&p.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,mC(p,n)),n=t[n],h=!0);else if(r[1]._container){for(a=n,o=void 0;a--;)if(u=p.get(a),u[1].type==="lineEnding"||u[1].type==="lineEndingBlank")u[0]==="enter"&&(o&&(p.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=B({},p.get(o)[1].start),c=p.slice(o,n),c.unshift(r),p.splice(o,n-o+1,c))}}return xn(e,0,Number.POSITIVE_INFINITY,p.slice(0)),!h}function mC(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 p,E,T=-1,y=n,x=0,_=0;const S=[_];for(;y;){for(;e.get(++o)[1]!==y;);a.push(o),y._tokenizer||(p=r.sliceStream(y),y.next||p.push(null),E&&u.defineSkip(y.start),y._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=!0),u.write(p),y._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=void 0)),E=y,y=y.next}for(y=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&&(_=T+1,S.push(_),y._tokenizer=void 0,y.previous=void 0,y=y.next);for(u.events=[],y?(y._tokenizer=void 0,y.previous=void 0):S.pop(),T=S.length;T--;){const A=c.slice(S[T],S[T+1]),O=a.pop();d.push([O,O+A.length-1]),e.splice(O,2,A)}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 gC={resolve:yC,tokenize:bC},EC={partial:!0,tokenize:TC};function yC(e){return Rg(e),e}function bC(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(EC,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 TC(e,t,n){const r=this;return o;function o(u){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),Qe(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 Pg(e,t,n,r,o,a,u,c,d){const h=d||Number.POSITIVE_INFINITY;let p=0;return E;function E(A){return A===60?(e.enter(r),e.enter(o),e.enter(a),e.consume(A),e.exit(a),T):A===null||A===32||A===41||Ou(A)?n(A):(e.enter(r),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),_(A))}function T(A){return A===62?(e.enter(a),e.consume(A),e.exit(a),e.exit(o),e.exit(r),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),y(A))}function y(A){return A===62?(e.exit("chunkString"),e.exit(c),T(A)):A===null||A===60||Le(A)?n(A):(e.consume(A),A===92?x:y)}function x(A){return A===60||A===62||A===92?(e.consume(A),y):y(A)}function _(A){return!p&&(A===null||A===41||it(A))?(e.exit("chunkString"),e.exit(c),e.exit(u),e.exit(r),t(A)):p<h&&A===40?(e.consume(A),p++,_):A===41?(e.consume(A),p--,_):A===null||A===32||A===40||Ou(A)?n(A):(e.consume(A),A===92?S:_)}function S(A){return A===40||A===41||A===92?(e.consume(A),_):_(A)}}function Lg(e,t,n,r,o,a){const u=this;let c=0,d;return h;function h(y){return e.enter(r),e.enter(o),e.consume(y),e.exit(o),e.enter(a),p}function p(y){return c>999||y===null||y===91||y===93&&!d||y===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(y):y===93?(e.exit(a),e.enter(o),e.consume(y),e.exit(o),e.exit(r),t):Le(y)?(e.enter("lineEnding"),e.consume(y),e.exit("lineEnding"),p):(e.enter("chunkString",{contentType:"string"}),E(y))}function E(y){return y===null||y===91||y===93||Le(y)||c++>999?(e.exit("chunkString"),p(y)):(e.consume(y),d||(d=!Ge(y)),y===92?T:E)}function T(y){return y===91||y===92||y===93?(e.consume(y),c++,E):E(y)}}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"),Qe(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),p(T))}function p(T){return T===u||T===null||Le(T)?(e.exit("chunkString"),h(T)):(e.consume(T),T===92?E:p)}function E(T){return T===u||T===92?(e.consume(T),p):p(T)}}function Hs(e,t){let n;return r;function r(o){return Le(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):Ge(o)?Qe(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}const xC={name:"definition",tokenize:_C},wC={partial:!0,tokenize:vC};function _C(e,t,n){const r=this;let o;return a;function a(y){return e.enter("definition"),u(y)}function u(y){return Lg.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(y)}function c(y){return o=Yn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),y===58?(e.enter("definitionMarker"),e.consume(y),e.exit("definitionMarker"),d):n(y)}function d(y){return it(y)?Hs(e,h)(y):h(y)}function h(y){return Pg(e,p,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(y)}function p(y){return e.attempt(wC,E,E)(y)}function E(y){return Ge(y)?Qe(e,T,"whitespace")(y):T(y)}function T(y){return y===null||Le(y)?(e.exit("definition"),r.parser.defined.push(o),t(y)):n(y)}}function vC(e,t,n){return r;function r(c){return it(c)?Hs(e,o)(c):n(c)}function o(c){return Dg(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function a(c){return Ge(c)?Qe(e,u,"whitespace")(c):u(c)}function u(c){return c===null||Le(c)?t(c):n(c)}}const SC={name:"hardBreakEscape",tokenize:AC};function AC(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 CC={name:"headingAtx",resolve:kC,tokenize:NC};function kC(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 NC(e,t,n){let r=0;return o;function o(p){return e.enter("atxHeading"),a(p)}function a(p){return e.enter("atxHeadingSequence"),u(p)}function u(p){return p===35&&r++<6?(e.consume(p),u):p===null||it(p)?(e.exit("atxHeadingSequence"),c(p)):n(p)}function c(p){return p===35?(e.enter("atxHeadingSequence"),d(p)):p===null||Le(p)?(e.exit("atxHeading"),t(p)):Ge(p)?Qe(e,c,"whitespace")(p):(e.enter("atxHeadingText"),h(p))}function d(p){return p===35?(e.consume(p),d):(e.exit("atxHeadingSequence"),c(p))}function h(p){return p===null||p===35||it(p)?(e.exit("atxHeadingText"),c(p)):(e.consume(p),h)}}const OC=["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"],Mg=["pre","script","style","textarea"],IC={concrete:!0,name:"htmlFlow",resolveTo:LC,tokenize:DC},RC={partial:!0,tokenize:FC},PC={partial:!0,tokenize:MC};function LC(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 DC(e,t,n){const r=this;let o,a,u,c,d;return h;function h(k){return p(k)}function p(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,_):k===63?(e.consume(k),o=3,r.interrupt?t:C):nn(k)?(e.consume(k),u=String.fromCharCode(k),S):n(k)}function T(k){return k===45?(e.consume(k),o=2,y):k===91?(e.consume(k),o=5,c=0,x):nn(k)?(e.consume(k),o=4,r.interrupt?t:C):n(k)}function y(k){return k===45?(e.consume(k),r.interrupt?t:C):n(k)}function x(k){const me="CDATA[";return k===me.charCodeAt(c++)?(e.consume(k),c===me.length?r.interrupt?t:se:x):n(k)}function _(k){return nn(k)?(e.consume(k),u=String.fromCharCode(k),S):n(k)}function S(k){if(k===null||k===47||k===62||it(k)){const me=k===47,Se=u.toLowerCase();return!me&&!a&&Mg.includes(Se)?(o=1,r.interrupt?t(k):se(k)):OC.includes(u.toLowerCase())?(o=6,me?(e.consume(k),A):r.interrupt?t(k):se(k)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?O(k):R(k))}return k===45||Gt(k)?(e.consume(k),u+=String.fromCharCode(k),S):n(k)}function A(k){return k===62?(e.consume(k),r.interrupt?t:se):n(k)}function O(k){return Ge(k)?(e.consume(k),O):z(k)}function R(k){return k===47?(e.consume(k),z):k===58||k===95||nn(k)?(e.consume(k),H):Ge(k)?(e.consume(k),R):z(k)}function H(k){return k===45||k===46||k===58||k===95||Gt(k)?(e.consume(k),H):W(k)}function W(k){return k===61?(e.consume(k),D):Ge(k)?(e.consume(k),W):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,K):Ge(k)?(e.consume(k),D):fe(k)}function K(k){return k===d?(e.consume(k),d=null,Te):k===null||Le(k)?n(k):(e.consume(k),K)}function fe(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||it(k)?W(k):(e.consume(k),fe)}function Te(k){return k===47||k===62||Ge(k)?R(k):n(k)}function z(k){return k===62?(e.consume(k),X):n(k)}function X(k){return k===null||Le(k)?se(k):Ge(k)?(e.consume(k),X):n(k)}function se(k){return k===45&&o===2?(e.consume(k),Oe):k===60&&o===1?(e.consume(k),he):k===62&&o===4?(e.consume(k),M):k===63&&o===3?(e.consume(k),C):k===93&&o===5?(e.consume(k),oe):Le(k)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(RC,ne,ee)(k)):k===null||Le(k)?(e.exit("htmlFlowData"),ee(k)):(e.consume(k),se)}function ee(k){return e.check(PC,re,ne)(k)}function re(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),de}function de(k){return k===null||Le(k)?ee(k):(e.enter("htmlFlowData"),se(k))}function Oe(k){return k===45?(e.consume(k),C):se(k)}function he(k){return k===47?(e.consume(k),u="",Q):se(k)}function Q(k){if(k===62){const me=u.toLowerCase();return Mg.includes(me)?(e.consume(k),M):se(k)}return nn(k)&&u.length<8?(e.consume(k),u+=String.fromCharCode(k),Q):se(k)}function oe(k){return k===93?(e.consume(k),C):se(k)}function C(k){return k===62?(e.consume(k),M):k===45&&o===2?(e.consume(k),C):se(k)}function M(k){return k===null||Le(k)?(e.exit("htmlFlowData"),ne(k)):(e.consume(k),M)}function ne(k){return e.exit("htmlFlow"),t(k)}}function MC(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 FC(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Bs,t,n)}}const BC={name:"htmlText",tokenize:UC};function UC(e,t,n){const r=this;let o,a,u;return c;function c(C){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(C),d}function d(C){return C===33?(e.consume(C),h):C===47?(e.consume(C),W):C===63?(e.consume(C),R):nn(C)?(e.consume(C),fe):n(C)}function h(C){return C===45?(e.consume(C),p):C===91?(e.consume(C),a=0,x):nn(C)?(e.consume(C),O):n(C)}function p(C){return C===45?(e.consume(C),y):n(C)}function E(C){return C===null?n(C):C===45?(e.consume(C),T):Le(C)?(u=E,he(C)):(e.consume(C),E)}function T(C){return C===45?(e.consume(C),y):E(C)}function y(C){return C===62?Oe(C):C===45?T(C):E(C)}function x(C){const M="CDATA[";return C===M.charCodeAt(a++)?(e.consume(C),a===M.length?_:x):n(C)}function _(C){return C===null?n(C):C===93?(e.consume(C),S):Le(C)?(u=_,he(C)):(e.consume(C),_)}function S(C){return C===93?(e.consume(C),A):_(C)}function A(C){return C===62?Oe(C):C===93?(e.consume(C),A):_(C)}function O(C){return C===null||C===62?Oe(C):Le(C)?(u=O,he(C)):(e.consume(C),O)}function R(C){return C===null?n(C):C===63?(e.consume(C),H):Le(C)?(u=R,he(C)):(e.consume(C),R)}function H(C){return C===62?Oe(C):R(C)}function W(C){return nn(C)?(e.consume(C),D):n(C)}function D(C){return C===45||Gt(C)?(e.consume(C),D):K(C)}function K(C){return Le(C)?(u=K,he(C)):Ge(C)?(e.consume(C),K):Oe(C)}function fe(C){return C===45||Gt(C)?(e.consume(C),fe):C===47||C===62||it(C)?Te(C):n(C)}function Te(C){return C===47?(e.consume(C),Oe):C===58||C===95||nn(C)?(e.consume(C),z):Le(C)?(u=Te,he(C)):Ge(C)?(e.consume(C),Te):Oe(C)}function z(C){return C===45||C===46||C===58||C===95||Gt(C)?(e.consume(C),z):X(C)}function X(C){return C===61?(e.consume(C),se):Le(C)?(u=X,he(C)):Ge(C)?(e.consume(C),X):Te(C)}function se(C){return C===null||C===60||C===61||C===62||C===96?n(C):C===34||C===39?(e.consume(C),o=C,ee):Le(C)?(u=se,he(C)):Ge(C)?(e.consume(C),se):(e.consume(C),re)}function ee(C){return C===o?(e.consume(C),o=void 0,de):C===null?n(C):Le(C)?(u=ee,he(C)):(e.consume(C),ee)}function re(C){return C===null||C===34||C===39||C===60||C===61||C===96?n(C):C===47||C===62||it(C)?Te(C):(e.consume(C),re)}function de(C){return C===47||C===62||it(C)?Te(C):n(C)}function Oe(C){return C===62?(e.consume(C),e.exit("htmlTextData"),e.exit("htmlText"),t):n(C)}function he(C){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),Q}function Q(C){return Ge(C)?Qe(e,oe,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(C):oe(C)}function oe(C){return e.enter("htmlTextData"),u(C)}}const jd={name:"labelEnd",resolveAll:$C,resolveTo:VC,tokenize:qC},HC={tokenize:YC},zC={tokenize:WC},jC={tokenize:GC};function $C(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 VC(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:B({},e[a][1].start),end:B({},e[e.length-1][1].end)},h={type:"label",start:B({},e[a][1].start),end:B({},e[u][1].end)},p={type:"labelText",start:B({},e[a+r+2][1].end),end:B({},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",p,t]]),c=Rn(c,Ru(t.parser.constructs.insideSpan.null,e.slice(a+r+4,u-3),t)),c=Rn(c,[["exit",p,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 qC(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(Yn(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(HC,p,u?p:E)(T):T===91?e.attempt(zC,p,u?h:E)(T):u?p(T):E(T)}function h(T){return e.attempt(jC,p,E)(T)}function p(T){return t(T)}function E(T){return a._balanced=!0,n(T)}}function YC(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)?Hs(e,a)(E):a(E)}function a(E){return E===41?p(E):Pg(e,u,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function u(E){return it(E)?Hs(e,d)(E):p(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):p(E)}function h(E){return it(E)?Hs(e,p)(E):p(E)}function p(E){return E===41?(e.enter("resourceMarker"),e.consume(E),e.exit("resourceMarker"),e.exit("resource"),t):n(E)}}function WC(e,t,n){const r=this;return o;function o(c){return Lg.call(r,e,a,u,"reference","referenceMarker","referenceString")(c)}function a(c){return r.parser.defined.includes(Yn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(c):n(c)}function u(c){return n(c)}}function GC(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 KC={name:"labelStartImage",resolveAll:jd.resolveAll,tokenize:QC};function QC(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 XC={name:"labelStartLink",resolveAll:jd.resolveAll,tokenize:JC};function JC(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 $d={name:"lineEnding",tokenize:ZC};function ZC(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Qe(e,t,"linePrefix")}}const Pu={name:"thematicBreak",tokenize:ek};function ek(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"),Ge(h)?Qe(e,c,"whitespace")(h):c(h))}}const dn={continuation:{tokenize:ik},exit:sk,name:"list",tokenize:rk},tk={partial:!0,tokenize:ak},nk={partial:!0,tokenize:ok};function rk(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(y){const x=r.containerState.type||(y===42||y===43||y===45?"listUnordered":"listOrdered");if(x==="listUnordered"?!r.containerState.marker||y===r.containerState.marker:Ud(y)){if(r.containerState.type||(r.containerState.type=x,e.enter(x,{_container:!0})),x==="listUnordered")return e.enter("listItemPrefix"),y===42||y===45?e.check(Pu,n,h)(y):h(y);if(!r.interrupt||y===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),d(y)}return n(y)}function d(y){return Ud(y)&&++u<10?(e.consume(y),d):(!r.interrupt||u<2)&&(r.containerState.marker?y===r.containerState.marker:y===41||y===46)?(e.exit("listItemValue"),h(y)):n(y)}function h(y){return e.enter("listItemMarker"),e.consume(y),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||y,e.check(Bs,r.interrupt?n:p,e.attempt(tk,T,E))}function p(y){return r.containerState.initialBlankLine=!0,a++,T(y)}function E(y){return Ge(y)?(e.enter("listItemPrefixWhitespace"),e.consume(y),e.exit("listItemPrefixWhitespace"),T):n(y)}function T(y){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(y)}}function ik(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Bs,o,a);function o(c){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Qe(e,t,"listItemIndent",r.containerState.size+1)(c)}function a(c){return r.containerState.furtherBlankLines||!Ge(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(nk,t,u)(c))}function u(c){return r.containerState._closeFlow=!0,r.interrupt=void 0,Qe(e,e.attempt(dn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function ok(e,t,n){const r=this;return Qe(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 sk(e){e.exit(this.containerState.type)}function ak(e,t,n){const r=this;return Qe(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!Ge(a)&&u&&u[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const Fg={name:"setextUnderline",resolveTo:uk,tokenize:lk};function uk(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:B({},e[r][1].start),end:B({},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=B({},e[a][1].end)):e[r][1]=u,e.push(["exit",u,t]),e}function lk(e,t,n){const r=this;let o;return a;function a(h){let p=r.events.length,E;for(;p--;)if(r.events[p][1].type!=="lineEnding"&&r.events[p][1].type!=="linePrefix"&&r.events[p][1].type!=="content"){E=r.events[p][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"),Ge(h)?Qe(e,d,"lineSuffix")(h):d(h))}function d(h){return h===null||Le(h)?(e.exit("setextHeadingLine"),t(h)):n(h)}}const ck={tokenize:dk};function dk(e){const t=this,n=e.attempt(Bs,r,e.attempt(this.parser.constructs.flowInitial,o,Qe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(gC,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 fk={resolveAll:Ug()},hk=Bg("string"),pk=Bg("text");function Bg(e){return{resolveAll:Ug(e==="text"?mk: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(p){return h(p)?a(p):c(p)}function c(p){if(p===null){n.consume(p);return}return n.enter("data"),n.consume(p),d}function d(p){return h(p)?(n.exit("data"),a(p)):(n.consume(p),d)}function h(p){if(p===null)return!0;const E=o[p];let T=-1;if(E)for(;++T<E.length;){const y=E[T];if(!y.previous||y.previous.call(r,r.previous))return!0}return!1}}}function Ug(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 mk(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:B({},r.end)};r.end=B({},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 gk=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:xC},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:Cg},flow:{35:CC,42:Pu,45:[Fg,Pu],60:IC,61:Fg,95:Pu,96:Ig,126:Ig},flowInitial:{[-2]:zd,[-1]:zd,32:zd},insideSpan:{null:[Hd,fk]},string:{38:Ng,92:kg},text:{[-5]:$d,[-4]:$d,[-3]:$d,33:KC,38:Ng,42:Hd,60:[XA,BC],91:XC,92:[SC,kg],93:jd,95:Hd,96:cC}},Symbol.toStringTag,{value:"Module"}));function Ek(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:K(W),check:K(D),consume:O,enter:R,exit:H,interrupt:K(D,{interrupt:!0})},h={code:null,containerState:{},defineSkip:_,events:[],now:x,parser:e,previous:null,sliceSerialize:T,sliceStream:y,write:E};let p=t.tokenize.call(h,d);return t.resolveAll&&a.push(t),h;function E(X){return u=Rn(u,X),S(),u[u.length-1]!==null?[]:(fe(t,0),h.events=Ru(a,h.events,h),h.events)}function T(X,se){return bk(y(X),se)}function y(X){return yk(u,X)}function x(){const{_bufferIndex:X,_index:se,line:ee,column:re,offset:de}=r;return{_bufferIndex:X,_index:se,line:ee,column:re,offset:de}}function _(X){o[X.line]=X.column,z()}function S(){let X;for(;r._index<u.length;){const se=u[r._index];if(typeof se=="string")for(X=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===X&&r._bufferIndex<se.length;)A(se.charCodeAt(r._bufferIndex));else A(se)}}function A(X){p=p(X)}function O(X){Le(X)?(r.line++,r.column=1,r.offset+=X===-3?2:1,z()):X!==-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=X}function R(X,se){const ee=se||{};return ee.type=X,ee.start=x(),h.events.push(["enter",ee,h]),c.push(ee),ee}function H(X){const se=c.pop();return se.end=x(),h.events.push(["exit",se,h]),se}function W(X,se){fe(X,se.from)}function D(X,se){se.restore()}function K(X,se){return ee;function ee(re,de,Oe){let he,Q,oe,C;return Array.isArray(re)?ne(re):"tokenize"in re?ne([re]):M(re);function M(Ae){return Be;function Be(ve){const qe=ve!==null&&Ae[ve],ut=ve!==null&&Ae.null,pn=[...Array.isArray(qe)?qe:qe?[qe]:[],...Array.isArray(ut)?ut:ut?[ut]:[]];return ne(pn)(ve)}}function ne(Ae){return he=Ae,Q=0,Ae.length===0?Oe:k(Ae[Q])}function k(Ae){return Be;function Be(ve){return C=Te(),oe=Ae,Ae.partial||(h.currentConstruct=Ae),Ae.name&&h.parser.constructs.disable.null.includes(Ae.name)?Se():Ae.tokenize.call(se?Object.assign(Object.create(h),se):h,d,me,Se)(ve)}}function me(Ae){return X(oe,C),de}function Se(Ae){return C.restore(),++Q<he.length?k(he[Q]):Oe}}}function fe(X,se){X.resolveAll&&!a.includes(X)&&a.push(X),X.resolve&&xn(h.events,se,h.events.length-se,X.resolve(h.events.slice(se),h)),X.resolveTo&&(h.events=X.resolveTo(h.events,h))}function Te(){const X=x(),se=h.previous,ee=h.currentConstruct,re=h.events.length,de=Array.from(c);return{from:re,restore:Oe};function Oe(){r=X,h.previous=se,h.currentConstruct=ee,h.events.length=re,c=de,z()}}function z(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function yk(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 bk(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 Tk(e){const r={constructs:_g([gk,...(e||{}).extensions||[]]),content:o(VA),defined:[],document:o(YA),flow:o(ck),lazy:{},string:o(hk),text:o(pk)};return r;function o(a){return u;function u(c){return Ek(r,a,c)}}}function xk(e){for(;!Rg(e););return e}const Hg=/[\0\t\n\r]/g;function wk(){let e=1,t="",n=!0,r;return o;function o(a,u,c){const d=[];let h,p,E,T,y;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(Hg.lastIndex=E,h=Hg.exec(a),T=h&&h.index!==void 0?h.index:a.length,y=a.charCodeAt(T),!h){t=a.slice(E);break}if(y===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),y){case 0:{d.push(65533),e++;break}case 9:{for(p=Math.ceil(e/4)*4,d.push(-2);e++<p;)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 _k=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function vk(e){return e.replace(_k,Sk)}function Sk(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return vg(n.slice(a?2:1),a?16:10)}return Bd(n)||e}const zg={}.hasOwnProperty;function Ak(e,t,n){return typeof t!="string"&&(n=t,t=void 0),Ck(n)(xk(Tk(n).document().write(wk()(e,t,!0))))}function Ck(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Ko),autolinkProtocol:xe,autolinkEmail:xe,atxHeading:a(Ea),blockQuote:a(ut),characterEscape:xe,characterReference:xe,codeFenced:a(pn),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(pn,u),codeText:a(Wi,u),codeTextData:xe,data:xe,codeFlowValue:xe,definition:a(Zr),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(Xn),hardBreakEscape:a(ya),hardBreakTrailing:a(ya),htmlFlow:a(Go,u),htmlFlowData:xe,htmlText:a(Go,u),htmlTextData:xe,image:a(Al),label:u,link:a(Ko),listItem:a(ti),listItemValue:T,listOrdered:a(ei,E),listUnordered:a(ei),paragraph:a(ba),reference:k,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(Ea),strong:a(Cl),thematicBreak:a(Nl)},exit:{atxHeading:d(),atxHeadingSequence:W,autolink:d(),autolinkEmail:qe,autolinkProtocol:ve,blockQuote:d(),characterEscapeValue:D,characterReferenceMarkerHexadecimal:Se,characterReferenceMarkerNumeric:Se,characterReferenceValue:Ae,characterReference:Be,codeFenced:d(S),codeFencedFence:_,codeFencedFenceInfo:y,codeFencedFenceMeta:x,codeFlowValue:D,codeIndented:d(A),codeText:d(be),codeTextData:D,data:D,definition:d(),definitionDestinationString:z,definitionLabelString:O,definitionTitleString:R,emphasis:d(),hardBreakEscape:d(J),hardBreakTrailing:d(J),htmlFlow:d(re),htmlFlowData:D,htmlText:d(oe),htmlTextData:D,image:d(fe),label:se,labelText:Q,lineEnding:ne,link:d(Ie),listItem:d(),listOrdered:d(),listUnordered:d(),paragraph:d(),referenceString:pe,resourceDestinationString:C,resourceTitleString:F,resource:te,setextHeading:d(de),setextHeadingLineSequence:K,setextHeadingText:M,strong:d(),thematicBreak:d()}};jg(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(ie){let Te={type:"root",children:[]};const Ue={stack:[Te],tokenStack:[],config:t,enter:c,exit:h,buffer:u,resume:p,data:n},Ye=[];let Xe=-1;for(;++Xe<ie.length;)if(ie[Xe][1].type==="listOrdered"||ie[Xe][1].type==="listUnordered")if(ie[Xe][0]==="enter")Ye.push(Xe);else{const jt=Ye.pop();Xe=o(ie,jt,Xe)}for(Xe=-1;++Xe<ie.length;){const jt=t[ie[Xe][0]];zg.call(jt,ie[Xe][1].type)&&jt[ie[Xe][1].type].call(Object.assign({sliceSerialize:ie[Xe][2].sliceSerialize},Ue),ie[Xe][1])}if(Ue.tokenStack.length>0){const jt=Ue.tokenStack[Ue.tokenStack.length-1];(jt[1]||$g).call(Ue,void 0,jt[0])}for(Te.position={start:Yr(ie.length>0?ie[0][1].start:{line:1,column:1,offset:0}),end:Yr(ie.length>0?ie[ie.length-2][1].end:{line:1,column:1,offset:0})},Xe=-1;++Xe<t.transforms.length;)Te=t.transforms[Xe](Te)||Te;return Te}function o(ie,Te,Ue){let Ye=Te-1,Xe=-1,jt=!1,Rr,Mn,ni,Gi;for(;++Ye<=Ue;){const $t=ie[Ye];switch($t[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{$t[0]==="enter"?Xe++:Xe--,Gi=void 0;break}case"lineEndingBlank":{$t[0]==="enter"&&(Rr&&!Gi&&!Xe&&!ni&&(ni=Ye),Gi=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Gi=void 0}if(!Xe&&$t[0]==="enter"&&$t[1].type==="listItemPrefix"||Xe===-1&&$t[0]==="exit"&&($t[1].type==="listUnordered"||$t[1].type==="listOrdered")){if(Rr){let br=Ye;for(Mn=void 0;br--;){const Sn=ie[br];if(Sn[1].type==="lineEnding"||Sn[1].type==="lineEndingBlank"){if(Sn[0]==="exit")continue;Mn&&(ie[Mn][1].type="lineEndingBlank",jt=!0),Sn[1].type="lineEnding",Mn=br}else if(!(Sn[1].type==="linePrefix"||Sn[1].type==="blockQuotePrefix"||Sn[1].type==="blockQuotePrefixWhitespace"||Sn[1].type==="blockQuoteMarker"||Sn[1].type==="listItemIndent"))break}ni&&(!Mn||ni<Mn)&&(Rr._spread=!0),Rr.end=Object.assign({},Mn?ie[Mn][1].start:$t[1].end),ie.splice(Mn||Ye,0,["exit",Rr,$t[2]]),Ye++,Ue++}if($t[1].type==="listItemPrefix"){const br={type:"listItem",_spread:!1,start:Object.assign({},$t[1].start),end:void 0};Rr=br,ie.splice(Ye,0,["enter",br,$t[2]]),Ye++,Ue++,ni=void 0,Gi=!0}}}return ie[Te][1]._spread=jt,Ue}function a(ie,Te){return Ue;function Ue(Ye){c.call(this,ie(Ye),Ye),Te&&Te.call(this,Ye)}}function u(){this.stack.push({type:"fragment",children:[]})}function c(ie,Te,Ue){this.stack[this.stack.length-1].children.push(ie),this.stack.push(ie),this.tokenStack.push([Te,Ue||void 0]),ie.position={start:Yr(Te.start),end:void 0}}function d(ie){return Te;function Te(Ue){ie&&ie.call(this,Ue),h.call(this,Ue)}}function h(ie,Te){const Ue=this.stack.pop(),Ye=this.tokenStack.pop();if(Ye)Ye[0].type!==ie.type&&(Te?Te.call(this,ie,Ye[0]):(Ye[1]||$g).call(this,ie,Ye[0]));else throw new Error("Cannot close `"+ie.type+"` ("+Ms({start:ie.start,end:ie.end})+"): it’s not open");Ue.position.end=Yr(ie.end)}function p(){return Fd(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function T(ie){if(this.data.expectingFirstListItemValue){const Te=this.stack[this.stack.length-2];Te.start=Number.parseInt(this.sliceSerialize(ie),10),this.data.expectingFirstListItemValue=void 0}}function y(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.lang=ie}function x(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.meta=ie}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function S(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ie.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function A(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ie.replace(/(\r?\n|\r)$/g,"")}function O(ie){const Te=this.resume(),Ue=this.stack[this.stack.length-1];Ue.label=Te,Ue.identifier=Yn(this.sliceSerialize(ie)).toLowerCase()}function R(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.title=ie}function z(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.url=ie}function W(ie){const Te=this.stack[this.stack.length-1];if(!Te.depth){const Ue=this.sliceSerialize(ie).length;Te.depth=Ue}}function M(){this.data.setextHeadingSlurpLineEnding=!0}function K(ie){const Te=this.stack[this.stack.length-1];Te.depth=this.sliceSerialize(ie).codePointAt(0)===61?1:2}function de(){this.data.setextHeadingSlurpLineEnding=void 0}function xe(ie){const Ue=this.stack[this.stack.length-1].children;let Ye=Ue[Ue.length-1];(!Ye||Ye.type!=="text")&&(Ye=kl(),Ye.position={start:Yr(ie.start),end:void 0},Ue.push(Ye)),this.stack.push(Ye)}function D(ie){const Te=this.stack.pop();Te.value+=this.sliceSerialize(ie),Te.position.end=Yr(ie.end)}function ne(ie){const Te=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Ue=Te.children[Te.children.length-1];Ue.position.end=Yr(ie.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(Te.type)&&(xe.call(this,ie),D.call(this,ie))}function J(){this.data.atHardBreak=!0}function re(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ie}function oe(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ie}function be(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ie}function Ie(){const ie=this.stack[this.stack.length-1];if(this.data.inReference){const Te=this.data.referenceType||"shortcut";ie.type+="Reference",ie.referenceType=Te,delete ie.url,delete ie.title}else delete ie.identifier,delete ie.label;this.data.referenceType=void 0}function fe(){const ie=this.stack[this.stack.length-1];if(this.data.inReference){const Te=this.data.referenceType||"shortcut";ie.type+="Reference",ie.referenceType=Te,delete ie.url,delete ie.title}else delete ie.identifier,delete ie.label;this.data.referenceType=void 0}function Q(ie){const Te=this.sliceSerialize(ie),Ue=this.stack[this.stack.length-2];Ue.label=vk(Te),Ue.identifier=Yn(Te).toLowerCase()}function se(){const ie=this.stack[this.stack.length-1],Te=this.resume(),Ue=this.stack[this.stack.length-1];if(this.data.inReference=!0,Ue.type==="link"){const Ye=ie.children;Ue.children=Ye}else Ue.alt=Te}function C(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.url=ie}function F(){const ie=this.resume(),Te=this.stack[this.stack.length-1];Te.title=ie}function te(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function pe(ie){const Te=this.resume(),Ue=this.stack[this.stack.length-1];Ue.label=Te,Ue.identifier=Yn(this.sliceSerialize(ie)).toLowerCase(),this.data.referenceType="full"}function Se(ie){this.data.characterReferenceType=ie.type}function Ae(ie){const Te=this.sliceSerialize(ie),Ue=this.data.characterReferenceType;let Ye;Ue?(Ye=vg(Te,Ue==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ye=Bd(Te);const Xe=this.stack[this.stack.length-1];Xe.value+=Ye}function Be(ie){const Te=this.stack.pop();Te.position.end=Yr(ie.end)}function ve(ie){D.call(this,ie);const Te=this.stack[this.stack.length-1];Te.url=this.sliceSerialize(ie)}function qe(ie){D.call(this,ie);const Te=this.stack[this.stack.length-1];Te.url="mailto:"+this.sliceSerialize(ie)}function ut(){return{type:"blockquote",children:[]}}function pn(){return{type:"code",lang:null,meta:null,value:""}}function Wi(){return{type:"inlineCode",value:""}}function Zr(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Xn(){return{type:"emphasis",children:[]}}function Ea(){return{type:"heading",depth:0,children:[]}}function ya(){return{type:"break"}}function Go(){return{type:"html",value:""}}function Al(){return{type:"image",title:null,url:"",alt:null}}function Ko(){return{type:"link",title:null,url:"",children:[]}}function ei(ie){return{type:"list",ordered:ie.type==="listOrdered",start:null,spread:ie._spread,children:[]}}function ti(ie){return{type:"listItem",spread:ie._spread,checked:null,children:[]}}function ba(){return{type:"paragraph",children:[]}}function Cl(){return{type:"strong",children:[]}}function kl(){return{type:"text",value:""}}function Nl(){return{type:"thematicBreak"}}}function Yr(e){return{line:e.line,column:e.column,offset:e.offset}}function jg(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?jg(e,r):kk(e,r)}}function kk(e,t){let n;for(n in t)if(zg.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 $g(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Ms({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ms({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Ms({start:t.start,end:t.end})+") is still open")}function Nk(e){const t=this;t.parser=n;function n(r){return Ak(r,ae(H(H({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function Ok(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 Ik(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 Tk(e){const r={constructs:_g([gk,...(e||{}).extensions||[]]),content:o(VA),defined:[],document:o(YA),flow:o(ck),lazy:{},string:o(hk),text:o(pk)};return r;function o(a){return u;function u(c){return Ek(r,a,c)}}}function xk(e){for(;!Rg(e););return e}const Hg=/[\0\t\n\r]/g;function wk(){let e=1,t="",n=!0,r;return o;function o(a,u,c){const d=[];let h,p,E,T,y;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(Hg.lastIndex=E,h=Hg.exec(a),T=h&&h.index!==void 0?h.index:a.length,y=a.charCodeAt(T),!h){t=a.slice(E);break}if(y===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),y){case 0:{d.push(65533),e++;break}case 9:{for(p=Math.ceil(e/4)*4,d.push(-2);e++<p;)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 _k=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function vk(e){return e.replace(_k,Sk)}function Sk(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return vg(n.slice(a?2:1),a?16:10)}return Bd(n)||e}const zg={}.hasOwnProperty;function Ak(e,t,n){return typeof t!="string"&&(n=t,t=void 0),Ck(n)(xk(Tk(n).document().write(wk()(e,t,!0))))}function Ck(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Ko),autolinkProtocol:Te,autolinkEmail:Te,atxHeading:a(Ea),blockQuote:a(ut),characterEscape:Te,characterReference:Te,codeFenced:a(pn),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(pn,u),codeText:a(Wi,u),codeTextData:Te,data:Te,codeFlowValue:Te,definition:a(Zr),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(Xn),hardBreakEscape:a(ya),hardBreakTrailing:a(ya),htmlFlow:a(Go,u),htmlFlowData:Te,htmlText:a(Go,u),htmlTextData:Te,image:a(Al),label:u,link:a(Ko),listItem:a(ti),listItemValue:T,listOrdered:a(ei,E),listUnordered:a(ei),paragraph:a(ba),reference:k,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(Ea),strong:a(Cl),thematicBreak:a(Nl)},exit:{atxHeading:d(),atxHeadingSequence:W,autolink:d(),autolinkEmail:qe,autolinkProtocol:ve,blockQuote:d(),characterEscapeValue:z,characterReferenceMarkerHexadecimal:Se,characterReferenceMarkerNumeric:Se,characterReferenceValue:Ae,characterReference:Be,codeFenced:d(S),codeFencedFence:_,codeFencedFenceInfo:y,codeFencedFenceMeta:x,codeFlowValue:z,codeIndented:d(A),codeText:d(de),codeTextData:z,data:z,definition:d(),definitionDestinationString:H,definitionLabelString:O,definitionTitleString:R,emphasis:d(),hardBreakEscape:d(se),hardBreakTrailing:d(se),htmlFlow:d(ee),htmlFlowData:z,htmlText:d(re),htmlTextData:z,image:d(he),label:oe,labelText:Q,lineEnding:X,link:d(Oe),listItem:d(),listOrdered:d(),listUnordered:d(),paragraph:d(),referenceString:me,resourceDestinationString:C,resourceTitleString:M,resource:ne,setextHeading:d(fe),setextHeadingLineSequence:K,setextHeadingText:D,strong:d(),thematicBreak:d()}};jg(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(ie){let xe={type:"root",children:[]};const Ue={stack:[xe],tokenStack:[],config:t,enter:c,exit:h,buffer:u,resume:p,data:n},Ye=[];let Xe=-1;for(;++Xe<ie.length;)if(ie[Xe][1].type==="listOrdered"||ie[Xe][1].type==="listUnordered")if(ie[Xe][0]==="enter")Ye.push(Xe);else{const jt=Ye.pop();Xe=o(ie,jt,Xe)}for(Xe=-1;++Xe<ie.length;){const jt=t[ie[Xe][0]];zg.call(jt,ie[Xe][1].type)&&jt[ie[Xe][1].type].call(Object.assign({sliceSerialize:ie[Xe][2].sliceSerialize},Ue),ie[Xe][1])}if(Ue.tokenStack.length>0){const jt=Ue.tokenStack[Ue.tokenStack.length-1];(jt[1]||$g).call(Ue,void 0,jt[0])}for(xe.position={start:Yr(ie.length>0?ie[0][1].start:{line:1,column:1,offset:0}),end:Yr(ie.length>0?ie[ie.length-2][1].end:{line:1,column:1,offset:0})},Xe=-1;++Xe<t.transforms.length;)xe=t.transforms[Xe](xe)||xe;return xe}function o(ie,xe,Ue){let Ye=xe-1,Xe=-1,jt=!1,Rr,Mn,ni,Gi;for(;++Ye<=Ue;){const $t=ie[Ye];switch($t[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{$t[0]==="enter"?Xe++:Xe--,Gi=void 0;break}case"lineEndingBlank":{$t[0]==="enter"&&(Rr&&!Gi&&!Xe&&!ni&&(ni=Ye),Gi=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Gi=void 0}if(!Xe&&$t[0]==="enter"&&$t[1].type==="listItemPrefix"||Xe===-1&&$t[0]==="exit"&&($t[1].type==="listUnordered"||$t[1].type==="listOrdered")){if(Rr){let br=Ye;for(Mn=void 0;br--;){const Sn=ie[br];if(Sn[1].type==="lineEnding"||Sn[1].type==="lineEndingBlank"){if(Sn[0]==="exit")continue;Mn&&(ie[Mn][1].type="lineEndingBlank",jt=!0),Sn[1].type="lineEnding",Mn=br}else if(!(Sn[1].type==="linePrefix"||Sn[1].type==="blockQuotePrefix"||Sn[1].type==="blockQuotePrefixWhitespace"||Sn[1].type==="blockQuoteMarker"||Sn[1].type==="listItemIndent"))break}ni&&(!Mn||ni<Mn)&&(Rr._spread=!0),Rr.end=Object.assign({},Mn?ie[Mn][1].start:$t[1].end),ie.splice(Mn||Ye,0,["exit",Rr,$t[2]]),Ye++,Ue++}if($t[1].type==="listItemPrefix"){const br={type:"listItem",_spread:!1,start:Object.assign({},$t[1].start),end:void 0};Rr=br,ie.splice(Ye,0,["enter",br,$t[2]]),Ye++,Ue++,ni=void 0,Gi=!0}}}return ie[xe][1]._spread=jt,Ue}function a(ie,xe){return Ue;function Ue(Ye){c.call(this,ie(Ye),Ye),xe&&xe.call(this,Ye)}}function u(){this.stack.push({type:"fragment",children:[]})}function c(ie,xe,Ue){this.stack[this.stack.length-1].children.push(ie),this.stack.push(ie),this.tokenStack.push([xe,Ue||void 0]),ie.position={start:Yr(xe.start),end:void 0}}function d(ie){return xe;function xe(Ue){ie&&ie.call(this,Ue),h.call(this,Ue)}}function h(ie,xe){const Ue=this.stack.pop(),Ye=this.tokenStack.pop();if(Ye)Ye[0].type!==ie.type&&(xe?xe.call(this,ie,Ye[0]):(Ye[1]||$g).call(this,ie,Ye[0]));else throw new Error("Cannot close `"+ie.type+"` ("+Ms({start:ie.start,end:ie.end})+"): it’s not open");Ue.position.end=Yr(ie.end)}function p(){return Fd(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function T(ie){if(this.data.expectingFirstListItemValue){const xe=this.stack[this.stack.length-2];xe.start=Number.parseInt(this.sliceSerialize(ie),10),this.data.expectingFirstListItemValue=void 0}}function y(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.lang=ie}function x(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.meta=ie}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function S(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.value=ie.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function A(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.value=ie.replace(/(\r?\n|\r)$/g,"")}function O(ie){const xe=this.resume(),Ue=this.stack[this.stack.length-1];Ue.label=xe,Ue.identifier=Yn(this.sliceSerialize(ie)).toLowerCase()}function R(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.title=ie}function H(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.url=ie}function W(ie){const xe=this.stack[this.stack.length-1];if(!xe.depth){const Ue=this.sliceSerialize(ie).length;xe.depth=Ue}}function D(){this.data.setextHeadingSlurpLineEnding=!0}function K(ie){const xe=this.stack[this.stack.length-1];xe.depth=this.sliceSerialize(ie).codePointAt(0)===61?1:2}function fe(){this.data.setextHeadingSlurpLineEnding=void 0}function Te(ie){const Ue=this.stack[this.stack.length-1].children;let Ye=Ue[Ue.length-1];(!Ye||Ye.type!=="text")&&(Ye=kl(),Ye.position={start:Yr(ie.start),end:void 0},Ue.push(Ye)),this.stack.push(Ye)}function z(ie){const xe=this.stack.pop();xe.value+=this.sliceSerialize(ie),xe.position.end=Yr(ie.end)}function X(ie){const xe=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Ue=xe.children[xe.children.length-1];Ue.position.end=Yr(ie.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(xe.type)&&(Te.call(this,ie),z.call(this,ie))}function se(){this.data.atHardBreak=!0}function ee(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.value=ie}function re(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.value=ie}function de(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.value=ie}function Oe(){const ie=this.stack[this.stack.length-1];if(this.data.inReference){const xe=this.data.referenceType||"shortcut";ie.type+="Reference",ie.referenceType=xe,delete ie.url,delete ie.title}else delete ie.identifier,delete ie.label;this.data.referenceType=void 0}function he(){const ie=this.stack[this.stack.length-1];if(this.data.inReference){const xe=this.data.referenceType||"shortcut";ie.type+="Reference",ie.referenceType=xe,delete ie.url,delete ie.title}else delete ie.identifier,delete ie.label;this.data.referenceType=void 0}function Q(ie){const xe=this.sliceSerialize(ie),Ue=this.stack[this.stack.length-2];Ue.label=vk(xe),Ue.identifier=Yn(xe).toLowerCase()}function oe(){const ie=this.stack[this.stack.length-1],xe=this.resume(),Ue=this.stack[this.stack.length-1];if(this.data.inReference=!0,Ue.type==="link"){const Ye=ie.children;Ue.children=Ye}else Ue.alt=xe}function C(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.url=ie}function M(){const ie=this.resume(),xe=this.stack[this.stack.length-1];xe.title=ie}function ne(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function me(ie){const xe=this.resume(),Ue=this.stack[this.stack.length-1];Ue.label=xe,Ue.identifier=Yn(this.sliceSerialize(ie)).toLowerCase(),this.data.referenceType="full"}function Se(ie){this.data.characterReferenceType=ie.type}function Ae(ie){const xe=this.sliceSerialize(ie),Ue=this.data.characterReferenceType;let Ye;Ue?(Ye=vg(xe,Ue==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ye=Bd(xe);const Xe=this.stack[this.stack.length-1];Xe.value+=Ye}function Be(ie){const xe=this.stack.pop();xe.position.end=Yr(ie.end)}function ve(ie){z.call(this,ie);const xe=this.stack[this.stack.length-1];xe.url=this.sliceSerialize(ie)}function qe(ie){z.call(this,ie);const xe=this.stack[this.stack.length-1];xe.url="mailto:"+this.sliceSerialize(ie)}function ut(){return{type:"blockquote",children:[]}}function pn(){return{type:"code",lang:null,meta:null,value:""}}function Wi(){return{type:"inlineCode",value:""}}function Zr(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Xn(){return{type:"emphasis",children:[]}}function Ea(){return{type:"heading",depth:0,children:[]}}function ya(){return{type:"break"}}function Go(){return{type:"html",value:""}}function Al(){return{type:"image",title:null,url:"",alt:null}}function Ko(){return{type:"link",title:null,url:"",children:[]}}function ei(ie){return{type:"list",ordered:ie.type==="listOrdered",start:null,spread:ie._spread,children:[]}}function ti(ie){return{type:"listItem",spread:ie._spread,checked:null,children:[]}}function ba(){return{type:"paragraph",children:[]}}function Cl(){return{type:"strong",children:[]}}function kl(){return{type:"text",value:""}}function Nl(){return{type:"thematicBreak"}}}function Yr(e){return{line:e.line,column:e.column,offset:e.offset}}function jg(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?jg(e,r):kk(e,r)}}function kk(e,t){let n;for(n in t)if(zg.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 $g(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Ms({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ms({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Ms({start:t.start,end:t.end})+") is still open")}function Nk(e){const t=this;t.parser=n;function n(r){return Ak(r,ae(B(B({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function Ok(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 Ik(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 Rk(e,t){const n=t.value?t.value+`
28
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 Pk(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Lk(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Dk(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),o=bo(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 Mk(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 Fk(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function Vg(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 Bk(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Vg(e,t);const o={src:bo(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 Uk(e,t){const n={src:bo(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 Hk(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 zk(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Vg(e,t);const o={href:bo(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 jk(e,t){const n={href:bo(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 $k(e,t,n){const r=e.all(t),o=n?Vk(n):qg(t),a={},u=[];if(typeof t.checked=="boolean"){const p=r[0];let E;p&&p.type==="element"&&p.tagName==="p"?E=p:(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 p=r[c];(o||c!==0||p.type!=="element"||p.tagName!=="p")&&u.push({type:"text",value:`
29
29
  `}),p.type==="element"&&p.tagName==="p"&&!o?u.push(...p.children):u.push(p)}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 Vk(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=qg(n[r])}return t}function qg(e){const t=e.spread;return t==null?e.children.length>1:t}function qk(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 Yk(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Wk(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function Gk(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Kk(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=ur(t.children[1]),d=Nu(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 Qk(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={},y=u?u[d]:void 0;y&&(T.align=y);let x={type:"element",tagName:a,properties:T,children:[]};E&&(x.children=e.all(E),e.patch(E,x),x=e.applyData(E,x)),h.push(x)}const p={type:"element",tagName:"tr",properties:{},children:e.wrap(h,!0)};return e.patch(t,p),e.applyData(t,p)}function Xk(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const Yg=9,Wg=32;function Jk(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const a=[];for(;r;)a.push(Gg(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return a.push(Gg(t.slice(o),o>0,!1)),a.join("")}function Gg(e,t,n){let r=0,o=e.length;if(t){let a=e.codePointAt(r);for(;a===Yg||a===Wg;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(o-1);for(;a===Yg||a===Wg;)o--,a=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function Zk(e,t){const n={type:"text",value:Jk(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function e3(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const t3={blockquote:Ok,break:Ik,code:Rk,delete:Pk,emphasis:Lk,footnoteReference:Dk,heading:Mk,html:Fk,imageReference:Bk,image:Uk,inlineCode:Hk,linkReference:zk,link:jk,listItem:$k,list:qk,paragraph:Yk,root:Wk,strong:Gk,table:Kk,tableCell:Xk,tableRow:Qk,text:Zk,thematicBreak:e3,toml:Lu,yaml:Lu,definition:Lu,footnoteDefinition:Lu};function Lu(){}const Kg=-1,Du=0,zs=1,Mu=2,Vd=3,qd=4,Yd=5,Wd=6,Qg=7,Xg=8,Jg=typeof self=="object"?self:globalThis,n3=(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 Du:case Kg:return n(u,o);case zs:{const c=n([],o);for(const d of u)c.push(r(d));return c}case Mu:{const c=n({},o);for(const[d,h]of u)c[r(d)]=r(h);return c}case Vd:return n(new Date(u),o);case qd:{const{source:c,flags:d}=u;return n(new RegExp(c,d),o)}case Yd:{const c=n(new Map,o);for(const[d,h]of u)c.set(r(d),r(h));return c}case Wd:{const c=n(new Set,o);for(const d of u)c.add(r(d));return c}case Qg:{const{name:c,message:d}=u;return n(new Jg[c](d),o)}case Xg: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 Jg[a](u),o)};return r},Zg=e=>n3(new Map,e)(0),xo="",{toString:r3}={},{keys:i3}=Object,js=e=>{const t=typeof e;if(t!=="object"||!e)return[Du,t];const n=r3.call(e).slice(8,-1);switch(n){case"Array":return[zs,xo];case"Object":return[Mu,xo];case"Date":return[Vd,xo];case"RegExp":return[qd,xo];case"Map":return[Yd,xo];case"Set":return[Wd,xo];case"DataView":return[zs,n]}return n.includes("Array")?[zs,n]:n.includes("Error")?[Qg,n]:[Mu,n]},Fu=([e,t])=>e===Du&&(t==="function"||t==="symbol"),o3=(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]=js(u);switch(c){case Du:{let p=u;switch(d){case"bigint":c=Xg,p=u.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+d);p=null;break;case"undefined":return o([Kg],u)}return o([c,p],u)}case zs:{if(d){let T=u;return d==="DataView"?T=new Uint8Array(u.buffer):d==="ArrayBuffer"&&(T=new Uint8Array(u)),o([d,[...T]],u)}const p=[],E=o([c,p],u);for(const T of u)p.push(a(T));return E}case Mu:{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 p=[],E=o([c,p],u);for(const T of i3(u))(e||!Fu(js(u[T])))&&p.push([a(T),a(u[T])]);return E}case Vd:return o([c,u.toISOString()],u);case qd:{const{source:p,flags:E}=u;return o([c,{source:p,flags:E}],u)}case Yd:{const p=[],E=o([c,p],u);for(const[T,y]of u)(e||!(Fu(js(T))||Fu(js(y))))&&p.push([a(T),a(y)]);return E}case Wd:{const p=[],E=o([c,p],u);for(const T of u)(e||!Fu(js(T)))&&p.push(a(T));return E}}const{message:h}=u;return o([c,{name:d,message:h}],u)};return a},e1=(e,{json:t,lossy:n}={})=>{const r=[];return o3(!(t||n),!!t,new Map,r)(e),r},Ri=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Zg(e1(e,t)):structuredClone(e):(e,t)=>Zg(e1(e,t));function s3(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 a3(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function u3(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||s3,r=e.options.footnoteBackLabel||a3,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 p=e.all(h),E=String(h.identifier).toUpperCase(),T=bo(E.toLowerCase());let y=0;const x=[],_=e.footnoteCounts.get(E);for(;_!==void 0&&++y<=_;){x.length>0&&x.push({type:"text",value:" "});let O=typeof n=="string"?n:n(d,y);typeof O=="string"&&(O={type:"text",value:O}),x.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+T+(y>1?"-"+y:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(d,y),className:["data-footnote-backref"]},children:Array.isArray(O)?O:[O]})}const S=p[p.length-1];if(S&&S.type==="element"&&S.tagName==="p"){const O=S.children[S.children.length-1];O&&O.type==="text"?O.value+=" ":S.children.push({type:"text",value:" "}),S.children.push(...x)}else p.push(...x);const A={type:"element",tagName:"li",properties:{id:t+"fn-"+T},children:e.wrap(p,!0)};e.patch(h,A),c.push(A)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:ae(H({},Ri(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 Vk(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=qg(n[r])}return t}function qg(e){const t=e.spread;return t==null?e.children.length>1:t}function qk(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 Yk(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Wk(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function Gk(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Kk(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=ur(t.children[1]),d=Nu(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 Qk(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={},y=u?u[d]:void 0;y&&(T.align=y);let x={type:"element",tagName:a,properties:T,children:[]};E&&(x.children=e.all(E),e.patch(E,x),x=e.applyData(E,x)),h.push(x)}const p={type:"element",tagName:"tr",properties:{},children:e.wrap(h,!0)};return e.patch(t,p),e.applyData(t,p)}function Xk(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const Yg=9,Wg=32;function Jk(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const a=[];for(;r;)a.push(Gg(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return a.push(Gg(t.slice(o),o>0,!1)),a.join("")}function Gg(e,t,n){let r=0,o=e.length;if(t){let a=e.codePointAt(r);for(;a===Yg||a===Wg;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(o-1);for(;a===Yg||a===Wg;)o--,a=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function Zk(e,t){const n={type:"text",value:Jk(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function e3(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const t3={blockquote:Ok,break:Ik,code:Rk,delete:Pk,emphasis:Lk,footnoteReference:Dk,heading:Mk,html:Fk,imageReference:Bk,image:Uk,inlineCode:Hk,linkReference:zk,link:jk,listItem:$k,list:qk,paragraph:Yk,root:Wk,strong:Gk,table:Kk,tableCell:Xk,tableRow:Qk,text:Zk,thematicBreak:e3,toml:Lu,yaml:Lu,definition:Lu,footnoteDefinition:Lu};function Lu(){}const Kg=-1,Du=0,zs=1,Mu=2,Vd=3,qd=4,Yd=5,Wd=6,Qg=7,Xg=8,Jg=typeof self=="object"?self:globalThis,n3=(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 Du:case Kg:return n(u,o);case zs:{const c=n([],o);for(const d of u)c.push(r(d));return c}case Mu:{const c=n({},o);for(const[d,h]of u)c[r(d)]=r(h);return c}case Vd:return n(new Date(u),o);case qd:{const{source:c,flags:d}=u;return n(new RegExp(c,d),o)}case Yd:{const c=n(new Map,o);for(const[d,h]of u)c.set(r(d),r(h));return c}case Wd:{const c=n(new Set,o);for(const d of u)c.add(r(d));return c}case Qg:{const{name:c,message:d}=u;return n(new Jg[c](d),o)}case Xg: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 Jg[a](u),o)};return r},Zg=e=>n3(new Map,e)(0),xo="",{toString:r3}={},{keys:i3}=Object,js=e=>{const t=typeof e;if(t!=="object"||!e)return[Du,t];const n=r3.call(e).slice(8,-1);switch(n){case"Array":return[zs,xo];case"Object":return[Mu,xo];case"Date":return[Vd,xo];case"RegExp":return[qd,xo];case"Map":return[Yd,xo];case"Set":return[Wd,xo];case"DataView":return[zs,n]}return n.includes("Array")?[zs,n]:n.includes("Error")?[Qg,n]:[Mu,n]},Fu=([e,t])=>e===Du&&(t==="function"||t==="symbol"),o3=(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]=js(u);switch(c){case Du:{let p=u;switch(d){case"bigint":c=Xg,p=u.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+d);p=null;break;case"undefined":return o([Kg],u)}return o([c,p],u)}case zs:{if(d){let T=u;return d==="DataView"?T=new Uint8Array(u.buffer):d==="ArrayBuffer"&&(T=new Uint8Array(u)),o([d,[...T]],u)}const p=[],E=o([c,p],u);for(const T of u)p.push(a(T));return E}case Mu:{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 p=[],E=o([c,p],u);for(const T of i3(u))(e||!Fu(js(u[T])))&&p.push([a(T),a(u[T])]);return E}case Vd:return o([c,u.toISOString()],u);case qd:{const{source:p,flags:E}=u;return o([c,{source:p,flags:E}],u)}case Yd:{const p=[],E=o([c,p],u);for(const[T,y]of u)(e||!(Fu(js(T))||Fu(js(y))))&&p.push([a(T),a(y)]);return E}case Wd:{const p=[],E=o([c,p],u);for(const T of u)(e||!Fu(js(T)))&&p.push(a(T));return E}}const{message:h}=u;return o([c,{name:d,message:h}],u)};return a},e1=(e,{json:t,lossy:n}={})=>{const r=[];return o3(!(t||n),!!t,new Map,r)(e),r},Ri=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Zg(e1(e,t)):structuredClone(e):(e,t)=>Zg(e1(e,t));function s3(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 a3(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function u3(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||s3,r=e.options.footnoteBackLabel||a3,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 p=e.all(h),E=String(h.identifier).toUpperCase(),T=bo(E.toLowerCase());let y=0;const x=[],_=e.footnoteCounts.get(E);for(;_!==void 0&&++y<=_;){x.length>0&&x.push({type:"text",value:" "});let O=typeof n=="string"?n:n(d,y);typeof O=="string"&&(O={type:"text",value:O}),x.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+T+(y>1?"-"+y:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(d,y),className:["data-footnote-backref"]},children:Array.isArray(O)?O:[O]})}const S=p[p.length-1];if(S&&S.type==="element"&&S.tagName==="p"){const O=S.children[S.children.length-1];O&&O.type==="text"?O.value+=" ":S.children.push({type:"text",value:" "}),S.children.push(...x)}else p.push(...x);const A={type:"element",tagName:"li",properties:{id:t+"fn-"+T},children:e.wrap(p,!0)};e.patch(h,A),c.push(A)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:ae(B({},Ri(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 Bu=(function(e){if(e==null)return f3;if(typeof e=="function")return Uu(e);if(typeof e=="object")return Array.isArray(e)?l3(e):c3(e);if(typeof e=="string")return d3(e);throw new Error("Expected function, string, or object as test")});function l3(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Bu(e[n]);return Uu(r);function r(...o){let a=-1;for(;++a<t.length;)if(t[a].apply(this,o))return!0;return!1}}function c3(e){const t=e;return Uu(n);function n(r){const o=r;let a;for(a in e)if(o[a]!==t[a])return!1;return!0}}function d3(e){return Uu(t);function t(n){return n&&n.type===e}}function Uu(e){return t;function t(n,r,o){return!!(h3(n)&&e.call(this,n,typeof r=="number"?r:void 0,o||void 0))}}function f3(){return!0}function h3(e){return e!==null&&typeof e=="object"&&"type"in e}function TF(e){return e}const t1=[],p3=!0,Gd=!1,m3="skip";function n1(e,t,n,r){let o;typeof t=="function"&&typeof n!="function"?(r=n,n=t):o=t;const a=Bu(o),u=r?-1:1;c(e,void 0,[])();function c(d,h,p){const E=d&&typeof d=="object"?d:{};if(typeof E.type=="string"){const y=typeof E.tagName=="string"?E.tagName:typeof E.name=="string"?E.name:void 0;Object.defineProperty(T,"name",{value:"node ("+(d.type+(y?"<"+y+">":""))+")"})}return T;function T(){let y=t1,x,_,S;if((!t||a(d,h,p[p.length-1]||void 0))&&(y=g3(n(d,p)),y[0]===Gd))return y;if("children"in d&&d.children){const A=d;if(A.children&&y[0]!==m3)for(_=(r?A.children.length:-1)+u,S=p.concat(A);_>-1&&_<A.children.length;){const O=A.children[_];if(x=c(O,_,S)(),x[0]===Gd)return x;_=typeof x[1]=="number"?x[1]:_+u}}return y}}}function g3(e){return Array.isArray(e)?e:typeof e=="number"?[p3,e]:e==null?t1:[e]}function Hu(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),n1(e,a,c,o);function c(d,h){const p=h[h.length-1],E=p?p.children.indexOf(d):void 0;return u(d,E,p)}}const Kd={}.hasOwnProperty,E3={};function y3(e,t){const n=t||E3,r=new Map,o=new Map,a=new Map,u=H(H({},t3),n.handlers),c={all:h,applyData:T3,definitionById:r,footnoteById:o,footnoteCounts:a,footnoteOrder:[],handlers:u,one:d,options:n,patch:b3,wrap:w3};return Hu(e,function(p){if(p.type==="definition"||p.type==="footnoteDefinition"){const E=p.type==="definition"?r:o,T=String(p.identifier).toUpperCase();E.has(T)||E.set(T,p)}}),c;function d(p,E){const T=p.type,y=c.handlers[T];if(Kd.call(c.handlers,T)&&y)return y(c,p,E);if(c.options.passThrough&&c.options.passThrough.includes(T)){if("children"in p){const _=p,{children:S}=_,A=sn(_,["children"]),O=Ri(A);return O.children=c.all(p),O}return Ri(p)}return(c.options.unknownHandler||x3)(c,p,E)}function h(p){const E=[];if("children"in p){const T=p.children;let y=-1;for(;++y<T.length;){const x=c.one(T[y],p);if(x){if(y&&T[y-1].type==="break"&&(!Array.isArray(x)&&x.type==="text"&&(x.value=r1(x.value)),!Array.isArray(x)&&x.type==="element")){const _=x.children[0];_&&_.type==="text"&&(_.value=r1(_.value))}Array.isArray(x)?E.push(...x):E.push(x)}}}return E}}function b3(e,t){e.position&&(t.position=fg(e))}function T3(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,Ri(a)),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function x3(e,t){const n=t.data||{},r="value"in t&&!(Kd.call(n,"hProperties")||Kd.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 w3(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
32
+ `}]}}const Bu=(function(e){if(e==null)return f3;if(typeof e=="function")return Uu(e);if(typeof e=="object")return Array.isArray(e)?l3(e):c3(e);if(typeof e=="string")return d3(e);throw new Error("Expected function, string, or object as test")});function l3(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Bu(e[n]);return Uu(r);function r(...o){let a=-1;for(;++a<t.length;)if(t[a].apply(this,o))return!0;return!1}}function c3(e){const t=e;return Uu(n);function n(r){const o=r;let a;for(a in e)if(o[a]!==t[a])return!1;return!0}}function d3(e){return Uu(t);function t(n){return n&&n.type===e}}function Uu(e){return t;function t(n,r,o){return!!(h3(n)&&e.call(this,n,typeof r=="number"?r:void 0,o||void 0))}}function f3(){return!0}function h3(e){return e!==null&&typeof e=="object"&&"type"in e}function TF(e){return e}const t1=[],p3=!0,Gd=!1,m3="skip";function n1(e,t,n,r){let o;typeof t=="function"&&typeof n!="function"?(r=n,n=t):o=t;const a=Bu(o),u=r?-1:1;c(e,void 0,[])();function c(d,h,p){const E=d&&typeof d=="object"?d:{};if(typeof E.type=="string"){const y=typeof E.tagName=="string"?E.tagName:typeof E.name=="string"?E.name:void 0;Object.defineProperty(T,"name",{value:"node ("+(d.type+(y?"<"+y+">":""))+")"})}return T;function T(){let y=t1,x,_,S;if((!t||a(d,h,p[p.length-1]||void 0))&&(y=g3(n(d,p)),y[0]===Gd))return y;if("children"in d&&d.children){const A=d;if(A.children&&y[0]!==m3)for(_=(r?A.children.length:-1)+u,S=p.concat(A);_>-1&&_<A.children.length;){const O=A.children[_];if(x=c(O,_,S)(),x[0]===Gd)return x;_=typeof x[1]=="number"?x[1]:_+u}}return y}}}function g3(e){return Array.isArray(e)?e:typeof e=="number"?[p3,e]:e==null?t1:[e]}function Hu(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),n1(e,a,c,o);function c(d,h){const p=h[h.length-1],E=p?p.children.indexOf(d):void 0;return u(d,E,p)}}const Kd={}.hasOwnProperty,E3={};function y3(e,t){const n=t||E3,r=new Map,o=new Map,a=new Map,u=B(B({},t3),n.handlers),c={all:h,applyData:T3,definitionById:r,footnoteById:o,footnoteCounts:a,footnoteOrder:[],handlers:u,one:d,options:n,patch:b3,wrap:w3};return Hu(e,function(p){if(p.type==="definition"||p.type==="footnoteDefinition"){const E=p.type==="definition"?r:o,T=String(p.identifier).toUpperCase();E.has(T)||E.set(T,p)}}),c;function d(p,E){const T=p.type,y=c.handlers[T];if(Kd.call(c.handlers,T)&&y)return y(c,p,E);if(c.options.passThrough&&c.options.passThrough.includes(T)){if("children"in p){const _=p,{children:S}=_,A=sn(_,["children"]),O=Ri(A);return O.children=c.all(p),O}return Ri(p)}return(c.options.unknownHandler||x3)(c,p,E)}function h(p){const E=[];if("children"in p){const T=p.children;let y=-1;for(;++y<T.length;){const x=c.one(T[y],p);if(x){if(y&&T[y-1].type==="break"&&(!Array.isArray(x)&&x.type==="text"&&(x.value=r1(x.value)),!Array.isArray(x)&&x.type==="element")){const _=x.children[0];_&&_.type==="text"&&(_.value=r1(_.value))}Array.isArray(x)?E.push(...x):E.push(x)}}}return E}}function b3(e,t){e.position&&(t.position=fg(e))}function T3(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,Ri(a)),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function x3(e,t){const n=t.data||{},r="value"in t&&!(Kd.call(n,"hProperties")||Kd.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 w3(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
35
  `}),n}function r1(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function i1(e,t){const n=y3(e,t),r=n.one(e,void 0),o=u3(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 _3(e,t){return e&&"run"in e?function(n,r){return $e(this,null,function*(){const o=i1(n,H({file:r},t));yield e.run(o,r)})}:function(n,r){return i1(n,H({file:r},e||t))}}function o1(e){if(e)throw e}var Qd,s1;function v3(){if(s1)return Qd;s1=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 p=e.call(h,"constructor"),E=h.constructor&&h.constructor.prototype&&e.call(h.constructor.prototype,"isPrototypeOf");if(h.constructor&&!p&&!E)return!1;var T;for(T in h);return typeof T=="undefined"||e.call(h,T)},u=function(h,p){n&&p.name==="__proto__"?n(h,p.name,{enumerable:!0,configurable:!0,value:p.newValue,writable:!0}):h[p.name]=p.newValue},c=function(h,p){if(p==="__proto__")if(e.call(h,p)){if(r)return r(h,p).value}else return;return h[p]};return Qd=function d(){var h,p,E,T,y,x,_=arguments[0],S=1,A=arguments.length,O=!1;for(typeof _=="boolean"&&(O=_,_=arguments[1]||{},S=2),(_==null||typeof _!="object"&&typeof _!="function")&&(_={});S<A;++S)if(h=arguments[S],h!=null)for(p in h)E=c(_,p),T=c(h,p),_!==T&&(O&&T&&(a(T)||(y=o(T)))?(y?(y=!1,x=E&&o(E)?E:[]):x=E&&a(E)?E:{},u(_,{name:p,newValue:d(O,x,T)})):typeof T!="undefined"&&u(_,{name:p,newValue:T}));return _},Qd}var S3=v3();const Xd=We(S3);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 A3(){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 p=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,p?C3(p,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 C3(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 p=h;if(c&&n)throw p;return o(p)}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 lr={basename:k3,dirname:N3,extname:O3,join:I3,sep:"/"};function k3(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');$s(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 N3(e){if($s(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 O3(e){$s(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 I3(...e){let t=-1,n;for(;++t<e.length;)$s(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":R3(n)}function R3(e){$s(e);const t=e.codePointAt(0)===47;let n=P3(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function P3(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 $s(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const L3={cwd:D3};function D3(){return"/"}function Zd(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function M3(e){if(typeof e=="string")e=new URL(e);else if(!Zd(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 F3(e)}function F3(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 ef=["history","path","basename","stem","extname","dirname"];class a1{constructor(t){let n;t?Zd(t)?n={path:t}:typeof t=="string"||B3(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":L3.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<ef.length;){const a=ef[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)ef.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?lr.basename(this.path):void 0}set basename(t){nf(t,"basename"),tf(t,"basename"),this.path=lr.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?lr.dirname(this.path):void 0}set dirname(t){u1(this.basename,"dirname"),this.path=lr.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?lr.extname(this.path):void 0}set extname(t){if(tf(t,"extname"),u1(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=lr.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Zd(t)&&(t=M3(t)),nf(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?lr.basename(this.path,this.extname):void 0}set stem(t){nf(t,"stem"),tf(t,"stem"),this.path=lr.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 Wt(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 tf(e,t){if(e&&e.includes(lr.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+lr.sep+"`")}function nf(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function u1(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function B3(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const U3=(function(e){const r=this.constructor.prototype,o=r[e],a=function(){return o.apply(a,arguments)};return Object.setPrototypeOf(a,r),a}),H3={}.hasOwnProperty;class rf extends U3{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=A3()}copy(){const t=new rf;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Xd(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(af("data",this.frozen),this.namespace[t]=n,this):H3.call(this.namespace,t)&&this.namespace[t]||void 0:t?(af("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=zu(t),r=this.parser||this.Parser;return of("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),of("process",this.parser||this.Parser),sf("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(a,u){const c=zu(t),d=r.parse(c);r.run(d,c,function(p,E,T){if(p||!E||!T)return h(p);const y=E,x=r.stringify(y,T);$3(x)?T.value=x:T.result=x,h(p,T)});function h(p,E){p||!E?u(p):a?a(E):n(void 0,E)}}}processSync(t){let n=!1,r;return this.freeze(),of("processSync",this.parser||this.Parser),sf("processSync",this.compiler||this.Compiler),this.process(t,o),c1("processSync","process",n),r;function o(a,u){n=!0,o1(a),r=u}}run(t,n,r){l1(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=zu(n);o.run(t,d,h);function h(p,E,T){const y=E||t;p?c(p):u?u(y):r(void 0,y,T)}}}runSync(t,n){let r=!1,o;return this.run(t,n,a),c1("runSync","run",r),o;function a(u,c){o1(u),o=c,r=!0}}stringify(t,n){this.freeze();const r=zu(n),o=this.compiler||this.Compiler;return sf("stringify",o),l1(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(af("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[p,...E]=h;d(p,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=Xd(!0,o.settings,h.settings))}function c(h){let p=-1;if(h!=null)if(Array.isArray(h))for(;++p<h.length;){const E=h[p];a(E)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function d(h,p){let E=-1,T=-1;for(;++E<r.length;)if(r[E][0]===h){T=E;break}if(T===-1)r.push([h,...p]);else if(p.length>0){let[y,...x]=p;const _=r[T][1];Jd(_)&&Jd(y)&&(y=Xd(!0,_,y)),r[T]=[h,y,...x]}}}}const z3=new rf().freeze();function of(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function sf(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function af(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 l1(e){if(!Jd(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function c1(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function zu(e){return j3(e)?e:new a1(e)}function j3(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function $3(e){return typeof e=="string"||V3(e)}function V3(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const q3="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",d1=[],f1={allowDangerousHtml:!0},Y3=/^(https?|ircs?|mailto|xmpp)$/i,W3=[{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 h1(e){const t=G3(e),n=K3(e);return Q3(t.runSync(t.parse(n),n),e)}function G3(e){const t=e.rehypePlugins||d1,n=e.remarkPlugins||d1,r=e.remarkRehypeOptions?H(H({},e.remarkRehypeOptions),f1):f1;return z3().use(Nk).use(n).use(_3,r).use(t)}function K3(e){const t=e.children||"",n=new a1;return typeof t=="string"&&(n.value=t),n}function Q3(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,a=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,d=t.urlTransform||X3;for(const p of W3)Object.hasOwn(t,p.from)&&(""+p.from+(p.to?"use `"+p.to+"` instead":"remove it")+q3+p.id,void 0);return Hu(e,h),xA(e,{Fragment:v.Fragment,components:o,ignoreInvalidStyle:!0,jsx:v.jsx,jsxs:v.jsxs,passKeys:!0,passNode:!0});function h(p,E,T){if(p.type==="raw"&&T&&typeof E=="number")return u?T.children.splice(E,1):T.children[E]={type:"text",value:p.value},E;if(p.type==="element"){let y;for(y in Md)if(Object.hasOwn(Md,y)&&Object.hasOwn(p.properties,y)){const x=p.properties[y],_=Md[y];(_===null||_.includes(p.tagName))&&(p.properties[y]=d(String(x||""),y,p))}}if(p.type==="element"){let y=n?!n.includes(p.tagName):a?a.includes(p.tagName):!1;if(!y&&r&&typeof E=="number"&&(y=!r(p,E,T)),y&&T&&typeof E=="number")return c&&p.children?T.children.splice(E,1,...p.children):T.children.splice(E,1),E}}}function X3(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||Y3.test(e.slice(0,t))?e:""}const p1=/[#.]/g;function J3(e,t){const n=e||"",r={};let o=0,a,u;for(;o<n.length;){p1.lastIndex=o;const c=p1.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 m1(e,t,n){const r=n?nN(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=J3(a,t);const h=d.tagName.toLowerCase(),p=r?r.get(h):void 0;if(d.tagName=p||h,Z3(u))c.unshift(u);else for(const[E,T]of Object.entries(u))eN(e,d.properties,E,T)}for(const h of c)uf(d.children,h);return d.type==="element"&&d.tagName==="template"&&(d.content={type:"root",children:d.children},d.children=[]),d}return o}function Z3(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 eN(e,t,n,r){const o=Od(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=og(r):o.commaSeparated?a=Y0(r):o.commaOrSpaceSeparated?a=og(Y0(r).join(" ")):a=g1(o,o.property,r):Array.isArray(r)?a=[...r]:a=o.property==="style"?tN(r):String(r);if(Array.isArray(a)){const u=[];for(const c of a)u.push(g1(o,o.property,c));a=u}o.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[o.property]=a}}function uf(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)uf(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?uf(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function g1(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||Ps(n)===Ps(t)))return!0}return n}function tN(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function nN(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const rN=["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"],iN=m1(ku,"div"),oN=m1(Eo,"g",rN);function sN(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=E1(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=E1(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 E1(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 Pi={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/"},y1={}.hasOwnProperty,aN=Object.prototype;function uN(e,t){const n=t||{};return lf({file:n.file||void 0,location:!1,schema:n.space==="svg"?Eo:ku,verbose:n.verbose||!1},e)}function lf(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},ju(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:b1(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const a=String(e.file),u=sN(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"},ju(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},ju(e,r,n),n}default:return n=lN(e,t),n}}function b1(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=lf(e,t[n]);r.push(o)}return r}function lN(e,t){const n=e.schema;e.schema=t.namespaceURI===Pi.svg?Eo:ku;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],d=(c.prefix?c.prefix+":":"")+c.name;y1.call(aN,d)||(o[d]=c.value)}const u=(e.schema.space==="svg"?oN:iN)(t.tagName,o,b1(e,t.childNodes));if(ju(e,t,u),u.tagName==="template"){const c=t,d=c.sourceCodeLocation,h=d&&d.startTag&&wo(d.startTag),p=d&&d.endTag&&wo(d.endTag),E=lf(e,c.content);h&&p&&e.file&&(E.position={start:h.end,end:p.start}),u.content=E}return e.schema=n,u}function ju(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=cN(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function cN(e,t,n){const r=wo(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)y1.call(n.attrs,u)&&(a[Od(e.schema,u).property]=wo(n.attrs[u]));n.startTag;const c=wo(n.startTag),d=n.endTag?wo(n.endTag):void 0,h={opening:c};d&&(h.closing=d),h.properties=a,t.data={position:h}}}return r}function wo(e){const t=T1({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=T1({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function T1(e){return e.line&&e.column?e:void 0}class Vs{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}Vs.prototype.property={},Vs.prototype.normal={},Vs.prototype.space=null;function x1(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 Vs(n,r,t)}function cf(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 dN=0;const ze=Li(),kt=Li(),w1=Li(),Ee=Li(),st=Li(),_o=Li(),wn=Li();function Li(){return nu(2,++dN)}const df=Object.freeze(Object.defineProperty({__proto__:null,boolean:ze,booleanish:kt,commaOrSpaceSeparated:wn,commaSeparated:_o,number:Ee,overloadedBoolean:w1,spaceSeparated:st},Symbol.toStringTag,{value:"Module"})),ff=Object.keys(df);class hf extends Pn{constructor(t,n,r,o){let a=-1;if(super(t,n),_1(this,"space",o),typeof r=="number")for(;++a<ff.length;){const u=ff[a];_1(this,ff[a],(r&df[u])===df[u])}}}hf.prototype.defined=!0;function _1(e,t,n){n&&(e[t]=n)}const fN={}.hasOwnProperty;function vo(e){const t={},n={};let r;for(r in e.properties)if(fN.call(e.properties,r)){const o=e.properties[r],a=new hf(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[cf(r)]=r,n[cf(a.attribute)]=r}return new Vs(t,n,e.space)}const v1=vo({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}}),S1=vo({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function A1(e,t){return t in e?e[t]:t}function C1(e,t){return A1(e,t.toLowerCase())}const k1=vo({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:C1,properties:{xmlns:null,xmlnsXLink:null}}),N1=vo({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:kt,ariaAutoComplete:null,ariaBusy:kt,ariaChecked:kt,ariaColCount:Ee,ariaColIndex:Ee,ariaColSpan:Ee,ariaControls:st,ariaCurrent:null,ariaDescribedBy:st,ariaDetails:null,ariaDisabled:kt,ariaDropEffect:st,ariaErrorMessage:null,ariaExpanded:kt,ariaFlowTo:st,ariaGrabbed:kt,ariaHasPopup:null,ariaHidden:kt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:st,ariaLevel:Ee,ariaLive:null,ariaModal:kt,ariaMultiLine:kt,ariaMultiSelectable:kt,ariaOrientation:null,ariaOwns:st,ariaPlaceholder:null,ariaPosInSet:Ee,ariaPressed:kt,ariaReadOnly:kt,ariaRelevant:null,ariaRequired:kt,ariaRoleDescription:st,ariaRowCount:Ee,ariaRowIndex:Ee,ariaRowSpan:Ee,ariaSelected:kt,ariaSetSize:Ee,ariaSort:null,ariaValueMax:Ee,ariaValueMin:Ee,ariaValueNow:Ee,ariaValueText:null,role:null}}),hN=vo({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:C1,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:_o,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:Ee,colSpan:null,content:null,contentEditable:kt,controls:ze,controlsList:st,coords:Ee|_o,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ze,defer:ze,dir:null,dirName:null,disabled:ze,download:w1,draggable:kt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:ze,formTarget:null,headers:st,height:Ee,hidden:ze,high:Ee,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:Ee,manifest:null,max:null,maxLength:Ee,media:null,method:null,min:null,minLength:Ee,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:Ee,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:Ee,rowSpan:Ee,sandbox:st,scope:null,scoped:ze,seamless:ze,selected:ze,shadowRootClonable:ze,shadowRootDelegatesFocus:ze,shadowRootMode:null,shape:null,size:Ee,sizes:null,slot:null,span:Ee,spellCheck:kt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:Ee,step:null,style:null,tabIndex:Ee,target:null,title:null,translate:null,type:null,typeMustMatch:ze,useMap:null,value:kt,width:Ee,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:st,axis:null,background:null,bgColor:null,border:Ee,borderColor:null,bottomMargin:Ee,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:Ee,leftMargin:Ee,link:null,longDesc:null,lowSrc:null,marginHeight:Ee,marginWidth:Ee,noResize:ze,noHref:ze,noShade:ze,noWrap:ze,object:null,profile:null,prompt:null,rev:null,rightMargin:Ee,rules:null,scheme:null,scrolling:kt,standby:null,summary:null,text:null,topMargin:Ee,valueType:null,version:null,vAlign:null,vLink:null,vSpace:Ee,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:ze,disableRemotePlayback:ze,prefix:null,property:null,results:Ee,security:null,unselectable:null}}),pN=vo({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:A1,properties:{about:wn,accentHeight:Ee,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:Ee,amplitude:Ee,arabicForm:null,ascent:Ee,attributeName:null,attributeType:null,azimuth:Ee,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:Ee,by:null,calcMode:null,capHeight:Ee,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:Ee,diffuseConstant:Ee,direction:null,display:null,dur:null,divisor:Ee,dominantBaseline:null,download:ze,dx:null,dy:null,edgeMode:null,editable:null,elevation:Ee,enableBackground:null,end:null,event:null,exponent:Ee,externalResourcesRequired:null,fill:null,fillOpacity:Ee,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:_o,g2:_o,glyphName:_o,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:Ee,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:Ee,horizOriginX:Ee,horizOriginY:Ee,id:null,ideographic:Ee,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:Ee,k:Ee,k1:Ee,k2:Ee,k3:Ee,k4:Ee,kernelMatrix:wn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:Ee,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:Ee,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:Ee,overlineThickness:Ee,paintOrder:null,panose1:null,path:null,pathLength:Ee,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:st,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:Ee,pointsAtY:Ee,pointsAtZ:Ee,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:wn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:wn,rev:wn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:wn,requiredFeatures:wn,requiredFonts:wn,requiredFormats:wn,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:Ee,specularExponent:Ee,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:Ee,strikethroughThickness:Ee,string:null,stroke:null,strokeDashArray:wn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:Ee,strokeOpacity:Ee,strokeWidth:null,style:null,surfaceScale:Ee,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:wn,tabIndex:Ee,tableValues:null,target:null,targetX:Ee,targetY:Ee,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:wn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:Ee,underlineThickness:Ee,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:Ee,values:null,vAlphabetic:Ee,vMathematical:Ee,vectorEffect:null,vHanging:Ee,vIdeographic:Ee,version:null,vertAdvY:Ee,vertOriginX:Ee,vertOriginY:Ee,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:Ee,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),mN=/^data[-\w.:]+$/i,O1=/-[a-z]/g,gN=/[A-Z]/g;function EN(e,t){const n=cf(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"&&mN.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(O1,bN);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!O1.test(a)){let u=a.replace(gN,yN);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=hf}return new o(r,t)}function yN(e){return"-"+e.toLowerCase()}function bN(e){return e.charAt(1).toUpperCase()}const TN=x1([S1,v1,k1,N1,hN],"html"),I1=x1([S1,v1,k1,N1,pN],"svg"),R1={}.hasOwnProperty;function P1(e,t){const n=t||{};function r(o,...a){let u=r.invalid;const c=r.handlers;if(o&&R1.call(o,e)){const d=String(o[e]);u=R1.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 xN={},wN={}.hasOwnProperty,L1=P1("type",{handlers:{root:vN,element:NN,text:CN,comment:kN,doctype:AN}});function _N(e,t){const r=(t||xN).space;return L1(e,r==="svg"?I1:TN)}function vN(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=pf(e.children,n,t),So(e,n),n}function SN(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=pf(e.children,n,t),So(e,n),n}function AN(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return So(e,t),t}function CN(e){const t={nodeName:"#text",value:e.value,parentNode:null};return So(e,t),t}function kN(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return So(e,t),t}function NN(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=I1);const o=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&wN.call(e.properties,a)){const d=ON(r,a,e.properties[a]);d&&o.push(d)}}const u=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Pi[u],childNodes:[],parentNode:null};return c.childNodes=pf(e.children,c,r),So(e,c),e.tagName==="template"&&e.content&&(c.content=SN(e.content,r)),c}function ON(e,t,n){const r=EN(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):sg(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=Pi[r.space]}return o}function pf(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const a=L1(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 IN=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],RN=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 N;(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"})(N||(N={}));const fn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function D1(e){return e>=55296&&e<=57343}function PN(e){return e>=56320&&e<=57343}function LN(e,t){return(e-55296)*1024+9216+t}function M1(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function F1(e){return e>=64976&&e<=65007||RN.has(e)}var ee;(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"})(ee||(ee={}));const DN=65536;class MN{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=DN,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(PN(n))return this.pos++,this._addGap(),LN(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,N.EOF;return this._err(ee.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,N.EOF;const r=this.html.charCodeAt(n);return r===N.CARRIAGE_RETURN?N.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,N.EOF;let t=this.html.charCodeAt(this.pos);return t===N.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,N.LINE_FEED):t===N.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===N.LINE_FEED||t===N.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){M1(t)?this._err(ee.controlCharacterInInputStream):F1(t)&&this._err(ee.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var Ve;(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"})(Ve||(Ve={}));function B1(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 FN=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))),BN=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 UN(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=BN.get(e))!==null&&t!==void 0?t:e}var Dt;(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"})(Dt||(Dt={}));const HN=32;var Wr;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Wr||(Wr={}));function mf(e){return e>=Dt.ZERO&&e<=Dt.NINE}function zN(e){return e>=Dt.UPPER_A&&e<=Dt.UPPER_F||e>=Dt.LOWER_A&&e<=Dt.LOWER_F}function jN(e){return e>=Dt.UPPER_A&&e<=Dt.UPPER_Z||e>=Dt.LOWER_A&&e<=Dt.LOWER_Z||mf(e)}function $N(e){return e===Dt.EQUALS||jN(e)}var Mt;(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"})(Mt||(Mt={}));var Ar;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Ar||(Ar={}));class VN{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Mt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Ar.Strict}startEntity(t){this.decodeMode=t,this.state=Mt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Mt.EntityStart:return t.charCodeAt(n)===Dt.NUM?(this.state=Mt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Mt.NamedEntity,this.stateNamedEntity(t,n));case Mt.NumericStart:return this.stateNumericStart(t,n);case Mt.NumericDecimal:return this.stateNumericDecimal(t,n);case Mt.NumericHex:return this.stateNumericHex(t,n);case Mt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|HN)===Dt.LOWER_X?(this.state=Mt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Mt.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(mf(o)||zN(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(mf(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===Dt.SEMI)this.consumed+=1;else if(this.decodeMode===Ar.Strict)return 0;return this.emitCodePoint(UN(this.result),this.consumed),this.errors&&(t!==Dt.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&Wr.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const u=t.charCodeAt(n);if(this.treeIndex=qN(r,o,this.treeIndex+Math.max(1,a),u),this.treeIndex<0)return this.result===0||this.decodeMode===Ar.Attribute&&(a===0||$N(u))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],a=(o&Wr.VALUE_LENGTH)>>14,a!==0){if(u===Dt.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]&Wr.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]&~Wr.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Mt.NamedEntity:return this.result!==0&&(this.decodeMode!==Ar.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Mt.NumericDecimal:return this.emitNumericEntity(0,2);case Mt.NumericHex:return this.emitNumericEntity(0,3);case Mt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Mt.EntityStart:return 0}}}function qN(e,t,n,r){const o=(t&Wr.BRANCH_LENGTH)>>7,a=t&Wr.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 le;(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/"})(le||(le={}));var Di;(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"})(Di||(Di={}));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 m;(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"})(m||(m={}));const YN=new Map([[Y.A,m.A],[Y.ADDRESS,m.ADDRESS],[Y.ANNOTATION_XML,m.ANNOTATION_XML],[Y.APPLET,m.APPLET],[Y.AREA,m.AREA],[Y.ARTICLE,m.ARTICLE],[Y.ASIDE,m.ASIDE],[Y.B,m.B],[Y.BASE,m.BASE],[Y.BASEFONT,m.BASEFONT],[Y.BGSOUND,m.BGSOUND],[Y.BIG,m.BIG],[Y.BLOCKQUOTE,m.BLOCKQUOTE],[Y.BODY,m.BODY],[Y.BR,m.BR],[Y.BUTTON,m.BUTTON],[Y.CAPTION,m.CAPTION],[Y.CENTER,m.CENTER],[Y.CODE,m.CODE],[Y.COL,m.COL],[Y.COLGROUP,m.COLGROUP],[Y.DD,m.DD],[Y.DESC,m.DESC],[Y.DETAILS,m.DETAILS],[Y.DIALOG,m.DIALOG],[Y.DIR,m.DIR],[Y.DIV,m.DIV],[Y.DL,m.DL],[Y.DT,m.DT],[Y.EM,m.EM],[Y.EMBED,m.EMBED],[Y.FIELDSET,m.FIELDSET],[Y.FIGCAPTION,m.FIGCAPTION],[Y.FIGURE,m.FIGURE],[Y.FONT,m.FONT],[Y.FOOTER,m.FOOTER],[Y.FOREIGN_OBJECT,m.FOREIGN_OBJECT],[Y.FORM,m.FORM],[Y.FRAME,m.FRAME],[Y.FRAMESET,m.FRAMESET],[Y.H1,m.H1],[Y.H2,m.H2],[Y.H3,m.H3],[Y.H4,m.H4],[Y.H5,m.H5],[Y.H6,m.H6],[Y.HEAD,m.HEAD],[Y.HEADER,m.HEADER],[Y.HGROUP,m.HGROUP],[Y.HR,m.HR],[Y.HTML,m.HTML],[Y.I,m.I],[Y.IMG,m.IMG],[Y.IMAGE,m.IMAGE],[Y.INPUT,m.INPUT],[Y.IFRAME,m.IFRAME],[Y.KEYGEN,m.KEYGEN],[Y.LABEL,m.LABEL],[Y.LI,m.LI],[Y.LINK,m.LINK],[Y.LISTING,m.LISTING],[Y.MAIN,m.MAIN],[Y.MALIGNMARK,m.MALIGNMARK],[Y.MARQUEE,m.MARQUEE],[Y.MATH,m.MATH],[Y.MENU,m.MENU],[Y.META,m.META],[Y.MGLYPH,m.MGLYPH],[Y.MI,m.MI],[Y.MO,m.MO],[Y.MN,m.MN],[Y.MS,m.MS],[Y.MTEXT,m.MTEXT],[Y.NAV,m.NAV],[Y.NOBR,m.NOBR],[Y.NOFRAMES,m.NOFRAMES],[Y.NOEMBED,m.NOEMBED],[Y.NOSCRIPT,m.NOSCRIPT],[Y.OBJECT,m.OBJECT],[Y.OL,m.OL],[Y.OPTGROUP,m.OPTGROUP],[Y.OPTION,m.OPTION],[Y.P,m.P],[Y.PARAM,m.PARAM],[Y.PLAINTEXT,m.PLAINTEXT],[Y.PRE,m.PRE],[Y.RB,m.RB],[Y.RP,m.RP],[Y.RT,m.RT],[Y.RTC,m.RTC],[Y.RUBY,m.RUBY],[Y.S,m.S],[Y.SCRIPT,m.SCRIPT],[Y.SEARCH,m.SEARCH],[Y.SECTION,m.SECTION],[Y.SELECT,m.SELECT],[Y.SOURCE,m.SOURCE],[Y.SMALL,m.SMALL],[Y.SPAN,m.SPAN],[Y.STRIKE,m.STRIKE],[Y.STRONG,m.STRONG],[Y.STYLE,m.STYLE],[Y.SUB,m.SUB],[Y.SUMMARY,m.SUMMARY],[Y.SUP,m.SUP],[Y.TABLE,m.TABLE],[Y.TBODY,m.TBODY],[Y.TEMPLATE,m.TEMPLATE],[Y.TEXTAREA,m.TEXTAREA],[Y.TFOOT,m.TFOOT],[Y.TD,m.TD],[Y.TH,m.TH],[Y.THEAD,m.THEAD],[Y.TITLE,m.TITLE],[Y.TR,m.TR],[Y.TRACK,m.TRACK],[Y.TT,m.TT],[Y.U,m.U],[Y.UL,m.UL],[Y.SVG,m.SVG],[Y.VAR,m.VAR],[Y.WBR,m.WBR],[Y.XMP,m.XMP]]);function Ao(e){var t;return(t=YN.get(e))!==null&&t!==void 0?t:m.UNKNOWN}const he=m,WN={[le.HTML]:new Set([he.ADDRESS,he.APPLET,he.AREA,he.ARTICLE,he.ASIDE,he.BASE,he.BASEFONT,he.BGSOUND,he.BLOCKQUOTE,he.BODY,he.BR,he.BUTTON,he.CAPTION,he.CENTER,he.COL,he.COLGROUP,he.DD,he.DETAILS,he.DIR,he.DIV,he.DL,he.DT,he.EMBED,he.FIELDSET,he.FIGCAPTION,he.FIGURE,he.FOOTER,he.FORM,he.FRAME,he.FRAMESET,he.H1,he.H2,he.H3,he.H4,he.H5,he.H6,he.HEAD,he.HEADER,he.HGROUP,he.HR,he.HTML,he.IFRAME,he.IMG,he.INPUT,he.LI,he.LINK,he.LISTING,he.MAIN,he.MARQUEE,he.MENU,he.META,he.NAV,he.NOEMBED,he.NOFRAMES,he.NOSCRIPT,he.OBJECT,he.OL,he.P,he.PARAM,he.PLAINTEXT,he.PRE,he.SCRIPT,he.SECTION,he.SELECT,he.SOURCE,he.STYLE,he.SUMMARY,he.TABLE,he.TBODY,he.TD,he.TEMPLATE,he.TEXTAREA,he.TFOOT,he.TH,he.THEAD,he.TITLE,he.TR,he.TRACK,he.UL,he.WBR,he.XMP]),[le.MATHML]:new Set([he.MI,he.MO,he.MN,he.MS,he.MTEXT,he.ANNOTATION_XML]),[le.SVG]:new Set([he.TITLE,he.FOREIGN_OBJECT,he.DESC]),[le.XLINK]:new Set,[le.XML]:new Set,[le.XMLNS]:new Set},gf=new Set([he.H1,he.H2,he.H3,he.H4,he.H5,he.H6]);Y.STYLE,Y.SCRIPT,Y.XMP,Y.IFRAME,Y.NOEMBED,Y.NOFRAMES,Y.PLAINTEXT;var I;(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"})(I||(I={}));const wt={DATA:I.DATA,RCDATA:I.RCDATA,RAWTEXT:I.RAWTEXT,SCRIPT_DATA:I.SCRIPT_DATA,PLAINTEXT:I.PLAINTEXT,CDATA_SECTION:I.CDATA_SECTION};function GN(e){return e>=N.DIGIT_0&&e<=N.DIGIT_9}function qs(e){return e>=N.LATIN_CAPITAL_A&&e<=N.LATIN_CAPITAL_Z}function KN(e){return e>=N.LATIN_SMALL_A&&e<=N.LATIN_SMALL_Z}function Gr(e){return KN(e)||qs(e)}function U1(e){return Gr(e)||GN(e)}function $u(e){return e+32}function H1(e){return e===N.SPACE||e===N.LINE_FEED||e===N.TABULATION||e===N.FORM_FEED}function z1(e){return H1(e)||e===N.SOLIDUS||e===N.GREATER_THAN_SIGN}function QN(e){return e===N.NULL?ee.nullCharacterReference:e>1114111?ee.characterReferenceOutsideUnicodeRange:D1(e)?ee.surrogateCharacterReference:F1(e)?ee.noncharacterCharacterReference:M1(e)||e===N.CARRIAGE_RETURN?ee.controlCharacterReference:null}class XN{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=I.DATA,this.returnState=I.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new MN(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new VN(FN,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(ee.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(ee.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=QN(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:Ve.START_TAG,tagName:"",tagID:m.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:Ve.END_TAG,tagName:"",tagID:m.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:Ve.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:Ve.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(B1(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(ee.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=Ao(t.tagName),t.type===Ve.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(ee.endTagWithAttributes),t.selfClosing&&this._err(ee.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 Ve.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case Ve.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case Ve.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:Ve.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=H1(t)?Ve.WHITESPACE_CHARACTER:t===N.NULL?Ve.NULL_CHARACTER:Ve.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(Ve.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=I.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Ar.Attribute:Ar.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===I.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===I.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===I.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case I.DATA:{this._stateData(t);break}case I.RCDATA:{this._stateRcdata(t);break}case I.RAWTEXT:{this._stateRawtext(t);break}case I.SCRIPT_DATA:{this._stateScriptData(t);break}case I.PLAINTEXT:{this._statePlaintext(t);break}case I.TAG_OPEN:{this._stateTagOpen(t);break}case I.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case I.TAG_NAME:{this._stateTagName(t);break}case I.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case I.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case I.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case I.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case I.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case I.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case I.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case I.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case I.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case I.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case I.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case I.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case I.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case I.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case I.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case I.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case I.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case I.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case I.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case I.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case I.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case I.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case I.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case I.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case I.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case I.BOGUS_COMMENT:{this._stateBogusComment(t);break}case I.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case I.COMMENT_START:{this._stateCommentStart(t);break}case I.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case I.COMMENT:{this._stateComment(t);break}case I.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case I.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case I.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case I.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case I.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case I.COMMENT_END:{this._stateCommentEnd(t);break}case I.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case I.DOCTYPE:{this._stateDoctype(t);break}case I.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case I.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case I.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case I.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case I.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case I.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case I.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case I.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case I.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case I.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case I.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case I.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case I.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case I.CDATA_SECTION:{this._stateCdataSection(t);break}case I.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case I.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case I.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case I.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case N.LESS_THAN_SIGN:{this.state=I.TAG_OPEN;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitCodePoint(t);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case N.AMPERSAND:{this._startCharacterReference();break}case N.LESS_THAN_SIGN:{this.state=I.RCDATA_LESS_THAN_SIGN;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case N.LESS_THAN_SIGN:{this.state=I.RAWTEXT_LESS_THAN_SIGN;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_LESS_THAN_SIGN;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Gr(t))this._createStartTagToken(),this.state=I.TAG_NAME,this._stateTagName(t);else switch(t){case N.EXCLAMATION_MARK:{this.state=I.MARKUP_DECLARATION_OPEN;break}case N.SOLIDUS:{this.state=I.END_TAG_OPEN;break}case N.QUESTION_MARK:{this._err(ee.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=I.BOGUS_COMMENT,this._stateBogusComment(t);break}case N.EOF:{this._err(ee.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(ee.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=I.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Gr(t))this._createEndTagToken(),this.state=I.TAG_NAME,this._stateTagName(t);else switch(t){case N.GREATER_THAN_SIGN:{this._err(ee.missingEndTagName),this.state=I.DATA;break}case N.EOF:{this._err(ee.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(ee.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=I.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_ATTRIBUTE_NAME;break}case N.SOLIDUS:{this.state=I.SELF_CLOSING_START_TAG;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentTagToken();break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.tagName+=ft;break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(qs(t)?$u(t):t)}}_stateRcdataLessThanSign(t){t===N.SOLIDUS?this.state=I.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=I.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Gr(t)?(this.state=I.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=I.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 N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=I.BEFORE_ATTRIBUTE_NAME,!1;case N.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=I.SELF_CLOSING_START_TAG,!1;case N.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=I.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===N.SOLIDUS?this.state=I.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=I.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Gr(t)?(this.state=I.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=I.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case N.SOLIDUS:{this.state=I.SCRIPT_DATA_END_TAG_OPEN;break}case N.EXCLAMATION_MARK:{this.state=I.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=I.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Gr(t)?(this.state=I.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===N.HYPHEN_MINUS?(this.state=I.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===N.HYPHEN_MINUS?(this.state=I.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._err(ee.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(ee.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case N.HYPHEN_MINUS:{this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case N.GREATER_THAN_SIGN:{this.state=I.SCRIPT_DATA,this._emitChars(">");break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(ee.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===N.SOLIDUS?this.state=I.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Gr(t)?(this._emitChars("<"),this.state=I.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Gr(t)?(this.state=I.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&z1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._err(ee.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(ee.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case N.HYPHEN_MINUS:{this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case N.GREATER_THAN_SIGN:{this.state=I.SCRIPT_DATA,this._emitChars(">");break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(ee.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===N.SOLIDUS?(this.state=I.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&z1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=I.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.SOLIDUS:case N.GREATER_THAN_SIGN:case N.EOF:{this.state=I.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case N.EQUALS_SIGN:{this._err(ee.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=I.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=I.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:case N.SOLIDUS:case N.GREATER_THAN_SIGN:case N.EOF:{this._leaveAttrName(),this.state=I.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case N.EQUALS_SIGN:{this._leaveAttrName(),this.state=I.BEFORE_ATTRIBUTE_VALUE;break}case N.QUOTATION_MARK:case N.APOSTROPHE:case N.LESS_THAN_SIGN:{this._err(ee.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.currentAttr.name+=ft;break}default:this.currentAttr.name+=String.fromCodePoint(qs(t)?$u(t):t)}}_stateAfterAttributeName(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.SOLIDUS:{this.state=I.SELF_CLOSING_START_TAG;break}case N.EQUALS_SIGN:{this.state=I.BEFORE_ATTRIBUTE_VALUE;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentTagToken();break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=I.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.QUOTATION_MARK:{this.state=I.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this.state=I.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(ee.missingAttributeValue),this.state=I.DATA,this.emitCurrentTagToken();break}default:this.state=I.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case N.QUOTATION_MARK:{this.state=I.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case N.APOSTROPHE:{this.state=I.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this._leaveAttrValue(),this.state=I.BEFORE_ATTRIBUTE_NAME;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=I.DATA,this.emitCurrentTagToken();break}case N.NULL:{this._err(ee.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case N.QUOTATION_MARK:case N.APOSTROPHE:case N.LESS_THAN_SIGN:case N.EQUALS_SIGN:case N.GRAVE_ACCENT:{this._err(ee.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this._leaveAttrValue(),this.state=I.BEFORE_ATTRIBUTE_NAME;break}case N.SOLIDUS:{this._leaveAttrValue(),this.state=I.SELF_CLOSING_START_TAG;break}case N.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=I.DATA,this.emitCurrentTagToken();break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:this._err(ee.missingWhitespaceBetweenAttributes),this.state=I.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case N.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=I.DATA,this.emitCurrentTagToken();break}case N.EOF:{this._err(ee.eofInTag),this._emitEOFToken();break}default:this._err(ee.unexpectedSolidusInTag),this.state=I.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentComment(n);break}case N.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case N.NULL:{this._err(ee.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=I.COMMENT_START):this._consumeSequenceIfMatch(fn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(fn.DOCTYPE.length+1),this.state=I.DOCTYPE):this._consumeSequenceIfMatch(fn.CDATA_START,!0)?this.inForeignNode?this.state=I.CDATA_SECTION:(this._err(ee.cdataInHtmlContent),this._createCommentToken(fn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=I.BOGUS_COMMENT):this._ensureHibernation()||(this._err(ee.incorrectlyOpenedComment),this._createCommentToken(2),this.state=I.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_START_DASH;break}case N.GREATER_THAN_SIGN:{this._err(ee.abruptClosingOfEmptyComment),this.state=I.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=I.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_END;break}case N.GREATER_THAN_SIGN:{this._err(ee.abruptClosingOfEmptyComment),this.state=I.DATA,this.emitCurrentComment(n);break}case N.EOF:{this._err(ee.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=I.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_END_DASH;break}case N.LESS_THAN_SIGN:{n.data+="<",this.state=I.COMMENT_LESS_THAN_SIGN;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.data+=ft;break}case N.EOF:{this._err(ee.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case N.EXCLAMATION_MARK:{n.data+="!",this.state=I.COMMENT_LESS_THAN_SIGN_BANG;break}case N.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=I.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===N.HYPHEN_MINUS?this.state=I.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=I.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===N.HYPHEN_MINUS?this.state=I.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=I.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==N.GREATER_THAN_SIGN&&t!==N.EOF&&this._err(ee.nestedComment),this.state=I.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_END;break}case N.EOF:{this._err(ee.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=I.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentComment(n);break}case N.EXCLAMATION_MARK:{this.state=I.COMMENT_END_BANG;break}case N.HYPHEN_MINUS:{n.data+="-";break}case N.EOF:{this._err(ee.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=I.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{n.data+="--!",this.state=I.COMMENT_END_DASH;break}case N.GREATER_THAN_SIGN:{this._err(ee.incorrectlyClosedComment),this.state=I.DATA,this.emitCurrentComment(n);break}case N.EOF:{this._err(ee.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=I.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_DOCTYPE_NAME;break}case N.GREATER_THAN_SIGN:{this.state=I.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case N.EOF:{this._err(ee.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingWhitespaceBeforeDoctypeName),this.state=I.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(qs(t))this._createDoctypeToken(String.fromCharCode($u(t))),this.state=I.DOCTYPE_NAME;else switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.NULL:{this._err(ee.unexpectedNullCharacter),this._createDoctypeToken(ft),this.state=I.DOCTYPE_NAME;break}case N.GREATER_THAN_SIGN:{this._err(ee.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(ee.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=I.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.AFTER_DOCTYPE_NAME;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.name+=ft;break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(qs(t)?$u(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(fn.PUBLIC,!1)?this.state=I.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(fn.SYSTEM,!1)?this.state=I.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(ee.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case N.QUOTATION_MARK:{this._err(ee.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this._err(ee.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(ee.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.QUOTATION_MARK:{n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(ee.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case N.QUOTATION_MARK:{this.state=I.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.publicId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(ee.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(ee.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 N.APOSTROPHE:{this.state=I.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.publicId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(ee.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(ee.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 N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.QUOTATION_MARK:{this._err(ee.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this._err(ee.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.QUOTATION_MARK:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case N.QUOTATION_MARK:{this._err(ee.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this._err(ee.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(ee.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.QUOTATION_MARK:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(ee.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case N.QUOTATION_MARK:{this.state=I.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.systemId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(ee.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(ee.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 N.APOSTROPHE:{this.state=I.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case N.NULL:{this._err(ee.unexpectedNullCharacter),n.systemId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(ee.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(ee.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 N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(ee.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(ee.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case N.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.NULL:{this._err(ee.unexpectedNullCharacter);break}case N.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case N.RIGHT_SQUARE_BRACKET:{this.state=I.CDATA_SECTION_BRACKET;break}case N.EOF:{this._err(ee.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===N.RIGHT_SQUARE_BRACKET?this.state=I.CDATA_SECTION_END:(this._emitChars("]"),this.state=I.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case N.GREATER_THAN_SIGN:{this.state=I.DATA;break}case N.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=I.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(N.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&U1(this.preprocessor.peek(1))?I.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){U1(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===N.SEMICOLON&&this._err(ee.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const j1=new Set([m.DD,m.DT,m.LI,m.OPTGROUP,m.OPTION,m.P,m.RB,m.RP,m.RT,m.RTC]),$1=new Set([...j1,m.CAPTION,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]),Vu=new Set([m.APPLET,m.CAPTION,m.HTML,m.MARQUEE,m.OBJECT,m.TABLE,m.TD,m.TEMPLATE,m.TH]),JN=new Set([...Vu,m.OL,m.UL]),ZN=new Set([...Vu,m.BUTTON]),V1=new Set([m.ANNOTATION_XML,m.MI,m.MN,m.MO,m.MS,m.MTEXT]),q1=new Set([m.DESC,m.FOREIGN_OBJECT,m.TITLE]),eO=new Set([m.TR,m.TEMPLATE,m.HTML]),tO=new Set([m.TBODY,m.TFOOT,m.THEAD,m.TEMPLATE,m.HTML]),nO=new Set([m.TABLE,m.TEMPLATE,m.HTML]),rO=new Set([m.TD,m.TH]);class iO{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=m.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===m.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===le.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])!==le.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(gf,le.HTML)}popUntilTableCellPopped(){this.popUntilPopped(rO,le.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(nO,le.HTML)}clearBackToTableBodyContext(){this.clearBackTo(tO,le.HTML)}clearBackToTableRowContext(){this.clearBackTo(eO,le.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]===m.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]===m.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 le.HTML:{if(o===t)return!0;if(n.has(o))return!1;break}case le.SVG:{if(q1.has(o))return!1;break}case le.MATHML:{if(V1.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Vu)}hasInListItemScope(t){return this.hasInDynamicScope(t,JN)}hasInButtonScope(t){return this.hasInDynamicScope(t,ZN)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case le.HTML:{if(gf.has(n))return!0;if(Vu.has(n))return!1;break}case le.SVG:{if(q1.has(n))return!1;break}case le.MATHML:{if(V1.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===le.HTML)switch(this.tagIDs[n]){case t:return!0;case m.TABLE:case m.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===le.HTML)switch(this.tagIDs[t]){case m.TBODY:case m.THEAD:case m.TFOOT:return!0;case m.TABLE:case m.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===le.HTML)switch(this.tagIDs[n]){case t:return!0;case m.OPTION:case m.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&j1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&$1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&$1.has(this.currentTagId);)this.pop()}}const Ef=3;var cr;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(cr||(cr={}));const Y1={type:cr.Marker};class oO{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===cr.Marker)break;const{element:h}=d;if(this.treeAdapter.getTagName(h)===a&&this.treeAdapter.getNamespaceURI(h)===u){const p=this.treeAdapter.getAttrList(h);p.length===o&&r.push({idx:c,attrs:p})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<Ef)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<Ef)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>=Ef&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(Y1)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:cr.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:cr.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(Y1);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===cr.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===cr.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===cr.Element&&n.element===t)}}const Kr={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};Kr.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(Kr.isTextNode(n)){n.value+=t;return}}Kr.appendChild(e,Kr.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Kr.isTextNode(r)?r.value+=t:Kr.insertBefore(e,Kr.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=H(H({},e.sourceCodeLocation),t)}},W1="html",sO="about:legacy-compat",aO="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",G1=["+//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//"],uO=[...G1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],lO=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),K1=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],cO=[...K1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function Q1(e,t){return t.some(n=>e.startsWith(n))}function dO(e){return e.name===W1&&e.publicId===null&&(e.systemId===null||e.systemId===sO)}function fO(e){if(e.name!==W1)return Ln.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===aO)return Ln.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),lO.has(n))return Ln.QUIRKS;let r=t===null?uO:G1;if(Q1(n,r))return Ln.QUIRKS;if(r=t===null?K1:cO,Q1(n,r))return Ln.LIMITED_QUIRKS}return Ln.NO_QUIRKS}const X1={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},hO="definitionurl",pO="definitionURL",mO=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])),gO=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:le.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:le.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:le.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:le.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:le.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:le.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:le.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:le.XML}],["xml:space",{prefix:"xml",name:"space",namespace:le.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:le.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:le.XMLNS}]]),EO=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])),yO=new Set([m.B,m.BIG,m.BLOCKQUOTE,m.BODY,m.BR,m.CENTER,m.CODE,m.DD,m.DIV,m.DL,m.DT,m.EM,m.EMBED,m.H1,m.H2,m.H3,m.H4,m.H5,m.H6,m.HEAD,m.HR,m.I,m.IMG,m.LI,m.LISTING,m.MENU,m.META,m.NOBR,m.OL,m.P,m.PRE,m.RUBY,m.S,m.SMALL,m.SPAN,m.STRONG,m.STRIKE,m.SUB,m.SUP,m.TABLE,m.TT,m.U,m.UL,m.VAR]);function bO(e){const t=e.tagID;return t===m.FONT&&e.attrs.some(({name:r})=>r===Di.COLOR||r===Di.SIZE||r===Di.FACE)||yO.has(t)}function J1(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===hO){e.attrs[t].name=pO;break}}function Z1(e){for(let t=0;t<e.attrs.length;t++){const n=mO.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function yf(e){for(let t=0;t<e.attrs.length;t++){const n=gO.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 TO(e){const t=EO.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Ao(e.tagName))}function xO(e,t){return t===le.MATHML&&(e===m.MI||e===m.MO||e===m.MN||e===m.MS||e===m.MTEXT)}function wO(e,t,n){if(t===le.MATHML&&e===m.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Di.ENCODING){const o=n[r].value.toLowerCase();return o===X1.TEXT_HTML||o===X1.APPLICATION_XML}}return t===le.SVG&&(e===m.FOREIGN_OBJECT||e===m.DESC||e===m.TITLE)}function _O(e,t,n,r){return(!r||r===le.HTML)&&wO(e,t,n)||(!r||r===le.MATHML)&&xO(e,t)}const vO="hidden",SO=8,AO=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 CO={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},eE=new Set([m.TABLE,m.TBODY,m.TFOOT,m.THEAD,m.TR]),tE={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Kr,onParseError:null};class nE{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=H(H({},tE),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 XN(this.options,this),this.activeFormattingElements=new oO(this.treeAdapter),this.fragmentContextID=r?Ao(this.treeAdapter.getTagName(r)):m.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new iO(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=H(H({},tE),n);t!=null||(t=r.treeAdapter.createElement(Y.TEMPLATE,le.HTML,[]));const o=r.treeAdapter.createElement("documentmock",le.HTML,[]),a=new this(r,o,t);return a.fragmentContextID===m.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:CO,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)===le.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,le.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=wt.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)!==le.HTML))switch(this.fragmentContextID){case m.TITLE:case m.TEXTAREA:{this.tokenizer.state=wt.RCDATA;break}case m.STYLE:case m.XMP:case m.IFRAME:case m.NOEMBED:case m.NOFRAMES:case m.NOSCRIPT:{this.tokenizer.state=wt.RAWTEXT;break}case m.SCRIPT:{this.tokenizer.state=wt.SCRIPT_DATA;break}case m.PLAINTEXT:{this.tokenizer.state=wt.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&&ae(H({},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,le.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,le.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,le.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,m.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:p}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(u,{endLine:d,endCol:h,endOffset:p})}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===Ve.END_TAG&&o===n.tagName?{endTag:H({},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===m.SVG&&this.treeAdapter.getTagName(n)===Y.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===le.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===m.MGLYPH||t.tagID===m.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,le.HTML)}_processToken(t){switch(t.type){case Ve.CHARACTER:{this.onCharacter(t);break}case Ve.NULL_CHARACTER:{this.onNullCharacter(t);break}case Ve.COMMENT:{this.onComment(t);break}case Ve.DOCTYPE:{this.onDoctype(t);break}case Ve.START_TAG:{this._processStartTag(t);break}case Ve.END_TAG:{this.onEndTag(t);break}case Ve.EOF:{this.onEof(t);break}case Ve.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const o=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return _O(t,o,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===cr.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(m.P),this.openElements.popUntilTagNamePopped(m.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case m.TR:{this.insertionMode=L.IN_ROW;return}case m.TBODY:case m.THEAD:case m.TFOOT:{this.insertionMode=L.IN_TABLE_BODY;return}case m.CAPTION:{this.insertionMode=L.IN_CAPTION;return}case m.COLGROUP:{this.insertionMode=L.IN_COLUMN_GROUP;return}case m.TABLE:{this.insertionMode=L.IN_TABLE;return}case m.BODY:{this.insertionMode=L.IN_BODY;return}case m.FRAMESET:{this.insertionMode=L.IN_FRAMESET;return}case m.SELECT:{this._resetInsertionModeForSelect(t);return}case m.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case m.HTML:{this.insertionMode=this.headElement?L.AFTER_HEAD:L.BEFORE_HEAD;return}case m.TD:case m.TH:{if(t>0){this.insertionMode=L.IN_CELL;return}break}case m.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===m.TEMPLATE)break;if(r===m.TABLE){this.insertionMode=L.IN_SELECT_IN_TABLE;return}}this.insertionMode=L.IN_SELECT}_isElementCausesFosterParenting(t){return eE.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 m.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===le.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case m.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 WN[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){rR(this,t);return}switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{Ws(this,t);break}case L.BEFORE_HEAD:{Gs(this,t);break}case L.IN_HEAD:{Ks(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Qs(this,t);break}case L.AFTER_HEAD:{Xs(this,t);break}case L.IN_BODY:case L.IN_CAPTION:case L.IN_CELL:case L.IN_TEMPLATE:{iE(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:{wf(this,t);break}case L.IN_TABLE_TEXT:{fE(this,t);break}case L.IN_COLUMN_GROUP:{Wu(this,t);break}case L.AFTER_BODY:{Qu(this,t);break}case L.AFTER_AFTER_BODY:{Xu(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){nR(this,t);return}switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{Ws(this,t);break}case L.BEFORE_HEAD:{Gs(this,t);break}case L.IN_HEAD:{Ks(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Qs(this,t);break}case L.AFTER_HEAD:{Xs(this,t);break}case L.TEXT:{this._insertCharacters(t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{wf(this,t);break}case L.IN_COLUMN_GROUP:{Wu(this,t);break}case L.AFTER_BODY:{Qu(this,t);break}case L.AFTER_AFTER_BODY:{Xu(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){Tf(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:{Tf(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.AFTER_BODY:{LO(this,t);break}case L.AFTER_AFTER_BODY:case L.AFTER_AFTER_FRAMESET:{DO(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case L.INITIAL:{MO(this,t);break}case L.BEFORE_HEAD:case L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:{this._err(t,ee.misplacedDoctype);break}case L.IN_TABLE_TEXT:{ea(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,ee.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?iR(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{FO(this,t);break}case L.BEFORE_HEAD:{UO(this,t);break}case L.IN_HEAD:{Wn(this,t);break}case L.IN_HEAD_NO_SCRIPT:{jO(this,t);break}case L.AFTER_HEAD:{VO(this,t);break}case L.IN_BODY:{Kt(this,t);break}case L.IN_TABLE:{Co(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.IN_CAPTION:{HI(this,t);break}case L.IN_COLUMN_GROUP:{_f(this,t);break}case L.IN_TABLE_BODY:{Gu(this,t);break}case L.IN_ROW:{Ku(this,t);break}case L.IN_CELL:{$I(this,t);break}case L.IN_SELECT:{mE(this,t);break}case L.IN_SELECT_IN_TABLE:{qI(this,t);break}case L.IN_TEMPLATE:{WI(this,t);break}case L.AFTER_BODY:{KI(this,t);break}case L.IN_FRAMESET:{QI(this,t);break}case L.AFTER_FRAMESET:{JI(this,t);break}case L.AFTER_AFTER_BODY:{eR(this,t);break}case L.AFTER_AFTER_FRAMESET:{tR(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?oR(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{BO(this,t);break}case L.BEFORE_HEAD:{HO(this,t);break}case L.IN_HEAD:{zO(this,t);break}case L.IN_HEAD_NO_SCRIPT:{$O(this,t);break}case L.AFTER_HEAD:{qO(this,t);break}case L.IN_BODY:{Yu(this,t);break}case L.TEXT:{OI(this,t);break}case L.IN_TABLE:{Js(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.IN_CAPTION:{zI(this,t);break}case L.IN_COLUMN_GROUP:{jI(this,t);break}case L.IN_TABLE_BODY:{vf(this,t);break}case L.IN_ROW:{pE(this,t);break}case L.IN_CELL:{VI(this,t);break}case L.IN_SELECT:{gE(this,t);break}case L.IN_SELECT_IN_TABLE:{YI(this,t);break}case L.IN_TEMPLATE:{GI(this,t);break}case L.AFTER_BODY:{yE(this,t);break}case L.IN_FRAMESET:{XI(this,t);break}case L.AFTER_FRAMESET:{ZI(this,t);break}case L.AFTER_AFTER_BODY:{Xu(this,t);break}}}onEof(t){switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{Ws(this,t);break}case L.BEFORE_HEAD:{Gs(this,t);break}case L.IN_HEAD:{Ks(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Qs(this,t);break}case L.AFTER_HEAD:{Xs(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:{cE(this,t);break}case L.TEXT:{II(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.IN_TEMPLATE:{EE(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:{xf(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===N.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:{rE(this,t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{wf(this,t);break}case L.IN_TABLE_TEXT:{dE(this,t);break}}}}function kO(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):lE(e,t),n}function NO(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 OO(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>=AO;!c||d?(d&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(u)):(u=IO(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(u,r),r=u)}return r}function IO(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 RO(e,t,n){const r=e.treeAdapter.getTagName(t),o=Ao(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);o===m.TEMPLATE&&a===le.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function PO(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 bf(e,t){for(let n=0;n<SO;n++){const r=kO(e,t);if(!r)break;const o=NO(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const a=OO(e,o,r.element),u=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),u&&RO(e,u,a),PO(e,o,r)}}function Tf(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function LO(e,t){e._appendCommentNode(t,e.openElements.items[0])}function DO(e,t){e._appendCommentNode(t,e.document)}function xf(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 MO(e,t){e._setDocumentType(t);const n=t.forceQuirks?Ln.QUIRKS:fO(t);dO(t)||e._err(t,ee.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=L.BEFORE_HTML}function Ys(e,t){e._err(t,ee.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Ln.QUIRKS),e.insertionMode=L.BEFORE_HTML,e._processToken(t)}function FO(e,t){t.tagID===m.HTML?(e._insertElement(t,le.HTML),e.insertionMode=L.BEFORE_HEAD):Ws(e,t)}function BO(e,t){const n=t.tagID;(n===m.HTML||n===m.HEAD||n===m.BODY||n===m.BR)&&Ws(e,t)}function Ws(e,t){e._insertFakeRootElement(),e.insertionMode=L.BEFORE_HEAD,e._processToken(t)}function UO(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.HEAD:{e._insertElement(t,le.HTML),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD;break}default:Gs(e,t)}}function HO(e,t){const n=t.tagID;n===m.HEAD||n===m.BODY||n===m.HTML||n===m.BR?Gs(e,t):e._err(t,ee.endTagWithoutMatchingOpenElement)}function Gs(e,t){e._insertFakeElement(Y.HEAD,m.HEAD),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD,e._processToken(t)}function Wn(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.BASE:case m.BASEFONT:case m.BGSOUND:case m.LINK:case m.META:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.TITLE:{e._switchToTextParsing(t,wt.RCDATA);break}case m.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,wt.RAWTEXT):(e._insertElement(t,le.HTML),e.insertionMode=L.IN_HEAD_NO_SCRIPT);break}case m.NOFRAMES:case m.STYLE:{e._switchToTextParsing(t,wt.RAWTEXT);break}case m.SCRIPT:{e._switchToTextParsing(t,wt.SCRIPT_DATA);break}case m.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=L.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(L.IN_TEMPLATE);break}case m.HEAD:{e._err(t,ee.misplacedStartTagForHeadElement);break}default:Ks(e,t)}}function zO(e,t){switch(t.tagID){case m.HEAD:{e.openElements.pop(),e.insertionMode=L.AFTER_HEAD;break}case m.BODY:case m.BR:case m.HTML:{Ks(e,t);break}case m.TEMPLATE:{Mi(e,t);break}default:e._err(t,ee.endTagWithoutMatchingOpenElement)}}function Mi(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==m.TEMPLATE&&e._err(t,ee.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,ee.endTagWithoutMatchingOpenElement)}function Ks(e,t){e.openElements.pop(),e.insertionMode=L.AFTER_HEAD,e._processToken(t)}function jO(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.BASEFONT:case m.BGSOUND:case m.HEAD:case m.LINK:case m.META:case m.NOFRAMES:case m.STYLE:{Wn(e,t);break}case m.NOSCRIPT:{e._err(t,ee.nestedNoscriptInHead);break}default:Qs(e,t)}}function $O(e,t){switch(t.tagID){case m.NOSCRIPT:{e.openElements.pop(),e.insertionMode=L.IN_HEAD;break}case m.BR:{Qs(e,t);break}default:e._err(t,ee.endTagWithoutMatchingOpenElement)}}function Qs(e,t){const n=t.type===Ve.EOF?ee.openElementsLeftAfterEof:ee.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=L.IN_HEAD,e._processToken(t)}function VO(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.BODY:{e._insertElement(t,le.HTML),e.framesetOk=!1,e.insertionMode=L.IN_BODY;break}case m.FRAMESET:{e._insertElement(t,le.HTML),e.insertionMode=L.IN_FRAMESET;break}case m.BASE:case m.BASEFONT:case m.BGSOUND:case m.LINK:case m.META:case m.NOFRAMES:case m.SCRIPT:case m.STYLE:case m.TEMPLATE:case m.TITLE:{e._err(t,ee.abandonedHeadElementChild),e.openElements.push(e.headElement,m.HEAD),Wn(e,t),e.openElements.remove(e.headElement);break}case m.HEAD:{e._err(t,ee.misplacedStartTagForHeadElement);break}default:Xs(e,t)}}function qO(e,t){switch(t.tagID){case m.BODY:case m.HTML:case m.BR:{Xs(e,t);break}case m.TEMPLATE:{Mi(e,t);break}default:e._err(t,ee.endTagWithoutMatchingOpenElement)}}function Xs(e,t){e._insertFakeElement(Y.BODY,m.BODY),e.insertionMode=L.IN_BODY,qu(e,t)}function qu(e,t){switch(t.type){case Ve.CHARACTER:{iE(e,t);break}case Ve.WHITESPACE_CHARACTER:{rE(e,t);break}case Ve.COMMENT:{Tf(e,t);break}case Ve.START_TAG:{Kt(e,t);break}case Ve.END_TAG:{Yu(e,t);break}case Ve.EOF:{cE(e,t);break}}}function rE(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function iE(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function YO(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function WO(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function GO(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_FRAMESET)}function KO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML)}function QO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&gf.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,le.HTML)}function XO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function JO(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),n||(e.formElement=e.openElements.current))}function ZO(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===m.LI&&o===m.LI||(n===m.DD||n===m.DT)&&(o===m.DD||o===m.DT)){e.openElements.generateImpliedEndTagsWithExclusion(o),e.openElements.popUntilTagNamePopped(o);break}if(o!==m.ADDRESS&&o!==m.DIV&&o!==m.P&&e._isSpecialElement(e.openElements.items[r],o))break}e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML)}function eI(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.tokenizer.state=wt.PLAINTEXT}function tI(e,t){e.openElements.hasInScope(m.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.framesetOk=!1}function nI(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(Y.A);n&&(bf(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function rI(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function iI(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(m.NOBR)&&(bf(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function oI(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function sI(e,t){e.treeAdapter.getDocumentMode(e.document)!==Ln.QUIRKS&&e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.framesetOk=!1,e.insertionMode=L.IN_TABLE}function oE(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function sE(e){const t=B1(e,Di.TYPE);return t!=null&&t.toLowerCase()===vO}function aI(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),sE(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function uI(e,t){e._appendElement(t,le.HTML),t.ackSelfClosing=!0}function lI(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function cI(e,t){t.tagName=Y.IMG,t.tagID=m.IMG,oE(e,t)}function dI(e,t){e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.tokenizer.state=wt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=L.TEXT}function fI(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,wt.RAWTEXT)}function hI(e,t){e.framesetOk=!1,e._switchToTextParsing(t,wt.RAWTEXT)}function aE(e,t){e._switchToTextParsing(t,wt.RAWTEXT)}function pI(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.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 mI(e,t){e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function gI(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,le.HTML)}function EI(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(m.RTC),e._insertElement(t,le.HTML)}function yI(e,t){e._reconstructActiveFormattingElements(),J1(t),yf(t),t.selfClosing?e._appendElement(t,le.MATHML):e._insertElement(t,le.MATHML),t.ackSelfClosing=!0}function bI(e,t){e._reconstructActiveFormattingElements(),Z1(t),yf(t),t.selfClosing?e._appendElement(t,le.SVG):e._insertElement(t,le.SVG),t.ackSelfClosing=!0}function uE(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function Kt(e,t){switch(t.tagID){case m.I:case m.S:case m.B:case m.U:case m.EM:case m.TT:case m.BIG:case m.CODE:case m.FONT:case m.SMALL:case m.STRIKE:case m.STRONG:{rI(e,t);break}case m.A:{nI(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{QO(e,t);break}case m.P:case m.DL:case m.OL:case m.UL:case m.DIV:case m.DIR:case m.NAV:case m.MAIN:case m.MENU:case m.ASIDE:case m.CENTER:case m.FIGURE:case m.FOOTER:case m.HEADER:case m.HGROUP:case m.DIALOG:case m.DETAILS:case m.ADDRESS:case m.ARTICLE:case m.SEARCH:case m.SECTION:case m.SUMMARY:case m.FIELDSET:case m.BLOCKQUOTE:case m.FIGCAPTION:{KO(e,t);break}case m.LI:case m.DD:case m.DT:{ZO(e,t);break}case m.BR:case m.IMG:case m.WBR:case m.AREA:case m.EMBED:case m.KEYGEN:{oE(e,t);break}case m.HR:{lI(e,t);break}case m.RB:case m.RTC:{gI(e,t);break}case m.RT:case m.RP:{EI(e,t);break}case m.PRE:case m.LISTING:{XO(e,t);break}case m.XMP:{fI(e,t);break}case m.SVG:{bI(e,t);break}case m.HTML:{YO(e,t);break}case m.BASE:case m.LINK:case m.META:case m.STYLE:case m.TITLE:case m.SCRIPT:case m.BGSOUND:case m.BASEFONT:case m.TEMPLATE:{Wn(e,t);break}case m.BODY:{WO(e,t);break}case m.FORM:{JO(e,t);break}case m.NOBR:{iI(e,t);break}case m.MATH:{yI(e,t);break}case m.TABLE:{sI(e,t);break}case m.INPUT:{aI(e,t);break}case m.PARAM:case m.TRACK:case m.SOURCE:{uI(e,t);break}case m.IMAGE:{cI(e,t);break}case m.BUTTON:{tI(e,t);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{oI(e,t);break}case m.IFRAME:{hI(e,t);break}case m.SELECT:{pI(e,t);break}case m.OPTION:case m.OPTGROUP:{mI(e,t);break}case m.NOEMBED:case m.NOFRAMES:{aE(e,t);break}case m.FRAMESET:{GO(e,t);break}case m.TEXTAREA:{dI(e,t);break}case m.NOSCRIPT:{e.options.scriptingEnabled?aE(e,t):uE(e,t);break}case m.PLAINTEXT:{eI(e,t);break}case m.COL:case m.TH:case m.TD:case m.TR:case m.HEAD:case m.FRAME:case m.TBODY:case m.TFOOT:case m.THEAD:case m.CAPTION:case m.COLGROUP:break;default:uE(e,t)}}function TI(e,t){if(e.openElements.hasInScope(m.BODY)&&(e.insertionMode=L.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function xI(e,t){e.openElements.hasInScope(m.BODY)&&(e.insertionMode=L.AFTER_BODY,yE(e,t))}function wI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function _I(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(m.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(m.FORM):n&&e.openElements.remove(n))}function vI(e){e.openElements.hasInButtonScope(m.P)||e._insertFakeElement(Y.P,m.P),e._closePElement()}function SI(e){e.openElements.hasInListItemScope(m.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(m.LI),e.openElements.popUntilTagNamePopped(m.LI))}function AI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function CI(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function kI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function NI(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(Y.BR,m.BR),e.openElements.pop(),e.framesetOk=!1}function lE(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!==m.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 Yu(e,t){switch(t.tagID){case m.A:case m.B:case m.I:case m.S:case m.U:case m.EM:case m.TT:case m.BIG:case m.CODE:case m.FONT:case m.NOBR:case m.SMALL:case m.STRIKE:case m.STRONG:{bf(e,t);break}case m.P:{vI(e);break}case m.DL:case m.UL:case m.OL:case m.DIR:case m.DIV:case m.NAV:case m.PRE:case m.MAIN:case m.MENU:case m.ASIDE:case m.BUTTON:case m.CENTER:case m.FIGURE:case m.FOOTER:case m.HEADER:case m.HGROUP:case m.DIALOG:case m.ADDRESS:case m.ARTICLE:case m.DETAILS:case m.SEARCH:case m.SECTION:case m.SUMMARY:case m.LISTING:case m.FIELDSET:case m.BLOCKQUOTE:case m.FIGCAPTION:{wI(e,t);break}case m.LI:{SI(e);break}case m.DD:case m.DT:{AI(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{CI(e);break}case m.BR:{NI(e);break}case m.BODY:{TI(e,t);break}case m.HTML:{xI(e,t);break}case m.FORM:{_I(e);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{kI(e,t);break}case m.TEMPLATE:{Mi(e,t);break}default:lE(e,t)}}function cE(e,t){e.tmplInsertionModeStack.length>0?EE(e,t):xf(e,t)}function OI(e,t){var n;t.tagID===m.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function II(e,t){e._err(t,ee.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function wf(e,t){if(e.openElements.currentTagId!==void 0&&eE.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 Ve.CHARACTER:{fE(e,t);break}case Ve.WHITESPACE_CHARACTER:{dE(e,t);break}}else Zs(e,t)}function RI(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_CAPTION}function PI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_COLUMN_GROUP}function LI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.COLGROUP,m.COLGROUP),e.insertionMode=L.IN_COLUMN_GROUP,_f(e,t)}function DI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_TABLE_BODY}function MI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.TBODY,m.TBODY),e.insertionMode=L.IN_TABLE_BODY,Gu(e,t)}function FI(e,t){e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function BI(e,t){sE(t)?e._appendElement(t,le.HTML):Zs(e,t),t.ackSelfClosing=!0}function UI(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,le.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Co(e,t){switch(t.tagID){case m.TD:case m.TH:case m.TR:{MI(e,t);break}case m.STYLE:case m.SCRIPT:case m.TEMPLATE:{Wn(e,t);break}case m.COL:{LI(e,t);break}case m.FORM:{UI(e,t);break}case m.TABLE:{FI(e,t);break}case m.TBODY:case m.TFOOT:case m.THEAD:{DI(e,t);break}case m.INPUT:{BI(e,t);break}case m.CAPTION:{RI(e,t);break}case m.COLGROUP:{PI(e,t);break}default:Zs(e,t)}}function Js(e,t){switch(t.tagID){case m.TABLE:{e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode());break}case m.TEMPLATE:{Mi(e,t);break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:case m.TBODY:case m.TD:case m.TFOOT:case m.TH:case m.THEAD:case m.TR:break;default:Zs(e,t)}}function Zs(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,qu(e,t),e.fosterParentingEnabled=n}function dE(e,t){e.pendingCharacterTokens.push(t)}function fE(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function ea(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Zs(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const hE=new Set([m.CAPTION,m.COL,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]);function HI(e,t){const n=t.tagID;hE.has(n)?e.openElements.hasInTableScope(m.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,Co(e,t)):Kt(e,t)}function zI(e,t){const n=t.tagID;switch(n){case m.CAPTION:case m.TABLE:{e.openElements.hasInTableScope(m.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,n===m.TABLE&&Js(e,t));break}case m.BODY:case m.COL:case m.COLGROUP:case m.HTML:case m.TBODY:case m.TD:case m.TFOOT:case m.TH:case m.THEAD:case m.TR:break;default:Yu(e,t)}}function _f(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.COL:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.TEMPLATE:{Wn(e,t);break}default:Wu(e,t)}}function jI(e,t){switch(t.tagID){case m.COLGROUP:{e.openElements.currentTagId===m.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE);break}case m.TEMPLATE:{Mi(e,t);break}case m.COL:break;default:Wu(e,t)}}function Wu(e,t){e.openElements.currentTagId===m.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE,e._processToken(t))}function Gu(e,t){switch(t.tagID){case m.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_ROW;break}case m.TH:case m.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(Y.TR,m.TR),e.insertionMode=L.IN_ROW,Ku(e,t);break}case m.CAPTION:case m.COL:case m.COLGROUP:case m.TBODY:case m.TFOOT:case m.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE,Co(e,t));break}default:Co(e,t)}}function vf(e,t){const n=t.tagID;switch(t.tagID){case m.TBODY:case m.TFOOT:case m.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE);break}case m.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE,Js(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:case m.TD:case m.TH:case m.TR:break;default:Js(e,t)}}function Ku(e,t){switch(t.tagID){case m.TH:case m.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_CELL,e.activeFormattingElements.insertMarker();break}case m.CAPTION:case m.COL:case m.COLGROUP:case m.TBODY:case m.TFOOT:case m.THEAD:case m.TR:{e.openElements.hasInTableScope(m.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,Gu(e,t));break}default:Co(e,t)}}function pE(e,t){switch(t.tagID){case m.TR:{e.openElements.hasInTableScope(m.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY);break}case m.TABLE:{e.openElements.hasInTableScope(m.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,vf(e,t));break}case m.TBODY:case m.TFOOT:case m.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(m.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,vf(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:case m.TD:case m.TH:break;default:Js(e,t)}}function $I(e,t){const n=t.tagID;hE.has(n)?(e.openElements.hasInTableScope(m.TD)||e.openElements.hasInTableScope(m.TH))&&(e._closeTableCell(),Ku(e,t)):Kt(e,t)}function VI(e,t){const n=t.tagID;switch(n){case m.TD:case m.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_ROW);break}case m.TABLE:case m.TBODY:case m.TFOOT:case m.THEAD:case m.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),pE(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:break;default:Yu(e,t)}}function mE(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.OPTION:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e._insertElement(t,le.HTML);break}case m.OPTGROUP:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e.openElements.currentTagId===m.OPTGROUP&&e.openElements.pop(),e._insertElement(t,le.HTML);break}case m.HR:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e.openElements.currentTagId===m.OPTGROUP&&e.openElements.pop(),e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.INPUT:case m.KEYGEN:case m.TEXTAREA:case m.SELECT:{e.openElements.hasInSelectScope(m.SELECT)&&(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode(),t.tagID!==m.SELECT&&e._processStartTag(t));break}case m.SCRIPT:case m.TEMPLATE:{Wn(e,t);break}}}function gE(e,t){switch(t.tagID){case m.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===m.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===m.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===m.OPTGROUP&&e.openElements.pop();break}case m.OPTION:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop();break}case m.SELECT:{e.openElements.hasInSelectScope(m.SELECT)&&(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode());break}case m.TEMPLATE:{Mi(e,t);break}}}function qI(e,t){const n=t.tagID;n===m.CAPTION||n===m.TABLE||n===m.TBODY||n===m.TFOOT||n===m.THEAD||n===m.TR||n===m.TD||n===m.TH?(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode(),e._processStartTag(t)):mE(e,t)}function YI(e,t){const n=t.tagID;n===m.CAPTION||n===m.TABLE||n===m.TBODY||n===m.TFOOT||n===m.THEAD||n===m.TR||n===m.TD||n===m.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode(),e.onEndTag(t)):gE(e,t)}function WI(e,t){switch(t.tagID){case m.BASE:case m.BASEFONT:case m.BGSOUND:case m.LINK:case m.META:case m.NOFRAMES:case m.SCRIPT:case m.STYLE:case m.TEMPLATE:case m.TITLE:{Wn(e,t);break}case m.CAPTION:case m.COLGROUP:case m.TBODY:case m.TFOOT:case m.THEAD:{e.tmplInsertionModeStack[0]=L.IN_TABLE,e.insertionMode=L.IN_TABLE,Co(e,t);break}case m.COL:{e.tmplInsertionModeStack[0]=L.IN_COLUMN_GROUP,e.insertionMode=L.IN_COLUMN_GROUP,_f(e,t);break}case m.TR:{e.tmplInsertionModeStack[0]=L.IN_TABLE_BODY,e.insertionMode=L.IN_TABLE_BODY,Gu(e,t);break}case m.TD:case m.TH:{e.tmplInsertionModeStack[0]=L.IN_ROW,e.insertionMode=L.IN_ROW,Ku(e,t);break}default:e.tmplInsertionModeStack[0]=L.IN_BODY,e.insertionMode=L.IN_BODY,Kt(e,t)}}function GI(e,t){t.tagID===m.TEMPLATE&&Mi(e,t)}function EE(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):xf(e,t)}function KI(e,t){t.tagID===m.HTML?Kt(e,t):Qu(e,t)}function yE(e,t){var n;if(t.tagID===m.HTML){if(e.fragmentContext||(e.insertionMode=L.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===m.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 Qu(e,t)}function Qu(e,t){e.insertionMode=L.IN_BODY,qu(e,t)}function QI(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.FRAMESET:{e._insertElement(t,le.HTML);break}case m.FRAME:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.NOFRAMES:{Wn(e,t);break}}}function XI(e,t){t.tagID===m.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==m.FRAMESET&&(e.insertionMode=L.AFTER_FRAMESET))}function JI(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function ZI(e,t){t.tagID===m.HTML&&(e.insertionMode=L.AFTER_AFTER_FRAMESET)}function eR(e,t){t.tagID===m.HTML?Kt(e,t):Xu(e,t)}function Xu(e,t){e.insertionMode=L.IN_BODY,qu(e,t)}function tR(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function nR(e,t){t.chars=ft,e._insertCharacters(t)}function rR(e,t){e._insertCharacters(t),e.framesetOk=!1}function bE(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==le.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function iR(e,t){if(bO(t))bE(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===le.MATHML?J1(t):r===le.SVG&&(TO(t),Z1(t)),yf(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function oR(e,t){if(t.tagID===m.P||t.tagID===m.BR){bE(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)===le.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 sR=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,aR=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),TE={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function xE(e,t){const n=ER(e),r=P1("type",{handlers:{root:uR,element:lR,text:cR,comment:_E,doctype:dR,raw:hR},unknown:pR}),o={parser:n?new nE(TE):nE.getFragmentParser(void 0,TE),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),ko(o,ur());const a=n?o.parser.document:o.parser.getFragment(),u=uN(a,{file:o.options.file});return o.stitches&&Hu(u,"comment",function(c,d,h){const p=c;if(p.value.stitch&&h&&d!==void 0){const E=h.children;return E[d]=p.value.stitch,d}}),u.type==="root"&&u.children.length===1&&u.children[0].type===e.type?u.children[0]:u}function wE(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function uR(e,t){wE(e.children,t)}function lR(e,t){mR(e,t),wE(e.children,t),gR(e,t)}function cR(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:Ve.CHARACTER,chars:e.value,location:ta(e)};ko(t,ur(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function dR(e,t){const n={type:Ve.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:ta(e)};ko(t,ur(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function fR(e,t){t.stitches=!0;const n=yR(e);if("children"in e&&"children"in n){const r=xE({type:"root",children:e.children},t.options);n.children=r.children}_E({type:"comment",value:{stitch:n}},t)}function _E(e,t){const n=e.value,r={type:Ve.COMMENT,data:n,location:ta(e)};ko(t,ur(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function hR(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,vE(t,ur(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(sR,"&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 pR(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))fR(n,t);else{let r="";throw aR.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 ko(e,t){vE(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=wt.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 vE(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 mR(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===wt.PLAINTEXT)return;ko(t,ur(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Pi.html;o===Pi.html&&n==="svg"&&(o=Pi.svg);const a=_N(ae(H({},e),{children:[]}),{space:o===Pi.svg?"svg":"html"}),u={type:Ve.START_TAG,tagName:n,tagID:Ao(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:ta(e)};t.parser.currentToken=u,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function gR(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&IN.includes(n)||t.parser.tokenizer.state===wt.PLAINTEXT)return;ko(t,Nu(e));const r={type:Ve.END_TAG,tagName:n,tagID:Ao(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:ta(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===wt.RCDATA||t.parser.tokenizer.state===wt.RAWTEXT||t.parser.tokenizer.state===wt.SCRIPT_DATA)&&(t.parser.tokenizer.state=wt.DATA)}function ER(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function ta(e){const t=ur(e)||{line:void 0,column:void 0,offset:void 0},n=Nu(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 yR(e){return"children"in e?Ri(ae(H({},e),{children:[]})):Ri(e)}function SE(e){return function(t,n){return xE(t,ae(H({},e),{file:n}))}}const Fi=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],AE={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Fi,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Fi],h2:[["className","sr-only"]],img:[...Fi,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Fi,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Fi],table:[...Fi],ul:[...Fi,["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"]},Qr={}.hasOwnProperty;function bR(e,t){let n={type:"root",children:[]};const r={schema:t?H(H({},AE),t):AE,stack:[]},o=CE(r,e);return o&&(Array.isArray(o)?o.length===1?n=o[0]:n.children=o:n=o),n}function CE(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return TR(e,n);case"doctype":return xR(e,n);case"element":return wR(e,n);case"root":return _R(e,n);case"text":return vR(e,n)}}}function TR(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 na(a,t),a}}function xR(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return na(n,t),n}}function wR(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=kE(e,t.children),o=SR(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&&Qr.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 na(u,t),u}function _R(e,t){const r={type:"root",children:kE(e,t.children)};return na(r,t),r}function vR(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return na(r,t),r}function kE(e,t){const n=[];if(Array.isArray(t)){const r=t;let o=-1;for(;++o<r.length;){const a=CE(e,r[o]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function SR(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,o=e.schema.required,a=r&&Qr.call(r,n)?r[n]:void 0,u=r&&Qr.call(r,"*")?r["*"]:void 0,c=t&&typeof t=="object"?t:{},d={};let h;for(h in c)if(Qr.call(c,h)){const p=c[h];let E=NE(e,IE(a,h),h,p);E==null&&(E=NE(e,IE(u,h),h,p)),E!=null&&(d[h]=E)}if(o&&Qr.call(o,n)){const p=o[n];for(h in p)Qr.call(p,h)&&!Qr.call(d,h)&&(d[h]=p[h])}return d}function NE(e,t,n,r){return t?Array.isArray(r)?AR(e,t,n,r):OE(e,t,n,r):void 0}function AR(e,t,n,r){let o=-1;const a=[];for(;++o<r.length;){const u=OE(e,t,n,r[o]);(typeof u=="number"||typeof u=="string")&&a.push(u)}return a}function OE(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&CR(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 CR(e,t,n){const r=e.schema.protocols&&Qr.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 p=r[h];if(a===p.length&&o.slice(0,p.length)===p)return!0}return!1}function na(e,t){const n=fg(t);t.data&&(e.data=Ri(t.data)),n&&(e.position=n)}function IE(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 kR(e){return function(t){return bR(t,e)}}const RE=({globalClassName:e,openLinksInNewTab:t,href:n,title:r,children:o})=>{const a=n?t?"_blank":"_self":void 0;return v.jsx("a",ae(H(H({className:$(e,`${U}-link`)},n?{href:n,target:a}:{}),r?{title:r}:{}),{rel:"noopener noreferrer",children:o}))},NR=()=>{const{disclaimerText:e,disclaimerMarkdown:t,globalClassName:n}=At();return!e&&!t?null:v.jsx("div",{className:$(n,`${U}-disclaimer`),children:t?v.jsx(h1,{rehypePlugins:[SE,kR],components:{ul:({children:r})=>v.jsx("ul",{className:$(n,`${U}-ul`),children:r}),ol:({children:r})=>v.jsx("ol",{className:$(n,`${U}-ol`),children:r}),li:({children:r})=>v.jsx("li",{className:$(n,`${U}-li`),children:r}),a:({href:r,title:o,children:a})=>v.jsx(RE,{globalClassName:n,openLinksInNewTab:!0,href:r,title:o,children:a}),img:({src:r,alt:o})=>v.jsx("img",{className:$(n,`${U}-disclaimer-image`),src:r,alt:o}),p:({children:r})=>v.jsx("p",{className:$(n,`${U}-disclaimer-text`),children:r}),span:({children:r})=>v.jsx("span",{className:$(n,`${U}-disclaimer-text-span`),children:r})},children:t}):v.jsx("p",{className:$(n,`${U}-disclaimer-text`),children:e})})},Sf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{isConnected:o}=Vr(),{globalClassName:a,searchConfig:u}=At(),c=Z.useRef(null),d=t||!o,h=E=>{var y;E.preventDefault();const T=(((y=c.current)==null?void 0:y.value)||"").trim();T&&(c.current.value="",r(T))},p=()=>{r("Can you connect me to a human?")};return v.jsxs("div",{className:$(a,e,`cim-${n}-component`,`${U}-search-bar-wrapper`),children:[v.jsxs("form",{className:$(a,e,`cim-${n}-component`,`${U}-search-bar`),name:`${U}-search-form`,onSubmit:h,children:[v.jsx("input",{className:$(a,e,`cim-${n}-component`,`${U}-search-input`),type:"text",ref:c,placeholder:(u==null?void 0:u.placeholder)||"Ask us anything",name:`${U}-user-input`,disabled:d}),v.jsx(XS,{className:e,globalClassName:a,searchConfig:u,componentType:n,isLoading:d}),v.jsx(ar,{className:$(a,`${U}-escalate-btn`),ariaLabel:"Connect to a human agent",title:"Connect to a human agent",disabled:d,onClick:p,icon:v.jsx(zS,{})})]}),v.jsx(NR,{})]})};function OR(e){return mt({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 PE=Z.createContext({isOpen:!1}),Af=Z.createContext(null),LE=Z.createContext(null),ra=()=>{var n,r;const e=Z.useContext(Af),t=Z.useContext(LE);return(r=(n=e==null?void 0:e.closeMenu)!=null?n:t==null?void 0:t.closeMenu)!=null?r:(()=>{})},DE=({onClearChat:e,componentType:t})=>{const n=ra(),r=()=>{e(),n()};return v.jsxs("button",{className:$(`${U}-overflow-menu-button`,"clear-chat-button",`cim-${t}-component`),onClick:r,children:[v.jsx(OR,{}),"Clear chat"]})};function IR(e){return e==null?[]:Array.isArray(e)?e:[e]}var RR=(e,...t)=>e.concat(t),PR=(e,...t)=>e.filter(n=>!t.includes(n)),LR=e=>Array.from(new Set(e));function ME(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 DR(e,t,n={}){const{step:r=1,loop:o=!0}=n;return ME(e,t,{step:-r,loop:o})}var MR=e=>Array.isArray(e),FE=e=>e!=null&&typeof e=="object",FR=e=>FE(e)&&!MR(e),Ju=e=>typeof e=="string",No=e=>typeof e=="function",BR=e=>e==null,UR=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),HR=e=>Object.prototype.toString.call(e),BE=Function.prototype.toString,zR=BE.call(Object),jR=e=>{if(!FE(e)||HR(e)!="[object Object]"||qR(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=UR(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&BE.call(n)==zR},$R=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,VR=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,qR=e=>$R(e)||VR(e),YR=e=>e(),WR=()=>{},Cf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function GR(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:KR,max:QR}=Math,XR=e=>Number.isNaN(e),JR=e=>XR(e)?0:e,UE=(e,t,n)=>KR(QR(JR(e),t),n);function kf(e){if(!jR(e)||e===void 0)return e;const t=Reflect.ownKeys(e).filter(r=>typeof r=="string"),n={};for(const r of t){const o=e[r];o!==void 0&&(n[r]=kf(o))}return n}function Nf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function ZR(e,t){if(e==null)throw new Error(t())}function eP(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 tP=Object.defineProperty,nP=(e,t,n)=>t in e?tP(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Of=(e,t,n)=>nP(e,typeof t!="symbol"?t+"":t,n),HE=()=>{},Zu=e=>typeof e=="object"&&e!==null,Oo=e=>e?"":void 0,zE=e=>e?"true":void 0,rP=1,iP=9,oP=11,Ft=e=>Zu(e)&&e.nodeType===rP&&typeof e.nodeName=="string",el=e=>Zu(e)&&e.nodeType===iP,sP=e=>Zu(e)&&e===e.window,jE=e=>Ft(e)?e.localName||"":"#document";function aP(e){return["html","body","#document"].includes(jE(e))}var uP=e=>Zu(e)&&e.nodeType!==void 0,Bi=e=>uP(e)&&e.nodeType===oP&&"host"in e,lP=e=>Ft(e)&&e.localName==="input",cP=e=>Ft(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function ia(e){if(!e)return!1;const t=e.getRootNode();return Po(t)===e}var dP=/(textarea|select)/;function fP(e){if(e==null||!Ft(e))return!1;try{return lP(e)&&e.selectionStart!=null||dP.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function Io(e,t){var r;if(!e||!t||!Ft(e)||!Ft(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Bi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function dr(e){var t;return el(e)?e:sP(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function hP(e){return dr(e).documentElement}function Ro(e){var t,n,r;return Bi(e)?Ro(e.host):el(e)?(t=e.defaultView)!=null?t:window:Ft(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Po(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 pP(e){if(jE(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Bi(e)&&e.host||hP(e);return Bi(t)?t.host:t}function If(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),el(t)||Bi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var Rf=new WeakMap;function Lo(e){return Rf.has(e)||Rf.set(e,Ro(e).getComputedStyle(e)),Rf.get(e)}var Pf=new Set(["menu","listbox","dialog","grid","tree","region"]),mP=e=>Pf.has(e),$E=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function VE(e,t){const n=new Set,r=If(e),o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=$E(c);for(const h of d){if(!h||n.has(h))continue;n.add(h);const p=r.getElementById(h);if(p){const E=p.getAttribute("role"),T=p.getAttribute("aria-modal")==="true";if(E&&mP(E)&&!T&&(p===t||p.contains(t)||o(p)))return!0}}}return!1};return o(e)}function qE(e,t){const n=If(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=$E(c);for(const h of d){if(!h||r.has(h))continue;r.add(h);const p=n.getElementById(h);if(p){const E=p.getAttribute("role"),T=p.getAttribute("aria-modal")==="true";E&&Pf.has(E)&&!T&&(t(p),o(p))}}}};o(e)}function gP(e){const t=new Set;return qE(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function EP(e){const t=e.getAttribute("role");return!!(t&&Pf.has(t))}function yP(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function bP(e){var t;return yP(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function TP(e){if(!e.id)return!1;const t=If(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&EP(e))}var Lf=()=>typeof document!="undefined";function xP(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Df=e=>Lf()&&e.test(xP()),wP=e=>Lf()&&e.test(navigator.vendor),YE=()=>Lf()&&!!navigator.maxTouchPoints,_P=()=>Df(/^iPhone/i),vP=()=>Df(/^iPad/i)||Mf()&&navigator.maxTouchPoints>1,tl=()=>_P()||vP(),SP=()=>Mf()||tl(),Mf=()=>Df(/^Mac/i),AP=()=>SP()&&wP(/apple/i);function CP(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=CP(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var WE=e=>e.button===0,kP=e=>e.button===2||Mf()&&e.ctrlKey&&e.button===0,NP=e=>"touches"in e&&e.touches.length>0,OP={Up:"ArrowUp",Down:"ArrowDown",Esc:"Escape"," ":"Space",",":"Comma",Left:"ArrowLeft",Right:"ArrowRight"},GE={ArrowLeft:"ArrowRight",ArrowRight:"ArrowLeft"};function IP(e,t={}){var u;const{dir:n="ltr",orientation:r="horizontal"}=t;let o=e.key;return o=(u=OP[o])!=null?u:o,n==="rtl"&&r==="horizontal"&&o in GE&&(o=GE[o]),o}function KE(e,t="client"){const n=NP(e)?e.touches[0]||e.changedTouches[0]:e;return{x:n[`${t}X`],y:n[`${t}Y`]}}var Bt=(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)}},QE=e=>Ft(e)&&e.tagName==="IFRAME",RP=/^(audio|video|details)$/;function XE(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var PP=e=>!Number.isNaN(XE(e)),LP=e=>XE(e)<0;function DP(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 JE(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=DP(d,t);if(h){const p=Array.from(h.querySelectorAll(nl)).filter(n),E=u.get(d);if(E!==void 0){const T=E+1;r.splice(T,0,...p),p.forEach((y,x)=>{u.set(y,T+x)});for(let y=T+p.length;y<r.length;y++)u.set(r[y],y)}else{const T=r.length;r.push(...p),p.forEach((y,x)=>{u.set(y,T+x)})}o.push(...p)}}return r}var nl="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",ZE=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(nl));(n==!0||n=="if-empty"&&o.length===0)&&Ft(e)&&fr(e)&&o.unshift(e);const u=[];for(const c of o)if(fr(c)){if(QE(c)&&c.contentDocument){const d=c.contentDocument.body;u.push(...ZE(d,{getShadowRoot:r}));continue}u.push(c)}return r?JE(u,r,fr):u};function fr(e){return!Ft(e)||e.closest("[inert]")?!1:e.matches(nl)&&cP(e)}function Do(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(nl));n&&Ui(e)&&o.unshift(e);const a=[];for(const u of o)if(Ui(u)){if(QE(u)&&u.contentDocument){const c=u.contentDocument.body;a.push(...Do(c,{getShadowRoot:r}));continue}a.push(u)}if(r){const u=JE(a,r,Ui);return!u.length&&n?o:u}return!a.length&&n?o:a}function Ui(e){return Ft(e)&&e.tabIndex>0?!0:fr(e)&&!LP(e)}function MP(e,t={}){const n=Do(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function FP(e,t={}){const{current:n,getShadowRoot:r}=t,o=Do(e,{getShadowRoot:r}),a=(e==null?void 0:e.ownerDocument)||document,u=n!=null?n:Po(a);if(!u)return null;const c=o.indexOf(u);return o[c+1]||null}function oa(e){return e.tabIndex<0&&(RP.test(e.localName)||fP(e))&&!PP(e)?0:e.tabIndex}function ey(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=Do(t);a=r?u.filter(r)[0]:u[0]}return a||t||void 0}var BP=class nw{constructor(){Of(this,"id",null),Of(this,"fn_cleanup"),Of(this,"cleanup",()=>{this.cancel()})}static create(){return new nw}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 Ot(e){const t=BP.create();return t.request(e),t.cleanup}function ty(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 Ff(e){const t=pP(e);return aP(t)?dr(t).body:Ft(t)&&zP(t)?t:Ff(t)}var UP=/auto|scroll|overlay|hidden|clip/,HP=new Set(["inline","contents"]);function zP(e){const t=Ro(e),{overflow:n,overflowX:r,overflowY:o,display:a}=t.getComputedStyle(e);return UP.test(n+o+r)&&!HP.has(a)}var Mo="default",Bf="",rl=new WeakMap;function jP(e={}){const{target:t,doc:n}=e,r=n!=null?n:document,o=r.documentElement;return tl()?(Mo==="default"&&(Bf=o.style.webkitUserSelect,o.style.webkitUserSelect="none"),Mo="disabled"):t&&(rl.set(t,t.style.userSelect),t.style.userSelect="none"),()=>$P({target:t,doc:r})}function $P(e={}){const{target:t,doc:n}=e,o=(n!=null?n:document).documentElement;if(tl()){if(Mo!=="disabled")return;Mo="restoring",setTimeout(()=>{ty(()=>{Mo==="restoring"&&(o.style.webkitUserSelect==="none"&&(o.style.webkitUserSelect=Bf||""),Bf="",Mo="default")})},300)}else if(t&&rl.has(t)){const a=rl.get(t);t.style.userSelect==="none"&&(t.style.userSelect=a!=null?a:""),t.getAttribute("style")===""&&t.removeAttribute("style"),rl.delete(t)}}function VP(e={}){const u=e,{defer:t,target:n}=u,r=sn(u,["defer","target"]),o=t?Ot:c=>c(),a=[];return a.push(o(()=>{const c=typeof n=="function"?n():n;a.push(jP(ae(H({},r),{target:c})))})),()=>{a.forEach(c=>c==null?void 0:c())}}function qP(e,t){const{onPointerMove:n,onPointerUp:r}=t,o=c=>{const d=KE(c),h=Math.sqrt(nu(d.x,2)+nu(d.y,2)),p=c.pointerType==="touch"?10:5;if(!(h<p)){if(c.pointerType==="mouse"&&c.button===0){a(c);return}n({point:d,event:c})}},a=c=>{const d=KE(c);r({point:d,event:c})},u=[Bt(e,"pointermove",o,!1),Bt(e,"pointerup",a,!1),Bt(e,"pointercancel",a,!1),Bt(e,"contextmenu",a,!1),VP({doc:e})];return()=>{u.forEach(c=>c())}}function YP(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 p=null;const[E,T]=MP(e,{includeContainer:!0,getShadowRoot:a}),y=FP(c,{current:n,getShadowRoot:a}),x=!E&&!T;h.shiftKey&&ia(y)?(o==null||o(),p=T):h.shiftKey&&(ia(E)||x)?p=n:!h.shiftKey&&ia(n)?(o==null||o(),p=E):!h.shiftKey&&(ia(T)||x)&&(p=y),p&&(h.preventDefault(),typeof r=="function"?r(p):p.focus())}return Bt(u,"keydown",d,!0)}function WP(e,t){const c=t,{defer:n,triggerElement:r}=c,o=sn(c,["defer","triggerElement"]),a=n?Ot:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof r=="function"?r():r;u.push(YP(d,H({triggerElement:h},o)))})),()=>{u.forEach(d=>d==null?void 0:d())}}function GP(e,t){var n;return Array.from((n=e==null?void 0:e.querySelectorAll(t))!=null?n:[])}function il(e,t){if(!e)return HE;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 KP(e,t,n){if(!e)return HE;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 QP(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 XP(e,t){const{timeout:n,rootNode:r}=t,o=Ro(r),a=dr(r),u=new o.AbortController;return QP(new Promise(c=>{const d=e();if(d){c(d);return}const h=new o.MutationObserver(()=>{const p=e();p&&p.isConnected&&(h.disconnect(),c(p))});h.observe(a.body,{childList:!0,subtree:!0})}),u,n)}var JP=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),ZP=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,ny=e=>{const t={};let n;for(;n=ZP.exec(e);)t[n[1]]=n[2];return t},e4=(e,t)=>{if(Ju(e)){if(Ju(t))return`${e};${t}`;e=ny(e)}else Ju(t)&&(t=ny(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function It(...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]=Cf(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=JP(t[o],n[o]);continue}if(o==="style"){t[o]=e4(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 xF(e){return e}var Fo=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Fo||{}),Uf="__init__";function t4(e){const t=()=>{var u,c;return(c=(u=e.getRootNode)==null?void 0:u.call(e))!=null?c:document},n=()=>dr(t()),r=()=>{var u;return(u=n().defaultView)!=null?u:window},o=()=>Po(t()),a=u=>t().getElementById(u);return ae(H({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:ia,getById:a})}function n4(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var Bo=()=>e=>Array.from(new Set(e)),ry=typeof globalThis.document!="undefined"?Z.useLayoutEffect:Z.useEffect;function ol(e){var E,T;const t=(E=e().value)!=null?E:e().defaultValue,n=(T=e().isEqual)!=null?T:Object.is,[r]=Z.useState(t),[o,a]=Z.useState(r),u=e().value!==void 0,c=Z.useRef(o);c.current=u?e().value:o;const d=Z.useRef(c.current);ry(()=>{d.current=c.current},[o,e().value]);const h=y=>{var S,A;const x=d.current,_=No(y)?y(x):y;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:_,prev:x}),u||a(_),n(_,x)||(A=(S=e()).onChange)==null||A.call(S,_,x)};function p(){return u?e().value:o}return{initial:r,ref:c,get:p,set(y){(e().sync?Is.flushSync:YR)(()=>h(y))},invoke(y,x){var _,S;(S=(_=e()).onChange)==null||S.call(_,y,x)},hash(y){var x,_,S;return(S=(_=(x=e()).hash)==null?void 0:_.call(x,y))!=null?S:String(y)}}}ol.cleanup=e=>{Z.useEffect(()=>e,[])},ol.ref=e=>{const t=Z.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function r4(e){const t=Z.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var i4=(e,t)=>{const n=Z.useRef(!1),r=Z.useRef(!1);Z.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),Z.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function sl(e,t={}){var ne,J,re,oe,be,Ie;const n=Z.useMemo(()=>{const{id:fe,ids:Q,getRootNode:se}=t;return t4({id:fe,ids:Q,getRootNode:se})},[t]),r=(...fe)=>{e.debug&&console.log(...fe)},o=(J=(ne=e.props)==null?void 0:ne.call(e,{props:kf(t),scope:n}))!=null?J:t,a=o4(o),u=(re=e.context)==null?void 0:re.call(e,{prop:a,bindable:ol,scope:n,flush:oy,getContext(){return d},getComputed(){return W},getRefs(){return _},getEvent(){return y()}}),c=iy(u),d={get(fe){var Q;return(Q=c.current)==null?void 0:Q[fe].ref.current},set(fe,Q){var se;(se=c.current)==null||se[fe].set(Q)},initial(fe){var Q;return(Q=c.current)==null?void 0:Q[fe].initial},hash(fe){var se,C;const Q=(se=c.current)==null?void 0:se[fe].get();return(C=c.current)==null?void 0:C[fe].hash(Q)}},h=Z.useRef(new Map),p=Z.useRef(null),E=Z.useRef(null),T=Z.useRef({type:""}),y=()=>ae(H({},T.current),{current(){return T.current},previous(){return E.current}}),x=()=>ae(H({},M),{matches(...fe){return fe.includes(M.ref.current)},hasTag(fe){var Q,se;return!!((se=(Q=e.states[M.ref.current])==null?void 0:Q.tags)!=null&&se.includes(fe))}}),_=r4((be=(oe=e.refs)==null?void 0:oe.call(e,{prop:a,context:d}))!=null?be:{}),S=()=>({state:x(),context:d,event:y(),prop:a,send:D,action:A,guard:O,track:i4,refs:_,computed:W,flush:oy,scope:n,choose:z}),A=fe=>{const Q=No(fe)?fe(S()):fe;if(!Q)return;const se=Q.map(C=>{var te,k;const F=(k=(te=e.implementations)==null?void 0:te.actions)==null?void 0:k[C];return F||Nf(`[zag-js] No implementation found for action "${JSON.stringify(C)}"`),F});for(const C of se)C==null||C(S())},O=fe=>{var Q,se;return No(fe)?fe(S()):(se=(Q=e.implementations)==null?void 0:Q.guards)==null?void 0:se[fe](S())},R=fe=>{const Q=No(fe)?fe(S()):fe;if(!Q)return;const se=Q.map(F=>{var k,pe;const te=(pe=(k=e.implementations)==null?void 0:k.effects)==null?void 0:pe[F];return te||Nf(`[zag-js] No implementation found for effect "${JSON.stringify(F)}"`),te}),C=[];for(const F of se){const te=F==null?void 0:F(S());te&&C.push(te)}return()=>C.forEach(F=>F==null?void 0:F())},z=fe=>IR(fe).find(Q=>{let se=!Q.guard;return Ju(Q.guard)?se=!!O(Q.guard):No(Q.guard)&&(se=Q.guard(S())),se}),W=fe=>{ZR(e.computed,()=>"[zag-js] No computed object found on machine");const Q=e.computed[fe];return Q({context:d,event:y(),prop:a,refs:_,scope:n,computed:W})},M=ol(()=>({defaultValue:e.initialState({prop:a}),onChange(fe,Q){var C,F,te,k;if(Q){const pe=h.current.get(Q);pe==null||pe(),h.current.delete(Q)}Q&&A((C=e.states[Q])==null?void 0:C.exit),A((F=p.current)==null?void 0:F.actions);const se=R((te=e.states[fe])==null?void 0:te.effects);if(se&&h.current.set(fe,se),Q===Uf){A(e.entry);const pe=R(e.effects);pe&&h.current.set(Uf,pe)}A((k=e.states[fe])==null?void 0:k.entry)}})),K=Z.useRef(void 0),de=Z.useRef(Fo.NotStarted);ry(()=>{queueMicrotask(()=>{var F;const se=de.current===Fo.Started;de.current=Fo.Started,r(se?"rehydrating...":"initializing...");const C=(F=K.current)!=null?F:M.initial;M.invoke(C,se?M.get():Uf)});const fe=h.current,Q=M.ref.current;return()=>{r("unmounting..."),K.current=Q,de.current=Fo.Stopped,fe.forEach(se=>se==null?void 0:se()),h.current=new Map,p.current=null,queueMicrotask(()=>{A(e.exit)})}},[]);const xe=()=>"ref"in M?M.ref.current:M.get(),D=fe=>{queueMicrotask(()=>{var k,pe,Se,Ae,Be;if(de.current!==Fo.Started)return;E.current=T.current,T.current=fe;let Q=xe();const se=(Se=(k=e.states[Q].on)==null?void 0:k[fe.type])!=null?Se:(pe=e.on)==null?void 0:pe[fe.type],C=z(se);if(!C)return;p.current=C;const F=(Ae=C.target)!=null?Ae:Q;r("transition",fe.type,C.target||Q,`(${C.actions})`);const te=F!==Q;te?Is.flushSync(()=>M.set(F)):C.reenter&&!te?M.invoke(Q,Q):A((Be=C.actions)!=null?Be:[])})};return(Ie=e.watch)==null||Ie.call(e,S()),{state:x(),send:D,context:d,prop:a,scope:n,refs:_,computed:W,event:y(),getStatus:()=>de.current}}function iy(e){const t=Z.useRef(e);return t.current=e,t}function o4(e){const t=iy(e);return function(r){return t.current[r]}}function oy(e){queueMicrotask(()=>{Is.flushSync(()=>e())})}var Hf=n4(e=>e);function al(...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 s4(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 zf=e=>{const t=Z.memo(Z.forwardRef((n,r)=>{const h=n,{asChild:o,children:a}=h,u=sn(h,["asChild","children"]);if(!o)return Z.createElement(e,ae(H({},u),{ref:r}),a);if(!Z.isValidElement(a))return null;const c=Z.Children.only(a),d=s4(c);return Z.cloneElement(c,ae(H({},It(u,c.props)),{ref:r?al(r,d):d}))}));return t.displayName=e.displayName||e.name,t},Qt=(()=>{const e=new Map;return new Proxy(zf,{apply(t,n,r){return zf(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,zf(r)),e.get(r)}})})();function a4(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Hi(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:a,defaultValue:u}=e,c=Z.createContext(u);c.displayName=t;function d(){var p;const h=Z.useContext(c);if(!h&&n){const E=new Error(a!=null?a:a4(r,o));throw E.name="ContextError",(p=Error.captureStackTrace)==null||p.call(Error,E,d),E}return h}return[c.Provider,d,c]}const[u4,jf]=Hi({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[sy,sa]=Hi({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),ay=Z.forwardRef((e,t)=>{const n=jf(),r=sa(),o=It(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:v.jsx(Qt.div,ae(H({},o),{ref:al(r.ref,t)}))});ay.displayName="PopoverContent";const uy=Z.forwardRef((e,t)=>{const n=jf(),r=sa(),o=It(n.getPositionerProps(),e);return r.unmounted?null:v.jsx(Qt.div,ae(H({},o),{ref:t}))});uy.displayName="PopoverPositioner";const aa=()=>(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]},[{},H({},e)]),ly=e=>aa()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function l4(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 c4={props({props:e}){return ae(H({},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",Lo(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"});Ot(()=>{var c,d;const u=ul(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})=>{Ot(()=>{e.set("prevAnimationName",ul(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 p,E,T;((T=(E=(p=d.composedPath)==null?void 0:p.call(d))==null?void 0:E[0])!=null?T:d.target)===o&&e.set("prevAnimationName",ul(t.get("styles")))},u=d=>{const h=ul(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=il(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",a),o.removeEventListener("animationcancel",u),o.removeEventListener("animationend",u),ty(()=>c())}}}}};function ul(e){return(e==null?void 0:e.animationName)||"none"}Bo()(["onExitComplete","present","immediate"]);function d4(e,t={}){const{sync:n=!1}=t,r=f4(e);return Z.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 f4(e){const t=Z.useRef(e);return t.current=e,t}const $f=(e={})=>{const T=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=T,a=sn(T,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),u=Z.useRef(!1),c=ae(H({},a),{present:r,onExitComplete:d4(e.onExitComplete)}),d=sl(c4,c),h=l4(d);h.present&&(u.current=!0);const p=!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:p}};var zi=(e,t=[])=>({parts:(...n)=>{if(h4(t))return zi(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>zi(e,[...t,...n]),omit:(...n)=>zi(e,t.filter(r=>!n.includes(r))),rename:n=>zi(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Uo(e)}"][data-part="${Uo(r)}"]`,`& [data-scope="${Uo(e)}"][data-part="${Uo(r)}"]`].join(", "),attrs:{"data-scope":Uo(e),"data-part":Uo(r)}}}),{})}),Uo=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),h4=e=>e.length===0;const p4=["top","right","bottom","left"],Xr=Math.min,_n=Math.max,ll=Math.round,cl=Math.floor,hr=e=>({x:e,y:e}),m4={left:"right",right:"left",bottom:"top",top:"bottom"},g4={start:"end",end:"start"};function Vf(e,t,n){return _n(e,Xr(t,n))}function Cr(e,t){return typeof e=="function"?e(t):e}function kr(e){return e.split("-")[0]}function Ho(e){return e.split("-")[1]}function qf(e){return e==="x"?"y":"x"}function Yf(e){return e==="y"?"height":"width"}const E4=new Set(["top","bottom"]);function pr(e){return E4.has(kr(e))?"y":"x"}function Wf(e){return qf(pr(e))}function y4(e,t,n){n===void 0&&(n=!1);const r=Ho(e),o=Wf(e),a=Yf(o);let u=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(u=dl(u)),[u,dl(u)]}function b4(e){const t=dl(e);return[Gf(e),t,Gf(t)]}function Gf(e){return e.replace(/start|end/g,t=>g4[t])}const cy=["left","right"],dy=["right","left"],T4=["top","bottom"],x4=["bottom","top"];function w4(e,t,n){switch(e){case"top":case"bottom":return n?t?dy:cy:t?cy:dy;case"left":case"right":return t?T4:x4;default:return[]}}function _4(e,t,n,r){const o=Ho(e);let a=w4(kr(e),n==="start",r);return o&&(a=a.map(u=>u+"-"+o),t&&(a=a.concat(a.map(Gf)))),a}function dl(e){return e.replace(/left|right|bottom|top/g,t=>m4[t])}function v4(e){return H({top:0,right:0,bottom:0,left:0},e)}function fy(e){return typeof e!="number"?v4(e):{top:e,right:e,bottom:e,left:e}}function fl(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 hy(e,t,n){let{reference:r,floating:o}=e;const a=pr(t),u=Wf(t),c=Yf(u),d=kr(t),h=a==="y",p=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 y;switch(d){case"top":y={x:p,y:r.y-o.height};break;case"bottom":y={x:p,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:E};break;case"left":y={x:r.x-o.width,y:E};break;default:y={x:r.x,y:r.y}}switch(Ho(t)){case"start":y[u]-=T*(n&&h?-1:1);break;case"end":y[u]+=T*(n&&h?-1:1);break}return y}const S4=(e,t,n)=>$e(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:p,y:E}=hy(h,r,d),T=r,y={},x=0;for(let _=0;_<c.length;_++){const{name:S,fn:A}=c[_],{x:O,y:R,data:z,reset:W}=yield A({x:p,y:E,initialPlacement:r,placement:T,strategy:o,middlewareData:y,rects:h,platform:u,elements:{reference:e,floating:t}});p=O!=null?O:p,E=R!=null?R:E,y=ae(H({},y),{[S]:H(H({},y[S]),z)}),W&&x<=50&&(x++,typeof W=="object"&&(W.placement&&(T=W.placement),W.rects&&(h=W.rects===!0?yield u.getElementRects({reference:e,floating:t,strategy:o}):W.rects),{x:p,y:E}=hy(h,T,d)),_=-1)}return{x:p,y:E,placement:T,strategy:o,middlewareData:y}});function ua(e,t){return $e(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:p="viewport",elementContext:E="floating",altBoundary:T=!1,padding:y=0}=Cr(t,e),x=fy(y),S=c[T?E==="floating"?"reference":"floating":E],A=fl(yield a.getClippingRect({element:(n=yield a.isElement==null?void 0:a.isElement(S))==null||n?S:S.contextElement||(yield a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:h,rootBoundary:p,strategy:d})),O=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),z=(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},W=fl(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:O,offsetParent:R,strategy:d}):O);return{top:(A.top-W.top+x.top)/z.y,bottom:(W.bottom-A.bottom+x.bottom)/z.y,left:(A.left-W.left+x.left)/z.x,right:(W.right-A.right+x.right)/z.x}})}const A4=e=>({name:"arrow",options:e,fn(n){return $e(this,null,function*(){const{x:r,y:o,placement:a,rects:u,platform:c,elements:d,middlewareData:h}=n,{element:p,padding:E=0}=Cr(e,n)||{};if(p==null)return{};const T=fy(E),y={x:r,y:o},x=Wf(a),_=Yf(x),S=yield c.getDimensions(p),A=x==="y",O=A?"top":"left",R=A?"bottom":"right",z=A?"clientHeight":"clientWidth",W=u.reference[_]+u.reference[x]-y[x]-u.floating[_],M=y[x]-u.reference[x],K=yield c.getOffsetParent==null?void 0:c.getOffsetParent(p);let de=K?K[z]:0;(!de||!(yield c.isElement==null?void 0:c.isElement(K)))&&(de=d.floating[z]||u.floating[_]);const xe=W/2-M/2,D=de/2-S[_]/2-1,ne=Xr(T[O],D),J=Xr(T[R],D),re=ne,oe=de-S[_]-J,be=de/2-S[_]/2+xe,Ie=Vf(re,be,oe),fe=!h.arrow&&Ho(a)!=null&&be!==Ie&&u.reference[_]/2-(be<re?ne:J)-S[_]/2<0,Q=fe?be<re?be-re:be-oe:0;return{[x]:y[x]+Q,data:H({[x]:Ie,centerOffset:be-Ie-Q},fe&&{alignmentOffset:Q}),reset:fe}})}}),C4=function(e){return e===void 0&&(e={}),{name:"flip",options:e,fn(n){return $e(this,null,function*(){var r,o;const{placement:a,middlewareData:u,rects:c,initialPlacement:d,platform:h,elements:p}=n,be=Cr(e,n),{mainAxis:E=!0,crossAxis:T=!0,fallbackPlacements:y,fallbackStrategy:x="bestFit",fallbackAxisSideDirection:_="none",flipAlignment:S=!0}=be,A=sn(be,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=u.arrow)!=null&&r.alignmentOffset)return{};const O=kr(a),R=pr(d),z=kr(d)===d,W=yield h.isRTL==null?void 0:h.isRTL(p.floating),M=y||(z||!S?[dl(d)]:b4(d)),K=_!=="none";!y&&K&&M.push(..._4(d,S,_,W));const de=[d,...M],xe=yield ua(n,A),D=[];let ne=((o=u.flip)==null?void 0:o.overflows)||[];if(E&&D.push(xe[O]),T){const Ie=y4(a,c,W);D.push(xe[Ie[0]],xe[Ie[1]])}if(ne=[...ne,{placement:a,overflows:D}],!D.every(Ie=>Ie<=0)){var J,re;const Ie=(((J=u.flip)==null?void 0:J.index)||0)+1,fe=de[Ie];if(fe&&(!(T==="alignment"?R!==pr(fe):!1)||ne.every(C=>pr(C.placement)===R?C.overflows[0]>0:!0)))return{data:{index:Ie,overflows:ne},reset:{placement:fe}};let Q=(re=ne.filter(se=>se.overflows[0]<=0).sort((se,C)=>se.overflows[1]-C.overflows[1])[0])==null?void 0:re.placement;if(!Q)switch(x){case"bestFit":{var oe;const se=(oe=ne.filter(C=>{if(K){const F=pr(C.placement);return F===R||F==="y"}return!0}).map(C=>[C.placement,C.overflows.filter(F=>F>0).reduce((F,te)=>F+te,0)]).sort((C,F)=>C[1]-F[1])[0])==null?void 0:oe[0];se&&(Q=se);break}case"initialPlacement":Q=d;break}if(a!==Q)return{reset:{placement:Q}}}return{}})}}};function py(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function my(e){return p4.some(t=>e[t]>=0)}const k4=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return $e(this,null,function*(){const{rects:r}=n,u=Cr(e,n),{strategy:o="referenceHidden"}=u,a=sn(u,["strategy"]);switch(o){case"referenceHidden":{const c=yield ua(n,ae(H({},a),{elementContext:"reference"})),d=py(c,r.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:my(d)}}}case"escaped":{const c=yield ua(n,ae(H({},a),{altBoundary:!0})),d=py(c,r.floating);return{data:{escapedOffsets:d,escaped:my(d)}}}default:return{}}})}}},gy=new Set(["left","top"]);function N4(e,t){return $e(this,null,function*(){const{placement:n,platform:r,elements:o}=e,a=yield r.isRTL==null?void 0:r.isRTL(o.floating),u=kr(n),c=Ho(n),d=pr(n)==="y",h=gy.has(u)?-1:1,p=a&&d?-1:1,E=Cr(t,e);let{mainAxis:T,crossAxis:y,alignmentAxis:x}=typeof E=="number"?{mainAxis:E,crossAxis:0,alignmentAxis:null}:{mainAxis:E.mainAxis||0,crossAxis:E.crossAxis||0,alignmentAxis:E.alignmentAxis};return c&&typeof x=="number"&&(y=c==="end"?x*-1:x),d?{x:y*p,y:T*h}:{x:T*h,y:y*p}})}const O4=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(n){return $e(this,null,function*(){var r,o;const{x:a,y:u,placement:c,middlewareData:d}=n,h=yield N4(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:ae(H({},h),{placement:c})}})}}},I4=function(e){return e===void 0&&(e={}),{name:"shift",options:e,fn(n){return $e(this,null,function*(){const{x:r,y:o,placement:a}=n,A=Cr(e,n),{mainAxis:u=!0,crossAxis:c=!1,limiter:d={fn:O=>{let{x:R,y:z}=O;return{x:R,y:z}}}}=A,h=sn(A,["mainAxis","crossAxis","limiter"]),p={x:r,y:o},E=yield ua(n,h),T=pr(kr(a)),y=qf(T);let x=p[y],_=p[T];if(u){const O=y==="y"?"top":"left",R=y==="y"?"bottom":"right",z=x+E[O],W=x-E[R];x=Vf(z,x,W)}if(c){const O=T==="y"?"top":"left",R=T==="y"?"bottom":"right",z=_+E[O],W=_-E[R];_=Vf(z,_,W)}const S=d.fn(ae(H({},n),{[y]:x,[T]:_}));return ae(H({},S),{data:{x:S.x-r,y:S.y-o,enabled:{[y]:u,[T]:c}}})})}}},R4=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}=Cr(e,t),p={x:n,y:r},E=pr(o),T=qf(E);let y=p[T],x=p[E];const _=Cr(c,t),S=typeof _=="number"?{mainAxis:_,crossAxis:0}:H({mainAxis:0,crossAxis:0},_);if(d){const R=T==="y"?"height":"width",z=a.reference[T]-a.floating[R]+S.mainAxis,W=a.reference[T]+a.reference[R]-S.mainAxis;y<z?y=z:y>W&&(y=W)}if(h){var A,O;const R=T==="y"?"width":"height",z=gy.has(kr(o)),W=a.reference[E]-a.floating[R]+(z&&((A=u.offset)==null?void 0:A[E])||0)+(z?0:S.crossAxis),M=a.reference[E]+a.reference[R]+(z?0:((O=u.offset)==null?void 0:O[E])||0)-(z?S.crossAxis:0);x<W?x=W:x>M&&(x=M)}return{[T]:y,[E]:x}}}},P4=function(e){return e===void 0&&(e={}),{name:"size",options:e,fn(n){return $e(this,null,function*(){var r,o;const{placement:a,rects:u,platform:c,elements:d}=n,ne=Cr(e,n),{apply:h=()=>{}}=ne,p=sn(ne,["apply"]),E=yield ua(n,p),T=kr(a),y=Ho(a),x=pr(a)==="y",{width:_,height:S}=u.floating;let A,O;T==="top"||T==="bottom"?(A=T,O=y===((yield c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(O=T,A=y==="end"?"top":"bottom");const R=S-E.top-E.bottom,z=_-E.left-E.right,W=Xr(S-E[A],R),M=Xr(_-E[O],z),K=!n.middlewareData.shift;let de=W,xe=M;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(xe=z),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(de=R),K&&!y){const J=_n(E.left,0),re=_n(E.right,0),oe=_n(E.top,0),be=_n(E.bottom,0);x?xe=_-2*(J!==0||re!==0?J+re:_n(E.left,E.right)):de=S-2*(oe!==0||be!==0?oe+be:_n(E.top,E.bottom))}yield h(ae(H({},n),{availableWidth:xe,availableHeight:de}));const D=yield c.getDimensions(d.floating);return _!==D.width||S!==D.height?{reset:{rects:!0}}:{}})}}};function hl(){return typeof window!="undefined"}function zo(e){return Ey(e)?(e.nodeName||"").toLowerCase():"#document"}function vn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function mr(e){var t;return(t=(Ey(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ey(e){return hl()?e instanceof Node||e instanceof vn(e).Node:!1}function Kn(e){return hl()?e instanceof Element||e instanceof vn(e).Element:!1}function gr(e){return hl()?e instanceof HTMLElement||e instanceof vn(e).HTMLElement:!1}function yy(e){return!hl()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof vn(e).ShadowRoot}const L4=new Set(["inline","contents"]);function la(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!L4.has(o)}const D4=new Set(["table","td","th"]);function M4(e){return D4.has(zo(e))}const F4=[":popover-open",":modal"];function pl(e){return F4.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const B4=["transform","translate","scale","rotate","perspective"],U4=["transform","translate","scale","rotate","perspective","filter"],H4=["paint","layout","strict","content"];function Kf(e){const t=Qf(),n=Kn(e)?Qn(e):e;return B4.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)||U4.some(r=>(n.willChange||"").includes(r))||H4.some(r=>(n.contain||"").includes(r))}function z4(e){let t=Jr(e);for(;gr(t)&&!jo(t);){if(Kf(t))return t;if(pl(t))return null;t=Jr(t)}return null}function Qf(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const j4=new Set(["html","body","#document"]);function jo(e){return j4.has(zo(e))}function Qn(e){return vn(e).getComputedStyle(e)}function ml(e){return Kn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Jr(e){if(zo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||yy(e)&&e.host||mr(e);return yy(t)?t.host:t}function by(e){const t=Jr(e);return jo(t)?e.ownerDocument?e.ownerDocument.body:e.body:gr(t)&&la(t)?t:by(t)}function ca(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=by(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),u=vn(o);if(a){const c=Xf(u);return t.concat(u,u.visualViewport||[],la(o)?o:[],c&&n?ca(c):[])}return t.concat(o,ca(o,[],n))}function Xf(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ty(e){const t=Qn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=gr(e),a=o?e.offsetWidth:n,u=o?e.offsetHeight:r,c=ll(n)!==a||ll(r)!==u;return c&&(n=a,r=u),{width:n,height:r,$:c}}function Jf(e){return Kn(e)?e:e.contextElement}function $o(e){const t=Jf(e);if(!gr(t))return hr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=Ty(t);let u=(a?ll(n.width):n.width)/r,c=(a?ll(n.height):n.height)/o;return(!u||!Number.isFinite(u))&&(u=1),(!c||!Number.isFinite(c))&&(c=1),{x:u,y:c}}const $4=hr(0);function xy(e){const t=vn(e);return!Qf()||!t.visualViewport?$4:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function V4(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==vn(e)?!1:t}function ji(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=Jf(e);let u=hr(1);t&&(r?Kn(r)&&(u=$o(r)):u=$o(e));const c=V4(a,n,r)?xy(a):hr(0);let d=(o.left+c.x)/u.x,h=(o.top+c.y)/u.y,p=o.width/u.x,E=o.height/u.y;if(a){const T=vn(a),y=r&&Kn(r)?vn(r):r;let x=T,_=Xf(x);for(;_&&r&&y!==x;){const S=$o(_),A=_.getBoundingClientRect(),O=Qn(_),R=A.left+(_.clientLeft+parseFloat(O.paddingLeft))*S.x,z=A.top+(_.clientTop+parseFloat(O.paddingTop))*S.y;d*=S.x,h*=S.y,p*=S.x,E*=S.y,d+=R,h+=z,x=vn(_),_=Xf(x)}}return fl({width:p,height:E,x:d,y:h})}function gl(e,t){const n=ml(e).scrollLeft;return t?t.left+n:ji(mr(e)).left+n}function wy(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-gl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function q4(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",u=mr(r),c=t?pl(t.floating):!1;if(r===u||c&&a)return n;let d={scrollLeft:0,scrollTop:0},h=hr(1);const p=hr(0),E=gr(r);if((E||!E&&!a)&&((zo(r)!=="body"||la(u))&&(d=ml(r)),gr(r))){const y=ji(r);h=$o(r),p.x=y.x+r.clientLeft,p.y=y.y+r.clientTop}const T=u&&!E&&!a?wy(u,d):hr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+p.x+T.x,y:n.y*h.y-d.scrollTop*h.y+p.y+T.y}}function Y4(e){return Array.from(e.getClientRects())}function W4(e){const t=mr(e),n=ml(e),r=e.ownerDocument.body,o=_n(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=_n(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let u=-n.scrollLeft+gl(e);const c=-n.scrollTop;return Qn(r).direction==="rtl"&&(u+=_n(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:u,y:c}}const _y=25;function G4(e,t){const n=vn(e),r=mr(e),o=n.visualViewport;let a=r.clientWidth,u=r.clientHeight,c=0,d=0;if(o){a=o.width,u=o.height;const p=Qf();(!p||p&&t==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const h=gl(r);if(h<=0){const p=r.ownerDocument,E=p.body,T=getComputedStyle(E),y=p.compatMode==="CSS1Compat"&&parseFloat(T.marginLeft)+parseFloat(T.marginRight)||0,x=Math.abs(r.clientWidth-E.clientWidth-y);x<=_y&&(a-=x)}else h<=_y&&(a+=h);return{width:a,height:u,x:c,y:d}}const K4=new Set(["absolute","fixed"]);function Q4(e,t){const n=ji(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=gr(e)?$o(e):hr(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 vy(e,t,n){let r;if(t==="viewport")r=G4(e,n);else if(t==="document")r=W4(mr(e));else if(Kn(t))r=Q4(t,n);else{const o=xy(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return fl(r)}function Sy(e,t){const n=Jr(e);return n===t||!Kn(n)||jo(n)?!1:Qn(n).position==="fixed"||Sy(n,t)}function X4(e,t){const n=t.get(e);if(n)return n;let r=ca(e,[],!1).filter(c=>Kn(c)&&zo(c)!=="body"),o=null;const a=Qn(e).position==="fixed";let u=a?Jr(e):e;for(;Kn(u)&&!jo(u);){const c=Qn(u),d=Kf(u);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&K4.has(o.position)||la(u)&&!d&&Sy(e,u))?r=r.filter(p=>p!==u):o=c,u=Jr(u)}return t.set(e,r),r}function J4(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const u=[...n==="clippingAncestors"?pl(t)?[]:X4(t,this._c):[].concat(n),r],c=u[0],d=u.reduce((h,p)=>{const E=vy(t,p,o);return h.top=_n(E.top,h.top),h.right=Xr(E.right,h.right),h.bottom=Xr(E.bottom,h.bottom),h.left=_n(E.left,h.left),h},vy(t,c,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function Z4(e){const{width:t,height:n}=Ty(e);return{width:t,height:n}}function e6(e,t,n){const r=gr(t),o=mr(t),a=n==="fixed",u=ji(e,!0,a,t);let c={scrollLeft:0,scrollTop:0};const d=hr(0);function h(){d.x=gl(o)}if(r||!r&&!a)if((zo(t)!=="body"||la(o))&&(c=ml(t)),r){const y=ji(t,!0,a,t);d.x=y.x+t.clientLeft,d.y=y.y+t.clientTop}else o&&h();a&&!r&&o&&h();const p=o&&!r&&!a?wy(o,c):hr(0),E=u.left+c.scrollLeft-d.x-p.x,T=u.top+c.scrollTop-d.y-p.y;return{x:E,y:T,width:u.width,height:u.height}}function Zf(e){return Qn(e).position==="static"}function Ay(e,t){if(!gr(e)||Qn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return mr(e)===n&&(n=n.ownerDocument.body),n}function Cy(e,t){const n=vn(e);if(pl(e))return n;if(!gr(e)){let o=Jr(e);for(;o&&!jo(o);){if(Kn(o)&&!Zf(o))return o;o=Jr(o)}return n}let r=Ay(e,t);for(;r&&M4(r)&&Zf(r);)r=Ay(r,t);return r&&jo(r)&&Zf(r)&&!Kf(r)?n:r||z4(e)||n}const t6=function(e){return $e(this,null,function*(){const t=this.getOffsetParent||Cy,n=this.getDimensions,r=yield n(e.floating);return{reference:e6(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function n6(e){return Qn(e).direction==="rtl"}const r6={convertOffsetParentRelativeRectToViewportRelativeRect:q4,getDocumentElement:mr,getClippingRect:J4,getOffsetParent:Cy,getElementRects:t6,getClientRects:Y4,getDimensions:Z4,getScale:$o,isElement:Kn,isRTL:n6};function ky(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function i6(e,t){let n=null,r;const o=mr(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:p,top:E,width:T,height:y}=h;if(c||t(),!T||!y)return;const x=cl(E),_=cl(o.clientWidth-(p+T)),S=cl(o.clientHeight-(E+y)),A=cl(p),R={rootMargin:-x+"px "+-_+"px "+-S+"px "+-A+"px",threshold:_n(0,Xr(1,d))||1};let z=!0;function W(M){const K=M[0].intersectionRatio;if(K!==d){if(!z)return u();K?u(!1,K):r=setTimeout(()=>{u(!1,1e-7)},1e3)}K===1&&!ky(h,e.getBoundingClientRect())&&u(),z=!1}try{n=new IntersectionObserver(W,ae(H({},R),{root:o.ownerDocument}))}catch(M){n=new IntersectionObserver(W,R)}n.observe(e)}return u(!0),a}function o6(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),p=o||a?[...h?ca(h):[],...ca(t)]:[];p.forEach(A=>{o&&A.addEventListener("scroll",n,{passive:!0}),a&&A.addEventListener("resize",n)});const E=h&&c?i6(h,n):null;let T=-1,y=null;u&&(y=new ResizeObserver(A=>{let[O]=A;O&&O.target===h&&y&&(y.unobserve(t),cancelAnimationFrame(T),T=requestAnimationFrame(()=>{var R;(R=y)==null||R.observe(t)})),n()}),h&&!d&&y.observe(h),y.observe(t));let x,_=d?ji(e):null;d&&S();function S(){const A=ji(e);_&&!ky(_,A)&&n(),_=A,x=requestAnimationFrame(S)}return n(),()=>{var A;p.forEach(O=>{o&&O.removeEventListener("scroll",n),a&&O.removeEventListener("resize",n)}),E==null||E(),(A=y)==null||A.disconnect(),y=null,d&&cancelAnimationFrame(x)}}const s6=O4,a6=I4,u6=C4,l6=P4,c6=k4,d6=A4,f6=R4,h6=(e,t,n)=>{const r=new Map,o=H({platform:r6},n),a=ae(H({},o.platform),{_c:r});return S4(e,t,ae(H({},o),{platform:a}))};function Ny(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 ae(H({},o),{toJSON:()=>o})}function p6(e){if(!e)return Ny();const{x:t,y:n,width:r,height:o}=e;return Ny(t,n,r,o)}function m6(e,t){return{contextElement:Ft(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?p6(r):n.getBoundingClientRect()}}}var da=e=>({variable:e,reference:`var(${e})`}),Nr={arrowSize:da("--arrow-size"),arrowSizeHalf:da("--arrow-size-half"),arrowBg:da("--arrow-background"),transformOrigin:da("--transform-origin"),arrowOffset:da("--arrow-offset")},g6=e=>e==="top"||e==="bottom"?"y":"x";function E6(e,t){return{name:"transformOrigin",fn(n){var xe,D,ne,J,re;const{elements:r,middlewareData:o,placement:a,rects:u,y:c}=n,d=a.split("-")[0],h=g6(d),p=((xe=o.arrow)==null?void 0:xe.x)||0,E=((D=o.arrow)==null?void 0:D.y)||0,T=(t==null?void 0:t.clientWidth)||0,y=(t==null?void 0:t.clientHeight)||0,x=p+T/2,_=E+y/2,S=Math.abs(((ne=o.shift)==null?void 0:ne.y)||0),A=u.reference.height/2,O=y/2,R=(re=(J=e.offset)==null?void 0:J.mainAxis)!=null?re:e.gutter,z=typeof R=="number"?R+O:R!=null?R:O,W=S>z,M={top:`${x}px calc(100% + ${z}px)`,bottom:`${x}px ${-z}px`,left:`calc(100% + ${z}px) ${_}px`,right:`${-z}px ${_}px`}[d],K=`${x}px ${u.reference.y+A-c}px`,de=!!e.overlap&&h==="y"&&W;return r.floating.style.setProperty(Nr.transformOrigin.variable,de?K:M),{data:{transformOrigin:de?K:M}}}}}var y6={name:"rects",fn({rects:e}){return{data:e}}},b6=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% + ${Nr.arrowOffset.reference})`}),{}}}};function T6(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var x6={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 eh(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function w6(e,t,n){const r=e||t.createElement("div");return d6({element:r,padding:n.arrowPadding})}function _6(e,t){var n;if(!BR((n=t.offset)!=null?n:t.gutter))return s6(({placement:r})=>{var p,E,T,y;const o=((e==null?void 0:e.clientHeight)||0)/2,a=(E=(p=t.offset)==null?void 0:p.mainAxis)!=null?E:t.gutter,u=typeof a=="number"?a+o:a!=null?a:o,{hasAlign:c}=T6(r),d=c?void 0:t.shift,h=(y=(T=t.offset)==null?void 0:T.crossAxis)!=null?y:d;return kf({crossAxis:h,mainAxis:u,alignmentAxis:t.shift})})}function v6(e){if(!e.flip)return;const t=eh(e.boundary);return u6(ae(H({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function S6(e){if(!e.slide&&!e.overlap)return;const t=eh(e.boundary);return a6(ae(H({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:f6()}))}function A6(e){return l6({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 C6(e){var t;if(e.hideWhenDetached)return c6({strategy:"referenceHidden",boundary:(t=eh(e.boundary))!=null?t:"clippingAncestors"})}function k6(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function N6(e,t,n={}){const r=m6(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},x6,n),a=t.querySelector("[data-part=arrow]"),u=[_6(a,o),v6(o),S6(o),w6(a,t.ownerDocument,o),b6(a),E6({gutter:o.gutter,offset:o.offset,overlap:o.overlap},a),A6(o),C6(o),y6],{placement:c,strategy:d,onComplete:h,onPositioned:p}=o,E=()=>$e(null,null,function*(){var z;if(!r||!t)return;const _=yield h6(r,t,{placement:c,middleware:u,strategy:d});h==null||h(_),p==null||p({placed:!0});const S=Ro(t),A=Oy(S,_.x),O=Oy(S,_.y);t.style.setProperty("--x",`${A}px`),t.style.setProperty("--y",`${O}px`),o.hideWhenDetached&&(((z=_.middlewareData.hide)==null?void 0:z.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 W=Lo(R);t.style.setProperty("--z-index",W.zIndex)}}),T=()=>$e(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),p==null||p({placed:!0})):yield E()}),y=k6(o.listeners),x=o.listeners?o6(r,t,T,y):WR;return T(),()=>{x==null||x(),p==null||p({placed:!1})}}function Iy(e,t,n={}){const c=n,{defer:r}=c,o=sn(c,["defer"]),a=r?Ot:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof t=="function"?t():t;u.push(N6(d,h,o))})),()=>{u.forEach(d=>d==null?void 0:d())}}var O6={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function I6(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:Nr.arrowSize.reference,height:Nr.arrowSize.reference,[Nr.arrowSizeHalf.variable]:`calc(${Nr.arrowSize.reference} / 2)`,[Nr.arrowOffset.variable]:`calc(${Nr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?O6[t.split("-")[0]]:void 0,background:Nr.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 Vo=new WeakMap,El=new WeakMap,yl={},th=0,Ry=e=>e&&(e.host||Ry(e.parentNode)),R6=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=Ry(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),P6=new Set(["script","output","status","next-route-announcer"]),L6=e=>P6.has(e.localName)||e.role==="status"||e.hasAttribute("aria-live")?!0:e.matches("[data-live-announcer]"),D6=(e,t)=>{const{parentNode:n,markerName:r,controlAttribute:o,followControlledElements:a=!0}=t,u=R6(n,Array.isArray(e)?e:[e]);yl[r]||(yl[r]=new WeakMap);const c=yl[r],d=[],h=new Set,p=new Set(u),E=y=>{!y||h.has(y)||(h.add(y),E(y.parentNode))};u.forEach(y=>{E(y),a&&Ft(y)&&qE(y,x=>{E(x)})});const T=y=>{!y||p.has(y)||Array.prototype.forEach.call(y.children,x=>{if(h.has(x))T(x);else try{if(L6(x))return;const S=x.getAttribute(o)==="true",A=(Vo.get(x)||0)+1,O=(c.get(x)||0)+1;Vo.set(x,A),c.set(x,O),d.push(x),A===1&&S&&El.set(x,!0),O===1&&x.setAttribute(r,""),S||x.setAttribute(o,"true")}catch(_){console.error("[zag-js > ariaHidden] cannot operate on ",x,_)}})};return T(n),h.clear(),th++,()=>{d.forEach(y=>{const x=Vo.get(y)-1,_=c.get(y)-1;Vo.set(y,x),c.set(y,_),x||(El.has(y)||y.removeAttribute(o),El.delete(y)),_||y.removeAttribute(r)}),th--,th||(Vo=new WeakMap,Vo=new WeakMap,El=new WeakMap,yl={})}},M6=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,F6=(e,t=M6(e),n="data-aria-hidden",r=!0)=>{if(t)return D6(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},B6=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function Py(e,t={}){const{defer:n=!0}=t,r=n?B6:a=>a(),o=[];return o.push(r(()=>{const u=(typeof e=="function"?e():e).filter(Boolean);u.length!==0&&o.push(F6(u))})),()=>{o.forEach(a=>a==null?void 0:a())}}function U6(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 H6(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",Dy="focus.outside";function z6(e){for(const t of e)if(Ft(t)&&fr(t))return!0;return!1}var My=e=>"clientY"in e;function j6(e,t){if(!My(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 $6(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||!My(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 $6(u,c)?r||a:!1}function V6(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:a,defer:u,followControlledElements:c=!0}=t;if(!e)return;const d=dr(e),h=Ro(e),p=U6(h),E=H6(h);function T(R,z){if(!Ft(z)||!z.isConnected||Io(e,z)||j6(e,R)||c&&VE(e,z))return!1;const W=d.querySelector(`[aria-controls="${e.id}"]`);if(W){const K=Ff(W);if(Fy(R,K))return!1}const M=Ff(e);return Fy(R,M)?!1:!(n!=null&&n(z))}const y=new Set,x=Bi(e==null?void 0:e.getRootNode());function _(R){function z(W){var xe,D;const M=u&&!YE()?Ot:ne=>ne(),K=W!=null?W:R,de=(D=(xe=K==null?void 0:K.composedPath)==null?void 0:xe.call(K))!=null?D:[K==null?void 0:K.target];M(()=>{const ne=x?de[0]:Gn(R);if(!(!e||!T(R,ne))){if(o||a){const J=Cf(o,a);e.addEventListener(Ly,J,{once:!0})}By(e,Ly,{bubbles:!1,cancelable:!0,detail:{originalEvent:K,contextmenu:kP(K),focusable:z6(de),target:ne}})}})}R.pointerType==="touch"?(y.forEach(W=>W()),y.add(Bt(d,"click",z,{once:!0})),y.add(E.addEventListener("click",z,{once:!0})),y.add(p.addEventListener("click",z,{once:!0}))):z()}const S=new Set,A=setTimeout(()=>{S.add(Bt(d,"pointerdown",_,!0)),S.add(E.addEventListener("pointerdown",_,!0)),S.add(p.addEventListener("pointerdown",_,!0))},0);function O(R){(u?Ot:W=>W())(()=>{var K,de;const W=(de=(K=R==null?void 0:R.composedPath)==null?void 0:K.call(R))!=null?de:[R==null?void 0:R.target],M=x?W[0]:Gn(R);if(!(!e||!T(R,M))){if(r||a){const xe=Cf(r,a);e.addEventListener(Dy,xe,{once:!0})}By(e,Dy,{bubbles:!1,cancelable:!0,detail:{originalEvent:R,contextmenu:!1,focusable:fr(M),target:M}})}})}return YE()||(S.add(Bt(d,"focusin",O,!0)),S.add(E.addEventListener("focusin",O,!0)),S.add(p.addEventListener("focusin",O,!0))),()=>{clearTimeout(A),y.forEach(R=>R()),S.forEach(R=>R())}}function q6(e,t){const{defer:n}=t,r=n?Ot:a=>a(),o=[];return o.push(r(()=>{const a=typeof e=="function"?e():e;o.push(V6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}function By(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function Y6(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return Bt(dr(e),"keydown",n,{capture:!0})}var Uy="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=>Io(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>Io(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];G6(e,Uy,o=>{var a;(a=r.requestDismiss)==null||a.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),W6(e,Uy,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function W6(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 G6(e,t,n){e.addEventListener(t,n,{once:!0})}var Hy;function zy(){Dn.layers.forEach(({node:e})=>{e.style.pointerEvents=Dn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function K6(e){e.style.pointerEvents=""}function Q6(e,t){const n=dr(e),r=[];return Dn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(Hy=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[a,u]=XP(()=>{const c=o();return Ft(c)?c:null},{timeout:1e3});a.then(c=>r.push(il(c,{pointerEvents:"auto"}))),r.push(u)}),()=>{Dn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=Hy,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function X6(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Nf("[@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),zy();function p(_){var A,O;const S=Gn(_.detail.originalEvent);Dn.isBelowPointerBlockingLayer(e)||Dn.isInBranch(S)||((A=t.onPointerDownOutside)==null||A.call(t,_),(O=t.onInteractOutside)==null||O.call(t,_),!_.defaultPrevented&&(c&&console.log("onPointerDownOutside:",_.detail.originalEvent),r==null||r()))}function E(_){var A,O;const S=Gn(_.detail.originalEvent);Dn.isInBranch(S)||((A=t.onFocusOutside)==null||A.call(t,_),(O=t.onInteractOutside)==null||O.call(t,_),!_.defaultPrevented&&(c&&console.log("onFocusOutside:",_.detail.originalEvent),r==null||r()))}function T(_){var S;Dn.isTopMost(e)&&((S=t.onEscapeKeyDown)==null||S.call(t,_),!_.defaultPrevented&&r&&(_.preventDefault(),r()))}function y(_){var R;if(!e)return!1;const S=typeof u=="function"?u():u,A=Array.isArray(S)?S:[S],O=(R=t.persistentElements)==null?void 0:R.map(z=>z()).filter(Ft);return O&&A.push(...O),A.some(z=>Io(z,_))||Dn.isInNestedLayer(e,_)}const x=[a?Q6(e,t.persistentElements):void 0,Y6(e,T),q6(e,{exclude:y,onFocusOutside:E,onPointerDownOutside:p,defer:t.defer})];return()=>{Dn.remove(e),zy(),K6(e),x.forEach(_=>_==null?void 0:_())}}function jy(e,t){const{defer:n}=t,r=n?Ot:a=>a(),o=[];return o.push(r(()=>{const a=No(e)?e():e;o.push(X6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}var J6=Object.defineProperty,Z6=(e,t,n)=>t in e?J6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ht=(e,t,n)=>Z6(e,typeof t!="symbol"?t+"":t,n),$y={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()}},eL=[],tL=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||el(o))a&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let u,c=!0;if(this.state.mostRecentlyFocusedNode)if(oa(this.state.mostRecentlyFocusedNode)>0){const d=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:h}=this.state.containerGroups[d];if(h.length>0){const p=h.findIndex(E=>E===this.state.mostRecentlyFocusedNode);p>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?p+1<h.length&&(u=h[p+1],c=!1):p-1>=0&&(u=h[p-1],c=!1))}}else this.state.containerGroups.some(d=>d.tabbableNodes.some(h=>oa(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(ha(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}ha(this.config.allowOutsideClick,r)||r.preventDefault()}}),ht(this,"handleClick",r=>{const o=Gn(r);this.findContainerIndex(o,r)>=0||ha(this.config.clickOutsideDeactivates,r)||ha(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;fa(r)&&r.preventDefault(),this.tryFocus(a)}}),ht(this,"handleEscapeKey",r=>{nL(r)&&ha(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 bP(h)?!0:h.id&&!this.state.containers.some(p=>p.contains(h))?TP(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&&!fr(r)){const o=Po(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!==Po(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,rL(r)&&r.select()}}),ht(this,"deactivate",r=>{if(!this.state.active)return this;const o=H({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(),$y.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=()=>{Vy(()=>{if(d){const p=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(p)}u==null||u()})};if(d&&c){const p=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);return c(p).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 p=this.state.tabbableGroups.findIndex(({firstTabbableNode:E})=>u===E);if(p<0&&((h==null?void 0:h.container)===u||fr(u)&&!Ui(u)&&!(h!=null&&h.nextTabbableNode(u,!1)))&&(p=d),p>=0){const E=p===0?this.state.tabbableGroups.length-1:p-1,T=this.state.tabbableGroups[E];c=oa(u)>=0?T.lastTabbableNode:T.lastDomTabbableNode}else fa(o)||(c=h==null?void 0:h.nextTabbableNode(u,!1))}else{let p=this.state.tabbableGroups.findIndex(({lastTabbableNode:E})=>u===E);if(p<0&&((h==null?void 0:h.container)===u||fr(u)&&!Ui(u)&&!(h!=null&&h.nextTabbableNode(u)))&&(p=d),p>=0){const E=p===this.state.tabbableGroups.length-1?0:p+1,T=this.state.tabbableGroups[E];c=oa(u)>=0?T.firstTabbableNode:T.firstDomTabbableNode}else fa(o)||(c=h==null?void 0:h.nextTabbableNode(u))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||eL;const n=H({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return fa(r)&&!r.shiftKey},isKeyBackward(r){return fa(r)&&r.shiftKey}},t);this.doc=n.document||dr(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=>{gP(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?VE(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Do(e,{getShadowRoot:this.config.getShadowRoot}),n=ZE(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(oa(t[h])>0){c=!0;break}function d(h,p=!0){const E=t.indexOf(h);if(E>=0)return t[E+(p?1:-1)];const T=n.indexOf(h);if(!(T<0)){if(p){for(let y=T+1;y<n.length;y++)if(Ui(n[y]))return n[y]}else for(let y=T-1;y>=0;y--)if(Ui(n[y]))return n[y]}}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 $y.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Vy(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(Bt(this.doc,"focusin",this.handleFocus,!0),Bt(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),Bt(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),Bt(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),Bt(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),Bt(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=Po(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)}},fa=e=>e.key==="Tab",ha=(e,...t)=>typeof e=="function"?e(...t):e,nL=e=>!e.isComposing&&e.key==="Escape",Vy=e=>setTimeout(e,0),rL=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function qy(e,t={}){let n;const r=Ot(()=>{const o=typeof e=="function"?e():e;if(o){n=new tL(o,ae(H({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:dr(o)}));try{n.activate()}catch(a){}}});return function(){n==null||n.deactivate(),r()}}var nh="data-scroll-lock";function iL(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function Yy(e){const t=Lo(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function Wy(e){var y;const t=e!=null?e:document,n=(y=t.defaultView)!=null?y:window,{documentElement:r,body:o}=t;if(o.hasAttribute(nh))return;const u=Yy(r)||Yy(o),c=n.innerWidth-r.clientWidth;o.setAttribute(nh,"");const d=()=>KP(r,"--scrollbar-width",`${c}px`),h=iL(r),p=()=>{const x={overflow:"hidden"};return!u&&c>0&&(x[h]=`${c}px`),il(o,x)},E=()=>{var W,M;const{scrollX:x,scrollY:_,visualViewport:S}=n,A=(W=S==null?void 0:S.offsetLeft)!=null?W:0,O=(M=S==null?void 0:S.offsetTop)!=null?M:0,R={position:"fixed",overflow:"hidden",top:`${-(_-Math.floor(O))}px`,left:`${-(x-Math.floor(A))}px`,right:"0"};!u&&c>0&&(R[h]=`${c}px`);const z=il(o,R);return()=>{z==null||z(),n.scrollTo({left:x,top:_,behavior:"instant"})}},T=[d(),tl()?E():p()];return()=>{T.forEach(x=>x==null?void 0:x()),o.removeAttribute(nh)}}var oL=zi("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),Er=oL.build(),Gy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},Ky=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},rh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},Qy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},sL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},ih=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},oh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},aL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},Xy=e=>e.getById(Gy(e)),qo=e=>e.getById(Ky(e)),Yo=e=>e.getById(rh(e)),Jy=e=>e.getById(Qy(e)),uL=e=>e.getById(ih(e)),lL=e=>e.getById(oh(e));function cL(e,t){const{state:n,context:r,send:o,computed:a,prop:u,scope:c}=e,d=n.matches("open"),h=r.get("currentPlacement"),p=a("currentPortalled"),E=r.get("renderedElements"),T=I6(ae(H({},u("positioning")),{placement:h}));return{portalled:p,open:d,setOpen(y){n.matches("open")!==y&&o({type:y?"OPEN":"CLOSE"})},reposition(y={}){o({type:"POSITIONING.SET",options:y})},getArrowProps(){return t.element(ae(H({id:sL(c)},Er.arrow.attrs),{dir:u("dir"),style:T.arrow}))},getArrowTipProps(){return t.element(ae(H({},Er.arrowTip.attrs),{dir:u("dir"),style:T.arrowTip}))},getAnchorProps(){return t.element(ae(H({},Er.anchor.attrs),{dir:u("dir"),id:Gy(c)}))},getTriggerProps(){return t.button(ae(H({},Er.trigger.attrs),{dir:u("dir"),type:"button","data-placement":h,id:Ky(c),"aria-haspopup":"dialog","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":rh(c),onPointerDown(y){WE(y)&&AP()&&y.currentTarget.focus()},onClick(y){y.defaultPrevented||o({type:"TOGGLE"})},onBlur(y){o({type:"TRIGGER_BLUR",target:y.relatedTarget})}}))},getIndicatorProps(){return t.element(ae(H({},Er.indicator.attrs),{dir:u("dir"),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ae(H({id:Qy(c)},Er.positioner.attrs),{dir:u("dir"),style:T.floating}))},getContentProps(){return t.element(ae(H({},Er.content.attrs),{dir:u("dir"),id:rh(c),tabIndex:-1,role:"dialog","aria-modal":zE(u("modal")),hidden:!d,"data-state":d?"open":"closed","data-expanded":Oo(d),"aria-labelledby":E.title?ih(c):void 0,"aria-describedby":E.description?oh(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(ae(H({},Er.title.attrs),{id:ih(c),dir:u("dir")}))},getDescriptionProps(){return t.element(ae(H({},Er.description.attrs),{id:oh(c),dir:u("dir")}))},getCloseTriggerProps(){return t.button(ae(H({},Er.closeTrigger.attrs),{dir:u("dir"),id:aL(c),type:"button","aria-label":"close",onClick(y){y.defaultPrevented||(y.stopPropagation(),o({type:"CLOSE"}))}}))}}}var dL={props({props:e}){return ae(H({closeOnInteractOutside:!0,closeOnEscape:!0,autoFocus:!0,modal:!1,portalled:!0},e),{positioning:H({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=Xy(n))!=null?a:qo(n);return Iy(r,()=>Jy(n),ae(H({},t("positioning")),{defer:!0,onComplete(u){e.set("currentPlacement",u.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Yo(n);let o=!0;return jy(r,{type:"popover",pointerBlocking:t("modal"),exclude:qo(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:WP(()=>Yo(t),{triggerElement:qo(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?Py(()=>[Yo(t),qo(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return Wy(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?qy(()=>Yo(t),{initialFocus:()=>ey({root:Yo(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=Xy(n))!=null?u:qo(n);Iy(o,()=>Jy(n),ae(H(H({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){Ot(()=>{Object.assign(e.get("renderedElements"),{title:!!uL(t),description:!!lL(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||Ot(()=>{const n=ey({root:Yo(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||Ot(()=>{const a=qo(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})}}}};Bo()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[_F,bl]=Hi({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[vF,sh]=Hi({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),fL=e=>{const t=Z.useId(),{getRootNode:n}=bl(),{dir:r}=sh(),o=H({id:t,dir:r,getRootNode:n},e),a=sl(dL,o);return cL(a,Hf)},hL=e=>{const[t,u]=ly(e),c=u,{children:n}=c,r=sn(c,["children"]),o=fL(r),a=$f(It({present:o.open},t));return v.jsx(u4,{value:o,children:v.jsx(sy,{value:a,children:n})})},Zy=Z.forwardRef((e,t)=>{const n=jf(),r=sa(),o=It(ae(H({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return v.jsx(Qt.button,ae(H({},o),{ref:t}))});Zy.displayName="PopoverTrigger";function pL(e){return mt({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 mL(e){return mt({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 eb(e){return mt({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 tb(e){return mt({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 nb(e){return mt({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 gL=({className:e,componentType:t,children:n})=>{const[r,o]=Z.useState(!1),{globalClassName:a}=At(),u=h=>{o(h.open)},c=Z.useCallback(()=>{o(!1)},[]),d=Z.useMemo(()=>({closeMenu:c}),[c]);return v.jsxs(hL,{open:r,onOpenChange:u,positioning:{placement:"bottom-end"},children:[v.jsx(Zy,{"aria-label":`Overflow menu for ${t}`,className:$(`${U}-overflow-menu-button-trigger`,`${U}-icon-button`,a,e,`cim-${t}-component`),children:v.jsx(nb,{})}),v.jsx(uy,{children:v.jsx(ay,{className:$(`${U}-overflow-menu-list`,a,`cim-${t}-component`),children:v.jsx(LE.Provider,{value:d,children:n})})})]})};function rb(e){return mt({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 ib(e){return mt({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[EL,$i]=Hi({name:"CarouselContext",hookName:"useCarouselContext",providerName:"<CarouselProvider />"}),ah=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getControlProps(),e);return v.jsx(Qt.div,ae(H(H({},r),e),{ref:t}))});ah.displayName="CarouselControl";const uh=Z.forwardRef((e,t)=>{const[n,r]=aa()(e,["readOnly","index"]),o=$i(),a=It(o.getIndicatorProps(n),r);return v.jsx(Qt.button,ae(H({},a),{ref:t}))});uh.displayName="CarouselIndicator";const lh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getIndicatorGroupProps(),e);return v.jsx(Qt.div,ae(H({},r),{ref:t}))});lh.displayName="CarouselIndicatorGroup";const ch=Z.forwardRef((e,t)=>{const[n,r]=aa()(e,["index","snapAlign"]),o=$i(),a=It(o.getItemProps(n),r);return v.jsx(Qt.div,ae(H({},a),{ref:t}))});ch.displayName="CarouselItem";const dh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getItemGroupProps(),e);return v.jsx(Qt.div,ae(H({},r),{ref:t}))});dh.displayName="CarouselItemGroup";const fh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getNextTriggerProps(),e);return v.jsx(Qt.button,ae(H({},r),{ref:t}))});fh.displayName="CarouselNextTrigger";const hh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getPrevTriggerProps(),e);return v.jsx(Qt.button,ae(H({},r),{ref:t}))});hh.displayName="CarouselPrevTrigger";function yL(e){const t=Lo(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,y){let x=parseFloat(T);return/%/.test(T)&&(x/=100,x*=y),Number.isNaN(x)?0:x}let d=c(r,n.width),h=c(o,n.height),p=c(a,n.width),E=c(u,n.height);return{x:{before:d,after:p},y:{before:h,after:E}}}function bL(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 ob(e){let t=[];for(const n of e.children)t=t.concat(n,ob(n));return t}function sb(e,t=!1){const n=e.getBoundingClientRect(),r={x:{start:[],center:[],end:[]},y:{start:[],center:[],end:[]}},o=t?ob(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 p of o){const E=p.getBoundingClientRect();if(!bL(n,E,u))continue;const T=Lo(p);let[y,x]=T.getPropertyValue("scroll-snap-align").split(" ");typeof x=="undefined"&&(x=y);const _=a==="x"?x:y,S=E[c]-n[c]+e[h];switch(_){case"none":break;case"start":r[a].start.push({node:p,position:S});break;case"center":r[a].center.push({node:p,position:S+E[d]/2});break;case"end":r[a].end.push({node:p,position:S+E[d]});break}}}return r}function ab(e){const t=e.getBoundingClientRect(),n=yL(e),r=sb(e),o={x:e.scrollWidth-e.offsetWidth,y:e.scrollHeight-e.offsetHeight};return{x:ub([...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(lb(0,o.x))),y:ub([...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(lb(0,o.y)))}}function TL(e,t,n){const r=sb(e),o=[...r[t].start,...r[t].center,...r[t].end];for(const a of o)if(n(a.node))return a.position}var ub=e=>[...new Set(e)],lb=(e,t)=>n=>Math.max(e,Math.min(t,n)),xL=zi("carousel").parts("root","itemGroup","item","control","nextTrigger","prevTrigger","indicatorGroup","indicator","autoplayTrigger"),Or=xL.build(),wL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.root)!=null?n:`carousel:${e.id}`},_L=(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}`},Tl=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.itemGroup)!=null?n:`carousel:${e.id}:item-group`},vL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.nextTrigger)!=null?n:`carousel:${e.id}:next-trigger`},SL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.prevTrigger)!=null?n:`carousel:${e.id}:prev-trigger`},AL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.indicatorGroup)!=null?n:`carousel:${e.id}:indicator-group`},cb=(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(Tl(e)),db=e=>GP(hn(e),"[data-part=item]"),CL=(e,t)=>e.getById(cb(e,t)),fb=e=>{const t=hn(e);if(!t)return;const n=Do(t);t.setAttribute("tabindex",n.length>0?"-1":"0")};function kL(e,t){const{state:n,context:r,computed:o,send:a,scope:u,prop:c}=e,d=n.matches("autoplay"),h=n.matches("dragging"),p=o("canScrollNext"),E=o("canScrollPrev"),T=o("isHorizontal"),y=Array.from(r.get("pageSnapPoints")),x=r.get("page"),_=c("slidesPerPage"),S=c("padding"),A=c("translations");return{isPlaying:d,isDragging:h,page:x,pageSnapPoints:y,canScrollNext:p,canScrollPrev:E,getProgress(){return x/y.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(ae(H({},Or.root.attrs),{id:wL(u),role:"region","aria-roledescription":"carousel","data-orientation":c("orientation"),dir:c("dir"),style:{"--slides-per-page":_,"--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(ae(H({},Or.itemGroup.attrs),{id:Tl(u),"data-orientation":c("orientation"),"data-dragging":Oo(h),dir:c("dir"),"aria-live":d?"off":"polite",onFocus(O){Io(O.currentTarget,Gn(O))&&a({type:"VIEWPORT.FOCUS"})},onBlur(O){Io(O.currentTarget,O.relatedTarget)||a({type:"VIEWPORT.BLUR"})},onMouseDown(O){if(O.defaultPrevented||!c("allowMouseDrag")||!WE(O))return;const R=Gn(O);fr(R)&&R!==O.currentTarget||(O.preventDefault(),a({type:"DRAGGING.START"}))},onWheel:GR(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"]:S,[T?"paddingInline":"paddingBlock"]:S,[T?"overflowX":"overflowY"]:"auto"}}))},getItemProps(O){const R=r.get("slidesInView").includes(O.index);return t.element(ae(H({},Or.item.attrs),{id:_L(u,O.index),dir:c("dir"),role:"group","data-index":O.index,"data-inview":Oo(R),"aria-roledescription":"slide","data-orientation":c("orientation"),"aria-label":A.item(O.index,c("slideCount")),"aria-hidden":zE(!R),style:{scrollSnapAlign:(()=>{var de;const z=(de=O.snapAlign)!=null?de:"start",W=c("slidesPerMove"),M=W==="auto"?Math.floor(c("slidesPerPage")):W;return(O.index+M)%M===0?z:void 0})()}}))},getControlProps(){return t.element(ae(H({},Or.control.attrs),{"data-orientation":c("orientation")}))},getPrevTriggerProps(){return t.button(ae(H({},Or.prevTrigger.attrs),{id:SL(u),type:"button",disabled:!E,dir:c("dir"),"aria-label":A.prevTrigger,"data-orientation":c("orientation"),"aria-controls":Tl(u),onClick(O){O.defaultPrevented||a({type:"PAGE.PREV",src:"trigger"})}}))},getNextTriggerProps(){return t.button(ae(H({},Or.nextTrigger.attrs),{dir:c("dir"),id:vL(u),type:"button","aria-label":A.nextTrigger,"data-orientation":c("orientation"),"aria-controls":Tl(u),disabled:!p,onClick(O){O.defaultPrevented||a({type:"PAGE.NEXT",src:"trigger"})}}))},getIndicatorGroupProps(){return t.element(ae(H({},Or.indicatorGroup.attrs),{dir:c("dir"),id:AL(u),"data-orientation":c("orientation"),onKeyDown(O){if(O.defaultPrevented)return;const R="indicator",z={ArrowDown(K){T||(a({type:"PAGE.NEXT",src:R}),K.preventDefault())},ArrowUp(K){T||(a({type:"PAGE.PREV",src:R}),K.preventDefault())},ArrowRight(K){T&&(a({type:"PAGE.NEXT",src:R}),K.preventDefault())},ArrowLeft(K){T&&(a({type:"PAGE.PREV",src:R}),K.preventDefault())},Home(K){a({type:"PAGE.SET",index:0,src:R}),K.preventDefault()},End(K){a({type:"PAGE.SET",index:y.length-1,src:R}),K.preventDefault()}},W=IP(O,{dir:c("dir"),orientation:c("orientation")}),M=z[W];M==null||M(O)}}))},getIndicatorProps(O){return t.button(ae(H({},Or.indicator.attrs),{dir:c("dir"),id:cb(u,O.index),type:"button","data-orientation":c("orientation"),"data-index":O.index,"data-readonly":Oo(O.readOnly),"data-current":Oo(O.index===x),"aria-label":A.indicator(O.index),onClick(R){R.defaultPrevented||O.readOnly||a({type:"PAGE.SET",index:O.index,src:"indicator"})}}))},getAutoplayTriggerProps(){return t.button(ae(H({},Or.autoplayTrigger.attrs),{type:"button","data-orientation":c("orientation"),"data-pressed":Oo(d),"aria-label":d?A.autoplayStop:A.autoplayStart,onClick(O){O.defaultPrevented||a({type:d?"AUTOPLAY.PAUSE":"AUTOPLAY.START"})}}))}}}var NL={props({props:e}){return eP(e,["slideCount"],"carousel"),ae(H({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:H({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:OL(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 FR(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"}),fb(e)});return fb(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"})};Ot(()=>{o(),Ot(()=>{t({type:"PAGE.SCROLL",instant:!0})})});const a=new r.ResizeObserver(o);return db(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 p=h.target,E=Number((T=p.dataset.index)!=null?T:"-1");return E==null||Number.isNaN(E)||E===-1?d:h.isIntersecting?RR(d,E):PR(d,E)},n.get("slidesInView"));n.set("slidesInView",LR(c))},{root:r,threshold:t("inViewThreshold")});return db(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackScroll({send:e,refs:t,scope:n}){const r=hn(n);return r?Bt(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 Bt(n,"visibilitychange",()=>{n.visibilityState!=="visible"&&t({type:"AUTOPLAY.PAUSE",src:"doc.hidden"})})},trackPointerMove({scope:e,send:t}){const n=e.getDoc();return qP(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 Bt(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=UE((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=ME(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=DR(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=TL(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=UE(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=ab(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=ab(r),c=u.x.reduce((h,p)=>Math.abs(p-o)<Math.abs(h-o)?p:h,u.x[0]),d=u.y.reduce((h,p)=>Math.abs(p-a)<Math.abs(h-a)?p:h,u.y[0]);Ot(()=>{r.scrollTo({left:c,top:d,behavior:"smooth"});const h=n("isHorizontal")?c:d;t.set("page",t.get("pageSnapPoints").indexOf(h));const p=r.dataset.scrollSnapType;p&&(r.style.setProperty("scroll-snap-type",p),delete r.dataset.scrollSnapType)})},focusIndicatorEl({context:e,event:t,scope:n}){if(t.src!=="indicator")return;const r=CL(n,e.get("page"));r&&Ot(()=>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 OL(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}Bo()(["dir","getRootNode","id","ids","loop","page","defaultPage","onPageChange","orientation","slideCount","slidesPerPage","slidesPerMove","spacing","padding","autoplay","allowMouseDrag","inViewThreshold","translations","snapType","onDragStatusChange","onAutoplayStatusChange"]),Bo()(["index","readOnly"]),Bo()(["index","snapAlign"]);const IL=e=>{const t=Z.useId(),{getRootNode:n}=bl(),{dir:r}=sh(),o=H({id:t,dir:r,getRootNode:n},e),a=sl(NL,o);return kL(a,Hf)},ph=Z.forwardRef((e,t)=>{const[n,r]=aa()(e,["allowMouseDrag","autoplay","defaultPage","id","ids","inViewThreshold","loop","onAutoplayStatusChange","onDragStatusChange","onPageChange","orientation","padding","page","slideCount","slidesPerMove","slidesPerPage","snapType","spacing","translations"]),o=IL(n),a=It(o.getRootProps(),r);return v.jsx(EL,{value:o,children:v.jsx(Qt.div,ae(H({},a),{ref:t}))})});ph.displayName="CarouselRoot";const RL=180,PL=e=>{const t=e.trim(),n=parseFloat(t);return Number.isNaN(n)?0:t.endsWith("rem")?n*16:n},LL=({globalClassName:e,className:t,itemMinWidth:n=RL,spacing:r="0.5rem",loop:o=!1,allowMouseDrag:a=!0,showIndicators:u=!0,showNavigation:c=!0,onPageChange:d,ariaLabel:h="Product carousel",children:p})=>{const E=Array.from(p),T=E.length,y=Z.useRef(null),[x,_]=Z.useState(0),{width:S}=yS();Z.useLayoutEffect(()=>{y.current&&_(y.current.getBoundingClientRect().width)},[S,T]);const A=PL(r),O=n+A,R=x>0?(x+A)/O:1,z=Math.max(1,Math.floor(R));if(T===0)return null;const W=T>z,M=Math.ceil(T/z),K=W?Math.max(1,R):z;return v.jsxs(ph,{ref:y,className:$(e,t,`${U}-carousel`),slidesPerPage:K,slidesPerMove:z,spacing:r,loop:o,allowMouseDrag:a,slideCount:T,onPageChange:d,"aria-label":h,children:[v.jsx(dh,{className:$(e,`${U}-carousel__item-group`,{"carousel-row-container":!W}),children:E.map((de,xe)=>v.jsx(ch,{index:xe,className:$(e,`${U}-carousel__item`),children:de},xe))}),c&&W&&v.jsxs(ah,{className:$(e,`${U}-carousel__control`),children:[v.jsx(hh,{className:$(e,`${U}-carousel__prev-trigger`),"aria-label":"Previous slide",children:v.jsx(eb,{size:"16px"})}),v.jsx(fh,{className:$(e,`${U}-carousel__next-trigger`),"aria-label":"Next slide",children:v.jsx(tb,{size:"16px"})})]}),u&&W&&v.jsx(lh,{className:$(e,`${U}-carousel__indicator-group`),children:Array.from({length:M},(de,xe)=>v.jsx(uh,{index:xe,className:$(e,`${U}-carousel__indicator`),"aria-label":`Go to slide group ${xe+1}`},xe))})]})},DL=({className:e,label:t="Close",onClick:n,disabled:r=!1})=>v.jsx("button",{"aria-label":t,title:t,className:$(e,`${U}-close-button`),disabled:r,onClick:n,children:v.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:v.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"})})}),[ML,FL]=Hi({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),BL=e=>aa()(e,["lazyMount","unmountOnExit"]),[UL,pa]=Hi({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),hb=Z.forwardRef((e,t)=>{const n=pa(),r=FL(),o=$f(ae(H({},r),{present:n.open})),a=It(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:v.jsx(Qt.div,ae(H({},a),{ref:al(o.ref,t)}))});hb.displayName="DialogBackdrop";const mh=Z.forwardRef((e,t)=>{const n=pa(),r=sa(),o=It(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:v.jsx(Qt.div,ae(H({},o),{ref:al(r.ref,t)}))});mh.displayName="DialogContent";const gh=Z.forwardRef((e,t)=>{const n=pa(),r=It(n.getDescriptionProps(),e);return v.jsx(Qt.div,ae(H({},r),{ref:t}))});gh.displayName="DialogDescription";const Eh=Z.forwardRef((e,t)=>{const n=pa(),r=It(n.getPositionerProps(),e);return sa().unmounted?null:v.jsx(Qt.div,ae(H({},r),{ref:t}))});Eh.displayName="DialogPositioner";var HL=zi("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),Vi=HL.build(),pb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},mb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},yh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},gb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},bh=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`},Eb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},xl=e=>e.getById(yh(e)),zL=e=>e.getById(pb(e)),jL=e=>e.getById(mb(e)),$L=e=>e.getById(gb(e)),VL=e=>e.getById(bh(e)),qL=e=>e.getById(Th(e)),YL=e=>e.getById(Eb(e));function WL(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(ae(H({},Vi.trigger.attrs),{dir:a("dir"),id:gb(u),"aria-haspopup":"dialog",type:"button","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":yh(u),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(ae(H({},Vi.backdrop.attrs),{dir:a("dir"),hidden:!d,id:mb(u),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ae(H({},Vi.positioner.attrs),{dir:a("dir"),id:pb(u),style:{pointerEvents:d?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(ae(H({},Vi.content.attrs),{dir:a("dir"),role:a("role"),hidden:!d,id:yh(u),tabIndex:-1,"data-state":d?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:bh(u),"aria-describedby":h.description?Th(u):void 0}))},getTitleProps(){return t.element(ae(H({},Vi.title.attrs),{dir:a("dir"),id:bh(u)}))},getDescriptionProps(){return t.element(ae(H({},Vi.description.attrs),{dir:a("dir"),id:Th(u)}))},getCloseTriggerProps(){return t.button(ae(H({},Vi.closeTrigger.attrs),{dir:a("dir"),id:Eb(u),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var GL={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>YL(t):void 0,o=typeof e.modal=="boolean"?e.modal:!0;return H({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 jy(()=>xl(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[$L(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 Wy(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?qy(()=>xl(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")?Py(()=>[xl(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){Ot(()=>{e.set("rendered",{title:!!VL(t),description:!!qL(t)})})},syncZIndex({scope:e}){Ot(()=>{const t=xl(e);if(!t)return;const n=Lo(t);[zL(e),jL(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})}}}};Bo()(["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 KL=e=>{const t=Z.useId(),{getRootNode:n}=bl(),{dir:r}=sh(),o=H({id:t,getRootNode:n,dir:r},e),a=sl(GL,o);return WL(a,Hf)},yb=e=>{const[t,c]=ly(e),d=c,{children:n}=d,r=sn(d,["children"]),[o]=BL(t),a=KL(r),u=$f(It({present:a.open},t));return v.jsx(UL,{value:a,children:v.jsx(ML,{value:o,children:v.jsx(sy,{value:u,children:n})})})},bb=Z.forwardRef((e,t)=>{const n=pa(),r=It(n.getTitleProps(),e);return v.jsx(Qt.h2,ae(H({},r),{ref:t}))});bb.displayName="DialogTitle";const QL=({children:e})=>{const[t,n]=Z.useState(!1),r=Z.useMemo(()=>({toggleMenu:()=>n(a=>!a),closeMenu:()=>n(!1)}),[]),o=Z.useMemo(()=>({isOpen:t}),[t]);return v.jsx(Af.Provider,{value:r,children:v.jsx(PE.Provider,{value:o,children:e})})},Tb=()=>Z.useContext(PE),xb=()=>{const e=Z.useContext(Af);if(!e)throw new Error("useOverflowMenuDispatch must be used within an OverflowMenuProvider");return e},XL=`${U}-overflow-menu-button-trigger`,JL=({componentType:e,children:t})=>{const{isOpen:n}=Tb(),{closeMenu:r}=xb(),{globalClassName:o}=At(),a=Z.useRef(null);return Z.useEffect(()=>{if(!n)return;const u=d=>{d.key==="Escape"&&r()},c=d=>{const h=d.target;h instanceof Element&&h.closest(`.${XL}`)||a.current&&!a.current.contains(h)&&r()};return document.addEventListener("keydown",u),document.addEventListener("mousedown",c),()=>{document.removeEventListener("keydown",u),document.removeEventListener("mousedown",c)}},[n,r]),n?v.jsx("div",{ref:a,role:"menu","aria-label":`Overflow menu for ${e}`,className:$(`${U}-overflow-panel`,o,`cim-${e}-component`),children:t}):null},ZL=({componentType:e,className:t})=>{const{toggleMenu:n}=xb(),{isOpen:r}=Tb(),{globalClassName:o}=At();return v.jsx("button",{"aria-label":`Overflow menu for ${e}`,title:"More options","aria-expanded":r,"aria-haspopup":"menu",className:$(`${U}-overflow-menu-button-trigger`,`${U}-icon-button`,o,t,`cim-${e}-component`),onClick:n,children:v.jsx(nb,{})})},eD=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),{previousComponentType:r}=ki(),o=ra(),a=()=>{Su(r||"dialog"),o()};return t?v.jsx(ar,{className:$(n,`${U}-toggle-dialog-button`,`cim-${e}-component`),ariaLabel:"Collapse",title:"Collapse",onClick:a,icon:v.jsx(rb,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-toggle-dialog-button`,`cim-${e}-component`),onClick:a,children:[v.jsx(rb,{}),"Show ",r||"dialog"]})},tD=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),{isModalFullscreen:r}=ki(),o=ra(),a=()=>{xd(!r),o()},u=r?GS:KS,c="Toggle Fullscreen";return t?v.jsx(ar,{ariaLabel:c,title:c,className:$(n,`${U}-modal-fullscreen-button`,`cim-${e}-component`),icon:v.jsx(u,{}),onClick:a}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-modal-fullscreen-button`,`cim-${e}-component`),onClick:a,children:[v.jsx(u,{}),c]})},nD=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),{dialogPosition:r}=ki(),o=ra(),a=r==="bottom-left",u=()=>{wd(a?"bottom-right":"bottom-left"),o()},c=a?mL:pL,d=a?"Move right":"Move left";return t?v.jsx(ar,{className:$(n,`${U}-left-right-toggle-button`,`cim-${e}-component`),ariaLabel:d,title:d,onClick:u,icon:v.jsx(c,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-left-right-toggle-button`,`cim-${e}-component`),onClick:u,children:[v.jsx(c,{}),d]})},wb=({componentType:e,onClearChat:t,onClose:n})=>{const{headerConfig:r,globalClassName:o}=At(),{mode:a}=ki(),u=a==="standalone",c=e==="modal",d=c?eD:Sb,h=c?tD:nD,p=Z.useMemo(()=>r?jS(r):{},[r]);return v.jsx(QL,{children:v.jsxs("div",{className:$(o,`${U}-${e}-header-wrapper`),style:{display:"flex",flexDirection:"column",position:"relative"},children:[v.jsxs("div",{className:$(o,`${U}-${e}-header`,{standalone:u,embedded:!u}),style:p,children:[(r==null?void 0:r.logoUrl)&&v.jsx("img",{alt:"",role:"img",className:$(o,`${U}-${e}-logo`,{standalone:u,embedded:!u}),src:r.logoUrl}),v.jsx(bb,{className:$(o,`${U}-${e}-title`,{standalone:u,embedded:!u}),children:r==null?void 0:r.headerText}),v.jsxs("div",{className:$(o,`${U}-${e}-controls`),children:[v.jsx(d,{componentType:e,isIcon:!0}),v.jsx(ZL,{componentType:e}),v.jsx(DL,{className:$(o,`cim-${e}-component`),onClick:n})]})]}),v.jsxs(JL,{componentType:e,children:[v.jsx(h,{componentType:e}),v.jsx(oD,{componentType:e}),v.jsx(DE,{componentType:e,onClearChat:t})]})]})})},_b="USD",ma=(e,t)=>{if(typeof e!="number"||Number.isNaN(e))return null;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t}).format(e)}catch(n){return`${e}`}},rD=({retailPrice:e,discountPrice:t,currencyCode:n=_b})=>{const r=n||_b,o=typeof t=="number"&&typeof e=="number"&&t<e,a=o?t:e||t||null,u=o?e:null;return{price:ma(a,r),comparePrice:ma(u,r),hasDiscount:o}},vb=({retailPrice:e,discountPrice:t,currencyCode:n,fontSize:r,globalClassName:o,className:a})=>{const{price:u,comparePrice:c,hasDiscount:d}=rD({retailPrice:e,discountPrice:t,currencyCode:n});if(!u)return null;const h=typeof r=="string"?{fontSize:r}:{};return v.jsxs("div",{className:$(o,a,`${U}-price`),style:h,children:[v.jsx("span",{className:$(o,`${U}-price__amount`),children:u}),d&&c&&v.jsx("span",{className:$(o,`${U}-price__compare`),children:c})]})},iD=({className:e,globalClassName:t,suggestions:n,disabled:r,isWidgetStandalone:o,onSuggestionClick:a})=>{const u=o?"standalone":"embedded",c=d=>()=>{a(d)};return v.jsx("div",{className:$(t,`${U}-suggestion-container ${u}`,e),children:n.map(d=>o?v.jsx(Ni,{disabled:r,className:$(t,`${U}-suggestion-button standalone`),onClick:c(d),children:d},d):v.jsx("button",{disabled:r,className:$(t,`${U}-suggestion-button embedded`),onClick:c(d),children:d},d))})},oD=({componentType:e,isIcon:t})=>{const{globalClassName:n,enableMinimize:r}=At();if(!r)return null;const o=()=>{Ci(!1),vu(!0)};return t?v.jsx(ar,{className:$(n,`${U}-toggle-minimize-button`,`cim-${e}-component`),ariaLabel:"Toggle Minimize",title:"Minimize",onClick:o,icon:v.jsx($0,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-toggle-minimize-button`,`cim-${e}-component`),onClick:o,children:[v.jsx($0,{}),"Minimize"]})},Sb=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),r=ra(),o=()=>{Su("modal"),r()};return t?v.jsx(ar,{className:$(n,`${U}-toggle-modal-button`,`cim-${e}-component`),ariaLabel:"Expand",title:"Expand",onClick:o,icon:v.jsx(ib,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-toggle-modal-button`,`cim-${e}-component`),onClick:o,children:[v.jsx(ib,{}),"Show modal"]})},sD=["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"],aD=3e3,uD=400,lD=({globalClassName:e,isWidgetStandalone:t,messages:n=sD})=>{const[r,o]=Z.useState(0),[a,u]=Z.useState(!0);return Z.useEffect(()=>{let c;const d=setInterval(()=>{u(!1),c=setTimeout(()=>{o(h=>(h+1)%n.length),u(!0)},uD)},aD);return()=>{clearInterval(d),clearTimeout(c)}},[n.length]),v.jsxs("div",{className:$(e,`${U}-connecting-indicator`,t?"standalone":"embedded"),role:"status","aria-label":"Connecting to assistant",children:[v.jsxs("div",{className:`${U}-connecting-pulse-wrapper`,children:[v.jsx("div",{className:`${U}-connecting-pulse`}),v.jsx("div",{className:`${U}-connecting-ring`})]}),v.jsx("span",{className:$(`${U}-connecting-text`,a&&`${U}-connecting-text--visible`),children:n[r]})]})},cD=({shouldShow:e,loadingText:t})=>e?v.jsx("span",{className:`${U}-processing-text`,children:t}):null,dD=({shouldShow:e})=>e?v.jsxs(v.Fragment,{children:[v.jsx("div",{className:`${U}-processing-shimmer-bar`}),v.jsx("div",{className:`${U}-processing-shimmer-bar`}),v.jsx("div",{className:`${U}-processing-shimmer-bar`})]}):null,xh=({globalClassName:e,isWidgetStandalone:t,loadingText:n})=>v.jsxs("div",{className:$(e,`${U}-processing-indicator`,t?"standalone":"embedded"),role:"status","aria-label":n||"Loading response",children:[v.jsx(cD,{shouldShow:!!n,loadingText:n}),v.jsx(dD,{shouldShow:!n})]});function Ab(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 fD(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function hD(e,t,n){const o=Bu((n||{}).ignore||[]),a=pD(t);let u=-1;for(;++u<a.length;)n1(e,"text",c);function c(h,p){let E=-1,T;for(;++E<p.length;){const y=p[E],x=T?T.children:void 0;if(o(y,x?x.indexOf(y):void 0,T))return;T=y}if(T)return d(h,p)}function d(h,p){const E=p[p.length-1],T=a[u][0],y=a[u][1];let x=0;const S=E.children.indexOf(h);let A=!1,O=[];T.lastIndex=0;let R=T.exec(h.value);for(;R;){const z=R.index,W={index:R.index,input:R.input,stack:[...p,h]};let M=y(...R,W);if(typeof M=="string"&&(M=M.length>0?{type:"text",value:M}:void 0),M===!1?T.lastIndex=z+1:(x!==z&&O.push({type:"text",value:h.value.slice(x,z)}),Array.isArray(M)?O.push(...M):M&&O.push(M),x=z+R[0].length,A=!0),!T.global)break;R=T.exec(h.value)}return A?(x<h.value.length&&O.push({type:"text",value:h.value.slice(x)}),E.children.splice(S,1,...O)):O=[h],S+O.length}}function pD(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([mD(o[0]),gD(o[1])])}return t}function mD(e){return typeof e=="string"?new RegExp(fD(e),"g"):e}function gD(e){return typeof e=="function"?e:function(){return e}}const wh="phrasing",_h=["autolink","link","image","label"];function ED(){return{transforms:[vD],enter:{literalAutolink:bD,literalAutolinkEmail:vh,literalAutolinkHttp:vh,literalAutolinkWww:vh},exit:{literalAutolink:_D,literalAutolinkEmail:wD,literalAutolinkHttp:TD,literalAutolinkWww:xD}}}function yD(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:wh,notInConstruct:_h},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:wh,notInConstruct:_h},{character:":",before:"[ps]",after:"\\/",inConstruct:wh,notInConstruct:_h}]}}function bD(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function vh(e){this.config.enter.autolinkProtocol.call(this,e)}function TD(e){this.config.exit.autolinkProtocol.call(this,e)}function xD(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 wD(e){this.config.exit.autolinkEmail.call(this,e)}function _D(e){this.exit(e)}function vD(e){hD(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,SD],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),AD]],{ignore:["link","linkReference"]})}function SD(e,t,n,r,o){let a="";if(!Cb(o)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!CD(n)))return!1;const u=kD(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 AD(e,t,n,r){return!Cb(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function CD(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 kD(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=Ab(e,"(");let a=Ab(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 Cb(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Ii(n)||Iu(n))&&(!t||n!==47)}kb.peek=FD;function ND(){this.buffer()}function OD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function ID(){this.buffer()}function RD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function PD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Yn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function LD(e){this.exit(e)}function DD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Yn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function MD(e){this.exit(e)}function FD(){return"["}function kb(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 BD(){return{enter:{gfmFootnoteCallString:ND,gfmFootnoteCall:OD,gfmFootnoteDefinitionLabelString:ID,gfmFootnoteDefinition:RD},exit:{gfmFootnoteCallString:PD,gfmFootnoteCall:LD,gfmFootnoteDefinitionLabelString:DD,gfmFootnoteDefinition:MD}}}function UD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:kb},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"),p=a.enter("label");return d+=c.move(a.safe(a.associationId(r),{before:d,after:"]"})),p(),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?Nb:HD))),h(),d}}function HD(e,t,n){return t===0?e:Nb(e,t,n)}function Nb(e,t,n){return(n?"":" ")+e}const zD=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Ob.peek=YD;function jD(){return{canContainEols:["delete"],enter:{strikethrough:VD},exit:{strikethrough:qD}}}function $D(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:zD}],handlers:{delete:Ob}}}function VD(e){this.enter({type:"delete",children:[]},e)}function qD(e){this.exit(e)}function Ob(e,t,n,r){const o=n.createTracker(r),a=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,ae(H({},o.current()),{before:u,after:"~"})),u+=o.move("~~"),a(),u}function YD(){return"~"}function WD(e){return e.length}function GD(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||WD,a=[],u=[],c=[],d=[];let h=0,p=-1;for(;++p<e.length;){const _=[],S=[];let A=-1;for(e[p].length>h&&(h=e[p].length);++A<e[p].length;){const O=KD(e[p][A]);if(n.alignDelimiters!==!1){const R=o(O);S[A]=R,(d[A]===void 0||R>d[A])&&(d[A]=R)}_.push(O)}u[p]=_,c[p]=S}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)a[E]=Ib(r[E]);else{const _=Ib(r);for(;++E<h;)a[E]=_}E=-1;const T=[],y=[];for(;++E<h;){const _=a[E];let S="",A="";_===99?(S=":",A=":"):_===108?S=":":_===114&&(A=":");let O=n.alignDelimiters===!1?1:Math.max(1,d[E]-S.length-A.length);const R=S+"-".repeat(O)+A;n.alignDelimiters!==!1&&(O=S.length+O+A.length,O>d[E]&&(d[E]=O),y[E]=O),T[E]=R}u.splice(1,0,T),c.splice(1,0,y),p=-1;const x=[];for(;++p<u.length;){const _=u[p],S=c[p];E=-1;const A=[];for(;++E<h;){const O=_[E]||"";let R="",z="";if(n.alignDelimiters!==!1){const W=d[E]-(S[E]||0),M=a[E];M===114?R=" ".repeat(W):M===99?W%2?(R=" ".repeat(W/2+.5),z=" ".repeat(W/2-.5)):(R=" ".repeat(W/2),z=R):z=" ".repeat(W)}n.delimiterStart!==!1&&!E&&A.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&O==="")&&(n.delimiterStart!==!1||E)&&A.push(" "),n.alignDelimiters!==!1&&A.push(R),A.push(O),n.alignDelimiters!==!1&&A.push(z),n.padding!==!1&&A.push(" "),(n.delimiterEnd!==!1||E!==h-1)&&A.push("|")}x.push(n.delimiterEnd===!1?A.join("").replace(/ +$/,""):A.join(""))}return x.join(`
36
+ `},o),a}function _3(e,t){return e&&"run"in e?function(n,r){return $e(this,null,function*(){const o=i1(n,B({file:r},t));yield e.run(o,r)})}:function(n,r){return i1(n,B({file:r},e||t))}}function o1(e){if(e)throw e}var Qd,s1;function v3(){if(s1)return Qd;s1=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 p=e.call(h,"constructor"),E=h.constructor&&h.constructor.prototype&&e.call(h.constructor.prototype,"isPrototypeOf");if(h.constructor&&!p&&!E)return!1;var T;for(T in h);return typeof T=="undefined"||e.call(h,T)},u=function(h,p){n&&p.name==="__proto__"?n(h,p.name,{enumerable:!0,configurable:!0,value:p.newValue,writable:!0}):h[p.name]=p.newValue},c=function(h,p){if(p==="__proto__")if(e.call(h,p)){if(r)return r(h,p).value}else return;return h[p]};return Qd=function d(){var h,p,E,T,y,x,_=arguments[0],S=1,A=arguments.length,O=!1;for(typeof _=="boolean"&&(O=_,_=arguments[1]||{},S=2),(_==null||typeof _!="object"&&typeof _!="function")&&(_={});S<A;++S)if(h=arguments[S],h!=null)for(p in h)E=c(_,p),T=c(h,p),_!==T&&(O&&T&&(a(T)||(y=o(T)))?(y?(y=!1,x=E&&o(E)?E:[]):x=E&&a(E)?E:{},u(_,{name:p,newValue:d(O,x,T)})):typeof T!="undefined"&&u(_,{name:p,newValue:T}));return _},Qd}var S3=v3();const Xd=We(S3);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 A3(){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 p=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,p?C3(p,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 C3(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 p=h;if(c&&n)throw p;return o(p)}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 lr={basename:k3,dirname:N3,extname:O3,join:I3,sep:"/"};function k3(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');$s(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 N3(e){if($s(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 O3(e){$s(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 I3(...e){let t=-1,n;for(;++t<e.length;)$s(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":R3(n)}function R3(e){$s(e);const t=e.codePointAt(0)===47;let n=P3(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function P3(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 $s(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const L3={cwd:D3};function D3(){return"/"}function Zd(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function M3(e){if(typeof e=="string")e=new URL(e);else if(!Zd(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 F3(e)}function F3(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 ef=["history","path","basename","stem","extname","dirname"];class a1{constructor(t){let n;t?Zd(t)?n={path:t}:typeof t=="string"||B3(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":L3.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<ef.length;){const a=ef[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)ef.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?lr.basename(this.path):void 0}set basename(t){nf(t,"basename"),tf(t,"basename"),this.path=lr.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?lr.dirname(this.path):void 0}set dirname(t){u1(this.basename,"dirname"),this.path=lr.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?lr.extname(this.path):void 0}set extname(t){if(tf(t,"extname"),u1(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=lr.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Zd(t)&&(t=M3(t)),nf(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?lr.basename(this.path,this.extname):void 0}set stem(t){nf(t,"stem"),tf(t,"stem"),this.path=lr.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 Wt(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 tf(e,t){if(e&&e.includes(lr.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+lr.sep+"`")}function nf(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function u1(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function B3(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const U3=(function(e){const r=this.constructor.prototype,o=r[e],a=function(){return o.apply(a,arguments)};return Object.setPrototypeOf(a,r),a}),H3={}.hasOwnProperty;class rf extends U3{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=A3()}copy(){const t=new rf;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Xd(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(af("data",this.frozen),this.namespace[t]=n,this):H3.call(this.namespace,t)&&this.namespace[t]||void 0:t?(af("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=zu(t),r=this.parser||this.Parser;return of("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),of("process",this.parser||this.Parser),sf("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(a,u){const c=zu(t),d=r.parse(c);r.run(d,c,function(p,E,T){if(p||!E||!T)return h(p);const y=E,x=r.stringify(y,T);$3(x)?T.value=x:T.result=x,h(p,T)});function h(p,E){p||!E?u(p):a?a(E):n(void 0,E)}}}processSync(t){let n=!1,r;return this.freeze(),of("processSync",this.parser||this.Parser),sf("processSync",this.compiler||this.Compiler),this.process(t,o),c1("processSync","process",n),r;function o(a,u){n=!0,o1(a),r=u}}run(t,n,r){l1(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=zu(n);o.run(t,d,h);function h(p,E,T){const y=E||t;p?c(p):u?u(y):r(void 0,y,T)}}}runSync(t,n){let r=!1,o;return this.run(t,n,a),c1("runSync","run",r),o;function a(u,c){o1(u),o=c,r=!0}}stringify(t,n){this.freeze();const r=zu(n),o=this.compiler||this.Compiler;return sf("stringify",o),l1(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(af("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[p,...E]=h;d(p,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=Xd(!0,o.settings,h.settings))}function c(h){let p=-1;if(h!=null)if(Array.isArray(h))for(;++p<h.length;){const E=h[p];a(E)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function d(h,p){let E=-1,T=-1;for(;++E<r.length;)if(r[E][0]===h){T=E;break}if(T===-1)r.push([h,...p]);else if(p.length>0){let[y,...x]=p;const _=r[T][1];Jd(_)&&Jd(y)&&(y=Xd(!0,_,y)),r[T]=[h,y,...x]}}}}const z3=new rf().freeze();function of(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function sf(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function af(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 l1(e){if(!Jd(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function c1(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function zu(e){return j3(e)?e:new a1(e)}function j3(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function $3(e){return typeof e=="string"||V3(e)}function V3(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const q3="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",d1=[],f1={allowDangerousHtml:!0},Y3=/^(https?|ircs?|mailto|xmpp)$/i,W3=[{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 h1(e){const t=G3(e),n=K3(e);return Q3(t.runSync(t.parse(n),n),e)}function G3(e){const t=e.rehypePlugins||d1,n=e.remarkPlugins||d1,r=e.remarkRehypeOptions?B(B({},e.remarkRehypeOptions),f1):f1;return z3().use(Nk).use(n).use(_3,r).use(t)}function K3(e){const t=e.children||"",n=new a1;return typeof t=="string"&&(n.value=t),n}function Q3(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,a=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,d=t.urlTransform||X3;for(const p of W3)Object.hasOwn(t,p.from)&&(""+p.from+(p.to?"use `"+p.to+"` instead":"remove it")+q3+p.id,void 0);return Hu(e,h),xA(e,{Fragment:v.Fragment,components:o,ignoreInvalidStyle:!0,jsx:v.jsx,jsxs:v.jsxs,passKeys:!0,passNode:!0});function h(p,E,T){if(p.type==="raw"&&T&&typeof E=="number")return u?T.children.splice(E,1):T.children[E]={type:"text",value:p.value},E;if(p.type==="element"){let y;for(y in Md)if(Object.hasOwn(Md,y)&&Object.hasOwn(p.properties,y)){const x=p.properties[y],_=Md[y];(_===null||_.includes(p.tagName))&&(p.properties[y]=d(String(x||""),y,p))}}if(p.type==="element"){let y=n?!n.includes(p.tagName):a?a.includes(p.tagName):!1;if(!y&&r&&typeof E=="number"&&(y=!r(p,E,T)),y&&T&&typeof E=="number")return c&&p.children?T.children.splice(E,1,...p.children):T.children.splice(E,1),E}}}function X3(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||Y3.test(e.slice(0,t))?e:""}const p1=/[#.]/g;function J3(e,t){const n=e||"",r={};let o=0,a,u;for(;o<n.length;){p1.lastIndex=o;const c=p1.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 m1(e,t,n){const r=n?nN(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=J3(a,t);const h=d.tagName.toLowerCase(),p=r?r.get(h):void 0;if(d.tagName=p||h,Z3(u))c.unshift(u);else for(const[E,T]of Object.entries(u))eN(e,d.properties,E,T)}for(const h of c)uf(d.children,h);return d.type==="element"&&d.tagName==="template"&&(d.content={type:"root",children:d.children},d.children=[]),d}return o}function Z3(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 eN(e,t,n,r){const o=Od(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=og(r):o.commaSeparated?a=Y0(r):o.commaOrSpaceSeparated?a=og(Y0(r).join(" ")):a=g1(o,o.property,r):Array.isArray(r)?a=[...r]:a=o.property==="style"?tN(r):String(r);if(Array.isArray(a)){const u=[];for(const c of a)u.push(g1(o,o.property,c));a=u}o.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[o.property]=a}}function uf(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)uf(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?uf(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function g1(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||Ps(n)===Ps(t)))return!0}return n}function tN(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function nN(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const rN=["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"],iN=m1(ku,"div"),oN=m1(Eo,"g",rN);function sN(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=E1(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=E1(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 E1(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 Pi={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/"},y1={}.hasOwnProperty,aN=Object.prototype;function uN(e,t){const n=t||{};return lf({file:n.file||void 0,location:!1,schema:n.space==="svg"?Eo:ku,verbose:n.verbose||!1},e)}function lf(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},ju(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:b1(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const a=String(e.file),u=sN(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"},ju(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},ju(e,r,n),n}default:return n=lN(e,t),n}}function b1(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=lf(e,t[n]);r.push(o)}return r}function lN(e,t){const n=e.schema;e.schema=t.namespaceURI===Pi.svg?Eo:ku;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],d=(c.prefix?c.prefix+":":"")+c.name;y1.call(aN,d)||(o[d]=c.value)}const u=(e.schema.space==="svg"?oN:iN)(t.tagName,o,b1(e,t.childNodes));if(ju(e,t,u),u.tagName==="template"){const c=t,d=c.sourceCodeLocation,h=d&&d.startTag&&wo(d.startTag),p=d&&d.endTag&&wo(d.endTag),E=lf(e,c.content);h&&p&&e.file&&(E.position={start:h.end,end:p.start}),u.content=E}return e.schema=n,u}function ju(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=cN(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function cN(e,t,n){const r=wo(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)y1.call(n.attrs,u)&&(a[Od(e.schema,u).property]=wo(n.attrs[u]));n.startTag;const c=wo(n.startTag),d=n.endTag?wo(n.endTag):void 0,h={opening:c};d&&(h.closing=d),h.properties=a,t.data={position:h}}}return r}function wo(e){const t=T1({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=T1({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function T1(e){return e.line&&e.column?e:void 0}class Vs{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}Vs.prototype.property={},Vs.prototype.normal={},Vs.prototype.space=null;function x1(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 Vs(n,r,t)}function cf(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 dN=0;const ze=Li(),kt=Li(),w1=Li(),ye=Li(),st=Li(),_o=Li(),wn=Li();function Li(){return nu(2,++dN)}const df=Object.freeze(Object.defineProperty({__proto__:null,boolean:ze,booleanish:kt,commaOrSpaceSeparated:wn,commaSeparated:_o,number:ye,overloadedBoolean:w1,spaceSeparated:st},Symbol.toStringTag,{value:"Module"})),ff=Object.keys(df);class hf extends Pn{constructor(t,n,r,o){let a=-1;if(super(t,n),_1(this,"space",o),typeof r=="number")for(;++a<ff.length;){const u=ff[a];_1(this,ff[a],(r&df[u])===df[u])}}}hf.prototype.defined=!0;function _1(e,t,n){n&&(e[t]=n)}const fN={}.hasOwnProperty;function vo(e){const t={},n={};let r;for(r in e.properties)if(fN.call(e.properties,r)){const o=e.properties[r],a=new hf(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[cf(r)]=r,n[cf(a.attribute)]=r}return new Vs(t,n,e.space)}const v1=vo({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}}),S1=vo({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function A1(e,t){return t in e?e[t]:t}function C1(e,t){return A1(e,t.toLowerCase())}const k1=vo({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:C1,properties:{xmlns:null,xmlnsXLink:null}}),N1=vo({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:kt,ariaAutoComplete:null,ariaBusy:kt,ariaChecked:kt,ariaColCount:ye,ariaColIndex:ye,ariaColSpan:ye,ariaControls:st,ariaCurrent:null,ariaDescribedBy:st,ariaDetails:null,ariaDisabled:kt,ariaDropEffect:st,ariaErrorMessage:null,ariaExpanded:kt,ariaFlowTo:st,ariaGrabbed:kt,ariaHasPopup:null,ariaHidden:kt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:st,ariaLevel:ye,ariaLive:null,ariaModal:kt,ariaMultiLine:kt,ariaMultiSelectable:kt,ariaOrientation:null,ariaOwns:st,ariaPlaceholder:null,ariaPosInSet:ye,ariaPressed:kt,ariaReadOnly:kt,ariaRelevant:null,ariaRequired:kt,ariaRoleDescription:st,ariaRowCount:ye,ariaRowIndex:ye,ariaRowSpan:ye,ariaSelected:kt,ariaSetSize:ye,ariaSort:null,ariaValueMax:ye,ariaValueMin:ye,ariaValueNow:ye,ariaValueText:null,role:null}}),hN=vo({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:C1,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:_o,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:ye,colSpan:null,content:null,contentEditable:kt,controls:ze,controlsList:st,coords:ye|_o,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ze,defer:ze,dir:null,dirName:null,disabled:ze,download:w1,draggable:kt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:ze,formTarget:null,headers:st,height:ye,hidden:ze,high:ye,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:ye,manifest:null,max:null,maxLength:ye,media:null,method:null,min:null,minLength:ye,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:ye,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:ye,rowSpan:ye,sandbox:st,scope:null,scoped:ze,seamless:ze,selected:ze,shadowRootClonable:ze,shadowRootDelegatesFocus:ze,shadowRootMode:null,shape:null,size:ye,sizes:null,slot:null,span:ye,spellCheck:kt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ye,step:null,style:null,tabIndex:ye,target:null,title:null,translate:null,type:null,typeMustMatch:ze,useMap:null,value:kt,width:ye,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:st,axis:null,background:null,bgColor:null,border:ye,borderColor:null,bottomMargin:ye,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:ye,leftMargin:ye,link:null,longDesc:null,lowSrc:null,marginHeight:ye,marginWidth:ye,noResize:ze,noHref:ze,noShade:ze,noWrap:ze,object:null,profile:null,prompt:null,rev:null,rightMargin:ye,rules:null,scheme:null,scrolling:kt,standby:null,summary:null,text:null,topMargin:ye,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ye,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:ze,disableRemotePlayback:ze,prefix:null,property:null,results:ye,security:null,unselectable:null}}),pN=vo({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:A1,properties:{about:wn,accentHeight:ye,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ye,amplitude:ye,arabicForm:null,ascent:ye,attributeName:null,attributeType:null,azimuth:ye,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ye,by:null,calcMode:null,capHeight:ye,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:ye,diffuseConstant:ye,direction:null,display:null,dur:null,divisor:ye,dominantBaseline:null,download:ze,dx:null,dy:null,edgeMode:null,editable:null,elevation:ye,enableBackground:null,end:null,event:null,exponent:ye,externalResourcesRequired:null,fill:null,fillOpacity:ye,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:_o,g2:_o,glyphName:_o,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ye,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ye,horizOriginX:ye,horizOriginY:ye,id:null,ideographic:ye,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ye,k:ye,k1:ye,k2:ye,k3:ye,k4:ye,kernelMatrix:wn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ye,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:ye,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:ye,overlineThickness:ye,paintOrder:null,panose1:null,path:null,pathLength:ye,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:st,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ye,pointsAtY:ye,pointsAtZ:ye,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:wn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:wn,rev:wn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:wn,requiredFeatures:wn,requiredFonts:wn,requiredFormats:wn,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:ye,specularExponent:ye,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ye,strikethroughThickness:ye,string:null,stroke:null,strokeDashArray:wn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ye,strokeOpacity:ye,strokeWidth:null,style:null,surfaceScale:ye,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:wn,tabIndex:ye,tableValues:null,target:null,targetX:ye,targetY:ye,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:wn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ye,underlineThickness:ye,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ye,values:null,vAlphabetic:ye,vMathematical:ye,vectorEffect:null,vHanging:ye,vIdeographic:ye,version:null,vertAdvY:ye,vertOriginX:ye,vertOriginY:ye,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ye,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),mN=/^data[-\w.:]+$/i,O1=/-[a-z]/g,gN=/[A-Z]/g;function EN(e,t){const n=cf(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"&&mN.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(O1,bN);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!O1.test(a)){let u=a.replace(gN,yN);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=hf}return new o(r,t)}function yN(e){return"-"+e.toLowerCase()}function bN(e){return e.charAt(1).toUpperCase()}const TN=x1([S1,v1,k1,N1,hN],"html"),I1=x1([S1,v1,k1,N1,pN],"svg"),R1={}.hasOwnProperty;function P1(e,t){const n=t||{};function r(o,...a){let u=r.invalid;const c=r.handlers;if(o&&R1.call(o,e)){const d=String(o[e]);u=R1.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 xN={},wN={}.hasOwnProperty,L1=P1("type",{handlers:{root:vN,element:NN,text:CN,comment:kN,doctype:AN}});function _N(e,t){const r=(t||xN).space;return L1(e,r==="svg"?I1:TN)}function vN(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=pf(e.children,n,t),So(e,n),n}function SN(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=pf(e.children,n,t),So(e,n),n}function AN(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return So(e,t),t}function CN(e){const t={nodeName:"#text",value:e.value,parentNode:null};return So(e,t),t}function kN(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return So(e,t),t}function NN(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=I1);const o=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&wN.call(e.properties,a)){const d=ON(r,a,e.properties[a]);d&&o.push(d)}}const u=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Pi[u],childNodes:[],parentNode:null};return c.childNodes=pf(e.children,c,r),So(e,c),e.tagName==="template"&&e.content&&(c.content=SN(e.content,r)),c}function ON(e,t,n){const r=EN(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):sg(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=Pi[r.space]}return o}function pf(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const a=L1(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 IN=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],RN=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 N;(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"})(N||(N={}));const fn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function D1(e){return e>=55296&&e<=57343}function PN(e){return e>=56320&&e<=57343}function LN(e,t){return(e-55296)*1024+9216+t}function M1(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function F1(e){return e>=64976&&e<=65007||RN.has(e)}var te;(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"})(te||(te={}));const DN=65536;class MN{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=DN,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(PN(n))return this.pos++,this._addGap(),LN(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,N.EOF;return this._err(te.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,N.EOF;const r=this.html.charCodeAt(n);return r===N.CARRIAGE_RETURN?N.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,N.EOF;let t=this.html.charCodeAt(this.pos);return t===N.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,N.LINE_FEED):t===N.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===N.LINE_FEED||t===N.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){M1(t)?this._err(te.controlCharacterInInputStream):F1(t)&&this._err(te.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var Ve;(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"})(Ve||(Ve={}));function B1(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 FN=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))),BN=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 UN(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=BN.get(e))!==null&&t!==void 0?t:e}var Dt;(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"})(Dt||(Dt={}));const HN=32;var Wr;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Wr||(Wr={}));function mf(e){return e>=Dt.ZERO&&e<=Dt.NINE}function zN(e){return e>=Dt.UPPER_A&&e<=Dt.UPPER_F||e>=Dt.LOWER_A&&e<=Dt.LOWER_F}function jN(e){return e>=Dt.UPPER_A&&e<=Dt.UPPER_Z||e>=Dt.LOWER_A&&e<=Dt.LOWER_Z||mf(e)}function $N(e){return e===Dt.EQUALS||jN(e)}var Mt;(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"})(Mt||(Mt={}));var Ar;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Ar||(Ar={}));class VN{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Mt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Ar.Strict}startEntity(t){this.decodeMode=t,this.state=Mt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Mt.EntityStart:return t.charCodeAt(n)===Dt.NUM?(this.state=Mt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Mt.NamedEntity,this.stateNamedEntity(t,n));case Mt.NumericStart:return this.stateNumericStart(t,n);case Mt.NumericDecimal:return this.stateNumericDecimal(t,n);case Mt.NumericHex:return this.stateNumericHex(t,n);case Mt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|HN)===Dt.LOWER_X?(this.state=Mt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Mt.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(mf(o)||zN(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(mf(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===Dt.SEMI)this.consumed+=1;else if(this.decodeMode===Ar.Strict)return 0;return this.emitCodePoint(UN(this.result),this.consumed),this.errors&&(t!==Dt.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&Wr.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const u=t.charCodeAt(n);if(this.treeIndex=qN(r,o,this.treeIndex+Math.max(1,a),u),this.treeIndex<0)return this.result===0||this.decodeMode===Ar.Attribute&&(a===0||$N(u))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],a=(o&Wr.VALUE_LENGTH)>>14,a!==0){if(u===Dt.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]&Wr.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]&~Wr.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Mt.NamedEntity:return this.result!==0&&(this.decodeMode!==Ar.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Mt.NumericDecimal:return this.emitNumericEntity(0,2);case Mt.NumericHex:return this.emitNumericEntity(0,3);case Mt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Mt.EntityStart:return 0}}}function qN(e,t,n,r){const o=(t&Wr.BRANCH_LENGTH)>>7,a=t&Wr.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 le;(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/"})(le||(le={}));var Di;(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"})(Di||(Di={}));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 m;(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"})(m||(m={}));const YN=new Map([[Y.A,m.A],[Y.ADDRESS,m.ADDRESS],[Y.ANNOTATION_XML,m.ANNOTATION_XML],[Y.APPLET,m.APPLET],[Y.AREA,m.AREA],[Y.ARTICLE,m.ARTICLE],[Y.ASIDE,m.ASIDE],[Y.B,m.B],[Y.BASE,m.BASE],[Y.BASEFONT,m.BASEFONT],[Y.BGSOUND,m.BGSOUND],[Y.BIG,m.BIG],[Y.BLOCKQUOTE,m.BLOCKQUOTE],[Y.BODY,m.BODY],[Y.BR,m.BR],[Y.BUTTON,m.BUTTON],[Y.CAPTION,m.CAPTION],[Y.CENTER,m.CENTER],[Y.CODE,m.CODE],[Y.COL,m.COL],[Y.COLGROUP,m.COLGROUP],[Y.DD,m.DD],[Y.DESC,m.DESC],[Y.DETAILS,m.DETAILS],[Y.DIALOG,m.DIALOG],[Y.DIR,m.DIR],[Y.DIV,m.DIV],[Y.DL,m.DL],[Y.DT,m.DT],[Y.EM,m.EM],[Y.EMBED,m.EMBED],[Y.FIELDSET,m.FIELDSET],[Y.FIGCAPTION,m.FIGCAPTION],[Y.FIGURE,m.FIGURE],[Y.FONT,m.FONT],[Y.FOOTER,m.FOOTER],[Y.FOREIGN_OBJECT,m.FOREIGN_OBJECT],[Y.FORM,m.FORM],[Y.FRAME,m.FRAME],[Y.FRAMESET,m.FRAMESET],[Y.H1,m.H1],[Y.H2,m.H2],[Y.H3,m.H3],[Y.H4,m.H4],[Y.H5,m.H5],[Y.H6,m.H6],[Y.HEAD,m.HEAD],[Y.HEADER,m.HEADER],[Y.HGROUP,m.HGROUP],[Y.HR,m.HR],[Y.HTML,m.HTML],[Y.I,m.I],[Y.IMG,m.IMG],[Y.IMAGE,m.IMAGE],[Y.INPUT,m.INPUT],[Y.IFRAME,m.IFRAME],[Y.KEYGEN,m.KEYGEN],[Y.LABEL,m.LABEL],[Y.LI,m.LI],[Y.LINK,m.LINK],[Y.LISTING,m.LISTING],[Y.MAIN,m.MAIN],[Y.MALIGNMARK,m.MALIGNMARK],[Y.MARQUEE,m.MARQUEE],[Y.MATH,m.MATH],[Y.MENU,m.MENU],[Y.META,m.META],[Y.MGLYPH,m.MGLYPH],[Y.MI,m.MI],[Y.MO,m.MO],[Y.MN,m.MN],[Y.MS,m.MS],[Y.MTEXT,m.MTEXT],[Y.NAV,m.NAV],[Y.NOBR,m.NOBR],[Y.NOFRAMES,m.NOFRAMES],[Y.NOEMBED,m.NOEMBED],[Y.NOSCRIPT,m.NOSCRIPT],[Y.OBJECT,m.OBJECT],[Y.OL,m.OL],[Y.OPTGROUP,m.OPTGROUP],[Y.OPTION,m.OPTION],[Y.P,m.P],[Y.PARAM,m.PARAM],[Y.PLAINTEXT,m.PLAINTEXT],[Y.PRE,m.PRE],[Y.RB,m.RB],[Y.RP,m.RP],[Y.RT,m.RT],[Y.RTC,m.RTC],[Y.RUBY,m.RUBY],[Y.S,m.S],[Y.SCRIPT,m.SCRIPT],[Y.SEARCH,m.SEARCH],[Y.SECTION,m.SECTION],[Y.SELECT,m.SELECT],[Y.SOURCE,m.SOURCE],[Y.SMALL,m.SMALL],[Y.SPAN,m.SPAN],[Y.STRIKE,m.STRIKE],[Y.STRONG,m.STRONG],[Y.STYLE,m.STYLE],[Y.SUB,m.SUB],[Y.SUMMARY,m.SUMMARY],[Y.SUP,m.SUP],[Y.TABLE,m.TABLE],[Y.TBODY,m.TBODY],[Y.TEMPLATE,m.TEMPLATE],[Y.TEXTAREA,m.TEXTAREA],[Y.TFOOT,m.TFOOT],[Y.TD,m.TD],[Y.TH,m.TH],[Y.THEAD,m.THEAD],[Y.TITLE,m.TITLE],[Y.TR,m.TR],[Y.TRACK,m.TRACK],[Y.TT,m.TT],[Y.U,m.U],[Y.UL,m.UL],[Y.SVG,m.SVG],[Y.VAR,m.VAR],[Y.WBR,m.WBR],[Y.XMP,m.XMP]]);function Ao(e){var t;return(t=YN.get(e))!==null&&t!==void 0?t:m.UNKNOWN}const pe=m,WN={[le.HTML]:new Set([pe.ADDRESS,pe.APPLET,pe.AREA,pe.ARTICLE,pe.ASIDE,pe.BASE,pe.BASEFONT,pe.BGSOUND,pe.BLOCKQUOTE,pe.BODY,pe.BR,pe.BUTTON,pe.CAPTION,pe.CENTER,pe.COL,pe.COLGROUP,pe.DD,pe.DETAILS,pe.DIR,pe.DIV,pe.DL,pe.DT,pe.EMBED,pe.FIELDSET,pe.FIGCAPTION,pe.FIGURE,pe.FOOTER,pe.FORM,pe.FRAME,pe.FRAMESET,pe.H1,pe.H2,pe.H3,pe.H4,pe.H5,pe.H6,pe.HEAD,pe.HEADER,pe.HGROUP,pe.HR,pe.HTML,pe.IFRAME,pe.IMG,pe.INPUT,pe.LI,pe.LINK,pe.LISTING,pe.MAIN,pe.MARQUEE,pe.MENU,pe.META,pe.NAV,pe.NOEMBED,pe.NOFRAMES,pe.NOSCRIPT,pe.OBJECT,pe.OL,pe.P,pe.PARAM,pe.PLAINTEXT,pe.PRE,pe.SCRIPT,pe.SECTION,pe.SELECT,pe.SOURCE,pe.STYLE,pe.SUMMARY,pe.TABLE,pe.TBODY,pe.TD,pe.TEMPLATE,pe.TEXTAREA,pe.TFOOT,pe.TH,pe.THEAD,pe.TITLE,pe.TR,pe.TRACK,pe.UL,pe.WBR,pe.XMP]),[le.MATHML]:new Set([pe.MI,pe.MO,pe.MN,pe.MS,pe.MTEXT,pe.ANNOTATION_XML]),[le.SVG]:new Set([pe.TITLE,pe.FOREIGN_OBJECT,pe.DESC]),[le.XLINK]:new Set,[le.XML]:new Set,[le.XMLNS]:new Set},gf=new Set([pe.H1,pe.H2,pe.H3,pe.H4,pe.H5,pe.H6]);Y.STYLE,Y.SCRIPT,Y.XMP,Y.IFRAME,Y.NOEMBED,Y.NOFRAMES,Y.PLAINTEXT;var I;(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"})(I||(I={}));const wt={DATA:I.DATA,RCDATA:I.RCDATA,RAWTEXT:I.RAWTEXT,SCRIPT_DATA:I.SCRIPT_DATA,PLAINTEXT:I.PLAINTEXT,CDATA_SECTION:I.CDATA_SECTION};function GN(e){return e>=N.DIGIT_0&&e<=N.DIGIT_9}function qs(e){return e>=N.LATIN_CAPITAL_A&&e<=N.LATIN_CAPITAL_Z}function KN(e){return e>=N.LATIN_SMALL_A&&e<=N.LATIN_SMALL_Z}function Gr(e){return KN(e)||qs(e)}function U1(e){return Gr(e)||GN(e)}function $u(e){return e+32}function H1(e){return e===N.SPACE||e===N.LINE_FEED||e===N.TABULATION||e===N.FORM_FEED}function z1(e){return H1(e)||e===N.SOLIDUS||e===N.GREATER_THAN_SIGN}function QN(e){return e===N.NULL?te.nullCharacterReference:e>1114111?te.characterReferenceOutsideUnicodeRange:D1(e)?te.surrogateCharacterReference:F1(e)?te.noncharacterCharacterReference:M1(e)||e===N.CARRIAGE_RETURN?te.controlCharacterReference:null}class XN{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=I.DATA,this.returnState=I.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new MN(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new VN(FN,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(te.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(te.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=QN(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:Ve.START_TAG,tagName:"",tagID:m.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:Ve.END_TAG,tagName:"",tagID:m.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:Ve.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:Ve.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(B1(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(te.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=Ao(t.tagName),t.type===Ve.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(te.endTagWithAttributes),t.selfClosing&&this._err(te.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 Ve.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case Ve.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case Ve.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:Ve.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=H1(t)?Ve.WHITESPACE_CHARACTER:t===N.NULL?Ve.NULL_CHARACTER:Ve.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(Ve.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=I.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Ar.Attribute:Ar.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===I.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===I.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===I.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case I.DATA:{this._stateData(t);break}case I.RCDATA:{this._stateRcdata(t);break}case I.RAWTEXT:{this._stateRawtext(t);break}case I.SCRIPT_DATA:{this._stateScriptData(t);break}case I.PLAINTEXT:{this._statePlaintext(t);break}case I.TAG_OPEN:{this._stateTagOpen(t);break}case I.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case I.TAG_NAME:{this._stateTagName(t);break}case I.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case I.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case I.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case I.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case I.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case I.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case I.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case I.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case I.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case I.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case I.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case I.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case I.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case I.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case I.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case I.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case I.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case I.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case I.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case I.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case I.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case I.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case I.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case I.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case I.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case I.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case I.BOGUS_COMMENT:{this._stateBogusComment(t);break}case I.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case I.COMMENT_START:{this._stateCommentStart(t);break}case I.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case I.COMMENT:{this._stateComment(t);break}case I.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case I.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case I.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case I.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case I.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case I.COMMENT_END:{this._stateCommentEnd(t);break}case I.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case I.DOCTYPE:{this._stateDoctype(t);break}case I.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case I.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case I.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case I.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case I.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case I.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case I.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case I.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case I.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case I.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case I.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case I.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case I.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case I.CDATA_SECTION:{this._stateCdataSection(t);break}case I.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case I.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case I.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case I.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case N.LESS_THAN_SIGN:{this.state=I.TAG_OPEN;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitCodePoint(t);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case N.AMPERSAND:{this._startCharacterReference();break}case N.LESS_THAN_SIGN:{this.state=I.RCDATA_LESS_THAN_SIGN;break}case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case N.LESS_THAN_SIGN:{this.state=I.RAWTEXT_LESS_THAN_SIGN;break}case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_LESS_THAN_SIGN;break}case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Gr(t))this._createStartTagToken(),this.state=I.TAG_NAME,this._stateTagName(t);else switch(t){case N.EXCLAMATION_MARK:{this.state=I.MARKUP_DECLARATION_OPEN;break}case N.SOLIDUS:{this.state=I.END_TAG_OPEN;break}case N.QUESTION_MARK:{this._err(te.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=I.BOGUS_COMMENT,this._stateBogusComment(t);break}case N.EOF:{this._err(te.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(te.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=I.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Gr(t))this._createEndTagToken(),this.state=I.TAG_NAME,this._stateTagName(t);else switch(t){case N.GREATER_THAN_SIGN:{this._err(te.missingEndTagName),this.state=I.DATA;break}case N.EOF:{this._err(te.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(te.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=I.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_ATTRIBUTE_NAME;break}case N.SOLIDUS:{this.state=I.SELF_CLOSING_START_TAG;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentTagToken();break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.tagName+=ft;break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(qs(t)?$u(t):t)}}_stateRcdataLessThanSign(t){t===N.SOLIDUS?this.state=I.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=I.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Gr(t)?(this.state=I.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=I.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 N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=I.BEFORE_ATTRIBUTE_NAME,!1;case N.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=I.SELF_CLOSING_START_TAG,!1;case N.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=I.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===N.SOLIDUS?this.state=I.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=I.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Gr(t)?(this.state=I.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=I.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case N.SOLIDUS:{this.state=I.SCRIPT_DATA_END_TAG_OPEN;break}case N.EXCLAMATION_MARK:{this.state=I.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=I.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Gr(t)?(this.state=I.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===N.HYPHEN_MINUS?(this.state=I.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===N.HYPHEN_MINUS?(this.state=I.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=I.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._err(te.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(te.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case N.HYPHEN_MINUS:{this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case N.GREATER_THAN_SIGN:{this.state=I.SCRIPT_DATA,this._emitChars(">");break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(te.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===N.SOLIDUS?this.state=I.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Gr(t)?(this._emitChars("<"),this.state=I.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Gr(t)?(this.state=I.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&z1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=I.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case N.NULL:{this._err(te.unexpectedNullCharacter),this._emitChars(ft);break}case N.EOF:{this._err(te.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(te.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case N.HYPHEN_MINUS:{this._emitChars("-");break}case N.LESS_THAN_SIGN:{this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case N.GREATER_THAN_SIGN:{this.state=I.SCRIPT_DATA,this._emitChars(">");break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case N.EOF:{this._err(te.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===N.SOLIDUS?(this.state=I.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&z1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=I.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=I.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.SOLIDUS:case N.GREATER_THAN_SIGN:case N.EOF:{this.state=I.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case N.EQUALS_SIGN:{this._err(te.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=I.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=I.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:case N.SOLIDUS:case N.GREATER_THAN_SIGN:case N.EOF:{this._leaveAttrName(),this.state=I.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case N.EQUALS_SIGN:{this._leaveAttrName(),this.state=I.BEFORE_ATTRIBUTE_VALUE;break}case N.QUOTATION_MARK:case N.APOSTROPHE:case N.LESS_THAN_SIGN:{this._err(te.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.currentAttr.name+=ft;break}default:this.currentAttr.name+=String.fromCodePoint(qs(t)?$u(t):t)}}_stateAfterAttributeName(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.SOLIDUS:{this.state=I.SELF_CLOSING_START_TAG;break}case N.EQUALS_SIGN:{this.state=I.BEFORE_ATTRIBUTE_VALUE;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentTagToken();break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=I.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.QUOTATION_MARK:{this.state=I.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this.state=I.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(te.missingAttributeValue),this.state=I.DATA,this.emitCurrentTagToken();break}default:this.state=I.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case N.QUOTATION_MARK:{this.state=I.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case N.APOSTROPHE:{this.state=I.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this._leaveAttrValue(),this.state=I.BEFORE_ATTRIBUTE_NAME;break}case N.AMPERSAND:{this._startCharacterReference();break}case N.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=I.DATA,this.emitCurrentTagToken();break}case N.NULL:{this._err(te.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case N.QUOTATION_MARK:case N.APOSTROPHE:case N.LESS_THAN_SIGN:case N.EQUALS_SIGN:case N.GRAVE_ACCENT:{this._err(te.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this._leaveAttrValue(),this.state=I.BEFORE_ATTRIBUTE_NAME;break}case N.SOLIDUS:{this._leaveAttrValue(),this.state=I.SELF_CLOSING_START_TAG;break}case N.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=I.DATA,this.emitCurrentTagToken();break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:this._err(te.missingWhitespaceBetweenAttributes),this.state=I.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case N.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=I.DATA,this.emitCurrentTagToken();break}case N.EOF:{this._err(te.eofInTag),this._emitEOFToken();break}default:this._err(te.unexpectedSolidusInTag),this.state=I.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentComment(n);break}case N.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case N.NULL:{this._err(te.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=I.COMMENT_START):this._consumeSequenceIfMatch(fn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(fn.DOCTYPE.length+1),this.state=I.DOCTYPE):this._consumeSequenceIfMatch(fn.CDATA_START,!0)?this.inForeignNode?this.state=I.CDATA_SECTION:(this._err(te.cdataInHtmlContent),this._createCommentToken(fn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=I.BOGUS_COMMENT):this._ensureHibernation()||(this._err(te.incorrectlyOpenedComment),this._createCommentToken(2),this.state=I.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_START_DASH;break}case N.GREATER_THAN_SIGN:{this._err(te.abruptClosingOfEmptyComment),this.state=I.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=I.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_END;break}case N.GREATER_THAN_SIGN:{this._err(te.abruptClosingOfEmptyComment),this.state=I.DATA,this.emitCurrentComment(n);break}case N.EOF:{this._err(te.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=I.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_END_DASH;break}case N.LESS_THAN_SIGN:{n.data+="<",this.state=I.COMMENT_LESS_THAN_SIGN;break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.data+=ft;break}case N.EOF:{this._err(te.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case N.EXCLAMATION_MARK:{n.data+="!",this.state=I.COMMENT_LESS_THAN_SIGN_BANG;break}case N.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=I.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===N.HYPHEN_MINUS?this.state=I.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=I.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===N.HYPHEN_MINUS?this.state=I.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=I.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==N.GREATER_THAN_SIGN&&t!==N.EOF&&this._err(te.nestedComment),this.state=I.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{this.state=I.COMMENT_END;break}case N.EOF:{this._err(te.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=I.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentComment(n);break}case N.EXCLAMATION_MARK:{this.state=I.COMMENT_END_BANG;break}case N.HYPHEN_MINUS:{n.data+="-";break}case N.EOF:{this._err(te.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=I.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case N.HYPHEN_MINUS:{n.data+="--!",this.state=I.COMMENT_END_DASH;break}case N.GREATER_THAN_SIGN:{this._err(te.incorrectlyClosedComment),this.state=I.DATA,this.emitCurrentComment(n);break}case N.EOF:{this._err(te.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=I.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_DOCTYPE_NAME;break}case N.GREATER_THAN_SIGN:{this.state=I.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case N.EOF:{this._err(te.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingWhitespaceBeforeDoctypeName),this.state=I.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(qs(t))this._createDoctypeToken(String.fromCharCode($u(t))),this.state=I.DOCTYPE_NAME;else switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.NULL:{this._err(te.unexpectedNullCharacter),this._createDoctypeToken(ft),this.state=I.DOCTYPE_NAME;break}case N.GREATER_THAN_SIGN:{this._err(te.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(te.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=I.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.AFTER_DOCTYPE_NAME;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.name+=ft;break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(qs(t)?$u(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(fn.PUBLIC,!1)?this.state=I.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(fn.SYSTEM,!1)?this.state=I.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(te.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case N.QUOTATION_MARK:{this._err(te.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this._err(te.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(te.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.QUOTATION_MARK:{n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{n.publicId="",this.state=I.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(te.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case N.QUOTATION_MARK:{this.state=I.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.publicId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(te.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(te.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 N.APOSTROPHE:{this.state=I.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.publicId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(te.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(te.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 N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case N.GREATER_THAN_SIGN:{this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.QUOTATION_MARK:{this._err(te.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this._err(te.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.QUOTATION_MARK:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:{this.state=I.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case N.QUOTATION_MARK:{this._err(te.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{this._err(te.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(te.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.QUOTATION_MARK:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case N.APOSTROPHE:{n.systemId="",this.state=I.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case N.GREATER_THAN_SIGN:{this._err(te.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.DATA,this.emitCurrentDoctype(n);break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case N.QUOTATION_MARK:{this.state=I.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.systemId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(te.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(te.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 N.APOSTROPHE:{this.state=I.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case N.NULL:{this._err(te.unexpectedNullCharacter),n.systemId+=ft;break}case N.GREATER_THAN_SIGN:{this._err(te.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(te.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 N.SPACE:case N.LINE_FEED:case N.TABULATION:case N.FORM_FEED:break;case N.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.EOF:{this._err(te.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(te.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=I.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case N.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=I.DATA;break}case N.NULL:{this._err(te.unexpectedNullCharacter);break}case N.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case N.RIGHT_SQUARE_BRACKET:{this.state=I.CDATA_SECTION_BRACKET;break}case N.EOF:{this._err(te.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===N.RIGHT_SQUARE_BRACKET?this.state=I.CDATA_SECTION_END:(this._emitChars("]"),this.state=I.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case N.GREATER_THAN_SIGN:{this.state=I.DATA;break}case N.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=I.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(N.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&U1(this.preprocessor.peek(1))?I.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){U1(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===N.SEMICOLON&&this._err(te.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const j1=new Set([m.DD,m.DT,m.LI,m.OPTGROUP,m.OPTION,m.P,m.RB,m.RP,m.RT,m.RTC]),$1=new Set([...j1,m.CAPTION,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]),Vu=new Set([m.APPLET,m.CAPTION,m.HTML,m.MARQUEE,m.OBJECT,m.TABLE,m.TD,m.TEMPLATE,m.TH]),JN=new Set([...Vu,m.OL,m.UL]),ZN=new Set([...Vu,m.BUTTON]),V1=new Set([m.ANNOTATION_XML,m.MI,m.MN,m.MO,m.MS,m.MTEXT]),q1=new Set([m.DESC,m.FOREIGN_OBJECT,m.TITLE]),eO=new Set([m.TR,m.TEMPLATE,m.HTML]),tO=new Set([m.TBODY,m.TFOOT,m.THEAD,m.TEMPLATE,m.HTML]),nO=new Set([m.TABLE,m.TEMPLATE,m.HTML]),rO=new Set([m.TD,m.TH]);class iO{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=m.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===m.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===le.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])!==le.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(gf,le.HTML)}popUntilTableCellPopped(){this.popUntilPopped(rO,le.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(nO,le.HTML)}clearBackToTableBodyContext(){this.clearBackTo(tO,le.HTML)}clearBackToTableRowContext(){this.clearBackTo(eO,le.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]===m.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]===m.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 le.HTML:{if(o===t)return!0;if(n.has(o))return!1;break}case le.SVG:{if(q1.has(o))return!1;break}case le.MATHML:{if(V1.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Vu)}hasInListItemScope(t){return this.hasInDynamicScope(t,JN)}hasInButtonScope(t){return this.hasInDynamicScope(t,ZN)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case le.HTML:{if(gf.has(n))return!0;if(Vu.has(n))return!1;break}case le.SVG:{if(q1.has(n))return!1;break}case le.MATHML:{if(V1.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===le.HTML)switch(this.tagIDs[n]){case t:return!0;case m.TABLE:case m.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===le.HTML)switch(this.tagIDs[t]){case m.TBODY:case m.THEAD:case m.TFOOT:return!0;case m.TABLE:case m.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===le.HTML)switch(this.tagIDs[n]){case t:return!0;case m.OPTION:case m.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&j1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&$1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&$1.has(this.currentTagId);)this.pop()}}const Ef=3;var cr;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(cr||(cr={}));const Y1={type:cr.Marker};class oO{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===cr.Marker)break;const{element:h}=d;if(this.treeAdapter.getTagName(h)===a&&this.treeAdapter.getNamespaceURI(h)===u){const p=this.treeAdapter.getAttrList(h);p.length===o&&r.push({idx:c,attrs:p})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<Ef)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<Ef)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>=Ef&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(Y1)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:cr.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:cr.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(Y1);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===cr.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===cr.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===cr.Element&&n.element===t)}}const Kr={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};Kr.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(Kr.isTextNode(n)){n.value+=t;return}}Kr.appendChild(e,Kr.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Kr.isTextNode(r)?r.value+=t:Kr.insertBefore(e,Kr.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=B(B({},e.sourceCodeLocation),t)}},W1="html",sO="about:legacy-compat",aO="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",G1=["+//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//"],uO=[...G1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],lO=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),K1=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],cO=[...K1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function Q1(e,t){return t.some(n=>e.startsWith(n))}function dO(e){return e.name===W1&&e.publicId===null&&(e.systemId===null||e.systemId===sO)}function fO(e){if(e.name!==W1)return Ln.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===aO)return Ln.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),lO.has(n))return Ln.QUIRKS;let r=t===null?uO:G1;if(Q1(n,r))return Ln.QUIRKS;if(r=t===null?K1:cO,Q1(n,r))return Ln.LIMITED_QUIRKS}return Ln.NO_QUIRKS}const X1={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},hO="definitionurl",pO="definitionURL",mO=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])),gO=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:le.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:le.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:le.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:le.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:le.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:le.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:le.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:le.XML}],["xml:space",{prefix:"xml",name:"space",namespace:le.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:le.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:le.XMLNS}]]),EO=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])),yO=new Set([m.B,m.BIG,m.BLOCKQUOTE,m.BODY,m.BR,m.CENTER,m.CODE,m.DD,m.DIV,m.DL,m.DT,m.EM,m.EMBED,m.H1,m.H2,m.H3,m.H4,m.H5,m.H6,m.HEAD,m.HR,m.I,m.IMG,m.LI,m.LISTING,m.MENU,m.META,m.NOBR,m.OL,m.P,m.PRE,m.RUBY,m.S,m.SMALL,m.SPAN,m.STRONG,m.STRIKE,m.SUB,m.SUP,m.TABLE,m.TT,m.U,m.UL,m.VAR]);function bO(e){const t=e.tagID;return t===m.FONT&&e.attrs.some(({name:r})=>r===Di.COLOR||r===Di.SIZE||r===Di.FACE)||yO.has(t)}function J1(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===hO){e.attrs[t].name=pO;break}}function Z1(e){for(let t=0;t<e.attrs.length;t++){const n=mO.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function yf(e){for(let t=0;t<e.attrs.length;t++){const n=gO.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 TO(e){const t=EO.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Ao(e.tagName))}function xO(e,t){return t===le.MATHML&&(e===m.MI||e===m.MO||e===m.MN||e===m.MS||e===m.MTEXT)}function wO(e,t,n){if(t===le.MATHML&&e===m.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Di.ENCODING){const o=n[r].value.toLowerCase();return o===X1.TEXT_HTML||o===X1.APPLICATION_XML}}return t===le.SVG&&(e===m.FOREIGN_OBJECT||e===m.DESC||e===m.TITLE)}function _O(e,t,n,r){return(!r||r===le.HTML)&&wO(e,t,n)||(!r||r===le.MATHML)&&xO(e,t)}const vO="hidden",SO=8,AO=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 CO={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},eE=new Set([m.TABLE,m.TBODY,m.TFOOT,m.THEAD,m.TR]),tE={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Kr,onParseError:null};class nE{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=B(B({},tE),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 XN(this.options,this),this.activeFormattingElements=new oO(this.treeAdapter),this.fragmentContextID=r?Ao(this.treeAdapter.getTagName(r)):m.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new iO(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=B(B({},tE),n);t!=null||(t=r.treeAdapter.createElement(Y.TEMPLATE,le.HTML,[]));const o=r.treeAdapter.createElement("documentmock",le.HTML,[]),a=new this(r,o,t);return a.fragmentContextID===m.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:CO,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)===le.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,le.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=wt.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)!==le.HTML))switch(this.fragmentContextID){case m.TITLE:case m.TEXTAREA:{this.tokenizer.state=wt.RCDATA;break}case m.STYLE:case m.XMP:case m.IFRAME:case m.NOEMBED:case m.NOFRAMES:case m.NOSCRIPT:{this.tokenizer.state=wt.RAWTEXT;break}case m.SCRIPT:{this.tokenizer.state=wt.SCRIPT_DATA;break}case m.PLAINTEXT:{this.tokenizer.state=wt.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&&ae(B({},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,le.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,le.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,le.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,m.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:p}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(u,{endLine:d,endCol:h,endOffset:p})}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===Ve.END_TAG&&o===n.tagName?{endTag:B({},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===m.SVG&&this.treeAdapter.getTagName(n)===Y.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===le.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===m.MGLYPH||t.tagID===m.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,le.HTML)}_processToken(t){switch(t.type){case Ve.CHARACTER:{this.onCharacter(t);break}case Ve.NULL_CHARACTER:{this.onNullCharacter(t);break}case Ve.COMMENT:{this.onComment(t);break}case Ve.DOCTYPE:{this.onDoctype(t);break}case Ve.START_TAG:{this._processStartTag(t);break}case Ve.END_TAG:{this.onEndTag(t);break}case Ve.EOF:{this.onEof(t);break}case Ve.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const o=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return _O(t,o,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===cr.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(m.P),this.openElements.popUntilTagNamePopped(m.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case m.TR:{this.insertionMode=L.IN_ROW;return}case m.TBODY:case m.THEAD:case m.TFOOT:{this.insertionMode=L.IN_TABLE_BODY;return}case m.CAPTION:{this.insertionMode=L.IN_CAPTION;return}case m.COLGROUP:{this.insertionMode=L.IN_COLUMN_GROUP;return}case m.TABLE:{this.insertionMode=L.IN_TABLE;return}case m.BODY:{this.insertionMode=L.IN_BODY;return}case m.FRAMESET:{this.insertionMode=L.IN_FRAMESET;return}case m.SELECT:{this._resetInsertionModeForSelect(t);return}case m.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case m.HTML:{this.insertionMode=this.headElement?L.AFTER_HEAD:L.BEFORE_HEAD;return}case m.TD:case m.TH:{if(t>0){this.insertionMode=L.IN_CELL;return}break}case m.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===m.TEMPLATE)break;if(r===m.TABLE){this.insertionMode=L.IN_SELECT_IN_TABLE;return}}this.insertionMode=L.IN_SELECT}_isElementCausesFosterParenting(t){return eE.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 m.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===le.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case m.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 WN[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){rR(this,t);return}switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{Ws(this,t);break}case L.BEFORE_HEAD:{Gs(this,t);break}case L.IN_HEAD:{Ks(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Qs(this,t);break}case L.AFTER_HEAD:{Xs(this,t);break}case L.IN_BODY:case L.IN_CAPTION:case L.IN_CELL:case L.IN_TEMPLATE:{iE(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:{wf(this,t);break}case L.IN_TABLE_TEXT:{fE(this,t);break}case L.IN_COLUMN_GROUP:{Wu(this,t);break}case L.AFTER_BODY:{Qu(this,t);break}case L.AFTER_AFTER_BODY:{Xu(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){nR(this,t);return}switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{Ws(this,t);break}case L.BEFORE_HEAD:{Gs(this,t);break}case L.IN_HEAD:{Ks(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Qs(this,t);break}case L.AFTER_HEAD:{Xs(this,t);break}case L.TEXT:{this._insertCharacters(t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{wf(this,t);break}case L.IN_COLUMN_GROUP:{Wu(this,t);break}case L.AFTER_BODY:{Qu(this,t);break}case L.AFTER_AFTER_BODY:{Xu(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){Tf(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:{Tf(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.AFTER_BODY:{LO(this,t);break}case L.AFTER_AFTER_BODY:case L.AFTER_AFTER_FRAMESET:{DO(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case L.INITIAL:{MO(this,t);break}case L.BEFORE_HEAD:case L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:{this._err(t,te.misplacedDoctype);break}case L.IN_TABLE_TEXT:{ea(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,te.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?iR(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{FO(this,t);break}case L.BEFORE_HEAD:{UO(this,t);break}case L.IN_HEAD:{Wn(this,t);break}case L.IN_HEAD_NO_SCRIPT:{jO(this,t);break}case L.AFTER_HEAD:{VO(this,t);break}case L.IN_BODY:{Kt(this,t);break}case L.IN_TABLE:{Co(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.IN_CAPTION:{HI(this,t);break}case L.IN_COLUMN_GROUP:{_f(this,t);break}case L.IN_TABLE_BODY:{Gu(this,t);break}case L.IN_ROW:{Ku(this,t);break}case L.IN_CELL:{$I(this,t);break}case L.IN_SELECT:{mE(this,t);break}case L.IN_SELECT_IN_TABLE:{qI(this,t);break}case L.IN_TEMPLATE:{WI(this,t);break}case L.AFTER_BODY:{KI(this,t);break}case L.IN_FRAMESET:{QI(this,t);break}case L.AFTER_FRAMESET:{JI(this,t);break}case L.AFTER_AFTER_BODY:{eR(this,t);break}case L.AFTER_AFTER_FRAMESET:{tR(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?oR(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{BO(this,t);break}case L.BEFORE_HEAD:{HO(this,t);break}case L.IN_HEAD:{zO(this,t);break}case L.IN_HEAD_NO_SCRIPT:{$O(this,t);break}case L.AFTER_HEAD:{qO(this,t);break}case L.IN_BODY:{Yu(this,t);break}case L.TEXT:{OI(this,t);break}case L.IN_TABLE:{Js(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.IN_CAPTION:{zI(this,t);break}case L.IN_COLUMN_GROUP:{jI(this,t);break}case L.IN_TABLE_BODY:{vf(this,t);break}case L.IN_ROW:{pE(this,t);break}case L.IN_CELL:{VI(this,t);break}case L.IN_SELECT:{gE(this,t);break}case L.IN_SELECT_IN_TABLE:{YI(this,t);break}case L.IN_TEMPLATE:{GI(this,t);break}case L.AFTER_BODY:{yE(this,t);break}case L.IN_FRAMESET:{XI(this,t);break}case L.AFTER_FRAMESET:{ZI(this,t);break}case L.AFTER_AFTER_BODY:{Xu(this,t);break}}}onEof(t){switch(this.insertionMode){case L.INITIAL:{Ys(this,t);break}case L.BEFORE_HTML:{Ws(this,t);break}case L.BEFORE_HEAD:{Gs(this,t);break}case L.IN_HEAD:{Ks(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Qs(this,t);break}case L.AFTER_HEAD:{Xs(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:{cE(this,t);break}case L.TEXT:{II(this,t);break}case L.IN_TABLE_TEXT:{ea(this,t);break}case L.IN_TEMPLATE:{EE(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:{xf(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===N.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:{rE(this,t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{wf(this,t);break}case L.IN_TABLE_TEXT:{dE(this,t);break}}}}function kO(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):lE(e,t),n}function NO(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 OO(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>=AO;!c||d?(d&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(u)):(u=IO(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(u,r),r=u)}return r}function IO(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 RO(e,t,n){const r=e.treeAdapter.getTagName(t),o=Ao(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);o===m.TEMPLATE&&a===le.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function PO(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 bf(e,t){for(let n=0;n<SO;n++){const r=kO(e,t);if(!r)break;const o=NO(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const a=OO(e,o,r.element),u=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),u&&RO(e,u,a),PO(e,o,r)}}function Tf(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function LO(e,t){e._appendCommentNode(t,e.openElements.items[0])}function DO(e,t){e._appendCommentNode(t,e.document)}function xf(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 MO(e,t){e._setDocumentType(t);const n=t.forceQuirks?Ln.QUIRKS:fO(t);dO(t)||e._err(t,te.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=L.BEFORE_HTML}function Ys(e,t){e._err(t,te.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Ln.QUIRKS),e.insertionMode=L.BEFORE_HTML,e._processToken(t)}function FO(e,t){t.tagID===m.HTML?(e._insertElement(t,le.HTML),e.insertionMode=L.BEFORE_HEAD):Ws(e,t)}function BO(e,t){const n=t.tagID;(n===m.HTML||n===m.HEAD||n===m.BODY||n===m.BR)&&Ws(e,t)}function Ws(e,t){e._insertFakeRootElement(),e.insertionMode=L.BEFORE_HEAD,e._processToken(t)}function UO(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.HEAD:{e._insertElement(t,le.HTML),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD;break}default:Gs(e,t)}}function HO(e,t){const n=t.tagID;n===m.HEAD||n===m.BODY||n===m.HTML||n===m.BR?Gs(e,t):e._err(t,te.endTagWithoutMatchingOpenElement)}function Gs(e,t){e._insertFakeElement(Y.HEAD,m.HEAD),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD,e._processToken(t)}function Wn(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.BASE:case m.BASEFONT:case m.BGSOUND:case m.LINK:case m.META:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.TITLE:{e._switchToTextParsing(t,wt.RCDATA);break}case m.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,wt.RAWTEXT):(e._insertElement(t,le.HTML),e.insertionMode=L.IN_HEAD_NO_SCRIPT);break}case m.NOFRAMES:case m.STYLE:{e._switchToTextParsing(t,wt.RAWTEXT);break}case m.SCRIPT:{e._switchToTextParsing(t,wt.SCRIPT_DATA);break}case m.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=L.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(L.IN_TEMPLATE);break}case m.HEAD:{e._err(t,te.misplacedStartTagForHeadElement);break}default:Ks(e,t)}}function zO(e,t){switch(t.tagID){case m.HEAD:{e.openElements.pop(),e.insertionMode=L.AFTER_HEAD;break}case m.BODY:case m.BR:case m.HTML:{Ks(e,t);break}case m.TEMPLATE:{Mi(e,t);break}default:e._err(t,te.endTagWithoutMatchingOpenElement)}}function Mi(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==m.TEMPLATE&&e._err(t,te.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,te.endTagWithoutMatchingOpenElement)}function Ks(e,t){e.openElements.pop(),e.insertionMode=L.AFTER_HEAD,e._processToken(t)}function jO(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.BASEFONT:case m.BGSOUND:case m.HEAD:case m.LINK:case m.META:case m.NOFRAMES:case m.STYLE:{Wn(e,t);break}case m.NOSCRIPT:{e._err(t,te.nestedNoscriptInHead);break}default:Qs(e,t)}}function $O(e,t){switch(t.tagID){case m.NOSCRIPT:{e.openElements.pop(),e.insertionMode=L.IN_HEAD;break}case m.BR:{Qs(e,t);break}default:e._err(t,te.endTagWithoutMatchingOpenElement)}}function Qs(e,t){const n=t.type===Ve.EOF?te.openElementsLeftAfterEof:te.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=L.IN_HEAD,e._processToken(t)}function VO(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.BODY:{e._insertElement(t,le.HTML),e.framesetOk=!1,e.insertionMode=L.IN_BODY;break}case m.FRAMESET:{e._insertElement(t,le.HTML),e.insertionMode=L.IN_FRAMESET;break}case m.BASE:case m.BASEFONT:case m.BGSOUND:case m.LINK:case m.META:case m.NOFRAMES:case m.SCRIPT:case m.STYLE:case m.TEMPLATE:case m.TITLE:{e._err(t,te.abandonedHeadElementChild),e.openElements.push(e.headElement,m.HEAD),Wn(e,t),e.openElements.remove(e.headElement);break}case m.HEAD:{e._err(t,te.misplacedStartTagForHeadElement);break}default:Xs(e,t)}}function qO(e,t){switch(t.tagID){case m.BODY:case m.HTML:case m.BR:{Xs(e,t);break}case m.TEMPLATE:{Mi(e,t);break}default:e._err(t,te.endTagWithoutMatchingOpenElement)}}function Xs(e,t){e._insertFakeElement(Y.BODY,m.BODY),e.insertionMode=L.IN_BODY,qu(e,t)}function qu(e,t){switch(t.type){case Ve.CHARACTER:{iE(e,t);break}case Ve.WHITESPACE_CHARACTER:{rE(e,t);break}case Ve.COMMENT:{Tf(e,t);break}case Ve.START_TAG:{Kt(e,t);break}case Ve.END_TAG:{Yu(e,t);break}case Ve.EOF:{cE(e,t);break}}}function rE(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function iE(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function YO(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function WO(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function GO(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_FRAMESET)}function KO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML)}function QO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&gf.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,le.HTML)}function XO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function JO(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),n||(e.formElement=e.openElements.current))}function ZO(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===m.LI&&o===m.LI||(n===m.DD||n===m.DT)&&(o===m.DD||o===m.DT)){e.openElements.generateImpliedEndTagsWithExclusion(o),e.openElements.popUntilTagNamePopped(o);break}if(o!==m.ADDRESS&&o!==m.DIV&&o!==m.P&&e._isSpecialElement(e.openElements.items[r],o))break}e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML)}function eI(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.tokenizer.state=wt.PLAINTEXT}function tI(e,t){e.openElements.hasInScope(m.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.framesetOk=!1}function nI(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(Y.A);n&&(bf(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function rI(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function iI(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(m.NOBR)&&(bf(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function oI(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function sI(e,t){e.treeAdapter.getDocumentMode(e.document)!==Ln.QUIRKS&&e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.framesetOk=!1,e.insertionMode=L.IN_TABLE}function oE(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function sE(e){const t=B1(e,Di.TYPE);return t!=null&&t.toLowerCase()===vO}function aI(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),sE(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function uI(e,t){e._appendElement(t,le.HTML),t.ackSelfClosing=!0}function lI(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function cI(e,t){t.tagName=Y.IMG,t.tagID=m.IMG,oE(e,t)}function dI(e,t){e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.tokenizer.state=wt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=L.TEXT}function fI(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,wt.RAWTEXT)}function hI(e,t){e.framesetOk=!1,e._switchToTextParsing(t,wt.RAWTEXT)}function aE(e,t){e._switchToTextParsing(t,wt.RAWTEXT)}function pI(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.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 mI(e,t){e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function gI(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,le.HTML)}function EI(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(m.RTC),e._insertElement(t,le.HTML)}function yI(e,t){e._reconstructActiveFormattingElements(),J1(t),yf(t),t.selfClosing?e._appendElement(t,le.MATHML):e._insertElement(t,le.MATHML),t.ackSelfClosing=!0}function bI(e,t){e._reconstructActiveFormattingElements(),Z1(t),yf(t),t.selfClosing?e._appendElement(t,le.SVG):e._insertElement(t,le.SVG),t.ackSelfClosing=!0}function uE(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function Kt(e,t){switch(t.tagID){case m.I:case m.S:case m.B:case m.U:case m.EM:case m.TT:case m.BIG:case m.CODE:case m.FONT:case m.SMALL:case m.STRIKE:case m.STRONG:{rI(e,t);break}case m.A:{nI(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{QO(e,t);break}case m.P:case m.DL:case m.OL:case m.UL:case m.DIV:case m.DIR:case m.NAV:case m.MAIN:case m.MENU:case m.ASIDE:case m.CENTER:case m.FIGURE:case m.FOOTER:case m.HEADER:case m.HGROUP:case m.DIALOG:case m.DETAILS:case m.ADDRESS:case m.ARTICLE:case m.SEARCH:case m.SECTION:case m.SUMMARY:case m.FIELDSET:case m.BLOCKQUOTE:case m.FIGCAPTION:{KO(e,t);break}case m.LI:case m.DD:case m.DT:{ZO(e,t);break}case m.BR:case m.IMG:case m.WBR:case m.AREA:case m.EMBED:case m.KEYGEN:{oE(e,t);break}case m.HR:{lI(e,t);break}case m.RB:case m.RTC:{gI(e,t);break}case m.RT:case m.RP:{EI(e,t);break}case m.PRE:case m.LISTING:{XO(e,t);break}case m.XMP:{fI(e,t);break}case m.SVG:{bI(e,t);break}case m.HTML:{YO(e,t);break}case m.BASE:case m.LINK:case m.META:case m.STYLE:case m.TITLE:case m.SCRIPT:case m.BGSOUND:case m.BASEFONT:case m.TEMPLATE:{Wn(e,t);break}case m.BODY:{WO(e,t);break}case m.FORM:{JO(e,t);break}case m.NOBR:{iI(e,t);break}case m.MATH:{yI(e,t);break}case m.TABLE:{sI(e,t);break}case m.INPUT:{aI(e,t);break}case m.PARAM:case m.TRACK:case m.SOURCE:{uI(e,t);break}case m.IMAGE:{cI(e,t);break}case m.BUTTON:{tI(e,t);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{oI(e,t);break}case m.IFRAME:{hI(e,t);break}case m.SELECT:{pI(e,t);break}case m.OPTION:case m.OPTGROUP:{mI(e,t);break}case m.NOEMBED:case m.NOFRAMES:{aE(e,t);break}case m.FRAMESET:{GO(e,t);break}case m.TEXTAREA:{dI(e,t);break}case m.NOSCRIPT:{e.options.scriptingEnabled?aE(e,t):uE(e,t);break}case m.PLAINTEXT:{eI(e,t);break}case m.COL:case m.TH:case m.TD:case m.TR:case m.HEAD:case m.FRAME:case m.TBODY:case m.TFOOT:case m.THEAD:case m.CAPTION:case m.COLGROUP:break;default:uE(e,t)}}function TI(e,t){if(e.openElements.hasInScope(m.BODY)&&(e.insertionMode=L.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function xI(e,t){e.openElements.hasInScope(m.BODY)&&(e.insertionMode=L.AFTER_BODY,yE(e,t))}function wI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function _I(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(m.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(m.FORM):n&&e.openElements.remove(n))}function vI(e){e.openElements.hasInButtonScope(m.P)||e._insertFakeElement(Y.P,m.P),e._closePElement()}function SI(e){e.openElements.hasInListItemScope(m.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(m.LI),e.openElements.popUntilTagNamePopped(m.LI))}function AI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function CI(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function kI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function NI(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(Y.BR,m.BR),e.openElements.pop(),e.framesetOk=!1}function lE(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!==m.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 Yu(e,t){switch(t.tagID){case m.A:case m.B:case m.I:case m.S:case m.U:case m.EM:case m.TT:case m.BIG:case m.CODE:case m.FONT:case m.NOBR:case m.SMALL:case m.STRIKE:case m.STRONG:{bf(e,t);break}case m.P:{vI(e);break}case m.DL:case m.UL:case m.OL:case m.DIR:case m.DIV:case m.NAV:case m.PRE:case m.MAIN:case m.MENU:case m.ASIDE:case m.BUTTON:case m.CENTER:case m.FIGURE:case m.FOOTER:case m.HEADER:case m.HGROUP:case m.DIALOG:case m.ADDRESS:case m.ARTICLE:case m.DETAILS:case m.SEARCH:case m.SECTION:case m.SUMMARY:case m.LISTING:case m.FIELDSET:case m.BLOCKQUOTE:case m.FIGCAPTION:{wI(e,t);break}case m.LI:{SI(e);break}case m.DD:case m.DT:{AI(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{CI(e);break}case m.BR:{NI(e);break}case m.BODY:{TI(e,t);break}case m.HTML:{xI(e,t);break}case m.FORM:{_I(e);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{kI(e,t);break}case m.TEMPLATE:{Mi(e,t);break}default:lE(e,t)}}function cE(e,t){e.tmplInsertionModeStack.length>0?EE(e,t):xf(e,t)}function OI(e,t){var n;t.tagID===m.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function II(e,t){e._err(t,te.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function wf(e,t){if(e.openElements.currentTagId!==void 0&&eE.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 Ve.CHARACTER:{fE(e,t);break}case Ve.WHITESPACE_CHARACTER:{dE(e,t);break}}else Zs(e,t)}function RI(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_CAPTION}function PI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_COLUMN_GROUP}function LI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.COLGROUP,m.COLGROUP),e.insertionMode=L.IN_COLUMN_GROUP,_f(e,t)}function DI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_TABLE_BODY}function MI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(Y.TBODY,m.TBODY),e.insertionMode=L.IN_TABLE_BODY,Gu(e,t)}function FI(e,t){e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function BI(e,t){sE(t)?e._appendElement(t,le.HTML):Zs(e,t),t.ackSelfClosing=!0}function UI(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,le.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Co(e,t){switch(t.tagID){case m.TD:case m.TH:case m.TR:{MI(e,t);break}case m.STYLE:case m.SCRIPT:case m.TEMPLATE:{Wn(e,t);break}case m.COL:{LI(e,t);break}case m.FORM:{UI(e,t);break}case m.TABLE:{FI(e,t);break}case m.TBODY:case m.TFOOT:case m.THEAD:{DI(e,t);break}case m.INPUT:{BI(e,t);break}case m.CAPTION:{RI(e,t);break}case m.COLGROUP:{PI(e,t);break}default:Zs(e,t)}}function Js(e,t){switch(t.tagID){case m.TABLE:{e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode());break}case m.TEMPLATE:{Mi(e,t);break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:case m.TBODY:case m.TD:case m.TFOOT:case m.TH:case m.THEAD:case m.TR:break;default:Zs(e,t)}}function Zs(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,qu(e,t),e.fosterParentingEnabled=n}function dE(e,t){e.pendingCharacterTokens.push(t)}function fE(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function ea(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Zs(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const hE=new Set([m.CAPTION,m.COL,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]);function HI(e,t){const n=t.tagID;hE.has(n)?e.openElements.hasInTableScope(m.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,Co(e,t)):Kt(e,t)}function zI(e,t){const n=t.tagID;switch(n){case m.CAPTION:case m.TABLE:{e.openElements.hasInTableScope(m.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,n===m.TABLE&&Js(e,t));break}case m.BODY:case m.COL:case m.COLGROUP:case m.HTML:case m.TBODY:case m.TD:case m.TFOOT:case m.TH:case m.THEAD:case m.TR:break;default:Yu(e,t)}}function _f(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.COL:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.TEMPLATE:{Wn(e,t);break}default:Wu(e,t)}}function jI(e,t){switch(t.tagID){case m.COLGROUP:{e.openElements.currentTagId===m.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE);break}case m.TEMPLATE:{Mi(e,t);break}case m.COL:break;default:Wu(e,t)}}function Wu(e,t){e.openElements.currentTagId===m.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE,e._processToken(t))}function Gu(e,t){switch(t.tagID){case m.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_ROW;break}case m.TH:case m.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(Y.TR,m.TR),e.insertionMode=L.IN_ROW,Ku(e,t);break}case m.CAPTION:case m.COL:case m.COLGROUP:case m.TBODY:case m.TFOOT:case m.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE,Co(e,t));break}default:Co(e,t)}}function vf(e,t){const n=t.tagID;switch(t.tagID){case m.TBODY:case m.TFOOT:case m.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE);break}case m.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE,Js(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:case m.TD:case m.TH:case m.TR:break;default:Js(e,t)}}function Ku(e,t){switch(t.tagID){case m.TH:case m.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_CELL,e.activeFormattingElements.insertMarker();break}case m.CAPTION:case m.COL:case m.COLGROUP:case m.TBODY:case m.TFOOT:case m.THEAD:case m.TR:{e.openElements.hasInTableScope(m.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,Gu(e,t));break}default:Co(e,t)}}function pE(e,t){switch(t.tagID){case m.TR:{e.openElements.hasInTableScope(m.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY);break}case m.TABLE:{e.openElements.hasInTableScope(m.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,vf(e,t));break}case m.TBODY:case m.TFOOT:case m.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(m.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=L.IN_TABLE_BODY,vf(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:case m.TD:case m.TH:break;default:Js(e,t)}}function $I(e,t){const n=t.tagID;hE.has(n)?(e.openElements.hasInTableScope(m.TD)||e.openElements.hasInTableScope(m.TH))&&(e._closeTableCell(),Ku(e,t)):Kt(e,t)}function VI(e,t){const n=t.tagID;switch(n){case m.TD:case m.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_ROW);break}case m.TABLE:case m.TBODY:case m.TFOOT:case m.THEAD:case m.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),pE(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:break;default:Yu(e,t)}}function mE(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.OPTION:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e._insertElement(t,le.HTML);break}case m.OPTGROUP:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e.openElements.currentTagId===m.OPTGROUP&&e.openElements.pop(),e._insertElement(t,le.HTML);break}case m.HR:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e.openElements.currentTagId===m.OPTGROUP&&e.openElements.pop(),e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.INPUT:case m.KEYGEN:case m.TEXTAREA:case m.SELECT:{e.openElements.hasInSelectScope(m.SELECT)&&(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode(),t.tagID!==m.SELECT&&e._processStartTag(t));break}case m.SCRIPT:case m.TEMPLATE:{Wn(e,t);break}}}function gE(e,t){switch(t.tagID){case m.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===m.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===m.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===m.OPTGROUP&&e.openElements.pop();break}case m.OPTION:{e.openElements.currentTagId===m.OPTION&&e.openElements.pop();break}case m.SELECT:{e.openElements.hasInSelectScope(m.SELECT)&&(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode());break}case m.TEMPLATE:{Mi(e,t);break}}}function qI(e,t){const n=t.tagID;n===m.CAPTION||n===m.TABLE||n===m.TBODY||n===m.TFOOT||n===m.THEAD||n===m.TR||n===m.TD||n===m.TH?(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode(),e._processStartTag(t)):mE(e,t)}function YI(e,t){const n=t.tagID;n===m.CAPTION||n===m.TABLE||n===m.TBODY||n===m.TFOOT||n===m.THEAD||n===m.TR||n===m.TD||n===m.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(m.SELECT),e._resetInsertionMode(),e.onEndTag(t)):gE(e,t)}function WI(e,t){switch(t.tagID){case m.BASE:case m.BASEFONT:case m.BGSOUND:case m.LINK:case m.META:case m.NOFRAMES:case m.SCRIPT:case m.STYLE:case m.TEMPLATE:case m.TITLE:{Wn(e,t);break}case m.CAPTION:case m.COLGROUP:case m.TBODY:case m.TFOOT:case m.THEAD:{e.tmplInsertionModeStack[0]=L.IN_TABLE,e.insertionMode=L.IN_TABLE,Co(e,t);break}case m.COL:{e.tmplInsertionModeStack[0]=L.IN_COLUMN_GROUP,e.insertionMode=L.IN_COLUMN_GROUP,_f(e,t);break}case m.TR:{e.tmplInsertionModeStack[0]=L.IN_TABLE_BODY,e.insertionMode=L.IN_TABLE_BODY,Gu(e,t);break}case m.TD:case m.TH:{e.tmplInsertionModeStack[0]=L.IN_ROW,e.insertionMode=L.IN_ROW,Ku(e,t);break}default:e.tmplInsertionModeStack[0]=L.IN_BODY,e.insertionMode=L.IN_BODY,Kt(e,t)}}function GI(e,t){t.tagID===m.TEMPLATE&&Mi(e,t)}function EE(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):xf(e,t)}function KI(e,t){t.tagID===m.HTML?Kt(e,t):Qu(e,t)}function yE(e,t){var n;if(t.tagID===m.HTML){if(e.fragmentContext||(e.insertionMode=L.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===m.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 Qu(e,t)}function Qu(e,t){e.insertionMode=L.IN_BODY,qu(e,t)}function QI(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.FRAMESET:{e._insertElement(t,le.HTML);break}case m.FRAME:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.NOFRAMES:{Wn(e,t);break}}}function XI(e,t){t.tagID===m.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==m.FRAMESET&&(e.insertionMode=L.AFTER_FRAMESET))}function JI(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function ZI(e,t){t.tagID===m.HTML&&(e.insertionMode=L.AFTER_AFTER_FRAMESET)}function eR(e,t){t.tagID===m.HTML?Kt(e,t):Xu(e,t)}function Xu(e,t){e.insertionMode=L.IN_BODY,qu(e,t)}function tR(e,t){switch(t.tagID){case m.HTML:{Kt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function nR(e,t){t.chars=ft,e._insertCharacters(t)}function rR(e,t){e._insertCharacters(t),e.framesetOk=!1}function bE(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==le.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function iR(e,t){if(bO(t))bE(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===le.MATHML?J1(t):r===le.SVG&&(TO(t),Z1(t)),yf(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function oR(e,t){if(t.tagID===m.P||t.tagID===m.BR){bE(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)===le.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 sR=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,aR=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),TE={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function xE(e,t){const n=ER(e),r=P1("type",{handlers:{root:uR,element:lR,text:cR,comment:_E,doctype:dR,raw:hR},unknown:pR}),o={parser:n?new nE(TE):nE.getFragmentParser(void 0,TE),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),ko(o,ur());const a=n?o.parser.document:o.parser.getFragment(),u=uN(a,{file:o.options.file});return o.stitches&&Hu(u,"comment",function(c,d,h){const p=c;if(p.value.stitch&&h&&d!==void 0){const E=h.children;return E[d]=p.value.stitch,d}}),u.type==="root"&&u.children.length===1&&u.children[0].type===e.type?u.children[0]:u}function wE(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function uR(e,t){wE(e.children,t)}function lR(e,t){mR(e,t),wE(e.children,t),gR(e,t)}function cR(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:Ve.CHARACTER,chars:e.value,location:ta(e)};ko(t,ur(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function dR(e,t){const n={type:Ve.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:ta(e)};ko(t,ur(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function fR(e,t){t.stitches=!0;const n=yR(e);if("children"in e&&"children"in n){const r=xE({type:"root",children:e.children},t.options);n.children=r.children}_E({type:"comment",value:{stitch:n}},t)}function _E(e,t){const n=e.value,r={type:Ve.COMMENT,data:n,location:ta(e)};ko(t,ur(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function hR(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,vE(t,ur(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(sR,"&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 pR(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))fR(n,t);else{let r="";throw aR.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 ko(e,t){vE(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=wt.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 vE(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 mR(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===wt.PLAINTEXT)return;ko(t,ur(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Pi.html;o===Pi.html&&n==="svg"&&(o=Pi.svg);const a=_N(ae(B({},e),{children:[]}),{space:o===Pi.svg?"svg":"html"}),u={type:Ve.START_TAG,tagName:n,tagID:Ao(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:ta(e)};t.parser.currentToken=u,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function gR(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&IN.includes(n)||t.parser.tokenizer.state===wt.PLAINTEXT)return;ko(t,Nu(e));const r={type:Ve.END_TAG,tagName:n,tagID:Ao(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:ta(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===wt.RCDATA||t.parser.tokenizer.state===wt.RAWTEXT||t.parser.tokenizer.state===wt.SCRIPT_DATA)&&(t.parser.tokenizer.state=wt.DATA)}function ER(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function ta(e){const t=ur(e)||{line:void 0,column:void 0,offset:void 0},n=Nu(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 yR(e){return"children"in e?Ri(ae(B({},e),{children:[]})):Ri(e)}function SE(e){return function(t,n){return xE(t,ae(B({},e),{file:n}))}}const Fi=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],AE={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Fi,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Fi],h2:[["className","sr-only"]],img:[...Fi,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Fi,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Fi],table:[...Fi],ul:[...Fi,["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"]},Qr={}.hasOwnProperty;function bR(e,t){let n={type:"root",children:[]};const r={schema:t?B(B({},AE),t):AE,stack:[]},o=CE(r,e);return o&&(Array.isArray(o)?o.length===1?n=o[0]:n.children=o:n=o),n}function CE(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return TR(e,n);case"doctype":return xR(e,n);case"element":return wR(e,n);case"root":return _R(e,n);case"text":return vR(e,n)}}}function TR(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 na(a,t),a}}function xR(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return na(n,t),n}}function wR(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=kE(e,t.children),o=SR(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&&Qr.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 na(u,t),u}function _R(e,t){const r={type:"root",children:kE(e,t.children)};return na(r,t),r}function vR(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return na(r,t),r}function kE(e,t){const n=[];if(Array.isArray(t)){const r=t;let o=-1;for(;++o<r.length;){const a=CE(e,r[o]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function SR(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,o=e.schema.required,a=r&&Qr.call(r,n)?r[n]:void 0,u=r&&Qr.call(r,"*")?r["*"]:void 0,c=t&&typeof t=="object"?t:{},d={};let h;for(h in c)if(Qr.call(c,h)){const p=c[h];let E=NE(e,IE(a,h),h,p);E==null&&(E=NE(e,IE(u,h),h,p)),E!=null&&(d[h]=E)}if(o&&Qr.call(o,n)){const p=o[n];for(h in p)Qr.call(p,h)&&!Qr.call(d,h)&&(d[h]=p[h])}return d}function NE(e,t,n,r){return t?Array.isArray(r)?AR(e,t,n,r):OE(e,t,n,r):void 0}function AR(e,t,n,r){let o=-1;const a=[];for(;++o<r.length;){const u=OE(e,t,n,r[o]);(typeof u=="number"||typeof u=="string")&&a.push(u)}return a}function OE(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&CR(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 CR(e,t,n){const r=e.schema.protocols&&Qr.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 p=r[h];if(a===p.length&&o.slice(0,p.length)===p)return!0}return!1}function na(e,t){const n=fg(t);t.data&&(e.data=Ri(t.data)),n&&(e.position=n)}function IE(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 kR(e){return function(t){return bR(t,e)}}const RE=({globalClassName:e,openLinksInNewTab:t,href:n,title:r,children:o})=>{const a=n?t?"_blank":"_self":void 0;return v.jsx("a",ae(B(B({className:$(e,`${U}-link`)},n?{href:n,target:a}:{}),r?{title:r}:{}),{rel:"noopener noreferrer",children:o}))},NR=()=>{const{disclaimerText:e,disclaimerMarkdown:t,globalClassName:n}=At();return!e&&!t?null:v.jsx("div",{className:$(n,`${U}-disclaimer`),children:t?v.jsx(h1,{rehypePlugins:[SE,kR],components:{ul:({children:r})=>v.jsx("ul",{className:$(n,`${U}-ul`),children:r}),ol:({children:r})=>v.jsx("ol",{className:$(n,`${U}-ol`),children:r}),li:({children:r})=>v.jsx("li",{className:$(n,`${U}-li`),children:r}),a:({href:r,title:o,children:a})=>v.jsx(RE,{globalClassName:n,openLinksInNewTab:!0,href:r,title:o,children:a}),img:({src:r,alt:o})=>v.jsx("img",{className:$(n,`${U}-disclaimer-image`),src:r,alt:o}),p:({children:r})=>v.jsx("p",{className:$(n,`${U}-disclaimer-text`),children:r}),span:({children:r})=>v.jsx("span",{className:$(n,`${U}-disclaimer-text-span`),children:r})},children:t}):v.jsx("p",{className:$(n,`${U}-disclaimer-text`),children:e})})},Sf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{isConnected:o,sessionExpired:a}=Vr(),{globalClassName:u,searchConfig:c}=At(),d=Z.useRef(null),h=t||!o&&!a,p=T=>{var x;T.preventDefault();const y=(((x=d.current)==null?void 0:x.value)||"").trim();y&&(d.current.value="",r(y))},E=()=>{r("Can you connect me to a human?")};return v.jsxs("div",{className:$(u,e,`cim-${n}-component`,`${U}-search-bar-wrapper`),children:[v.jsxs("form",{className:$(u,e,`cim-${n}-component`,`${U}-search-bar`),name:`${U}-search-form`,onSubmit:p,children:[v.jsx("input",{className:$(u,e,`cim-${n}-component`,`${U}-search-input`),type:"text",ref:d,placeholder:(c==null?void 0:c.placeholder)||"Ask us anything",name:`${U}-user-input`,disabled:h}),v.jsx(XS,{className:e,globalClassName:u,searchConfig:c,componentType:n,isLoading:h}),v.jsx(ar,{className:$(u,`${U}-escalate-btn`),ariaLabel:"Connect to a human agent",title:"Connect to a human agent",disabled:h,onClick:E,icon:v.jsx(zS,{})})]}),v.jsx(NR,{})]})};function OR(e){return mt({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 PE=Z.createContext({isOpen:!1}),Af=Z.createContext(null),LE=Z.createContext(null),ra=()=>{var n,r;const e=Z.useContext(Af),t=Z.useContext(LE);return(r=(n=e==null?void 0:e.closeMenu)!=null?n:t==null?void 0:t.closeMenu)!=null?r:(()=>{})},DE=({onClearChat:e,componentType:t})=>{const n=ra(),r=()=>{e(),n()};return v.jsxs("button",{className:$(`${U}-overflow-menu-button`,"clear-chat-button",`cim-${t}-component`),onClick:r,children:[v.jsx(OR,{}),"Clear chat"]})};function IR(e){return e==null?[]:Array.isArray(e)?e:[e]}var RR=(e,...t)=>e.concat(t),PR=(e,...t)=>e.filter(n=>!t.includes(n)),LR=e=>Array.from(new Set(e));function ME(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 DR(e,t,n={}){const{step:r=1,loop:o=!0}=n;return ME(e,t,{step:-r,loop:o})}var MR=e=>Array.isArray(e),FE=e=>e!=null&&typeof e=="object",FR=e=>FE(e)&&!MR(e),Ju=e=>typeof e=="string",No=e=>typeof e=="function",BR=e=>e==null,UR=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),HR=e=>Object.prototype.toString.call(e),BE=Function.prototype.toString,zR=BE.call(Object),jR=e=>{if(!FE(e)||HR(e)!="[object Object]"||qR(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=UR(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&BE.call(n)==zR},$R=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,VR=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,qR=e=>$R(e)||VR(e),YR=e=>e(),WR=()=>{},Cf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function GR(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:KR,max:QR}=Math,XR=e=>Number.isNaN(e),JR=e=>XR(e)?0:e,UE=(e,t,n)=>KR(QR(JR(e),t),n);function kf(e){if(!jR(e)||e===void 0)return e;const t=Reflect.ownKeys(e).filter(r=>typeof r=="string"),n={};for(const r of t){const o=e[r];o!==void 0&&(n[r]=kf(o))}return n}function Nf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function ZR(e,t){if(e==null)throw new Error(t())}function eP(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 tP=Object.defineProperty,nP=(e,t,n)=>t in e?tP(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Of=(e,t,n)=>nP(e,typeof t!="symbol"?t+"":t,n),HE=()=>{},Zu=e=>typeof e=="object"&&e!==null,Oo=e=>e?"":void 0,zE=e=>e?"true":void 0,rP=1,iP=9,oP=11,Ft=e=>Zu(e)&&e.nodeType===rP&&typeof e.nodeName=="string",el=e=>Zu(e)&&e.nodeType===iP,sP=e=>Zu(e)&&e===e.window,jE=e=>Ft(e)?e.localName||"":"#document";function aP(e){return["html","body","#document"].includes(jE(e))}var uP=e=>Zu(e)&&e.nodeType!==void 0,Bi=e=>uP(e)&&e.nodeType===oP&&"host"in e,lP=e=>Ft(e)&&e.localName==="input",cP=e=>Ft(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function ia(e){if(!e)return!1;const t=e.getRootNode();return Po(t)===e}var dP=/(textarea|select)/;function fP(e){if(e==null||!Ft(e))return!1;try{return lP(e)&&e.selectionStart!=null||dP.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function Io(e,t){var r;if(!e||!t||!Ft(e)||!Ft(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Bi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function dr(e){var t;return el(e)?e:sP(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function hP(e){return dr(e).documentElement}function Ro(e){var t,n,r;return Bi(e)?Ro(e.host):el(e)?(t=e.defaultView)!=null?t:window:Ft(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Po(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 pP(e){if(jE(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Bi(e)&&e.host||hP(e);return Bi(t)?t.host:t}function If(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),el(t)||Bi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var Rf=new WeakMap;function Lo(e){return Rf.has(e)||Rf.set(e,Ro(e).getComputedStyle(e)),Rf.get(e)}var Pf=new Set(["menu","listbox","dialog","grid","tree","region"]),mP=e=>Pf.has(e),$E=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function VE(e,t){const n=new Set,r=If(e),o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=$E(c);for(const h of d){if(!h||n.has(h))continue;n.add(h);const p=r.getElementById(h);if(p){const E=p.getAttribute("role"),T=p.getAttribute("aria-modal")==="true";if(E&&mP(E)&&!T&&(p===t||p.contains(t)||o(p)))return!0}}}return!1};return o(e)}function qE(e,t){const n=If(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=$E(c);for(const h of d){if(!h||r.has(h))continue;r.add(h);const p=n.getElementById(h);if(p){const E=p.getAttribute("role"),T=p.getAttribute("aria-modal")==="true";E&&Pf.has(E)&&!T&&(t(p),o(p))}}}};o(e)}function gP(e){const t=new Set;return qE(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function EP(e){const t=e.getAttribute("role");return!!(t&&Pf.has(t))}function yP(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function bP(e){var t;return yP(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function TP(e){if(!e.id)return!1;const t=If(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&EP(e))}var Lf=()=>typeof document!="undefined";function xP(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Df=e=>Lf()&&e.test(xP()),wP=e=>Lf()&&e.test(navigator.vendor),YE=()=>Lf()&&!!navigator.maxTouchPoints,_P=()=>Df(/^iPhone/i),vP=()=>Df(/^iPad/i)||Mf()&&navigator.maxTouchPoints>1,tl=()=>_P()||vP(),SP=()=>Mf()||tl(),Mf=()=>Df(/^Mac/i),AP=()=>SP()&&wP(/apple/i);function CP(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=CP(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var WE=e=>e.button===0,kP=e=>e.button===2||Mf()&&e.ctrlKey&&e.button===0,NP=e=>"touches"in e&&e.touches.length>0,OP={Up:"ArrowUp",Down:"ArrowDown",Esc:"Escape"," ":"Space",",":"Comma",Left:"ArrowLeft",Right:"ArrowRight"},GE={ArrowLeft:"ArrowRight",ArrowRight:"ArrowLeft"};function IP(e,t={}){var u;const{dir:n="ltr",orientation:r="horizontal"}=t;let o=e.key;return o=(u=OP[o])!=null?u:o,n==="rtl"&&r==="horizontal"&&o in GE&&(o=GE[o]),o}function KE(e,t="client"){const n=NP(e)?e.touches[0]||e.changedTouches[0]:e;return{x:n[`${t}X`],y:n[`${t}Y`]}}var Bt=(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)}},QE=e=>Ft(e)&&e.tagName==="IFRAME",RP=/^(audio|video|details)$/;function XE(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var PP=e=>!Number.isNaN(XE(e)),LP=e=>XE(e)<0;function DP(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 JE(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=DP(d,t);if(h){const p=Array.from(h.querySelectorAll(nl)).filter(n),E=u.get(d);if(E!==void 0){const T=E+1;r.splice(T,0,...p),p.forEach((y,x)=>{u.set(y,T+x)});for(let y=T+p.length;y<r.length;y++)u.set(r[y],y)}else{const T=r.length;r.push(...p),p.forEach((y,x)=>{u.set(y,T+x)})}o.push(...p)}}return r}var nl="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",ZE=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(nl));(n==!0||n=="if-empty"&&o.length===0)&&Ft(e)&&fr(e)&&o.unshift(e);const u=[];for(const c of o)if(fr(c)){if(QE(c)&&c.contentDocument){const d=c.contentDocument.body;u.push(...ZE(d,{getShadowRoot:r}));continue}u.push(c)}return r?JE(u,r,fr):u};function fr(e){return!Ft(e)||e.closest("[inert]")?!1:e.matches(nl)&&cP(e)}function Do(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(nl));n&&Ui(e)&&o.unshift(e);const a=[];for(const u of o)if(Ui(u)){if(QE(u)&&u.contentDocument){const c=u.contentDocument.body;a.push(...Do(c,{getShadowRoot:r}));continue}a.push(u)}if(r){const u=JE(a,r,Ui);return!u.length&&n?o:u}return!a.length&&n?o:a}function Ui(e){return Ft(e)&&e.tabIndex>0?!0:fr(e)&&!LP(e)}function MP(e,t={}){const n=Do(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function FP(e,t={}){const{current:n,getShadowRoot:r}=t,o=Do(e,{getShadowRoot:r}),a=(e==null?void 0:e.ownerDocument)||document,u=n!=null?n:Po(a);if(!u)return null;const c=o.indexOf(u);return o[c+1]||null}function oa(e){return e.tabIndex<0&&(RP.test(e.localName)||fP(e))&&!PP(e)?0:e.tabIndex}function ey(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=Do(t);a=r?u.filter(r)[0]:u[0]}return a||t||void 0}var BP=class nw{constructor(){Of(this,"id",null),Of(this,"fn_cleanup"),Of(this,"cleanup",()=>{this.cancel()})}static create(){return new nw}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 Ot(e){const t=BP.create();return t.request(e),t.cleanup}function ty(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 Ff(e){const t=pP(e);return aP(t)?dr(t).body:Ft(t)&&zP(t)?t:Ff(t)}var UP=/auto|scroll|overlay|hidden|clip/,HP=new Set(["inline","contents"]);function zP(e){const t=Ro(e),{overflow:n,overflowX:r,overflowY:o,display:a}=t.getComputedStyle(e);return UP.test(n+o+r)&&!HP.has(a)}var Mo="default",Bf="",rl=new WeakMap;function jP(e={}){const{target:t,doc:n}=e,r=n!=null?n:document,o=r.documentElement;return tl()?(Mo==="default"&&(Bf=o.style.webkitUserSelect,o.style.webkitUserSelect="none"),Mo="disabled"):t&&(rl.set(t,t.style.userSelect),t.style.userSelect="none"),()=>$P({target:t,doc:r})}function $P(e={}){const{target:t,doc:n}=e,o=(n!=null?n:document).documentElement;if(tl()){if(Mo!=="disabled")return;Mo="restoring",setTimeout(()=>{ty(()=>{Mo==="restoring"&&(o.style.webkitUserSelect==="none"&&(o.style.webkitUserSelect=Bf||""),Bf="",Mo="default")})},300)}else if(t&&rl.has(t)){const a=rl.get(t);t.style.userSelect==="none"&&(t.style.userSelect=a!=null?a:""),t.getAttribute("style")===""&&t.removeAttribute("style"),rl.delete(t)}}function VP(e={}){const u=e,{defer:t,target:n}=u,r=sn(u,["defer","target"]),o=t?Ot:c=>c(),a=[];return a.push(o(()=>{const c=typeof n=="function"?n():n;a.push(jP(ae(B({},r),{target:c})))})),()=>{a.forEach(c=>c==null?void 0:c())}}function qP(e,t){const{onPointerMove:n,onPointerUp:r}=t,o=c=>{const d=KE(c),h=Math.sqrt(nu(d.x,2)+nu(d.y,2)),p=c.pointerType==="touch"?10:5;if(!(h<p)){if(c.pointerType==="mouse"&&c.button===0){a(c);return}n({point:d,event:c})}},a=c=>{const d=KE(c);r({point:d,event:c})},u=[Bt(e,"pointermove",o,!1),Bt(e,"pointerup",a,!1),Bt(e,"pointercancel",a,!1),Bt(e,"contextmenu",a,!1),VP({doc:e})];return()=>{u.forEach(c=>c())}}function YP(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 p=null;const[E,T]=MP(e,{includeContainer:!0,getShadowRoot:a}),y=FP(c,{current:n,getShadowRoot:a}),x=!E&&!T;h.shiftKey&&ia(y)?(o==null||o(),p=T):h.shiftKey&&(ia(E)||x)?p=n:!h.shiftKey&&ia(n)?(o==null||o(),p=E):!h.shiftKey&&(ia(T)||x)&&(p=y),p&&(h.preventDefault(),typeof r=="function"?r(p):p.focus())}return Bt(u,"keydown",d,!0)}function WP(e,t){const c=t,{defer:n,triggerElement:r}=c,o=sn(c,["defer","triggerElement"]),a=n?Ot:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof r=="function"?r():r;u.push(YP(d,B({triggerElement:h},o)))})),()=>{u.forEach(d=>d==null?void 0:d())}}function GP(e,t){var n;return Array.from((n=e==null?void 0:e.querySelectorAll(t))!=null?n:[])}function il(e,t){if(!e)return HE;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 KP(e,t,n){if(!e)return HE;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 QP(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 XP(e,t){const{timeout:n,rootNode:r}=t,o=Ro(r),a=dr(r),u=new o.AbortController;return QP(new Promise(c=>{const d=e();if(d){c(d);return}const h=new o.MutationObserver(()=>{const p=e();p&&p.isConnected&&(h.disconnect(),c(p))});h.observe(a.body,{childList:!0,subtree:!0})}),u,n)}var JP=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),ZP=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,ny=e=>{const t={};let n;for(;n=ZP.exec(e);)t[n[1]]=n[2];return t},e4=(e,t)=>{if(Ju(e)){if(Ju(t))return`${e};${t}`;e=ny(e)}else Ju(t)&&(t=ny(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function It(...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]=Cf(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=JP(t[o],n[o]);continue}if(o==="style"){t[o]=e4(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 xF(e){return e}var Fo=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Fo||{}),Uf="__init__";function t4(e){const t=()=>{var u,c;return(c=(u=e.getRootNode)==null?void 0:u.call(e))!=null?c:document},n=()=>dr(t()),r=()=>{var u;return(u=n().defaultView)!=null?u:window},o=()=>Po(t()),a=u=>t().getElementById(u);return ae(B({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:ia,getById:a})}function n4(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var Bo=()=>e=>Array.from(new Set(e)),ry=typeof globalThis.document!="undefined"?Z.useLayoutEffect:Z.useEffect;function ol(e){var E,T;const t=(E=e().value)!=null?E:e().defaultValue,n=(T=e().isEqual)!=null?T:Object.is,[r]=Z.useState(t),[o,a]=Z.useState(r),u=e().value!==void 0,c=Z.useRef(o);c.current=u?e().value:o;const d=Z.useRef(c.current);ry(()=>{d.current=c.current},[o,e().value]);const h=y=>{var S,A;const x=d.current,_=No(y)?y(x):y;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:_,prev:x}),u||a(_),n(_,x)||(A=(S=e()).onChange)==null||A.call(S,_,x)};function p(){return u?e().value:o}return{initial:r,ref:c,get:p,set(y){(e().sync?Is.flushSync:YR)(()=>h(y))},invoke(y,x){var _,S;(S=(_=e()).onChange)==null||S.call(_,y,x)},hash(y){var x,_,S;return(S=(_=(x=e()).hash)==null?void 0:_.call(x,y))!=null?S:String(y)}}}ol.cleanup=e=>{Z.useEffect(()=>e,[])},ol.ref=e=>{const t=Z.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function r4(e){const t=Z.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var i4=(e,t)=>{const n=Z.useRef(!1),r=Z.useRef(!1);Z.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),Z.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function sl(e,t={}){var X,se,ee,re,de,Oe;const n=Z.useMemo(()=>{const{id:he,ids:Q,getRootNode:oe}=t;return t4({id:he,ids:Q,getRootNode:oe})},[t]),r=(...he)=>{e.debug&&console.log(...he)},o=(se=(X=e.props)==null?void 0:X.call(e,{props:kf(t),scope:n}))!=null?se:t,a=o4(o),u=(ee=e.context)==null?void 0:ee.call(e,{prop:a,bindable:ol,scope:n,flush:oy,getContext(){return d},getComputed(){return W},getRefs(){return _},getEvent(){return y()}}),c=iy(u),d={get(he){var Q;return(Q=c.current)==null?void 0:Q[he].ref.current},set(he,Q){var oe;(oe=c.current)==null||oe[he].set(Q)},initial(he){var Q;return(Q=c.current)==null?void 0:Q[he].initial},hash(he){var oe,C;const Q=(oe=c.current)==null?void 0:oe[he].get();return(C=c.current)==null?void 0:C[he].hash(Q)}},h=Z.useRef(new Map),p=Z.useRef(null),E=Z.useRef(null),T=Z.useRef({type:""}),y=()=>ae(B({},T.current),{current(){return T.current},previous(){return E.current}}),x=()=>ae(B({},D),{matches(...he){return he.includes(D.ref.current)},hasTag(he){var Q,oe;return!!((oe=(Q=e.states[D.ref.current])==null?void 0:Q.tags)!=null&&oe.includes(he))}}),_=r4((de=(re=e.refs)==null?void 0:re.call(e,{prop:a,context:d}))!=null?de:{}),S=()=>({state:x(),context:d,event:y(),prop:a,send:z,action:A,guard:O,track:i4,refs:_,computed:W,flush:oy,scope:n,choose:H}),A=he=>{const Q=No(he)?he(S()):he;if(!Q)return;const oe=Q.map(C=>{var ne,k;const M=(k=(ne=e.implementations)==null?void 0:ne.actions)==null?void 0:k[C];return M||Nf(`[zag-js] No implementation found for action "${JSON.stringify(C)}"`),M});for(const C of oe)C==null||C(S())},O=he=>{var Q,oe;return No(he)?he(S()):(oe=(Q=e.implementations)==null?void 0:Q.guards)==null?void 0:oe[he](S())},R=he=>{const Q=No(he)?he(S()):he;if(!Q)return;const oe=Q.map(M=>{var k,me;const ne=(me=(k=e.implementations)==null?void 0:k.effects)==null?void 0:me[M];return ne||Nf(`[zag-js] No implementation found for effect "${JSON.stringify(M)}"`),ne}),C=[];for(const M of oe){const ne=M==null?void 0:M(S());ne&&C.push(ne)}return()=>C.forEach(M=>M==null?void 0:M())},H=he=>IR(he).find(Q=>{let oe=!Q.guard;return Ju(Q.guard)?oe=!!O(Q.guard):No(Q.guard)&&(oe=Q.guard(S())),oe}),W=he=>{ZR(e.computed,()=>"[zag-js] No computed object found on machine");const Q=e.computed[he];return Q({context:d,event:y(),prop:a,refs:_,scope:n,computed:W})},D=ol(()=>({defaultValue:e.initialState({prop:a}),onChange(he,Q){var C,M,ne,k;if(Q){const me=h.current.get(Q);me==null||me(),h.current.delete(Q)}Q&&A((C=e.states[Q])==null?void 0:C.exit),A((M=p.current)==null?void 0:M.actions);const oe=R((ne=e.states[he])==null?void 0:ne.effects);if(oe&&h.current.set(he,oe),Q===Uf){A(e.entry);const me=R(e.effects);me&&h.current.set(Uf,me)}A((k=e.states[he])==null?void 0:k.entry)}})),K=Z.useRef(void 0),fe=Z.useRef(Fo.NotStarted);ry(()=>{queueMicrotask(()=>{var M;const oe=fe.current===Fo.Started;fe.current=Fo.Started,r(oe?"rehydrating...":"initializing...");const C=(M=K.current)!=null?M:D.initial;D.invoke(C,oe?D.get():Uf)});const he=h.current,Q=D.ref.current;return()=>{r("unmounting..."),K.current=Q,fe.current=Fo.Stopped,he.forEach(oe=>oe==null?void 0:oe()),h.current=new Map,p.current=null,queueMicrotask(()=>{A(e.exit)})}},[]);const Te=()=>"ref"in D?D.ref.current:D.get(),z=he=>{queueMicrotask(()=>{var k,me,Se,Ae,Be;if(fe.current!==Fo.Started)return;E.current=T.current,T.current=he;let Q=Te();const oe=(Se=(k=e.states[Q].on)==null?void 0:k[he.type])!=null?Se:(me=e.on)==null?void 0:me[he.type],C=H(oe);if(!C)return;p.current=C;const M=(Ae=C.target)!=null?Ae:Q;r("transition",he.type,C.target||Q,`(${C.actions})`);const ne=M!==Q;ne?Is.flushSync(()=>D.set(M)):C.reenter&&!ne?D.invoke(Q,Q):A((Be=C.actions)!=null?Be:[])})};return(Oe=e.watch)==null||Oe.call(e,S()),{state:x(),send:z,context:d,prop:a,scope:n,refs:_,computed:W,event:y(),getStatus:()=>fe.current}}function iy(e){const t=Z.useRef(e);return t.current=e,t}function o4(e){const t=iy(e);return function(r){return t.current[r]}}function oy(e){queueMicrotask(()=>{Is.flushSync(()=>e())})}var Hf=n4(e=>e);function al(...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 s4(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 zf=e=>{const t=Z.memo(Z.forwardRef((n,r)=>{const h=n,{asChild:o,children:a}=h,u=sn(h,["asChild","children"]);if(!o)return Z.createElement(e,ae(B({},u),{ref:r}),a);if(!Z.isValidElement(a))return null;const c=Z.Children.only(a),d=s4(c);return Z.cloneElement(c,ae(B({},It(u,c.props)),{ref:r?al(r,d):d}))}));return t.displayName=e.displayName||e.name,t},Qt=(()=>{const e=new Map;return new Proxy(zf,{apply(t,n,r){return zf(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,zf(r)),e.get(r)}})})();function a4(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Hi(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:a,defaultValue:u}=e,c=Z.createContext(u);c.displayName=t;function d(){var p;const h=Z.useContext(c);if(!h&&n){const E=new Error(a!=null?a:a4(r,o));throw E.name="ContextError",(p=Error.captureStackTrace)==null||p.call(Error,E,d),E}return h}return[c.Provider,d,c]}const[u4,jf]=Hi({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[sy,sa]=Hi({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),ay=Z.forwardRef((e,t)=>{const n=jf(),r=sa(),o=It(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:v.jsx(Qt.div,ae(B({},o),{ref:al(r.ref,t)}))});ay.displayName="PopoverContent";const uy=Z.forwardRef((e,t)=>{const n=jf(),r=sa(),o=It(n.getPositionerProps(),e);return r.unmounted?null:v.jsx(Qt.div,ae(B({},o),{ref:t}))});uy.displayName="PopoverPositioner";const aa=()=>(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]},[{},B({},e)]),ly=e=>aa()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function l4(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 c4={props({props:e}){return ae(B({},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",Lo(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"});Ot(()=>{var c,d;const u=ul(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})=>{Ot(()=>{e.set("prevAnimationName",ul(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 p,E,T;((T=(E=(p=d.composedPath)==null?void 0:p.call(d))==null?void 0:E[0])!=null?T:d.target)===o&&e.set("prevAnimationName",ul(t.get("styles")))},u=d=>{const h=ul(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=il(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",a),o.removeEventListener("animationcancel",u),o.removeEventListener("animationend",u),ty(()=>c())}}}}};function ul(e){return(e==null?void 0:e.animationName)||"none"}Bo()(["onExitComplete","present","immediate"]);function d4(e,t={}){const{sync:n=!1}=t,r=f4(e);return Z.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 f4(e){const t=Z.useRef(e);return t.current=e,t}const $f=(e={})=>{const T=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=T,a=sn(T,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),u=Z.useRef(!1),c=ae(B({},a),{present:r,onExitComplete:d4(e.onExitComplete)}),d=sl(c4,c),h=l4(d);h.present&&(u.current=!0);const p=!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:p}};var zi=(e,t=[])=>({parts:(...n)=>{if(h4(t))return zi(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>zi(e,[...t,...n]),omit:(...n)=>zi(e,t.filter(r=>!n.includes(r))),rename:n=>zi(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Uo(e)}"][data-part="${Uo(r)}"]`,`& [data-scope="${Uo(e)}"][data-part="${Uo(r)}"]`].join(", "),attrs:{"data-scope":Uo(e),"data-part":Uo(r)}}}),{})}),Uo=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),h4=e=>e.length===0;const p4=["top","right","bottom","left"],Xr=Math.min,_n=Math.max,ll=Math.round,cl=Math.floor,hr=e=>({x:e,y:e}),m4={left:"right",right:"left",bottom:"top",top:"bottom"},g4={start:"end",end:"start"};function Vf(e,t,n){return _n(e,Xr(t,n))}function Cr(e,t){return typeof e=="function"?e(t):e}function kr(e){return e.split("-")[0]}function Ho(e){return e.split("-")[1]}function qf(e){return e==="x"?"y":"x"}function Yf(e){return e==="y"?"height":"width"}const E4=new Set(["top","bottom"]);function pr(e){return E4.has(kr(e))?"y":"x"}function Wf(e){return qf(pr(e))}function y4(e,t,n){n===void 0&&(n=!1);const r=Ho(e),o=Wf(e),a=Yf(o);let u=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(u=dl(u)),[u,dl(u)]}function b4(e){const t=dl(e);return[Gf(e),t,Gf(t)]}function Gf(e){return e.replace(/start|end/g,t=>g4[t])}const cy=["left","right"],dy=["right","left"],T4=["top","bottom"],x4=["bottom","top"];function w4(e,t,n){switch(e){case"top":case"bottom":return n?t?dy:cy:t?cy:dy;case"left":case"right":return t?T4:x4;default:return[]}}function _4(e,t,n,r){const o=Ho(e);let a=w4(kr(e),n==="start",r);return o&&(a=a.map(u=>u+"-"+o),t&&(a=a.concat(a.map(Gf)))),a}function dl(e){return e.replace(/left|right|bottom|top/g,t=>m4[t])}function v4(e){return B({top:0,right:0,bottom:0,left:0},e)}function fy(e){return typeof e!="number"?v4(e):{top:e,right:e,bottom:e,left:e}}function fl(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 hy(e,t,n){let{reference:r,floating:o}=e;const a=pr(t),u=Wf(t),c=Yf(u),d=kr(t),h=a==="y",p=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 y;switch(d){case"top":y={x:p,y:r.y-o.height};break;case"bottom":y={x:p,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:E};break;case"left":y={x:r.x-o.width,y:E};break;default:y={x:r.x,y:r.y}}switch(Ho(t)){case"start":y[u]-=T*(n&&h?-1:1);break;case"end":y[u]+=T*(n&&h?-1:1);break}return y}const S4=(e,t,n)=>$e(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:p,y:E}=hy(h,r,d),T=r,y={},x=0;for(let _=0;_<c.length;_++){const{name:S,fn:A}=c[_],{x:O,y:R,data:H,reset:W}=yield A({x:p,y:E,initialPlacement:r,placement:T,strategy:o,middlewareData:y,rects:h,platform:u,elements:{reference:e,floating:t}});p=O!=null?O:p,E=R!=null?R:E,y=ae(B({},y),{[S]:B(B({},y[S]),H)}),W&&x<=50&&(x++,typeof W=="object"&&(W.placement&&(T=W.placement),W.rects&&(h=W.rects===!0?yield u.getElementRects({reference:e,floating:t,strategy:o}):W.rects),{x:p,y:E}=hy(h,T,d)),_=-1)}return{x:p,y:E,placement:T,strategy:o,middlewareData:y}});function ua(e,t){return $e(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:p="viewport",elementContext:E="floating",altBoundary:T=!1,padding:y=0}=Cr(t,e),x=fy(y),S=c[T?E==="floating"?"reference":"floating":E],A=fl(yield a.getClippingRect({element:(n=yield a.isElement==null?void 0:a.isElement(S))==null||n?S:S.contextElement||(yield a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:h,rootBoundary:p,strategy:d})),O=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),H=(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},W=fl(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:O,offsetParent:R,strategy:d}):O);return{top:(A.top-W.top+x.top)/H.y,bottom:(W.bottom-A.bottom+x.bottom)/H.y,left:(A.left-W.left+x.left)/H.x,right:(W.right-A.right+x.right)/H.x}})}const A4=e=>({name:"arrow",options:e,fn(n){return $e(this,null,function*(){const{x:r,y:o,placement:a,rects:u,platform:c,elements:d,middlewareData:h}=n,{element:p,padding:E=0}=Cr(e,n)||{};if(p==null)return{};const T=fy(E),y={x:r,y:o},x=Wf(a),_=Yf(x),S=yield c.getDimensions(p),A=x==="y",O=A?"top":"left",R=A?"bottom":"right",H=A?"clientHeight":"clientWidth",W=u.reference[_]+u.reference[x]-y[x]-u.floating[_],D=y[x]-u.reference[x],K=yield c.getOffsetParent==null?void 0:c.getOffsetParent(p);let fe=K?K[H]:0;(!fe||!(yield c.isElement==null?void 0:c.isElement(K)))&&(fe=d.floating[H]||u.floating[_]);const Te=W/2-D/2,z=fe/2-S[_]/2-1,X=Xr(T[O],z),se=Xr(T[R],z),ee=X,re=fe-S[_]-se,de=fe/2-S[_]/2+Te,Oe=Vf(ee,de,re),he=!h.arrow&&Ho(a)!=null&&de!==Oe&&u.reference[_]/2-(de<ee?X:se)-S[_]/2<0,Q=he?de<ee?de-ee:de-re:0;return{[x]:y[x]+Q,data:B({[x]:Oe,centerOffset:de-Oe-Q},he&&{alignmentOffset:Q}),reset:he}})}}),C4=function(e){return e===void 0&&(e={}),{name:"flip",options:e,fn(n){return $e(this,null,function*(){var r,o;const{placement:a,middlewareData:u,rects:c,initialPlacement:d,platform:h,elements:p}=n,de=Cr(e,n),{mainAxis:E=!0,crossAxis:T=!0,fallbackPlacements:y,fallbackStrategy:x="bestFit",fallbackAxisSideDirection:_="none",flipAlignment:S=!0}=de,A=sn(de,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=u.arrow)!=null&&r.alignmentOffset)return{};const O=kr(a),R=pr(d),H=kr(d)===d,W=yield h.isRTL==null?void 0:h.isRTL(p.floating),D=y||(H||!S?[dl(d)]:b4(d)),K=_!=="none";!y&&K&&D.push(..._4(d,S,_,W));const fe=[d,...D],Te=yield ua(n,A),z=[];let X=((o=u.flip)==null?void 0:o.overflows)||[];if(E&&z.push(Te[O]),T){const Oe=y4(a,c,W);z.push(Te[Oe[0]],Te[Oe[1]])}if(X=[...X,{placement:a,overflows:z}],!z.every(Oe=>Oe<=0)){var se,ee;const Oe=(((se=u.flip)==null?void 0:se.index)||0)+1,he=fe[Oe];if(he&&(!(T==="alignment"?R!==pr(he):!1)||X.every(C=>pr(C.placement)===R?C.overflows[0]>0:!0)))return{data:{index:Oe,overflows:X},reset:{placement:he}};let Q=(ee=X.filter(oe=>oe.overflows[0]<=0).sort((oe,C)=>oe.overflows[1]-C.overflows[1])[0])==null?void 0:ee.placement;if(!Q)switch(x){case"bestFit":{var re;const oe=(re=X.filter(C=>{if(K){const M=pr(C.placement);return M===R||M==="y"}return!0}).map(C=>[C.placement,C.overflows.filter(M=>M>0).reduce((M,ne)=>M+ne,0)]).sort((C,M)=>C[1]-M[1])[0])==null?void 0:re[0];oe&&(Q=oe);break}case"initialPlacement":Q=d;break}if(a!==Q)return{reset:{placement:Q}}}return{}})}}};function py(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function my(e){return p4.some(t=>e[t]>=0)}const k4=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return $e(this,null,function*(){const{rects:r}=n,u=Cr(e,n),{strategy:o="referenceHidden"}=u,a=sn(u,["strategy"]);switch(o){case"referenceHidden":{const c=yield ua(n,ae(B({},a),{elementContext:"reference"})),d=py(c,r.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:my(d)}}}case"escaped":{const c=yield ua(n,ae(B({},a),{altBoundary:!0})),d=py(c,r.floating);return{data:{escapedOffsets:d,escaped:my(d)}}}default:return{}}})}}},gy=new Set(["left","top"]);function N4(e,t){return $e(this,null,function*(){const{placement:n,platform:r,elements:o}=e,a=yield r.isRTL==null?void 0:r.isRTL(o.floating),u=kr(n),c=Ho(n),d=pr(n)==="y",h=gy.has(u)?-1:1,p=a&&d?-1:1,E=Cr(t,e);let{mainAxis:T,crossAxis:y,alignmentAxis:x}=typeof E=="number"?{mainAxis:E,crossAxis:0,alignmentAxis:null}:{mainAxis:E.mainAxis||0,crossAxis:E.crossAxis||0,alignmentAxis:E.alignmentAxis};return c&&typeof x=="number"&&(y=c==="end"?x*-1:x),d?{x:y*p,y:T*h}:{x:T*h,y:y*p}})}const O4=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(n){return $e(this,null,function*(){var r,o;const{x:a,y:u,placement:c,middlewareData:d}=n,h=yield N4(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:ae(B({},h),{placement:c})}})}}},I4=function(e){return e===void 0&&(e={}),{name:"shift",options:e,fn(n){return $e(this,null,function*(){const{x:r,y:o,placement:a}=n,A=Cr(e,n),{mainAxis:u=!0,crossAxis:c=!1,limiter:d={fn:O=>{let{x:R,y:H}=O;return{x:R,y:H}}}}=A,h=sn(A,["mainAxis","crossAxis","limiter"]),p={x:r,y:o},E=yield ua(n,h),T=pr(kr(a)),y=qf(T);let x=p[y],_=p[T];if(u){const O=y==="y"?"top":"left",R=y==="y"?"bottom":"right",H=x+E[O],W=x-E[R];x=Vf(H,x,W)}if(c){const O=T==="y"?"top":"left",R=T==="y"?"bottom":"right",H=_+E[O],W=_-E[R];_=Vf(H,_,W)}const S=d.fn(ae(B({},n),{[y]:x,[T]:_}));return ae(B({},S),{data:{x:S.x-r,y:S.y-o,enabled:{[y]:u,[T]:c}}})})}}},R4=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}=Cr(e,t),p={x:n,y:r},E=pr(o),T=qf(E);let y=p[T],x=p[E];const _=Cr(c,t),S=typeof _=="number"?{mainAxis:_,crossAxis:0}:B({mainAxis:0,crossAxis:0},_);if(d){const R=T==="y"?"height":"width",H=a.reference[T]-a.floating[R]+S.mainAxis,W=a.reference[T]+a.reference[R]-S.mainAxis;y<H?y=H:y>W&&(y=W)}if(h){var A,O;const R=T==="y"?"width":"height",H=gy.has(kr(o)),W=a.reference[E]-a.floating[R]+(H&&((A=u.offset)==null?void 0:A[E])||0)+(H?0:S.crossAxis),D=a.reference[E]+a.reference[R]+(H?0:((O=u.offset)==null?void 0:O[E])||0)-(H?S.crossAxis:0);x<W?x=W:x>D&&(x=D)}return{[T]:y,[E]:x}}}},P4=function(e){return e===void 0&&(e={}),{name:"size",options:e,fn(n){return $e(this,null,function*(){var r,o;const{placement:a,rects:u,platform:c,elements:d}=n,X=Cr(e,n),{apply:h=()=>{}}=X,p=sn(X,["apply"]),E=yield ua(n,p),T=kr(a),y=Ho(a),x=pr(a)==="y",{width:_,height:S}=u.floating;let A,O;T==="top"||T==="bottom"?(A=T,O=y===((yield c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(O=T,A=y==="end"?"top":"bottom");const R=S-E.top-E.bottom,H=_-E.left-E.right,W=Xr(S-E[A],R),D=Xr(_-E[O],H),K=!n.middlewareData.shift;let fe=W,Te=D;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(Te=H),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(fe=R),K&&!y){const se=_n(E.left,0),ee=_n(E.right,0),re=_n(E.top,0),de=_n(E.bottom,0);x?Te=_-2*(se!==0||ee!==0?se+ee:_n(E.left,E.right)):fe=S-2*(re!==0||de!==0?re+de:_n(E.top,E.bottom))}yield h(ae(B({},n),{availableWidth:Te,availableHeight:fe}));const z=yield c.getDimensions(d.floating);return _!==z.width||S!==z.height?{reset:{rects:!0}}:{}})}}};function hl(){return typeof window!="undefined"}function zo(e){return Ey(e)?(e.nodeName||"").toLowerCase():"#document"}function vn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function mr(e){var t;return(t=(Ey(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ey(e){return hl()?e instanceof Node||e instanceof vn(e).Node:!1}function Kn(e){return hl()?e instanceof Element||e instanceof vn(e).Element:!1}function gr(e){return hl()?e instanceof HTMLElement||e instanceof vn(e).HTMLElement:!1}function yy(e){return!hl()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof vn(e).ShadowRoot}const L4=new Set(["inline","contents"]);function la(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!L4.has(o)}const D4=new Set(["table","td","th"]);function M4(e){return D4.has(zo(e))}const F4=[":popover-open",":modal"];function pl(e){return F4.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const B4=["transform","translate","scale","rotate","perspective"],U4=["transform","translate","scale","rotate","perspective","filter"],H4=["paint","layout","strict","content"];function Kf(e){const t=Qf(),n=Kn(e)?Qn(e):e;return B4.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)||U4.some(r=>(n.willChange||"").includes(r))||H4.some(r=>(n.contain||"").includes(r))}function z4(e){let t=Jr(e);for(;gr(t)&&!jo(t);){if(Kf(t))return t;if(pl(t))return null;t=Jr(t)}return null}function Qf(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const j4=new Set(["html","body","#document"]);function jo(e){return j4.has(zo(e))}function Qn(e){return vn(e).getComputedStyle(e)}function ml(e){return Kn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Jr(e){if(zo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||yy(e)&&e.host||mr(e);return yy(t)?t.host:t}function by(e){const t=Jr(e);return jo(t)?e.ownerDocument?e.ownerDocument.body:e.body:gr(t)&&la(t)?t:by(t)}function ca(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=by(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),u=vn(o);if(a){const c=Xf(u);return t.concat(u,u.visualViewport||[],la(o)?o:[],c&&n?ca(c):[])}return t.concat(o,ca(o,[],n))}function Xf(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ty(e){const t=Qn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=gr(e),a=o?e.offsetWidth:n,u=o?e.offsetHeight:r,c=ll(n)!==a||ll(r)!==u;return c&&(n=a,r=u),{width:n,height:r,$:c}}function Jf(e){return Kn(e)?e:e.contextElement}function $o(e){const t=Jf(e);if(!gr(t))return hr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=Ty(t);let u=(a?ll(n.width):n.width)/r,c=(a?ll(n.height):n.height)/o;return(!u||!Number.isFinite(u))&&(u=1),(!c||!Number.isFinite(c))&&(c=1),{x:u,y:c}}const $4=hr(0);function xy(e){const t=vn(e);return!Qf()||!t.visualViewport?$4:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function V4(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==vn(e)?!1:t}function ji(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=Jf(e);let u=hr(1);t&&(r?Kn(r)&&(u=$o(r)):u=$o(e));const c=V4(a,n,r)?xy(a):hr(0);let d=(o.left+c.x)/u.x,h=(o.top+c.y)/u.y,p=o.width/u.x,E=o.height/u.y;if(a){const T=vn(a),y=r&&Kn(r)?vn(r):r;let x=T,_=Xf(x);for(;_&&r&&y!==x;){const S=$o(_),A=_.getBoundingClientRect(),O=Qn(_),R=A.left+(_.clientLeft+parseFloat(O.paddingLeft))*S.x,H=A.top+(_.clientTop+parseFloat(O.paddingTop))*S.y;d*=S.x,h*=S.y,p*=S.x,E*=S.y,d+=R,h+=H,x=vn(_),_=Xf(x)}}return fl({width:p,height:E,x:d,y:h})}function gl(e,t){const n=ml(e).scrollLeft;return t?t.left+n:ji(mr(e)).left+n}function wy(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-gl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function q4(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",u=mr(r),c=t?pl(t.floating):!1;if(r===u||c&&a)return n;let d={scrollLeft:0,scrollTop:0},h=hr(1);const p=hr(0),E=gr(r);if((E||!E&&!a)&&((zo(r)!=="body"||la(u))&&(d=ml(r)),gr(r))){const y=ji(r);h=$o(r),p.x=y.x+r.clientLeft,p.y=y.y+r.clientTop}const T=u&&!E&&!a?wy(u,d):hr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+p.x+T.x,y:n.y*h.y-d.scrollTop*h.y+p.y+T.y}}function Y4(e){return Array.from(e.getClientRects())}function W4(e){const t=mr(e),n=ml(e),r=e.ownerDocument.body,o=_n(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=_n(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let u=-n.scrollLeft+gl(e);const c=-n.scrollTop;return Qn(r).direction==="rtl"&&(u+=_n(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:u,y:c}}const _y=25;function G4(e,t){const n=vn(e),r=mr(e),o=n.visualViewport;let a=r.clientWidth,u=r.clientHeight,c=0,d=0;if(o){a=o.width,u=o.height;const p=Qf();(!p||p&&t==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const h=gl(r);if(h<=0){const p=r.ownerDocument,E=p.body,T=getComputedStyle(E),y=p.compatMode==="CSS1Compat"&&parseFloat(T.marginLeft)+parseFloat(T.marginRight)||0,x=Math.abs(r.clientWidth-E.clientWidth-y);x<=_y&&(a-=x)}else h<=_y&&(a+=h);return{width:a,height:u,x:c,y:d}}const K4=new Set(["absolute","fixed"]);function Q4(e,t){const n=ji(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=gr(e)?$o(e):hr(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 vy(e,t,n){let r;if(t==="viewport")r=G4(e,n);else if(t==="document")r=W4(mr(e));else if(Kn(t))r=Q4(t,n);else{const o=xy(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return fl(r)}function Sy(e,t){const n=Jr(e);return n===t||!Kn(n)||jo(n)?!1:Qn(n).position==="fixed"||Sy(n,t)}function X4(e,t){const n=t.get(e);if(n)return n;let r=ca(e,[],!1).filter(c=>Kn(c)&&zo(c)!=="body"),o=null;const a=Qn(e).position==="fixed";let u=a?Jr(e):e;for(;Kn(u)&&!jo(u);){const c=Qn(u),d=Kf(u);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&K4.has(o.position)||la(u)&&!d&&Sy(e,u))?r=r.filter(p=>p!==u):o=c,u=Jr(u)}return t.set(e,r),r}function J4(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const u=[...n==="clippingAncestors"?pl(t)?[]:X4(t,this._c):[].concat(n),r],c=u[0],d=u.reduce((h,p)=>{const E=vy(t,p,o);return h.top=_n(E.top,h.top),h.right=Xr(E.right,h.right),h.bottom=Xr(E.bottom,h.bottom),h.left=_n(E.left,h.left),h},vy(t,c,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function Z4(e){const{width:t,height:n}=Ty(e);return{width:t,height:n}}function e6(e,t,n){const r=gr(t),o=mr(t),a=n==="fixed",u=ji(e,!0,a,t);let c={scrollLeft:0,scrollTop:0};const d=hr(0);function h(){d.x=gl(o)}if(r||!r&&!a)if((zo(t)!=="body"||la(o))&&(c=ml(t)),r){const y=ji(t,!0,a,t);d.x=y.x+t.clientLeft,d.y=y.y+t.clientTop}else o&&h();a&&!r&&o&&h();const p=o&&!r&&!a?wy(o,c):hr(0),E=u.left+c.scrollLeft-d.x-p.x,T=u.top+c.scrollTop-d.y-p.y;return{x:E,y:T,width:u.width,height:u.height}}function Zf(e){return Qn(e).position==="static"}function Ay(e,t){if(!gr(e)||Qn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return mr(e)===n&&(n=n.ownerDocument.body),n}function Cy(e,t){const n=vn(e);if(pl(e))return n;if(!gr(e)){let o=Jr(e);for(;o&&!jo(o);){if(Kn(o)&&!Zf(o))return o;o=Jr(o)}return n}let r=Ay(e,t);for(;r&&M4(r)&&Zf(r);)r=Ay(r,t);return r&&jo(r)&&Zf(r)&&!Kf(r)?n:r||z4(e)||n}const t6=function(e){return $e(this,null,function*(){const t=this.getOffsetParent||Cy,n=this.getDimensions,r=yield n(e.floating);return{reference:e6(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function n6(e){return Qn(e).direction==="rtl"}const r6={convertOffsetParentRelativeRectToViewportRelativeRect:q4,getDocumentElement:mr,getClippingRect:J4,getOffsetParent:Cy,getElementRects:t6,getClientRects:Y4,getDimensions:Z4,getScale:$o,isElement:Kn,isRTL:n6};function ky(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function i6(e,t){let n=null,r;const o=mr(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:p,top:E,width:T,height:y}=h;if(c||t(),!T||!y)return;const x=cl(E),_=cl(o.clientWidth-(p+T)),S=cl(o.clientHeight-(E+y)),A=cl(p),R={rootMargin:-x+"px "+-_+"px "+-S+"px "+-A+"px",threshold:_n(0,Xr(1,d))||1};let H=!0;function W(D){const K=D[0].intersectionRatio;if(K!==d){if(!H)return u();K?u(!1,K):r=setTimeout(()=>{u(!1,1e-7)},1e3)}K===1&&!ky(h,e.getBoundingClientRect())&&u(),H=!1}try{n=new IntersectionObserver(W,ae(B({},R),{root:o.ownerDocument}))}catch(D){n=new IntersectionObserver(W,R)}n.observe(e)}return u(!0),a}function o6(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),p=o||a?[...h?ca(h):[],...ca(t)]:[];p.forEach(A=>{o&&A.addEventListener("scroll",n,{passive:!0}),a&&A.addEventListener("resize",n)});const E=h&&c?i6(h,n):null;let T=-1,y=null;u&&(y=new ResizeObserver(A=>{let[O]=A;O&&O.target===h&&y&&(y.unobserve(t),cancelAnimationFrame(T),T=requestAnimationFrame(()=>{var R;(R=y)==null||R.observe(t)})),n()}),h&&!d&&y.observe(h),y.observe(t));let x,_=d?ji(e):null;d&&S();function S(){const A=ji(e);_&&!ky(_,A)&&n(),_=A,x=requestAnimationFrame(S)}return n(),()=>{var A;p.forEach(O=>{o&&O.removeEventListener("scroll",n),a&&O.removeEventListener("resize",n)}),E==null||E(),(A=y)==null||A.disconnect(),y=null,d&&cancelAnimationFrame(x)}}const s6=O4,a6=I4,u6=C4,l6=P4,c6=k4,d6=A4,f6=R4,h6=(e,t,n)=>{const r=new Map,o=B({platform:r6},n),a=ae(B({},o.platform),{_c:r});return S4(e,t,ae(B({},o),{platform:a}))};function Ny(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 ae(B({},o),{toJSON:()=>o})}function p6(e){if(!e)return Ny();const{x:t,y:n,width:r,height:o}=e;return Ny(t,n,r,o)}function m6(e,t){return{contextElement:Ft(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?p6(r):n.getBoundingClientRect()}}}var da=e=>({variable:e,reference:`var(${e})`}),Nr={arrowSize:da("--arrow-size"),arrowSizeHalf:da("--arrow-size-half"),arrowBg:da("--arrow-background"),transformOrigin:da("--transform-origin"),arrowOffset:da("--arrow-offset")},g6=e=>e==="top"||e==="bottom"?"y":"x";function E6(e,t){return{name:"transformOrigin",fn(n){var Te,z,X,se,ee;const{elements:r,middlewareData:o,placement:a,rects:u,y:c}=n,d=a.split("-")[0],h=g6(d),p=((Te=o.arrow)==null?void 0:Te.x)||0,E=((z=o.arrow)==null?void 0:z.y)||0,T=(t==null?void 0:t.clientWidth)||0,y=(t==null?void 0:t.clientHeight)||0,x=p+T/2,_=E+y/2,S=Math.abs(((X=o.shift)==null?void 0:X.y)||0),A=u.reference.height/2,O=y/2,R=(ee=(se=e.offset)==null?void 0:se.mainAxis)!=null?ee:e.gutter,H=typeof R=="number"?R+O:R!=null?R:O,W=S>H,D={top:`${x}px calc(100% + ${H}px)`,bottom:`${x}px ${-H}px`,left:`calc(100% + ${H}px) ${_}px`,right:`${-H}px ${_}px`}[d],K=`${x}px ${u.reference.y+A-c}px`,fe=!!e.overlap&&h==="y"&&W;return r.floating.style.setProperty(Nr.transformOrigin.variable,fe?K:D),{data:{transformOrigin:fe?K:D}}}}}var y6={name:"rects",fn({rects:e}){return{data:e}}},b6=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% + ${Nr.arrowOffset.reference})`}),{}}}};function T6(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var x6={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 eh(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function w6(e,t,n){const r=e||t.createElement("div");return d6({element:r,padding:n.arrowPadding})}function _6(e,t){var n;if(!BR((n=t.offset)!=null?n:t.gutter))return s6(({placement:r})=>{var p,E,T,y;const o=((e==null?void 0:e.clientHeight)||0)/2,a=(E=(p=t.offset)==null?void 0:p.mainAxis)!=null?E:t.gutter,u=typeof a=="number"?a+o:a!=null?a:o,{hasAlign:c}=T6(r),d=c?void 0:t.shift,h=(y=(T=t.offset)==null?void 0:T.crossAxis)!=null?y:d;return kf({crossAxis:h,mainAxis:u,alignmentAxis:t.shift})})}function v6(e){if(!e.flip)return;const t=eh(e.boundary);return u6(ae(B({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function S6(e){if(!e.slide&&!e.overlap)return;const t=eh(e.boundary);return a6(ae(B({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:f6()}))}function A6(e){return l6({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 C6(e){var t;if(e.hideWhenDetached)return c6({strategy:"referenceHidden",boundary:(t=eh(e.boundary))!=null?t:"clippingAncestors"})}function k6(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function N6(e,t,n={}){const r=m6(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},x6,n),a=t.querySelector("[data-part=arrow]"),u=[_6(a,o),v6(o),S6(o),w6(a,t.ownerDocument,o),b6(a),E6({gutter:o.gutter,offset:o.offset,overlap:o.overlap},a),A6(o),C6(o),y6],{placement:c,strategy:d,onComplete:h,onPositioned:p}=o,E=()=>$e(null,null,function*(){var H;if(!r||!t)return;const _=yield h6(r,t,{placement:c,middleware:u,strategy:d});h==null||h(_),p==null||p({placed:!0});const S=Ro(t),A=Oy(S,_.x),O=Oy(S,_.y);t.style.setProperty("--x",`${A}px`),t.style.setProperty("--y",`${O}px`),o.hideWhenDetached&&(((H=_.middlewareData.hide)==null?void 0:H.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 W=Lo(R);t.style.setProperty("--z-index",W.zIndex)}}),T=()=>$e(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),p==null||p({placed:!0})):yield E()}),y=k6(o.listeners),x=o.listeners?o6(r,t,T,y):WR;return T(),()=>{x==null||x(),p==null||p({placed:!1})}}function Iy(e,t,n={}){const c=n,{defer:r}=c,o=sn(c,["defer"]),a=r?Ot:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof t=="function"?t():t;u.push(N6(d,h,o))})),()=>{u.forEach(d=>d==null?void 0:d())}}var O6={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function I6(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:Nr.arrowSize.reference,height:Nr.arrowSize.reference,[Nr.arrowSizeHalf.variable]:`calc(${Nr.arrowSize.reference} / 2)`,[Nr.arrowOffset.variable]:`calc(${Nr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?O6[t.split("-")[0]]:void 0,background:Nr.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 Vo=new WeakMap,El=new WeakMap,yl={},th=0,Ry=e=>e&&(e.host||Ry(e.parentNode)),R6=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=Ry(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),P6=new Set(["script","output","status","next-route-announcer"]),L6=e=>P6.has(e.localName)||e.role==="status"||e.hasAttribute("aria-live")?!0:e.matches("[data-live-announcer]"),D6=(e,t)=>{const{parentNode:n,markerName:r,controlAttribute:o,followControlledElements:a=!0}=t,u=R6(n,Array.isArray(e)?e:[e]);yl[r]||(yl[r]=new WeakMap);const c=yl[r],d=[],h=new Set,p=new Set(u),E=y=>{!y||h.has(y)||(h.add(y),E(y.parentNode))};u.forEach(y=>{E(y),a&&Ft(y)&&qE(y,x=>{E(x)})});const T=y=>{!y||p.has(y)||Array.prototype.forEach.call(y.children,x=>{if(h.has(x))T(x);else try{if(L6(x))return;const S=x.getAttribute(o)==="true",A=(Vo.get(x)||0)+1,O=(c.get(x)||0)+1;Vo.set(x,A),c.set(x,O),d.push(x),A===1&&S&&El.set(x,!0),O===1&&x.setAttribute(r,""),S||x.setAttribute(o,"true")}catch(_){console.error("[zag-js > ariaHidden] cannot operate on ",x,_)}})};return T(n),h.clear(),th++,()=>{d.forEach(y=>{const x=Vo.get(y)-1,_=c.get(y)-1;Vo.set(y,x),c.set(y,_),x||(El.has(y)||y.removeAttribute(o),El.delete(y)),_||y.removeAttribute(r)}),th--,th||(Vo=new WeakMap,Vo=new WeakMap,El=new WeakMap,yl={})}},M6=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,F6=(e,t=M6(e),n="data-aria-hidden",r=!0)=>{if(t)return D6(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},B6=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function Py(e,t={}){const{defer:n=!0}=t,r=n?B6:a=>a(),o=[];return o.push(r(()=>{const u=(typeof e=="function"?e():e).filter(Boolean);u.length!==0&&o.push(F6(u))})),()=>{o.forEach(a=>a==null?void 0:a())}}function U6(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 H6(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",Dy="focus.outside";function z6(e){for(const t of e)if(Ft(t)&&fr(t))return!0;return!1}var My=e=>"clientY"in e;function j6(e,t){if(!My(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 $6(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||!My(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 $6(u,c)?r||a:!1}function V6(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:a,defer:u,followControlledElements:c=!0}=t;if(!e)return;const d=dr(e),h=Ro(e),p=U6(h),E=H6(h);function T(R,H){if(!Ft(H)||!H.isConnected||Io(e,H)||j6(e,R)||c&&VE(e,H))return!1;const W=d.querySelector(`[aria-controls="${e.id}"]`);if(W){const K=Ff(W);if(Fy(R,K))return!1}const D=Ff(e);return Fy(R,D)?!1:!(n!=null&&n(H))}const y=new Set,x=Bi(e==null?void 0:e.getRootNode());function _(R){function H(W){var Te,z;const D=u&&!YE()?Ot:X=>X(),K=W!=null?W:R,fe=(z=(Te=K==null?void 0:K.composedPath)==null?void 0:Te.call(K))!=null?z:[K==null?void 0:K.target];D(()=>{const X=x?fe[0]:Gn(R);if(!(!e||!T(R,X))){if(o||a){const se=Cf(o,a);e.addEventListener(Ly,se,{once:!0})}By(e,Ly,{bubbles:!1,cancelable:!0,detail:{originalEvent:K,contextmenu:kP(K),focusable:z6(fe),target:X}})}})}R.pointerType==="touch"?(y.forEach(W=>W()),y.add(Bt(d,"click",H,{once:!0})),y.add(E.addEventListener("click",H,{once:!0})),y.add(p.addEventListener("click",H,{once:!0}))):H()}const S=new Set,A=setTimeout(()=>{S.add(Bt(d,"pointerdown",_,!0)),S.add(E.addEventListener("pointerdown",_,!0)),S.add(p.addEventListener("pointerdown",_,!0))},0);function O(R){(u?Ot:W=>W())(()=>{var K,fe;const W=(fe=(K=R==null?void 0:R.composedPath)==null?void 0:K.call(R))!=null?fe:[R==null?void 0:R.target],D=x?W[0]:Gn(R);if(!(!e||!T(R,D))){if(r||a){const Te=Cf(r,a);e.addEventListener(Dy,Te,{once:!0})}By(e,Dy,{bubbles:!1,cancelable:!0,detail:{originalEvent:R,contextmenu:!1,focusable:fr(D),target:D}})}})}return YE()||(S.add(Bt(d,"focusin",O,!0)),S.add(E.addEventListener("focusin",O,!0)),S.add(p.addEventListener("focusin",O,!0))),()=>{clearTimeout(A),y.forEach(R=>R()),S.forEach(R=>R())}}function q6(e,t){const{defer:n}=t,r=n?Ot:a=>a(),o=[];return o.push(r(()=>{const a=typeof e=="function"?e():e;o.push(V6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}function By(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function Y6(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return Bt(dr(e),"keydown",n,{capture:!0})}var Uy="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=>Io(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>Io(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];G6(e,Uy,o=>{var a;(a=r.requestDismiss)==null||a.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),W6(e,Uy,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function W6(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 G6(e,t,n){e.addEventListener(t,n,{once:!0})}var Hy;function zy(){Dn.layers.forEach(({node:e})=>{e.style.pointerEvents=Dn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function K6(e){e.style.pointerEvents=""}function Q6(e,t){const n=dr(e),r=[];return Dn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(Hy=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[a,u]=XP(()=>{const c=o();return Ft(c)?c:null},{timeout:1e3});a.then(c=>r.push(il(c,{pointerEvents:"auto"}))),r.push(u)}),()=>{Dn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=Hy,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function X6(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Nf("[@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),zy();function p(_){var A,O;const S=Gn(_.detail.originalEvent);Dn.isBelowPointerBlockingLayer(e)||Dn.isInBranch(S)||((A=t.onPointerDownOutside)==null||A.call(t,_),(O=t.onInteractOutside)==null||O.call(t,_),!_.defaultPrevented&&(c&&console.log("onPointerDownOutside:",_.detail.originalEvent),r==null||r()))}function E(_){var A,O;const S=Gn(_.detail.originalEvent);Dn.isInBranch(S)||((A=t.onFocusOutside)==null||A.call(t,_),(O=t.onInteractOutside)==null||O.call(t,_),!_.defaultPrevented&&(c&&console.log("onFocusOutside:",_.detail.originalEvent),r==null||r()))}function T(_){var S;Dn.isTopMost(e)&&((S=t.onEscapeKeyDown)==null||S.call(t,_),!_.defaultPrevented&&r&&(_.preventDefault(),r()))}function y(_){var R;if(!e)return!1;const S=typeof u=="function"?u():u,A=Array.isArray(S)?S:[S],O=(R=t.persistentElements)==null?void 0:R.map(H=>H()).filter(Ft);return O&&A.push(...O),A.some(H=>Io(H,_))||Dn.isInNestedLayer(e,_)}const x=[a?Q6(e,t.persistentElements):void 0,Y6(e,T),q6(e,{exclude:y,onFocusOutside:E,onPointerDownOutside:p,defer:t.defer})];return()=>{Dn.remove(e),zy(),K6(e),x.forEach(_=>_==null?void 0:_())}}function jy(e,t){const{defer:n}=t,r=n?Ot:a=>a(),o=[];return o.push(r(()=>{const a=No(e)?e():e;o.push(X6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}var J6=Object.defineProperty,Z6=(e,t,n)=>t in e?J6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ht=(e,t,n)=>Z6(e,typeof t!="symbol"?t+"":t,n),$y={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()}},eL=[],tL=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||el(o))a&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let u,c=!0;if(this.state.mostRecentlyFocusedNode)if(oa(this.state.mostRecentlyFocusedNode)>0){const d=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:h}=this.state.containerGroups[d];if(h.length>0){const p=h.findIndex(E=>E===this.state.mostRecentlyFocusedNode);p>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?p+1<h.length&&(u=h[p+1],c=!1):p-1>=0&&(u=h[p-1],c=!1))}}else this.state.containerGroups.some(d=>d.tabbableNodes.some(h=>oa(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(ha(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}ha(this.config.allowOutsideClick,r)||r.preventDefault()}}),ht(this,"handleClick",r=>{const o=Gn(r);this.findContainerIndex(o,r)>=0||ha(this.config.clickOutsideDeactivates,r)||ha(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;fa(r)&&r.preventDefault(),this.tryFocus(a)}}),ht(this,"handleEscapeKey",r=>{nL(r)&&ha(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 bP(h)?!0:h.id&&!this.state.containers.some(p=>p.contains(h))?TP(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&&!fr(r)){const o=Po(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!==Po(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,rL(r)&&r.select()}}),ht(this,"deactivate",r=>{if(!this.state.active)return this;const o=B({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(),$y.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=()=>{Vy(()=>{if(d){const p=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(p)}u==null||u()})};if(d&&c){const p=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);return c(p).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 p=this.state.tabbableGroups.findIndex(({firstTabbableNode:E})=>u===E);if(p<0&&((h==null?void 0:h.container)===u||fr(u)&&!Ui(u)&&!(h!=null&&h.nextTabbableNode(u,!1)))&&(p=d),p>=0){const E=p===0?this.state.tabbableGroups.length-1:p-1,T=this.state.tabbableGroups[E];c=oa(u)>=0?T.lastTabbableNode:T.lastDomTabbableNode}else fa(o)||(c=h==null?void 0:h.nextTabbableNode(u,!1))}else{let p=this.state.tabbableGroups.findIndex(({lastTabbableNode:E})=>u===E);if(p<0&&((h==null?void 0:h.container)===u||fr(u)&&!Ui(u)&&!(h!=null&&h.nextTabbableNode(u)))&&(p=d),p>=0){const E=p===this.state.tabbableGroups.length-1?0:p+1,T=this.state.tabbableGroups[E];c=oa(u)>=0?T.firstTabbableNode:T.firstDomTabbableNode}else fa(o)||(c=h==null?void 0:h.nextTabbableNode(u))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||eL;const n=B({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return fa(r)&&!r.shiftKey},isKeyBackward(r){return fa(r)&&r.shiftKey}},t);this.doc=n.document||dr(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=>{gP(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?VE(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Do(e,{getShadowRoot:this.config.getShadowRoot}),n=ZE(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(oa(t[h])>0){c=!0;break}function d(h,p=!0){const E=t.indexOf(h);if(E>=0)return t[E+(p?1:-1)];const T=n.indexOf(h);if(!(T<0)){if(p){for(let y=T+1;y<n.length;y++)if(Ui(n[y]))return n[y]}else for(let y=T-1;y>=0;y--)if(Ui(n[y]))return n[y]}}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 $y.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Vy(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(Bt(this.doc,"focusin",this.handleFocus,!0),Bt(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),Bt(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),Bt(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),Bt(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),Bt(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=Po(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)}},fa=e=>e.key==="Tab",ha=(e,...t)=>typeof e=="function"?e(...t):e,nL=e=>!e.isComposing&&e.key==="Escape",Vy=e=>setTimeout(e,0),rL=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function qy(e,t={}){let n;const r=Ot(()=>{const o=typeof e=="function"?e():e;if(o){n=new tL(o,ae(B({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:dr(o)}));try{n.activate()}catch(a){}}});return function(){n==null||n.deactivate(),r()}}var nh="data-scroll-lock";function iL(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function Yy(e){const t=Lo(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function Wy(e){var y;const t=e!=null?e:document,n=(y=t.defaultView)!=null?y:window,{documentElement:r,body:o}=t;if(o.hasAttribute(nh))return;const u=Yy(r)||Yy(o),c=n.innerWidth-r.clientWidth;o.setAttribute(nh,"");const d=()=>KP(r,"--scrollbar-width",`${c}px`),h=iL(r),p=()=>{const x={overflow:"hidden"};return!u&&c>0&&(x[h]=`${c}px`),il(o,x)},E=()=>{var W,D;const{scrollX:x,scrollY:_,visualViewport:S}=n,A=(W=S==null?void 0:S.offsetLeft)!=null?W:0,O=(D=S==null?void 0:S.offsetTop)!=null?D:0,R={position:"fixed",overflow:"hidden",top:`${-(_-Math.floor(O))}px`,left:`${-(x-Math.floor(A))}px`,right:"0"};!u&&c>0&&(R[h]=`${c}px`);const H=il(o,R);return()=>{H==null||H(),n.scrollTo({left:x,top:_,behavior:"instant"})}},T=[d(),tl()?E():p()];return()=>{T.forEach(x=>x==null?void 0:x()),o.removeAttribute(nh)}}var oL=zi("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),Er=oL.build(),Gy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},Ky=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},rh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},Qy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},sL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},ih=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},oh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},aL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},Xy=e=>e.getById(Gy(e)),qo=e=>e.getById(Ky(e)),Yo=e=>e.getById(rh(e)),Jy=e=>e.getById(Qy(e)),uL=e=>e.getById(ih(e)),lL=e=>e.getById(oh(e));function cL(e,t){const{state:n,context:r,send:o,computed:a,prop:u,scope:c}=e,d=n.matches("open"),h=r.get("currentPlacement"),p=a("currentPortalled"),E=r.get("renderedElements"),T=I6(ae(B({},u("positioning")),{placement:h}));return{portalled:p,open:d,setOpen(y){n.matches("open")!==y&&o({type:y?"OPEN":"CLOSE"})},reposition(y={}){o({type:"POSITIONING.SET",options:y})},getArrowProps(){return t.element(ae(B({id:sL(c)},Er.arrow.attrs),{dir:u("dir"),style:T.arrow}))},getArrowTipProps(){return t.element(ae(B({},Er.arrowTip.attrs),{dir:u("dir"),style:T.arrowTip}))},getAnchorProps(){return t.element(ae(B({},Er.anchor.attrs),{dir:u("dir"),id:Gy(c)}))},getTriggerProps(){return t.button(ae(B({},Er.trigger.attrs),{dir:u("dir"),type:"button","data-placement":h,id:Ky(c),"aria-haspopup":"dialog","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":rh(c),onPointerDown(y){WE(y)&&AP()&&y.currentTarget.focus()},onClick(y){y.defaultPrevented||o({type:"TOGGLE"})},onBlur(y){o({type:"TRIGGER_BLUR",target:y.relatedTarget})}}))},getIndicatorProps(){return t.element(ae(B({},Er.indicator.attrs),{dir:u("dir"),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ae(B({id:Qy(c)},Er.positioner.attrs),{dir:u("dir"),style:T.floating}))},getContentProps(){return t.element(ae(B({},Er.content.attrs),{dir:u("dir"),id:rh(c),tabIndex:-1,role:"dialog","aria-modal":zE(u("modal")),hidden:!d,"data-state":d?"open":"closed","data-expanded":Oo(d),"aria-labelledby":E.title?ih(c):void 0,"aria-describedby":E.description?oh(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(ae(B({},Er.title.attrs),{id:ih(c),dir:u("dir")}))},getDescriptionProps(){return t.element(ae(B({},Er.description.attrs),{id:oh(c),dir:u("dir")}))},getCloseTriggerProps(){return t.button(ae(B({},Er.closeTrigger.attrs),{dir:u("dir"),id:aL(c),type:"button","aria-label":"close",onClick(y){y.defaultPrevented||(y.stopPropagation(),o({type:"CLOSE"}))}}))}}}var dL={props({props:e}){return ae(B({closeOnInteractOutside:!0,closeOnEscape:!0,autoFocus:!0,modal:!1,portalled:!0},e),{positioning:B({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=Xy(n))!=null?a:qo(n);return Iy(r,()=>Jy(n),ae(B({},t("positioning")),{defer:!0,onComplete(u){e.set("currentPlacement",u.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Yo(n);let o=!0;return jy(r,{type:"popover",pointerBlocking:t("modal"),exclude:qo(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:WP(()=>Yo(t),{triggerElement:qo(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?Py(()=>[Yo(t),qo(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return Wy(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?qy(()=>Yo(t),{initialFocus:()=>ey({root:Yo(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=Xy(n))!=null?u:qo(n);Iy(o,()=>Jy(n),ae(B(B({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){Ot(()=>{Object.assign(e.get("renderedElements"),{title:!!uL(t),description:!!lL(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||Ot(()=>{const n=ey({root:Yo(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||Ot(()=>{const a=qo(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})}}}};Bo()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[_F,bl]=Hi({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[vF,sh]=Hi({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),fL=e=>{const t=Z.useId(),{getRootNode:n}=bl(),{dir:r}=sh(),o=B({id:t,dir:r,getRootNode:n},e),a=sl(dL,o);return cL(a,Hf)},hL=e=>{const[t,u]=ly(e),c=u,{children:n}=c,r=sn(c,["children"]),o=fL(r),a=$f(It({present:o.open},t));return v.jsx(u4,{value:o,children:v.jsx(sy,{value:a,children:n})})},Zy=Z.forwardRef((e,t)=>{const n=jf(),r=sa(),o=It(ae(B({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return v.jsx(Qt.button,ae(B({},o),{ref:t}))});Zy.displayName="PopoverTrigger";function pL(e){return mt({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 mL(e){return mt({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 eb(e){return mt({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 tb(e){return mt({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 nb(e){return mt({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 gL=({className:e,componentType:t,children:n})=>{const[r,o]=Z.useState(!1),{globalClassName:a}=At(),u=h=>{o(h.open)},c=Z.useCallback(()=>{o(!1)},[]),d=Z.useMemo(()=>({closeMenu:c}),[c]);return v.jsxs(hL,{open:r,onOpenChange:u,positioning:{placement:"bottom-end"},children:[v.jsx(Zy,{"aria-label":`Overflow menu for ${t}`,className:$(`${U}-overflow-menu-button-trigger`,`${U}-icon-button`,a,e,`cim-${t}-component`),children:v.jsx(nb,{})}),v.jsx(uy,{children:v.jsx(ay,{className:$(`${U}-overflow-menu-list`,a,`cim-${t}-component`),children:v.jsx(LE.Provider,{value:d,children:n})})})]})};function rb(e){return mt({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 ib(e){return mt({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[EL,$i]=Hi({name:"CarouselContext",hookName:"useCarouselContext",providerName:"<CarouselProvider />"}),ah=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getControlProps(),e);return v.jsx(Qt.div,ae(B(B({},r),e),{ref:t}))});ah.displayName="CarouselControl";const uh=Z.forwardRef((e,t)=>{const[n,r]=aa()(e,["readOnly","index"]),o=$i(),a=It(o.getIndicatorProps(n),r);return v.jsx(Qt.button,ae(B({},a),{ref:t}))});uh.displayName="CarouselIndicator";const lh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getIndicatorGroupProps(),e);return v.jsx(Qt.div,ae(B({},r),{ref:t}))});lh.displayName="CarouselIndicatorGroup";const ch=Z.forwardRef((e,t)=>{const[n,r]=aa()(e,["index","snapAlign"]),o=$i(),a=It(o.getItemProps(n),r);return v.jsx(Qt.div,ae(B({},a),{ref:t}))});ch.displayName="CarouselItem";const dh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getItemGroupProps(),e);return v.jsx(Qt.div,ae(B({},r),{ref:t}))});dh.displayName="CarouselItemGroup";const fh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getNextTriggerProps(),e);return v.jsx(Qt.button,ae(B({},r),{ref:t}))});fh.displayName="CarouselNextTrigger";const hh=Z.forwardRef((e,t)=>{const n=$i(),r=It(n.getPrevTriggerProps(),e);return v.jsx(Qt.button,ae(B({},r),{ref:t}))});hh.displayName="CarouselPrevTrigger";function yL(e){const t=Lo(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,y){let x=parseFloat(T);return/%/.test(T)&&(x/=100,x*=y),Number.isNaN(x)?0:x}let d=c(r,n.width),h=c(o,n.height),p=c(a,n.width),E=c(u,n.height);return{x:{before:d,after:p},y:{before:h,after:E}}}function bL(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 ob(e){let t=[];for(const n of e.children)t=t.concat(n,ob(n));return t}function sb(e,t=!1){const n=e.getBoundingClientRect(),r={x:{start:[],center:[],end:[]},y:{start:[],center:[],end:[]}},o=t?ob(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 p of o){const E=p.getBoundingClientRect();if(!bL(n,E,u))continue;const T=Lo(p);let[y,x]=T.getPropertyValue("scroll-snap-align").split(" ");typeof x=="undefined"&&(x=y);const _=a==="x"?x:y,S=E[c]-n[c]+e[h];switch(_){case"none":break;case"start":r[a].start.push({node:p,position:S});break;case"center":r[a].center.push({node:p,position:S+E[d]/2});break;case"end":r[a].end.push({node:p,position:S+E[d]});break}}}return r}function ab(e){const t=e.getBoundingClientRect(),n=yL(e),r=sb(e),o={x:e.scrollWidth-e.offsetWidth,y:e.scrollHeight-e.offsetHeight};return{x:ub([...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(lb(0,o.x))),y:ub([...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(lb(0,o.y)))}}function TL(e,t,n){const r=sb(e),o=[...r[t].start,...r[t].center,...r[t].end];for(const a of o)if(n(a.node))return a.position}var ub=e=>[...new Set(e)],lb=(e,t)=>n=>Math.max(e,Math.min(t,n)),xL=zi("carousel").parts("root","itemGroup","item","control","nextTrigger","prevTrigger","indicatorGroup","indicator","autoplayTrigger"),Or=xL.build(),wL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.root)!=null?n:`carousel:${e.id}`},_L=(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}`},Tl=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.itemGroup)!=null?n:`carousel:${e.id}:item-group`},vL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.nextTrigger)!=null?n:`carousel:${e.id}:next-trigger`},SL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.prevTrigger)!=null?n:`carousel:${e.id}:prev-trigger`},AL=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.indicatorGroup)!=null?n:`carousel:${e.id}:indicator-group`},cb=(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(Tl(e)),db=e=>GP(hn(e),"[data-part=item]"),CL=(e,t)=>e.getById(cb(e,t)),fb=e=>{const t=hn(e);if(!t)return;const n=Do(t);t.setAttribute("tabindex",n.length>0?"-1":"0")};function kL(e,t){const{state:n,context:r,computed:o,send:a,scope:u,prop:c}=e,d=n.matches("autoplay"),h=n.matches("dragging"),p=o("canScrollNext"),E=o("canScrollPrev"),T=o("isHorizontal"),y=Array.from(r.get("pageSnapPoints")),x=r.get("page"),_=c("slidesPerPage"),S=c("padding"),A=c("translations");return{isPlaying:d,isDragging:h,page:x,pageSnapPoints:y,canScrollNext:p,canScrollPrev:E,getProgress(){return x/y.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(ae(B({},Or.root.attrs),{id:wL(u),role:"region","aria-roledescription":"carousel","data-orientation":c("orientation"),dir:c("dir"),style:{"--slides-per-page":_,"--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(ae(B({},Or.itemGroup.attrs),{id:Tl(u),"data-orientation":c("orientation"),"data-dragging":Oo(h),dir:c("dir"),"aria-live":d?"off":"polite",onFocus(O){Io(O.currentTarget,Gn(O))&&a({type:"VIEWPORT.FOCUS"})},onBlur(O){Io(O.currentTarget,O.relatedTarget)||a({type:"VIEWPORT.BLUR"})},onMouseDown(O){if(O.defaultPrevented||!c("allowMouseDrag")||!WE(O))return;const R=Gn(O);fr(R)&&R!==O.currentTarget||(O.preventDefault(),a({type:"DRAGGING.START"}))},onWheel:GR(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"]:S,[T?"paddingInline":"paddingBlock"]:S,[T?"overflowX":"overflowY"]:"auto"}}))},getItemProps(O){const R=r.get("slidesInView").includes(O.index);return t.element(ae(B({},Or.item.attrs),{id:_L(u,O.index),dir:c("dir"),role:"group","data-index":O.index,"data-inview":Oo(R),"aria-roledescription":"slide","data-orientation":c("orientation"),"aria-label":A.item(O.index,c("slideCount")),"aria-hidden":zE(!R),style:{scrollSnapAlign:(()=>{var fe;const H=(fe=O.snapAlign)!=null?fe:"start",W=c("slidesPerMove"),D=W==="auto"?Math.floor(c("slidesPerPage")):W;return(O.index+D)%D===0?H:void 0})()}}))},getControlProps(){return t.element(ae(B({},Or.control.attrs),{"data-orientation":c("orientation")}))},getPrevTriggerProps(){return t.button(ae(B({},Or.prevTrigger.attrs),{id:SL(u),type:"button",disabled:!E,dir:c("dir"),"aria-label":A.prevTrigger,"data-orientation":c("orientation"),"aria-controls":Tl(u),onClick(O){O.defaultPrevented||a({type:"PAGE.PREV",src:"trigger"})}}))},getNextTriggerProps(){return t.button(ae(B({},Or.nextTrigger.attrs),{dir:c("dir"),id:vL(u),type:"button","aria-label":A.nextTrigger,"data-orientation":c("orientation"),"aria-controls":Tl(u),disabled:!p,onClick(O){O.defaultPrevented||a({type:"PAGE.NEXT",src:"trigger"})}}))},getIndicatorGroupProps(){return t.element(ae(B({},Or.indicatorGroup.attrs),{dir:c("dir"),id:AL(u),"data-orientation":c("orientation"),onKeyDown(O){if(O.defaultPrevented)return;const R="indicator",H={ArrowDown(K){T||(a({type:"PAGE.NEXT",src:R}),K.preventDefault())},ArrowUp(K){T||(a({type:"PAGE.PREV",src:R}),K.preventDefault())},ArrowRight(K){T&&(a({type:"PAGE.NEXT",src:R}),K.preventDefault())},ArrowLeft(K){T&&(a({type:"PAGE.PREV",src:R}),K.preventDefault())},Home(K){a({type:"PAGE.SET",index:0,src:R}),K.preventDefault()},End(K){a({type:"PAGE.SET",index:y.length-1,src:R}),K.preventDefault()}},W=IP(O,{dir:c("dir"),orientation:c("orientation")}),D=H[W];D==null||D(O)}}))},getIndicatorProps(O){return t.button(ae(B({},Or.indicator.attrs),{dir:c("dir"),id:cb(u,O.index),type:"button","data-orientation":c("orientation"),"data-index":O.index,"data-readonly":Oo(O.readOnly),"data-current":Oo(O.index===x),"aria-label":A.indicator(O.index),onClick(R){R.defaultPrevented||O.readOnly||a({type:"PAGE.SET",index:O.index,src:"indicator"})}}))},getAutoplayTriggerProps(){return t.button(ae(B({},Or.autoplayTrigger.attrs),{type:"button","data-orientation":c("orientation"),"data-pressed":Oo(d),"aria-label":d?A.autoplayStop:A.autoplayStart,onClick(O){O.defaultPrevented||a({type:d?"AUTOPLAY.PAUSE":"AUTOPLAY.START"})}}))}}}var NL={props({props:e}){return eP(e,["slideCount"],"carousel"),ae(B({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:B({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:OL(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 FR(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"}),fb(e)});return fb(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"})};Ot(()=>{o(),Ot(()=>{t({type:"PAGE.SCROLL",instant:!0})})});const a=new r.ResizeObserver(o);return db(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 p=h.target,E=Number((T=p.dataset.index)!=null?T:"-1");return E==null||Number.isNaN(E)||E===-1?d:h.isIntersecting?RR(d,E):PR(d,E)},n.get("slidesInView"));n.set("slidesInView",LR(c))},{root:r,threshold:t("inViewThreshold")});return db(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackScroll({send:e,refs:t,scope:n}){const r=hn(n);return r?Bt(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 Bt(n,"visibilitychange",()=>{n.visibilityState!=="visible"&&t({type:"AUTOPLAY.PAUSE",src:"doc.hidden"})})},trackPointerMove({scope:e,send:t}){const n=e.getDoc();return qP(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 Bt(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=UE((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=ME(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=DR(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=TL(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=UE(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=ab(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=ab(r),c=u.x.reduce((h,p)=>Math.abs(p-o)<Math.abs(h-o)?p:h,u.x[0]),d=u.y.reduce((h,p)=>Math.abs(p-a)<Math.abs(h-a)?p:h,u.y[0]);Ot(()=>{r.scrollTo({left:c,top:d,behavior:"smooth"});const h=n("isHorizontal")?c:d;t.set("page",t.get("pageSnapPoints").indexOf(h));const p=r.dataset.scrollSnapType;p&&(r.style.setProperty("scroll-snap-type",p),delete r.dataset.scrollSnapType)})},focusIndicatorEl({context:e,event:t,scope:n}){if(t.src!=="indicator")return;const r=CL(n,e.get("page"));r&&Ot(()=>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 OL(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}Bo()(["dir","getRootNode","id","ids","loop","page","defaultPage","onPageChange","orientation","slideCount","slidesPerPage","slidesPerMove","spacing","padding","autoplay","allowMouseDrag","inViewThreshold","translations","snapType","onDragStatusChange","onAutoplayStatusChange"]),Bo()(["index","readOnly"]),Bo()(["index","snapAlign"]);const IL=e=>{const t=Z.useId(),{getRootNode:n}=bl(),{dir:r}=sh(),o=B({id:t,dir:r,getRootNode:n},e),a=sl(NL,o);return kL(a,Hf)},ph=Z.forwardRef((e,t)=>{const[n,r]=aa()(e,["allowMouseDrag","autoplay","defaultPage","id","ids","inViewThreshold","loop","onAutoplayStatusChange","onDragStatusChange","onPageChange","orientation","padding","page","slideCount","slidesPerMove","slidesPerPage","snapType","spacing","translations"]),o=IL(n),a=It(o.getRootProps(),r);return v.jsx(EL,{value:o,children:v.jsx(Qt.div,ae(B({},a),{ref:t}))})});ph.displayName="CarouselRoot";const RL=180,PL=e=>{const t=e.trim(),n=parseFloat(t);return Number.isNaN(n)?0:t.endsWith("rem")?n*16:n},LL=({globalClassName:e,className:t,itemMinWidth:n=RL,spacing:r="0.5rem",loop:o=!1,allowMouseDrag:a=!0,showIndicators:u=!0,showNavigation:c=!0,onPageChange:d,ariaLabel:h="Product carousel",children:p})=>{const E=Array.from(p),T=E.length,y=Z.useRef(null),[x,_]=Z.useState(0),{width:S}=yS();Z.useLayoutEffect(()=>{y.current&&_(y.current.getBoundingClientRect().width)},[S,T]);const A=PL(r),O=n+A,R=x>0?(x+A)/O:1,H=Math.max(1,Math.floor(R));if(T===0)return null;const W=T>H,D=Math.ceil(T/H),K=W?Math.max(1,R):H;return v.jsxs(ph,{ref:y,className:$(e,t,`${U}-carousel`),slidesPerPage:K,slidesPerMove:H,spacing:r,loop:o,allowMouseDrag:a,slideCount:T,onPageChange:d,"aria-label":h,children:[v.jsx(dh,{className:$(e,`${U}-carousel__item-group`,{"carousel-row-container":!W}),children:E.map((fe,Te)=>v.jsx(ch,{index:Te,className:$(e,`${U}-carousel__item`),children:fe},Te))}),c&&W&&v.jsxs(ah,{className:$(e,`${U}-carousel__control`),children:[v.jsx(hh,{className:$(e,`${U}-carousel__prev-trigger`),"aria-label":"Previous slide",children:v.jsx(eb,{size:"16px"})}),v.jsx(fh,{className:$(e,`${U}-carousel__next-trigger`),"aria-label":"Next slide",children:v.jsx(tb,{size:"16px"})})]}),u&&W&&v.jsx(lh,{className:$(e,`${U}-carousel__indicator-group`),children:Array.from({length:D},(fe,Te)=>v.jsx(uh,{index:Te,className:$(e,`${U}-carousel__indicator`),"aria-label":`Go to slide group ${Te+1}`},Te))})]})},DL=({className:e,label:t="Close",onClick:n,disabled:r=!1})=>v.jsx("button",{"aria-label":t,title:t,className:$(e,`${U}-close-button`),disabled:r,onClick:n,children:v.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:v.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"})})}),[ML,FL]=Hi({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),BL=e=>aa()(e,["lazyMount","unmountOnExit"]),[UL,pa]=Hi({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),hb=Z.forwardRef((e,t)=>{const n=pa(),r=FL(),o=$f(ae(B({},r),{present:n.open})),a=It(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:v.jsx(Qt.div,ae(B({},a),{ref:al(o.ref,t)}))});hb.displayName="DialogBackdrop";const mh=Z.forwardRef((e,t)=>{const n=pa(),r=sa(),o=It(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:v.jsx(Qt.div,ae(B({},o),{ref:al(r.ref,t)}))});mh.displayName="DialogContent";const gh=Z.forwardRef((e,t)=>{const n=pa(),r=It(n.getDescriptionProps(),e);return v.jsx(Qt.div,ae(B({},r),{ref:t}))});gh.displayName="DialogDescription";const Eh=Z.forwardRef((e,t)=>{const n=pa(),r=It(n.getPositionerProps(),e);return sa().unmounted?null:v.jsx(Qt.div,ae(B({},r),{ref:t}))});Eh.displayName="DialogPositioner";var HL=zi("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),Vi=HL.build(),pb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},mb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},yh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},gb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},bh=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`},Eb=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},xl=e=>e.getById(yh(e)),zL=e=>e.getById(pb(e)),jL=e=>e.getById(mb(e)),$L=e=>e.getById(gb(e)),VL=e=>e.getById(bh(e)),qL=e=>e.getById(Th(e)),YL=e=>e.getById(Eb(e));function WL(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(ae(B({},Vi.trigger.attrs),{dir:a("dir"),id:gb(u),"aria-haspopup":"dialog",type:"button","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":yh(u),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(ae(B({},Vi.backdrop.attrs),{dir:a("dir"),hidden:!d,id:mb(u),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(ae(B({},Vi.positioner.attrs),{dir:a("dir"),id:pb(u),style:{pointerEvents:d?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(ae(B({},Vi.content.attrs),{dir:a("dir"),role:a("role"),hidden:!d,id:yh(u),tabIndex:-1,"data-state":d?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:bh(u),"aria-describedby":h.description?Th(u):void 0}))},getTitleProps(){return t.element(ae(B({},Vi.title.attrs),{dir:a("dir"),id:bh(u)}))},getDescriptionProps(){return t.element(ae(B({},Vi.description.attrs),{dir:a("dir"),id:Th(u)}))},getCloseTriggerProps(){return t.button(ae(B({},Vi.closeTrigger.attrs),{dir:a("dir"),id:Eb(u),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var GL={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>YL(t):void 0,o=typeof e.modal=="boolean"?e.modal:!0;return B({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 jy(()=>xl(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[$L(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 Wy(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?qy(()=>xl(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")?Py(()=>[xl(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){Ot(()=>{e.set("rendered",{title:!!VL(t),description:!!qL(t)})})},syncZIndex({scope:e}){Ot(()=>{const t=xl(e);if(!t)return;const n=Lo(t);[zL(e),jL(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})}}}};Bo()(["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 KL=e=>{const t=Z.useId(),{getRootNode:n}=bl(),{dir:r}=sh(),o=B({id:t,getRootNode:n,dir:r},e),a=sl(GL,o);return WL(a,Hf)},yb=e=>{const[t,c]=ly(e),d=c,{children:n}=d,r=sn(d,["children"]),[o]=BL(t),a=KL(r),u=$f(It({present:a.open},t));return v.jsx(UL,{value:a,children:v.jsx(ML,{value:o,children:v.jsx(sy,{value:u,children:n})})})},bb=Z.forwardRef((e,t)=>{const n=pa(),r=It(n.getTitleProps(),e);return v.jsx(Qt.h2,ae(B({},r),{ref:t}))});bb.displayName="DialogTitle";const QL=({children:e})=>{const[t,n]=Z.useState(!1),r=Z.useMemo(()=>({toggleMenu:()=>n(a=>!a),closeMenu:()=>n(!1)}),[]),o=Z.useMemo(()=>({isOpen:t}),[t]);return v.jsx(Af.Provider,{value:r,children:v.jsx(PE.Provider,{value:o,children:e})})},Tb=()=>Z.useContext(PE),xb=()=>{const e=Z.useContext(Af);if(!e)throw new Error("useOverflowMenuDispatch must be used within an OverflowMenuProvider");return e},XL=`${U}-overflow-menu-button-trigger`,JL=({componentType:e,children:t})=>{const{isOpen:n}=Tb(),{closeMenu:r}=xb(),{globalClassName:o}=At(),a=Z.useRef(null);return Z.useEffect(()=>{if(!n)return;const u=d=>{d.key==="Escape"&&r()},c=d=>{const h=d.target;h instanceof Element&&h.closest(`.${XL}`)||a.current&&!a.current.contains(h)&&r()};return document.addEventListener("keydown",u),document.addEventListener("mousedown",c),()=>{document.removeEventListener("keydown",u),document.removeEventListener("mousedown",c)}},[n,r]),n?v.jsx("div",{ref:a,role:"menu","aria-label":`Overflow menu for ${e}`,className:$(`${U}-overflow-panel`,o,`cim-${e}-component`),children:t}):null},ZL=({componentType:e,className:t})=>{const{toggleMenu:n}=xb(),{isOpen:r}=Tb(),{globalClassName:o}=At();return v.jsx("button",{"aria-label":`Overflow menu for ${e}`,title:"More options","aria-expanded":r,"aria-haspopup":"menu",className:$(`${U}-overflow-menu-button-trigger`,`${U}-icon-button`,o,t,`cim-${e}-component`),onClick:n,children:v.jsx(nb,{})})},eD=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),{previousComponentType:r}=ki(),o=ra(),a=()=>{Su(r||"dialog"),o()};return t?v.jsx(ar,{className:$(n,`${U}-toggle-dialog-button`,`cim-${e}-component`),ariaLabel:"Collapse",title:"Collapse",onClick:a,icon:v.jsx(rb,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-toggle-dialog-button`,`cim-${e}-component`),onClick:a,children:[v.jsx(rb,{}),"Show ",r||"dialog"]})},tD=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),{isModalFullscreen:r}=ki(),o=ra(),a=()=>{xd(!r),o()},u=r?GS:KS,c="Toggle Fullscreen";return t?v.jsx(ar,{ariaLabel:c,title:c,className:$(n,`${U}-modal-fullscreen-button`,`cim-${e}-component`),icon:v.jsx(u,{}),onClick:a}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-modal-fullscreen-button`,`cim-${e}-component`),onClick:a,children:[v.jsx(u,{}),c]})},nD=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),{dialogPosition:r}=ki(),o=ra(),a=r==="bottom-left",u=()=>{wd(a?"bottom-right":"bottom-left"),o()},c=a?mL:pL,d=a?"Move right":"Move left";return t?v.jsx(ar,{className:$(n,`${U}-left-right-toggle-button`,`cim-${e}-component`),ariaLabel:d,title:d,onClick:u,icon:v.jsx(c,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-left-right-toggle-button`,`cim-${e}-component`),onClick:u,children:[v.jsx(c,{}),d]})},wb=({componentType:e,onClearChat:t,onClose:n})=>{const{headerConfig:r,globalClassName:o}=At(),{mode:a}=ki(),u=a==="standalone",c=e==="modal",d=c?eD:Sb,h=c?tD:nD,p=Z.useMemo(()=>r?jS(r):{},[r]);return v.jsx(QL,{children:v.jsxs("div",{className:$(o,`${U}-${e}-header-wrapper`),style:{display:"flex",flexDirection:"column",position:"relative"},children:[v.jsxs("div",{className:$(o,`${U}-${e}-header`,{standalone:u,embedded:!u}),style:p,children:[(r==null?void 0:r.logoUrl)&&v.jsx("img",{alt:"",role:"img",className:$(o,`${U}-${e}-logo`,{standalone:u,embedded:!u}),src:r.logoUrl}),v.jsx(bb,{className:$(o,`${U}-${e}-title`,{standalone:u,embedded:!u}),children:r==null?void 0:r.headerText}),v.jsxs("div",{className:$(o,`${U}-${e}-controls`),children:[v.jsx(d,{componentType:e,isIcon:!0}),v.jsx(ZL,{componentType:e}),v.jsx(DL,{className:$(o,`cim-${e}-component`),onClick:n})]})]}),v.jsxs(JL,{componentType:e,children:[v.jsx(h,{componentType:e}),v.jsx(oD,{componentType:e}),v.jsx(DE,{componentType:e,onClearChat:t})]})]})})},_b="USD",ma=(e,t)=>{if(typeof e!="number"||Number.isNaN(e))return null;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t}).format(e)}catch(n){return`${e}`}},rD=({retailPrice:e,discountPrice:t,currencyCode:n=_b})=>{const r=n||_b,o=typeof t=="number"&&typeof e=="number"&&t<e,a=o?t:e||t||null,u=o?e:null;return{price:ma(a,r),comparePrice:ma(u,r),hasDiscount:o}},vb=({retailPrice:e,discountPrice:t,currencyCode:n,fontSize:r,globalClassName:o,className:a})=>{const{price:u,comparePrice:c,hasDiscount:d}=rD({retailPrice:e,discountPrice:t,currencyCode:n});if(!u)return null;const h=typeof r=="string"?{fontSize:r}:{};return v.jsxs("div",{className:$(o,a,`${U}-price`),style:h,children:[v.jsx("span",{className:$(o,`${U}-price__amount`),children:u}),d&&c&&v.jsx("span",{className:$(o,`${U}-price__compare`),children:c})]})},iD=({className:e,globalClassName:t,suggestions:n,disabled:r,isWidgetStandalone:o,onSuggestionClick:a})=>{const u=o?"standalone":"embedded",c=d=>()=>{a(d)};return v.jsx("div",{className:$(t,`${U}-suggestion-container ${u}`,e),children:n.map(d=>o?v.jsx(Ni,{disabled:r,className:$(t,`${U}-suggestion-button standalone`),onClick:c(d),children:d},d):v.jsx("button",{disabled:r,className:$(t,`${U}-suggestion-button embedded`),onClick:c(d),children:d},d))})},oD=({componentType:e,isIcon:t})=>{const{globalClassName:n,enableMinimize:r}=At();if(!r)return null;const o=()=>{Ci(!1),vu(!0)};return t?v.jsx(ar,{className:$(n,`${U}-toggle-minimize-button`,`cim-${e}-component`),ariaLabel:"Toggle Minimize",title:"Minimize",onClick:o,icon:v.jsx($0,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-toggle-minimize-button`,`cim-${e}-component`),onClick:o,children:[v.jsx($0,{}),"Minimize"]})},Sb=({componentType:e,isIcon:t})=>{const{globalClassName:n}=At(),r=ra(),o=()=>{Su("modal"),r()};return t?v.jsx(ar,{className:$(n,`${U}-toggle-modal-button`,`cim-${e}-component`),ariaLabel:"Expand",title:"Expand",onClick:o,icon:v.jsx(ib,{})}):v.jsxs("button",{className:$(n,`${U}-overflow-menu-button`,`${U}-toggle-modal-button`,`cim-${e}-component`),onClick:o,children:[v.jsx(ib,{}),"Show modal"]})},sD=["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"],aD=3e3,uD=400,lD=({globalClassName:e,isWidgetStandalone:t,messages:n=sD})=>{const[r,o]=Z.useState(0),[a,u]=Z.useState(!0);return Z.useEffect(()=>{let c;const d=setInterval(()=>{u(!1),c=setTimeout(()=>{o(h=>(h+1)%n.length),u(!0)},uD)},aD);return()=>{clearInterval(d),clearTimeout(c)}},[n.length]),v.jsxs("div",{className:$(e,`${U}-connecting-indicator`,t?"standalone":"embedded"),role:"status","aria-label":"Connecting to assistant",children:[v.jsxs("div",{className:`${U}-connecting-pulse-wrapper`,children:[v.jsx("div",{className:`${U}-connecting-pulse`}),v.jsx("div",{className:`${U}-connecting-ring`})]}),v.jsx("span",{className:$(`${U}-connecting-text`,a&&`${U}-connecting-text--visible`),children:n[r]})]})},cD=({shouldShow:e,loadingText:t})=>e?v.jsx("span",{className:`${U}-processing-text`,children:t}):null,dD=({shouldShow:e})=>e?v.jsxs(v.Fragment,{children:[v.jsx("div",{className:`${U}-processing-shimmer-bar`}),v.jsx("div",{className:`${U}-processing-shimmer-bar`}),v.jsx("div",{className:`${U}-processing-shimmer-bar`})]}):null,xh=({globalClassName:e,isWidgetStandalone:t,loadingText:n})=>v.jsxs("div",{className:$(e,`${U}-processing-indicator`,t?"standalone":"embedded"),role:"status","aria-label":n||"Loading response",children:[v.jsx(cD,{shouldShow:!!n,loadingText:n}),v.jsx(dD,{shouldShow:!n})]});function Ab(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 fD(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function hD(e,t,n){const o=Bu((n||{}).ignore||[]),a=pD(t);let u=-1;for(;++u<a.length;)n1(e,"text",c);function c(h,p){let E=-1,T;for(;++E<p.length;){const y=p[E],x=T?T.children:void 0;if(o(y,x?x.indexOf(y):void 0,T))return;T=y}if(T)return d(h,p)}function d(h,p){const E=p[p.length-1],T=a[u][0],y=a[u][1];let x=0;const S=E.children.indexOf(h);let A=!1,O=[];T.lastIndex=0;let R=T.exec(h.value);for(;R;){const H=R.index,W={index:R.index,input:R.input,stack:[...p,h]};let D=y(...R,W);if(typeof D=="string"&&(D=D.length>0?{type:"text",value:D}:void 0),D===!1?T.lastIndex=H+1:(x!==H&&O.push({type:"text",value:h.value.slice(x,H)}),Array.isArray(D)?O.push(...D):D&&O.push(D),x=H+R[0].length,A=!0),!T.global)break;R=T.exec(h.value)}return A?(x<h.value.length&&O.push({type:"text",value:h.value.slice(x)}),E.children.splice(S,1,...O)):O=[h],S+O.length}}function pD(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([mD(o[0]),gD(o[1])])}return t}function mD(e){return typeof e=="string"?new RegExp(fD(e),"g"):e}function gD(e){return typeof e=="function"?e:function(){return e}}const wh="phrasing",_h=["autolink","link","image","label"];function ED(){return{transforms:[vD],enter:{literalAutolink:bD,literalAutolinkEmail:vh,literalAutolinkHttp:vh,literalAutolinkWww:vh},exit:{literalAutolink:_D,literalAutolinkEmail:wD,literalAutolinkHttp:TD,literalAutolinkWww:xD}}}function yD(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:wh,notInConstruct:_h},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:wh,notInConstruct:_h},{character:":",before:"[ps]",after:"\\/",inConstruct:wh,notInConstruct:_h}]}}function bD(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function vh(e){this.config.enter.autolinkProtocol.call(this,e)}function TD(e){this.config.exit.autolinkProtocol.call(this,e)}function xD(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 wD(e){this.config.exit.autolinkEmail.call(this,e)}function _D(e){this.exit(e)}function vD(e){hD(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,SD],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),AD]],{ignore:["link","linkReference"]})}function SD(e,t,n,r,o){let a="";if(!Cb(o)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!CD(n)))return!1;const u=kD(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 AD(e,t,n,r){return!Cb(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function CD(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 kD(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=Ab(e,"(");let a=Ab(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 Cb(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Ii(n)||Iu(n))&&(!t||n!==47)}kb.peek=FD;function ND(){this.buffer()}function OD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function ID(){this.buffer()}function RD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function PD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Yn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function LD(e){this.exit(e)}function DD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Yn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function MD(e){this.exit(e)}function FD(){return"["}function kb(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 BD(){return{enter:{gfmFootnoteCallString:ND,gfmFootnoteCall:OD,gfmFootnoteDefinitionLabelString:ID,gfmFootnoteDefinition:RD},exit:{gfmFootnoteCallString:PD,gfmFootnoteCall:LD,gfmFootnoteDefinitionLabelString:DD,gfmFootnoteDefinition:MD}}}function UD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:kb},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"),p=a.enter("label");return d+=c.move(a.safe(a.associationId(r),{before:d,after:"]"})),p(),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?Nb:HD))),h(),d}}function HD(e,t,n){return t===0?e:Nb(e,t,n)}function Nb(e,t,n){return(n?"":" ")+e}const zD=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Ob.peek=YD;function jD(){return{canContainEols:["delete"],enter:{strikethrough:VD},exit:{strikethrough:qD}}}function $D(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:zD}],handlers:{delete:Ob}}}function VD(e){this.enter({type:"delete",children:[]},e)}function qD(e){this.exit(e)}function Ob(e,t,n,r){const o=n.createTracker(r),a=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,ae(B({},o.current()),{before:u,after:"~"})),u+=o.move("~~"),a(),u}function YD(){return"~"}function WD(e){return e.length}function GD(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||WD,a=[],u=[],c=[],d=[];let h=0,p=-1;for(;++p<e.length;){const _=[],S=[];let A=-1;for(e[p].length>h&&(h=e[p].length);++A<e[p].length;){const O=KD(e[p][A]);if(n.alignDelimiters!==!1){const R=o(O);S[A]=R,(d[A]===void 0||R>d[A])&&(d[A]=R)}_.push(O)}u[p]=_,c[p]=S}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)a[E]=Ib(r[E]);else{const _=Ib(r);for(;++E<h;)a[E]=_}E=-1;const T=[],y=[];for(;++E<h;){const _=a[E];let S="",A="";_===99?(S=":",A=":"):_===108?S=":":_===114&&(A=":");let O=n.alignDelimiters===!1?1:Math.max(1,d[E]-S.length-A.length);const R=S+"-".repeat(O)+A;n.alignDelimiters!==!1&&(O=S.length+O+A.length,O>d[E]&&(d[E]=O),y[E]=O),T[E]=R}u.splice(1,0,T),c.splice(1,0,y),p=-1;const x=[];for(;++p<u.length;){const _=u[p],S=c[p];E=-1;const A=[];for(;++E<h;){const O=_[E]||"";let R="",H="";if(n.alignDelimiters!==!1){const W=d[E]-(S[E]||0),D=a[E];D===114?R=" ".repeat(W):D===99?W%2?(R=" ".repeat(W/2+.5),H=" ".repeat(W/2-.5)):(R=" ".repeat(W/2),H=R):H=" ".repeat(W)}n.delimiterStart!==!1&&!E&&A.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&O==="")&&(n.delimiterStart!==!1||E)&&A.push(" "),n.alignDelimiters!==!1&&A.push(R),A.push(O),n.alignDelimiters!==!1&&A.push(H),n.padding!==!1&&A.push(" "),(n.delimiterEnd!==!1||E!==h-1)&&A.push("|")}x.push(n.delimiterEnd===!1?A.join("").replace(/ +$/,""):A.join(""))}return x.join(`
39
39
  `)}function KD(e){return e==null?"":String(e)}function Ib(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 QD(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()),XD);return o(),u}function XD(e,t,n){return">"+(n?"":" ")+e}function JD(e,t){return Rb(e,t.inConstruct,!0)&&!Rb(e,t.notInConstruct,!1)}function Rb(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 Pb(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if(n.unsafe[o].character===`
40
40
  `&&JD(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return`\\
41
- `}function ZD(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 e5(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 t5(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 n5(e,t,n,r){const o=t5(n),a=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(e5(e,n)){const E=n.enter("codeIndented"),T=n.indentLines(a,r5);return E(),T}const c=n.createTracker(r),d=o.repeat(Math.max(ZD(a,o)+1,3)),h=n.enter("codeFenced");let p=c.move(d);if(e.lang){const E=n.enter(`codeFencedLang${u}`);p+=c.move(n.safe(e.lang,H({before:p,after:" ",encode:["`"]},c.current()))),E()}if(e.lang&&e.meta){const E=n.enter(`codeFencedMeta${u}`);p+=c.move(" "),p+=c.move(n.safe(e.meta,H({before:p,after:`
41
+ `}function ZD(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 e5(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 t5(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 n5(e,t,n,r){const o=t5(n),a=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(e5(e,n)){const E=n.enter("codeIndented"),T=n.indentLines(a,r5);return E(),T}const c=n.createTracker(r),d=o.repeat(Math.max(ZD(a,o)+1,3)),h=n.enter("codeFenced");let p=c.move(d);if(e.lang){const E=n.enter(`codeFencedLang${u}`);p+=c.move(n.safe(e.lang,B({before:p,after:" ",encode:["`"]},c.current()))),E()}if(e.lang&&e.meta){const E=n.enter(`codeFencedMeta${u}`);p+=c.move(" "),p+=c.move(n.safe(e.meta,B({before:p,after:`
42
42
  `,encode:["`"]},c.current()))),E()}return p+=c.move(`
43
43
  `),a&&(p+=c.move(a+`
44
- `)),p+=c.move(d),h(),p}function r5(e,t,n){return(n?"":" ")+e}function Sh(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 i5(e,t,n,r){const o=Sh(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),H({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,H({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,H({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,H({before:h,after:o},d.current()))),h+=d.move(o),c()),u(),h}function o5(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 ga(e){return"&#x"+e.toString(16).toUpperCase()+";"}function wl(e,t,n){const r=To(e),o=To(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}}Lb.peek=s5;function Lb(e,t,n,r){const o=o5(n),a=n.enter("emphasis"),u=n.createTracker(r),c=u.move(o);let d=u.move(n.containerPhrasing(e,H({after:o,before:c},u.current())));const h=d.charCodeAt(0),p=wl(r.before.charCodeAt(r.before.length-1),h,o);p.inside&&(d=ga(h)+d.slice(1));const E=d.charCodeAt(d.length-1),T=wl(r.after.charCodeAt(0),E,o);T.inside&&(d=d.slice(0,-1)+ga(E));const y=u.move(o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:p.outside},c+d+y}function s5(e,t,n){return n.options.emphasis||"*"}function a5(e,t){let n=!1;return Hu(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Gd}),!!((!e.depth||e.depth<3)&&Fd(e)&&(t.options.setext||n))}function u5(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(a5(e,n)){const p=n.enter("headingSetext"),E=n.enter("phrasing"),T=n.containerPhrasing(e,ae(H({},a.current()),{before:`
44
+ `)),p+=c.move(d),h(),p}function r5(e,t,n){return(n?"":" ")+e}function Sh(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 i5(e,t,n,r){const o=Sh(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),B({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,B({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,B({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,B({before:h,after:o},d.current()))),h+=d.move(o),c()),u(),h}function o5(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 ga(e){return"&#x"+e.toString(16).toUpperCase()+";"}function wl(e,t,n){const r=To(e),o=To(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}}Lb.peek=s5;function Lb(e,t,n,r){const o=o5(n),a=n.enter("emphasis"),u=n.createTracker(r),c=u.move(o);let d=u.move(n.containerPhrasing(e,B({after:o,before:c},u.current())));const h=d.charCodeAt(0),p=wl(r.before.charCodeAt(r.before.length-1),h,o);p.inside&&(d=ga(h)+d.slice(1));const E=d.charCodeAt(d.length-1),T=wl(r.after.charCodeAt(0),E,o);T.inside&&(d=d.slice(0,-1)+ga(E));const y=u.move(o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:p.outside},c+d+y}function s5(e,t,n){return n.options.emphasis||"*"}function a5(e,t){let n=!1;return Hu(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Gd}),!!((!e.depth||e.depth<3)&&Fd(e)&&(t.options.setext||n))}function u5(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(a5(e,n)){const p=n.enter("headingSetext"),E=n.enter("phrasing"),T=n.containerPhrasing(e,ae(B({},a.current()),{before:`
46
46
  `,after:`
47
47
  `}));return E(),p(),T+`
48
48
  `+(o===1?"=":"-").repeat(T.length-(Math.max(T.lastIndexOf("\r"),T.lastIndexOf(`
49
- `))+1))}const u="#".repeat(o),c=n.enter("headingAtx"),d=n.enter("phrasing");a.move(u+" ");let h=n.containerPhrasing(e,H({before:"# ",after:`
50
- `},a.current()));return/^[\t ]/.test(h)&&(h=ga(h.charCodeAt(0))+h.slice(1)),h=h?u+" "+h:u,n.options.closeAtx&&(h+=" "+u),d(),c(),h}Db.peek=l5;function Db(e){return e.value||""}function l5(){return"<"}Mb.peek=c5;function Mb(e,t,n,r){const o=Sh(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,H({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,H({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,H({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,H({before:h,after:o},d.current()))),h+=d.move(o),c()),h+=d.move(")"),u(),h}function c5(){return"!"}Fb.peek=d5;function Fb(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,H({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const p=n.stack;n.stack=[],u=n.enter("reference");const E=n.safe(n.associationId(e),H({before:d,after:"]"},c.current()));return u(),n.stack=p,a(),o==="full"||!h||h!==E?d+=c.move(E+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function d5(){return"!"}Bb.peek=f5;function Bb(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 f5(){return"`"}function Ub(e,t){const n=Fd(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))}Hb.peek=h5;function Hb(e,t,n,r){const o=Sh(n),a=o==='"'?"Quote":"Apostrophe",u=n.createTracker(r);let c,d;if(Ub(e,n)){const p=n.stack;n.stack=[],c=n.enter("autolink");let E=u.move("<");return E+=u.move(n.containerPhrasing(e,H({before:E,after:">"},u.current()))),E+=u.move(">"),c(),n.stack=p,E}c=n.enter("link"),d=n.enter("label");let h=u.move("[");return h+=u.move(n.containerPhrasing(e,H({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,H({before:h,after:">"},u.current()))),h+=u.move(">")):(d=n.enter("destinationRaw"),h+=u.move(n.safe(e.url,H({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,H({before:h,after:o},u.current()))),h+=u.move(o),d()),h+=u.move(")"),c(),h}function h5(e,t,n){return Ub(e,n)?"<":"["}zb.peek=p5;function zb(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,H({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const p=n.stack;n.stack=[],u=n.enter("reference");const E=n.safe(n.associationId(e),H({before:d,after:"]"},c.current()));return u(),n.stack=p,a(),o==="full"||!h||h!==E?d+=c.move(E+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function p5(){return"["}function Ah(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 m5(e){const t=Ah(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 g5(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 jb(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 E5(e,t,n,r){const o=n.enter("list"),a=n.bulletCurrent;let u=e.ordered?g5(n):Ah(n);const c=e.ordered?u==="."?")":".":m5(n);let d=t&&n.bulletLastUsed?u===n.bulletLastUsed:!1;if(!e.ordered){const p=e.children?e.children[0]:void 0;if((u==="*"||u==="-")&&p&&(!p.children||!p.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),jb(n)===u&&p){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 y5(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 b5(e,t,n,r){const o=y5(n);let a=n.bulletCurrent||Ah(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()),p);return d(),h;function p(E,T,y){return T?(y?"":" ".repeat(u))+E:(y?a:a+" ".repeat(u-a.length))+E}}function T5(e,t,n,r){const o=n.enter("paragraph"),a=n.enter("phrasing"),u=n.containerPhrasing(e,r);return a(),o(),u}const x5=Bu(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function w5(e,t,n,r){return(e.children.some(function(u){return x5(u)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function _5(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}$b.peek=v5;function $b(e,t,n,r){const o=_5(n),a=n.enter("strong"),u=n.createTracker(r),c=u.move(o+o);let d=u.move(n.containerPhrasing(e,H({after:o,before:c},u.current())));const h=d.charCodeAt(0),p=wl(r.before.charCodeAt(r.before.length-1),h,o);p.inside&&(d=ga(h)+d.slice(1));const E=d.charCodeAt(d.length-1),T=wl(r.after.charCodeAt(0),E,o);T.inside&&(d=d.slice(0,-1)+ga(E));const y=u.move(o+o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:p.outside},c+d+y}function v5(e,t,n){return n.options.strong||"*"}function S5(e,t,n,r){return n.safe(e.value,r)}function A5(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 C5(e,t,n){const r=(jb(n)+(n.options.ruleSpaces?" ":"")).repeat(A5(n));return n.options.ruleSpaces?r.slice(0,-1):r}const Vb={blockquote:QD,break:Pb,code:n5,definition:i5,emphasis:Lb,hardBreak:Pb,heading:u5,html:Db,image:Mb,imageReference:Fb,inlineCode:Bb,link:Hb,linkReference:zb,list:E5,listItem:b5,paragraph:T5,root:w5,strong:$b,text:S5,thematicBreak:C5};function k5(){return{enter:{table:N5,tableData:qb,tableHeader:qb,tableRow:I5},exit:{codeText:R5,table:O5,tableData:Ch,tableHeader:Ch,tableRow:Ch}}}function N5(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 O5(e){this.exit(e),this.data.inTable=void 0}function I5(e){this.enter({type:"tableRow",children:[]},e)}function Ch(e){this.exit(e)}function qb(e){this.enter({type:"tableCell",children:[]},e)}function R5(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,P5));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function P5(e,t){return t==="|"?t:e}function L5(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
49
+ `))+1))}const u="#".repeat(o),c=n.enter("headingAtx"),d=n.enter("phrasing");a.move(u+" ");let h=n.containerPhrasing(e,B({before:"# ",after:`
50
+ `},a.current()));return/^[\t ]/.test(h)&&(h=ga(h.charCodeAt(0))+h.slice(1)),h=h?u+" "+h:u,n.options.closeAtx&&(h+=" "+u),d(),c(),h}Db.peek=l5;function Db(e){return e.value||""}function l5(){return"<"}Mb.peek=c5;function Mb(e,t,n,r){const o=Sh(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,B({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,B({before:h,after:">"},d.current()))),h+=d.move(">")):(c=n.enter("destinationRaw"),h+=d.move(n.safe(e.url,B({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,B({before:h,after:o},d.current()))),h+=d.move(o),c()),h+=d.move(")"),u(),h}function c5(){return"!"}Fb.peek=d5;function Fb(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,B({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const p=n.stack;n.stack=[],u=n.enter("reference");const E=n.safe(n.associationId(e),B({before:d,after:"]"},c.current()));return u(),n.stack=p,a(),o==="full"||!h||h!==E?d+=c.move(E+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function d5(){return"!"}Bb.peek=f5;function Bb(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 f5(){return"`"}function Ub(e,t){const n=Fd(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))}Hb.peek=h5;function Hb(e,t,n,r){const o=Sh(n),a=o==='"'?"Quote":"Apostrophe",u=n.createTracker(r);let c,d;if(Ub(e,n)){const p=n.stack;n.stack=[],c=n.enter("autolink");let E=u.move("<");return E+=u.move(n.containerPhrasing(e,B({before:E,after:">"},u.current()))),E+=u.move(">"),c(),n.stack=p,E}c=n.enter("link"),d=n.enter("label");let h=u.move("[");return h+=u.move(n.containerPhrasing(e,B({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,B({before:h,after:">"},u.current()))),h+=u.move(">")):(d=n.enter("destinationRaw"),h+=u.move(n.safe(e.url,B({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,B({before:h,after:o},u.current()))),h+=u.move(o),d()),h+=u.move(")"),c(),h}function h5(e,t,n){return Ub(e,n)?"<":"["}zb.peek=p5;function zb(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,B({before:d,after:"]"},c.current()));d+=c.move(h+"]["),u();const p=n.stack;n.stack=[],u=n.enter("reference");const E=n.safe(n.associationId(e),B({before:d,after:"]"},c.current()));return u(),n.stack=p,a(),o==="full"||!h||h!==E?d+=c.move(E+"]"):o==="shortcut"?d=d.slice(0,-1):d+=c.move("]"),d}function p5(){return"["}function Ah(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 m5(e){const t=Ah(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 g5(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 jb(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 E5(e,t,n,r){const o=n.enter("list"),a=n.bulletCurrent;let u=e.ordered?g5(n):Ah(n);const c=e.ordered?u==="."?")":".":m5(n);let d=t&&n.bulletLastUsed?u===n.bulletLastUsed:!1;if(!e.ordered){const p=e.children?e.children[0]:void 0;if((u==="*"||u==="-")&&p&&(!p.children||!p.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),jb(n)===u&&p){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 y5(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 b5(e,t,n,r){const o=y5(n);let a=n.bulletCurrent||Ah(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()),p);return d(),h;function p(E,T,y){return T?(y?"":" ".repeat(u))+E:(y?a:a+" ".repeat(u-a.length))+E}}function T5(e,t,n,r){const o=n.enter("paragraph"),a=n.enter("phrasing"),u=n.containerPhrasing(e,r);return a(),o(),u}const x5=Bu(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function w5(e,t,n,r){return(e.children.some(function(u){return x5(u)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function _5(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}$b.peek=v5;function $b(e,t,n,r){const o=_5(n),a=n.enter("strong"),u=n.createTracker(r),c=u.move(o+o);let d=u.move(n.containerPhrasing(e,B({after:o,before:c},u.current())));const h=d.charCodeAt(0),p=wl(r.before.charCodeAt(r.before.length-1),h,o);p.inside&&(d=ga(h)+d.slice(1));const E=d.charCodeAt(d.length-1),T=wl(r.after.charCodeAt(0),E,o);T.inside&&(d=d.slice(0,-1)+ga(E));const y=u.move(o+o);return a(),n.attentionEncodeSurroundingInfo={after:T.outside,before:p.outside},c+d+y}function v5(e,t,n){return n.options.strong||"*"}function S5(e,t,n,r){return n.safe(e.value,r)}function A5(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 C5(e,t,n){const r=(jb(n)+(n.options.ruleSpaces?" ":"")).repeat(A5(n));return n.options.ruleSpaces?r.slice(0,-1):r}const Vb={blockquote:QD,break:Pb,code:n5,definition:i5,emphasis:Lb,hardBreak:Pb,heading:u5,html:Db,image:Mb,imageReference:Fb,inlineCode:Bb,link:Hb,linkReference:zb,list:E5,listItem:b5,paragraph:T5,root:w5,strong:$b,text:S5,thematicBreak:C5};function k5(){return{enter:{table:N5,tableData:qb,tableHeader:qb,tableRow:I5},exit:{codeText:R5,table:O5,tableData:Ch,tableHeader:Ch,tableRow:Ch}}}function N5(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 O5(e){this.exit(e),this.data.inTable=void 0}function I5(e){this.enter({type:"tableRow",children:[]},e)}function Ch(e){this.exit(e)}function qb(e){this.enter({type:"tableCell",children:[]},e)}function R5(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,P5));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function P5(e,t){return t==="|"?t:e}function L5(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
51
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(y,x,_,S){return h(p(y,_,S),y.align)}function c(y,x,_,S){const A=E(y,_,S),O=h([A]);return O.slice(0,O.indexOf(`
52
- `))}function d(y,x,_,S){const A=_.enter("tableCell"),O=_.enter("phrasing"),R=_.containerPhrasing(y,ae(H({},S),{before:a,after:a}));return O(),A(),R}function h(y,x){return GD(y,{align:x,alignDelimiters:r,padding:n,stringLength:o})}function p(y,x,_){const S=y.children;let A=-1;const O=[],R=x.enter("table");for(;++A<S.length;)O[A]=E(S[A],x,_);return R(),O}function E(y,x,_){const S=y.children;let A=-1;const O=[],R=x.enter("tableRow");for(;++A<S.length;)O[A]=d(S[A],y,x,_);return R(),O}function T(y,x,_){let S=Vb.inlineCode(y,x,_);return _.stack.includes("tableCell")&&(S=S.replace(/\|/g,"\\$&")),S}}function D5(){return{exit:{taskListCheckValueChecked:Yb,taskListCheckValueUnchecked:Yb,paragraph:F5}}}function M5(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:B5}}}function Yb(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function F5(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 B5(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=Vb.listItem(e,t,n,H(H({},r),c.current()));return a&&(d=d.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),d;function h(p){return p+u}}function U5(){return[ED(),BD(),jD(),k5(),D5()]}function H5(e){return{extensions:[yD(),UD(e),$D(),L5(e),M5()]}}const z5={tokenize:W5,partial:!0},Wb={tokenize:G5,partial:!0},Gb={tokenize:K5,partial:!0},Kb={tokenize:Q5,partial:!0},j5={tokenize:X5,partial:!0},Qb={name:"wwwAutolink",tokenize:q5,previous:Jb},Xb={name:"protocolAutolink",tokenize:Y5,previous:Zb},Ir={name:"emailAutolink",tokenize:V5,previous:eT},yr={};function $5(){return{text:yr}}let qi=48;for(;qi<123;)yr[qi]=Ir,qi++,qi===58?qi=65:qi===91&&(qi=97);yr[43]=Ir,yr[45]=Ir,yr[46]=Ir,yr[95]=Ir,yr[72]=[Ir,Xb],yr[104]=[Ir,Xb],yr[87]=[Ir,Qb],yr[119]=[Ir,Qb];function V5(e,t,n){const r=this;let o,a;return u;function u(E){return!kh(E)||!eT.call(r,r.previous)||Nh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return kh(E)?(e.consume(E),c):E===64?(e.consume(E),d):n(E)}function d(E){return E===46?e.check(j5,p,h)(E):E===45||E===95||Gt(E)?(a=!0,e.consume(E),d):p(E)}function h(E){return e.consume(E),o=!0,d}function p(E){return a&&o&&nn(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(E)):n(E)}}function q5(e,t,n){const r=this;return o;function o(u){return u!==87&&u!==119||!Jb.call(r,r.previous)||Nh(r.events)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(z5,e.attempt(Wb,e.attempt(Gb,a),n),n)(u))}function a(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function Y5(e,t,n){const r=this;let o="",a=!1;return u;function u(E){return(E===72||E===104)&&Zb.call(r,r.previous)&&!Nh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(nn(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||Ou(E)||it(E)||Ii(E)||Iu(E)?n(E):e.attempt(Wb,e.attempt(Gb,p),n)(E)}function p(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function W5(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 G5(e,t,n){let r,o,a;return u;function u(h){return h===46||h===95?e.check(Kb,d,c)(h):h===null||it(h)||Ii(h)||h!==45&&Iu(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 K5(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(Kb,t,a)(u):u===null||it(u)||Ii(u)?t(u):(e.consume(u),o)}function a(u){return u===41&&r++,e.consume(u),o}}function Q5(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)||Ii(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||it(c)||Ii(c)?t(c):r(c)}function a(c){return nn(c)?u(c):n(c)}function u(c){return c===59?(e.consume(c),r):nn(c)?(e.consume(c),u):n(c)}}function X5(e,t,n){return r;function r(a){return e.consume(a),o}function o(a){return Gt(a)?n(a):t(a)}}function Jb(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||it(e)}function Zb(e){return!nn(e)}function eT(e){return!(e===47||kh(e))}function kh(e){return e===43||e===45||e===46||e===95||Gt(e)}function Nh(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 J5={tokenize:s8,partial:!0};function Z5(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:r8,continuation:{tokenize:i8},exit:o8}},text:{91:{name:"gfmFootnoteCall",tokenize:n8},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:e8,resolveTo:t8}}}}function e8(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=Yn(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 t8(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 n8(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(Yn(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?p:h}function p(E){return E===91||E===92||E===93?(e.consume(E),a++,h):h(E)}}function r8(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",p):n(x)}function p(x){if(u>999||x===93&&!c||x===null||x===91||it(x))return n(x);if(x===93){e.exit("chunkString");const _=e.exit("gfmFootnoteDefinitionLabelString");return a=Yn(r.sliceSerialize(_)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(x),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),T}return it(x)||(c=!0),u++,e.consume(x),x===92?E:p}function E(x){return x===91||x===92||x===93?(e.consume(x),u++,p):p(x)}function T(x){return x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),o.includes(a)||o.push(a),Qe(e,y,"gfmFootnoteDefinitionWhitespace")):n(x)}function y(x){return t(x)}}function i8(e,t,n){return e.check(Bs,t,e.attempt(J5,t,n))}function o8(e){e.exit("gfmFootnoteDefinition")}function s8(e,t,n){const r=this;return Qe(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 a8(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 p={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",p,c],["enter",u[h][1],c],["exit",u[h][1],c],["enter",E,c]],y=c.parser.constructs.insideSpan.null;y&&xn(T,T.length,0,Ru(y,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",p,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,p=this.events;let E=0;return T;function T(x){return h===126&&p[p.length-1][1].type!=="characterEscape"?d(x):(u.enter("strikethroughSequenceTemporary"),y(x))}function y(x){const _=To(h);if(x===126)return E>1?d(x):(u.consume(x),E++,y);if(E<2&&!n)return d(x);const S=u.exit("strikethroughSequenceTemporary"),A=To(x);return S._open=!A||A===2&&!!_,S._close=!_||_===2&&!!A,c(x)}}}class u8{constructor(){this.map=[]}add(t,n,r){l8(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 l8(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 c8(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 d8(){return{flow:{null:{name:"table",tokenize:f8,resolveAll:h8}}}}function f8(e,t,n){const r=this;let o=0,a=0,u;return c;function c(D){let ne=r.events.length-1;for(;ne>-1;){const oe=r.events[ne][1].type;if(oe==="lineEnding"||oe==="linePrefix")ne--;else break}const J=ne>-1?r.events[ne][1].type:null,re=J==="tableHead"||J==="tableRow"?M:d;return re===M&&r.parser.lazy[r.now().line]?n(D):re(D)}function d(D){return e.enter("tableHead"),e.enter("tableRow"),h(D)}function h(D){return D===124||(u=!0,a+=1),p(D)}function p(D){return D===null?n(D):Le(D)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(D),e.exit("lineEnding"),y):n(D):Ge(D)?Qe(e,p,"whitespace")(D):(a+=1,u&&(u=!1,o+=1),D===124?(e.enter("tableCellDivider"),e.consume(D),e.exit("tableCellDivider"),u=!0,p):(e.enter("data"),E(D)))}function E(D){return D===null||D===124||it(D)?(e.exit("data"),p(D)):(e.consume(D),D===92?T:E)}function T(D){return D===92||D===124?(e.consume(D),E):E(D)}function y(D){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(D):(e.enter("tableDelimiterRow"),u=!1,Ge(D)?Qe(e,x,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(D):x(D))}function x(D){return D===45||D===58?S(D):D===124?(u=!0,e.enter("tableCellDivider"),e.consume(D),e.exit("tableCellDivider"),_):W(D)}function _(D){return Ge(D)?Qe(e,S,"whitespace")(D):S(D)}function S(D){return D===58?(a+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(D),e.exit("tableDelimiterMarker"),A):D===45?(a+=1,A(D)):D===null||Le(D)?z(D):W(D)}function A(D){return D===45?(e.enter("tableDelimiterFiller"),O(D)):W(D)}function O(D){return D===45?(e.consume(D),O):D===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(D),e.exit("tableDelimiterMarker"),R):(e.exit("tableDelimiterFiller"),R(D))}function R(D){return Ge(D)?Qe(e,z,"whitespace")(D):z(D)}function z(D){return D===124?x(D):D===null||Le(D)?!u||o!==a?W(D):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(D)):W(D)}function W(D){return n(D)}function M(D){return e.enter("tableRow"),K(D)}function K(D){return D===124?(e.enter("tableCellDivider"),e.consume(D),e.exit("tableCellDivider"),K):D===null||Le(D)?(e.exit("tableRow"),t(D)):Ge(D)?Qe(e,K,"whitespace")(D):(e.enter("data"),de(D))}function de(D){return D===null||D===124||it(D)?(e.exit("data"),K(D)):(e.consume(D),D===92?xe:de)}function xe(D){return D===92||D===124?(e.consume(D),de):de(D)}}function h8(e,t){let n=-1,r=!0,o=0,a=[0,0,0,0],u=[0,0,0,0],c=!1,d=0,h,p,E;const T=new u8;for(;++n<e.length;){const y=e[n],x=y[1];y[0]==="enter"?x.type==="tableHead"?(c=!1,d!==0&&(tT(T,t,d,h,p),p=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,E=void 0,a=[0,0,0,0],u=[0,n+1,0,0],c&&(c=!1,p={type:"tableBody",start:Object.assign({},x.start),end:Object.assign({},x.end)},T.add(n,0,[["enter",p,t]])),o=x.type==="tableDelimiterRow"?2:p?3:1):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")?(r=!1,u[2]===0&&(a[1]!==0&&(u[0]=u[1],E=_l(T,t,a,o,void 0,E),a=[0,0,0,0]),u[2]=n)):x.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(u[0]=u[1],E=_l(T,t,a,o,void 0,E)),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],E=_l(T,t,a,o,n,E)):u[1]!==0&&(E=_l(T,t,u,o,n,E)),o=0):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")&&(u[3]=n)}for(d!==0&&tT(T,t,d,h,p),T.consume(t.events),n=-1;++n<t.events.length;){const y=t.events[n];y[0]==="enter"&&y[1].type==="table"&&(y[1]._align=c8(t.events,n))}return e}function _l(e,t,n,r,o,a){const u=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(a.end=Object.assign({},Wo(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const d=Wo(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=Wo(t.events,n[2]),p=Wo(t.events,n[3]),E={type:c,start:Object.assign({},h),end:Object.assign({},p)};if(e.add(n[2],0,[["enter",E,t]]),r!==2){const T=t.events[n[2]],y=t.events[n[3]];if(T[1].end=Object.assign({},y[1].end),T[1].type="chunkText",T[1].contentType="text",n[3]>n[2]+1){const x=n[2]+1,_=n[3]-n[2]-1;e.add(x,_,[])}}e.add(n[3]+1,0,[["exit",E,t]])}return o!==void 0&&(a.end=Object.assign({},Wo(t.events,o)),e.add(o,0,[["exit",a,t]]),a=void 0),a}function tT(e,t,n,r,o){const a=[],u=Wo(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 Wo(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const p8={name:"tasklistCheck",tokenize:g8};function m8(){return{text:{91:p8}}}function g8(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):Ge(d)?e.check({tokenize:E8},t,n)(d):n(d)}}function E8(e,t,n){return Qe(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function y8(e){return _g([$5(),Z5(),a8(e),d8(),m8()])}const b8={};function T8(e){const t=this,n=e||b8,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),u=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push(y8(n)),a.push(U5()),u.push(H5(n))}const x8=()=>v.jsx("span",{className:`${U}-blinking-cursor`,children:v.jsx("svg",{height:"16px",width:"16px",xmlns:"http://www.w3.org/2000/svg",children:v.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),Oh=({globalClassName:e,openLinksInNewTab:t,showIsLoading:n,text:r})=>v.jsx(h1,{remarkPlugins:[T8],rehypePlugins:[SE],components:{h1:({children:o})=>v.jsx("h1",{className:$(e,`${U}-header h1`),children:o}),h2:({children:o})=>v.jsx("h2",{className:$(e,`${U}-header h2`),children:o}),h3:({children:o})=>v.jsx("h3",{className:$(e,`${U}-header h3`),children:o}),ul:({children:o})=>v.jsx("ul",{className:$(e,`${U}-ul`),children:o}),ol:({children:o})=>v.jsx("ol",{className:$(e,`${U}-ol`),children:o}),li:({children:o})=>v.jsx("li",{className:$(e,`${U}-li`),children:o}),a:({href:o,children:a})=>v.jsx(RE,{globalClassName:e,openLinksInNewTab:t,href:o,children:a}),table:({children:o})=>v.jsx("div",{className:$(e,`${U}-table-container`),children:v.jsx("table",{className:$(e,`${U}-table`),children:o})}),thead:({children:o})=>v.jsx("thead",{className:$(e,`${U}-thead`),children:o}),tbody:({children:o})=>v.jsx("tbody",{className:$(e,`${U}-tbody`),children:o}),tr:({children:o})=>v.jsx("tr",{className:$(e,`${U}-tr`),children:o}),th:({children:o})=>v.jsx("th",{className:$(e,`${U}-th`),children:o}),td:({children:o})=>v.jsx("td",{className:$(e,`${U}-td`),children:o}),span:({className:o,children:a})=>o===`${U}-blinking-cursor`?v.jsx(x8,{}):v.jsx("span",{children:a})},children:r+(n?`<span className='${U}-blinking-cursor'></span>`:"")}),nT=({product:e,globalClassName:t,isFullWidth:n,openLinksInNewTab:r})=>{const{name:o,imageUrl:a,productPageUrl:u,price:c,discountPrice:d,compareAtPrice:h,currencyCode:p}=e,E=typeof d=="number"&&typeof c=="number"&&d<c,T=E?c:h!=null?h:c,y=E?d:c;return v.jsxs("div",{className:$(t,`${U}-msg-product-card`,{"card-full-width":n}),children:[v.jsx("div",{className:$(t,`${U}-msg-product-card__image-wrapper`),children:a&&(u?v.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener","aria-label":`Go to product page for ${o}`,children:v.jsx("img",{className:$(t,`${U}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"})}):v.jsx("img",{className:$(t,`${U}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"}))}),v.jsxs("div",{className:$(t,`${U}-msg-product-card__content`),children:[u?v.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener",className:$(t,`${U}-msg-product-card__title-link`),"aria-label":`Go to product page for ${o}`,children:o}):v.jsx("p",{className:$(t,`${U}-msg-product-card__title`),children:o}),v.jsx("div",{className:$(t,`${U}-msg-product-card__price-row`),children:v.jsx(vb,{globalClassName:t,retailPrice:T,discountPrice:y,currencyCode:p})})]})]})},rT=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}),w8=({title:e,products:t,globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o})=>{if(t.length===1){const a=t[0];return v.jsxs("div",{children:[e&&v.jsx("p",{className:$(n,`${U}-product-carousel-title`),children:e}),v.jsx(nT,{product:rT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o,isFullWidth:!o})]})}return v.jsxs("div",{style:{marginBottom:"1rem"},children:[e&&v.jsx("p",{className:$(n,`${U}-product-carousel-title`),children:e}),v.jsx(LL,{globalClassName:n,spacing:o?"0.5rem":"6px",ariaLabel:e||"Product recommendations",children:t.map(a=>v.jsx(nT,{product:rT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o},a.id))})]})},iT=({code:e,globalClassName:t})=>v.jsxs("span",{className:$(t,`${U}-cart-chip`),children:[v.jsx(q0,{"aria-hidden":"true"}),v.jsx("span",{children:e})]}),Yi=({label:e,badge:t,value:n,currencyCode:r,globalClassName:o,emphasized:a,isDiscount:u,fallback:c})=>{let d;if(typeof n=="number")n===0&&!u?d="Free":d=ma(u?-n:n,r);else if(c)d=c;else return null;return v.jsxs("div",{className:$(o,`${U}-cart-total-row`,{emphasized:a}),children:[v.jsxs("span",{className:$(o,`${U}-cart-total-label`),children:[e,t&&v.jsx("span",{className:$(o,`${U}-cart-total-badge`),children:t})]}),v.jsx("span",{className:$(o,`${U}-cart-total-value`),children:d})]})},_8=({item:e,currencyCode:t,loading:n,globalClassName:r,onRemove:o})=>{var u,c,d;const a=typeof e.originalSubtotal=="number"&&typeof e.itemSubtotal=="number"&&e.originalSubtotal>e.itemSubtotal;return v.jsxs("li",{className:$(r,`${U}-cart-item`),children:[e.imageUrl&&v.jsx("div",{className:$(r,`${U}-cart-item-image`),children:v.jsx("img",{src:e.imageUrl,alt:e.name||"Product image",loading:"lazy"})}),v.jsxs("div",{className:$(r,`${U}-cart-item-details`),children:[v.jsx("p",{className:$(r,`${U}-cart-item-name`),children:e.name}),v.jsxs("div",{className:$(r,`${U}-cart-item-attrs`),children:[((u=e.variants)!=null?u:[]).map(h=>v.jsxs("p",{className:$(r,`${U}-cart-item-attr`),children:[h.lbl,": ",h.value]},`${h.type}-${h.value}`)),((c=e.promotions)!=null?c:[]).map(h=>v.jsxs("p",{className:$(r,`${U}-cart-item-attr`),children:["Promotion: ",h]},h))]}),((d=e.coupons)!=null?d:[]).length>0&&v.jsx("div",{className:$(r,`${U}-cart-chips`),children:e.coupons.map(h=>v.jsx(iT,{code:h,globalClassName:r},h))}),v.jsxs("span",{className:$(r,`${U}-cart-item-price`),children:[a&&v.jsx("span",{className:$(r,`${U}-cart-item-original-price`),children:ma(e.originalSubtotal,t)}),v.jsx("span",{className:$(r,`${U}-cart-item-final-price`),children:ma(e.itemSubtotal,t)})]}),v.jsxs("div",{className:$(r,`${U}-cart-item-footer`),children:[v.jsxs("span",{className:$(r,`${U}-cart-item-qty`),children:["Qty: ",e.quantity]}),v.jsx("button",{type:"button",className:$(r,`${U}-cart-item-remove`),disabled:n,onClick:()=>o(e),children:"Remove"})]})]})]})},v8=({cart:e,globalClassName:t,openLinksInNewTab:n})=>{const{sendMessage:r,loading:o}=Vr(),[a,u]=Z.useState(!0),[c,d]=Z.useState(""),{items:h=[],currencyCode:p="USD",subtotal:E,total:T,taxes:y,shippingCost:x,shippingDiscount:_,shippingPromotions:S=[],promotionsDiscount:A,promotions:O=[],couponsDiscount:R,couponsApplied:z=[],bodyMessage:W,footerMessage:M,checkoutButtonUrl:K}=e,de=D=>{o||r(`Remove ${D.name} from my cart`)},xe=()=>{const D=c.trim();!D||o||(r(`Apply coupon code ${D}`),d(""))};return v.jsxs("div",{className:$(t,`${U}-cart`),children:[v.jsxs("div",{className:$(t,`${U}-cart-box`),children:[W&&v.jsxs("button",{type:"button",className:$(t,`${U}-cart-summary`),"aria-expanded":a,onClick:()=>u(D=>!D),children:[v.jsx("span",{className:$(t,`${U}-cart-summary-text`),children:v.jsx(Oh,{text:W,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})}),v.jsx("span",{className:$(t,`${U}-cart-summary-toggle`),"aria-hidden":"true",children:a?v.jsx(YS,{}):v.jsx(WS,{})})]}),a&&v.jsxs("div",{className:$(t,`${U}-cart-expanded`),children:[v.jsx("ul",{className:$(t,`${U}-cart-items`),children:h.map(D=>v.jsx(_8,{item:D,currencyCode:p,loading:o,globalClassName:t,onRemove:de},D.itemId))}),z.length>0&&v.jsx("div",{className:$(t,`${U}-cart-chips`,`${U}-cart-applied-coupons`),children:z.map(D=>v.jsx(iT,{code:D,globalClassName:t},D))}),v.jsxs("div",{className:$(t,`${U}-cart-totals`),children:[v.jsx(Yi,{label:"Subtotal",value:E,currencyCode:p,globalClassName:t}),v.jsx(Yi,{label:"Coupon",value:R,currencyCode:p,globalClassName:t,isDiscount:!0}),v.jsx(Yi,{label:"Promotions",badge:O[0],value:A,currencyCode:p,globalClassName:t,isDiscount:!0}),v.jsx(Yi,{label:"Shipping",value:x,currencyCode:p,globalClassName:t,fallback:"TBD"}),v.jsx(Yi,{label:"Shipping Discount",badge:S[0],value:_,currencyCode:p,globalClassName:t,isDiscount:!0}),v.jsx(Yi,{label:"Tax",value:y,currencyCode:p,globalClassName:t,fallback:"TBD"}),v.jsx(Yi,{label:"Total",value:T,currencyCode:p,globalClassName:t,emphasized:!0})]})]})]}),v.jsxs("div",{className:$(t,`${U}-cart-coupon`),children:[v.jsxs("div",{className:$(t,`${U}-cart-coupon-field`),children:[v.jsx("span",{className:$(t,`${U}-cart-coupon-icon`),"aria-hidden":"true",children:v.jsx(q0,{})}),v.jsx("input",{type:"text",className:$(t,`${U}-cart-coupon-input`),placeholder:"Enter coupon code","aria-label":"Enter coupon code",value:c,disabled:o,onChange:D=>d(D.target.value),onKeyDown:D=>{D.key==="Enter"&&(D.preventDefault(),xe())}})]}),v.jsx("button",{type:"button",className:$(t,`${U}-cart-coupon-submit`),"aria-label":"Apply coupon",disabled:o||!c.trim(),onClick:xe,children:v.jsx(qS,{"aria-hidden":"true"})})]}),K&&v.jsxs("a",{className:$(t,`${U}-cart-checkout-button`),href:K,target:n?"_blank":"_self",rel:"noopener noreferrer",children:[v.jsx($S,{"aria-hidden":"true"}),v.jsx("span",{children:"Checkout"})]}),v.jsx("p",{className:$(t,`${U}-cart-footer`),children:M||"Shipping and taxes calculated at checkout."})]})};function S8(e){return mt({attr:{viewBox:"0 0 384 512"},child:[{tag:"path",attr:{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"},child:[]}]})(e)}const A8=({images:e,altText:t,globalClassName:n})=>{if(e.length===0)return null;const r=e.length>1;return v.jsxs(ph,{className:$(n,`${U}-pdp-gallery`),slidesPerPage:1,slidesPerMove:1,slideCount:e.length,loop:!0,"aria-label":t||"Product images",children:[v.jsx(dh,{className:$(n,`${U}-pdp-gallery__item-group`),children:e.map((o,a)=>v.jsx(ch,{index:a,className:$(n,`${U}-pdp-gallery__item`),children:v.jsx("img",{className:$(n,`${U}-pdp-gallery__image`),src:o,alt:t?`${t} (${a+1})`:`Product image ${a+1}`,loading:"lazy"})},o))}),r&&v.jsxs(ah,{className:$(n,`${U}-pdp-gallery__control`),children:[v.jsx(hh,{className:$(n,`${U}-pdp-gallery__prev-trigger`),"aria-label":"Previous image",children:v.jsx(eb,{size:"16px"})}),v.jsx(fh,{className:$(n,`${U}-pdp-gallery__next-trigger`),"aria-label":"Next image",children:v.jsx(tb,{size:"16px"})})]}),r&&v.jsx(lh,{className:$(n,`${U}-pdp-gallery__indicator-group`),children:e.map((o,a)=>v.jsx(uh,{index:a,className:$(n,`${U}-pdp-gallery__indicator`),"aria-label":`Go to image ${a+1}`},a))})]})},vl="color",Ih=(e,t)=>/^https?:\/\//i.test(t)||!e?t:`${e}${t}`,oT=e=>e.replace(/(^|\/)large\//,"$1medium/"),sT=(e,t)=>!e.vattr||!t?!1:e.vattr.some(n=>n.id===vl&&n.vals.includes(t)),C8=(e,t)=>{var c,d;const n=((c=e.imgGroups)!=null?c:[]).filter(h=>h.viewType==="large"),r=t&&n.find(h=>sT(h,t)),o=n.find(h=>h.vattr===null),a=r||o||n[0],u=((d=a==null?void 0:a.imgs)!=null?d:[]).map(h=>Ih(e.baseUrl,oT(h.url)));return u.length>0?u:e.imageUrl?[Ih(e.baseUrl,oT(e.imageUrl))]:[]},k8=(e,t)=>{var o,a,u;const n=((o=e.imgGroups)!=null?o:[]).find(c=>c.viewType==="swatch"&&sT(c,t)),r=(u=(a=n==null?void 0:n.imgs)==null?void 0:a[0])==null?void 0:u.url;return r?Ih(e.baseUrl,r):""},Rh=(e,t,n,r={})=>!e||e.length===0||!t||!n?!1:e.some(o=>{var a;return((a=o.vars)==null?void 0:a[t])!==n||o.ord===!1?!1:Object.entries(r).every(([u,c])=>{var d;return u===t||((d=o.vars)==null?void 0:d[u])===c})}),N8=(e,t)=>{const n=Object.keys(t);return n.length===0?!0:!e||e.length===0?!1:e.some(r=>r.ord!==!1&&n.every(o=>{var a;return((a=r.vars)==null?void 0:a[o])===t[o]}))},O8=e=>{var n;const t={};for(const r of(n=e.vattr)!=null?n:[]){const o=r.opts.find(u=>Rh(e.vmat,r.id,u.val)),a=o!=null?o:r.opts[0];a&&(t[r.id]=a.val)}return t},I8=({product:e,globalClassName:t,openLinksInNewTab:n})=>{var ne,J,re,oe,be,Ie,fe,Q,se,C,F,te;const{logger:r}=At(),o=e.data,a=(ne=e.id)!=null?ne:o.id,[u,c]=Z.useState(()=>O8(o)),d=N8(o.vmat,u),h=(re=(J=o.quantity)==null?void 0:J.minQuantity)!=null?re:1,p=(be=(oe=o.quantity)==null?void 0:oe.maxQuantity)!=null?be:Number.POSITIVE_INFINITY,E=(fe=(Ie=o.quantity)==null?void 0:Ie.increment)!=null?fe:1,[T,y]=Z.useState(h),x=u[vl],_=Z.useMemo(()=>C8(o,x),[o,x]),S=((Q=o.vattr)!=null?Q:[]).find(k=>k.id===vl),A=((se=o.vattr)!=null?se:[]).filter(k=>k.id!==vl),O=(k,pe)=>()=>{c(Se=>ae(H({},Se),{[k]:pe}))},R=()=>{r==null||r.info("[ProductDetailCard] Add to cart",{productId:a,selectedVariants:u,quantity:T})},z=!d||T-E<h,W=!d||T+E>p,M=k=>{var Se;const pe=u[k.id];return(Se=k.opts.find(Ae=>Ae.val===pe))==null?void 0:Se.name},K=()=>y(k=>Math.max(h,k-E)),de=()=>y(k=>Math.min(p,k+E)),xe=k=>v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant`),children:[v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant-label`),children:[v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-name`),children:k.lbl||k.id}),M(k)&&v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-value`),children:M(k)})]}),v.jsx("div",{className:$(t,`${U}-msg-pdp__chips`),children:k.opts.map(pe=>{const Se=Rh(o.vmat,k.id,pe.val,u),Ae=u[k.id]===pe.val;return v.jsx(Ni,{className:$(`${U}-msg-pdp__chip`,{selected:Ae,unavailable:!Se}),onClick:O(k.id,pe.val),children:pe.name||pe.val},pe.val)})})]},k.id),D=k=>v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant`),children:[v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant-label`),children:[v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-name`),children:k.lbl||"Color"}),M(k)&&v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-value`),children:M(k)})]}),v.jsx("div",{className:$(t,`${U}-msg-pdp__swatches`),children:k.opts.map(pe=>{const Se=Rh(o.vmat,k.id,pe.val,u),Ae=u[k.id]===pe.val,Be=k8(o,pe.val);return Be?v.jsx(Ni,{title:`Select ${pe.name||pe.val}`,className:$(`${U}-msg-pdp__swatch`,{selected:Ae,unavailable:!Se}),onClick:O(k.id,pe.val),children:v.jsx("img",{className:$(t,`${U}-msg-pdp__swatch-image`),src:Be,alt:pe.name||pe.val,loading:"lazy"})},pe.val):v.jsx(Ni,{className:$(`${U}-msg-pdp__chip`,{selected:Ae,unavailable:!Se}),onClick:O(k.id,pe.val),children:pe.name||pe.val},pe.val)})})]});return v.jsx("div",{className:$(t,`${U}-msg-pdp`),children:v.jsxs("div",{className:$(t,`${U}-msg-pdp__card`),children:[v.jsx("div",{className:$(t,`${U}-msg-pdp__gallery`),children:v.jsx(A8,{images:_,altText:o.name,globalClassName:t})}),v.jsxs("div",{className:$(t,`${U}-msg-pdp__content`),children:[o.slugUrl?v.jsx("a",{href:o.slugUrl,target:n?"_blank":"_self",rel:"noopener noreferrer",className:$(t,`${U}-msg-pdp__title-link`),"aria-label":`Go to product page for ${o.name}`,children:o.name}):v.jsx("p",{className:$(t,`${U}-msg-pdp__title`),children:o.name}),v.jsx(vb,{globalClassName:t,className:`${U}-msg-pdp__price`,retailPrice:(C=o.pr)==null?void 0:C.orig,discountPrice:((F=o.pr)==null?void 0:F.cur)||((te=o.pr)==null?void 0:te.prom),currencyCode:o.ccy,fontSize:"14px"}),o.dscr&&v.jsx("p",{className:$(t,`${U}-msg-pdp__description`),children:o.dscr}),S&&D(S),A.map(xe),v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant`),children:[v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant-label`),children:[v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-name`),children:"Quantity"}),v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-value`),children:T})]}),v.jsxs("div",{className:$(t,`${U}-msg-pdp__stepper`),children:[v.jsx(ar,{className:`${U}-msg-pdp__stepper-btn`,ariaLabel:"Decrease quantity",icon:v.jsx(DS,{}),disabled:z,onClick:K}),v.jsx("span",{className:$(t,`${U}-msg-pdp__quantity`),children:T}),v.jsx(ar,{className:`${U}-msg-pdp__stepper-btn`,ariaLabel:"Increase quantity",icon:v.jsx(MS,{}),disabled:W,onClick:de})]})]}),v.jsxs("div",{className:$(t,`${U}-msg-pdp__actions`),children:[v.jsxs(Ni,{className:`${U}-msg-pdp__express-pay`,disabled:!0,children:[v.jsx(S8,{size:"16px"})," Pay"]}),v.jsx(Ni,{className:`${U}-msg-pdp__add-to-cart`,disabled:!d,onClick:R,children:"Add to cart"})]})]})]})})},aT=({content:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{sendMessage:o,loading:a}=Vr();return v.jsx(v.Fragment,{children:e.response.map((u,c)=>{var d,h,p,E,T,y,x,_,S,A,O,R,z,W,M,K;switch(u.type){case"markdown":return v.jsx(Oh,{text:(h=(d=u.data)==null?void 0:d.content)!=null?h:"",globalClassName:t,openLinksInNewTab:n,showIsLoading:!1},`${u.type}-${(p=u.index)!=null?p:c}`);case"product_carousel":return v.jsx(w8,{title:(T=(E=u.data)==null?void 0:E.title)!=null?T:"",products:(x=(y=u.data)==null?void 0:y.products)!=null?x:[],globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(_=u.index)!=null?_:c}`);case"product_tile":return v.jsx(I8,{product:u.data,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(S=u.index)!=null?S:c}`);case"cart":{const de=(R=(O=(A=u.data)==null?void 0:A.cart)==null?void 0:O.cartSummary)==null?void 0:R.cartDetails;return de?v.jsx(v8,{cart:de,productsToHighlight:u.data.products_to_highlight,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(z=u.index)!=null?z:c}`):null}case"suggestions":return v.jsx("div",{style:{marginTop:"0.5rem"},children:v.jsx(iD,{disabled:a,suggestions:(M=(W=u.data)==null?void 0:W.display_text)!=null?M:[],globalClassName:t,isWidgetStandalone:r,onSuggestionClick:o})},`${u.type}-${(K=u.index)!=null?K:c}`);default:return null}})})},R8=({message:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{logger:o}=At(),a=Z.useMemo(()=>{try{const c=JSON.parse(e.content);return Array.isArray(c==null?void 0:c.response)?c:null}catch(c){return null}},[e.content]),u=Z.useMemo(()=>{const c="Oops, I had trouble with your request.";if(typeof e.content!="string")return o==null||o.warn("Message content is not richtext format. Showing fallback text.",e.content),c;const d=e.content.trim();try{const h=JSON.parse(d);if(typeof h=="object"&&h!==null)return o==null||o.debug("Detected JSON object instead of array of responses in message content",e.content),h.text||h.message||c}catch(h){if(d.startsWith("{")||d.startsWith("["))return o==null||o.warn("Failed to parse JSON-like message content. Showing fallback text.",e.content),c}return e.content||c},[o,e.content]);switch(e.role){case"user":return v.jsx("div",{className:$(t,`${U}-message`,r?"standalone":"embedded"),children:v.jsx("div",{className:$(t,`${U}-user-message`,r?"standalone":"embedded"),children:v.jsxs("div",{className:$(t,`${U}-user-message-row`,r?"standalone":"embedded"),children:[v.jsx("span",{className:$(t,`${U}-message-icon user-message-icon`,r?"standalone":"embedded"),children:v.jsx(VS,{})}),v.jsx("p",{className:$(t,`${U}-user-message-text`,r?"standalone":"embedded"),children:e.content})]})})});case"agent":return v.jsx("div",{className:$(t,`${U}-message-group`,r?"standalone":"embedded"),children:v.jsx("div",{className:`${U}-message-group-child`,children:a?v.jsx(aT,{content:a,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r}):v.jsx(Oh,{text:u,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})})});case"system":return v.jsx("div",{className:$(t,`${U}-message`,r?"standalone":"embedded"),children:v.jsx("p",{className:$(t,`${U}-reset-message`),children:e.content})})}},Ph=({isWidgetStandalone:e})=>{const{globalClassName:t,openLinksInNewTab:n}=At(),{messages:r,streamingBlocks:o,isAgentTyping:a,loading:u,progressMessage:c,connectionStatus:d}=Vr(),h=Z.useRef(null),p=r.length>0,E=o.length>0,T=p&&(u||a)&&!E,y=d==="reconnecting"&&!T;return Z.useEffect(()=>{var x;(x=h.current)==null||x.scrollIntoView({behavior:"smooth"})},[r,o]),v.jsxs(v.Fragment,{children:[u&&!p&&v.jsx(lD,{globalClassName:t,isWidgetStandalone:e}),r.map(x=>v.jsx(R8,{message:x,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e},x.id)),E&&v.jsxs("div",{className:$(t,`${U}-message-group`,e?"standalone":"embedded"),children:[v.jsx(aT,{content:{response:o},globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e}),(u||a)&&v.jsx(xh,{globalClassName:t,isWidgetStandalone:e})]}),T&&v.jsx(xh,{globalClassName:t,isWidgetStandalone:e,loadingText:c}),y&&v.jsx(xh,{globalClassName:t,isWidgetStandalone:e,loadingText:"Reconnecting..."}),v.jsx("div",{ref:h})]})},uT=()=>{const{globalClassName:e,themeVariables:t}=At(),{isAgentTyping:n,sendMessage:r,resetConversation:o}=Vr(),a=n;return v.jsxs("div",{className:$(e,`${U}-container`,`${U}-embedded-chat`),style:t,children:[v.jsx("div",{className:$(e,`${U}-message-container`,"embedded"),children:v.jsx(Ph,{isWidgetStandalone:!1})}),v.jsx(Sf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:u=>r(u)}),v.jsx("div",{className:$(`${U}-embedded-chat-menu`),children:v.jsxs(gL,{componentType:"chat",children:[v.jsx(Sb,{componentType:"chat"}),v.jsx(DE,{componentType:"chat",onClearChat:o})]})})]})},lT=e=>{var d;const{children:t,disabled:n}=e,[r,o]=Z.useState((d=e.container)==null?void 0:d.current),a=Z.useSyncExternalStore(L8,()=>!1,()=>!0),{getRootNode:u}=bl();if(Z.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),a||n)return v.jsx(v.Fragment,{children:t});const c=r!=null?r:P8(u);return v.jsx(v.Fragment,{children:Z.Children.map(t,h=>Is.createPortal(h,c))})},P8=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Bi(n)?n:dr(t).body},L8=()=>()=>{},cT=()=>{const{globalClassName:e,themeVariables:t}=At(),{mode:n,status:r,dialogPosition:o,isDialogFullHeight:a,dialogWidth:u}=ki(),{loading:c,isAgentTyping:d,sendMessage:h,resetConversation:p}=Vr(),{isOpen:E}=r||{},T=!!r.isOpen,y=n==="standalone",x=d||c,_=()=>{Ci(!1)};return v.jsx(yb,{lazyMount:!0,unmountOnExit:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:T,children:v.jsx(lT,{children:v.jsx(Eh,{className:$(e,`${U}-container`,`${U}-dialog`,o,a&&"full-height"),style:H(H({},t),u&&{width:u}),children:v.jsxs(mh,{className:$(e,`${U}-dialog-content`,{standalone:y,embedded:!y}),children:[v.jsx(wb,{componentType:"dialog",onClearChat:p,onClose:_}),v.jsx(gh,{className:$(e,`${U}-message-container`,{standalone:y,embedded:!y}),children:v.jsx(Ph,{isWidgetStandalone:y,isOpen:E})}),v.jsx(Sf,{componentType:"dialog",isLoading:x,onSubmit:S=>h(S)})]})})})})},dT=()=>{const{globalClassName:e,themeVariables:t}=At(),{mode:n,status:r,isModalFullscreen:o}=ki(),{isAgentTyping:a,sendMessage:u,resetConversation:c}=Vr(),{isOpen:d}=r||{},h=!!r.isOpen,p=n==="standalone",E=a,T=({open:x})=>{Ci(x)},y=()=>{Ci(!1)};return h?v.jsx(yb,{lazyMount:!0,unmountOnExit:!0,open:h,onOpenChange:T,children:v.jsx(lT,{children:v.jsxs("div",{className:$(e,`${U}-modal-container`),style:t,children:[v.jsx(hb,{className:$(e,`${U}-modal-backdrop`)}),v.jsx(Eh,{className:$(e,`${U}-container`,`${U}-modal`,{fullscreen:o,standalone:p,embedded:!p}),children:v.jsxs(mh,{className:$(e,`${U}-modal-content`,{standalone:p,embedded:!p}),children:[v.jsx(wb,{componentType:"modal",onClearChat:c,onClose:y}),v.jsx(gh,{className:$(e,`${U}-message-container`,{standalone:p,embedded:!p}),children:v.jsx(Ph,{isWidgetStandalone:p,isOpen:d})}),v.jsx(Sf,{componentType:"modal",isLoading:E,onSubmit:x=>u(x)})]})})]})})}):null},D8=()=>{const e=ki(),{status:{type:t,isMinimized:n}}=e||{status:{}};return n?v.jsx(HS,{}):t==="dialog"?v.jsx(cT,{}):t==="modal"?v.jsx(dT,{}):v.jsx(uT,{})},Lh=e=>v.jsx(R0,ae(H({},e),{children:v.jsx(D8,{})}));var Sl={},fT;function M8(){if(fT)return Sl;fT=1;var e=F0();return Sl.createRoot=e.createRoot,Sl.hydrateRoot=e.hydrateRoot,Sl}var hT=M8();const F8=r=>{var o=r,{elementId:e,timeout:t=5e3}=o,n=sn(o,["elementId","timeout"]);let a;const u=(d,h)=>{var p;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),(p=hT.createRoot(T))==null||p.render(v.jsx(Lh,ae(H({},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},B8=r=>{var o=r,{timeout:e,elementId:t}=o,n=sn(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"),F8(H({elementId:t,timeout:e},n));return}hT.createRoot(a).render(v.jsx(Lh,ae(H({},n),{mode:"messaging"})))},U8={components:{setEntryType:O0,toggleWidgetOpen:Ci,toggleWidgetMinimized:vu,toggleModalFullscreen:xd,setWidgetType:Su,setWidgetDialogPosition:wd}};Re.AgentForceWidget=Lh,Re.AgentforceWidgetProvider=R0,Re.MessagingDialog=cT,Re.MessagingEmbed=uT,Re.MessagingModal=dT,Re.MessagingProvider=N0,Re.eventHandlers=U8,Re.injectMessagingWidget=B8,Re.useMessaging=Vr,Object.defineProperty(Re,Symbol.toStringTag,{value:"Module"})}));
52
+ `))}function d(y,x,_,S){const A=_.enter("tableCell"),O=_.enter("phrasing"),R=_.containerPhrasing(y,ae(B({},S),{before:a,after:a}));return O(),A(),R}function h(y,x){return GD(y,{align:x,alignDelimiters:r,padding:n,stringLength:o})}function p(y,x,_){const S=y.children;let A=-1;const O=[],R=x.enter("table");for(;++A<S.length;)O[A]=E(S[A],x,_);return R(),O}function E(y,x,_){const S=y.children;let A=-1;const O=[],R=x.enter("tableRow");for(;++A<S.length;)O[A]=d(S[A],y,x,_);return R(),O}function T(y,x,_){let S=Vb.inlineCode(y,x,_);return _.stack.includes("tableCell")&&(S=S.replace(/\|/g,"\\$&")),S}}function D5(){return{exit:{taskListCheckValueChecked:Yb,taskListCheckValueUnchecked:Yb,paragraph:F5}}}function M5(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:B5}}}function Yb(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function F5(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 B5(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=Vb.listItem(e,t,n,B(B({},r),c.current()));return a&&(d=d.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),d;function h(p){return p+u}}function U5(){return[ED(),BD(),jD(),k5(),D5()]}function H5(e){return{extensions:[yD(),UD(e),$D(),L5(e),M5()]}}const z5={tokenize:W5,partial:!0},Wb={tokenize:G5,partial:!0},Gb={tokenize:K5,partial:!0},Kb={tokenize:Q5,partial:!0},j5={tokenize:X5,partial:!0},Qb={name:"wwwAutolink",tokenize:q5,previous:Jb},Xb={name:"protocolAutolink",tokenize:Y5,previous:Zb},Ir={name:"emailAutolink",tokenize:V5,previous:eT},yr={};function $5(){return{text:yr}}let qi=48;for(;qi<123;)yr[qi]=Ir,qi++,qi===58?qi=65:qi===91&&(qi=97);yr[43]=Ir,yr[45]=Ir,yr[46]=Ir,yr[95]=Ir,yr[72]=[Ir,Xb],yr[104]=[Ir,Xb],yr[87]=[Ir,Qb],yr[119]=[Ir,Qb];function V5(e,t,n){const r=this;let o,a;return u;function u(E){return!kh(E)||!eT.call(r,r.previous)||Nh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return kh(E)?(e.consume(E),c):E===64?(e.consume(E),d):n(E)}function d(E){return E===46?e.check(j5,p,h)(E):E===45||E===95||Gt(E)?(a=!0,e.consume(E),d):p(E)}function h(E){return e.consume(E),o=!0,d}function p(E){return a&&o&&nn(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(E)):n(E)}}function q5(e,t,n){const r=this;return o;function o(u){return u!==87&&u!==119||!Jb.call(r,r.previous)||Nh(r.events)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(z5,e.attempt(Wb,e.attempt(Gb,a),n),n)(u))}function a(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function Y5(e,t,n){const r=this;let o="",a=!1;return u;function u(E){return(E===72||E===104)&&Zb.call(r,r.previous)&&!Nh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(nn(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||Ou(E)||it(E)||Ii(E)||Iu(E)?n(E):e.attempt(Wb,e.attempt(Gb,p),n)(E)}function p(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function W5(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 G5(e,t,n){let r,o,a;return u;function u(h){return h===46||h===95?e.check(Kb,d,c)(h):h===null||it(h)||Ii(h)||h!==45&&Iu(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 K5(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(Kb,t,a)(u):u===null||it(u)||Ii(u)?t(u):(e.consume(u),o)}function a(u){return u===41&&r++,e.consume(u),o}}function Q5(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)||Ii(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||it(c)||Ii(c)?t(c):r(c)}function a(c){return nn(c)?u(c):n(c)}function u(c){return c===59?(e.consume(c),r):nn(c)?(e.consume(c),u):n(c)}}function X5(e,t,n){return r;function r(a){return e.consume(a),o}function o(a){return Gt(a)?n(a):t(a)}}function Jb(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||it(e)}function Zb(e){return!nn(e)}function eT(e){return!(e===47||kh(e))}function kh(e){return e===43||e===45||e===46||e===95||Gt(e)}function Nh(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 J5={tokenize:s8,partial:!0};function Z5(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:r8,continuation:{tokenize:i8},exit:o8}},text:{91:{name:"gfmFootnoteCall",tokenize:n8},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:e8,resolveTo:t8}}}}function e8(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=Yn(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 t8(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 n8(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(Yn(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?p:h}function p(E){return E===91||E===92||E===93?(e.consume(E),a++,h):h(E)}}function r8(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",p):n(x)}function p(x){if(u>999||x===93&&!c||x===null||x===91||it(x))return n(x);if(x===93){e.exit("chunkString");const _=e.exit("gfmFootnoteDefinitionLabelString");return a=Yn(r.sliceSerialize(_)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(x),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),T}return it(x)||(c=!0),u++,e.consume(x),x===92?E:p}function E(x){return x===91||x===92||x===93?(e.consume(x),u++,p):p(x)}function T(x){return x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),o.includes(a)||o.push(a),Qe(e,y,"gfmFootnoteDefinitionWhitespace")):n(x)}function y(x){return t(x)}}function i8(e,t,n){return e.check(Bs,t,e.attempt(J5,t,n))}function o8(e){e.exit("gfmFootnoteDefinition")}function s8(e,t,n){const r=this;return Qe(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 a8(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 p={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",p,c],["enter",u[h][1],c],["exit",u[h][1],c],["enter",E,c]],y=c.parser.constructs.insideSpan.null;y&&xn(T,T.length,0,Ru(y,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",p,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,p=this.events;let E=0;return T;function T(x){return h===126&&p[p.length-1][1].type!=="characterEscape"?d(x):(u.enter("strikethroughSequenceTemporary"),y(x))}function y(x){const _=To(h);if(x===126)return E>1?d(x):(u.consume(x),E++,y);if(E<2&&!n)return d(x);const S=u.exit("strikethroughSequenceTemporary"),A=To(x);return S._open=!A||A===2&&!!_,S._close=!_||_===2&&!!A,c(x)}}}class u8{constructor(){this.map=[]}add(t,n,r){l8(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 l8(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 c8(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 d8(){return{flow:{null:{name:"table",tokenize:f8,resolveAll:h8}}}}function f8(e,t,n){const r=this;let o=0,a=0,u;return c;function c(z){let X=r.events.length-1;for(;X>-1;){const re=r.events[X][1].type;if(re==="lineEnding"||re==="linePrefix")X--;else break}const se=X>-1?r.events[X][1].type:null,ee=se==="tableHead"||se==="tableRow"?D:d;return ee===D&&r.parser.lazy[r.now().line]?n(z):ee(z)}function d(z){return e.enter("tableHead"),e.enter("tableRow"),h(z)}function h(z){return z===124||(u=!0,a+=1),p(z)}function p(z){return z===null?n(z):Le(z)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(z),e.exit("lineEnding"),y):n(z):Ge(z)?Qe(e,p,"whitespace")(z):(a+=1,u&&(u=!1,o+=1),z===124?(e.enter("tableCellDivider"),e.consume(z),e.exit("tableCellDivider"),u=!0,p):(e.enter("data"),E(z)))}function E(z){return z===null||z===124||it(z)?(e.exit("data"),p(z)):(e.consume(z),z===92?T:E)}function T(z){return z===92||z===124?(e.consume(z),E):E(z)}function y(z){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(z):(e.enter("tableDelimiterRow"),u=!1,Ge(z)?Qe(e,x,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(z):x(z))}function x(z){return z===45||z===58?S(z):z===124?(u=!0,e.enter("tableCellDivider"),e.consume(z),e.exit("tableCellDivider"),_):W(z)}function _(z){return Ge(z)?Qe(e,S,"whitespace")(z):S(z)}function S(z){return z===58?(a+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(z),e.exit("tableDelimiterMarker"),A):z===45?(a+=1,A(z)):z===null||Le(z)?H(z):W(z)}function A(z){return z===45?(e.enter("tableDelimiterFiller"),O(z)):W(z)}function O(z){return z===45?(e.consume(z),O):z===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(z),e.exit("tableDelimiterMarker"),R):(e.exit("tableDelimiterFiller"),R(z))}function R(z){return Ge(z)?Qe(e,H,"whitespace")(z):H(z)}function H(z){return z===124?x(z):z===null||Le(z)?!u||o!==a?W(z):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(z)):W(z)}function W(z){return n(z)}function D(z){return e.enter("tableRow"),K(z)}function K(z){return z===124?(e.enter("tableCellDivider"),e.consume(z),e.exit("tableCellDivider"),K):z===null||Le(z)?(e.exit("tableRow"),t(z)):Ge(z)?Qe(e,K,"whitespace")(z):(e.enter("data"),fe(z))}function fe(z){return z===null||z===124||it(z)?(e.exit("data"),K(z)):(e.consume(z),z===92?Te:fe)}function Te(z){return z===92||z===124?(e.consume(z),fe):fe(z)}}function h8(e,t){let n=-1,r=!0,o=0,a=[0,0,0,0],u=[0,0,0,0],c=!1,d=0,h,p,E;const T=new u8;for(;++n<e.length;){const y=e[n],x=y[1];y[0]==="enter"?x.type==="tableHead"?(c=!1,d!==0&&(tT(T,t,d,h,p),p=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,E=void 0,a=[0,0,0,0],u=[0,n+1,0,0],c&&(c=!1,p={type:"tableBody",start:Object.assign({},x.start),end:Object.assign({},x.end)},T.add(n,0,[["enter",p,t]])),o=x.type==="tableDelimiterRow"?2:p?3:1):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")?(r=!1,u[2]===0&&(a[1]!==0&&(u[0]=u[1],E=_l(T,t,a,o,void 0,E),a=[0,0,0,0]),u[2]=n)):x.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(u[0]=u[1],E=_l(T,t,a,o,void 0,E)),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],E=_l(T,t,a,o,n,E)):u[1]!==0&&(E=_l(T,t,u,o,n,E)),o=0):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")&&(u[3]=n)}for(d!==0&&tT(T,t,d,h,p),T.consume(t.events),n=-1;++n<t.events.length;){const y=t.events[n];y[0]==="enter"&&y[1].type==="table"&&(y[1]._align=c8(t.events,n))}return e}function _l(e,t,n,r,o,a){const u=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(a.end=Object.assign({},Wo(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const d=Wo(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=Wo(t.events,n[2]),p=Wo(t.events,n[3]),E={type:c,start:Object.assign({},h),end:Object.assign({},p)};if(e.add(n[2],0,[["enter",E,t]]),r!==2){const T=t.events[n[2]],y=t.events[n[3]];if(T[1].end=Object.assign({},y[1].end),T[1].type="chunkText",T[1].contentType="text",n[3]>n[2]+1){const x=n[2]+1,_=n[3]-n[2]-1;e.add(x,_,[])}}e.add(n[3]+1,0,[["exit",E,t]])}return o!==void 0&&(a.end=Object.assign({},Wo(t.events,o)),e.add(o,0,[["exit",a,t]]),a=void 0),a}function tT(e,t,n,r,o){const a=[],u=Wo(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 Wo(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const p8={name:"tasklistCheck",tokenize:g8};function m8(){return{text:{91:p8}}}function g8(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):Ge(d)?e.check({tokenize:E8},t,n)(d):n(d)}}function E8(e,t,n){return Qe(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function y8(e){return _g([$5(),Z5(),a8(e),d8(),m8()])}const b8={};function T8(e){const t=this,n=e||b8,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),u=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push(y8(n)),a.push(U5()),u.push(H5(n))}const x8=()=>v.jsx("span",{className:`${U}-blinking-cursor`,children:v.jsx("svg",{height:"16px",width:"16px",xmlns:"http://www.w3.org/2000/svg",children:v.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),Oh=({globalClassName:e,openLinksInNewTab:t,showIsLoading:n,text:r})=>v.jsx(h1,{remarkPlugins:[T8],rehypePlugins:[SE],components:{h1:({children:o})=>v.jsx("h1",{className:$(e,`${U}-header h1`),children:o}),h2:({children:o})=>v.jsx("h2",{className:$(e,`${U}-header h2`),children:o}),h3:({children:o})=>v.jsx("h3",{className:$(e,`${U}-header h3`),children:o}),ul:({children:o})=>v.jsx("ul",{className:$(e,`${U}-ul`),children:o}),ol:({children:o})=>v.jsx("ol",{className:$(e,`${U}-ol`),children:o}),li:({children:o})=>v.jsx("li",{className:$(e,`${U}-li`),children:o}),a:({href:o,children:a})=>v.jsx(RE,{globalClassName:e,openLinksInNewTab:t,href:o,children:a}),table:({children:o})=>v.jsx("div",{className:$(e,`${U}-table-container`),children:v.jsx("table",{className:$(e,`${U}-table`),children:o})}),thead:({children:o})=>v.jsx("thead",{className:$(e,`${U}-thead`),children:o}),tbody:({children:o})=>v.jsx("tbody",{className:$(e,`${U}-tbody`),children:o}),tr:({children:o})=>v.jsx("tr",{className:$(e,`${U}-tr`),children:o}),th:({children:o})=>v.jsx("th",{className:$(e,`${U}-th`),children:o}),td:({children:o})=>v.jsx("td",{className:$(e,`${U}-td`),children:o}),span:({className:o,children:a})=>o===`${U}-blinking-cursor`?v.jsx(x8,{}):v.jsx("span",{children:a})},children:r+(n?`<span className='${U}-blinking-cursor'></span>`:"")}),nT=({product:e,globalClassName:t,isFullWidth:n,openLinksInNewTab:r})=>{const{name:o,imageUrl:a,productPageUrl:u,price:c,discountPrice:d,compareAtPrice:h,currencyCode:p}=e,E=typeof d=="number"&&typeof c=="number"&&d<c,T=E?c:h!=null?h:c,y=E?d:c;return v.jsxs("div",{className:$(t,`${U}-msg-product-card`,{"card-full-width":n}),children:[v.jsx("div",{className:$(t,`${U}-msg-product-card__image-wrapper`),children:a&&(u?v.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener","aria-label":`Go to product page for ${o}`,children:v.jsx("img",{className:$(t,`${U}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"})}):v.jsx("img",{className:$(t,`${U}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"}))}),v.jsxs("div",{className:$(t,`${U}-msg-product-card__content`),children:[u?v.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener",className:$(t,`${U}-msg-product-card__title-link`),"aria-label":`Go to product page for ${o}`,children:o}):v.jsx("p",{className:$(t,`${U}-msg-product-card__title`),children:o}),v.jsx("div",{className:$(t,`${U}-msg-product-card__price-row`),children:v.jsx(vb,{globalClassName:t,retailPrice:T,discountPrice:y,currencyCode:p})})]})]})},rT=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}),w8=({title:e,products:t,globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o})=>{if(t.length===1){const a=t[0];return v.jsxs("div",{children:[e&&v.jsx("p",{className:$(n,`${U}-product-carousel-title`),children:e}),v.jsx(nT,{product:rT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o,isFullWidth:!o})]})}return v.jsxs("div",{style:{marginBottom:"1rem"},children:[e&&v.jsx("p",{className:$(n,`${U}-product-carousel-title`),children:e}),v.jsx(LL,{globalClassName:n,spacing:o?"0.5rem":"6px",ariaLabel:e||"Product recommendations",children:t.map(a=>v.jsx(nT,{product:rT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o},a.id))})]})},iT=({code:e,globalClassName:t})=>v.jsxs("span",{className:$(t,`${U}-cart-chip`),children:[v.jsx(q0,{"aria-hidden":"true"}),v.jsx("span",{children:e})]}),Yi=({label:e,badge:t,value:n,currencyCode:r,globalClassName:o,emphasized:a,isDiscount:u,fallback:c})=>{let d;if(typeof n=="number")n===0&&!u?d="Free":d=ma(u?-n:n,r);else if(c)d=c;else return null;return v.jsxs("div",{className:$(o,`${U}-cart-total-row`,{emphasized:a}),children:[v.jsxs("span",{className:$(o,`${U}-cart-total-label`),children:[e,t&&v.jsx("span",{className:$(o,`${U}-cart-total-badge`),children:t})]}),v.jsx("span",{className:$(o,`${U}-cart-total-value`),children:d})]})},_8=({item:e,currencyCode:t,loading:n,globalClassName:r,onRemove:o})=>{var u,c,d;const a=typeof e.originalSubtotal=="number"&&typeof e.itemSubtotal=="number"&&e.originalSubtotal>e.itemSubtotal;return v.jsxs("li",{className:$(r,`${U}-cart-item`),children:[e.imageUrl&&v.jsx("div",{className:$(r,`${U}-cart-item-image`),children:v.jsx("img",{src:e.imageUrl,alt:e.name||"Product image",loading:"lazy"})}),v.jsxs("div",{className:$(r,`${U}-cart-item-details`),children:[v.jsx("p",{className:$(r,`${U}-cart-item-name`),children:e.name}),v.jsxs("div",{className:$(r,`${U}-cart-item-attrs`),children:[((u=e.variants)!=null?u:[]).map(h=>v.jsxs("p",{className:$(r,`${U}-cart-item-attr`),children:[h.lbl,": ",h.value]},`${h.type}-${h.value}`)),((c=e.promotions)!=null?c:[]).map(h=>v.jsxs("p",{className:$(r,`${U}-cart-item-attr`),children:["Promotion: ",h]},h))]}),((d=e.coupons)!=null?d:[]).length>0&&v.jsx("div",{className:$(r,`${U}-cart-chips`),children:e.coupons.map(h=>v.jsx(iT,{code:h,globalClassName:r},h))}),v.jsxs("span",{className:$(r,`${U}-cart-item-price`),children:[a&&v.jsx("span",{className:$(r,`${U}-cart-item-original-price`),children:ma(e.originalSubtotal,t)}),v.jsx("span",{className:$(r,`${U}-cart-item-final-price`),children:ma(e.itemSubtotal,t)})]}),v.jsxs("div",{className:$(r,`${U}-cart-item-footer`),children:[v.jsxs("span",{className:$(r,`${U}-cart-item-qty`),children:["Qty: ",e.quantity]}),v.jsx("button",{type:"button",className:$(r,`${U}-cart-item-remove`),disabled:n,onClick:()=>o(e),children:"Remove"})]})]})]})},v8=({cart:e,globalClassName:t,openLinksInNewTab:n})=>{const{sendMessage:r,loading:o}=Vr(),[a,u]=Z.useState(!0),[c,d]=Z.useState(""),{items:h=[],currencyCode:p="USD",subtotal:E,total:T,taxes:y,shippingCost:x,shippingDiscount:_,shippingPromotions:S=[],promotionsDiscount:A,promotions:O=[],couponsDiscount:R,couponsApplied:H=[],bodyMessage:W,footerMessage:D,checkoutButtonUrl:K}=e,fe=z=>{o||r(`Remove ${z.name} from my cart`)},Te=()=>{const z=c.trim();!z||o||(r(`Apply coupon code ${z}`),d(""))};return v.jsxs("div",{className:$(t,`${U}-cart`),children:[v.jsxs("div",{className:$(t,`${U}-cart-box`),children:[W&&v.jsxs("button",{type:"button",className:$(t,`${U}-cart-summary`),"aria-expanded":a,onClick:()=>u(z=>!z),children:[v.jsx("span",{className:$(t,`${U}-cart-summary-text`),children:v.jsx(Oh,{text:W,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})}),v.jsx("span",{className:$(t,`${U}-cart-summary-toggle`),"aria-hidden":"true",children:a?v.jsx(YS,{}):v.jsx(WS,{})})]}),a&&v.jsxs("div",{className:$(t,`${U}-cart-expanded`),children:[v.jsx("ul",{className:$(t,`${U}-cart-items`),children:h.map(z=>v.jsx(_8,{item:z,currencyCode:p,loading:o,globalClassName:t,onRemove:fe},z.itemId))}),H.length>0&&v.jsx("div",{className:$(t,`${U}-cart-chips`,`${U}-cart-applied-coupons`),children:H.map(z=>v.jsx(iT,{code:z,globalClassName:t},z))}),v.jsxs("div",{className:$(t,`${U}-cart-totals`),children:[v.jsx(Yi,{label:"Subtotal",value:E,currencyCode:p,globalClassName:t}),v.jsx(Yi,{label:"Coupon",value:R,currencyCode:p,globalClassName:t,isDiscount:!0}),v.jsx(Yi,{label:"Promotions",badge:O[0],value:A,currencyCode:p,globalClassName:t,isDiscount:!0}),v.jsx(Yi,{label:"Shipping",value:x,currencyCode:p,globalClassName:t,fallback:"TBD"}),v.jsx(Yi,{label:"Shipping Discount",badge:S[0],value:_,currencyCode:p,globalClassName:t,isDiscount:!0}),v.jsx(Yi,{label:"Tax",value:y,currencyCode:p,globalClassName:t,fallback:"TBD"}),v.jsx(Yi,{label:"Total",value:T,currencyCode:p,globalClassName:t,emphasized:!0})]})]})]}),v.jsxs("div",{className:$(t,`${U}-cart-coupon`),children:[v.jsxs("div",{className:$(t,`${U}-cart-coupon-field`),children:[v.jsx("span",{className:$(t,`${U}-cart-coupon-icon`),"aria-hidden":"true",children:v.jsx(q0,{})}),v.jsx("input",{type:"text",className:$(t,`${U}-cart-coupon-input`),placeholder:"Enter coupon code","aria-label":"Enter coupon code",value:c,disabled:o,onChange:z=>d(z.target.value),onKeyDown:z=>{z.key==="Enter"&&(z.preventDefault(),Te())}})]}),v.jsx("button",{type:"button",className:$(t,`${U}-cart-coupon-submit`),"aria-label":"Apply coupon",disabled:o||!c.trim(),onClick:Te,children:v.jsx(qS,{"aria-hidden":"true"})})]}),K&&v.jsxs("a",{className:$(t,`${U}-cart-checkout-button`),href:K,target:n?"_blank":"_self",rel:"noopener noreferrer",children:[v.jsx($S,{"aria-hidden":"true"}),v.jsx("span",{children:"Checkout"})]}),v.jsx("p",{className:$(t,`${U}-cart-footer`),children:D||"Shipping and taxes calculated at checkout."})]})};function S8(e){return mt({attr:{viewBox:"0 0 384 512"},child:[{tag:"path",attr:{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"},child:[]}]})(e)}const A8=({images:e,altText:t,globalClassName:n})=>{if(e.length===0)return null;const r=e.length>1;return v.jsxs(ph,{className:$(n,`${U}-pdp-gallery`),slidesPerPage:1,slidesPerMove:1,slideCount:e.length,loop:!0,"aria-label":t||"Product images",children:[v.jsx(dh,{className:$(n,`${U}-pdp-gallery__item-group`),children:e.map((o,a)=>v.jsx(ch,{index:a,className:$(n,`${U}-pdp-gallery__item`),children:v.jsx("img",{className:$(n,`${U}-pdp-gallery__image`),src:o,alt:t?`${t} (${a+1})`:`Product image ${a+1}`,loading:"lazy"})},o))}),r&&v.jsxs(ah,{className:$(n,`${U}-pdp-gallery__control`),children:[v.jsx(hh,{className:$(n,`${U}-pdp-gallery__prev-trigger`),"aria-label":"Previous image",children:v.jsx(eb,{size:"16px"})}),v.jsx(fh,{className:$(n,`${U}-pdp-gallery__next-trigger`),"aria-label":"Next image",children:v.jsx(tb,{size:"16px"})})]}),r&&v.jsx(lh,{className:$(n,`${U}-pdp-gallery__indicator-group`),children:e.map((o,a)=>v.jsx(uh,{index:a,className:$(n,`${U}-pdp-gallery__indicator`),"aria-label":`Go to image ${a+1}`},a))})]})},vl="color",Ih=(e,t)=>/^https?:\/\//i.test(t)||!e?t:`${e}${t}`,oT=e=>e.replace(/(^|\/)large\//,"$1medium/"),sT=(e,t)=>!e.vattr||!t?!1:e.vattr.some(n=>n.id===vl&&n.vals.includes(t)),C8=(e,t)=>{var c,d;const n=((c=e.imgGroups)!=null?c:[]).filter(h=>h.viewType==="large"),r=t&&n.find(h=>sT(h,t)),o=n.find(h=>h.vattr===null),a=r||o||n[0],u=((d=a==null?void 0:a.imgs)!=null?d:[]).map(h=>Ih(e.baseUrl,oT(h.url)));return u.length>0?u:e.imageUrl?[Ih(e.baseUrl,oT(e.imageUrl))]:[]},k8=(e,t)=>{var o,a,u;const n=((o=e.imgGroups)!=null?o:[]).find(c=>c.viewType==="swatch"&&sT(c,t)),r=(u=(a=n==null?void 0:n.imgs)==null?void 0:a[0])==null?void 0:u.url;return r?Ih(e.baseUrl,r):""},Rh=(e,t,n,r={})=>!e||e.length===0||!t||!n?!1:e.some(o=>{var a;return((a=o.vars)==null?void 0:a[t])!==n||o.ord===!1?!1:Object.entries(r).every(([u,c])=>{var d;return u===t||((d=o.vars)==null?void 0:d[u])===c})}),N8=(e,t)=>{const n=Object.keys(t);return n.length===0?!0:!e||e.length===0?!1:e.some(r=>r.ord!==!1&&n.every(o=>{var a;return((a=r.vars)==null?void 0:a[o])===t[o]}))},O8=e=>{var n;const t={};for(const r of(n=e.vattr)!=null?n:[]){const o=r.opts.find(u=>Rh(e.vmat,r.id,u.val)),a=o!=null?o:r.opts[0];a&&(t[r.id]=a.val)}return t},I8=({product:e,globalClassName:t,openLinksInNewTab:n})=>{var X,se,ee,re,de,Oe,he,Q,oe,C,M,ne;const{logger:r}=At(),o=e.data,a=(X=e.id)!=null?X:o.id,[u,c]=Z.useState(()=>O8(o)),d=N8(o.vmat,u),h=(ee=(se=o.quantity)==null?void 0:se.minQuantity)!=null?ee:1,p=(de=(re=o.quantity)==null?void 0:re.maxQuantity)!=null?de:Number.POSITIVE_INFINITY,E=(he=(Oe=o.quantity)==null?void 0:Oe.increment)!=null?he:1,[T,y]=Z.useState(h),x=u[vl],_=Z.useMemo(()=>C8(o,x),[o,x]),S=((Q=o.vattr)!=null?Q:[]).find(k=>k.id===vl),A=((oe=o.vattr)!=null?oe:[]).filter(k=>k.id!==vl),O=(k,me)=>()=>{c(Se=>ae(B({},Se),{[k]:me}))},R=()=>{r==null||r.info("[ProductDetailCard] Add to cart",{productId:a,selectedVariants:u,quantity:T})},H=!d||T-E<h,W=!d||T+E>p,D=k=>{var Se;const me=u[k.id];return(Se=k.opts.find(Ae=>Ae.val===me))==null?void 0:Se.name},K=()=>y(k=>Math.max(h,k-E)),fe=()=>y(k=>Math.min(p,k+E)),Te=k=>v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant`),children:[v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant-label`),children:[v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-name`),children:k.lbl||k.id}),D(k)&&v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-value`),children:D(k)})]}),v.jsx("div",{className:$(t,`${U}-msg-pdp__chips`),children:k.opts.map(me=>{const Se=Rh(o.vmat,k.id,me.val,u),Ae=u[k.id]===me.val;return v.jsx(Ni,{className:$(`${U}-msg-pdp__chip`,{selected:Ae,unavailable:!Se}),onClick:O(k.id,me.val),children:me.name||me.val},me.val)})})]},k.id),z=k=>v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant`),children:[v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant-label`),children:[v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-name`),children:k.lbl||"Color"}),D(k)&&v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-value`),children:D(k)})]}),v.jsx("div",{className:$(t,`${U}-msg-pdp__swatches`),children:k.opts.map(me=>{const Se=Rh(o.vmat,k.id,me.val,u),Ae=u[k.id]===me.val,Be=k8(o,me.val);return Be?v.jsx(Ni,{title:`Select ${me.name||me.val}`,className:$(`${U}-msg-pdp__swatch`,{selected:Ae,unavailable:!Se}),onClick:O(k.id,me.val),children:v.jsx("img",{className:$(t,`${U}-msg-pdp__swatch-image`),src:Be,alt:me.name||me.val,loading:"lazy"})},me.val):v.jsx(Ni,{className:$(`${U}-msg-pdp__chip`,{selected:Ae,unavailable:!Se}),onClick:O(k.id,me.val),children:me.name||me.val},me.val)})})]});return v.jsx("div",{className:$(t,`${U}-msg-pdp`),children:v.jsxs("div",{className:$(t,`${U}-msg-pdp__card`),children:[v.jsx("div",{className:$(t,`${U}-msg-pdp__gallery`),children:v.jsx(A8,{images:_,altText:o.name,globalClassName:t})}),v.jsxs("div",{className:$(t,`${U}-msg-pdp__content`),children:[o.slugUrl?v.jsx("a",{href:o.slugUrl,target:n?"_blank":"_self",rel:"noopener noreferrer",className:$(t,`${U}-msg-pdp__title-link`),"aria-label":`Go to product page for ${o.name}`,children:o.name}):v.jsx("p",{className:$(t,`${U}-msg-pdp__title`),children:o.name}),v.jsx(vb,{globalClassName:t,className:`${U}-msg-pdp__price`,retailPrice:(C=o.pr)==null?void 0:C.orig,discountPrice:((M=o.pr)==null?void 0:M.cur)||((ne=o.pr)==null?void 0:ne.prom),currencyCode:o.ccy,fontSize:"14px"}),o.dscr&&v.jsx("p",{className:$(t,`${U}-msg-pdp__description`),children:o.dscr}),S&&z(S),A.map(Te),v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant`),children:[v.jsxs("div",{className:$(t,`${U}-msg-pdp__variant-label`),children:[v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-name`),children:"Quantity"}),v.jsx("span",{className:$(t,`${U}-msg-pdp__variant-value`),children:T})]}),v.jsxs("div",{className:$(t,`${U}-msg-pdp__stepper`),children:[v.jsx(ar,{className:`${U}-msg-pdp__stepper-btn`,ariaLabel:"Decrease quantity",icon:v.jsx(DS,{}),disabled:H,onClick:K}),v.jsx("span",{className:$(t,`${U}-msg-pdp__quantity`),children:T}),v.jsx(ar,{className:`${U}-msg-pdp__stepper-btn`,ariaLabel:"Increase quantity",icon:v.jsx(MS,{}),disabled:W,onClick:fe})]})]}),v.jsxs("div",{className:$(t,`${U}-msg-pdp__actions`),children:[v.jsxs(Ni,{className:`${U}-msg-pdp__express-pay`,disabled:!0,children:[v.jsx(S8,{size:"16px"})," Pay"]}),v.jsx(Ni,{className:`${U}-msg-pdp__add-to-cart`,disabled:!d,onClick:R,children:"Add to cart"})]})]})]})})},aT=({content:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{sendMessage:o,loading:a}=Vr();return v.jsx(v.Fragment,{children:e.response.map((u,c)=>{var d,h,p,E,T,y,x,_,S,A,O,R,H,W,D,K;switch(u.type){case"markdown":return v.jsx(Oh,{text:(h=(d=u.data)==null?void 0:d.content)!=null?h:"",globalClassName:t,openLinksInNewTab:n,showIsLoading:!1},`${u.type}-${(p=u.index)!=null?p:c}`);case"product_carousel":return v.jsx(w8,{title:(T=(E=u.data)==null?void 0:E.title)!=null?T:"",products:(x=(y=u.data)==null?void 0:y.products)!=null?x:[],globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(_=u.index)!=null?_:c}`);case"product_tile":return v.jsx(I8,{product:u.data,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(S=u.index)!=null?S:c}`);case"cart":{const fe=(R=(O=(A=u.data)==null?void 0:A.cart)==null?void 0:O.cartSummary)==null?void 0:R.cartDetails;return fe?v.jsx(v8,{cart:fe,productsToHighlight:u.data.products_to_highlight,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(H=u.index)!=null?H:c}`):null}case"suggestions":return v.jsx("div",{style:{marginTop:"0.5rem"},children:v.jsx(iD,{disabled:a,suggestions:(D=(W=u.data)==null?void 0:W.display_text)!=null?D:[],globalClassName:t,isWidgetStandalone:r,onSuggestionClick:o})},`${u.type}-${(K=u.index)!=null?K:c}`);default:return null}})})},R8=({message:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{logger:o}=At(),a=Z.useMemo(()=>{try{const c=JSON.parse(e.content);return Array.isArray(c==null?void 0:c.response)?c:null}catch(c){return null}},[e.content]),u=Z.useMemo(()=>{const c="Oops, I had trouble with your request.";if(typeof e.content!="string")return o==null||o.warn("Message content is not richtext format. Showing fallback text.",e.content),c;const d=e.content.trim();try{const h=JSON.parse(d);if(typeof h=="object"&&h!==null)return o==null||o.debug("Detected JSON object instead of array of responses in message content",e.content),h.text||h.message||c}catch(h){if(d.startsWith("{")||d.startsWith("["))return o==null||o.warn("Failed to parse JSON-like message content. Showing fallback text.",e.content),c}return e.content||c},[o,e.content]);switch(e.role){case"user":return v.jsx("div",{className:$(t,`${U}-message`,r?"standalone":"embedded"),children:v.jsx("div",{className:$(t,`${U}-user-message`,r?"standalone":"embedded"),children:v.jsxs("div",{className:$(t,`${U}-user-message-row`,r?"standalone":"embedded"),children:[v.jsx("span",{className:$(t,`${U}-message-icon user-message-icon`,r?"standalone":"embedded"),children:v.jsx(VS,{})}),v.jsx("p",{className:$(t,`${U}-user-message-text`,r?"standalone":"embedded"),children:e.content})]})})});case"agent":return v.jsx("div",{className:$(t,`${U}-message-group`,r?"standalone":"embedded"),children:v.jsx("div",{className:`${U}-message-group-child`,children:a?v.jsx(aT,{content:a,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r}):v.jsx(Oh,{text:u,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})})});case"system":return v.jsx("div",{className:$(t,`${U}-message`,r?"standalone":"embedded"),children:v.jsx("p",{className:$(t,`${U}-reset-message`),children:e.content})})}},Ph=({isWidgetStandalone:e})=>{const{globalClassName:t,openLinksInNewTab:n}=At(),{messages:r,streamingBlocks:o,isAgentTyping:a,loading:u,progressMessage:c,connectionStatus:d}=Vr(),h=Z.useRef(null),p=r.length>0,E=o.length>0,T=p&&(u||a)&&!E,y=d==="reconnecting"&&!T;return Z.useEffect(()=>{var x;(x=h.current)==null||x.scrollIntoView({behavior:"smooth"})},[r,o]),v.jsxs(v.Fragment,{children:[u&&!p&&v.jsx(lD,{globalClassName:t,isWidgetStandalone:e}),r.map(x=>v.jsx(R8,{message:x,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e},x.id)),E&&v.jsxs("div",{className:$(t,`${U}-message-group`,e?"standalone":"embedded"),children:[v.jsx(aT,{content:{response:o},globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e}),(u||a)&&v.jsx(xh,{globalClassName:t,isWidgetStandalone:e})]}),T&&v.jsx(xh,{globalClassName:t,isWidgetStandalone:e,loadingText:c}),y&&v.jsx(xh,{globalClassName:t,isWidgetStandalone:e,loadingText:"Reconnecting..."}),v.jsx("div",{ref:h})]})},uT=()=>{const{globalClassName:e,themeVariables:t}=At(),{isAgentTyping:n,sendMessage:r,resetConversation:o}=Vr(),a=n;return v.jsxs("div",{className:$(e,`${U}-container`,`${U}-embedded-chat`),style:t,children:[v.jsx("div",{className:$(e,`${U}-message-container`,"embedded"),children:v.jsx(Ph,{isWidgetStandalone:!1})}),v.jsx(Sf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:u=>r(u)}),v.jsx("div",{className:$(`${U}-embedded-chat-menu`),children:v.jsxs(gL,{componentType:"chat",children:[v.jsx(Sb,{componentType:"chat"}),v.jsx(DE,{componentType:"chat",onClearChat:o})]})})]})},lT=e=>{var d;const{children:t,disabled:n}=e,[r,o]=Z.useState((d=e.container)==null?void 0:d.current),a=Z.useSyncExternalStore(L8,()=>!1,()=>!0),{getRootNode:u}=bl();if(Z.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),a||n)return v.jsx(v.Fragment,{children:t});const c=r!=null?r:P8(u);return v.jsx(v.Fragment,{children:Z.Children.map(t,h=>Is.createPortal(h,c))})},P8=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Bi(n)?n:dr(t).body},L8=()=>()=>{},cT=()=>{const{globalClassName:e,themeVariables:t}=At(),{mode:n,status:r,dialogPosition:o,isDialogFullHeight:a,dialogWidth:u}=ki(),{loading:c,isAgentTyping:d,sendMessage:h,resetConversation:p}=Vr(),{isOpen:E}=r||{},T=!!r.isOpen,y=n==="standalone",x=d||c,_=()=>{Ci(!1)};return v.jsx(yb,{lazyMount:!0,unmountOnExit:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:T,children:v.jsx(lT,{children:v.jsx(Eh,{className:$(e,`${U}-container`,`${U}-dialog`,o,a&&"full-height"),style:B(B({},t),u&&{width:u}),children:v.jsxs(mh,{className:$(e,`${U}-dialog-content`,{standalone:y,embedded:!y}),children:[v.jsx(wb,{componentType:"dialog",onClearChat:p,onClose:_}),v.jsx(gh,{className:$(e,`${U}-message-container`,{standalone:y,embedded:!y}),children:v.jsx(Ph,{isWidgetStandalone:y,isOpen:E})}),v.jsx(Sf,{componentType:"dialog",isLoading:x,onSubmit:S=>h(S)})]})})})})},dT=()=>{const{globalClassName:e,themeVariables:t}=At(),{mode:n,status:r,isModalFullscreen:o}=ki(),{isAgentTyping:a,sendMessage:u,resetConversation:c}=Vr(),{isOpen:d}=r||{},h=!!r.isOpen,p=n==="standalone",E=a,T=({open:x})=>{Ci(x)},y=()=>{Ci(!1)};return h?v.jsx(yb,{lazyMount:!0,unmountOnExit:!0,open:h,onOpenChange:T,children:v.jsx(lT,{children:v.jsxs("div",{className:$(e,`${U}-modal-container`),style:t,children:[v.jsx(hb,{className:$(e,`${U}-modal-backdrop`)}),v.jsx(Eh,{className:$(e,`${U}-container`,`${U}-modal`,{fullscreen:o,standalone:p,embedded:!p}),children:v.jsxs(mh,{className:$(e,`${U}-modal-content`,{standalone:p,embedded:!p}),children:[v.jsx(wb,{componentType:"modal",onClearChat:c,onClose:y}),v.jsx(gh,{className:$(e,`${U}-message-container`,{standalone:p,embedded:!p}),children:v.jsx(Ph,{isWidgetStandalone:p,isOpen:d})}),v.jsx(Sf,{componentType:"modal",isLoading:E,onSubmit:x=>u(x)})]})})]})})}):null},D8=()=>{const e=ki(),{status:{type:t,isMinimized:n}}=e||{status:{}};return n?v.jsx(HS,{}):t==="dialog"?v.jsx(cT,{}):t==="modal"?v.jsx(dT,{}):v.jsx(uT,{})},Lh=e=>v.jsx(R0,ae(B({},e),{children:v.jsx(D8,{})}));var Sl={},fT;function M8(){if(fT)return Sl;fT=1;var e=F0();return Sl.createRoot=e.createRoot,Sl.hydrateRoot=e.hydrateRoot,Sl}var hT=M8();const F8=r=>{var o=r,{elementId:e,timeout:t=5e3}=o,n=sn(o,["elementId","timeout"]);let a;const u=(d,h)=>{var p;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),(p=hT.createRoot(T))==null||p.render(v.jsx(Lh,ae(B({},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},B8=r=>{var o=r,{timeout:e,elementId:t}=o,n=sn(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"),F8(B({elementId:t,timeout:e},n));return}hT.createRoot(a).render(v.jsx(Lh,ae(B({},n),{mode:"messaging"})))},U8={components:{setEntryType:O0,toggleWidgetOpen:Ci,toggleWidgetMinimized:vu,toggleModalFullscreen:xd,setWidgetType:Su,setWidgetDialogPosition:wd}};Re.AgentForceWidget=Lh,Re.AgentforceWidgetProvider=R0,Re.MessagingDialog=cT,Re.MessagingEmbed=uT,Re.MessagingModal=dT,Re.MessagingProvider=N0,Re.eventHandlers=U8,Re.injectMessagingWidget=B8,Re.useMessaging=Vr,Object.defineProperty(Re,Symbol.toStringTag,{value:"Module"})}));