@cimulate/copilot-widget 1.9.6 → 1.9.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cimulate-copilot-widget.d.ts +3 -1
- package/dist/cimulate-copilot-widget.es.js +5981 -5960
- package/dist/cimulate-copilot-widget.umd.js +25 -25
- package/dist/copilot.es.js +5231 -5210
- package/dist/copilot.umd.js +25 -25
- package/dist/messaging.d.ts +2 -0
- package/dist/messaging.es.js +1048 -1039
- package/dist/messaging.umd.js +12 -12
- package/package.json +2 -2
package/dist/messaging.umd.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
(function(Ie,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Ie=typeof globalThis!="undefined"?globalThis:Ie||self,Fe(Ie.CimulateMessaging={}))})(this,(function(Ie){"use strict";var iF=Object.defineProperty,oF=Object.defineProperties;var sF=Object.getOwnPropertyDescriptors;var Pc=Object.getOwnPropertySymbols;var Mx=Object.prototype.hasOwnProperty,Fx=Object.prototype.propertyIsEnumerable;var ys=(Ie,Fe)=>(Fe=Symbol[Ie])?Fe:Symbol.for("Symbol."+Ie),aF=Ie=>{throw TypeError(Ie)},Za=Math.pow,im=(Ie,Fe,We)=>Fe in Ie?iF(Ie,Fe,{enumerable:!0,configurable:!0,writable:!0,value:We}):Ie[Fe]=We,B=(Ie,Fe)=>{for(var We in Fe||(Fe={}))Mx.call(Fe,We)&&im(Ie,We,Fe[We]);if(Pc)for(var We of Pc(Fe))Fx.call(Fe,We)&&im(Ie,We,Fe[We]);return Ie},se=(Ie,Fe)=>oF(Ie,sF(Fe));var sn=(Ie,Fe)=>{var We={};for(var rt in Ie)Mx.call(Ie,rt)&&Fe.indexOf(rt)<0&&(We[rt]=Ie[rt]);if(Ie!=null&&Pc)for(var rt of Pc(Ie))Fe.indexOf(rt)<0&&Fx.call(Ie,rt)&&(We[rt]=Ie[rt]);return We};var Ze=(Ie,Fe,We)=>im(Ie,typeof Fe!="symbol"?Fe+"":Fe,We);var $e=(Ie,Fe,We)=>new Promise((rt,Et)=>{var dt=Tt=>{try{Pt(We.next(Tt))}catch(an){Et(an)}},Re=Tt=>{try{Pt(We.throw(Tt))}catch(an){Et(an)}},Pt=Tt=>Tt.done?rt(Tt.value):Promise.resolve(Tt.value).then(dt,Re);Pt((We=We.apply(Ie,Fe)).next())}),so=function(Ie,Fe){this[0]=Ie,this[1]=Fe},om=(Ie,Fe,We)=>{var rt=(Re,Pt,Tt,an)=>{try{var ao=We[Re](Pt),Ts=(Pt=ao.value)instanceof so,Lc=ao.done;Promise.resolve(Ts?Pt[0]:Pt).then($n=>Ts?rt(Re==="return"?Re:"next",Pt[1]?{done:$n.done,value:$n.value}:$n,Tt,an):Tt({value:$n,done:Lc})).catch($n=>rt("throw",$n,Tt,an))}catch($n){an($n)}},Et=Re=>dt[Re]=Pt=>new Promise((Tt,an)=>rt(Re,Pt,Tt,an)),dt={};return We=We.apply(Ie,Fe),dt[ys("asyncIterator")]=()=>dt,Et("next"),Et("throw"),Et("return"),dt},sm=Ie=>{var Fe=Ie[ys("asyncIterator")],We=!1,rt,Et={};return Fe==null?(Fe=Ie[ys("iterator")](),rt=dt=>Et[dt]=Re=>Fe[dt](Re)):(Fe=Fe.call(Ie),rt=dt=>Et[dt]=Re=>{if(We){if(We=!1,dt==="throw")throw Re;return Re}return We=!0,{done:!1,value:new so(new Promise(Pt=>{var Tt=Fe[dt](Re);Tt instanceof Object||aF("Object expected"),Pt(Tt)}),1)}}),Et[ys("iterator")]=()=>Et,rt("next"),"throw"in Fe?rt("throw"):Et.throw=dt=>{throw dt},"return"in Fe&&rt("return"),Et},Bx=(Ie,Fe,We)=>(Fe=Ie[ys("asyncIterator")])?Fe.call(Ie):(Ie=Ie[ys("iterator")](),Fe={},We=(rt,Et)=>(Et=Ie[rt])&&(Fe[rt]=dt=>new Promise((Re,Pt,Tt)=>(dt=Et.call(Ie,dt),Tt=dt.done,Promise.resolve(dt.value).then(an=>Re({value:an,done:Tt}),Pt)))),We("next"),We("return"),Fe);var Fe=document.createElement("style");Fe.textContent=`.cim-widget-icon-button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:32px;background-color:transparent;border:1px solid transparent;border-radius:var(--cim-widget-border-radius);padding:0;cursor:pointer;color:#333;font-size:18px;svg{padding:6px;height:100%;width:100%}&:hover{background-color:#f0f0f0}&:disabled,&[disabled]{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-icon-image{object-fit:contain;padding:6px;width:.875em;height:.875em}.cim-widget-minimized-container{--base-color: var(--cim-widget-primary-color, #3182ce);--base-color-darken: color-mix(in srgb, var(--base-color), black 20%);position:fixed;bottom:1rem;right:1rem;display:flex;align-items:center;justify-content:center;.cim-widget-minimized-button{height:3rem;width:3rem;border-radius:2rem;padding:.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;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;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color, #d1d5db);background-color:var(--cim-widget-background-color, #ffffff);color:var(--cim-widget-font-color, #3f3f46);cursor:pointer;box-shadow:0 1px 3px #0000001a;transition:background-color .15s ease,box-shadow .15s ease}.cim-widget-carousel__prev-trigger:hover,.cim-widget-carousel__next-trigger:hover{background-color:#f9fafb;box-shadow:0 2px 6px #0000001f}.cim-widget-carousel__prev-trigger:disabled,.cim-widget-carousel__next-trigger:disabled{opacity:.4;cursor:not-allowed}.cim-widget-carousel__indicator-group{display:flex;justify-content:center;gap:6px;padding-top:12px}.cim-widget-carousel__indicator{width:8px;height:8px;border-radius:50%;border:none;background-color:var(--cim-widget-border-color, #d1d5db);cursor:pointer;padding:0;transition:background-color .2s ease,transform .2s ease}.cim-widget-carousel__indicator[data-current]{background-color:var(--cim-widget-font-color, #1a202c);transform:scale(1.25)}.cim-widget-carousel__indicator:hover:not([data-current]){background-color:var(--cim-widget-font-color, #1a202c);opacity:.5}.cim-widget-close-button{display:flex;align-items:center;justify-content:center;padding:.5rem;border-radius:var(--cim-widget-border-radius);border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-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-toggle-modal-button.cim-dialog-component{display:none}@media(min-width:576px){.cim-widget-toggle-modal-button.cim-dialog-component{display:inline-flex}}.cim-widget-blinking-cursor{display:inline-flex;margin-left:2px;line-height:0;animation:cursor-blink 1.5s steps(2) infinite}@keyframes cursor-blink{0%{opacity:0}}.cim-widget-ul{list-style-type:disc;padding-left:1.5rem}.cim-widget-ol{list-style-type:decimal;padding-left:1.5rem}.cim-widget-table-container{margin-top:1rem;margin-bottom:1rem;margin-right:.5rem;overflow-x:auto}.cim-widget-table{border-radius:.5rem;border-width:1px;border-style:solid;border-color:var(--cim-widget-border-color);border-collapse:collapse;width:100%}.cim-widget-thead{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent);border-bottom-width:2px;border-color:var(--cim-widget-border-color)}.cim-widget-tbody{border-width:0px;box-sizing:border-box;background-color:#ffffff90;overflow-wrap:break-word}.cim-widget-tr{border-style:solid;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-th{padding:.5rem 1rem;text-align:left;font-weight:700;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-td{padding:.5rem 1rem;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-message-container pre{margin:0}.cim-widget-connecting-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-size: 8px;--cim-loader-speed: 1.4s;--cim-loader-gap: .5rem;display:flex;align-items:center;gap:var(--cim-loader-gap)}.cim-widget-connecting-indicator.embedded{padding:12px 4px}.cim-widget-connecting-indicator.standalone{padding:12px 1rem}.cim-widget-connecting-pulse-wrapper{position:relative;width:calc(var(--cim-loader-size) * 2);height:calc(var(--cim-loader-size) * 2);display:flex;align-items:center;justify-content:center}.cim-widget-connecting-pulse{width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;background-color:var(--cim-loader-color);animation:cim-widget-pulse var(--cim-loader-speed) ease-in-out infinite}.cim-widget-connecting-ring{position:absolute;width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;border:1.5px solid var(--cim-loader-color);animation:cim-widget-ring-expand var(--cim-loader-speed) ease-out infinite}.cim-widget-connecting-text{font-size:12px;color:var(--cim-widget-font-color);font-family:var(--cim-widget-font-family, inherit);opacity:0;transform:translateY(4px);transition:opacity .4s ease,transform .4s ease}.cim-widget-connecting-text--visible{opacity:1;transform:translateY(0)}@keyframes cim-widget-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.6);opacity:.4}}@keyframes cim-widget-ring-expand{0%{transform:scale(1);opacity:.6}to{transform:scale(2.8);opacity:0}}@media(prefers-reduced-motion:reduce){.cim-widget-connecting-pulse,.cim-widget-connecting-ring{animation:none!important}.cim-widget-connecting-pulse{opacity:.6}.cim-widget-connecting-text{animation:none!important;transition:none!important}}.cim-widget-processing-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-speed: 1.8s;display:flex;flex-direction:column;gap:8px}.cim-widget-processing-indicator.embedded{max-width:80%;min-height:2.5rem;padding:.5rem 0}.cim-widget-processing-indicator.standalone{padding:0 1rem;min-height:3rem}.cim-widget-processing-text{font-size:.875rem;font-style:italic;color:color-mix(in srgb,var(--cim-widget-secondary-color) 70%,var(--cim-loader-color));opacity:.75}.cim-widget-processing-shimmer-bar{height:10px;border-radius:4px;background:linear-gradient(90deg,var(--cim-widget-border-color) 25%,color-mix(in srgb,var(--cim-loader-color) 15%,var(--cim-widget-background-color)) 50%,var(--cim-widget-border-color) 75%);background-size:200% 100%;animation:cim-widget-shimmer var(--cim-loader-speed) ease-in-out infinite}.cim-widget-processing-shimmer-bar:nth-child(2){width:75%;animation-delay:.15s}.cim-widget-processing-shimmer-bar:nth-child(3){width:50%;animation-delay:.3s}@keyframes cim-widget-shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}@media(prefers-reduced-motion:reduce){.cim-widget-processing-shimmer-bar{animation:none!important;background:var(--cim-widget-border-color)!important}}.cim-widget-msg-product-card{display:flex;flex-direction:column;width:180px;min-width:180px;height:100%;background-color:var(--cim-widget-background-color, #ffffff);border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);overflow:hidden;transition:box-shadow .2s ease;&.card-full-width{width:100%;min-width:100%}}.cim-widget-msg-product-card:hover{box-shadow:0 2px 8px #0000001f}.cim-widget-msg-product-card__image-wrapper{position:relative;width:100%;height:100%;aspect-ratio:1 / 1;overflow:hidden}.cim-widget-msg-product-card__image{width:100%;height:100%;object-fit:contain;display:block}.cim-widget-msg-product-card__content{display:flex;flex-direction:column;justify-content:space-between;gap:1rem;padding:12px;height:40%}.cim-widget-msg-product-card__title,.cim-widget-msg-product-card__title-link{font-family:var(--cim-widget-font-family, sans-serif);font-weight:700;font-size:1rem;line-height:1.3;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46);margin:0;display:-webkit-box;line-clamp:2;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.cim-widget-msg-product-card__title-link{text-decoration:none}.cim-widget-msg-product-card__title-link:hover{text-decoration:underline}.cim-widget-msg-product-card__price-row{display:flex;align-items:center;justify-content:space-between;gap:8px}.cim-widget-msg-product-card__prices{display:flex;align-items:baseline;gap:6px;flex-wrap:wrap}.cim-widget-msg-product-card__price{font-family:var(--cim-widget-font-family, sans-serif);font-weight:700;font-size:14px;line-height:1.2;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-product-card__compare-price{font-family:var(--cim-widget-font-family, sans-serif);font-weight:400;font-size:13px;line-height:1.2;color:var(--cim-widget-font-color, #3f3f46);opacity:.6;text-decoration:line-through}.cim-widget-msg-product-card__add-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;min-width:28px;border:none;border-radius:4px;background-color:var(--cim-widget-primary-color, #141415);color:#fff;cursor:pointer;transition:opacity .15s ease}.cim-widget-msg-product-card__add-btn:hover{opacity:.85}.cim-widget-msg-product-card__add-btn svg{width:14px;height:14px}.cim-widget-product-carousel-title{font-weight:800}.cim-widget-message-group,.cim-widget-message{display:flex;flex-direction:column}.cim-widget-message-group{gap:.5rem;padding:.5rem 1rem;margin-bottom:1rem;border-radius:var(--cim-widget-border-radius);&.standalone{padding:0 1rem}.cim-widget-message-group-child{max-width:100%;margin-bottom:.25rem}}.cim-widget-message-group.embedded{max-width:80%;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent)}.cim-widget-message{margin-bottom:1rem}.cim-widget-message.standalone{border-radius:0;background-color:transparent;padding:0 1rem}.cim-widget-message.embedded{margin-bottom:1rem}.message{border-radius:.5rem}.widget-message{display:flex;align-self:flex-start}.user-message{display:flex;align-self:flex-end;padding:1rem}.cim-widget-reset-message{font-size:.75rem;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 75%,white)}.cim-widget-start-search-message{font-size:.875rem;font-weight:700;color:var(--cim-widget-font-color)}.cim-widget-user-message{display:flex;flex-direction:column;gap:.5rem;.cim-widget-user-message-row{display:inline-flex;align-items:center;gap:.5rem}}.cim-widget-user-message.embedded{display:inline-flex;align-self:flex-end;padding:.5rem 1rem;border-radius:var(--cim-widget-border-radius);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:50%}.cim-widget-user-message.standalone{margin:.5rem 0}.cim-widget-user-message-image{object-fit:contain;border-radius:8px;&.embedded{max-height:2.5rem}&.standalone{max-height:3.5rem}}.cim-widget-user-message-text{font-weight:700}.cim-widget-user-message-text.standalone{font-size:1.125rem;margin:0}.cim-widget-user-message-text.embedded{margin:0}.cim-widget-message-icon.user-message-icon.embedded{color:var(--cim-widget-primary-color)}.cim-widget-message-group-child{display:flex;flex-direction:column;gap:.25rem}.cim-widget-embedded-chat{position:relative;width:100%;height:100%;margin:0 auto;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color)}.cim-widget-embedded-chat>.cim-widget-message-container{padding-top:2rem;padding-left:1rem;padding-right:1rem}.cim-widget-embedded-chat-menu{position:absolute;top:.25rem;right:.25rem}.cim-widget-overflow-menu-button-trigger.cim-chat-component{border:1px solid var(--cim-widget-border-color);border-radius:var(--cim-widget-border-radius);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;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;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;color:var(--cim-widget-primary-color);white-space:normal;word-break:break-word;text-align:left;cursor:pointer}.cim-widget-suggestion-button.embedded:hover{background-color:#fff;color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-container.standalone{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:.5rem;padding:.5rem 0}@media(max-width:768px){.cim-widget-suggestion-container.standalone{grid-template-columns:repeat(1,1fr)}}.cim-widget-suggestion-button.standalone{display:inline-flex;align-items:center;padding:.5rem 1rem;border:1px solid var(--cim-widget-primary-color);border-radius:var(--cim-widget-border-radius);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent);font-weight:700;color:var(--cim-widget-primary-color);text-align:left;white-space:normal;word-break:break-word}.cim-widget-suggestion-button.standalone:hover{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 15%,transparent);color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-button:disabled{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a;cursor:not-allowed}.cim-widget-suggestion-button:disabled:hover{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a}
|
|
2
|
-
/*$vite$:1*/`,document.head.appendChild(Fe);function We(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var rt={exports:{}},Et={},dt={exports:{}},Re={};var Pt;function Tt(){if(Pt)return Re;Pt=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 b(D){return D===null||typeof D!="object"?null:(D=E&&D[E]||D["@@iterator"],typeof D=="function"?D:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,_={};function S(D,Z,k){this.props=D,this.context=Z,this.refs=_,this.updater=k||T}S.prototype.isReactComponent={},S.prototype.setState=function(D,Z){if(typeof D!="object"&&typeof D!="function"&&D!=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,D,Z,"setState")},S.prototype.forceUpdate=function(D){this.updater.enqueueForceUpdate(this,D,"forceUpdate")};function A(){}A.prototype=S.prototype;function O(D,Z,k){this.props=D,this.context=Z,this.refs=_,this.updater=k||T}var I=O.prototype=new A;I.constructor=O,x(I,S.prototype),I.isPureReactComponent=!0;var H=Array.isArray,Y=Object.prototype.hasOwnProperty,M={current:null},G={key:!0,ref:!0,__self:!0,__source:!0};function pe(D,Z,k){var xe,Pe={},Oe=null,He=null;if(Z!=null)for(xe in Z.ref!==void 0&&(He=Z.ref),Z.key!==void 0&&(Oe=""+Z.key),Z)Y.call(Z,xe)&&!G.hasOwnProperty(xe)&&(Pe[xe]=Z[xe]);var Se=arguments.length-2;if(Se===1)Pe.children=k;else if(1<Se){for(var qe=Array(Se),ut=0;ut<Se;ut++)qe[ut]=arguments[ut+2];Pe.children=qe}if(D&&D.defaultProps)for(xe in Se=D.defaultProps,Se)Pe[xe]===void 0&&(Pe[xe]=Se[xe]);return{$$typeof:e,type:D,key:Oe,ref:He,props:Pe,_owner:M.current}}function re(D,Z){return{$$typeof:e,type:D.type,key:Z,ref:D.ref,props:D.props,_owner:D._owner}}function z(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function W(D){var Z={"=":"=0",":":"=2"};return"$"+D.replace(/[=:]/g,function(k){return Z[k]})}var te=/\/+/g;function oe(D,Z){return typeof D=="object"&&D!==null&&D.key!=null?W(""+D.key):Z.toString(36)}function de(D,Z,k,xe,Pe){var Oe=typeof D;(Oe==="undefined"||Oe==="boolean")&&(D=null);var He=!1;if(D===null)He=!0;else switch(Oe){case"string":case"number":He=!0;break;case"object":switch(D.$$typeof){case e:case t:He=!0}}if(He)return He=D,Pe=Pe(He),D=xe===""?"."+oe(He,0):xe,H(Pe)?(k="",D!=null&&(k=D.replace(te,"$&/")+"/"),de(Pe,Z,k,"",function(ut){return ut})):Pe!=null&&(z(Pe)&&(Pe=re(Pe,k+(!Pe.key||He&&He.key===Pe.key?"":(""+Pe.key).replace(te,"$&/")+"/")+D)),Z.push(Pe)),1;if(He=0,xe=xe===""?".":xe+":",H(D))for(var Se=0;Se<D.length;Se++){Oe=D[Se];var qe=xe+oe(Oe,Se);He+=de(Oe,Z,k,qe,Pe)}else if(qe=b(D),typeof qe=="function")for(D=qe.call(D),Se=0;!(Oe=D.next()).done;)Oe=Oe.value,qe=xe+oe(Oe,Se++),He+=de(Oe,Z,k,qe,Pe);else if(Oe==="object")throw Z=String(D),Error("Objects are not valid as a React child (found: "+(Z==="[object Object]"?"object with keys {"+Object.keys(D).join(", ")+"}":Z)+"). If you meant to render a collection of children, use an array instead.");return He}function be(D,Z,k){if(D==null)return D;var xe=[],Pe=0;return de(D,xe,"","",function(Oe){return Z.call(k,Oe,Pe++)}),xe}function Ne(D){if(D._status===-1){var Z=D._result;Z=Z(),Z.then(function(k){(D._status===0||D._status===-1)&&(D._status=1,D._result=k)},function(k){(D._status===0||D._status===-1)&&(D._status=2,D._result=k)}),D._status===-1&&(D._status=0,D._result=Z)}if(D._status===1)return D._result.default;throw D._result}var me={current:null},Q={transition:null},ie={ReactCurrentDispatcher:me,ReactCurrentBatchConfig:Q,ReactCurrentOwner:M};function v(){throw Error("act(...) is not supported in production builds of React.")}return Re.Children={map:be,forEach:function(D,Z,k){be(D,function(){Z.apply(this,arguments)},k)},count:function(D){var Z=0;return be(D,function(){Z++}),Z},toArray:function(D){return be(D,function(Z){return Z})||[]},only:function(D){if(!z(D))throw Error("React.Children.only expected to receive a single React element child.");return D}},Re.Component=S,Re.Fragment=n,Re.Profiler=o,Re.PureComponent=O,Re.StrictMode=r,Re.Suspense=d,Re.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ie,Re.act=v,Re.cloneElement=function(D,Z,k){if(D==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+D+".");var xe=x({},D.props),Pe=D.key,Oe=D.ref,He=D._owner;if(Z!=null){if(Z.ref!==void 0&&(Oe=Z.ref,He=M.current),Z.key!==void 0&&(Pe=""+Z.key),D.type&&D.type.defaultProps)var Se=D.type.defaultProps;for(qe in Z)Y.call(Z,qe)&&!G.hasOwnProperty(qe)&&(xe[qe]=Z[qe]===void 0&&Se!==void 0?Se[qe]:Z[qe])}var qe=arguments.length-2;if(qe===1)xe.children=k;else if(1<qe){Se=Array(qe);for(var ut=0;ut<qe;ut++)Se[ut]=arguments[ut+2];xe.children=Se}return{$$typeof:e,type:D.type,key:Pe,ref:Oe,props:xe,_owner:He}},Re.createContext=function(D){return D={$$typeof:u,_currentValue:D,_currentValue2:D,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},D.Provider={$$typeof:a,_context:D},D.Consumer=D},Re.createElement=pe,Re.createFactory=function(D){var Z=pe.bind(null,D);return Z.type=D,Z},Re.createRef=function(){return{current:null}},Re.forwardRef=function(D){return{$$typeof:c,render:D}},Re.isValidElement=z,Re.lazy=function(D){return{$$typeof:p,_payload:{_status:-1,_result:D},_init:Ne}},Re.memo=function(D,Z){return{$$typeof:h,type:D,compare:Z===void 0?null:Z}},Re.startTransition=function(D){var Z=Q.transition;Q.transition={};try{D()}finally{Q.transition=Z}},Re.unstable_act=v,Re.useCallback=function(D,Z){return me.current.useCallback(D,Z)},Re.useContext=function(D){return me.current.useContext(D)},Re.useDebugValue=function(){},Re.useDeferredValue=function(D){return me.current.useDeferredValue(D)},Re.useEffect=function(D,Z){return me.current.useEffect(D,Z)},Re.useId=function(){return me.current.useId()},Re.useImperativeHandle=function(D,Z,k){return me.current.useImperativeHandle(D,Z,k)},Re.useInsertionEffect=function(D,Z){return me.current.useInsertionEffect(D,Z)},Re.useLayoutEffect=function(D,Z){return me.current.useLayoutEffect(D,Z)},Re.useMemo=function(D,Z){return me.current.useMemo(D,Z)},Re.useReducer=function(D,Z,k){return me.current.useReducer(D,Z,k)},Re.useRef=function(D){return me.current.useRef(D)},Re.useState=function(D){return me.current.useState(D)},Re.useSyncExternalStore=function(D,Z,k){return me.current.useSyncExternalStore(D,Z,k)},Re.useTransition=function(){return me.current.useTransition()},Re.version="18.3.1",Re}var an;function ao(){return an||(an=1,dt.exports=Tt()),dt.exports}var Ts;function Lc(){if(Ts)return Et;Ts=1;var e=ao(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function u(c,d,h){var p,E={},b=null,T=null;h!==void 0&&(b=""+h),d.key!==void 0&&(b=""+d.key),d.ref!==void 0&&(T=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:b,ref:T,props:E,_owner:o.current}}return Et.Fragment=n,Et.jsx=u,Et.jsxs=u,Et}var $n;function jx(){return $n||($n=1,rt.exports=Lc()),rt.exports}var P=jx();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 eu=Object.create(null);Object.keys(or).forEach(e=>{eu[or[e]]=e});const Dc={type:"error",data:"parser error"},am=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",um=typeof ArrayBuffer=="function",lm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Mc=({type:e,data:t},n,r)=>am&&t instanceof Blob?n?r(t):cm(t,r):um&&(t instanceof ArrayBuffer||lm(t))?n?r(t):cm(new Blob([t]),r):r(or[e]+(t||"")),cm=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function dm(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Fc;function $x(e,t){if(am&&e.data instanceof Blob)return e.data.arrayBuffer().then(dm).then(t);if(um&&(e.data instanceof ArrayBuffer||lm(e.data)))return t(dm(e.data));Mc(e,!1,n=>{Fc||(Fc=new TextEncoder),t(Fc.encode(n))})}const fm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bs=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<fm.length;e++)bs[fm.charCodeAt(e)]=e;const Vx=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=bs[e.charCodeAt(r)],u=bs[e.charCodeAt(r+1)],c=bs[e.charCodeAt(r+2)],d=bs[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},qx=typeof ArrayBuffer=="function",Bc=(e,t)=>{if(typeof e!="string")return{type:"message",data:hm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:Yx(e.substring(1),t)}:eu[n]?e.length>1?{type:eu[n],data:e.substring(1)}:{type:eu[n]}:Dc},Yx=(e,t)=>{if(qx){const n=Vx(e);return hm(n,t)}else return{base64:!0,data:e}},hm=(e,t)=>t==="blob"?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,pm="",Wx=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((a,u)=>{Mc(a,!1,c=>{r[u]=c,++o===n&&t(r.join(pm))})})},Gx=(e,t)=>{const n=e.split(pm),r=[];for(let o=0;o<n.length;o++){const a=Bc(n[o],t);if(r.push(a),a.type==="error")break}return r};function Kx(){return new TransformStream({transform(e,t){$x(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 Uc;function tu(e){return e.reduce((t,n)=>t+n.length,0)}function nu(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 Qx(e,t){Uc||(Uc=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(tu(n)<1)break;const d=nu(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(tu(n)<2)break;const d=nu(n,2);o=new DataView(d.buffer,d.byteOffset,d.length).getUint16(0),r=3}else if(r===2){if(tu(n)<8)break;const d=nu(n,8),h=new DataView(d.buffer,d.byteOffset,d.length),p=h.getUint32(0);if(p>Math.pow(2,21)-1){c.enqueue(Dc);break}o=p*Math.pow(2,32)+h.getUint32(4),r=3}else{if(tu(n)<o)break;const d=nu(n,o);c.enqueue(Bc(a?d:Uc.decode(d),t)),r=0}if(o===0||o>e){c.enqueue(Dc);break}}}})}const mm=4;function St(e){if(e)return Xx(e)}function Xx(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 ru=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")(),Jx="arraybuffer";function uF(){}function gm(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const Zx=On.setTimeout,ew=On.clearTimeout;function iu(e,t){t.useNativeTimers?(e.setTimeoutFn=Zx.bind(On),e.clearTimeoutFn=ew.bind(On)):(e.setTimeoutFn=On.setTimeout.bind(On),e.clearTimeoutFn=On.clearTimeout.bind(On))}const tw=1.33;function nw(e){return typeof e=="string"?rw(e):Math.ceil((e.byteLength||e.size)*tw)}function rw(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 Em(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function iw(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function ow(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 sw extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Hc extends St{constructor(t){super(),this.writable=!1,iu(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 sw(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=Bc(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=iw(t);return n.length?"?"+n:""}}class aw extends Hc{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)};Gx(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,Wx(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]=Em()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let ym=!1;try{ym=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const uw=ym;function lw(){}class cw extends aw{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,iu(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=gm(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=lw,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",Tm);else if(typeof addEventListener=="function"){const e="onpagehide"in On?"pagehide":"unload";addEventListener(e,Tm,!1)}}function Tm(){for(let e in sr.requests)sr.requests.hasOwnProperty(e)&&sr.requests[e].abort()}const dw=(function(){const e=bm({xdomain:!1});return e&&e.responseType!==null})();class fw extends cw{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=dw&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new sr(bm,this.uri(),t)}}function bm(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||uw))return new XMLHttpRequest}catch(n){}if(!t)try{return new On[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const xm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class hw extends Hc{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=xm?{}:gm(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;Mc(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch(u){}o&&ru(()=>{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]=Em()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const zc=On.WebSocket||On.MozWebSocket;class pw extends hw{createSocket(t,n,r){return xm?new zc(t,n,r):n?new zc(t,n):new zc(t)}doWrite(t,n){this.ws.send(n)}}class mw extends Hc{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=Qx(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=Kx();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&&ru(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const gw={websocket:pw,webtransport:mw,polling:fw},Ew=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,yw=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function jc(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=Ew.exec(e||""),a={},u=14;for(;u--;)a[yw[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=Tw(a,a.path),a.queryKey=bw(a,a.query),a}function Tw(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 bw(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,a){o&&(n[o]=a)}),n}const $c=typeof addEventListener=="function"&&typeof removeEventListener=="function",ou=[];$c&&addEventListener("offline",()=>{ou.forEach(e=>e())},!1);class Hr extends St{constructor(t,n){if(super(),this.binaryType=Jx,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=jc(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=jc(n.host).host);iu(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=ow(this.opts.query)),$c&&(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"})},ou.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=mm,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&Hr.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",Hr.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const o=this.writeBuffer[r].data;if(o&&(n+=nw(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,ru(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const a={type:t,data:n,options:r};this.emitReserved("packetCreate",a),this.writeBuffer.push(a),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(Hr.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),$c&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=ou.indexOf(this._offlineEventListener);r!==-1&&ou.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Hr.protocol=mm;class xw extends Hr{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;Hr.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",E=>{if(!r)if(E.type==="pong"&&E.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Hr.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(p(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const b=new Error("probe error");b.transport=n.name,this.emitReserved("upgradeError",b)}}))};function a(){r||(r=!0,p(),n.close(),n=null)}const u=E=>{const b=new Error("probe error: "+E);b.transport=n.name,a(),this.emitReserved("upgradeError",b)};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 ww=class extends xw{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(o=>gw[o]).filter(o=>!!o)),super(t,r)}};function _w(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=jc(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 Sw=typeof ArrayBuffer=="function",vw=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,wm=Object.prototype.toString,Aw=typeof Blob=="function"||typeof Blob!="undefined"&&wm.call(Blob)==="[object BlobConstructor]",Cw=typeof File=="function"||typeof File!="undefined"&&wm.call(File)==="[object FileConstructor]";function Vc(e){return Sw&&(e instanceof ArrayBuffer||vw(e))||Aw&&e instanceof Blob||Cw&&e instanceof File}function su(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(su(e[n]))return!0;return!1}if(Vc(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return su(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&su(e[n]))return!0;return!1}function kw(e){const t=[],n=e.data,r=e;return r.data=qc(n,t),r.attachments=t.length,{packet:r,buffers:t}}function qc(e,t){if(!e)return e;if(Vc(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]=qc(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]=qc(e[r],t));return n}return e}function Nw(e,t){return e.data=Yc(e.data,t),delete e.attachments,e}function Yc(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]=Yc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Yc(e[n],t));return e}const Ow=["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 Iw{constructor(t){this.replacer=t}encode(t){return(t.type===Ke.EVENT||t.type===Ke.ACK)&&su(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=kw(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class Wc 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 Rw(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Vc(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(!Pw(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(Wc.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 _m(n);case Ke.DISCONNECT:return n===void 0;case Ke.CONNECT_ERROR:return typeof n=="string"||_m(n);case Ke.EVENT:case Ke.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&Ow.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 Rw{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=Nw(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Pw=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e};function _m(e){return Object.prototype.toString.call(e)==="[object Object]"}const Lw=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Wc,Encoder:Iw,get PacketType(){return Ke}},Symbol.toStringTag,{value:"Module"}));function Vn(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Dw=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class Sm 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(Dw.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)=>r!==this._queue[0]?void 0:(o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...a)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type: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.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type: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 uo(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}uo.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=(Math.floor(t*10)&1)==0?e-n:e+n}return Math.min(e,this.max)|0},uo.prototype.reset=function(){this.attempts=0},uo.prototype.setMin=function(e){this.ms=e},uo.prototype.setMax=function(e){this.max=e},uo.prototype.setJitter=function(e){this.jitter=e};class Gc 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,iu(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new uo({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||Lw;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 ww(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){ru(()=>{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 Sm(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const xs={};function Kc(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=_w(e,t.path||"/socket.io"),r=n.source,o=n.id,a=n.path,u=xs[o]&&a in xs[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||u;let d;return c?d=new Gc(r,t):(xs[o]||(xs[o]=new Gc(r,t)),d=xs[o]),n.query&&!t.query&&(t.query=n.queryKey),d.socket(n.path,t)}Object.assign(Kc,{Manager:Gc,Socket:Sm,io:Kc,connect:Kc});const vm=Object.prototype.toString;typeof Blob=="function"||typeof Blob!="undefined"&&vm.call(Blob),typeof File=="function"||typeof File!="undefined"&&vm.call(File);var Am;(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"})(Am||(Am={}));var X=ao();const xi=We(X);class Mw{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 Fw{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:se(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,`
|
|
1
|
+
(function(Oe,Fe){typeof exports=="object"&&typeof module!="undefined"?Fe(exports):typeof define=="function"&&define.amd?define(["exports"],Fe):(Oe=typeof globalThis!="undefined"?globalThis:Oe||self,Fe(Oe.CimulateMessaging={}))})(this,(function(Oe){"use strict";var iF=Object.defineProperty,oF=Object.defineProperties;var sF=Object.getOwnPropertyDescriptors;var Pc=Object.getOwnPropertySymbols;var Mx=Object.prototype.hasOwnProperty,Fx=Object.prototype.propertyIsEnumerable;var ys=(Oe,Fe)=>(Fe=Symbol[Oe])?Fe:Symbol.for("Symbol."+Oe),aF=Oe=>{throw TypeError(Oe)},Za=Math.pow,im=(Oe,Fe,We)=>Fe in Oe?iF(Oe,Fe,{enumerable:!0,configurable:!0,writable:!0,value:We}):Oe[Fe]=We,B=(Oe,Fe)=>{for(var We in Fe||(Fe={}))Mx.call(Fe,We)&&im(Oe,We,Fe[We]);if(Pc)for(var We of Pc(Fe))Fx.call(Fe,We)&&im(Oe,We,Fe[We]);return Oe},se=(Oe,Fe)=>oF(Oe,sF(Fe));var sn=(Oe,Fe)=>{var We={};for(var rt in Oe)Mx.call(Oe,rt)&&Fe.indexOf(rt)<0&&(We[rt]=Oe[rt]);if(Oe!=null&&Pc)for(var rt of Pc(Oe))Fe.indexOf(rt)<0&&Fx.call(Oe,rt)&&(We[rt]=Oe[rt]);return We};var Ze=(Oe,Fe,We)=>im(Oe,typeof Fe!="symbol"?Fe+"":Fe,We);var $e=(Oe,Fe,We)=>new Promise((rt,Et)=>{var dt=Tt=>{try{Pt(We.next(Tt))}catch(an){Et(an)}},Re=Tt=>{try{Pt(We.throw(Tt))}catch(an){Et(an)}},Pt=Tt=>Tt.done?rt(Tt.value):Promise.resolve(Tt.value).then(dt,Re);Pt((We=We.apply(Oe,Fe)).next())}),so=function(Oe,Fe){this[0]=Oe,this[1]=Fe},om=(Oe,Fe,We)=>{var rt=(Re,Pt,Tt,an)=>{try{var ao=We[Re](Pt),Ts=(Pt=ao.value)instanceof so,Lc=ao.done;Promise.resolve(Ts?Pt[0]:Pt).then($n=>Ts?rt(Re==="return"?Re:"next",Pt[1]?{done:$n.done,value:$n.value}:$n,Tt,an):Tt({value:$n,done:Lc})).catch($n=>rt("throw",$n,Tt,an))}catch($n){an($n)}},Et=Re=>dt[Re]=Pt=>new Promise((Tt,an)=>rt(Re,Pt,Tt,an)),dt={};return We=We.apply(Oe,Fe),dt[ys("asyncIterator")]=()=>dt,Et("next"),Et("throw"),Et("return"),dt},sm=Oe=>{var Fe=Oe[ys("asyncIterator")],We=!1,rt,Et={};return Fe==null?(Fe=Oe[ys("iterator")](),rt=dt=>Et[dt]=Re=>Fe[dt](Re)):(Fe=Fe.call(Oe),rt=dt=>Et[dt]=Re=>{if(We){if(We=!1,dt==="throw")throw Re;return Re}return We=!0,{done:!1,value:new so(new Promise(Pt=>{var Tt=Fe[dt](Re);Tt instanceof Object||aF("Object expected"),Pt(Tt)}),1)}}),Et[ys("iterator")]=()=>Et,rt("next"),"throw"in Fe?rt("throw"):Et.throw=dt=>{throw dt},"return"in Fe&&rt("return"),Et},Bx=(Oe,Fe,We)=>(Fe=Oe[ys("asyncIterator")])?Fe.call(Oe):(Oe=Oe[ys("iterator")](),Fe={},We=(rt,Et)=>(Et=Oe[rt])&&(Fe[rt]=dt=>new Promise((Re,Pt,Tt)=>(dt=Et.call(Oe,dt),Tt=dt.done,Promise.resolve(dt.value).then(an=>Re({value:an,done:Tt}),Pt)))),We("next"),We("return"),Fe);var Fe=document.createElement("style");Fe.textContent=`.cim-widget-icon-button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:32px;background-color:transparent;border:1px solid transparent;border-radius:var(--cim-widget-border-radius);padding:0;cursor:pointer;color:#333;font-size:18px;svg{padding:6px;height:100%;width:100%}&:hover{background-color:#f0f0f0}&:disabled,&[disabled]{opacity:.6;background-color:#f9f9f9;cursor:not-allowed}}.cim-widget-icon-image{object-fit:contain;padding:6px;width:.875em;height:.875em}.cim-widget-minimized-container{--base-color: var(--cim-widget-primary-color, #3182ce);--base-color-darken: color-mix(in srgb, var(--base-color), black 20%);position:fixed;bottom:1rem;right:1rem;display:flex;align-items:center;justify-content:center;.cim-widget-minimized-button{height:3rem;width:3rem;border-radius:2rem;padding:.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;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;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color, #d1d5db);background-color:var(--cim-widget-background-color, #ffffff);color:var(--cim-widget-font-color, #3f3f46);cursor:pointer;box-shadow:0 1px 3px #0000001a;transition:background-color .15s ease,box-shadow .15s ease}.cim-widget-carousel__prev-trigger:hover,.cim-widget-carousel__next-trigger:hover{background-color:#f9fafb;box-shadow:0 2px 6px #0000001f}.cim-widget-carousel__prev-trigger:disabled,.cim-widget-carousel__next-trigger:disabled{opacity:.4;cursor:not-allowed}.cim-widget-carousel__indicator-group{display:flex;justify-content:center;gap:6px;padding-top:12px}.cim-widget-carousel__indicator{width:8px;height:8px;border-radius:50%;border:none;background-color:var(--cim-widget-border-color, #d1d5db);cursor:pointer;padding:0;transition:background-color .2s ease,transform .2s ease}.cim-widget-carousel__indicator[data-current]{background-color:var(--cim-widget-font-color, #1a202c);transform:scale(1.25)}.cim-widget-carousel__indicator:hover:not([data-current]){background-color:var(--cim-widget-font-color, #1a202c);opacity:.5}.cim-widget-close-button{display:flex;align-items:center;justify-content:center;padding:.5rem;border-radius:var(--cim-widget-border-radius);border:1px solid transparent;background-color:transparent;cursor:pointer;&:hover{background-color:#f0f0f0}}.cim-widget-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-toggle-modal-button.cim-dialog-component{display:none}@media(min-width:576px){.cim-widget-toggle-modal-button.cim-dialog-component{display:inline-flex}}.cim-widget-blinking-cursor{display:inline-flex;margin-left:2px;line-height:0;animation:cursor-blink 1.5s steps(2) infinite}@keyframes cursor-blink{0%{opacity:0}}.cim-widget-ul{list-style-type:disc;padding-left:1.5rem}.cim-widget-ol{list-style-type:decimal;padding-left:1.5rem}.cim-widget-table-container{margin-top:1rem;margin-bottom:1rem;margin-right:.5rem;overflow-x:auto}.cim-widget-table{border-radius:.5rem;border-width:1px;border-style:solid;border-color:var(--cim-widget-border-color);border-collapse:collapse;width:100%}.cim-widget-thead{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent);border-bottom-width:2px;border-color:var(--cim-widget-border-color)}.cim-widget-tbody{border-width:0px;box-sizing:border-box;background-color:#ffffff90;overflow-wrap:break-word}.cim-widget-tr{border-style:solid;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-th{padding:.5rem 1rem;text-align:left;font-weight:700;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-td{padding:.5rem 1rem;border-bottom-width:1px;border-color:var(--cim-widget-border-color)}.cim-widget-message-container pre{margin:0}.cim-widget-connecting-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-size: 8px;--cim-loader-speed: 1.4s;--cim-loader-gap: .5rem;display:flex;align-items:center;gap:var(--cim-loader-gap)}.cim-widget-connecting-indicator.embedded{padding:12px 4px}.cim-widget-connecting-indicator.standalone{padding:12px 1rem}.cim-widget-connecting-pulse-wrapper{position:relative;width:calc(var(--cim-loader-size) * 2);height:calc(var(--cim-loader-size) * 2);display:flex;align-items:center;justify-content:center}.cim-widget-connecting-pulse{width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;background-color:var(--cim-loader-color);animation:cim-widget-pulse var(--cim-loader-speed) ease-in-out infinite}.cim-widget-connecting-ring{position:absolute;width:var(--cim-loader-size);height:var(--cim-loader-size);border-radius:50%;border:1.5px solid var(--cim-loader-color);animation:cim-widget-ring-expand var(--cim-loader-speed) ease-out infinite}.cim-widget-connecting-text{font-size:12px;color:var(--cim-widget-font-color);font-family:var(--cim-widget-font-family, inherit);opacity:0;transform:translateY(4px);transition:opacity .4s ease,transform .4s ease}.cim-widget-connecting-text--visible{opacity:1;transform:translateY(0)}@keyframes cim-widget-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.6);opacity:.4}}@keyframes cim-widget-ring-expand{0%{transform:scale(1);opacity:.6}to{transform:scale(2.8);opacity:0}}@media(prefers-reduced-motion:reduce){.cim-widget-connecting-pulse,.cim-widget-connecting-ring{animation:none!important}.cim-widget-connecting-pulse{opacity:.6}.cim-widget-connecting-text{animation:none!important;transition:none!important}}.cim-widget-processing-indicator{--cim-loader-color: var(--cim-widget-primary-color);--cim-loader-speed: 1.8s;display:flex;flex-direction:column;gap:8px}.cim-widget-processing-indicator.embedded{max-width:80%;min-height:2.5rem;padding:.5rem 0}.cim-widget-processing-indicator.standalone{padding:0 1rem;min-height:3rem}.cim-widget-processing-text{font-size:.875rem;font-style:italic;color:color-mix(in srgb,var(--cim-widget-secondary-color) 70%,var(--cim-loader-color));opacity:.75}.cim-widget-processing-shimmer-bar{height:10px;border-radius:4px;background:linear-gradient(90deg,var(--cim-widget-border-color) 25%,color-mix(in srgb,var(--cim-loader-color) 15%,var(--cim-widget-background-color)) 50%,var(--cim-widget-border-color) 75%);background-size:200% 100%;animation:cim-widget-shimmer var(--cim-loader-speed) ease-in-out infinite}.cim-widget-processing-shimmer-bar:nth-child(2){width:75%;animation-delay:.15s}.cim-widget-processing-shimmer-bar:nth-child(3){width:50%;animation-delay:.3s}@keyframes cim-widget-shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}@media(prefers-reduced-motion:reduce){.cim-widget-processing-shimmer-bar{animation:none!important;background:var(--cim-widget-border-color)!important}}.cim-widget-msg-product-card{display:flex;flex-direction:column;width:180px;min-width:180px;height:100%;background-color:var(--cim-widget-background-color, #ffffff);border:1px solid var(--cim-widget-border-color, #d1d5db);border-radius:var(--cim-widget-border-radius);overflow:hidden;transition:box-shadow .2s ease;&.card-full-width{width:100%;min-width:100%}}.cim-widget-msg-product-card:hover{box-shadow:0 2px 8px #0000001f}.cim-widget-msg-product-card__image-wrapper{position:relative;width:100%;height:100%;aspect-ratio:1 / 1;overflow:hidden}.cim-widget-msg-product-card__image{width:100%;height:100%;object-fit:contain;display:block}.cim-widget-msg-product-card__content{display:flex;flex-direction:column;justify-content:space-between;gap:1rem;padding:12px;height:40%}.cim-widget-msg-product-card__title,.cim-widget-msg-product-card__title-link{font-family:var(--cim-widget-font-family, sans-serif);font-weight:700;font-size:1rem;line-height:1.3;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46);margin:0;display:-webkit-box;line-clamp:2;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.cim-widget-msg-product-card__title-link{text-decoration:none}.cim-widget-msg-product-card__title-link:hover{text-decoration:underline}.cim-widget-msg-product-card__price-row{display:flex;align-items:center;justify-content:space-between;gap:8px}.cim-widget-msg-product-card__prices{display:flex;align-items:baseline;gap:6px;flex-wrap:wrap}.cim-widget-msg-product-card__price{font-family:var(--cim-widget-font-family, sans-serif);font-weight:700;font-size:14px;line-height:1.2;letter-spacing:-.3px;color:var(--cim-widget-font-color, #3f3f46)}.cim-widget-msg-product-card__compare-price{font-family:var(--cim-widget-font-family, sans-serif);font-weight:400;font-size:13px;line-height:1.2;color:var(--cim-widget-font-color, #3f3f46);opacity:.6;text-decoration:line-through}.cim-widget-msg-product-card__add-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;min-width:28px;border:none;border-radius:4px;background-color:var(--cim-widget-primary-color, #141415);color:#fff;cursor:pointer;transition:opacity .15s ease}.cim-widget-msg-product-card__add-btn:hover{opacity:.85}.cim-widget-msg-product-card__add-btn svg{width:14px;height:14px}.cim-widget-product-carousel-title{font-weight:800}.cim-widget-message-group,.cim-widget-message{display:flex;flex-direction:column}.cim-widget-message-group{gap:.5rem;padding:.5rem 1rem;margin-bottom:1rem;border-radius:var(--cim-widget-border-radius);&.standalone{padding:0 1rem}.cim-widget-message-group-child{max-width:100%;margin-bottom:.25rem}}.cim-widget-message-group.embedded{max-width:80%;background-color:color-mix(in hsl decreasing hue,var(--cim-widget-secondary-color) 5%,transparent)}.cim-widget-message{margin-bottom:1rem}.cim-widget-message.standalone{border-radius:0;background-color:transparent;padding:0 1rem}.cim-widget-message.embedded{margin-bottom:1rem}.message{border-radius:.5rem}.widget-message{display:flex;align-self:flex-start}.user-message{display:flex;align-self:flex-end;padding:1rem}.cim-widget-reset-message{font-size:.75rem;font-style:italic;color:color-mix(in hsl decreasing hue,var(--cim-widget-font-color) 75%,white)}.cim-widget-start-search-message{font-size:.875rem;font-weight:700;color:var(--cim-widget-font-color)}.cim-widget-user-message{display:flex;flex-direction:column;gap:.5rem;.cim-widget-user-message-row{display:inline-flex;align-items:center;gap:.5rem}}.cim-widget-user-message.embedded{display:inline-flex;align-self:flex-end;padding:.5rem 1rem;border-radius:var(--cim-widget-border-radius);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 10%,transparent);max-width:80%;min-width:50%}.cim-widget-user-message.standalone{margin:.5rem 0}.cim-widget-user-message-image{object-fit:contain;border-radius:8px;&.embedded{max-height:2.5rem}&.standalone{max-height:3.5rem}}.cim-widget-user-message-text{font-weight:700}.cim-widget-user-message-text.standalone{font-size:1.125rem;margin:0}.cim-widget-user-message-text.embedded{margin:0}.cim-widget-message-icon.user-message-icon.embedded{color:var(--cim-widget-primary-color)}.cim-widget-message-group-child{display:flex;flex-direction:column;gap:.25rem}.cim-widget-embedded-chat{position:relative;width:100%;height:100%;margin:0 auto;border-radius:var(--cim-widget-border-radius);border:1px solid var(--cim-widget-border-color)}.cim-widget-embedded-chat>.cim-widget-message-container{padding-top:2rem;padding-left:1rem;padding-right:1rem}.cim-widget-embedded-chat-menu{position:absolute;top:.25rem;right:.25rem}.cim-widget-overflow-menu-button-trigger.cim-chat-component{border:1px solid var(--cim-widget-border-color);border-radius:var(--cim-widget-border-radius);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;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;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;color:var(--cim-widget-primary-color);white-space:normal;word-break:break-word;text-align:left;cursor:pointer}.cim-widget-suggestion-button.embedded:hover{background-color:#fff;color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-container.standalone{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:.5rem;padding:.5rem 0}@media(max-width:768px){.cim-widget-suggestion-container.standalone{grid-template-columns:repeat(1,1fr)}}.cim-widget-suggestion-button.standalone{display:inline-flex;align-items:center;padding:.5rem 1rem;border:1px solid var(--cim-widget-primary-color);border-radius:var(--cim-widget-border-radius);background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 5%,transparent);font-weight:700;color:var(--cim-widget-primary-color);text-align:left;white-space:normal;word-break:break-word}.cim-widget-suggestion-button.standalone:hover{background-color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 15%,transparent);color:color-mix(in hsl decreasing hue,var(--cim-widget-primary-color) 85%,black)}.cim-widget-suggestion-button:disabled{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a;cursor:not-allowed}.cim-widget-suggestion-button:disabled:hover{border-color:#8a8a8a;background-color:#f9f9f9;color:#8a8a8a}
|
|
2
|
+
/*$vite$:1*/`,document.head.appendChild(Fe);function We(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var rt={exports:{}},Et={},dt={exports:{}},Re={};var Pt;function Tt(){if(Pt)return Re;Pt=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 b(D){return D===null||typeof D!="object"?null:(D=E&&D[E]||D["@@iterator"],typeof D=="function"?D:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,_={};function S(D,Z,k){this.props=D,this.context=Z,this.refs=_,this.updater=k||T}S.prototype.isReactComponent={},S.prototype.setState=function(D,Z){if(typeof D!="object"&&typeof D!="function"&&D!=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,D,Z,"setState")},S.prototype.forceUpdate=function(D){this.updater.enqueueForceUpdate(this,D,"forceUpdate")};function A(){}A.prototype=S.prototype;function O(D,Z,k){this.props=D,this.context=Z,this.refs=_,this.updater=k||T}var I=O.prototype=new A;I.constructor=O,x(I,S.prototype),I.isPureReactComponent=!0;var z=Array.isArray,Y=Object.prototype.hasOwnProperty,M={current:null},Q={key:!0,ref:!0,__self:!0,__source:!0};function Ee(D,Z,k){var xe,Pe={},Ne=null,He=null;if(Z!=null)for(xe in Z.ref!==void 0&&(He=Z.ref),Z.key!==void 0&&(Ne=""+Z.key),Z)Y.call(Z,xe)&&!Q.hasOwnProperty(xe)&&(Pe[xe]=Z[xe]);var Se=arguments.length-2;if(Se===1)Pe.children=k;else if(1<Se){for(var qe=Array(Se),ut=0;ut<Se;ut++)qe[ut]=arguments[ut+2];Pe.children=qe}if(D&&D.defaultProps)for(xe in Se=D.defaultProps,Se)Pe[xe]===void 0&&(Pe[xe]=Se[xe]);return{$$typeof:e,type:D,key:Ne,ref:He,props:Pe,_owner:M.current}}function re(D,Z){return{$$typeof:e,type:D.type,key:Z,ref:D.ref,props:D.props,_owner:D._owner}}function U(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function W(D){var Z={"=":"=0",":":"=2"};return"$"+D.replace(/[=:]/g,function(k){return Z[k]})}var te=/\/+/g;function oe(D,Z){return typeof D=="object"&&D!==null&&D.key!=null?W(""+D.key):Z.toString(36)}function de(D,Z,k,xe,Pe){var Ne=typeof D;(Ne==="undefined"||Ne==="boolean")&&(D=null);var He=!1;if(D===null)He=!0;else switch(Ne){case"string":case"number":He=!0;break;case"object":switch(D.$$typeof){case e:case t:He=!0}}if(He)return He=D,Pe=Pe(He),D=xe===""?"."+oe(He,0):xe,z(Pe)?(k="",D!=null&&(k=D.replace(te,"$&/")+"/"),de(Pe,Z,k,"",function(ut){return ut})):Pe!=null&&(U(Pe)&&(Pe=re(Pe,k+(!Pe.key||He&&He.key===Pe.key?"":(""+Pe.key).replace(te,"$&/")+"/")+D)),Z.push(Pe)),1;if(He=0,xe=xe===""?".":xe+":",z(D))for(var Se=0;Se<D.length;Se++){Ne=D[Se];var qe=xe+oe(Ne,Se);He+=de(Ne,Z,k,qe,Pe)}else if(qe=b(D),typeof qe=="function")for(D=qe.call(D),Se=0;!(Ne=D.next()).done;)Ne=Ne.value,qe=xe+oe(Ne,Se++),He+=de(Ne,Z,k,qe,Pe);else if(Ne==="object")throw Z=String(D),Error("Objects are not valid as a React child (found: "+(Z==="[object Object]"?"object with keys {"+Object.keys(D).join(", ")+"}":Z)+"). If you meant to render a collection of children, use an array instead.");return He}function be(D,Z,k){if(D==null)return D;var xe=[],Pe=0;return de(D,xe,"","",function(Ne){return Z.call(k,Ne,Pe++)}),xe}function Ie(D){if(D._status===-1){var Z=D._result;Z=Z(),Z.then(function(k){(D._status===0||D._status===-1)&&(D._status=1,D._result=k)},function(k){(D._status===0||D._status===-1)&&(D._status=2,D._result=k)}),D._status===-1&&(D._status=0,D._result=Z)}if(D._status===1)return D._result.default;throw D._result}var he={current:null},G={transition:null},ie={ReactCurrentDispatcher:he,ReactCurrentBatchConfig:G,ReactCurrentOwner:M};function v(){throw Error("act(...) is not supported in production builds of React.")}return Re.Children={map:be,forEach:function(D,Z,k){be(D,function(){Z.apply(this,arguments)},k)},count:function(D){var Z=0;return be(D,function(){Z++}),Z},toArray:function(D){return be(D,function(Z){return Z})||[]},only:function(D){if(!U(D))throw Error("React.Children.only expected to receive a single React element child.");return D}},Re.Component=S,Re.Fragment=n,Re.Profiler=o,Re.PureComponent=O,Re.StrictMode=r,Re.Suspense=d,Re.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ie,Re.act=v,Re.cloneElement=function(D,Z,k){if(D==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+D+".");var xe=x({},D.props),Pe=D.key,Ne=D.ref,He=D._owner;if(Z!=null){if(Z.ref!==void 0&&(Ne=Z.ref,He=M.current),Z.key!==void 0&&(Pe=""+Z.key),D.type&&D.type.defaultProps)var Se=D.type.defaultProps;for(qe in Z)Y.call(Z,qe)&&!Q.hasOwnProperty(qe)&&(xe[qe]=Z[qe]===void 0&&Se!==void 0?Se[qe]:Z[qe])}var qe=arguments.length-2;if(qe===1)xe.children=k;else if(1<qe){Se=Array(qe);for(var ut=0;ut<qe;ut++)Se[ut]=arguments[ut+2];xe.children=Se}return{$$typeof:e,type:D.type,key:Pe,ref:Ne,props:xe,_owner:He}},Re.createContext=function(D){return D={$$typeof:u,_currentValue:D,_currentValue2:D,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},D.Provider={$$typeof:a,_context:D},D.Consumer=D},Re.createElement=Ee,Re.createFactory=function(D){var Z=Ee.bind(null,D);return Z.type=D,Z},Re.createRef=function(){return{current:null}},Re.forwardRef=function(D){return{$$typeof:c,render:D}},Re.isValidElement=U,Re.lazy=function(D){return{$$typeof:p,_payload:{_status:-1,_result:D},_init:Ie}},Re.memo=function(D,Z){return{$$typeof:h,type:D,compare:Z===void 0?null:Z}},Re.startTransition=function(D){var Z=G.transition;G.transition={};try{D()}finally{G.transition=Z}},Re.unstable_act=v,Re.useCallback=function(D,Z){return he.current.useCallback(D,Z)},Re.useContext=function(D){return he.current.useContext(D)},Re.useDebugValue=function(){},Re.useDeferredValue=function(D){return he.current.useDeferredValue(D)},Re.useEffect=function(D,Z){return he.current.useEffect(D,Z)},Re.useId=function(){return he.current.useId()},Re.useImperativeHandle=function(D,Z,k){return he.current.useImperativeHandle(D,Z,k)},Re.useInsertionEffect=function(D,Z){return he.current.useInsertionEffect(D,Z)},Re.useLayoutEffect=function(D,Z){return he.current.useLayoutEffect(D,Z)},Re.useMemo=function(D,Z){return he.current.useMemo(D,Z)},Re.useReducer=function(D,Z,k){return he.current.useReducer(D,Z,k)},Re.useRef=function(D){return he.current.useRef(D)},Re.useState=function(D){return he.current.useState(D)},Re.useSyncExternalStore=function(D,Z,k){return he.current.useSyncExternalStore(D,Z,k)},Re.useTransition=function(){return he.current.useTransition()},Re.version="18.3.1",Re}var an;function ao(){return an||(an=1,dt.exports=Tt()),dt.exports}var Ts;function Lc(){if(Ts)return Et;Ts=1;var e=ao(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function u(c,d,h){var p,E={},b=null,T=null;h!==void 0&&(b=""+h),d.key!==void 0&&(b=""+d.key),d.ref!==void 0&&(T=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:b,ref:T,props:E,_owner:o.current}}return Et.Fragment=n,Et.jsx=u,Et.jsxs=u,Et}var $n;function jx(){return $n||($n=1,rt.exports=Lc()),rt.exports}var P=jx();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 eu=Object.create(null);Object.keys(or).forEach(e=>{eu[or[e]]=e});const Dc={type:"error",data:"parser error"},am=typeof Blob=="function"||typeof Blob!="undefined"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",um=typeof ArrayBuffer=="function",lm=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Mc=({type:e,data:t},n,r)=>am&&t instanceof Blob?n?r(t):cm(t,r):um&&(t instanceof ArrayBuffer||lm(t))?n?r(t):cm(new Blob([t]),r):r(or[e]+(t||"")),cm=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function dm(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Fc;function $x(e,t){if(am&&e.data instanceof Blob)return e.data.arrayBuffer().then(dm).then(t);if(um&&(e.data instanceof ArrayBuffer||lm(e.data)))return t(dm(e.data));Mc(e,!1,n=>{Fc||(Fc=new TextEncoder),t(Fc.encode(n))})}const fm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bs=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(let e=0;e<fm.length;e++)bs[fm.charCodeAt(e)]=e;const Vx=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=bs[e.charCodeAt(r)],u=bs[e.charCodeAt(r+1)],c=bs[e.charCodeAt(r+2)],d=bs[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},qx=typeof ArrayBuffer=="function",Bc=(e,t)=>{if(typeof e!="string")return{type:"message",data:hm(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:Yx(e.substring(1),t)}:eu[n]?e.length>1?{type:eu[n],data:e.substring(1)}:{type:eu[n]}:Dc},Yx=(e,t)=>{if(qx){const n=Vx(e);return hm(n,t)}else return{base64:!0,data:e}},hm=(e,t)=>t==="blob"?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,pm="",Wx=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((a,u)=>{Mc(a,!1,c=>{r[u]=c,++o===n&&t(r.join(pm))})})},Gx=(e,t)=>{const n=e.split(pm),r=[];for(let o=0;o<n.length;o++){const a=Bc(n[o],t);if(r.push(a),a.type==="error")break}return r};function Kx(){return new TransformStream({transform(e,t){$x(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 Uc;function tu(e){return e.reduce((t,n)=>t+n.length,0)}function nu(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 Qx(e,t){Uc||(Uc=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(tu(n)<1)break;const d=nu(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(tu(n)<2)break;const d=nu(n,2);o=new DataView(d.buffer,d.byteOffset,d.length).getUint16(0),r=3}else if(r===2){if(tu(n)<8)break;const d=nu(n,8),h=new DataView(d.buffer,d.byteOffset,d.length),p=h.getUint32(0);if(p>Math.pow(2,21)-1){c.enqueue(Dc);break}o=p*Math.pow(2,32)+h.getUint32(4),r=3}else{if(tu(n)<o)break;const d=nu(n,o);c.enqueue(Bc(a?d:Uc.decode(d),t)),r=0}if(o===0||o>e){c.enqueue(Dc);break}}}})}const mm=4;function St(e){if(e)return Xx(e)}function Xx(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 ru=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")(),Jx="arraybuffer";function uF(){}function gm(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const Zx=On.setTimeout,ew=On.clearTimeout;function iu(e,t){t.useNativeTimers?(e.setTimeoutFn=Zx.bind(On),e.clearTimeoutFn=ew.bind(On)):(e.setTimeoutFn=On.setTimeout.bind(On),e.clearTimeoutFn=On.clearTimeout.bind(On))}const tw=1.33;function nw(e){return typeof e=="string"?rw(e):Math.ceil((e.byteLength||e.size)*tw)}function rw(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 Em(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function iw(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function ow(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 sw extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Hc extends St{constructor(t){super(),this.writable=!1,iu(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 sw(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=Bc(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=iw(t);return n.length?"?"+n:""}}class aw extends Hc{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)};Gx(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,Wx(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]=Em()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let ym=!1;try{ym=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){}const uw=ym;function lw(){}class cw extends aw{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,iu(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=gm(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=lw,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",Tm);else if(typeof addEventListener=="function"){const e="onpagehide"in On?"pagehide":"unload";addEventListener(e,Tm,!1)}}function Tm(){for(let e in sr.requests)sr.requests.hasOwnProperty(e)&&sr.requests[e].abort()}const dw=(function(){const e=bm({xdomain:!1});return e&&e.responseType!==null})();class fw extends cw{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=dw&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new sr(bm,this.uri(),t)}}function bm(e){const t=e.xdomain;try{if(typeof XMLHttpRequest!="undefined"&&(!t||uw))return new XMLHttpRequest}catch(n){}if(!t)try{return new On[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(n){}}const xm=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class hw extends Hc{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=xm?{}:gm(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;Mc(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch(u){}o&&ru(()=>{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]=Em()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const zc=On.WebSocket||On.MozWebSocket;class pw extends hw{createSocket(t,n,r){return xm?new zc(t,n,r):n?new zc(t,n):new zc(t)}doWrite(t,n){this.ws.send(n)}}class mw extends Hc{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=Qx(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=Kx();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&&ru(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const gw={websocket:pw,webtransport:mw,polling:fw},Ew=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,yw=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function jc(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=Ew.exec(e||""),a={},u=14;for(;u--;)a[yw[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=Tw(a,a.path),a.queryKey=bw(a,a.query),a}function Tw(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 bw(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,a){o&&(n[o]=a)}),n}const $c=typeof addEventListener=="function"&&typeof removeEventListener=="function",ou=[];$c&&addEventListener("offline",()=>{ou.forEach(e=>e())},!1);class Hr extends St{constructor(t,n){if(super(),this.binaryType=Jx,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=jc(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=jc(n.host).host);iu(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=ow(this.opts.query)),$c&&(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"})},ou.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=mm,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&Hr.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",Hr.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const o=this.writeBuffer[r].data;if(o&&(n+=nw(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,ru(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const a={type:t,data:n,options:r};this.emitReserved("packetCreate",a),this.writeBuffer.push(a),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(Hr.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),$c&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=ou.indexOf(this._offlineEventListener);r!==-1&&ou.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Hr.protocol=mm;class xw extends Hr{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;Hr.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",E=>{if(!r)if(E.type==="pong"&&E.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Hr.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(p(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const b=new Error("probe error");b.transport=n.name,this.emitReserved("upgradeError",b)}}))};function a(){r||(r=!0,p(),n.close(),n=null)}const u=E=>{const b=new Error("probe error: "+E);b.transport=n.name,a(),this.emitReserved("upgradeError",b)};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 ww=class extends xw{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(o=>gw[o]).filter(o=>!!o)),super(t,r)}};function _w(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=jc(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 Sw=typeof ArrayBuffer=="function",vw=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,wm=Object.prototype.toString,Aw=typeof Blob=="function"||typeof Blob!="undefined"&&wm.call(Blob)==="[object BlobConstructor]",Cw=typeof File=="function"||typeof File!="undefined"&&wm.call(File)==="[object FileConstructor]";function Vc(e){return Sw&&(e instanceof ArrayBuffer||vw(e))||Aw&&e instanceof Blob||Cw&&e instanceof File}function su(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(su(e[n]))return!0;return!1}if(Vc(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return su(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&su(e[n]))return!0;return!1}function kw(e){const t=[],n=e.data,r=e;return r.data=qc(n,t),r.attachments=t.length,{packet:r,buffers:t}}function qc(e,t){if(!e)return e;if(Vc(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]=qc(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]=qc(e[r],t));return n}return e}function Nw(e,t){return e.data=Yc(e.data,t),delete e.attachments,e}function Yc(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]=Yc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Yc(e[n],t));return e}const Ow=["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 Iw{constructor(t){this.replacer=t}encode(t){return(t.type===Ke.EVENT||t.type===Ke.ACK)&&su(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=kw(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class Wc 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 Rw(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Vc(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(!Pw(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(Wc.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 _m(n);case Ke.DISCONNECT:return n===void 0;case Ke.CONNECT_ERROR:return typeof n=="string"||_m(n);case Ke.EVENT:case Ke.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&Ow.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 Rw{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=Nw(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Pw=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e};function _m(e){return Object.prototype.toString.call(e)==="[object Object]"}const Lw=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Wc,Encoder:Iw,get PacketType(){return Ke}},Symbol.toStringTag,{value:"Module"}));function Vn(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Dw=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class Sm 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(Dw.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)=>r!==this._queue[0]?void 0:(o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...a)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type: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.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type: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 uo(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}uo.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=(Math.floor(t*10)&1)==0?e-n:e+n}return Math.min(e,this.max)|0},uo.prototype.reset=function(){this.attempts=0},uo.prototype.setMin=function(e){this.ms=e},uo.prototype.setMax=function(e){this.max=e},uo.prototype.setJitter=function(e){this.jitter=e};class Gc 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,iu(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new uo({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||Lw;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 ww(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){ru(()=>{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 Sm(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const xs={};function Kc(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=_w(e,t.path||"/socket.io"),r=n.source,o=n.id,a=n.path,u=xs[o]&&a in xs[o].nsps,c=t.forceNew||t["force new connection"]||t.multiplex===!1||u;let d;return c?d=new Gc(r,t):(xs[o]||(xs[o]=new Gc(r,t)),d=xs[o]),n.query&&!t.query&&(t.query=n.queryKey),d.socket(n.path,t)}Object.assign(Kc,{Manager:Gc,Socket:Sm,io:Kc,connect:Kc});const vm=Object.prototype.toString;typeof Blob=="function"||typeof Blob!="undefined"&&vm.call(Blob),typeof File=="function"||typeof File!="undefined"&&vm.call(File);var Am;(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"})(Am||(Am={}));var X=ao();const xi=We(X);class Mw{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 Fw{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:se(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
|
|
|
@@ -7,23 +7,23 @@
|
|
|
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
8
|
`);this.logger.debug(`SSE event: ${n}`,o.slice(0,200)),this.onEvent(n,o)}}class zr extends Error{constructor(t,n="unknown",r){super(t,r),this.name="AgentforceClientError",this.type=n}}let Bw=class extends zr{constructor(t,n,r,o){super(t,"api",o),this.name="AgentforceApiError",this.statusCode=n,this.responseBody=r}};class Cm extends zr{constructor(t,n=1,r){super(t,"network",r),this.name="AgentforceNetworkError",this.attemptsMade=n}}let km=class extends zr{constructor(t,n){super(t,"auth",n),this.name="AgentforceAuthError"}};class Uw{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 Hw extends Mw{constructor({baseURL:t,orgId:n,esDeveloperName:r,options:o={}}){var u,c,d,h,p,E,b;super(),this._accessToken=null,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:(b=o.capabilitiesVersion)!=null?b:"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 Uw(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._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")}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 zr("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 zr("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 Fw(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||(this._accessToken=yield this.fetchAccessToken(),this.intentionalDisconnect))return;yield this.openSSE(),this.reconnectAttempts=0,this.logger.info("Reconnected successfully")}catch(r){if(this.intentionalDisconnect)return;this.logger.error(`Reconnect attempt ${this.reconnectAttempts} failed: ${r instanceof Error?r.message:String(r)}`),this.attemptReconnect()}}),n)}clearReconnectTimer(){this.reconnectTimeout&&(clearTimeout(this.reconnectTimeout),this.reconnectTimeout=null)}handleSSEEvent(t,n){if(t==="ping")return;let r;try{r=JSON.parse(n)}catch(o){return void this.logger.debug(`Non-JSON SSE event (${t}): ${n.slice(0,100)}`)}switch(t){case"CONVERSATION_ROUTING_RESULT":this.handleRoutingResult(r);break;case"CONVERSATION_MESSAGE":this.handleConversationMessage(r);break;case"CONVERSATION_STREAMING_TOKEN":this.handleStreamingToken(r);break;case"CONVERSATION_TYPING_STARTED_INDICATOR":this.handleTypingStarted(r);break;case"CONVERSATION_TYPING_STOPPED_INDICATOR":this.handleTypingStopped(r);break;case"CONVERSATION_PROGRESS_INDICATOR":this.handleProgressIndicator(r);break;case"CONVERSATION_PARTICIPANT_CHANGED":this.handleParticipantChanged(r);break;case"CONVERSATION_CLOSE_CONVERSATION":this.handleConversationClosed(r);break;default:this.logger.debug(`Unknown SSE event: ${t}`)}}handleRoutingResult(t){let n=t;t.conversationEntry&&(n=this.parseEntryPayload(t.conversationEntry));const r=n.failureType||n.routingFailureType||"",o=!r||r==="None"||r==="NO_ERROR";this.emit("routing_result",{conversationId:this._conversationId||"",isSuccessful:o,failureType:o?void 0:r,raw:n}),o||this.emit("error",{code:"ROUTING_FAILED",message:`Routing failed: ${r}`,recoverable:!1})}handleConversationMessage(t){var c;const n=t.conversationEntry;if(!n)return;const r=((c=n.sender)==null?void 0:c.role)||"";if(r==="EndUser"||r==="Customer")return;const o=this.parseEntryPayload(n),a=this.getNestedValue(o,"abstractMessage"),u=this.getNestedString(a,"staticContent","text")||this.getNestedString(a,"content","text")||"";u&&this.emit("message",{conversationId:this._conversationId||"",messageId:n.identifier||"",content:u,sender:{role:r,name:n.senderDisplayName},timestamp:n.transcriptedTimestamp||new Date().toISOString(),raw:o})}handleStreamingToken(t){const n=t.token||t.text||"";n&&this.emit("streaming_token",{conversationId:this._conversationId||"",token:String(n)})}handleTypingStarted(t){var n;this.emit("typing_started",{conversationId:this._conversationId||"",participant:(n=t.conversationEntry)!=null&&n.sender?{role:t.conversationEntry.sender.role||"",name:t.conversationEntry.senderDisplayName}:void 0})}handleTypingStopped(t){var n;this.emit("typing_stopped",{conversationId:this._conversationId||"",participant:(n=t.conversationEntry)!=null&&n.sender?{role:t.conversationEntry.sender.role||"",name:t.conversationEntry.senderDisplayName}:void 0})}handleProgressIndicator(t){const n=t.conversationEntry;if(!n)return;const r=this.parseEntryPayload(n),o=this.getNestedValue(r,"progressIndicator"),a=this.getNestedString(o,"progressMessage","text")||this.getNestedString(o,"progressMessage","content")||t.text||"";if(!a)return;const u=this.getNestedString(o,"indicatorType")||void 0;this.emit("progress_indicator",{conversationId:this._conversationId||"",message:String(a),indicatorType:u,raw:r})}handleParticipantChanged(t){var o,a,u,c,d,h,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 b=E.participant,T=E.displayName||(b==null?void 0:b.displayName)||((o=t.conversationEntry)==null?void 0:o.senderDisplayName)||"Agent",x=(b==null?void 0:b.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:T},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",b=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(b)})}}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 km("Token response missing accessToken field");return 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 b=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 km(`Request ${t} ${n} failed (401): continuation token expired or invalid. Reconnect without a continuation token to create a new session.`);this.logger.info("Got 401 — refreshing token and retrying..."),this._accessToken=yield this.fetchAccessToken(),u++;continue}throw new Bw(`Request ${t} ${n} failed (${E.status}): ${b}`,E.status,b)}return E.status===204||t==="DELETE"?{}:E.text().then(b=>b?JSON.parse(b):null)}catch(d){if(clearTimeout(c),d instanceof zr)throw d;if(d instanceof DOMException&&d.name==="AbortError")throw new Cm("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 Cm(`Network error: ${d.message}`,u,{cause:d})}throw new zr(`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 zr("Client is not connected. Call connect() first.","unknown")}parseEntryPayload(t){if(!t.entryPayload)return{};if(typeof t.entryPayload=="string")try{return JSON.parse(t.entryPayload)}catch(n){return{}}return t.entryPayload}getNestedValue(t,...n){let r=t;for(const o of n){if(r==null||typeof r!="object")return;r=r[o]}return r}getNestedString(t,...n){const r=this.getNestedValue(t,...n);return typeof r=="string"?r:""}}const ee="cim-widget",Sr=`--${ee}`,jr={primaryColor:"#3182ce",secondaryColor:"#2c5282",fontColor:"#1a202c",fontFamily:"inherit",backgroundColor:"#ffffff",borderColor:"#dddddd",borderRadius:"0.25rem"},zw=(e=jr)=>({[`${Sr}-primary-color`]:e.primaryColor||jr.primaryColor,[`${Sr}-secondary-color`]:e.secondaryColor||jr.secondaryColor,[`${Sr}-font-color`]:e.fontColor||jr.fontColor,[`${Sr}-font-family`]:e.fontFamily||jr.fontFamily,[`${Sr}-background-color`]:e.backgroundColor||jr.backgroundColor,[`${Sr}-border-color`]:e.borderColor||jr.borderColor,[`${Sr}-border-radius`]:e.borderRadius||jr.borderRadius});function Nm(e,t){return function(){return e.apply(t,arguments)}}const{toString:jw}=Object.prototype,{getPrototypeOf:au}=Object,{iterator:uu,toStringTag:Om}=Symbol,lu=(e=>t=>{const n=jw.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),qn=e=>(e=e.toLowerCase(),t=>lu(t)===e),cu=e=>t=>typeof t===e,{isArray:lo}=Array,co=cu("undefined");function ws(e){return e!==null&&!co(e)&&e.constructor!==null&&!co(e.constructor)&&un(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Im=qn("ArrayBuffer");function $w(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Im(e.buffer),t}const Vw=cu("string"),un=cu("function"),Rm=cu("number"),_s=e=>e!==null&&typeof e=="object",qw=e=>e===!0||e===!1,du=e=>{if(lu(e)!=="object")return!1;const t=au(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Om in e)&&!(uu in e)},Yw=e=>{if(!_s(e)||ws(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},Ww=qn("Date"),Gw=qn("File"),Kw=e=>!!(e&&typeof e.uri!="undefined"),Qw=e=>e&&typeof e.getParts!="undefined",Xw=qn("Blob"),Jw=qn("FileList"),Zw=e=>_s(e)&&un(e.pipe);function e_(){return typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:{}}const Pm=e_(),Lm=typeof Pm.FormData!="undefined"?Pm.FormData:void 0,t_=e=>{if(!e)return!1;if(Lm&&e instanceof Lm)return!0;const t=au(e);if(!t||t===Object.prototype||!un(e.append))return!1;const n=lu(e);return n==="formdata"||n==="object"&&un(e.toString)&&e.toString()==="[object FormData]"},n_=qn("URLSearchParams"),[r_,i_,o_,s_]=["ReadableStream","Request","Response","Headers"].map(qn),a_=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ss(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,o;if(typeof e!="object"&&(e=[e]),lo(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(ws(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 Dm(e,t){if(ws(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 wi=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,Mm=e=>!co(e)&&e!==wi;function Qc(...e){const{caseless:t,skipUndefined:n}=Mm(this)&&this||{},r={},o=(a,u)=>{if(u==="__proto__"||u==="constructor"||u==="prototype")return;const c=t&&Dm(r,u)||u,d=Xc(r,c)?r[c]:void 0;du(d)&&du(a)?r[c]=Qc(d,a):du(a)?r[c]=Qc({},a):lo(a)?r[c]=a.slice():(!n||!co(a))&&(r[c]=a)};for(let a=0,u=e.length;a<u;a++)e[a]&&Ss(e[a],o);return r}const u_=(e,t,n,{allOwnKeys:r}={})=>(Ss(t,(o,a)=>{n&&un(o)?Object.defineProperty(e,a,{__proto__:null,value:Nm(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),l_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),c_=(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)},d_=(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&&au(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},f_=(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},h_=e=>{if(!e)return null;if(lo(e))return e;let t=e.length;if(!Rm(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},p_=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&au(Uint8Array)),m_=(e,t)=>{const r=(e&&e[uu]).call(e);let o;for(;(o=r.next())&&!o.done;){const a=o.value;t.call(e,a[0],a[1])}},g_=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},E_=qn("HTMLFormElement"),y_=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Xc=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),T_=qn("RegExp"),Fm=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Ss(n,(o,a)=>{let u;(u=t(o,a,e))!==!1&&(r[a]=u||o)}),Object.defineProperties(e,r)},b_=e=>{Fm(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+"'")})}})},x_=(e,t)=>{const n={},r=o=>{o.forEach(a=>{n[a]=!0})};return lo(e)?r(e):r(String(e).split(t)),n},w_=()=>{},__=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function S_(e){return!!(e&&un(e.append)&&e[Om]==="FormData"&&e[uu])}const v_=e=>{const t=new WeakSet,n=r=>{if(_s(r)){if(t.has(r))return;if(ws(r))return r;if(!("toJSON"in r)){t.add(r);const o=lo(r)?[]:{};return Ss(r,(a,u)=>{const c=n(a);!co(c)&&(o[u]=c)}),t.delete(r),o}}return r};return n(e)},A_=qn("AsyncFunction"),C_=e=>e&&(_s(e)||un(e))&&un(e.then)&&un(e.catch),Bm=((e,t)=>e?setImmediate:t?((n,r)=>(wi.addEventListener("message",({source:o,data:a})=>{o===wi&&a===n&&r.length&&r.shift()()},!1),o=>{r.push(o),wi.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",un(wi.postMessage)),k_=typeof queueMicrotask!="undefined"?queueMicrotask.bind(wi):typeof process!="undefined"&&process.nextTick||Bm,j={isArray:lo,isArrayBuffer:Im,isBuffer:ws,isFormData:t_,isArrayBufferView:$w,isString:Vw,isNumber:Rm,isBoolean:qw,isObject:_s,isPlainObject:du,isEmptyObject:Yw,isReadableStream:r_,isRequest:i_,isResponse:o_,isHeaders:s_,isUndefined:co,isDate:Ww,isFile:Gw,isReactNativeBlob:Kw,isReactNative:Qw,isBlob:Xw,isRegExp:T_,isFunction:un,isStream:Zw,isURLSearchParams:n_,isTypedArray:p_,isFileList:Jw,forEach:Ss,merge:Qc,extend:u_,trim:a_,stripBOM:l_,inherits:c_,toFlatObject:d_,kindOf:lu,kindOfTest:qn,endsWith:f_,toArray:h_,forEachEntry:m_,matchAll:g_,isHTMLForm:E_,hasOwnProperty:Xc,hasOwnProp:Xc,reduceDescriptors:Fm,freezeMethods:b_,toObjectSet:x_,toCamelCase:y_,noop:w_,toFiniteNumber:__,findKey:Dm,global:wi,isContextDefined:Mm,isSpecCompliantForm:S_,toJSONObject:v_,isAsyncFn:A_,isThenable:C_,setImmediate:Bm,asap:k_,isIterable:e=>e!=null&&un(e[uu])},N_=j.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"]),O_=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]&&N_[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t};function I_(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 R_=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),P_=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Jc(e,t){return j.isArray(e)?e.map(n=>Jc(n,t)):I_(String(e).replace(t,""))}const L_=e=>Jc(e,R_),D_=e=>Jc(e,P_);function Um(e){const t=Object.create(null);return j.forEach(e.toJSON(),(n,r)=>{t[r]=D_(n)}),t}const Hm=Symbol("internals");function vs(e){return e&&String(e).trim().toLowerCase()}function fu(e){return e===!1||e==null?e:j.isArray(e)?e.map(fu):L_(String(e))}function M_(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 F_=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Zc(e,t,n,r,o){if(j.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!j.isString(t)){if(j.isString(r))return t.indexOf(r)!==-1;if(j.isRegExp(r))return r.test(t)}}function B_(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function U_(e,t){const n=j.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 en=class{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function a(c,d,h){const p=vs(d);if(!p)throw new Error("header name must be a non-empty string");const E=j.findKey(o,p);(!E||o[E]===void 0||h===!0||h===void 0&&o[E]!==!1)&&(o[E||d]=fu(c))}const u=(c,d)=>j.forEach(c,(h,p)=>a(h,p,d));if(j.isPlainObject(t)||t instanceof this.constructor)u(t,n);else if(j.isString(t)&&(t=t.trim())&&!F_(t))u(O_(t),n);else if(j.isObject(t)&&j.isIterable(t)){let c={},d,h;for(const p of t){if(!j.isArray(p))throw TypeError("Object iterator must return a key-value pair");c[h=p[0]]=(d=c[h])?j.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=vs(t),t){const r=j.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return M_(o);if(j.isFunction(n))return n.call(this,o,r);if(j.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=vs(t),t){const r=j.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Zc(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function a(u){if(u=vs(u),u){const c=j.findKey(r,u);c&&(!n||Zc(r,r[c],c,n))&&(delete r[c],o=!0)}}return j.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||Zc(this,this[a],a,t,!0))&&(delete this[a],o=!0)}return o}normalize(t){const n=this,r={};return j.forEach(this,(o,a)=>{const u=j.findKey(r,a);if(u){n[u]=fu(o),delete n[a];return}const c=t?B_(a):String(a).trim();c!==a&&delete n[a],n[c]=fu(o),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return j.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&j.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[Hm]=this[Hm]={accessors:{}}).accessors,o=this.prototype;function a(u){const c=vs(u);r[c]||(U_(o,u),r[c]=!0)}return j.isArray(t)?t.forEach(a):a(t),this}};en.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),j.reduceDescriptors(en.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),j.freezeMethods(en);const H_="[REDACTED ****]";function z_(e){if(j.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(j.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function j_(e,t){const n=new Set(t.map(a=>String(a).toLowerCase())),r=[],o=a=>{if(a===null||typeof a!="object"||j.isBuffer(a))return a;if(r.indexOf(a)!==-1)return;a instanceof en&&(a=a.toJSON()),r.push(a);let u;if(j.isArray(a))u=[],a.forEach((c,d)=>{const h=o(c);j.isUndefined(h)||(u[d]=h)});else{if(!j.isPlainObject(a)&&z_(a))return r.pop(),a;u=Object.create(null);for(const[c,d]of Object.entries(a)){const h=n.has(c.toLowerCase())?H_:o(d);j.isUndefined(h)||(u[c]=h)}}return r.pop(),u};return o(e)}let Ae=class Ux extends Error{static from(t,n,r,o,a,u){const c=new Ux(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&&j.hasOwnProp(t,"redact")?t.redact:void 0,r=j.isArray(n)&&n.length>0?j_(t,n):j.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}}};Ae.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",Ae.ERR_BAD_OPTION="ERR_BAD_OPTION",Ae.ECONNABORTED="ECONNABORTED",Ae.ETIMEDOUT="ETIMEDOUT",Ae.ECONNREFUSED="ECONNREFUSED",Ae.ERR_NETWORK="ERR_NETWORK",Ae.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",Ae.ERR_DEPRECATED="ERR_DEPRECATED",Ae.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",Ae.ERR_BAD_REQUEST="ERR_BAD_REQUEST",Ae.ERR_CANCELED="ERR_CANCELED",Ae.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",Ae.ERR_INVALID_URL="ERR_INVALID_URL",Ae.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const $_=null;function ed(e){return j.isPlainObject(e)||j.isArray(e)}function zm(e){return j.endsWith(e,"[]")?e.slice(0,-2):e}function td(e,t,n){return e?e.concat(t).map(function(o,a){return o=zm(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function V_(e){return j.isArray(e)&&!e.some(ed)}const q_=j.toFlatObject(j,{},null,function(t){return/^is[A-Z]/.test(t)});function hu(e,t,n){if(!j.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=j.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,A){return!j.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&&j.isSpecCompliantForm(t);if(!j.isFunction(o))throw new TypeError("visitor must be a function");function p(_){if(_===null)return"";if(j.isDate(_))return _.toISOString();if(j.isBoolean(_))return _.toString();if(!h&&j.isBlob(_))throw new Ae("Blob is not supported. Use a Buffer instead.");return j.isArrayBuffer(_)||j.isTypedArray(_)?h&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function E(_,S,A){let O=_;if(j.isReactNative(t)&&j.isReactNativeBlob(_))return t.append(td(A,S,a),p(_)),!1;if(_&&!A&&typeof _=="object"){if(j.endsWith(S,"{}"))S=r?S:S.slice(0,-2),_=JSON.stringify(_);else if(j.isArray(_)&&V_(_)||(j.isFileList(_)||j.endsWith(S,"[]"))&&(O=j.toArray(_)))return S=zm(S),O.forEach(function(H,Y){!(j.isUndefined(H)||H===null)&&t.append(u===!0?td([S],Y,a):u===null?S:S+"[]",p(H))}),!1}return ed(_)?!0:(t.append(td(A,S,a),p(_)),!1)}const b=[],T=Object.assign(q_,{defaultVisitor:E,convertValue:p,isVisitable:ed});function x(_,S,A=0){if(!j.isUndefined(_)){if(A>d)throw new Ae("Object is too deeply nested ("+A+" levels). Max depth: "+d,Ae.ERR_FORM_DATA_DEPTH_EXCEEDED);if(b.indexOf(_)!==-1)throw Error("Circular reference detected in "+S.join("."));b.push(_),j.forEach(_,function(I,H){(!(j.isUndefined(I)||I===null)&&o.call(t,I,j.isString(H)?H.trim():H,S,T))===!0&&x(I,S?S.concat(H):[H],A+1)}),b.pop()}}if(!j.isObject(e))throw new TypeError("data must be an object");return x(e),t}function jm(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function nd(e,t){this._pairs=[],e&&hu(e,this,t)}const $m=nd.prototype;$m.append=function(t,n){this._pairs.push([t,n])},$m.toString=function(t){const n=t?function(r){return t.call(this,r,jm)}:jm;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Y_(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Vm(e,t,n){if(!t)return e;const r=n&&n.encode||Y_,o=j.isFunction(n)?{serialize:n}:n,a=o&&o.serialize;let u;if(a?u=a(t,o):u=j.isURLSearchParams(t)?t.toString():new nd(t,o).toString(r),u){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class qm{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){j.forEach(this.handlers,function(r){r!==null&&t(r)})}}const rd={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},W_={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:nd,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},id=typeof window!="undefined"&&typeof document!="undefined",od=typeof navigator=="object"&&navigator||void 0,G_=id&&(!od||["ReactNative","NativeScript","NS"].indexOf(od.product)<0),K_=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Q_=id&&window.location.href||"http://localhost",qt=B(B({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:id,hasStandardBrowserEnv:G_,hasStandardBrowserWebWorkerEnv:K_,navigator:od,origin:Q_},Symbol.toStringTag,{value:"Module"}))),W_);function X_(e,t){return hu(e,new qt.classes.URLSearchParams,B({visitor:function(n,r,o,a){return qt.isNode&&j.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function J_(e){return j.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Z_(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 Ym(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&&j.isArray(o)?o.length:u,d?(j.hasOwnProp(o,u)?o[u]=j.isArray(o[u])?o[u].concat(r):[o[u],r]:o[u]=r,!c):((!j.hasOwnProp(o,u)||!j.isObject(o[u]))&&(o[u]=[]),t(n,r,o[u],a)&&j.isArray(o[u])&&(o[u]=Z_(o[u])),!c)}if(j.isFormData(e)&&j.isFunction(e.entries)){const n={};return j.forEachEntry(e,(r,o)=>{t(J_(r),o,n,0)}),n}return null}const fo=(e,t)=>e!=null&&j.hasOwnProp(e,t)?e[t]:void 0;function eS(e,t,n){if(j.isString(e))try{return(t||JSON.parse)(e),j.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const As={transitional:rd,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=j.isObject(t);if(a&&j.isHTMLForm(t)&&(t=new FormData(t)),j.isFormData(t))return o?JSON.stringify(Ym(t)):t;if(j.isArrayBuffer(t)||j.isBuffer(t)||j.isStream(t)||j.isFile(t)||j.isBlob(t)||j.isReadableStream(t))return t;if(j.isArrayBufferView(t))return t.buffer;if(j.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(a){const d=fo(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return X_(t,d).toString();if((c=j.isFileList(t))||r.indexOf("multipart/form-data")>-1){const h=fo(this,"env"),p=h&&h.FormData;return hu(c?{"files[]":t}:t,p&&new p,d)}}return a||o?(n.setContentType("application/json",!1),eS(t)):t}],transformResponse:[function(t){const n=fo(this,"transitional")||As.transitional,r=n&&n.forcedJSONParsing,o=fo(this,"responseType"),a=o==="json";if(j.isResponse(t)||j.isReadableStream(t))return t;if(t&&j.isString(t)&&(r&&!o||a)){const c=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(t,fo(this,"parseReviver"))}catch(d){if(c)throw d.name==="SyntaxError"?Ae.from(d,Ae.ERR_BAD_RESPONSE,this,null,fo(this,"response")):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:qt.classes.FormData,Blob:qt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};j.forEach(["delete","get","head","post","put","patch","query"],e=>{As.headers[e]={}});function sd(e,t){const n=this||As,r=t||n,o=en.from(r.headers);let a=r.data;return j.forEach(e,function(c){a=c.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function Wm(e){return!!(e&&e.__CANCEL__)}let Cs=class extends Ae{constructor(t,n,r){super(t==null?"canceled":t,Ae.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function Gm(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new Ae("Request failed with status code "+n.status,n.status>=400&&n.status<500?Ae.ERR_BAD_REQUEST:Ae.ERR_BAD_RESPONSE,n.config,n.request,n))}function tS(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function nS(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,b=0;for(;E!==o;)b+=n[E++],E=E%e;if(o=(o+1)%e,o===a&&(a=(a+1)%e),h-u<t)return;const T=p&&h-p;return T?Math.round(b*1e3/T):void 0}}function rS(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 pu=(e,t,n=3)=>{let r=0;const o=nS(50,250);return rS(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)},Km=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Qm=e=>(...t)=>j.asap(()=>e(...t)),iS=qt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,qt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(qt.origin),qt.navigator&&/(msie|trident)/i.test(qt.navigator.userAgent)):()=>!0,oS=qt.hasStandardBrowserEnv?{write(e,t,n,r,o,a,u){if(typeof document=="undefined")return;const c=[`${e}=${encodeURIComponent(t)}`];j.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),j.isString(r)&&c.push(`path=${r}`),j.isString(o)&&c.push(`domain=${o}`),a===!0&&c.push("secure"),j.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 sS(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function aS(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Xm(e,t,n){let r=!sS(t);return e&&(r||n===!1)?aS(e,t):t}const Jm=e=>e instanceof en?B({},e):e;function _i(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,b){return j.isPlainObject(h)&&j.isPlainObject(p)?j.merge.call({caseless:b},h,p):j.isPlainObject(p)?j.merge({},p):j.isArray(p)?p.slice():p}function o(h,p,E,b){if(j.isUndefined(p)){if(!j.isUndefined(h))return r(void 0,h,E,b)}else return r(h,p,E,b)}function a(h,p){if(!j.isUndefined(p))return r(void 0,p)}function u(h,p){if(j.isUndefined(p)){if(!j.isUndefined(h))return r(void 0,h)}else return r(void 0,p)}function c(h,p,E){if(j.hasOwnProp(t,E))return r(h,p);if(j.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(Jm(h),Jm(p),E,!0)};return j.forEach(Object.keys(B(B({},e),t)),function(p){if(p==="__proto__"||p==="constructor"||p==="prototype")return;const E=j.hasOwnProp(d,p)?d[p]:o,b=j.hasOwnProp(e,p)?e[p]:void 0,T=j.hasOwnProp(t,p)?t[p]:void 0,x=E(b,T,p);j.isUndefined(x)&&E!==c||(n[p]=x)}),n}const uS=["content-type","content-length"];function lS(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,o])=>{uS.includes(r.toLowerCase())&&e.set(r,o)})}const cS=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),Zm=e=>{const t=_i({},e),n=b=>j.hasOwnProp(t,b)?t[b]: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=en.from(c),t.url=Vm(Xm(h,E,p),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?cS(d.password):""))),j.isFormData(r)&&(qt.hasStandardBrowserEnv||qt.hasStandardBrowserWebWorkerEnv?c.setContentType(void 0):j.isFunction(r.getHeaders)&&lS(c,r.getHeaders(),n("formDataHeaderPolicy"))),qt.hasStandardBrowserEnv&&(j.isFunction(o)&&(o=o(t)),o===!0||o==null&&iS(t.url))){const T=a&&u&&oS.read(u);T&&c.set(a,T)}return t},dS=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=Zm(e);let a=o.data;const u=en.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:h}=o,p,E,b,T,x;function _(){T&&T(),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 I=en.from("getAllResponseHeaders"in S&&S.getAllResponseHeaders()),Y={data:!c||c==="text"||c==="json"?S.responseText:S.response,status:S.status,statusText:S.statusText,headers:I,config:e,request:S};Gm(function(G){n(G),_()},function(G){r(G),_()},Y),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 Ae("Request aborted",Ae.ECONNABORTED,e,S)),_(),S=null)},S.onerror=function(H){const Y=H&&H.message?H.message:"Network Error",M=new Ae(Y,Ae.ERR_NETWORK,e,S);M.event=H||null,r(M),_(),S=null},S.ontimeout=function(){let H=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const Y=o.transitional||rd;o.timeoutErrorMessage&&(H=o.timeoutErrorMessage),r(new Ae(H,Y.clarifyTimeoutError?Ae.ETIMEDOUT:Ae.ECONNABORTED,e,S)),_(),S=null},a===void 0&&u.setContentType(null),"setRequestHeader"in S&&j.forEach(Um(u),function(H,Y){S.setRequestHeader(Y,H)}),j.isUndefined(o.withCredentials)||(S.withCredentials=!!o.withCredentials),c&&c!=="json"&&(S.responseType=o.responseType),h&&([b,x]=pu(h,!0),S.addEventListener("progress",b)),d&&S.upload&&([E,T]=pu(d),S.upload.addEventListener("progress",E),S.upload.addEventListener("loadend",T)),(o.cancelToken||o.signal)&&(p=I=>{S&&(r(!I||I.type?new Cs(null,e,S):I),S.abort(),_(),S=null)},o.cancelToken&&o.cancelToken.subscribe(p),o.signal&&(o.signal.aborted?p():o.signal.addEventListener("abort",p)));const O=tS(o.url);if(O&&!qt.protocols.includes(O)){r(new Ae("Unsupported protocol "+O+":",Ae.ERR_BAD_REQUEST,e));return}S.send(a||null)})},fS=(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 Ae?h:new Cs(h instanceof Error?h.message:h))}};let a=t&&setTimeout(()=>{a=null,o(new Ae(`timeout of ${t}ms exceeded`,Ae.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=()=>j.asap(u),c},hS=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},pS=function(e,t){return om(this,null,function*(){try{for(var n=Bx(mS(e)),r,o,a;r=!(o=yield new so(n.next())).done;r=!1){const u=o.value;yield*sm(hS(u,t))}}catch(o){a=[o]}finally{try{r&&(o=n.return)&&(yield new so(o.call(n)))}finally{if(a)throw a[0]}}})},mS=function(e){return om(this,null,function*(){if(e[Symbol.asyncIterator]){yield*sm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new so(t.read());if(n)break;yield r}}finally{yield new so(t.cancel())}})},e0=(e,t,n,r)=>{const o=pS(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 b=E.byteLength;if(n){let T=a+=b;n(T)}h.enqueue(new Uint8Array(E))}catch(p){throw c(p),p}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})};function gS(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 T=0;T<c;T++)if(r.charCodeAt(T)===37&&T+2<c){const x=r.charCodeAt(T+1),_=r.charCodeAt(T+2);(x>=48&&x<=57||x>=65&&x<=70||x>=97&&x<=102)&&(_>=48&&_<=57||_>=65&&_<=70||_>=97&&_<=102)&&(u-=2,T+=2)}let d=0,h=c-1;const p=T=>T>=2&&r.charCodeAt(T-2)===37&&r.charCodeAt(T-1)===51&&(r.charCodeAt(T)===68||r.charCodeAt(T)===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 b=Math.floor(u/4)*3-(d||0);return b>0?b: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 ad="1.16.1",t0=64*1024,{isFunction:mu}=j,n0=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},ES=e=>{const t=j.global!==void 0&&j.global!==null?j.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=j.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:o,Request:a,Response:u}=e,c=o?mu(o):typeof fetch=="function",d=mu(a),h=mu(u);if(!c)return!1;const p=c&&mu(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())})),b=d&&p&&n0(()=>{let A=!1;const O=new a(qt.origin,{body:new n,method:"POST",get duplex(){return A=!0,"half"}}),I=O.headers.has("Content-Type");return O.body!=null&&O.body.cancel(),A&&!I}),T=h&&p&&n0(()=>j.isReadableStream(new u("").body)),x={stream:T&&(A=>A.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(A=>{!x[A]&&(x[A]=(O,I)=>{let H=O&&O[A];if(H)return H.call(O);throw new Ae(`Response type '${A}' is not supported`,Ae.ERR_NOT_SUPPORT,I)})});const _=A=>$e(null,null,function*(){if(A==null)return 0;if(j.isBlob(A))return A.size;if(j.isSpecCompliantForm(A))return(yield new a(qt.origin,{method:"POST",body:A}).arrayBuffer()).byteLength;if(j.isArrayBufferView(A)||j.isArrayBuffer(A))return A.byteLength;if(j.isURLSearchParams(A)&&(A=A+""),j.isString(A))return(yield E(A)).byteLength}),S=(A,O)=>$e(null,null,function*(){const I=j.toFiniteNumber(A.getContentLength());return I==null?_(O):I});return A=>$e(null,null,function*(){let{url:O,method:I,data:H,signal:Y,cancelToken:M,timeout:G,onDownloadProgress:pe,onUploadProgress:re,responseType:z,headers:W,withCredentials:te="same-origin",fetchOptions:oe,maxContentLength:de,maxBodyLength:be}=Zm(A);const Ne=j.isNumber(de)&&de>-1,me=j.isNumber(be)&&be>-1;let Q=o||fetch;z=z?(z+"").toLowerCase():"text";let ie=fS([Y,M&&M.toAbortSignal()],G),v=null;const D=ie&&ie.unsubscribe&&(()=>{ie.unsubscribe()});let Z;try{if(Ne&&typeof O=="string"&&O.startsWith("data:")&&gS(O)>de)throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v);if(me&&I!=="get"&&I!=="head"){const Se=yield S(W,H);if(typeof Se=="number"&&isFinite(Se)&&Se>be)throw new Ae("Request body larger than maxBodyLength limit",Ae.ERR_BAD_REQUEST,A,v)}if(re&&b&&I!=="get"&&I!=="head"&&(Z=yield S(W,H))!==0){let Se=new a(O,{method:"POST",body:H,duplex:"half"}),qe;if(j.isFormData(H)&&(qe=Se.headers.get("content-type"))&&W.setContentType(qe),Se.body){const[ut,pn]=Km(Z,pu(Qm(re)));H=e0(Se.body,t0,ut,pn)}}j.isString(te)||(te=te?"include":"omit");const k=d&&"credentials"in a.prototype;if(j.isFormData(H)){const Se=W.getContentType();Se&&/^multipart\/form-data/i.test(Se)&&!/boundary=/i.test(Se)&&W.delete("content-type")}W.set("User-Agent","axios/"+ad,!1);const xe=se(B({},oe),{signal:ie,method:I.toUpperCase(),headers:Um(W.normalize()),body:H,duplex:"half",credentials:k?te:void 0});v=d&&new a(O,xe);let Pe=yield d?Q(v,oe):Q(O,xe);if(Ne){const Se=j.toFiniteNumber(Pe.headers.get("content-length"));if(Se!=null&&Se>de)throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v)}const Oe=T&&(z==="stream"||z==="response");if(T&&Pe.body&&(pe||Ne||Oe&&D)){const Se={};["status","statusText","headers"].forEach(Xn=>{Se[Xn]=Pe[Xn]});const qe=j.toFiniteNumber(Pe.headers.get("content-length")),[ut,pn]=pe&&Km(qe,pu(Qm(pe),!0))||[];let qi=0;const Jr=Xn=>{if(Ne&&(qi=Xn,qi>de))throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v);ut&&ut(Xn)};Pe=new u(e0(Pe.body,t0,Jr,()=>{pn&&pn(),D&&D()}),Se)}z=z||"text";let He=yield x[j.findKey(x,z)||"text"](Pe,A);if(Ne&&!T&&!Oe){let Se;if(He!=null&&(typeof He.byteLength=="number"?Se=He.byteLength:typeof He.size=="number"?Se=He.size:typeof He=="string"&&(Se=typeof r=="function"?new r().encode(He).byteLength:He.length)),typeof Se=="number"&&Se>de)throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v)}return!Oe&&D&&D(),yield new Promise((Se,qe)=>{Gm(Se,qe,{data:He,headers:en.from(Pe.headers),status:Pe.status,statusText:Pe.statusText,config:A,request:v})})}catch(k){if(D&&D(),ie&&ie.aborted&&ie.reason instanceof Ae){const xe=ie.reason;throw xe.config=A,v&&(xe.request=v),k!==xe&&(xe.cause=k),xe}throw k&&k.name==="TypeError"&&/Load failed|fetch/i.test(k.message)?Object.assign(new Ae("Network Error",Ae.ERR_NETWORK,A,v,k&&k.response),{cause:k.cause||k}):Ae.from(k,k&&k.code,A,v,k&&k.response)}})},yS=new Map,r0=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=yS;for(;c--;)d=a[c],h=p.get(d),h===void 0&&p.set(d,h=c?new Map:ES(t)),p=h;return h};r0();const ud={http:$_,xhr:dS,fetch:{get:r0}};j.forEach(ud,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(n){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const i0=e=>`- ${e}`,TS=e=>j.isFunction(e)||e===null||e===!1;function bS(e,t){e=j.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,!TS(r)&&(o=ud[(c=String(r)).toLowerCase()],o===void 0))throw new Ae(`Unknown adapter '${c}'`);if(o&&(j.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[Hm]=this[Hm]={accessors:{}}).accessors,o=this.prototype;function a(u){const c=vs(u);r[c]||(U_(o,u),r[c]=!0)}return j.isArray(t)?t.forEach(a):a(t),this}};en.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),j.reduceDescriptors(en.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),j.freezeMethods(en);const H_="[REDACTED ****]";function z_(e){if(j.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(j.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function j_(e,t){const n=new Set(t.map(a=>String(a).toLowerCase())),r=[],o=a=>{if(a===null||typeof a!="object"||j.isBuffer(a))return a;if(r.indexOf(a)!==-1)return;a instanceof en&&(a=a.toJSON()),r.push(a);let u;if(j.isArray(a))u=[],a.forEach((c,d)=>{const h=o(c);j.isUndefined(h)||(u[d]=h)});else{if(!j.isPlainObject(a)&&z_(a))return r.pop(),a;u=Object.create(null);for(const[c,d]of Object.entries(a)){const h=n.has(c.toLowerCase())?H_:o(d);j.isUndefined(h)||(u[c]=h)}}return r.pop(),u};return o(e)}let Ae=class Ux extends Error{static from(t,n,r,o,a,u){const c=new Ux(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&&j.hasOwnProp(t,"redact")?t.redact:void 0,r=j.isArray(n)&&n.length>0?j_(t,n):j.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}}};Ae.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",Ae.ERR_BAD_OPTION="ERR_BAD_OPTION",Ae.ECONNABORTED="ECONNABORTED",Ae.ETIMEDOUT="ETIMEDOUT",Ae.ECONNREFUSED="ECONNREFUSED",Ae.ERR_NETWORK="ERR_NETWORK",Ae.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",Ae.ERR_DEPRECATED="ERR_DEPRECATED",Ae.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",Ae.ERR_BAD_REQUEST="ERR_BAD_REQUEST",Ae.ERR_CANCELED="ERR_CANCELED",Ae.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",Ae.ERR_INVALID_URL="ERR_INVALID_URL",Ae.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const $_=null;function ed(e){return j.isPlainObject(e)||j.isArray(e)}function zm(e){return j.endsWith(e,"[]")?e.slice(0,-2):e}function td(e,t,n){return e?e.concat(t).map(function(o,a){return o=zm(o),!n&&a?"["+o+"]":o}).join(n?".":""):t}function V_(e){return j.isArray(e)&&!e.some(ed)}const q_=j.toFlatObject(j,{},null,function(t){return/^is[A-Z]/.test(t)});function hu(e,t,n){if(!j.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=j.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(S,A){return!j.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&&j.isSpecCompliantForm(t);if(!j.isFunction(o))throw new TypeError("visitor must be a function");function p(_){if(_===null)return"";if(j.isDate(_))return _.toISOString();if(j.isBoolean(_))return _.toString();if(!h&&j.isBlob(_))throw new Ae("Blob is not supported. Use a Buffer instead.");return j.isArrayBuffer(_)||j.isTypedArray(_)?h&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function E(_,S,A){let O=_;if(j.isReactNative(t)&&j.isReactNativeBlob(_))return t.append(td(A,S,a),p(_)),!1;if(_&&!A&&typeof _=="object"){if(j.endsWith(S,"{}"))S=r?S:S.slice(0,-2),_=JSON.stringify(_);else if(j.isArray(_)&&V_(_)||(j.isFileList(_)||j.endsWith(S,"[]"))&&(O=j.toArray(_)))return S=zm(S),O.forEach(function(z,Y){!(j.isUndefined(z)||z===null)&&t.append(u===!0?td([S],Y,a):u===null?S:S+"[]",p(z))}),!1}return ed(_)?!0:(t.append(td(A,S,a),p(_)),!1)}const b=[],T=Object.assign(q_,{defaultVisitor:E,convertValue:p,isVisitable:ed});function x(_,S,A=0){if(!j.isUndefined(_)){if(A>d)throw new Ae("Object is too deeply nested ("+A+" levels). Max depth: "+d,Ae.ERR_FORM_DATA_DEPTH_EXCEEDED);if(b.indexOf(_)!==-1)throw Error("Circular reference detected in "+S.join("."));b.push(_),j.forEach(_,function(I,z){(!(j.isUndefined(I)||I===null)&&o.call(t,I,j.isString(z)?z.trim():z,S,T))===!0&&x(I,S?S.concat(z):[z],A+1)}),b.pop()}}if(!j.isObject(e))throw new TypeError("data must be an object");return x(e),t}function jm(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function nd(e,t){this._pairs=[],e&&hu(e,this,t)}const $m=nd.prototype;$m.append=function(t,n){this._pairs.push([t,n])},$m.toString=function(t){const n=t?function(r){return t.call(this,r,jm)}:jm;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Y_(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Vm(e,t,n){if(!t)return e;const r=n&&n.encode||Y_,o=j.isFunction(n)?{serialize:n}:n,a=o&&o.serialize;let u;if(a?u=a(t,o):u=j.isURLSearchParams(t)?t.toString():new nd(t,o).toString(r),u){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+u}return e}class qm{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){j.forEach(this.handlers,function(r){r!==null&&t(r)})}}const rd={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},W_={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams!="undefined"?URLSearchParams:nd,FormData:typeof FormData!="undefined"?FormData:null,Blob:typeof Blob!="undefined"?Blob:null},protocols:["http","https","file","blob","url","data"]},id=typeof window!="undefined"&&typeof document!="undefined",od=typeof navigator=="object"&&navigator||void 0,G_=id&&(!od||["ReactNative","NativeScript","NS"].indexOf(od.product)<0),K_=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Q_=id&&window.location.href||"http://localhost",qt=B(B({},Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:id,hasStandardBrowserEnv:G_,hasStandardBrowserWebWorkerEnv:K_,navigator:od,origin:Q_},Symbol.toStringTag,{value:"Module"}))),W_);function X_(e,t){return hu(e,new qt.classes.URLSearchParams,B({visitor:function(n,r,o,a){return qt.isNode&&j.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function J_(e){return j.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Z_(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 Ym(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&&j.isArray(o)?o.length:u,d?(j.hasOwnProp(o,u)?o[u]=j.isArray(o[u])?o[u].concat(r):[o[u],r]:o[u]=r,!c):((!j.hasOwnProp(o,u)||!j.isObject(o[u]))&&(o[u]=[]),t(n,r,o[u],a)&&j.isArray(o[u])&&(o[u]=Z_(o[u])),!c)}if(j.isFormData(e)&&j.isFunction(e.entries)){const n={};return j.forEachEntry(e,(r,o)=>{t(J_(r),o,n,0)}),n}return null}const fo=(e,t)=>e!=null&&j.hasOwnProp(e,t)?e[t]:void 0;function eS(e,t,n){if(j.isString(e))try{return(t||JSON.parse)(e),j.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const As={transitional:rd,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,a=j.isObject(t);if(a&&j.isHTMLForm(t)&&(t=new FormData(t)),j.isFormData(t))return o?JSON.stringify(Ym(t)):t;if(j.isArrayBuffer(t)||j.isBuffer(t)||j.isStream(t)||j.isFile(t)||j.isBlob(t)||j.isReadableStream(t))return t;if(j.isArrayBufferView(t))return t.buffer;if(j.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(a){const d=fo(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return X_(t,d).toString();if((c=j.isFileList(t))||r.indexOf("multipart/form-data")>-1){const h=fo(this,"env"),p=h&&h.FormData;return hu(c?{"files[]":t}:t,p&&new p,d)}}return a||o?(n.setContentType("application/json",!1),eS(t)):t}],transformResponse:[function(t){const n=fo(this,"transitional")||As.transitional,r=n&&n.forcedJSONParsing,o=fo(this,"responseType"),a=o==="json";if(j.isResponse(t)||j.isReadableStream(t))return t;if(t&&j.isString(t)&&(r&&!o||a)){const c=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(t,fo(this,"parseReviver"))}catch(d){if(c)throw d.name==="SyntaxError"?Ae.from(d,Ae.ERR_BAD_RESPONSE,this,null,fo(this,"response")):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:qt.classes.FormData,Blob:qt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};j.forEach(["delete","get","head","post","put","patch","query"],e=>{As.headers[e]={}});function sd(e,t){const n=this||As,r=t||n,o=en.from(r.headers);let a=r.data;return j.forEach(e,function(c){a=c.call(n,a,o.normalize(),t?t.status:void 0)}),o.normalize(),a}function Wm(e){return!!(e&&e.__CANCEL__)}let Cs=class extends Ae{constructor(t,n,r){super(t==null?"canceled":t,Ae.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function Gm(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new Ae("Request failed with status code "+n.status,n.status>=400&&n.status<500?Ae.ERR_BAD_REQUEST:Ae.ERR_BAD_RESPONSE,n.config,n.request,n))}function tS(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function nS(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,b=0;for(;E!==o;)b+=n[E++],E=E%e;if(o=(o+1)%e,o===a&&(a=(a+1)%e),h-u<t)return;const T=p&&h-p;return T?Math.round(b*1e3/T):void 0}}function rS(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 pu=(e,t,n=3)=>{let r=0;const o=nS(50,250);return rS(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)},Km=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Qm=e=>(...t)=>j.asap(()=>e(...t)),iS=qt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,qt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(qt.origin),qt.navigator&&/(msie|trident)/i.test(qt.navigator.userAgent)):()=>!0,oS=qt.hasStandardBrowserEnv?{write(e,t,n,r,o,a,u){if(typeof document=="undefined")return;const c=[`${e}=${encodeURIComponent(t)}`];j.isNumber(n)&&c.push(`expires=${new Date(n).toUTCString()}`),j.isString(r)&&c.push(`path=${r}`),j.isString(o)&&c.push(`domain=${o}`),a===!0&&c.push("secure"),j.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 sS(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function aS(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Xm(e,t,n){let r=!sS(t);return e&&(r||n===!1)?aS(e,t):t}const Jm=e=>e instanceof en?B({},e):e;function _i(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,b){return j.isPlainObject(h)&&j.isPlainObject(p)?j.merge.call({caseless:b},h,p):j.isPlainObject(p)?j.merge({},p):j.isArray(p)?p.slice():p}function o(h,p,E,b){if(j.isUndefined(p)){if(!j.isUndefined(h))return r(void 0,h,E,b)}else return r(h,p,E,b)}function a(h,p){if(!j.isUndefined(p))return r(void 0,p)}function u(h,p){if(j.isUndefined(p)){if(!j.isUndefined(h))return r(void 0,h)}else return r(void 0,p)}function c(h,p,E){if(j.hasOwnProp(t,E))return r(h,p);if(j.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(Jm(h),Jm(p),E,!0)};return j.forEach(Object.keys(B(B({},e),t)),function(p){if(p==="__proto__"||p==="constructor"||p==="prototype")return;const E=j.hasOwnProp(d,p)?d[p]:o,b=j.hasOwnProp(e,p)?e[p]:void 0,T=j.hasOwnProp(t,p)?t[p]:void 0,x=E(b,T,p);j.isUndefined(x)&&E!==c||(n[p]=x)}),n}const uS=["content-type","content-length"];function lS(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,o])=>{uS.includes(r.toLowerCase())&&e.set(r,o)})}const cS=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),Zm=e=>{const t=_i({},e),n=b=>j.hasOwnProp(t,b)?t[b]: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=en.from(c),t.url=Vm(Xm(h,E,p),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?cS(d.password):""))),j.isFormData(r)&&(qt.hasStandardBrowserEnv||qt.hasStandardBrowserWebWorkerEnv?c.setContentType(void 0):j.isFunction(r.getHeaders)&&lS(c,r.getHeaders(),n("formDataHeaderPolicy"))),qt.hasStandardBrowserEnv&&(j.isFunction(o)&&(o=o(t)),o===!0||o==null&&iS(t.url))){const T=a&&u&&oS.read(u);T&&c.set(a,T)}return t},dS=typeof XMLHttpRequest!="undefined"&&function(e){return new Promise(function(n,r){const o=Zm(e);let a=o.data;const u=en.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:h}=o,p,E,b,T,x;function _(){T&&T(),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 I=en.from("getAllResponseHeaders"in S&&S.getAllResponseHeaders()),Y={data:!c||c==="text"||c==="json"?S.responseText:S.response,status:S.status,statusText:S.statusText,headers:I,config:e,request:S};Gm(function(Q){n(Q),_()},function(Q){r(Q),_()},Y),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 Ae("Request aborted",Ae.ECONNABORTED,e,S)),_(),S=null)},S.onerror=function(z){const Y=z&&z.message?z.message:"Network Error",M=new Ae(Y,Ae.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 Y=o.transitional||rd;o.timeoutErrorMessage&&(z=o.timeoutErrorMessage),r(new Ae(z,Y.clarifyTimeoutError?Ae.ETIMEDOUT:Ae.ECONNABORTED,e,S)),_(),S=null},a===void 0&&u.setContentType(null),"setRequestHeader"in S&&j.forEach(Um(u),function(z,Y){S.setRequestHeader(Y,z)}),j.isUndefined(o.withCredentials)||(S.withCredentials=!!o.withCredentials),c&&c!=="json"&&(S.responseType=o.responseType),h&&([b,x]=pu(h,!0),S.addEventListener("progress",b)),d&&S.upload&&([E,T]=pu(d),S.upload.addEventListener("progress",E),S.upload.addEventListener("loadend",T)),(o.cancelToken||o.signal)&&(p=I=>{S&&(r(!I||I.type?new Cs(null,e,S):I),S.abort(),_(),S=null)},o.cancelToken&&o.cancelToken.subscribe(p),o.signal&&(o.signal.aborted?p():o.signal.addEventListener("abort",p)));const O=tS(o.url);if(O&&!qt.protocols.includes(O)){r(new Ae("Unsupported protocol "+O+":",Ae.ERR_BAD_REQUEST,e));return}S.send(a||null)})},fS=(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 Ae?h:new Cs(h instanceof Error?h.message:h))}};let a=t&&setTimeout(()=>{a=null,o(new Ae(`timeout of ${t}ms exceeded`,Ae.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=()=>j.asap(u),c},hS=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},pS=function(e,t){return om(this,null,function*(){try{for(var n=Bx(mS(e)),r,o,a;r=!(o=yield new so(n.next())).done;r=!1){const u=o.value;yield*sm(hS(u,t))}}catch(o){a=[o]}finally{try{r&&(o=n.return)&&(yield new so(o.call(n)))}finally{if(a)throw a[0]}}})},mS=function(e){return om(this,null,function*(){if(e[Symbol.asyncIterator]){yield*sm(e);return}const t=e.getReader();try{for(;;){const{done:n,value:r}=yield new so(t.read());if(n)break;yield r}}finally{yield new so(t.cancel())}})},e0=(e,t,n,r)=>{const o=pS(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 b=E.byteLength;if(n){let T=a+=b;n(T)}h.enqueue(new Uint8Array(E))}catch(p){throw c(p),p}})},cancel(h){return c(h),o.return()}},{highWaterMark:2})};function gS(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 T=0;T<c;T++)if(r.charCodeAt(T)===37&&T+2<c){const x=r.charCodeAt(T+1),_=r.charCodeAt(T+2);(x>=48&&x<=57||x>=65&&x<=70||x>=97&&x<=102)&&(_>=48&&_<=57||_>=65&&_<=70||_>=97&&_<=102)&&(u-=2,T+=2)}let d=0,h=c-1;const p=T=>T>=2&&r.charCodeAt(T-2)===37&&r.charCodeAt(T-1)===51&&(r.charCodeAt(T)===68||r.charCodeAt(T)===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 b=Math.floor(u/4)*3-(d||0);return b>0?b: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 ad="1.16.1",t0=64*1024,{isFunction:mu}=j,n0=(e,...t)=>{try{return!!e(...t)}catch(n){return!1}},ES=e=>{const t=j.global!==void 0&&j.global!==null?j.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=j.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:o,Request:a,Response:u}=e,c=o?mu(o):typeof fetch=="function",d=mu(a),h=mu(u);if(!c)return!1;const p=c&&mu(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())})),b=d&&p&&n0(()=>{let A=!1;const O=new a(qt.origin,{body:new n,method:"POST",get duplex(){return A=!0,"half"}}),I=O.headers.has("Content-Type");return O.body!=null&&O.body.cancel(),A&&!I}),T=h&&p&&n0(()=>j.isReadableStream(new u("").body)),x={stream:T&&(A=>A.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(A=>{!x[A]&&(x[A]=(O,I)=>{let z=O&&O[A];if(z)return z.call(O);throw new Ae(`Response type '${A}' is not supported`,Ae.ERR_NOT_SUPPORT,I)})});const _=A=>$e(null,null,function*(){if(A==null)return 0;if(j.isBlob(A))return A.size;if(j.isSpecCompliantForm(A))return(yield new a(qt.origin,{method:"POST",body:A}).arrayBuffer()).byteLength;if(j.isArrayBufferView(A)||j.isArrayBuffer(A))return A.byteLength;if(j.isURLSearchParams(A)&&(A=A+""),j.isString(A))return(yield E(A)).byteLength}),S=(A,O)=>$e(null,null,function*(){const I=j.toFiniteNumber(A.getContentLength());return I==null?_(O):I});return A=>$e(null,null,function*(){let{url:O,method:I,data:z,signal:Y,cancelToken:M,timeout:Q,onDownloadProgress:Ee,onUploadProgress:re,responseType:U,headers:W,withCredentials:te="same-origin",fetchOptions:oe,maxContentLength:de,maxBodyLength:be}=Zm(A);const Ie=j.isNumber(de)&&de>-1,he=j.isNumber(be)&&be>-1;let G=o||fetch;U=U?(U+"").toLowerCase():"text";let ie=fS([Y,M&&M.toAbortSignal()],Q),v=null;const D=ie&&ie.unsubscribe&&(()=>{ie.unsubscribe()});let Z;try{if(Ie&&typeof O=="string"&&O.startsWith("data:")&&gS(O)>de)throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v);if(he&&I!=="get"&&I!=="head"){const Se=yield S(W,z);if(typeof Se=="number"&&isFinite(Se)&&Se>be)throw new Ae("Request body larger than maxBodyLength limit",Ae.ERR_BAD_REQUEST,A,v)}if(re&&b&&I!=="get"&&I!=="head"&&(Z=yield S(W,z))!==0){let Se=new a(O,{method:"POST",body:z,duplex:"half"}),qe;if(j.isFormData(z)&&(qe=Se.headers.get("content-type"))&&W.setContentType(qe),Se.body){const[ut,pn]=Km(Z,pu(Qm(re)));z=e0(Se.body,t0,ut,pn)}}j.isString(te)||(te=te?"include":"omit");const k=d&&"credentials"in a.prototype;if(j.isFormData(z)){const Se=W.getContentType();Se&&/^multipart\/form-data/i.test(Se)&&!/boundary=/i.test(Se)&&W.delete("content-type")}W.set("User-Agent","axios/"+ad,!1);const xe=se(B({},oe),{signal:ie,method:I.toUpperCase(),headers:Um(W.normalize()),body:z,duplex:"half",credentials:k?te:void 0});v=d&&new a(O,xe);let Pe=yield d?G(v,oe):G(O,xe);if(Ie){const Se=j.toFiniteNumber(Pe.headers.get("content-length"));if(Se!=null&&Se>de)throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v)}const Ne=T&&(U==="stream"||U==="response");if(T&&Pe.body&&(Ee||Ie||Ne&&D)){const Se={};["status","statusText","headers"].forEach(Xn=>{Se[Xn]=Pe[Xn]});const qe=j.toFiniteNumber(Pe.headers.get("content-length")),[ut,pn]=Ee&&Km(qe,pu(Qm(Ee),!0))||[];let qi=0;const Jr=Xn=>{if(Ie&&(qi=Xn,qi>de))throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v);ut&&ut(Xn)};Pe=new u(e0(Pe.body,t0,Jr,()=>{pn&&pn(),D&&D()}),Se)}U=U||"text";let He=yield x[j.findKey(x,U)||"text"](Pe,A);if(Ie&&!T&&!Ne){let Se;if(He!=null&&(typeof He.byteLength=="number"?Se=He.byteLength:typeof He.size=="number"?Se=He.size:typeof He=="string"&&(Se=typeof r=="function"?new r().encode(He).byteLength:He.length)),typeof Se=="number"&&Se>de)throw new Ae("maxContentLength size of "+de+" exceeded",Ae.ERR_BAD_RESPONSE,A,v)}return!Ne&&D&&D(),yield new Promise((Se,qe)=>{Gm(Se,qe,{data:He,headers:en.from(Pe.headers),status:Pe.status,statusText:Pe.statusText,config:A,request:v})})}catch(k){if(D&&D(),ie&&ie.aborted&&ie.reason instanceof Ae){const xe=ie.reason;throw xe.config=A,v&&(xe.request=v),k!==xe&&(xe.cause=k),xe}throw k&&k.name==="TypeError"&&/Load failed|fetch/i.test(k.message)?Object.assign(new Ae("Network Error",Ae.ERR_NETWORK,A,v,k&&k.response),{cause:k.cause||k}):Ae.from(k,k&&k.code,A,v,k&&k.response)}})},yS=new Map,r0=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=yS;for(;c--;)d=a[c],h=p.get(d),h===void 0&&p.set(d,h=c?new Map:ES(t)),p=h;return h};r0();const ud={http:$_,xhr:dS,fetch:{get:r0}};j.forEach(ud,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(n){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const i0=e=>`- ${e}`,TS=e=>j.isFunction(e)||e===null||e===!1;function bS(e,t){e=j.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,!TS(r)&&(o=ud[(c=String(r)).toLowerCase()],o===void 0))throw new Ae(`Unknown adapter '${c}'`);if(o&&(j.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(i0).join(`
|
|
12
12
|
`):" "+i0(u[0]):"as no adapter specified";throw new Ae("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return o}const o0={getAdapter:bS,adapters:ud};function ld(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Cs(null,e)}function s0(e){return ld(e),e.headers=en.from(e.headers),e.data=sd.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),o0.getAdapter(e.adapter||As.adapter,e)(e).then(function(r){ld(e),e.response=r;try{r.data=sd.call(e,e.transformResponse,r)}finally{delete e.response}return r.headers=en.from(r.headers),r},function(r){if(!Wm(r)&&(ld(e),r&&r.response)){e.response=r.response;try{r.response.data=sd.call(e,e.transformResponse,r.response)}finally{delete e.response}r.response.headers=en.from(r.response.headers)}return Promise.reject(r)})}const gu={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{gu[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const a0={};gu.transitional=function(t,n,r){function o(a,u){return"[Axios v"+ad+"] Transitional option '"+a+"'"+u+(r?". "+r:"")}return(a,u,c)=>{if(t===!1)throw new Ae(o(u," has been removed"+(n?" in "+n:"")),Ae.ERR_DEPRECATED);return n&&!a0[u]&&(a0[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}},gu.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function xS(e,t,n){if(typeof e!="object")throw new Ae("options must be an object",Ae.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 Ae("option "+a+" must be "+d,Ae.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new Ae("Unknown option "+a,Ae.ERR_BAD_OPTION)}}const Eu={assertOptions:xS,validators:gu},In=Eu.validators;let Si=class{constructor(t){this.defaults=t||{},this.interceptors={request:new qm,response:new qm}}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=_i(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&Eu.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&&(j.isFunction(o)?n.paramsSerializer={serialize:o}:Eu.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),Eu.assertOptions(n,{baseUrl:In.spelling("baseURL"),withXsrfToken:In.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&j.merge(a.common,a[n.method]);a&&j.forEach(["delete","get","head","post","put","patch","query","common"],x=>{delete a[x]}),n.headers=en.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||rd;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,b;if(!d){const x=[s0.bind(this),void 0];for(x.unshift(...c),x.push(...h),b=x.length,p=Promise.resolve(n);E<b;)p=p.then(x[E++],x[E++]);return p}b=c.length;let T=n;for(;E<b;){const x=c[E++],_=c[E++];try{T=x(T)}catch(S){_.call(this,S);break}}try{p=s0.call(this,T)}catch(x){return Promise.reject(x)}for(E=0,b=h.length;E<b;)p=p.then(h[E++],h[E++]);return p}getUri(t){t=_i(this.defaults,t);const n=Xm(t.baseURL,t.url,t.allowAbsoluteUrls);return Vm(n,t.params,t.paramsSerializer)}};j.forEach(["delete","get","head","options"],function(t){Si.prototype[t]=function(n,r){return this.request(_i(r||{},{method:t,url:n,data:(r||{}).data}))}}),j.forEach(["post","put","patch","query"],function(t){function n(r){return function(a,u,c){return this.request(_i(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 wS=class Hx{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const u=new Promise(c=>{r.subscribe(c),a=c}).then(o);return u.cancel=function(){r.unsubscribe(a)},u},t(function(a,u,c){r.reason||(r.reason=new Cs(a,u,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Hx(function(o){t=o}),cancel:t}}};function _S(e){return function(n){return e.apply(null,n)}}function SS(e){return j.isObject(e)&&e.isAxiosError===!0}const cd={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(cd).forEach(([e,t])=>{cd[t]=e});function u0(e){const t=new Si(e),n=Nm(Si.prototype.request,t);return j.extend(n,Si.prototype,t,{allOwnKeys:!0}),j.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return u0(_i(e,o))},n}const bt=u0(As);bt.Axios=Si,bt.CanceledError=Cs,bt.CancelToken=wS,bt.isCancel=Wm,bt.VERSION=ad,bt.toFormData=hu,bt.AxiosError=Ae,bt.Cancel=bt.CanceledError,bt.all=function(t){return Promise.all(t)},bt.spread=_S,bt.isAxiosError=SS,bt.mergeConfig=_i,bt.AxiosHeaders=en,bt.formToJSON=e=>Ym(j.isHTMLForm(e)?new FormData(e):e),bt.getAdapter=o0.getAdapter,bt.HttpStatusCode=cd,bt.default=bt;const{Axios:mF,AxiosError:gF,CanceledError:EF,isCancel:yF,CancelToken:TF,VERSION:bF,all:xF,Cancel:wF,isAxiosError:_F,spread:SF,toFormData:vF,AxiosHeaders:AF,HttpStatusCode:CF,formToJSON:kF,getAdapter:NF,mergeConfig:OF,create:IF}=bt;class vS{constructor(t,n,r,o=!1){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 bt.get(`${this.apiUrl}/configs/copilot`,{headers:this.headers}),{customer_config:n}=t.data,r=atob(n);return JSON.parse(r)}catch(t){throw console.error("Error fetching customer config:",t),t}}));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}`),this.baseApiUrl=this._mapCopilotUrlToSearchUrl(t,o)}get apiUrl(){return`${this.baseApiUrl}/${this.CIMULATE_SEARCH_API_PATH}`}}class AS{constructor(t,n,r,o=!1){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 vS(t,n,r,o)}getPriceDisplay(t){const n=this.getPrice(t);return n?typeof n=="string"?n.includes("$")?n:`$${n}`:typeof n=="number"?new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}).format(n):n:""}}const vi=(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 CS{constructor(t=!1){Ze(this,"isDevelopment");Ze(this,"_log",(t,n,...r)=>{vi(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 kS={copilot:"Your Search Assistant",messaging:"Commerce Client"},l0=X.createContext(null),NS=({mode:e,logoUrl:t,headerText:n="Your Search Assistant",headerConfig:r,globalClassName:o="",entryMessage:a,openLinksInNewTab:u=!1,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,searchPlaceholder:p,searchButtonLabel:E,searchConfig:b,componentConfig:T,conversationHistory:x,resetConversationMessage:_="",apiKey:S,apiToken:A,baseUrl:O,theme:I,isDevelopment:H,__features:Y,children:M})=>{const G=e==="messaging",pe=X.useMemo(()=>G?{config:null}:new AS(O,S,A,H),[G,O,S,A,H]),re=X.useMemo(()=>new CS(H),[H]);X.useEffect(()=>{G||!pe||pe.config||pe.getConfig()},[pe,G]);const z=X.useMemo(()=>zw(I),[I]),W=X.useMemo(()=>{const de=(b==null?void 0:b.placeholder)||p,be=(b==null?void 0:b.buttonLabel)||E;let Ne="icon";return b!=null&&b.buttonType?Ne=b.buttonType:E&&(Ne="text"),se(B({},b||{}),{placeholder:de,buttonLabel:be,buttonType:Ne})},[b,p,E]),te=X.useMemo(()=>se(B({},r||{}),{logoUrl:t||(r==null?void 0:r.logoUrl),headerText:n||kS[e!=null?e:"copilot"]}),[r,t,n,e]),oe=X.useMemo(()=>({configModule:pe,mode:e!=null?e:"copilot",headerConfig:te,entryMessage:a,globalClassName:o,openLinksInNewTab:u,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,themeVariables:z,logger:re,searchConfig:W,enableMinimize:!!(T!=null&&T.enableMinimize),resetConversationMessage:_,conversationHistory:{sinceHours:typeof(x==null?void 0:x.sinceHours)=="number"?x.sinceHours:1,limit:x==null?void 0:x.limit},features:Y}),[pe,e,te,a,o,h,c,d,u,W,T,_,re,z,x,Y]);return P.jsx(l0.Provider,{value:oe,children:M})},kt=()=>{const e=X.useContext(l0);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e},c0={connectionStatus:"disconnected",loading:!0,conversationId:null,messages:[],streamingContent:"",isAgentTyping:!1,progressMessage:"",routingResult:null,error:null};function OS(e,t){switch(t.type){case"SET_CONNECTION_STATUS":return B(se(B({},e),{connectionStatus:t.status}),t.status==="connected"||t.status==="connecting"?{error:null}:{});case"SET_LOADING":return se(B({},e),{loading:t.isLoading});case"SET_CONVERSATION_ID":return se(B({},e),{conversationId:t.id});case"ADD_MESSAGE":return se(B({},e),{messages:[...e.messages,se(B({},t.message),{type:"ADD_MESSAGE"})]});case"APPEND_STREAMING_TOKEN":return se(B({},e),{streamingContent:e.streamingContent+t.token});case"FLUSH_STREAMING":return se(B({},e),{messages:[...e.messages,se(B({},t.message),{type:"FLUSH_STREAMING"})],streamingContent:"",isAgentTyping:!1,loading:!1,progressMessage:""});case"SET_AGENT_TYPING":return se(B({},e),{isAgentTyping:t.isTyping,loading:t.isTyping});case"SET_PROGRESS_MESSAGE":return se(B({},e),{progressMessage:t.message});case"SET_ROUTING_RESULT":return se(B({},e),{routingResult:t.result});case"SET_ERROR":return se(B({},e),{error:t.error,loading:!1,progressMessage:""});case"LOAD_HISTORY":return se(B({},e),{messages:t.messages,loading:!1});case"RESET":return se(B({},c0),{connectionStatus:e.connectionStatus,loading:!0});default:return e}}const d0=X.createContext({connectionStatus:"disconnected",isConnected:!1,isAgentTyping:!1,conversationId:null,messages:[],streamingContent:"",progressMessage:"",loading:!0,error:null,sendMessage:()=>{},resetConversation:()=>{}});function dd(e,t){return`cim_af_conv_${e}_${t}`}function fd(e,t){return Date.now()-e>t}function IS(e,t,n){try{const r=dd(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"||fd(u.storedAt,n)?(sessionStorage.removeItem(r),null):u}catch(r){return null}}function ks(e,t,n){try{const r=dd(e,t),o={conversationId:n,storedAt:Date.now()};sessionStorage.setItem(r,JSON.stringify(o))}catch(r){}}function yu(e,t){try{const n=dd(e,t);sessionStorage.removeItem(n)}catch(n){}}function hd(e,t){return`cim_af_ct_${e}_${t}`}function f0(e,t,n){try{const r=hd(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 RS(e,t,n,r){try{const o=hd(e,t),a={accessToken:n,lastEventId:r,storedAt:Date.now()};sessionStorage.setItem(o,JSON.stringify(a))}catch(o){}}function PS(e,t){try{const n=hd(e,t);sessionStorage.removeItem(n)}catch(n){}}function LS(e,t){return`cim_af_conv_${e}_${t}`}function DS(e,t){try{if(typeof BroadcastChannel=="undefined")return null;const n=LS(e,t);return new BroadcastChannel(n)}catch(n){return null}}function MS(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 FS(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 BS(e){if(e)try{e.postMessage({type:"conversation_cleared"})}catch(t){}}function US(e){if(e)try{e.close()}catch(t){}}function HS(e){switch(e){case"EndUser":case"Customer":return"user";case"Agent":case"Chatbot":return"agent";default:return"system"}}function zS(e){if(!e)return{};if(typeof e=="string")try{return JSON.parse(e)}catch(t){return{}}return e}function h0(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 jS(e){if(e.entryType!=="Message")return null;const n=zS(e.entryPayload).abstractMessage;if(!n)return null;const r=h0(n,"staticContent","text")||h0(n,"content","text")||"";if(!r)return null;const o=HS(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 $S(e){const t=[];for(const n of e){const r=jS(n);r&&t.push(r)}return t}function VS(e){const{orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:o}=e,a=X.useRef(null),u=X.useRef(null),c=X.useRef(null),d=o.sinceHours*60*60*1e3,h=X.useCallback(()=>(c.current||(c.current=MS(a.current)),c.current),[]);X.useEffect(()=>{const S=DS(t,n);a.current=S,c.current=null;const A=FS(S,()=>{const O=u.current;if(!O)return null;const I=f0(t,n,d);return{conversationId:O,continuationToken:I==null?void 0:I.accessToken,lastEventId:I==null?void 0:I.lastEventId}},()=>{yu(t,n),u.current=null});return()=>{A(),US(S),a.current=null}},[t,n,d]);const p=X.useCallback(S=>$e(null,null,function*(){let A=IS(t,n,d);if(!A){const O=yield h();O&&!fd(O.storedAt,d)&&(A=O)}if(!A){const O=yield S.createConversation(r);return ks(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(M=>M.conversationId===A.conversationId&&!M.isConversationClosed);if(!H){yu(t,n);const M=yield S.createConversation(r);return ks(t,n,M),u.current=M,{conversationId:M,restoredMessages:[],resumed:!1}}S.resumeConversation(H.conversationId),u.current=H.conversationId,ks(t,n,H.conversationId);let Y=[];try{const M=yield S.listConversationEntries(H.conversationId,{limit:o.limit,startTimestamp:O,direction:"FromStart"});Y=$S(M.conversationEntries)}catch(M){}return{conversationId:H.conversationId,restoredMessages:Y,resumed:!0}}catch(O){yu(t,n);const I=yield S.createConversation(r);return ks(t,n,I),u.current=I,{conversationId:I,restoredMessages:[],resumed:!1}}}),[t,n,r,o,d,h]),E=X.useCallback(S=>{ks(t,n,S),u.current=S},[t,n]),b=X.useCallback(()=>{yu(t,n),PS(t,n),BS(a.current),u.current=null},[t,n]),T=X.useCallback(()=>{const S=f0(t,n,d);return S?{continuationToken:S.accessToken,lastEventId:S.lastEventId}:null},[t,n,d]),x=X.useCallback(()=>$e(null,null,function*(){const S=yield h();return!(S!=null&&S.continuationToken)||fd(S.storedAt,d)?null:{continuationToken:S.continuationToken,lastEventId:S.lastEventId}}),[d,h]),_=X.useCallback(S=>$e(null,null,function*(){try{const{accessToken:A,lastEventId:O}=yield S.generateContinuationToken();RS(t,n,A,O)}catch(A){}}),[t,n]);return{initializeConversation:p,persistConversationId:E,clearPersistedConversation:b,getStoredConnectOptions:T,getPeerConnectOptions:x,persistContinuationToken:_}}const qS="Your session ended due to inactivity. Starting a new session…";function YS(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 p0=({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}=kt(),[b,T]=X.useReducer(OS,c0),x=VS({orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:E}),_=X.useRef(null),S=X.useRef(c),A=X.useRef(d),O=X.useRef(u),I=X.useRef(!1);S.current=c,A.current=d,O.current=u,X.useEffect(()=>{const re=new Hw({baseURL:e,orgId:t,esDeveloperName:n,options:B({enableLogging:a},o?{capabilitiesVersion:o}:{})});return _.current=re,re.on("connected",()=>{var W;T({type:"SET_CONNECTION_STATUS",status:"connected"}),(W=O.current)==null||W.call(O)}),re.on("disconnected",()=>{T({type:"SET_CONNECTION_STATUS",status:"disconnected"})}),re.on("reconnecting",()=>{T({type:"SET_CONNECTION_STATUS",status:"reconnecting"})}),re.on("message",W=>{var oe;const te={id:W.messageId||crypto.randomUUID(),role:"agent",content:W.content,timestamp:W.timestamp,sender:W.sender,raw:W};T({type:"FLUSH_STREAMING",message:te}),(oe=S.current)==null||oe.call(S,te)}),re.on("streaming_token",W=>{T({type:"APPEND_STREAMING_TOKEN",token:W.token})}),re.on("typing_started",()=>{T({type:"SET_AGENT_TYPING",isTyping:!0})}),re.on("typing_stopped",()=>{T({type:"SET_AGENT_TYPING",isTyping:!1})}),re.on("progress_indicator",W=>{T({type:"SET_PROGRESS_MESSAGE",message:W.message})}),re.on("routing_result",W=>{var te;if(T({type:"SET_ROUTING_RESULT",result:W}),!W.isSuccessful){const oe=`Routing failed: ${W.failureType||"unknown"}`;T({type:"SET_ERROR",error:oe}),(te=A.current)==null||te.call(A,oe)}}),re.on("participant_changed",W=>{if(W.participant.name==="Automated Process")return;const te={id:crypto.randomUUID(),role:"system",content:W.action==="add"?`${W.participant.name||"Agent"} joined the conversation`:`${W.participant.name||"Agent"} left the conversation`,timestamp:new Date().toISOString()};p==null||p.log("🦜 MessagingProvider participant_changed event received",{event:W}),T({type:"ADD_MESSAGE",message:te})}),re.on("conversation_closed",()=>{const W={id:crypto.randomUUID(),role:"system",content:"Conversation reset",timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:W}),T({type:"SET_CONVERSATION_ID",id:null}),x.clearPersistedConversation()}),re.on("error",W=>{var te;p==null||p.log("🦜 MessagingProvider ERROR event received",{event:W}),T({type:"SET_ERROR",error:W.message}),W.recoverable||T({type:"SET_CONNECTION_STATUS",status:"error"}),(te=A.current)==null||te.call(A,W.message)}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),$e(null,null,function*(){let W=x.getStoredConnectOptions(),te=!1;W||(W=yield x.getPeerConnectOptions(),te=!!W);try{yield re.connect(W!=null?W:void 0)}catch(de){if(W)p==null||p.log("Continuation token failed, falling back to fresh connect"),te||x.clearPersistedConversation(),yield re.connect();else throw de}yield x.persistContinuationToken(re);const oe=yield x.initializeConversation(re);T({type:"SET_CONVERSATION_ID",id:oe.conversationId}),oe.resumed&&oe.restoredMessages.length>0&&T({type:"LOAD_HISTORY",messages:oe.restoredMessages})}).catch(W=>{var te;T({type:"SET_CONNECTION_STATUS",status:"error"}),T({type:"SET_ERROR",error:W.message}),(te=A.current)==null||te.call(A,W.message)}),()=>{re.disconnect(),re.off(),_.current=null}},[e,t,n,o]);const H=X.useCallback(re=>$e(null,null,function*(){var W;const z=_.current;if(!(!z||I.current)){I.current=!0,T({type:"ADD_MESSAGE",message:{id:crypto.randomUUID(),role:"system",content:qS,timestamp:new Date().toISOString()}}),x.clearPersistedConversation(),T({type:"SET_CONNECTION_STATUS",status:"connecting"});try{z.disconnect(),yield z.connect(),yield x.persistContinuationToken(z);const te=yield z.createConversation(r);T({type:"SET_CONVERSATION_ID",id:te}),T({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(te),re&&(T({type:"SET_LOADING",isLoading:!0}),T({type:"SET_PROGRESS_MESSAGE",message:""}),yield z.sendMessage(re))}catch(te){const oe=te instanceof Error?te.message:String(te);T({type:"SET_ERROR",error:oe}),T({type:"SET_CONNECTION_STATUS",status:"error"}),(W=A.current)==null||W.call(A,oe)}finally{I.current=!1}}}),[r,x]),Y=X.useRef(H);Y.current=H;const M=X.useCallback(re=>{if(!re.trim())return;const z=_.current;if(!z)return;const W={id:crypto.randomUUID(),role:"user",content:re,timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:W}),T({type:"SET_LOADING",isLoading:!0}),T({type:"SET_PROGRESS_MESSAGE",message:""}),z.sendMessage(re).catch(te=>{var oe;if(YS(te)){Y.current(re);return}T({type:"SET_ERROR",error:te.message}),(oe=A.current)==null||oe.call(A,te.message)})},[]),G=X.useCallback(()=>{const re=_.current;re&&(x.clearPersistedConversation(),T({type:"RESET"}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),re.endConversation().then(()=>(re.disconnect(),re.connect())).then(()=>$e(null,null,function*(){return yield x.persistContinuationToken(re),re.createConversation(r)})).then(z=>{T({type:"SET_CONVERSATION_ID",id:z}),T({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(z)}).catch(z=>{var W;T({type:"SET_ERROR",error:z.message}),T({type:"SET_CONNECTION_STATUS",status:"error"}),(W=A.current)==null||W.call(A,z.message)}))},[r,x]),pe=X.useMemo(()=>({connectionStatus:b.connectionStatus,isConnected:b.connectionStatus==="connected",isAgentTyping:b.isAgentTyping,conversationId:b.conversationId,messages:b.messages,streamingContent:b.streamingContent,progressMessage:b.progressMessage,error:b.error,loading:b.loading,sendMessage:M,resetConversation:G}),[b,M,G]);return P.jsx(d0.Provider,{value:pe,children:h})};function WS(){var e=X.useRef(!0);return e.current?(e.current=!1,!0):e.current}function GS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.addEventListener&&e.addEventListener.apply(e,t)}function KS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.removeEventListener&&e.removeEventListener.apply(e,t)}var pd=typeof window!="undefined",Tu=function(e){X.useEffect(e,[])},QS=function(e){var t=X.useRef(e);t.current=e,Tu(function(){return function(){return t.current()}})},XS=function(e){var t=X.useRef(0),n=X.useState(e),r=n[0],o=n[1],a=X.useCallback(function(u){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(u)})},[]);return QS(function(){cancelAnimationFrame(t.current)}),[r,a]},JS=function(e,t){return e===t};function ZS(e,t){t===void 0&&(t=JS);var n=X.useRef(),r=X.useRef(e),o=WS();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var ev=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=XS({width:pd?window.innerWidth:r,height:pd?window.innerHeight:a}),d=c[0],h=c[1];return X.useEffect(function(){if(pd){var p=function(){var E=window.innerWidth,b=window.innerHeight;h({width:E,height:b}),u&&u(E,b)};return GS(window,"resize",p),function(){KS(window,"resize",p)}}},[]),d};const md="cimulate:ui-state-update",tv=e=>{window.addEventListener(md,e)},nv=e=>{window.removeEventListener(md,e)},rv=(e,t)=>{const n=new CustomEvent(md,{detail:{property:e,value:t}});window.dispatchEvent(n)},m0=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},Ai=e=>{const t=tt.statusProxy.isOpen,n=typeof e=="boolean"?e:!t;tt.statusProxy.isOpen=n,n&&(tt.statusProxy.isMinimized=!1)},bu=e=>{const t=tt.statusProxy.isMinimized,n=typeof e=="boolean"?e:!t;tt.statusProxy.isMinimized=n,n&&(tt.statusProxy.isOpen=!1)},gd=e=>{tt.modalProxy.isFullscreen=e},xu=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"},Ed=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},iv=e=>{const t=tt.dialogProxy.isFullHeight,n=typeof e=="boolean"?e:!t;tt.dialogProxy.isFullHeight=n};class ov{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 rv(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 ov,g0=X.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}),sv=({entryType:e,componentConfig:t,componentType:n,children:r})=>{const[o,a]=X.useState(e!=null?e:tt.entryTypeProxy.entryType),[u,c]=X.useState(tt.modeProxy.mode),[d,h]=X.useState({type:n||tt.statusProxy.type,isOpen:tt.statusProxy.isOpen,isMinimized:tt.statusProxy.isMinimized}),[p,E]=X.useState(tt.dialogProxy.position),[b,T]=X.useState(tt.dialogProxy.isFullHeight),[x,_]=X.useState(tt.dialogProxy.width),[S,A]=X.useState(tt.modalProxy.isFullscreen),O=ZS(d.type);X.useEffect(()=>{const H=Y=>{const{property:M,value:G}=Y.detail||{};if(!(!M||G===void 0)){if(M==="mode"){c(G);return}if(M==="entryType"){a(G);return}if(M==="isMinimized"){h(pe=>se(B({},pe),{isMinimized:G}));return}if(M==="isOpen"){h(pe=>se(B({},pe),{isOpen:G}));return}if(M==="type"){h(pe=>se(B({},pe),{type:G}));return}if(M==="position"){E(G);return}if(M==="isFullHeight"){T(G);return}if(M==="width"){_(G);return}if(M==="isFullscreen"){A(G);return}}};return tv(H),()=>{nv(H)}},[]),Tu(()=>{e&&m0(e)}),Tu(()=>{const H=n||(t==null?void 0:t.type);H&&xu(H),t&&"isOpen"in t&&Ai(!!t.isOpen),t&&"isMinimized"in t&&bu(!!t.isMinimized)}),Tu(()=>{if(!(t!=null&&t.options))return;const{dialogPosition:H}=t.options;H&&Ed(H),"dialogFullHeight"in t.options&&iv(!!t.options.dialogFullHeight),"dialogWidth"in t.options&&t.options.dialogWidth&&_(t.options.dialogWidth),"isModalFullscreen"in t.options&&gd(!!t.options.isModalFullscreen)});const I=X.useMemo(()=>({mode:u,entryType:o,status:d,previousComponentType:O||"dialog",dialogPosition:p,isDialogFullHeight:b,dialogWidth:x,isModalFullscreen:S}),[u,o,d,O,p,b,x,S]);return P.jsx(g0.Provider,{value:I,children:r})},E0=({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:b,entryType:T,entryMessage:x,disclaimerText:_,disclaimerMarkdown:S,clientContext:A,searchPlaceholder:O,searchButtonLabel:I,searchConfig:H,resetConversationMessage:Y,conversationHistory:M,messagingConfig:G,__features:pe,children:re})=>P.jsx(NS,{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:I,searchConfig:H,componentConfig:b,clientContext:A,disclaimerMarkdown:S,disclaimerText:_,resetConversationMessage:Y,conversationHistory:M,isDevelopment:p,__features:pe,children:P.jsx(sv,{entryType:T,componentConfig:b,componentType:E,children:P.jsx(p0,{scrt2Url:(G==null?void 0:G.scrt2Url)||"",orgId:(G==null?void 0:G.orgId)||"",esDeveloperName:(G==null?void 0:G.esDeveloperName)||"",routingAttributes:(G==null?void 0:G.routingAttributes)||{},capabilitiesVersion:G==null?void 0:G.capabilitiesVersion,enableLogging:p,children:re})})}),Ci=()=>{const e=X.useContext(g0);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};var yd={exports:{}},ln={},Td={exports:{}},bd={};var y0;function av(){return y0||(y0=1,(function(e){function t(Q,ie){var v=Q.length;Q.push(ie);e:for(;0<v;){var D=v-1>>>1,Z=Q[D];if(0<o(Z,ie))Q[D]=ie,Q[v]=Z,v=D;else break e}}function n(Q){return Q.length===0?null:Q[0]}function r(Q){if(Q.length===0)return null;var ie=Q[0],v=Q.pop();if(v!==ie){Q[0]=v;e:for(var D=0,Z=Q.length,k=Z>>>1;D<k;){var xe=2*(D+1)-1,Pe=Q[xe],Oe=xe+1,He=Q[Oe];if(0>o(Pe,v))Oe<Z&&0>o(He,Pe)?(Q[D]=He,Q[Oe]=v,D=Oe):(Q[D]=Pe,Q[xe]=v,D=xe);else if(Oe<Z&&0>o(He,v))Q[D]=He,Q[Oe]=v,D=Oe;else break e}}return ie}function o(Q,ie){var v=Q.sortIndex-ie.sortIndex;return v!==0?v:Q.id-ie.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,b=3,T=!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 I(Q){for(var ie=n(h);ie!==null;){if(ie.callback===null)r(h);else if(ie.startTime<=Q)r(h),ie.sortIndex=ie.expirationTime,t(d,ie);else break;ie=n(h)}}function H(Q){if(_=!1,I(Q),!x)if(n(d)!==null)x=!0,Ne(Y);else{var ie=n(h);ie!==null&&me(H,ie.startTime-Q)}}function Y(Q,ie){x=!1,_&&(_=!1,A(pe),pe=-1),T=!0;var v=b;try{for(I(ie),E=n(d);E!==null&&(!(E.expirationTime>ie)||Q&&!W());){var D=E.callback;if(typeof D=="function"){E.callback=null,b=E.priorityLevel;var Z=D(E.expirationTime<=ie);ie=e.unstable_now(),typeof Z=="function"?E.callback=Z:E===n(d)&&r(d),I(ie)}else r(d);E=n(d)}if(E!==null)var k=!0;else{var xe=n(h);xe!==null&&me(H,xe.startTime-ie),k=!1}return k}finally{E=null,b=v,T=!1}}var M=!1,G=null,pe=-1,re=5,z=-1;function W(){return!(e.unstable_now()-z<re)}function te(){if(G!==null){var Q=e.unstable_now();z=Q;var ie=!0;try{ie=G(!0,Q)}finally{ie?oe():(M=!1,G=null)}}else M=!1}var oe;if(typeof O=="function")oe=function(){O(te)};else if(typeof MessageChannel!="undefined"){var de=new MessageChannel,be=de.port2;de.port1.onmessage=te,oe=function(){be.postMessage(null)}}else oe=function(){S(te,0)};function Ne(Q){G=Q,M||(M=!0,oe())}function me(Q,ie){pe=S(function(){Q(e.unstable_now())},ie)}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||T||(x=!0,Ne(Y))},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"):re=0<Q?Math.floor(1e3/Q):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(Q){switch(b){case 1:case 2:case 3:var ie=3;break;default:ie=b}var v=b;b=ie;try{return Q()}finally{b=v}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(Q,ie){switch(Q){case 1:case 2:case 3:case 4:case 5:break;default:Q=3}var v=b;b=Q;try{return ie()}finally{b=v}},e.unstable_scheduleCallback=function(Q,ie,v){var D=e.unstable_now();switch(typeof v=="object"&&v!==null?(v=v.delay,v=typeof v=="number"&&0<v?D+v:D):v=D,Q){case 1:var Z=-1;break;case 2:Z=250;break;case 5:Z=1073741823;break;case 4:Z=1e4;break;default:Z=5e3}return Z=v+Z,Q={id:p++,callback:ie,priorityLevel:Q,startTime:v,expirationTime:Z,sortIndex:-1},v>D?(Q.sortIndex=v,t(h,Q),n(d)===null&&Q===n(h)&&(_?(A(pe),pe=-1):_=!0,me(H,v-D))):(Q.sortIndex=Z,t(d,Q),x||T||(x=!0,Ne(Y))),Q},e.unstable_shouldYield=W,e.unstable_wrapCallback=function(Q){var ie=b;return function(){var v=b;b=ie;try{return Q.apply(this,arguments)}finally{b=v}}}})(bd)),bd}var T0;function uv(){return T0||(T0=1,Td.exports=av()),Td.exports}var b0;function lv(){if(b0)return ln;b0=1;var e=ao(),t=uv();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 b(i){return d.call(E,i)?!0:d.call(p,i)?!1:h.test(i)?E[i]=!0:(p[i]=!0,!1)}function T(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"||T(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,y,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=y,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 I(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?b(s)&&(l===null?i.removeAttribute(s):i.setAttribute(s,""+l)):g.mustUseProperty?i[g.propertyName]=l===null?g.type===3?!1:"":l:(s=g.attributeName,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,Y=Symbol.for("react.element"),M=Symbol.for("react.portal"),G=Symbol.for("react.fragment"),pe=Symbol.for("react.strict_mode"),re=Symbol.for("react.profiler"),z=Symbol.for("react.provider"),W=Symbol.for("react.context"),te=Symbol.for("react.forward_ref"),oe=Symbol.for("react.suspense"),de=Symbol.for("react.suspense_list"),be=Symbol.for("react.memo"),Ne=Symbol.for("react.lazy"),me=Symbol.for("react.offscreen"),Q=Symbol.iterator;function ie(i){return i===null||typeof i!="object"?null:(i=Q&&i[Q]||i["@@iterator"],typeof i=="function"?i:null)}var v=Object.assign,D;function Z(i){if(D===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);D=s&&s[1]||""}return`
|
|
16
|
+
`+a)}}catch(u){}}throw r}})}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=_i(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:a}=n;r!==void 0&&Eu.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&&(j.isFunction(o)?n.paramsSerializer={serialize:o}:Eu.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),Eu.assertOptions(n,{baseUrl:In.spelling("baseURL"),withXsrfToken:In.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&j.merge(a.common,a[n.method]);a&&j.forEach(["delete","get","head","post","put","patch","query","common"],x=>{delete a[x]}),n.headers=en.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||rd;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,b;if(!d){const x=[s0.bind(this),void 0];for(x.unshift(...c),x.push(...h),b=x.length,p=Promise.resolve(n);E<b;)p=p.then(x[E++],x[E++]);return p}b=c.length;let T=n;for(;E<b;){const x=c[E++],_=c[E++];try{T=x(T)}catch(S){_.call(this,S);break}}try{p=s0.call(this,T)}catch(x){return Promise.reject(x)}for(E=0,b=h.length;E<b;)p=p.then(h[E++],h[E++]);return p}getUri(t){t=_i(this.defaults,t);const n=Xm(t.baseURL,t.url,t.allowAbsoluteUrls);return Vm(n,t.params,t.paramsSerializer)}};j.forEach(["delete","get","head","options"],function(t){Si.prototype[t]=function(n,r){return this.request(_i(r||{},{method:t,url:n,data:(r||{}).data}))}}),j.forEach(["post","put","patch","query"],function(t){function n(r){return function(a,u,c){return this.request(_i(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 wS=class Hx{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const u=new Promise(c=>{r.subscribe(c),a=c}).then(o);return u.cancel=function(){r.unsubscribe(a)},u},t(function(a,u,c){r.reason||(r.reason=new Cs(a,u,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Hx(function(o){t=o}),cancel:t}}};function _S(e){return function(n){return e.apply(null,n)}}function SS(e){return j.isObject(e)&&e.isAxiosError===!0}const cd={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(cd).forEach(([e,t])=>{cd[t]=e});function u0(e){const t=new Si(e),n=Nm(Si.prototype.request,t);return j.extend(n,Si.prototype,t,{allOwnKeys:!0}),j.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return u0(_i(e,o))},n}const bt=u0(As);bt.Axios=Si,bt.CanceledError=Cs,bt.CancelToken=wS,bt.isCancel=Wm,bt.VERSION=ad,bt.toFormData=hu,bt.AxiosError=Ae,bt.Cancel=bt.CanceledError,bt.all=function(t){return Promise.all(t)},bt.spread=_S,bt.isAxiosError=SS,bt.mergeConfig=_i,bt.AxiosHeaders=en,bt.formToJSON=e=>Ym(j.isHTMLForm(e)?new FormData(e):e),bt.getAdapter=o0.getAdapter,bt.HttpStatusCode=cd,bt.default=bt;const{Axios:mF,AxiosError:gF,CanceledError:EF,isCancel:yF,CancelToken:TF,VERSION:bF,all:xF,Cancel:wF,isAxiosError:_F,spread:SF,toFormData:vF,AxiosHeaders:AF,HttpStatusCode:CF,formToJSON:kF,getAdapter:NF,mergeConfig:OF,create:IF}=bt;class vS{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 bt.get(`${this.apiUrl}/configs/copilot`,{headers:this.headers}),{customer_config:n}=t.data,r=atob(n);return JSON.parse(r)}catch(t){throw console.error("Error fetching customer config:",t),t}}));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 AS{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 vS(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 vi=(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 CS{constructor(t=!1){Ze(this,"isDevelopment");Ze(this,"_log",(t,n,...r)=>{vi(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 kS={copilot:"Your Search Assistant",messaging:"Commerce Client"},l0=X.createContext(null),NS=({mode:e,logoUrl:t,headerText:n="Your Search Assistant",headerConfig:r,globalClassName:o="",entryMessage:a,openLinksInNewTab:u=!1,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,searchPlaceholder:p,searchButtonLabel:E,searchConfig:b,componentConfig:T,conversationHistory:x,resetConversationMessage:_="",apiKey:S,apiToken:A,baseUrl:O,customerId:I,tenantId:z,theme:Y,isDevelopment:M,__features:Q,children:Ee})=>{const re=e==="messaging",U=X.useMemo(()=>re?{config:null}:new AS(O,S,A,M,I,z),[re,O,S,A,M,I,z]),W=X.useMemo(()=>new CS(M),[M]);X.useEffect(()=>{re||!U||U.config||U.getConfig()},[U,re]);const te=X.useMemo(()=>zw(Y),[Y]),oe=X.useMemo(()=>{const Ie=(b==null?void 0:b.placeholder)||p,he=(b==null?void 0:b.buttonLabel)||E;let G="icon";return b!=null&&b.buttonType?G=b.buttonType:E&&(G="text"),se(B({},b||{}),{placeholder:Ie,buttonLabel:he,buttonType:G})},[b,p,E]),de=X.useMemo(()=>se(B({},r||{}),{logoUrl:t||(r==null?void 0:r.logoUrl),headerText:n||kS[e!=null?e:"copilot"]}),[r,t,n,e]),be=X.useMemo(()=>({configModule:U,mode:e!=null?e:"copilot",headerConfig:de,entryMessage:a,globalClassName:o,openLinksInNewTab:u,disclaimerText:c,disclaimerMarkdown:d,clientContext:h,themeVariables:te,logger:W,searchConfig:oe,enableMinimize:!!(T!=null&&T.enableMinimize),resetConversationMessage:_,conversationHistory:{sinceHours:typeof(x==null?void 0:x.sinceHours)=="number"?x.sinceHours:1,limit:x==null?void 0:x.limit},features:Q}),[U,e,de,a,o,h,c,d,u,oe,T,_,W,te,x,Q]);return P.jsx(l0.Provider,{value:be,children:Ee})},kt=()=>{const e=X.useContext(l0);if(!e)throw new Error("useConfig must be used within a ConfigProvider");return e},c0={connectionStatus:"disconnected",loading:!0,conversationId:null,messages:[],streamingContent:"",isAgentTyping:!1,progressMessage:"",routingResult:null,error:null};function OS(e,t){switch(t.type){case"SET_CONNECTION_STATUS":return B(se(B({},e),{connectionStatus:t.status}),t.status==="connected"||t.status==="connecting"?{error:null}:{});case"SET_LOADING":return se(B({},e),{loading:t.isLoading});case"SET_CONVERSATION_ID":return se(B({},e),{conversationId:t.id});case"ADD_MESSAGE":return se(B({},e),{messages:[...e.messages,se(B({},t.message),{type:"ADD_MESSAGE"})]});case"APPEND_STREAMING_TOKEN":return se(B({},e),{streamingContent:e.streamingContent+t.token});case"FLUSH_STREAMING":return se(B({},e),{messages:[...e.messages,se(B({},t.message),{type:"FLUSH_STREAMING"})],streamingContent:"",isAgentTyping:!1,loading:!1,progressMessage:""});case"SET_AGENT_TYPING":return se(B({},e),{isAgentTyping:t.isTyping,loading:t.isTyping});case"SET_PROGRESS_MESSAGE":return se(B({},e),{progressMessage:t.message});case"SET_ROUTING_RESULT":return se(B({},e),{routingResult:t.result});case"SET_ERROR":return se(B({},e),{error:t.error,loading:!1,progressMessage:""});case"LOAD_HISTORY":return se(B({},e),{messages:t.messages,loading:!1});case"RESET":return se(B({},c0),{connectionStatus:e.connectionStatus,loading:!0});default:return e}}const d0=X.createContext({connectionStatus:"disconnected",isConnected:!1,isAgentTyping:!1,conversationId:null,messages:[],streamingContent:"",progressMessage:"",loading:!0,error:null,sendMessage:()=>{},resetConversation:()=>{}});function dd(e,t){return`cim_af_conv_${e}_${t}`}function fd(e,t){return Date.now()-e>t}function IS(e,t,n){try{const r=dd(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"||fd(u.storedAt,n)?(sessionStorage.removeItem(r),null):u}catch(r){return null}}function ks(e,t,n){try{const r=dd(e,t),o={conversationId:n,storedAt:Date.now()};sessionStorage.setItem(r,JSON.stringify(o))}catch(r){}}function yu(e,t){try{const n=dd(e,t);sessionStorage.removeItem(n)}catch(n){}}function hd(e,t){return`cim_af_ct_${e}_${t}`}function f0(e,t,n){try{const r=hd(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 RS(e,t,n,r){try{const o=hd(e,t),a={accessToken:n,lastEventId:r,storedAt:Date.now()};sessionStorage.setItem(o,JSON.stringify(a))}catch(o){}}function PS(e,t){try{const n=hd(e,t);sessionStorage.removeItem(n)}catch(n){}}function LS(e,t){return`cim_af_conv_${e}_${t}`}function DS(e,t){try{if(typeof BroadcastChannel=="undefined")return null;const n=LS(e,t);return new BroadcastChannel(n)}catch(n){return null}}function MS(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 FS(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 BS(e){if(e)try{e.postMessage({type:"conversation_cleared"})}catch(t){}}function US(e){if(e)try{e.close()}catch(t){}}function HS(e){switch(e){case"EndUser":case"Customer":return"user";case"Agent":case"Chatbot":return"agent";default:return"system"}}function zS(e){if(!e)return{};if(typeof e=="string")try{return JSON.parse(e)}catch(t){return{}}return e}function h0(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 jS(e){if(e.entryType!=="Message")return null;const n=zS(e.entryPayload).abstractMessage;if(!n)return null;const r=h0(n,"staticContent","text")||h0(n,"content","text")||"";if(!r)return null;const o=HS(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 $S(e){const t=[];for(const n of e){const r=jS(n);r&&t.push(r)}return t}function VS(e){const{orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:o}=e,a=X.useRef(null),u=X.useRef(null),c=X.useRef(null),d=o.sinceHours*60*60*1e3,h=X.useCallback(()=>(c.current||(c.current=MS(a.current)),c.current),[]);X.useEffect(()=>{const S=DS(t,n);a.current=S,c.current=null;const A=FS(S,()=>{const O=u.current;if(!O)return null;const I=f0(t,n,d);return{conversationId:O,continuationToken:I==null?void 0:I.accessToken,lastEventId:I==null?void 0:I.lastEventId}},()=>{yu(t,n),u.current=null});return()=>{A(),US(S),a.current=null}},[t,n,d]);const p=X.useCallback(S=>$e(null,null,function*(){let A=IS(t,n,d);if(!A){const O=yield h();O&&!fd(O.storedAt,d)&&(A=O)}if(!A){const O=yield S.createConversation(r);return ks(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){yu(t,n);const M=yield S.createConversation(r);return ks(t,n,M),u.current=M,{conversationId:M,restoredMessages:[],resumed:!1}}S.resumeConversation(z.conversationId),u.current=z.conversationId,ks(t,n,z.conversationId);let Y=[];try{const M=yield S.listConversationEntries(z.conversationId,{limit:o.limit,startTimestamp:O,direction:"FromStart"});Y=$S(M.conversationEntries)}catch(M){}return{conversationId:z.conversationId,restoredMessages:Y,resumed:!0}}catch(O){yu(t,n);const I=yield S.createConversation(r);return ks(t,n,I),u.current=I,{conversationId:I,restoredMessages:[],resumed:!1}}}),[t,n,r,o,d,h]),E=X.useCallback(S=>{ks(t,n,S),u.current=S},[t,n]),b=X.useCallback(()=>{yu(t,n),PS(t,n),BS(a.current),u.current=null},[t,n]),T=X.useCallback(()=>{const S=f0(t,n,d);return S?{continuationToken:S.accessToken,lastEventId:S.lastEventId}:null},[t,n,d]),x=X.useCallback(()=>$e(null,null,function*(){const S=yield h();return!(S!=null&&S.continuationToken)||fd(S.storedAt,d)?null:{continuationToken:S.continuationToken,lastEventId:S.lastEventId}}),[d,h]),_=X.useCallback(S=>$e(null,null,function*(){try{const{accessToken:A,lastEventId:O}=yield S.generateContinuationToken();RS(t,n,A,O)}catch(A){}}),[t,n]);return{initializeConversation:p,persistConversationId:E,clearPersistedConversation:b,getStoredConnectOptions:T,getPeerConnectOptions:x,persistContinuationToken:_}}const qS="Your session ended due to inactivity. Starting a new session…";function YS(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 p0=({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}=kt(),[b,T]=X.useReducer(OS,c0),x=VS({orgId:t,esDeveloperName:n,routingAttributes:r,conversationHistory:E}),_=X.useRef(null),S=X.useRef(c),A=X.useRef(d),O=X.useRef(u),I=X.useRef(!1);S.current=c,A.current=d,O.current=u,X.useEffect(()=>{const re=new Hw({baseURL:e,orgId:t,esDeveloperName:n,options:B({enableLogging:a},o?{capabilitiesVersion:o}:{})});return _.current=re,re.on("connected",()=>{var W;T({type:"SET_CONNECTION_STATUS",status:"connected"}),(W=O.current)==null||W.call(O)}),re.on("disconnected",()=>{T({type:"SET_CONNECTION_STATUS",status:"disconnected"})}),re.on("reconnecting",()=>{T({type:"SET_CONNECTION_STATUS",status:"reconnecting"})}),re.on("message",W=>{var oe;const te={id:W.messageId||crypto.randomUUID(),role:"agent",content:W.content,timestamp:W.timestamp,sender:W.sender,raw:W};T({type:"FLUSH_STREAMING",message:te}),(oe=S.current)==null||oe.call(S,te)}),re.on("streaming_token",W=>{T({type:"APPEND_STREAMING_TOKEN",token:W.token})}),re.on("typing_started",()=>{T({type:"SET_AGENT_TYPING",isTyping:!0})}),re.on("typing_stopped",()=>{T({type:"SET_AGENT_TYPING",isTyping:!1})}),re.on("progress_indicator",W=>{T({type:"SET_PROGRESS_MESSAGE",message:W.message})}),re.on("routing_result",W=>{var te;if(T({type:"SET_ROUTING_RESULT",result:W}),!W.isSuccessful){const oe=`Routing failed: ${W.failureType||"unknown"}`;T({type:"SET_ERROR",error:oe}),(te=A.current)==null||te.call(A,oe)}}),re.on("participant_changed",W=>{if(W.participant.name==="Automated Process")return;const te={id:crypto.randomUUID(),role:"system",content:W.action==="add"?`${W.participant.name||"Agent"} joined the conversation`:`${W.participant.name||"Agent"} left the conversation`,timestamp:new Date().toISOString()};p==null||p.log("🦜 MessagingProvider participant_changed event received",{event:W}),T({type:"ADD_MESSAGE",message:te})}),re.on("conversation_closed",()=>{const W={id:crypto.randomUUID(),role:"system",content:"Conversation reset",timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:W}),T({type:"SET_CONVERSATION_ID",id:null}),x.clearPersistedConversation()}),re.on("error",W=>{var te;p==null||p.log("🦜 MessagingProvider ERROR event received",{event:W}),T({type:"SET_ERROR",error:W.message}),W.recoverable||T({type:"SET_CONNECTION_STATUS",status:"error"}),(te=A.current)==null||te.call(A,W.message)}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),$e(null,null,function*(){let W=x.getStoredConnectOptions(),te=!1;W||(W=yield x.getPeerConnectOptions(),te=!!W);try{yield re.connect(W!=null?W:void 0)}catch(de){if(W)p==null||p.log("Continuation token failed, falling back to fresh connect"),te||x.clearPersistedConversation(),yield re.connect();else throw de}yield x.persistContinuationToken(re);const oe=yield x.initializeConversation(re);T({type:"SET_CONVERSATION_ID",id:oe.conversationId}),oe.resumed&&oe.restoredMessages.length>0&&T({type:"LOAD_HISTORY",messages:oe.restoredMessages})}).catch(W=>{var te;T({type:"SET_CONNECTION_STATUS",status:"error"}),T({type:"SET_ERROR",error:W.message}),(te=A.current)==null||te.call(A,W.message)}),()=>{re.disconnect(),re.off(),_.current=null}},[e,t,n,o]);const z=X.useCallback(re=>$e(null,null,function*(){var W;const U=_.current;if(!(!U||I.current)){I.current=!0,T({type:"ADD_MESSAGE",message:{id:crypto.randomUUID(),role:"system",content:qS,timestamp:new Date().toISOString()}}),x.clearPersistedConversation(),T({type:"SET_CONNECTION_STATUS",status:"connecting"});try{U.disconnect(),yield U.connect(),yield x.persistContinuationToken(U);const te=yield U.createConversation(r);T({type:"SET_CONVERSATION_ID",id:te}),T({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(te),re&&(T({type:"SET_LOADING",isLoading:!0}),T({type:"SET_PROGRESS_MESSAGE",message:""}),yield U.sendMessage(re))}catch(te){const oe=te instanceof Error?te.message:String(te);T({type:"SET_ERROR",error:oe}),T({type:"SET_CONNECTION_STATUS",status:"error"}),(W=A.current)==null||W.call(A,oe)}finally{I.current=!1}}}),[r,x]),Y=X.useRef(z);Y.current=z;const M=X.useCallback(re=>{if(!re.trim())return;const U=_.current;if(!U)return;const W={id:crypto.randomUUID(),role:"user",content:re,timestamp:new Date().toISOString()};T({type:"ADD_MESSAGE",message:W}),T({type:"SET_LOADING",isLoading:!0}),T({type:"SET_PROGRESS_MESSAGE",message:""}),U.sendMessage(re).catch(te=>{var oe;if(YS(te)){Y.current(re);return}T({type:"SET_ERROR",error:te.message}),(oe=A.current)==null||oe.call(A,te.message)})},[]),Q=X.useCallback(()=>{const re=_.current;re&&(x.clearPersistedConversation(),T({type:"RESET"}),T({type:"SET_CONNECTION_STATUS",status:"connecting"}),re.endConversation().then(()=>(re.disconnect(),re.connect())).then(()=>$e(null,null,function*(){return yield x.persistContinuationToken(re),re.createConversation(r)})).then(U=>{T({type:"SET_CONVERSATION_ID",id:U}),T({type:"SET_CONNECTION_STATUS",status:"connected"}),x.persistConversationId(U)}).catch(U=>{var W;T({type:"SET_ERROR",error:U.message}),T({type:"SET_CONNECTION_STATUS",status:"error"}),(W=A.current)==null||W.call(A,U.message)}))},[r,x]),Ee=X.useMemo(()=>({connectionStatus:b.connectionStatus,isConnected:b.connectionStatus==="connected",isAgentTyping:b.isAgentTyping,conversationId:b.conversationId,messages:b.messages,streamingContent:b.streamingContent,progressMessage:b.progressMessage,error:b.error,loading:b.loading,sendMessage:M,resetConversation:Q}),[b,M,Q]);return P.jsx(d0.Provider,{value:Ee,children:h})};function WS(){var e=X.useRef(!0);return e.current?(e.current=!1,!0):e.current}function GS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.addEventListener&&e.addEventListener.apply(e,t)}function KS(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];e&&e.removeEventListener&&e.removeEventListener.apply(e,t)}var pd=typeof window!="undefined",Tu=function(e){X.useEffect(e,[])},QS=function(e){var t=X.useRef(e);t.current=e,Tu(function(){return function(){return t.current()}})},XS=function(e){var t=X.useRef(0),n=X.useState(e),r=n[0],o=n[1],a=X.useCallback(function(u){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(u)})},[]);return QS(function(){cancelAnimationFrame(t.current)}),[r,a]},JS=function(e,t){return e===t};function ZS(e,t){t===void 0&&(t=JS);var n=X.useRef(),r=X.useRef(e),o=WS();return!o&&!t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var ev=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=XS({width:pd?window.innerWidth:r,height:pd?window.innerHeight:a}),d=c[0],h=c[1];return X.useEffect(function(){if(pd){var p=function(){var E=window.innerWidth,b=window.innerHeight;h({width:E,height:b}),u&&u(E,b)};return GS(window,"resize",p),function(){KS(window,"resize",p)}}},[]),d};const md="cimulate:ui-state-update",tv=e=>{window.addEventListener(md,e)},nv=e=>{window.removeEventListener(md,e)},rv=(e,t)=>{const n=new CustomEvent(md,{detail:{property:e,value:t}});window.dispatchEvent(n)},m0=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},Ai=e=>{const t=tt.statusProxy.isOpen,n=typeof e=="boolean"?e:!t;tt.statusProxy.isOpen=n,n&&(tt.statusProxy.isMinimized=!1)},bu=e=>{const t=tt.statusProxy.isMinimized,n=typeof e=="boolean"?e:!t;tt.statusProxy.isMinimized=n,n&&(tt.statusProxy.isOpen=!1)},gd=e=>{tt.modalProxy.isFullscreen=e},xu=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"},Ed=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},iv=e=>{const t=tt.dialogProxy.isFullHeight,n=typeof e=="boolean"?e:!t;tt.dialogProxy.isFullHeight=n};class ov{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 rv(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 ov,g0=X.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}),sv=({entryType:e,componentConfig:t,componentType:n,children:r})=>{const[o,a]=X.useState(e!=null?e:tt.entryTypeProxy.entryType),[u,c]=X.useState(tt.modeProxy.mode),[d,h]=X.useState({type:n||tt.statusProxy.type,isOpen:tt.statusProxy.isOpen,isMinimized:tt.statusProxy.isMinimized}),[p,E]=X.useState(tt.dialogProxy.position),[b,T]=X.useState(tt.dialogProxy.isFullHeight),[x,_]=X.useState(tt.dialogProxy.width),[S,A]=X.useState(tt.modalProxy.isFullscreen),O=ZS(d.type);X.useEffect(()=>{const z=Y=>{const{property:M,value:Q}=Y.detail||{};if(!(!M||Q===void 0)){if(M==="mode"){c(Q);return}if(M==="entryType"){a(Q);return}if(M==="isMinimized"){h(Ee=>se(B({},Ee),{isMinimized:Q}));return}if(M==="isOpen"){h(Ee=>se(B({},Ee),{isOpen:Q}));return}if(M==="type"){h(Ee=>se(B({},Ee),{type:Q}));return}if(M==="position"){E(Q);return}if(M==="isFullHeight"){T(Q);return}if(M==="width"){_(Q);return}if(M==="isFullscreen"){A(Q);return}}};return tv(z),()=>{nv(z)}},[]),Tu(()=>{e&&m0(e)}),Tu(()=>{const z=n||(t==null?void 0:t.type);z&&xu(z),t&&"isOpen"in t&&Ai(!!t.isOpen),t&&"isMinimized"in t&&bu(!!t.isMinimized)}),Tu(()=>{if(!(t!=null&&t.options))return;const{dialogPosition:z}=t.options;z&&Ed(z),"dialogFullHeight"in t.options&&iv(!!t.options.dialogFullHeight),"dialogWidth"in t.options&&t.options.dialogWidth&&_(t.options.dialogWidth),"isModalFullscreen"in t.options&&gd(!!t.options.isModalFullscreen)});const I=X.useMemo(()=>({mode:u,entryType:o,status:d,previousComponentType:O||"dialog",dialogPosition:p,isDialogFullHeight:b,dialogWidth:x,isModalFullscreen:S}),[u,o,d,O,p,b,x,S]);return P.jsx(g0.Provider,{value:I,children:r})},E0=({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:b,entryType:T,entryMessage:x,disclaimerText:_,disclaimerMarkdown:S,clientContext:A,searchPlaceholder:O,searchButtonLabel:I,searchConfig:z,resetConversationMessage:Y,conversationHistory:M,messagingConfig:Q,__features:Ee,children:re})=>P.jsx(NS,{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:I,searchConfig:z,componentConfig:b,clientContext:A,disclaimerMarkdown:S,disclaimerText:_,resetConversationMessage:Y,conversationHistory:M,isDevelopment:p,__features:Ee,children:P.jsx(sv,{entryType:T,componentConfig:b,componentType:E,children:P.jsx(p0,{scrt2Url:(Q==null?void 0:Q.scrt2Url)||"",orgId:(Q==null?void 0:Q.orgId)||"",esDeveloperName:(Q==null?void 0:Q.esDeveloperName)||"",routingAttributes:(Q==null?void 0:Q.routingAttributes)||{},capabilitiesVersion:Q==null?void 0:Q.capabilitiesVersion,enableLogging:p,children:re})})}),Ci=()=>{const e=X.useContext(g0);if(!e)throw new Error("useUIState must be used within a UIStateProvider");return e};var yd={exports:{}},ln={},Td={exports:{}},bd={};var y0;function av(){return y0||(y0=1,(function(e){function t(G,ie){var v=G.length;G.push(ie);e:for(;0<v;){var D=v-1>>>1,Z=G[D];if(0<o(Z,ie))G[D]=ie,G[v]=Z,v=D;else break e}}function n(G){return G.length===0?null:G[0]}function r(G){if(G.length===0)return null;var ie=G[0],v=G.pop();if(v!==ie){G[0]=v;e:for(var D=0,Z=G.length,k=Z>>>1;D<k;){var xe=2*(D+1)-1,Pe=G[xe],Ne=xe+1,He=G[Ne];if(0>o(Pe,v))Ne<Z&&0>o(He,Pe)?(G[D]=He,G[Ne]=v,D=Ne):(G[D]=Pe,G[xe]=v,D=xe);else if(Ne<Z&&0>o(He,v))G[D]=He,G[Ne]=v,D=Ne;else break e}}return ie}function o(G,ie){var v=G.sortIndex-ie.sortIndex;return v!==0?v:G.id-ie.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,b=3,T=!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 I(G){for(var ie=n(h);ie!==null;){if(ie.callback===null)r(h);else if(ie.startTime<=G)r(h),ie.sortIndex=ie.expirationTime,t(d,ie);else break;ie=n(h)}}function z(G){if(_=!1,I(G),!x)if(n(d)!==null)x=!0,Ie(Y);else{var ie=n(h);ie!==null&&he(z,ie.startTime-G)}}function Y(G,ie){x=!1,_&&(_=!1,A(Ee),Ee=-1),T=!0;var v=b;try{for(I(ie),E=n(d);E!==null&&(!(E.expirationTime>ie)||G&&!W());){var D=E.callback;if(typeof D=="function"){E.callback=null,b=E.priorityLevel;var Z=D(E.expirationTime<=ie);ie=e.unstable_now(),typeof Z=="function"?E.callback=Z:E===n(d)&&r(d),I(ie)}else r(d);E=n(d)}if(E!==null)var k=!0;else{var xe=n(h);xe!==null&&he(z,xe.startTime-ie),k=!1}return k}finally{E=null,b=v,T=!1}}var M=!1,Q=null,Ee=-1,re=5,U=-1;function W(){return!(e.unstable_now()-U<re)}function te(){if(Q!==null){var G=e.unstable_now();U=G;var ie=!0;try{ie=Q(!0,G)}finally{ie?oe():(M=!1,Q=null)}}else M=!1}var oe;if(typeof O=="function")oe=function(){O(te)};else if(typeof MessageChannel!="undefined"){var de=new MessageChannel,be=de.port2;de.port1.onmessage=te,oe=function(){be.postMessage(null)}}else oe=function(){S(te,0)};function Ie(G){Q=G,M||(M=!0,oe())}function he(G,ie){Ee=S(function(){G(e.unstable_now())},ie)}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(G){G.callback=null},e.unstable_continueExecution=function(){x||T||(x=!0,Ie(Y))},e.unstable_forceFrameRate=function(G){0>G||125<G?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):re=0<G?Math.floor(1e3/G):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(G){switch(b){case 1:case 2:case 3:var ie=3;break;default:ie=b}var v=b;b=ie;try{return G()}finally{b=v}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(G,ie){switch(G){case 1:case 2:case 3:case 4:case 5:break;default:G=3}var v=b;b=G;try{return ie()}finally{b=v}},e.unstable_scheduleCallback=function(G,ie,v){var D=e.unstable_now();switch(typeof v=="object"&&v!==null?(v=v.delay,v=typeof v=="number"&&0<v?D+v:D):v=D,G){case 1:var Z=-1;break;case 2:Z=250;break;case 5:Z=1073741823;break;case 4:Z=1e4;break;default:Z=5e3}return Z=v+Z,G={id:p++,callback:ie,priorityLevel:G,startTime:v,expirationTime:Z,sortIndex:-1},v>D?(G.sortIndex=v,t(h,G),n(d)===null&&G===n(h)&&(_?(A(Ee),Ee=-1):_=!0,he(z,v-D))):(G.sortIndex=Z,t(d,G),x||T||(x=!0,Ie(Y))),G},e.unstable_shouldYield=W,e.unstable_wrapCallback=function(G){var ie=b;return function(){var v=b;b=ie;try{return G.apply(this,arguments)}finally{b=v}}}})(bd)),bd}var T0;function uv(){return T0||(T0=1,Td.exports=av()),Td.exports}var b0;function lv(){if(b0)return ln;b0=1;var e=ao(),t=uv();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 b(i){return d.call(E,i)?!0:d.call(p,i)?!1:h.test(i)?E[i]=!0:(p[i]=!0,!1)}function T(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"||T(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,y,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=y,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 I(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?b(s)&&(l===null?i.removeAttribute(s):i.setAttribute(s,""+l)):g.mustUseProperty?i[g.propertyName]=l===null?g.type===3?!1:"":l:(s=g.attributeName,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,Y=Symbol.for("react.element"),M=Symbol.for("react.portal"),Q=Symbol.for("react.fragment"),Ee=Symbol.for("react.strict_mode"),re=Symbol.for("react.profiler"),U=Symbol.for("react.provider"),W=Symbol.for("react.context"),te=Symbol.for("react.forward_ref"),oe=Symbol.for("react.suspense"),de=Symbol.for("react.suspense_list"),be=Symbol.for("react.memo"),Ie=Symbol.for("react.lazy"),he=Symbol.for("react.offscreen"),G=Symbol.iterator;function ie(i){return i===null||typeof i!="object"?null:(i=G&&i[G]||i["@@iterator"],typeof i=="function"?i:null)}var v=Object.assign,D;function Z(i){if(D===void 0)try{throw Error()}catch(l){var s=l.stack.trim().match(/\n( *(at )?)/);D=s&&s[1]||""}return`
|
|
17
17
|
`+D+i}var k=!1;function xe(i,s){if(!i||k)return"";k=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(s)if(s=function(){throw Error()},Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(s,[])}catch(K){var f=K}Reflect.construct(i,[],s)}else{try{s.call()}catch(K){f=K}i.call(s.prototype)}else{try{throw Error()}catch(K){f=K}i()}}catch(K){if(K&&f&&typeof K.stack=="string"){for(var g=K.stack.split(`
|
|
18
18
|
`),y=f.stack.split(`
|
|
19
19
|
`),w=g.length-1,R=y.length-1;1<=w&&0<=R&&g[w]!==y[R];)R--;for(;1<=w&&0<=R;w--,R--)if(g[w]!==y[R]){if(w!==1||R!==1)do if(w--,R--,0>R||g[w]!==y[R]){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<=R);break}}}finally{k=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?Z(i):""}function Pe(i){switch(i.tag){case 5:return Z(i.type);case 16:return Z("Lazy");case 13:return Z("Suspense");case 19:return Z("SuspenseList");case 0:case 2:case 15:return i=xe(i.type,!1),i;case 11:return i=xe(i.type.render,!1),i;case 1:return i=xe(i.type,!0),i;default:return""}}function Oe(i){if(i==null)return null;if(typeof i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case G:return"Fragment";case M:return"Portal";case re:return"Profiler";case pe:return"StrictMode";case oe:return"Suspense";case de:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case W:return(i.displayName||"Context")+".Consumer";case z:return(i._context.displayName||"Context")+".Provider";case te: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:Oe(i.type)||"Memo";case Ne:s=i._payload,i=i._init;try{return Oe(i(s))}catch(l){}}return null}function He(i){var s=i.type;switch(i.tag){case 24:return"Cache";case 9:return(s.displayName||"Context")+".Consumer";case 10:return(s._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return i=s.render,i=i.displayName||i.name||"",s.displayName||(i!==""?"ForwardRef("+i+")":"ForwardRef");case 7:return"Fragment";case 5:return s;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Oe(s);case 8:return s===pe?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function Se(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function 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,y=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return g.call(this)},set:function(w){f=""+w,y.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 qi(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 Jr(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 v({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function pa(i,s){var l=s.defaultValue==null?"":s.defaultValue,f=s.checked!=null?s.checked:s.defaultChecked;l=Se(s.value!=null?s.value:l),i._wrapperState={initialChecked:f,initialValue:l,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function ma(i,s){s=s.checked,s!=null&&I(i,"checked",s,!1)}function Yo(i,s){ma(i,s);var l=Se(s.value),f=s.type;if(l!=null)f==="number"?(l===0&&i.value===""||i.value!=l)&&(i.value=""+l):i.value!==""+l&&(i.value=""+l);else if(f==="submit"||f==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?Wo(i,s.type,l):s.hasOwnProperty("defaultValue")&&Wo(i,s.type,Se(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function wl(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 Wo(i,s,l){(s!=="number"||Jr(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var Zr=Array.isArray;function ei(i,s,l,f){if(i=i.options,s){s={};for(var g=0;g<l.length;g++)s["$"+l[g]]=!0;for(l=0;l<i.length;l++)g=s.hasOwnProperty("$"+i[l].value),i[l].selected!==g&&(i[l].selected=g),g&&f&&(i[l].defaultSelected=!0)}else{for(l=""+Se(l),s=null,g=0;g<i.length;g++){if(i[g].value===l){i[g].selected=!0,f&&(i[g].defaultSelected=!0);return}s!==null||i[g].disabled||(s=i[g])}s!==null&&(s.selected=!0)}}function ga(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return v({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function _l(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(Zr(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:Se(l)}}function Sl(i,s){var l=Se(s.value),f=Se(s.defaultValue);l!=null&&(l=""+l,l!==i.value&&(i.value=l),s.defaultValue==null&&i.defaultValue!==l&&(i.defaultValue=l)),f!=null&&(i.defaultValue=""+f)}function vl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function ne(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"?ne(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Be,Ye=(function(i){return typeof MSApp!="undefined"&&MSApp.execUnsafeLocalFunction?function(s,l,f,g){MSApp.execUnsafeLocalFunction(function(){return i(s,l,f,g)})}:i})(function(i,s){if(i.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in i)i.innerHTML=s;else{for(Be=Be||document.createElement("div"),Be.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=Be.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function 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 zt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Ir=["Webkit","ms","Moz","O"];Object.keys(zt).forEach(function(i){Ir.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),zt[s]=zt[i]})});function Mn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||zt.hasOwnProperty(i)&&zt[i]?(""+s).trim():s+"px"}function ti(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 Yi=v({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 jt(i,s){if(s){if(Yi[i]&&(s.children!=null||s.dangerouslySetInnerHTML!=null))throw Error(n(137,i));if(s.dangerouslySetInnerHTML!=null){if(s.children!=null)throw Error(n(60));if(typeof s.dangerouslySetInnerHTML!="object"||!("__html"in s.dangerouslySetInnerHTML))throw Error(n(61))}if(s.style!=null&&typeof s.style!="object")throw Error(n(62))}}function yr(i,s){if(i.indexOf("-")===-1)return typeof s.is=="string";switch(i){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var vn=null;function Th(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var bh=null,Go=null,Ko=null;function ZT(i){if(i=Ba(i)){if(typeof bh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=Gl(s),bh(i.stateNode,i.type,s))}}function eb(i){Go?Ko?Ko.push(i):Ko=[i]:Go=i}function tb(){if(Go){var i=Go,s=Ko;if(Ko=Go=null,ZT(i),s)for(i=0;i<s.length;i++)ZT(s[i])}}function nb(i,s){return i(s)}function rb(){}var xh=!1;function ib(i,s,l){if(xh)return i(s,l);xh=!0;try{return nb(i,s,l)}finally{xh=!1,(Go!==null||Ko!==null)&&(rb(),tb())}}function Ea(i,s){var l=i.stateNode;if(l===null)return null;var f=Gl(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 wh=!1;if(c)try{var ya={};Object.defineProperty(ya,"passive",{get:function(){wh=!0}}),window.addEventListener("test",ya,ya),window.removeEventListener("test",ya,ya)}catch(i){wh=!1}function c8(i,s,l,f,g,y,w,R,F){var K=Array.prototype.slice.call(arguments,3);try{s.apply(l,K)}catch(ce){this.onError(ce)}}var Ta=!1,Al=null,Cl=!1,_h=null,d8={onError:function(i){Ta=!0,Al=i}};function f8(i,s,l,f,g,y,w,R,F){Ta=!1,Al=null,c8.apply(d8,arguments)}function h8(i,s,l,f,g,y,w,R,F){if(f8.apply(this,arguments),Ta){if(Ta){var K=Al;Ta=!1,Al=null}else throw Error(n(198));Cl||(Cl=!0,_h=K)}}function Wi(i){var s=i,l=i;if(i.alternate)for(;s.return;)s=s.return;else{i=s;do s=i,(s.flags&4098)!==0&&(l=s.return),i=s.return;while(i)}return s.tag===3?l:null}function ob(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 sb(i){if(Wi(i)!==i)throw Error(n(188))}function p8(i){var s=i.alternate;if(!s){if(s=Wi(i),s===null)throw Error(n(188));return s!==i?null:i}for(var l=i,f=s;;){var g=l.return;if(g===null)break;var y=g.alternate;if(y===null){if(f=g.return,f!==null){l=f;continue}break}if(g.child===y.child){for(y=g.child;y;){if(y===l)return sb(g),i;if(y===f)return sb(g),s;y=y.sibling}throw Error(n(188))}if(l.return!==f.return)l=g,f=y;else{for(var w=!1,R=g.child;R;){if(R===l){w=!0,l=g,f=y;break}if(R===f){w=!0,f=g,l=y;break}R=R.sibling}if(!w){for(R=y.child;R;){if(R===l){w=!0,l=y,f=g;break}if(R===f){w=!0,f=y,l=g;break}R=R.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 ab(i){return i=p8(i),i!==null?ub(i):null}function ub(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=ub(i);if(s!==null)return s;i=i.sibling}return null}var lb=t.unstable_scheduleCallback,cb=t.unstable_cancelCallback,m8=t.unstable_shouldYield,g8=t.unstable_requestPaint,wt=t.unstable_now,E8=t.unstable_getCurrentPriorityLevel,Sh=t.unstable_ImmediatePriority,db=t.unstable_UserBlockingPriority,kl=t.unstable_NormalPriority,y8=t.unstable_LowPriority,fb=t.unstable_IdlePriority,Nl=null,Tr=null;function T8(i){if(Tr&&typeof Tr.onCommitFiberRoot=="function")try{Tr.onCommitFiberRoot(Nl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var Jn=Math.clz32?Math.clz32:w8,b8=Math.log,x8=Math.LN2;function w8(i){return i>>>=0,i===0?32:31-(b8(i)/x8|0)|0}var Ol=64,Il=4194304;function ba(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 Rl(i,s){var l=i.pendingLanes;if(l===0)return 0;var f=0,g=i.suspendedLanes,y=i.pingedLanes,w=l&268435455;if(w!==0){var R=w&~g;R!==0?f=ba(R):(y&=w,y!==0&&(f=ba(y)))}else w=l&~g,w!==0?f=ba(w):y!==0&&(f=ba(y));if(f===0)return 0;if(s!==0&&s!==f&&(s&g)===0&&(g=f&-f,y=s&-s,g>=y||g===16&&(y&4194240)!==0))return s;if((f&4)!==0&&(f|=l&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=f;0<s;)l=31-Jn(s),g=1<<l,f|=i[l],s&=~g;return f}function _8(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 S8(i,s){for(var l=i.suspendedLanes,f=i.pingedLanes,g=i.expirationTimes,y=i.pendingLanes;0<y;){var w=31-Jn(y),R=1<<w,F=g[w];F===-1?((R&l)===0||(R&f)!==0)&&(g[w]=_8(R,s)):F<=s&&(i.expiredLanes|=R),y&=~R}}function vh(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function hb(){var i=Ol;return Ol<<=1,(Ol&4194240)===0&&(Ol=64),i}function Ah(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function xa(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 v8(i,s){var l=i.pendingLanes&~s;i.pendingLanes=s,i.suspendedLanes=0,i.pingedLanes=0,i.expiredLanes&=s,i.mutableReadLanes&=s,i.entangledLanes&=s,s=i.entanglements;var f=i.eventTimes;for(i=i.expirationTimes;0<l;){var g=31-Jn(l),y=1<<g;s[g]=0,f[g]=-1,i[g]=-1,l&=~y}}function Ch(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 pb(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var mb,kh,gb,Eb,yb,Nh=!1,Pl=[],ni=null,ri=null,ii=null,wa=new Map,_a=new Map,oi=[],A8="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 Tb(i,s){switch(i){case"focusin":case"focusout":ni=null;break;case"dragenter":case"dragleave":ri=null;break;case"mouseover":case"mouseout":ii=null;break;case"pointerover":case"pointerout":wa.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":_a.delete(s.pointerId)}}function Sa(i,s,l,f,g,y){return i===null||i.nativeEvent!==y?(i={blockedOn:s,domEventName:l,eventSystemFlags:f,nativeEvent:y,targetContainers:[g]},s!==null&&(s=Ba(s),s!==null&&kh(s)),i):(i.eventSystemFlags|=f,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function C8(i,s,l,f,g){switch(s){case"focusin":return ni=Sa(ni,i,s,l,f,g),!0;case"dragenter":return ri=Sa(ri,i,s,l,f,g),!0;case"mouseover":return ii=Sa(ii,i,s,l,f,g),!0;case"pointerover":var y=g.pointerId;return wa.set(y,Sa(wa.get(y)||null,i,s,l,f,g)),!0;case"gotpointercapture":return y=g.pointerId,_a.set(y,Sa(_a.get(y)||null,i,s,l,f,g)),!0}return!1}function bb(i){var s=Gi(i.target);if(s!==null){var l=Wi(s);if(l!==null){if(s=l.tag,s===13){if(s=ob(l),s!==null){i.blockedOn=s,yb(i.priority,function(){gb(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 Ll(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=Ih(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var f=new l.constructor(l.type,l);vn=f,l.target.dispatchEvent(f),vn=null}else return s=Ba(l),s!==null&&kh(s),i.blockedOn=l,!1;s.shift()}return!0}function xb(i,s,l){Ll(i)&&l.delete(s)}function k8(){Nh=!1,ni!==null&&Ll(ni)&&(ni=null),ri!==null&&Ll(ri)&&(ri=null),ii!==null&&Ll(ii)&&(ii=null),wa.forEach(xb),_a.forEach(xb)}function va(i,s){i.blockedOn===s&&(i.blockedOn=null,Nh||(Nh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,k8)))}function Aa(i){function s(g){return va(g,i)}if(0<Pl.length){va(Pl[0],i);for(var l=1;l<Pl.length;l++){var f=Pl[l];f.blockedOn===i&&(f.blockedOn=null)}}for(ni!==null&&va(ni,i),ri!==null&&va(ri,i),ii!==null&&va(ii,i),wa.forEach(s),_a.forEach(s),l=0;l<oi.length;l++)f=oi[l],f.blockedOn===i&&(f.blockedOn=null);for(;0<oi.length&&(l=oi[0],l.blockedOn===null);)bb(l),l.blockedOn===null&&oi.shift()}var Qo=H.ReactCurrentBatchConfig,Dl=!0;function N8(i,s,l,f){var g=nt,y=Qo.transition;Qo.transition=null;try{nt=1,Oh(i,s,l,f)}finally{nt=g,Qo.transition=y}}function O8(i,s,l,f){var g=nt,y=Qo.transition;Qo.transition=null;try{nt=4,Oh(i,s,l,f)}finally{nt=g,Qo.transition=y}}function Oh(i,s,l,f){if(Dl){var g=Ih(i,s,l,f);if(g===null)Gh(i,s,f,Ml,l),Tb(i,f);else if(C8(g,i,s,l,f))f.stopPropagation();else if(Tb(i,f),s&4&&-1<A8.indexOf(i)){for(;g!==null;){var y=Ba(g);if(y!==null&&mb(y),y=Ih(i,s,l,f),y===null&&Gh(i,s,f,Ml,l),y===g)break;g=y}g!==null&&f.stopPropagation()}else Gh(i,s,f,null,l)}}var Ml=null;function Ih(i,s,l,f){if(Ml=null,i=Th(f),i=Gi(i),i!==null)if(s=Wi(i),s===null)i=null;else if(l=s.tag,l===13){if(i=ob(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 Ml=i,null}function wb(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(E8()){case Sh:return 1;case db:return 4;case kl:case y8:return 16;case fb:return 536870912;default:return 16}default:return 16}}var si=null,Rh=null,Fl=null;function _b(){if(Fl)return Fl;var i,s=Rh,l=s.length,f,g="value"in si?si.value:si.textContent,y=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[y-f];f++);return Fl=g.slice(i,1<f?1-f:void 0)}function Bl(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 Ul(){return!0}function Sb(){return!1}function An(i){function s(l,f,g,y,w){this._reactName=l,this._targetInst=g,this.type=f,this.nativeEvent=y,this.target=w,this.currentTarget=null;for(var R in i)i.hasOwnProperty(R)&&(l=i[R],this[R]=l?l(y):y[R]);return this.isDefaultPrevented=(y.defaultPrevented!=null?y.defaultPrevented:y.returnValue===!1)?Ul:Sb,this.isPropagationStopped=Sb,this}return v(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=Ul)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Ul)},persist:function(){},isPersistent:Ul}),s}var Xo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ph=An(Xo),Ca=v({},Xo,{view:0,detail:0}),I8=An(Ca),Lh,Dh,ka,Hl=v({},Ca,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Fh,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!==ka&&(ka&&i.type==="mousemove"?(Lh=i.screenX-ka.screenX,Dh=i.screenY-ka.screenY):Dh=Lh=0,ka=i),Lh)},movementY:function(i){return"movementY"in i?i.movementY:Dh}}),vb=An(Hl),R8=v({},Hl,{dataTransfer:0}),P8=An(R8),L8=v({},Ca,{relatedTarget:0}),Mh=An(L8),D8=v({},Xo,{animationName:0,elapsedTime:0,pseudoElement:0}),M8=An(D8),F8=v({},Xo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),B8=An(F8),U8=v({},Xo,{data:0}),Ab=An(U8),H8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},z8={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"},j8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function $8(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=j8[i])?!!s[i]:!1}function Fh(){return $8}var V8=v({},Ca,{key:function(i){if(i.key){var s=H8[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=Bl(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?z8[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Fh,charCode:function(i){return i.type==="keypress"?Bl(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?Bl(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),q8=An(V8),Y8=v({},Hl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Cb=An(Y8),W8=v({},Ca,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Fh}),G8=An(W8),K8=v({},Xo,{propertyName:0,elapsedTime:0,pseudoElement:0}),Q8=An(K8),X8=v({},Hl,{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}),J8=An(X8),Z8=[9,13,27,32],Bh=c&&"CompositionEvent"in window,Na=null;c&&"documentMode"in document&&(Na=document.documentMode);var eM=c&&"TextEvent"in window&&!Na,kb=c&&(!Bh||Na&&8<Na&&11>=Na),Nb=" ",Ob=!1;function Ib(i,s){switch(i){case"keyup":return Z8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Rb(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var Jo=!1;function tM(i,s){switch(i){case"compositionend":return Rb(s);case"keypress":return s.which!==32?null:(Ob=!0,Nb);case"textInput":return i=s.data,i===Nb&&Ob?null:i;default:return null}}function nM(i,s){if(Jo)return i==="compositionend"||!Bh&&Ib(i,s)?(i=_b(),Fl=Rh=si=null,Jo=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return kb&&s.locale!=="ko"?null:s.data;default:return null}}var rM={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 Pb(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!rM[i.type]:s==="textarea"}function Lb(i,s,l,f){eb(f),s=ql(s,"onChange"),0<s.length&&(l=new Ph("onChange","change",null,l,f),i.push({event:l,listeners:s}))}var Oa=null,Ia=null;function iM(i){Jb(i,0)}function zl(i){var s=rs(i);if(qi(s))return i}function oM(i,s){if(i==="change")return s}var Db=!1;if(c){var Uh;if(c){var Hh="oninput"in document;if(!Hh){var Mb=document.createElement("div");Mb.setAttribute("oninput","return;"),Hh=typeof Mb.oninput=="function"}Uh=Hh}else Uh=!1;Db=Uh&&(!document.documentMode||9<document.documentMode)}function Fb(){Oa&&(Oa.detachEvent("onpropertychange",Bb),Ia=Oa=null)}function Bb(i){if(i.propertyName==="value"&&zl(Ia)){var s=[];Lb(s,Ia,i,Th(i)),ib(iM,s)}}function sM(i,s,l){i==="focusin"?(Fb(),Oa=s,Ia=l,Oa.attachEvent("onpropertychange",Bb)):i==="focusout"&&Fb()}function aM(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return zl(Ia)}function uM(i,s){if(i==="click")return zl(s)}function lM(i,s){if(i==="input"||i==="change")return zl(s)}function cM(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var Zn=typeof Object.is=="function"?Object.is:cM;function Ra(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 Ub(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function Hb(i,s){var l=Ub(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=Ub(l)}}function zb(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?zb(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function jb(){for(var i=window,s=Jr();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=Jr(i.document)}return s}function zh(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 dM(i){var s=jb(),l=i.focusedElem,f=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&zb(l.ownerDocument.documentElement,l)){if(f!==null&&zh(l)){if(s=f.start,i=f.end,i===void 0&&(i=s),"selectionStart"in l)l.selectionStart=s,l.selectionEnd=Math.min(i,l.value.length);else if(i=(s=l.ownerDocument||document)&&s.defaultView||window,i.getSelection){i=i.getSelection();var g=l.textContent.length,y=Math.min(f.start,g);f=f.end===void 0?y:Math.min(f.end,g),!i.extend&&y>f&&(g=f,f=y,y=g),g=Hb(l,y);var w=Hb(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(),y>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 fM=c&&"documentMode"in document&&11>=document.documentMode,Zo=null,jh=null,Pa=null,$h=!1;function $b(i,s,l){var f=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;$h||Zo==null||Zo!==Jr(f)||(f=Zo,"selectionStart"in f&&zh(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}),Pa&&Ra(Pa,f)||(Pa=f,f=ql(jh,"onSelect"),0<f.length&&(s=new Ph("onSelect","select",null,s,l),i.push({event:s,listeners:f}),s.target=Zo)))}function jl(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var es={animationend:jl("Animation","AnimationEnd"),animationiteration:jl("Animation","AnimationIteration"),animationstart:jl("Animation","AnimationStart"),transitionend:jl("Transition","TransitionEnd")},Vh={},Vb={};c&&(Vb=document.createElement("div").style,"AnimationEvent"in window||(delete es.animationend.animation,delete es.animationiteration.animation,delete es.animationstart.animation),"TransitionEvent"in window||delete es.transitionend.transition);function $l(i){if(Vh[i])return Vh[i];if(!es[i])return i;var s=es[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in Vb)return Vh[i]=s[l];return i}var qb=$l("animationend"),Yb=$l("animationiteration"),Wb=$l("animationstart"),Gb=$l("transitionend"),Kb=new Map,Qb="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 ai(i,s){Kb.set(i,s),a(s,[i])}for(var qh=0;qh<Qb.length;qh++){var Yh=Qb[qh],hM=Yh.toLowerCase(),pM=Yh[0].toUpperCase()+Yh.slice(1);ai(hM,"on"+pM)}ai(qb,"onAnimationEnd"),ai(Yb,"onAnimationIteration"),ai(Wb,"onAnimationStart"),ai("dblclick","onDoubleClick"),ai("focusin","onFocus"),ai("focusout","onBlur"),ai(Gb,"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 La="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(" "),mM=new Set("cancel close invalid load scroll toggle".split(" ").concat(La));function Xb(i,s,l){var f=i.type||"unknown-event";i.currentTarget=l,h8(f,s,void 0,i),i.currentTarget=null}function Jb(i,s){s=(s&4)!==0;for(var l=0;l<i.length;l++){var f=i[l],g=f.event;f=f.listeners;e:{var y=void 0;if(s)for(var w=f.length-1;0<=w;w--){var R=f[w],F=R.instance,K=R.currentTarget;if(R=R.listener,F!==y&&g.isPropagationStopped())break e;Xb(g,R,K),y=F}else for(w=0;w<f.length;w++){if(R=f[w],F=R.instance,K=R.currentTarget,R=R.listener,F!==y&&g.isPropagationStopped())break e;Xb(g,R,K),y=F}}}if(Cl)throw i=_h,Cl=!1,_h=null,i}function lt(i,s){var l=s[ep];l===void 0&&(l=s[ep]=new Set);var f=i+"__bubble";l.has(f)||(Zb(s,i,2,!1),l.add(f))}function Wh(i,s,l){var f=0;s&&(f|=4),Zb(l,i,f,s)}var Vl="_reactListening"+Math.random().toString(36).slice(2);function Da(i){if(!i[Vl]){i[Vl]=!0,r.forEach(function(l){l!=="selectionchange"&&(mM.has(l)||Wh(l,!1,i),Wh(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[Vl]||(s[Vl]=!0,Wh("selectionchange",!1,s))}}function Zb(i,s,l,f){switch(wb(s)){case 1:var g=N8;break;case 4:g=O8;break;default:g=Oh}l=g.bind(null,s,l,i),g=void 0,!wh||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 Gh(i,s,l,f,g){var y=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 R=f.stateNode.containerInfo;if(R===g||R.nodeType===8&&R.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(;R!==null;){if(w=Gi(R),w===null)return;if(F=w.tag,F===5||F===6){f=y=w;continue e}R=R.parentNode}}f=f.return}ib(function(){var K=y,ce=Th(l),he=[];e:{var ue=Kb.get(i);if(ue!==void 0){var we=Ph,ve=i;switch(i){case"keypress":if(Bl(l)===0)break e;case"keydown":case"keyup":we=q8;break;case"focusin":ve="focus",we=Mh;break;case"focusout":ve="blur",we=Mh;break;case"beforeblur":case"afterblur":we=Mh;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=vb;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":we=P8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":we=G8;break;case qb:case Yb:case Wb:we=M8;break;case Gb:we=Q8;break;case"scroll":we=I8;break;case"wheel":we=J8;break;case"copy":case"cut":case"paste":we=B8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":we=Cb}var Ce=(s&4)!==0,_t=!Ce&&i==="scroll",$=Ce?ue!==null?ue+"Capture":null:ue;Ce=[];for(var U=K,q;U!==null;){q=U;var ye=q.stateNode;if(q.tag===5&&ye!==null&&(q=ye,$!==null&&(ye=Ea(U,$),ye!=null&&Ce.push(Ma(U,ye,q)))),_t)break;U=U.return}0<Ce.length&&(ue=new we(ue,ve,null,l,ce),he.push({event:ue,listeners:Ce}))}}if((s&7)===0){e:{if(ue=i==="mouseover"||i==="pointerover",we=i==="mouseout"||i==="pointerout",ue&&l!==vn&&(ve=l.relatedTarget||l.fromElement)&&(Gi(ve)||ve[Rr]))break e;if((we||ue)&&(ue=ce.window===ce?ce:(ue=ce.ownerDocument)?ue.defaultView||ue.parentWindow:window,we?(ve=l.relatedTarget||l.toElement,we=K,ve=ve?Gi(ve):null,ve!==null&&(_t=Wi(ve),ve!==_t||ve.tag!==5&&ve.tag!==6)&&(ve=null)):(we=null,ve=K),we!==ve)){if(Ce=vb,ye="onMouseLeave",$="onMouseEnter",U="mouse",(i==="pointerout"||i==="pointerover")&&(Ce=Cb,ye="onPointerLeave",$="onPointerEnter",U="pointer"),_t=we==null?ue:rs(we),q=ve==null?ue:rs(ve),ue=new Ce(ye,U+"leave",we,l,ce),ue.target=_t,ue.relatedTarget=q,ye=null,Gi(ce)===K&&(Ce=new Ce($,U+"enter",ve,l,ce),Ce.target=q,Ce.relatedTarget=_t,ye=Ce),_t=ye,we&&ve)t:{for(Ce=we,$=ve,U=0,q=Ce;q;q=ts(q))U++;for(q=0,ye=$;ye;ye=ts(ye))q++;for(;0<U-q;)Ce=ts(Ce),U--;for(;0<q-U;)$=ts($),q--;for(;U--;){if(Ce===$||$!==null&&Ce===$.alternate)break t;Ce=ts(Ce),$=ts($)}Ce=null}else Ce=null;we!==null&&e2(he,ue,we,Ce,!1),ve!==null&&_t!==null&&e2(he,_t,ve,Ce,!0)}}e:{if(ue=K?rs(K):window,we=ue.nodeName&&ue.nodeName.toLowerCase(),we==="select"||we==="input"&&ue.type==="file")var ke=oM;else if(Pb(ue))if(Db)ke=lM;else{ke=aM;var De=sM}else(we=ue.nodeName)&&we.toLowerCase()==="input"&&(ue.type==="checkbox"||ue.type==="radio")&&(ke=uM);if(ke&&(ke=ke(i,K))){Lb(he,ke,l,ce);break e}De&&De(i,ue,K),i==="focusout"&&(De=ue._wrapperState)&&De.controlled&&ue.type==="number"&&Wo(ue,"number",ue.value)}switch(De=K?rs(K):window,i){case"focusin":(Pb(De)||De.contentEditable==="true")&&(Zo=De,jh=K,Pa=null);break;case"focusout":Pa=jh=Zo=null;break;case"mousedown":$h=!0;break;case"contextmenu":case"mouseup":case"dragend":$h=!1,$b(he,l,ce);break;case"selectionchange":if(fM)break;case"keydown":case"keyup":$b(he,l,ce)}var Me;if(Bh)e:{switch(i){case"compositionstart":var Ue="onCompositionStart";break e;case"compositionend":Ue="onCompositionEnd";break e;case"compositionupdate":Ue="onCompositionUpdate";break e}Ue=void 0}else Jo?Ib(i,l)&&(Ue="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(Ue="onCompositionStart");Ue&&(kb&&l.locale!=="ko"&&(Jo||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&Jo&&(Me=_b()):(si=ce,Rh="value"in si?si.value:si.textContent,Jo=!0)),De=ql(K,Ue),0<De.length&&(Ue=new Ab(Ue,i,null,l,ce),he.push({event:Ue,listeners:De}),Me?Ue.data=Me:(Me=Rb(l),Me!==null&&(Ue.data=Me)))),(Me=eM?tM(i,l):nM(i,l))&&(K=ql(K,"onBeforeInput"),0<K.length&&(ce=new Ab("onBeforeInput","beforeinput",null,l,ce),he.push({event:ce,listeners:K}),ce.data=Me))}Jb(he,s)})}function Ma(i,s,l){return{instance:i,listener:s,currentTarget:l}}function ql(i,s){for(var l=s+"Capture",f=[];i!==null;){var g=i,y=g.stateNode;g.tag===5&&y!==null&&(g=y,y=Ea(i,l),y!=null&&f.unshift(Ma(i,y,g)),y=Ea(i,s),y!=null&&f.push(Ma(i,y,g))),i=i.return}return f}function ts(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function e2(i,s,l,f,g){for(var y=s._reactName,w=[];l!==null&&l!==f;){var R=l,F=R.alternate,K=R.stateNode;if(F!==null&&F===f)break;R.tag===5&&K!==null&&(R=K,g?(F=Ea(l,y),F!=null&&w.unshift(Ma(l,F,R))):g||(F=Ea(l,y),F!=null&&w.push(Ma(l,F,R)))),l=l.return}w.length!==0&&i.push({event:s,listeners:w})}var gM=/\r\n?/g,EM=/\u0000|\uFFFD/g;function t2(i){return(typeof i=="string"?i:""+i).replace(gM,`
|
|
21
|
-
`).replace(EM,"")}function Yl(i,s,l){if(s=t2(s),t2(i)!==s&&l)throw Error(n(425))}function Wl(){}var Kh=null,Qh=null;function Xh(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 Jh=typeof setTimeout=="function"?setTimeout:void 0,yM=typeof clearTimeout=="function"?clearTimeout:void 0,n2=typeof Promise=="function"?Promise:void 0,TM=typeof queueMicrotask=="function"?queueMicrotask:typeof n2!="undefined"?function(i){return n2.resolve(null).then(i).catch(bM)}:Jh;function bM(i){setTimeout(function(){throw i})}function Zh(i,s){var l=s,f=0;do{var g=l.nextSibling;if(i.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(f===0){i.removeChild(g),Aa(s);return}f--}else l!=="$"&&l!=="$?"&&l!=="$!"||f++;l=g}while(l);Aa(s)}function ui(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 r2(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var l=i.data;if(l==="$"||l==="$!"||l==="$?"){if(s===0)return i;s--}else l==="/$"&&s++}i=i.previousSibling}return null}var ns=Math.random().toString(36).slice(2),br="__reactFiber$"+ns,Fa="__reactProps$"+ns,Rr="__reactContainer$"+ns,ep="__reactEvents$"+ns,xM="__reactListeners$"+ns,wM="__reactHandles$"+ns;function Gi(i){var s=i[br];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Rr]||l[br]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=r2(i);i!==null;){if(l=i[br])return l;i=r2(i)}return s}i=l,l=i.parentNode}return null}function Ba(i){return i=i[br]||i[Rr],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function rs(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function Gl(i){return i[Fa]||null}var tp=[],is=-1;function li(i){return{current:i}}function ct(i){0>is||(i.current=tp[is],tp[is]=null,is--)}function at(i,s){is++,tp[is]=i.current,i.current=s}var ci={},Qt=li(ci),mn=li(!1),Ki=ci;function os(i,s){var l=i.type.contextTypes;if(!l)return ci;var f=i.stateNode;if(f&&f.__reactInternalMemoizedUnmaskedChildContext===s)return f.__reactInternalMemoizedMaskedChildContext;var g={},y;for(y in l)g[y]=s[y];return f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function gn(i){return i=i.childContextTypes,i!=null}function Kl(){ct(mn),ct(Qt)}function i2(i,s,l){if(Qt.current!==ci)throw Error(n(168));at(Qt,s),at(mn,l)}function o2(i,s,l){var f=i.stateNode;if(s=s.childContextTypes,typeof f.getChildContext!="function")return l;f=f.getChildContext();for(var g in f)if(!(g in s))throw Error(n(108,He(i)||"Unknown",g));return v({},l,f)}function Ql(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||ci,Ki=Qt.current,at(Qt,i),at(mn,mn.current),!0}function s2(i,s,l){var f=i.stateNode;if(!f)throw Error(n(169));l?(i=o2(i,s,Ki),f.__reactInternalMemoizedMergedChildContext=i,ct(mn),ct(Qt),at(Qt,i)):ct(mn),at(mn,l)}var Pr=null,Xl=!1,np=!1;function a2(i){Pr===null?Pr=[i]:Pr.push(i)}function _M(i){Xl=!0,a2(i)}function di(){if(!np&&Pr!==null){np=!0;var i=0,s=nt;try{var l=Pr;for(nt=1;i<l.length;i++){var f=l[i];do f=f(!0);while(f!==null)}Pr=null,Xl=!1}catch(g){throw Pr!==null&&(Pr=Pr.slice(i+1)),lb(Sh,di),g}finally{nt=s,np=!1}}return null}var ss=[],as=0,Jl=null,Zl=0,Fn=[],Bn=0,Qi=null,Lr=1,Dr="";function Xi(i,s){ss[as++]=Zl,ss[as++]=Jl,Jl=i,Zl=s}function u2(i,s,l){Fn[Bn++]=Lr,Fn[Bn++]=Dr,Fn[Bn++]=Qi,Qi=i;var f=Lr;i=Dr;var g=32-Jn(f)-1;f&=~(1<<g),l+=1;var y=32-Jn(s)+g;if(30<y){var w=g-g%5;y=(f&(1<<w)-1).toString(32),f>>=w,g-=w,Lr=1<<32-Jn(s)+g|l<<g|f,Dr=y+i}else Lr=1<<y|l<<g|f,Dr=i}function rp(i){i.return!==null&&(Xi(i,1),u2(i,1,0))}function ip(i){for(;i===Jl;)Jl=ss[--as],ss[as]=null,Zl=ss[--as],ss[as]=null;for(;i===Qi;)Qi=Fn[--Bn],Fn[Bn]=null,Dr=Fn[--Bn],Fn[Bn]=null,Lr=Fn[--Bn],Fn[Bn]=null}var Cn=null,kn=null,pt=!1,er=null;function l2(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 c2(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=ui(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Cn=i,kn=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(l=Qi!==null?{id:Lr,overflow:Dr}:null,i.memoizedState={dehydrated:s,treeContext:l,retryLane:1073741824},l=jn(18,null,null,0),l.stateNode=s,l.return=i,i.child=l,Cn=i,kn=null,!0):!1;default:return!1}}function op(i){return(i.mode&1)!==0&&(i.flags&128)===0}function sp(i){if(pt){var s=kn;if(s){var l=s;if(!c2(i,s)){if(op(i))throw Error(n(418));s=ui(l.nextSibling);var f=Cn;s&&c2(i,s)?l2(f,l):(i.flags=i.flags&-4097|2,pt=!1,Cn=i)}}else{if(op(i))throw Error(n(418));i.flags=i.flags&-4097|2,pt=!1,Cn=i}}}function d2(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Cn=i}function ec(i){if(i!==Cn)return!1;if(!pt)return d2(i),pt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!Xh(i.type,i.memoizedProps)),s&&(s=kn)){if(op(i))throw f2(),Error(n(418));for(;s;)l2(i,s),s=ui(s.nextSibling)}if(d2(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=ui(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}kn=null}}else kn=Cn?ui(i.stateNode.nextSibling):null;return!0}function f2(){for(var i=kn;i;)i=ui(i.nextSibling)}function us(){kn=Cn=null,pt=!1}function ap(i){er===null?er=[i]:er.push(i)}var SM=H.ReactCurrentBatchConfig;function Ua(i,s,l){if(i=l.ref,i!==null&&typeof i!="function"&&typeof i!="object"){if(l._owner){if(l=l._owner,l){if(l.tag!==1)throw Error(n(309));var f=l.stateNode}if(!f)throw Error(n(147,i));var g=f,y=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===y?s.ref:(s=function(w){var R=g.refs;w===null?delete R[y]:R[y]=w},s._stringRef=y,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function tc(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function h2(i){var s=i._init;return s(i._payload)}function p2(i){function s($,U){if(i){var q=$.deletions;q===null?($.deletions=[U],$.flags|=16):q.push(U)}}function l($,U){if(!i)return null;for(;U!==null;)s($,U),U=U.sibling;return null}function f($,U){for($=new Map;U!==null;)U.key!==null?$.set(U.key,U):$.set(U.index,U),U=U.sibling;return $}function g($,U){return $=Ti($,U),$.index=0,$.sibling=null,$}function y($,U,q){return $.index=q,i?(q=$.alternate,q!==null?(q=q.index,q<U?($.flags|=2,U):q):($.flags|=2,U)):($.flags|=1048576,U)}function w($){return i&&$.alternate===null&&($.flags|=2),$}function R($,U,q,ye){return U===null||U.tag!==6?(U=Jp(q,$.mode,ye),U.return=$,U):(U=g(U,q),U.return=$,U)}function F($,U,q,ye){var ke=q.type;return ke===G?ce($,U,q.props.children,ye,q.key):U!==null&&(U.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ne&&h2(ke)===U.type)?(ye=g(U,q.props),ye.ref=Ua($,U,q),ye.return=$,ye):(ye=vc(q.type,q.key,q.props,null,$.mode,ye),ye.ref=Ua($,U,q),ye.return=$,ye)}function K($,U,q,ye){return U===null||U.tag!==4||U.stateNode.containerInfo!==q.containerInfo||U.stateNode.implementation!==q.implementation?(U=Zp(q,$.mode,ye),U.return=$,U):(U=g(U,q.children||[]),U.return=$,U)}function ce($,U,q,ye,ke){return U===null||U.tag!==7?(U=oo(q,$.mode,ye,ke),U.return=$,U):(U=g(U,q),U.return=$,U)}function he($,U,q){if(typeof U=="string"&&U!==""||typeof U=="number")return U=Jp(""+U,$.mode,q),U.return=$,U;if(typeof U=="object"&&U!==null){switch(U.$$typeof){case Y:return q=vc(U.type,U.key,U.props,null,$.mode,q),q.ref=Ua($,null,U),q.return=$,q;case M:return U=Zp(U,$.mode,q),U.return=$,U;case Ne:var ye=U._init;return he($,ye(U._payload),q)}if(Zr(U)||ie(U))return U=oo(U,$.mode,q,null),U.return=$,U;tc($,U)}return null}function ue($,U,q,ye){var ke=U!==null?U.key:null;if(typeof q=="string"&&q!==""||typeof q=="number")return ke!==null?null:R($,U,""+q,ye);if(typeof q=="object"&&q!==null){switch(q.$$typeof){case Y:return q.key===ke?F($,U,q,ye):null;case M:return q.key===ke?K($,U,q,ye):null;case Ne:return ke=q._init,ue($,U,ke(q._payload),ye)}if(Zr(q)||ie(q))return ke!==null?null:ce($,U,q,ye,null);tc($,q)}return null}function we($,U,q,ye,ke){if(typeof ye=="string"&&ye!==""||typeof ye=="number")return $=$.get(q)||null,R(U,$,""+ye,ke);if(typeof ye=="object"&&ye!==null){switch(ye.$$typeof){case Y:return $=$.get(ye.key===null?q:ye.key)||null,F(U,$,ye,ke);case M:return $=$.get(ye.key===null?q:ye.key)||null,K(U,$,ye,ke);case Ne:var De=ye._init;return we($,U,q,De(ye._payload),ke)}if(Zr(ye)||ie(ye))return $=$.get(q)||null,ce(U,$,ye,ke,null);tc(U,ye)}return null}function ve($,U,q,ye){for(var ke=null,De=null,Me=U,Ue=U=0,Ht=null;Me!==null&&Ue<q.length;Ue++){Me.index>Ue?(Ht=Me,Me=null):Ht=Me.sibling;var et=ue($,Me,q[Ue],ye);if(et===null){Me===null&&(Me=Ht);break}i&&Me&&et.alternate===null&&s($,Me),U=y(et,U,Ue),De===null?ke=et:De.sibling=et,De=et,Me=Ht}if(Ue===q.length)return l($,Me),pt&&Xi($,Ue),ke;if(Me===null){for(;Ue<q.length;Ue++)Me=he($,q[Ue],ye),Me!==null&&(U=y(Me,U,Ue),De===null?ke=Me:De.sibling=Me,De=Me);return pt&&Xi($,Ue),ke}for(Me=f($,Me);Ue<q.length;Ue++)Ht=we(Me,$,Ue,q[Ue],ye),Ht!==null&&(i&&Ht.alternate!==null&&Me.delete(Ht.key===null?Ue:Ht.key),U=y(Ht,U,Ue),De===null?ke=Ht:De.sibling=Ht,De=Ht);return i&&Me.forEach(function(bi){return s($,bi)}),pt&&Xi($,Ue),ke}function Ce($,U,q,ye){var ke=ie(q);if(typeof ke!="function")throw Error(n(150));if(q=ke.call(q),q==null)throw Error(n(151));for(var De=ke=null,Me=U,Ue=U=0,Ht=null,et=q.next();Me!==null&&!et.done;Ue++,et=q.next()){Me.index>Ue?(Ht=Me,Me=null):Ht=Me.sibling;var bi=ue($,Me,et.value,ye);if(bi===null){Me===null&&(Me=Ht);break}i&&Me&&bi.alternate===null&&s($,Me),U=y(bi,U,Ue),De===null?ke=bi:De.sibling=bi,De=bi,Me=Ht}if(et.done)return l($,Me),pt&&Xi($,Ue),ke;if(Me===null){for(;!et.done;Ue++,et=q.next())et=he($,et.value,ye),et!==null&&(U=y(et,U,Ue),De===null?ke=et:De.sibling=et,De=et);return pt&&Xi($,Ue),ke}for(Me=f($,Me);!et.done;Ue++,et=q.next())et=we(Me,$,Ue,et.value,ye),et!==null&&(i&&et.alternate!==null&&Me.delete(et.key===null?Ue:et.key),U=y(et,U,Ue),De===null?ke=et:De.sibling=et,De=et);return i&&Me.forEach(function(rF){return s($,rF)}),pt&&Xi($,Ue),ke}function _t($,U,q,ye){if(typeof q=="object"&&q!==null&&q.type===G&&q.key===null&&(q=q.props.children),typeof q=="object"&&q!==null){switch(q.$$typeof){case Y:e:{for(var ke=q.key,De=U;De!==null;){if(De.key===ke){if(ke=q.type,ke===G){if(De.tag===7){l($,De.sibling),U=g(De,q.props.children),U.return=$,$=U;break e}}else if(De.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ne&&h2(ke)===De.type){l($,De.sibling),U=g(De,q.props),U.ref=Ua($,De,q),U.return=$,$=U;break e}l($,De);break}else s($,De);De=De.sibling}q.type===G?(U=oo(q.props.children,$.mode,ye,q.key),U.return=$,$=U):(ye=vc(q.type,q.key,q.props,null,$.mode,ye),ye.ref=Ua($,U,q),ye.return=$,$=ye)}return w($);case M:e:{for(De=q.key;U!==null;){if(U.key===De)if(U.tag===4&&U.stateNode.containerInfo===q.containerInfo&&U.stateNode.implementation===q.implementation){l($,U.sibling),U=g(U,q.children||[]),U.return=$,$=U;break e}else{l($,U);break}else s($,U);U=U.sibling}U=Zp(q,$.mode,ye),U.return=$,$=U}return w($);case Ne:return De=q._init,_t($,U,De(q._payload),ye)}if(Zr(q))return ve($,U,q,ye);if(ie(q))return Ce($,U,q,ye);tc($,q)}return typeof q=="string"&&q!==""||typeof q=="number"?(q=""+q,U!==null&&U.tag===6?(l($,U.sibling),U=g(U,q),U.return=$,$=U):(l($,U),U=Jp(q,$.mode,ye),U.return=$,$=U),w($)):l($,U)}return _t}var ls=p2(!0),m2=p2(!1),nc=li(null),rc=null,cs=null,up=null;function lp(){up=cs=rc=null}function cp(i){var s=nc.current;ct(nc),i._currentValue=s}function dp(i,s,l){for(;i!==null;){var f=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,f!==null&&(f.childLanes|=s)):f!==null&&(f.childLanes&s)!==s&&(f.childLanes|=s),i===l)break;i=i.return}}function ds(i,s){rc=i,up=cs=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(En=!0),i.firstContext=null)}function Un(i){var s=i._currentValue;if(up!==i)if(i={context:i,memoizedValue:s,next:null},cs===null){if(rc===null)throw Error(n(308));cs=i,rc.dependencies={lanes:0,firstContext:i}}else cs=cs.next=i;return s}var Ji=null;function fp(i){Ji===null?Ji=[i]:Ji.push(i)}function g2(i,s,l,f){var g=s.interleaved;return g===null?(l.next=l,fp(s)):(l.next=g.next,g.next=l),s.interleaved=l,Mr(i,f)}function Mr(i,s){i.lanes|=s;var l=i.alternate;for(l!==null&&(l.lanes|=s),l=i,i=i.return;i!==null;)i.childLanes|=s,l=i.alternate,l!==null&&(l.childLanes|=s),l=i,i=i.return;return l.tag===3?l.stateNode:null}var fi=!1;function hp(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function E2(i,s){i=i.updateQueue,s.updateQueue===i&&(s.updateQueue={baseState:i.baseState,firstBaseUpdate:i.firstBaseUpdate,lastBaseUpdate:i.lastBaseUpdate,shared:i.shared,effects:i.effects})}function Fr(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function hi(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,Mr(i,l)}return g=f.interleaved,g===null?(s.next=s,fp(f)):(s.next=g.next,g.next=s),f.interleaved=s,Mr(i,l)}function ic(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,Ch(i,l)}}function y2(i,s){var l=i.updateQueue,f=i.alternate;if(f!==null&&(f=f.updateQueue,l===f)){var g=null,y=null;if(l=l.firstBaseUpdate,l!==null){do{var w={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};y===null?g=y=w:y=y.next=w,l=l.next}while(l!==null);y===null?g=y=s:y=y.next=s}else g=y=s;l={baseState:f.baseState,firstBaseUpdate:g,lastBaseUpdate:y,shared:f.shared,effects:f.effects},i.updateQueue=l;return}i=l.lastBaseUpdate,i===null?l.firstBaseUpdate=s:i.next=s,l.lastBaseUpdate=s}function oc(i,s,l,f){var g=i.updateQueue;fi=!1;var y=g.firstBaseUpdate,w=g.lastBaseUpdate,R=g.shared.pending;if(R!==null){g.shared.pending=null;var F=R,K=F.next;F.next=null,w===null?y=K:w.next=K,w=F;var ce=i.alternate;ce!==null&&(ce=ce.updateQueue,R=ce.lastBaseUpdate,R!==w&&(R===null?ce.firstBaseUpdate=K:R.next=K,ce.lastBaseUpdate=F))}if(y!==null){var he=g.baseState;w=0,ce=K=F=null,R=y;do{var ue=R.lane,we=R.eventTime;if((f&ue)===ue){ce!==null&&(ce=ce.next={eventTime:we,lane:0,tag:R.tag,payload:R.payload,callback:R.callback,next:null});e:{var ve=i,Ce=R;switch(ue=s,we=l,Ce.tag){case 1:if(ve=Ce.payload,typeof ve=="function"){he=ve.call(we,he,ue);break e}he=ve;break e;case 3:ve.flags=ve.flags&-65537|128;case 0:if(ve=Ce.payload,ue=typeof ve=="function"?ve.call(we,he,ue):ve,ue==null)break e;he=v({},he,ue);break e;case 2:fi=!0}}R.callback!==null&&R.lane!==0&&(i.flags|=64,ue=g.effects,ue===null?g.effects=[R]:ue.push(R))}else we={eventTime:we,lane:ue,tag:R.tag,payload:R.payload,callback:R.callback,next:null},ce===null?(K=ce=we,F=he):ce=ce.next=we,w|=ue;if(R=R.next,R===null){if(R=g.shared.pending,R===null)break;ue=R,R=ue.next,ue.next=null,g.lastBaseUpdate=ue,g.shared.pending=null}}while(!0);if(ce===null&&(F=he),g.baseState=F,g.firstBaseUpdate=K,g.lastBaseUpdate=ce,s=g.shared.interleaved,s!==null){g=s;do w|=g.lane,g=g.next;while(g!==s)}else y===null&&(g.shared.lanes=0);to|=w,i.lanes=w,i.memoizedState=he}}function T2(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 Ha={},xr=li(Ha),za=li(Ha),ja=li(Ha);function Zi(i){if(i===Ha)throw Error(n(174));return i}function pp(i,s){switch(at(ja,s),at(za,i),at(xr,Ha),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(xr),at(xr,s)}function fs(){ct(xr),ct(za),ct(ja)}function b2(i){Zi(ja.current);var s=Zi(xr.current),l=Te(s,i.type);s!==l&&(at(za,i),at(xr,l))}function mp(i){za.current===i&&(ct(xr),ct(za))}var mt=li(0);function sc(i){for(var s=i;s!==null;){if(s.tag===13){var l=s.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||l.data==="$!"))return s}else if(s.tag===19&&s.memoizedProps.revealOrder!==void 0){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var gp=[];function Ep(){for(var i=0;i<gp.length;i++)gp[i]._workInProgressVersionPrimary=null;gp.length=0}var ac=H.ReactCurrentDispatcher,yp=H.ReactCurrentBatchConfig,eo=0,gt=null,It=null,Bt=null,uc=!1,$a=!1,Va=0,vM=0;function Xt(){throw Error(n(321))}function Tp(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 bp(i,s,l,f,g,y){if(eo=y,gt=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,ac.current=i===null||i.memoizedState===null?NM:OM,i=l(f,g),$a){y=0;do{if($a=!1,Va=0,25<=y)throw Error(n(301));y+=1,Bt=It=null,s.updateQueue=null,ac.current=IM,i=l(f,g)}while($a)}if(ac.current=dc,s=It!==null&&It.next!==null,eo=0,Bt=It=gt=null,uc=!1,s)throw Error(n(300));return i}function xp(){var i=Va!==0;return Va=0,i}function wr(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Bt===null?gt.memoizedState=Bt=i:Bt=Bt.next=i,Bt}function Hn(){if(It===null){var i=gt.alternate;i=i!==null?i.memoizedState:null}else i=It.next;var s=Bt===null?gt.memoizedState:Bt.next;if(s!==null)Bt=s,It=i;else{if(i===null)throw Error(n(310));It=i,i={memoizedState:It.memoizedState,baseState:It.baseState,baseQueue:It.baseQueue,queue:It.queue,next:null},Bt===null?gt.memoizedState=Bt=i:Bt=Bt.next=i}return Bt}function qa(i,s){return typeof s=="function"?s(i):s}function wp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=It,g=f.baseQueue,y=l.pending;if(y!==null){if(g!==null){var w=g.next;g.next=y.next,y.next=w}f.baseQueue=g=y,l.pending=null}if(g!==null){y=g.next,f=f.baseState;var R=w=null,F=null,K=y;do{var ce=K.lane;if((eo&ce)===ce)F!==null&&(F=F.next={lane:0,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null}),f=K.hasEagerState?K.eagerState:i(f,K.action);else{var he={lane:ce,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null};F===null?(R=F=he,w=f):F=F.next=he,gt.lanes|=ce,to|=ce}K=K.next}while(K!==null&&K!==y);F===null?w=f:F.next=R,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 y=g.lane,gt.lanes|=y,to|=y,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function _p(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=l.dispatch,g=l.pending,y=s.memoizedState;if(g!==null){l.pending=null;var w=g=g.next;do y=i(y,w.action),w=w.next;while(w!==g);Zn(y,s.memoizedState)||(En=!0),s.memoizedState=y,s.baseQueue===null&&(s.baseState=y),l.lastRenderedState=y}return[y,f]}function x2(){}function w2(i,s){var l=gt,f=Hn(),g=s(),y=!Zn(f.memoizedState,g);if(y&&(f.memoizedState=g,En=!0),f=f.queue,Sp(v2.bind(null,l,f,i),[i]),f.getSnapshot!==s||y||Bt!==null&&Bt.memoizedState.tag&1){if(l.flags|=2048,Ya(9,S2.bind(null,l,f,g,s),void 0,null),Ut===null)throw Error(n(349));(eo&30)!==0||_2(l,s,g)}return g}function _2(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function S2(i,s,l,f){s.value=l,s.getSnapshot=f,A2(s)&&C2(i)}function v2(i,s,l){return l(function(){A2(s)&&C2(i)})}function A2(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!Zn(i,l)}catch(f){return!0}}function C2(i){var s=Mr(i,1);s!==null&&ir(s,i,1,-1)}function k2(i){var s=wr();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:qa,lastRenderedState:i},s.queue=i,i=i.dispatch=kM.bind(null,gt,i),[s.memoizedState,i]}function Ya(i,s,l,f){return i={tag:i,create:s,destroy:l,deps:f,next:null},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.lastEffect=i.next=i):(l=s.lastEffect,l===null?s.lastEffect=i.next=i:(f=l.next,l.next=i,i.next=f,s.lastEffect=i)),i}function N2(){return Hn().memoizedState}function lc(i,s,l,f){var g=wr();gt.flags|=i,g.memoizedState=Ya(1|s,l,void 0,f===void 0?null:f)}function cc(i,s,l,f){var g=Hn();f=f===void 0?null:f;var y=void 0;if(It!==null){var w=It.memoizedState;if(y=w.destroy,f!==null&&Tp(f,w.deps)){g.memoizedState=Ya(s,l,y,f);return}}gt.flags|=i,g.memoizedState=Ya(1|s,l,y,f)}function O2(i,s){return lc(8390656,8,i,s)}function Sp(i,s){return cc(2048,8,i,s)}function I2(i,s){return cc(4,2,i,s)}function R2(i,s){return cc(4,4,i,s)}function P2(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 L2(i,s,l){return l=l!=null?l.concat([i]):null,cc(4,4,P2.bind(null,s,i),l)}function vp(){}function D2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Tp(s,f[1])?f[0]:(l.memoizedState=[i,s],i)}function M2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Tp(s,f[1])?f[0]:(i=i(),l.memoizedState=[i,s],i)}function F2(i,s,l){return(eo&21)===0?(i.baseState&&(i.baseState=!1,En=!0),i.memoizedState=l):(Zn(l,s)||(l=hb(),gt.lanes|=l,to|=l,i.baseState=!0),s)}function AM(i,s){var l=nt;nt=l!==0&&4>l?l:4,i(!0);var f=yp.transition;yp.transition={};try{i(!1),s()}finally{nt=l,yp.transition=f}}function B2(){return Hn().memoizedState}function CM(i,s,l){var f=Ei(i);if(l={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null},U2(i))H2(s,l);else if(l=g2(i,s,l,f),l!==null){var g=on();ir(l,i,f,g),z2(l,s,f)}}function kM(i,s,l){var f=Ei(i),g={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null};if(U2(i))H2(s,g);else{var y=i.alternate;if(i.lanes===0&&(y===null||y.lanes===0)&&(y=s.lastRenderedReducer,y!==null))try{var w=s.lastRenderedState,R=y(w,l);if(g.hasEagerState=!0,g.eagerState=R,Zn(R,w)){var F=s.interleaved;F===null?(g.next=g,fp(s)):(g.next=F.next,F.next=g),s.interleaved=g;return}}catch(K){}l=g2(i,s,g,f),l!==null&&(g=on(),ir(l,i,f,g),z2(l,s,f))}}function U2(i){var s=i.alternate;return i===gt||s!==null&&s===gt}function H2(i,s){$a=uc=!0;var l=i.pending;l===null?s.next=s:(s.next=l.next,l.next=s),i.pending=s}function z2(i,s,l){if((l&4194240)!==0){var f=s.lanes;f&=i.pendingLanes,l|=f,s.lanes=l,Ch(i,l)}}var dc={readContext:Un,useCallback:Xt,useContext:Xt,useEffect:Xt,useImperativeHandle:Xt,useInsertionEffect:Xt,useLayoutEffect:Xt,useMemo:Xt,useReducer:Xt,useRef:Xt,useState:Xt,useDebugValue:Xt,useDeferredValue:Xt,useTransition:Xt,useMutableSource:Xt,useSyncExternalStore:Xt,useId:Xt,unstable_isNewReconciler:!1},NM={readContext:Un,useCallback:function(i,s){return wr().memoizedState=[i,s===void 0?null:s],i},useContext:Un,useEffect:O2,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,lc(4194308,4,P2.bind(null,s,i),l)},useLayoutEffect:function(i,s){return lc(4194308,4,i,s)},useInsertionEffect:function(i,s){return lc(4,2,i,s)},useMemo:function(i,s){var l=wr();return s=s===void 0?null:s,i=i(),l.memoizedState=[i,s],i},useReducer:function(i,s,l){var f=wr();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=CM.bind(null,gt,i),[f.memoizedState,i]},useRef:function(i){var s=wr();return i={current:i},s.memoizedState=i},useState:k2,useDebugValue:vp,useDeferredValue:function(i){return wr().memoizedState=i},useTransition:function(){var i=k2(!1),s=i[0];return i=AM.bind(null,i[1]),wr().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var f=gt,g=wr();if(pt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Ut===null)throw Error(n(349));(eo&30)!==0||_2(f,s,l)}g.memoizedState=l;var y={value:l,getSnapshot:s};return g.queue=y,O2(v2.bind(null,f,y,i),[i]),f.flags|=2048,Ya(9,S2.bind(null,f,y,l,s),void 0,null),l},useId:function(){var i=wr(),s=Ut.identifierPrefix;if(pt){var l=Dr,f=Lr;l=(f&~(1<<32-Jn(f)-1)).toString(32)+l,s=":"+s+"R"+l,l=Va++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=vM++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},OM={readContext:Un,useCallback:D2,useContext:Un,useEffect:Sp,useImperativeHandle:L2,useInsertionEffect:I2,useLayoutEffect:R2,useMemo:M2,useReducer:wp,useRef:N2,useState:function(){return wp(qa)},useDebugValue:vp,useDeferredValue:function(i){var s=Hn();return F2(s,It.memoizedState,i)},useTransition:function(){var i=wp(qa)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:x2,useSyncExternalStore:w2,useId:B2,unstable_isNewReconciler:!1},IM={readContext:Un,useCallback:D2,useContext:Un,useEffect:Sp,useImperativeHandle:L2,useInsertionEffect:I2,useLayoutEffect:R2,useMemo:M2,useReducer:_p,useRef:N2,useState:function(){return _p(qa)},useDebugValue:vp,useDeferredValue:function(i){var s=Hn();return It===null?s.memoizedState=i:F2(s,It.memoizedState,i)},useTransition:function(){var i=_p(qa)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:x2,useSyncExternalStore:w2,useId:B2,unstable_isNewReconciler:!1};function tr(i,s){if(i&&i.defaultProps){s=v({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function Ap(i,s,l,f){s=i.memoizedState,l=l(f,s),l=l==null?s:v({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var fc={isMounted:function(i){return(i=i._reactInternals)?Wi(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var f=on(),g=Ei(i),y=Fr(f,g);y.payload=s,l!=null&&(y.callback=l),s=hi(i,y,g),s!==null&&(ir(s,i,g,f),ic(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var f=on(),g=Ei(i),y=Fr(f,g);y.tag=1,y.payload=s,l!=null&&(y.callback=l),s=hi(i,y,g),s!==null&&(ir(s,i,g,f),ic(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=on(),f=Ei(i),g=Fr(l,f);g.tag=2,s!=null&&(g.callback=s),s=hi(i,g,f),s!==null&&(ir(s,i,f,l),ic(s,i,f))}};function j2(i,s,l,f,g,y,w){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(f,y,w):s.prototype&&s.prototype.isPureReactComponent?!Ra(l,f)||!Ra(g,y):!0}function $2(i,s,l){var f=!1,g=ci,y=s.contextType;return typeof y=="object"&&y!==null?y=Un(y):(g=gn(s)?Ki:Qt.current,f=s.contextTypes,y=(f=f!=null)?os(i,g):ci),s=new s(l,y),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=fc,i.stateNode=s,s._reactInternals=i,f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=y),s}function V2(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&&fc.enqueueReplaceState(s,s.state,null)}function Cp(i,s,l,f){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},hp(i);var y=s.contextType;typeof y=="object"&&y!==null?g.context=Un(y):(y=gn(s)?Ki:Qt.current,g.context=os(i,y)),g.state=i.memoizedState,y=s.getDerivedStateFromProps,typeof y=="function"&&(Ap(i,s,y,l),g.state=i.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(s=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),s!==g.state&&fc.enqueueReplaceState(g,g.state,null),oc(i,l,g,f),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function hs(i,s){try{var l="",f=s;do l+=Pe(f),f=f.return;while(f);var g=l}catch(y){g=`
|
|
20
|
+
`+g[w].replace(" at new "," at ");return i.displayName&&F.includes("<anonymous>")&&(F=F.replace("<anonymous>",i.displayName)),F}while(1<=w&&0<=R);break}}}finally{k=!1,Error.prepareStackTrace=l}return(i=i?i.displayName||i.name:"")?Z(i):""}function Pe(i){switch(i.tag){case 5:return Z(i.type);case 16:return Z("Lazy");case 13:return Z("Suspense");case 19:return Z("SuspenseList");case 0:case 2:case 15:return i=xe(i.type,!1),i;case 11:return i=xe(i.type.render,!1),i;case 1:return i=xe(i.type,!0),i;default:return""}}function Ne(i){if(i==null)return null;if(typeof i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case Q:return"Fragment";case M:return"Portal";case re:return"Profiler";case Ee:return"StrictMode";case oe:return"Suspense";case de:return"SuspenseList"}if(typeof i=="object")switch(i.$$typeof){case W:return(i.displayName||"Context")+".Consumer";case U:return(i._context.displayName||"Context")+".Provider";case te: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:Ne(i.type)||"Memo";case Ie:s=i._payload,i=i._init;try{return Ne(i(s))}catch(l){}}return null}function He(i){var s=i.type;switch(i.tag){case 24:return"Cache";case 9:return(s.displayName||"Context")+".Consumer";case 10:return(s._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return i=s.render,i=i.displayName||i.name||"",s.displayName||(i!==""?"ForwardRef("+i+")":"ForwardRef");case 7:return"Fragment";case 5:return s;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Ne(s);case 8:return s===Ee?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s}return null}function Se(i){switch(typeof i){case"boolean":case"number":case"string":case"undefined":return i;case"object":return i;default:return""}}function 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,y=l.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return g.call(this)},set:function(w){f=""+w,y.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 qi(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 Jr(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 v({},s,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l!=null?l:i._wrapperState.initialChecked})}function pa(i,s){var l=s.defaultValue==null?"":s.defaultValue,f=s.checked!=null?s.checked:s.defaultChecked;l=Se(s.value!=null?s.value:l),i._wrapperState={initialChecked:f,initialValue:l,controlled:s.type==="checkbox"||s.type==="radio"?s.checked!=null:s.value!=null}}function ma(i,s){s=s.checked,s!=null&&I(i,"checked",s,!1)}function Yo(i,s){ma(i,s);var l=Se(s.value),f=s.type;if(l!=null)f==="number"?(l===0&&i.value===""||i.value!=l)&&(i.value=""+l):i.value!==""+l&&(i.value=""+l);else if(f==="submit"||f==="reset"){i.removeAttribute("value");return}s.hasOwnProperty("value")?Wo(i,s.type,l):s.hasOwnProperty("defaultValue")&&Wo(i,s.type,Se(s.defaultValue)),s.checked==null&&s.defaultChecked!=null&&(i.defaultChecked=!!s.defaultChecked)}function wl(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 Wo(i,s,l){(s!=="number"||Jr(i.ownerDocument)!==i)&&(l==null?i.defaultValue=""+i._wrapperState.initialValue:i.defaultValue!==""+l&&(i.defaultValue=""+l))}var Zr=Array.isArray;function ei(i,s,l,f){if(i=i.options,s){s={};for(var g=0;g<l.length;g++)s["$"+l[g]]=!0;for(l=0;l<i.length;l++)g=s.hasOwnProperty("$"+i[l].value),i[l].selected!==g&&(i[l].selected=g),g&&f&&(i[l].defaultSelected=!0)}else{for(l=""+Se(l),s=null,g=0;g<i.length;g++){if(i[g].value===l){i[g].selected=!0,f&&(i[g].defaultSelected=!0);return}s!==null||i[g].disabled||(s=i[g])}s!==null&&(s.selected=!0)}}function ga(i,s){if(s.dangerouslySetInnerHTML!=null)throw Error(n(91));return v({},s,{value:void 0,defaultValue:void 0,children:""+i._wrapperState.initialValue})}function _l(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(Zr(l)){if(1<l.length)throw Error(n(93));l=l[0]}s=l}s==null&&(s=""),l=s}i._wrapperState={initialValue:Se(l)}}function Sl(i,s){var l=Se(s.value),f=Se(s.defaultValue);l!=null&&(l=""+l,l!==i.value&&(i.value=l),s.defaultValue==null&&i.defaultValue!==l&&(i.defaultValue=l)),f!=null&&(i.defaultValue=""+f)}function vl(i){var s=i.textContent;s===i._wrapperState.initialValue&&s!==""&&s!==null&&(i.value=s)}function ne(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"?ne(s):i==="http://www.w3.org/2000/svg"&&s==="foreignObject"?"http://www.w3.org/1999/xhtml":i}var Be,Ye=(function(i){return typeof MSApp!="undefined"&&MSApp.execUnsafeLocalFunction?function(s,l,f,g){MSApp.execUnsafeLocalFunction(function(){return i(s,l,f,g)})}:i})(function(i,s){if(i.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in i)i.innerHTML=s;else{for(Be=Be||document.createElement("div"),Be.innerHTML="<svg>"+s.valueOf().toString()+"</svg>",s=Be.firstChild;i.firstChild;)i.removeChild(i.firstChild);for(;s.firstChild;)i.appendChild(s.firstChild)}});function 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 zt={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Ir=["Webkit","ms","Moz","O"];Object.keys(zt).forEach(function(i){Ir.forEach(function(s){s=s+i.charAt(0).toUpperCase()+i.substring(1),zt[s]=zt[i]})});function Mn(i,s,l){return s==null||typeof s=="boolean"||s===""?"":l||typeof s!="number"||s===0||zt.hasOwnProperty(i)&&zt[i]?(""+s).trim():s+"px"}function ti(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 Yi=v({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 jt(i,s){if(s){if(Yi[i]&&(s.children!=null||s.dangerouslySetInnerHTML!=null))throw Error(n(137,i));if(s.dangerouslySetInnerHTML!=null){if(s.children!=null)throw Error(n(60));if(typeof s.dangerouslySetInnerHTML!="object"||!("__html"in s.dangerouslySetInnerHTML))throw Error(n(61))}if(s.style!=null&&typeof s.style!="object")throw Error(n(62))}}function yr(i,s){if(i.indexOf("-")===-1)return typeof s.is=="string";switch(i){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var vn=null;function Th(i){return i=i.target||i.srcElement||window,i.correspondingUseElement&&(i=i.correspondingUseElement),i.nodeType===3?i.parentNode:i}var bh=null,Go=null,Ko=null;function ZT(i){if(i=Ba(i)){if(typeof bh!="function")throw Error(n(280));var s=i.stateNode;s&&(s=Gl(s),bh(i.stateNode,i.type,s))}}function eb(i){Go?Ko?Ko.push(i):Ko=[i]:Go=i}function tb(){if(Go){var i=Go,s=Ko;if(Ko=Go=null,ZT(i),s)for(i=0;i<s.length;i++)ZT(s[i])}}function nb(i,s){return i(s)}function rb(){}var xh=!1;function ib(i,s,l){if(xh)return i(s,l);xh=!0;try{return nb(i,s,l)}finally{xh=!1,(Go!==null||Ko!==null)&&(rb(),tb())}}function Ea(i,s){var l=i.stateNode;if(l===null)return null;var f=Gl(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 wh=!1;if(c)try{var ya={};Object.defineProperty(ya,"passive",{get:function(){wh=!0}}),window.addEventListener("test",ya,ya),window.removeEventListener("test",ya,ya)}catch(i){wh=!1}function c8(i,s,l,f,g,y,w,R,F){var K=Array.prototype.slice.call(arguments,3);try{s.apply(l,K)}catch(ce){this.onError(ce)}}var Ta=!1,Al=null,Cl=!1,_h=null,d8={onError:function(i){Ta=!0,Al=i}};function f8(i,s,l,f,g,y,w,R,F){Ta=!1,Al=null,c8.apply(d8,arguments)}function h8(i,s,l,f,g,y,w,R,F){if(f8.apply(this,arguments),Ta){if(Ta){var K=Al;Ta=!1,Al=null}else throw Error(n(198));Cl||(Cl=!0,_h=K)}}function Wi(i){var s=i,l=i;if(i.alternate)for(;s.return;)s=s.return;else{i=s;do s=i,(s.flags&4098)!==0&&(l=s.return),i=s.return;while(i)}return s.tag===3?l:null}function ob(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 sb(i){if(Wi(i)!==i)throw Error(n(188))}function p8(i){var s=i.alternate;if(!s){if(s=Wi(i),s===null)throw Error(n(188));return s!==i?null:i}for(var l=i,f=s;;){var g=l.return;if(g===null)break;var y=g.alternate;if(y===null){if(f=g.return,f!==null){l=f;continue}break}if(g.child===y.child){for(y=g.child;y;){if(y===l)return sb(g),i;if(y===f)return sb(g),s;y=y.sibling}throw Error(n(188))}if(l.return!==f.return)l=g,f=y;else{for(var w=!1,R=g.child;R;){if(R===l){w=!0,l=g,f=y;break}if(R===f){w=!0,f=g,l=y;break}R=R.sibling}if(!w){for(R=y.child;R;){if(R===l){w=!0,l=y,f=g;break}if(R===f){w=!0,f=y,l=g;break}R=R.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 ab(i){return i=p8(i),i!==null?ub(i):null}function ub(i){if(i.tag===5||i.tag===6)return i;for(i=i.child;i!==null;){var s=ub(i);if(s!==null)return s;i=i.sibling}return null}var lb=t.unstable_scheduleCallback,cb=t.unstable_cancelCallback,m8=t.unstable_shouldYield,g8=t.unstable_requestPaint,wt=t.unstable_now,E8=t.unstable_getCurrentPriorityLevel,Sh=t.unstable_ImmediatePriority,db=t.unstable_UserBlockingPriority,kl=t.unstable_NormalPriority,y8=t.unstable_LowPriority,fb=t.unstable_IdlePriority,Nl=null,Tr=null;function T8(i){if(Tr&&typeof Tr.onCommitFiberRoot=="function")try{Tr.onCommitFiberRoot(Nl,i,void 0,(i.current.flags&128)===128)}catch(s){}}var Jn=Math.clz32?Math.clz32:w8,b8=Math.log,x8=Math.LN2;function w8(i){return i>>>=0,i===0?32:31-(b8(i)/x8|0)|0}var Ol=64,Il=4194304;function ba(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 Rl(i,s){var l=i.pendingLanes;if(l===0)return 0;var f=0,g=i.suspendedLanes,y=i.pingedLanes,w=l&268435455;if(w!==0){var R=w&~g;R!==0?f=ba(R):(y&=w,y!==0&&(f=ba(y)))}else w=l&~g,w!==0?f=ba(w):y!==0&&(f=ba(y));if(f===0)return 0;if(s!==0&&s!==f&&(s&g)===0&&(g=f&-f,y=s&-s,g>=y||g===16&&(y&4194240)!==0))return s;if((f&4)!==0&&(f|=l&16),s=i.entangledLanes,s!==0)for(i=i.entanglements,s&=f;0<s;)l=31-Jn(s),g=1<<l,f|=i[l],s&=~g;return f}function _8(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 S8(i,s){for(var l=i.suspendedLanes,f=i.pingedLanes,g=i.expirationTimes,y=i.pendingLanes;0<y;){var w=31-Jn(y),R=1<<w,F=g[w];F===-1?((R&l)===0||(R&f)!==0)&&(g[w]=_8(R,s)):F<=s&&(i.expiredLanes|=R),y&=~R}}function vh(i){return i=i.pendingLanes&-1073741825,i!==0?i:i&1073741824?1073741824:0}function hb(){var i=Ol;return Ol<<=1,(Ol&4194240)===0&&(Ol=64),i}function Ah(i){for(var s=[],l=0;31>l;l++)s.push(i);return s}function xa(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 v8(i,s){var l=i.pendingLanes&~s;i.pendingLanes=s,i.suspendedLanes=0,i.pingedLanes=0,i.expiredLanes&=s,i.mutableReadLanes&=s,i.entangledLanes&=s,s=i.entanglements;var f=i.eventTimes;for(i=i.expirationTimes;0<l;){var g=31-Jn(l),y=1<<g;s[g]=0,f[g]=-1,i[g]=-1,l&=~y}}function Ch(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 pb(i){return i&=-i,1<i?4<i?(i&268435455)!==0?16:536870912:4:1}var mb,kh,gb,Eb,yb,Nh=!1,Pl=[],ni=null,ri=null,ii=null,wa=new Map,_a=new Map,oi=[],A8="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 Tb(i,s){switch(i){case"focusin":case"focusout":ni=null;break;case"dragenter":case"dragleave":ri=null;break;case"mouseover":case"mouseout":ii=null;break;case"pointerover":case"pointerout":wa.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":_a.delete(s.pointerId)}}function Sa(i,s,l,f,g,y){return i===null||i.nativeEvent!==y?(i={blockedOn:s,domEventName:l,eventSystemFlags:f,nativeEvent:y,targetContainers:[g]},s!==null&&(s=Ba(s),s!==null&&kh(s)),i):(i.eventSystemFlags|=f,s=i.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),i)}function C8(i,s,l,f,g){switch(s){case"focusin":return ni=Sa(ni,i,s,l,f,g),!0;case"dragenter":return ri=Sa(ri,i,s,l,f,g),!0;case"mouseover":return ii=Sa(ii,i,s,l,f,g),!0;case"pointerover":var y=g.pointerId;return wa.set(y,Sa(wa.get(y)||null,i,s,l,f,g)),!0;case"gotpointercapture":return y=g.pointerId,_a.set(y,Sa(_a.get(y)||null,i,s,l,f,g)),!0}return!1}function bb(i){var s=Gi(i.target);if(s!==null){var l=Wi(s);if(l!==null){if(s=l.tag,s===13){if(s=ob(l),s!==null){i.blockedOn=s,yb(i.priority,function(){gb(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 Ll(i){if(i.blockedOn!==null)return!1;for(var s=i.targetContainers;0<s.length;){var l=Ih(i.domEventName,i.eventSystemFlags,s[0],i.nativeEvent);if(l===null){l=i.nativeEvent;var f=new l.constructor(l.type,l);vn=f,l.target.dispatchEvent(f),vn=null}else return s=Ba(l),s!==null&&kh(s),i.blockedOn=l,!1;s.shift()}return!0}function xb(i,s,l){Ll(i)&&l.delete(s)}function k8(){Nh=!1,ni!==null&&Ll(ni)&&(ni=null),ri!==null&&Ll(ri)&&(ri=null),ii!==null&&Ll(ii)&&(ii=null),wa.forEach(xb),_a.forEach(xb)}function va(i,s){i.blockedOn===s&&(i.blockedOn=null,Nh||(Nh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,k8)))}function Aa(i){function s(g){return va(g,i)}if(0<Pl.length){va(Pl[0],i);for(var l=1;l<Pl.length;l++){var f=Pl[l];f.blockedOn===i&&(f.blockedOn=null)}}for(ni!==null&&va(ni,i),ri!==null&&va(ri,i),ii!==null&&va(ii,i),wa.forEach(s),_a.forEach(s),l=0;l<oi.length;l++)f=oi[l],f.blockedOn===i&&(f.blockedOn=null);for(;0<oi.length&&(l=oi[0],l.blockedOn===null);)bb(l),l.blockedOn===null&&oi.shift()}var Qo=z.ReactCurrentBatchConfig,Dl=!0;function N8(i,s,l,f){var g=nt,y=Qo.transition;Qo.transition=null;try{nt=1,Oh(i,s,l,f)}finally{nt=g,Qo.transition=y}}function O8(i,s,l,f){var g=nt,y=Qo.transition;Qo.transition=null;try{nt=4,Oh(i,s,l,f)}finally{nt=g,Qo.transition=y}}function Oh(i,s,l,f){if(Dl){var g=Ih(i,s,l,f);if(g===null)Gh(i,s,f,Ml,l),Tb(i,f);else if(C8(g,i,s,l,f))f.stopPropagation();else if(Tb(i,f),s&4&&-1<A8.indexOf(i)){for(;g!==null;){var y=Ba(g);if(y!==null&&mb(y),y=Ih(i,s,l,f),y===null&&Gh(i,s,f,Ml,l),y===g)break;g=y}g!==null&&f.stopPropagation()}else Gh(i,s,f,null,l)}}var Ml=null;function Ih(i,s,l,f){if(Ml=null,i=Th(f),i=Gi(i),i!==null)if(s=Wi(i),s===null)i=null;else if(l=s.tag,l===13){if(i=ob(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 Ml=i,null}function wb(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(E8()){case Sh:return 1;case db:return 4;case kl:case y8:return 16;case fb:return 536870912;default:return 16}default:return 16}}var si=null,Rh=null,Fl=null;function _b(){if(Fl)return Fl;var i,s=Rh,l=s.length,f,g="value"in si?si.value:si.textContent,y=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[y-f];f++);return Fl=g.slice(i,1<f?1-f:void 0)}function Bl(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 Ul(){return!0}function Sb(){return!1}function An(i){function s(l,f,g,y,w){this._reactName=l,this._targetInst=g,this.type=f,this.nativeEvent=y,this.target=w,this.currentTarget=null;for(var R in i)i.hasOwnProperty(R)&&(l=i[R],this[R]=l?l(y):y[R]);return this.isDefaultPrevented=(y.defaultPrevented!=null?y.defaultPrevented:y.returnValue===!1)?Ul:Sb,this.isPropagationStopped=Sb,this}return v(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=Ul)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Ul)},persist:function(){},isPersistent:Ul}),s}var Xo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(i){return i.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ph=An(Xo),Ca=v({},Xo,{view:0,detail:0}),I8=An(Ca),Lh,Dh,ka,Hl=v({},Ca,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Fh,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!==ka&&(ka&&i.type==="mousemove"?(Lh=i.screenX-ka.screenX,Dh=i.screenY-ka.screenY):Dh=Lh=0,ka=i),Lh)},movementY:function(i){return"movementY"in i?i.movementY:Dh}}),vb=An(Hl),R8=v({},Hl,{dataTransfer:0}),P8=An(R8),L8=v({},Ca,{relatedTarget:0}),Mh=An(L8),D8=v({},Xo,{animationName:0,elapsedTime:0,pseudoElement:0}),M8=An(D8),F8=v({},Xo,{clipboardData:function(i){return"clipboardData"in i?i.clipboardData:window.clipboardData}}),B8=An(F8),U8=v({},Xo,{data:0}),Ab=An(U8),H8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},z8={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"},j8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function $8(i){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(i):(i=j8[i])?!!s[i]:!1}function Fh(){return $8}var V8=v({},Ca,{key:function(i){if(i.key){var s=H8[i.key]||i.key;if(s!=="Unidentified")return s}return i.type==="keypress"?(i=Bl(i),i===13?"Enter":String.fromCharCode(i)):i.type==="keydown"||i.type==="keyup"?z8[i.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Fh,charCode:function(i){return i.type==="keypress"?Bl(i):0},keyCode:function(i){return i.type==="keydown"||i.type==="keyup"?i.keyCode:0},which:function(i){return i.type==="keypress"?Bl(i):i.type==="keydown"||i.type==="keyup"?i.keyCode:0}}),q8=An(V8),Y8=v({},Hl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Cb=An(Y8),W8=v({},Ca,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Fh}),G8=An(W8),K8=v({},Xo,{propertyName:0,elapsedTime:0,pseudoElement:0}),Q8=An(K8),X8=v({},Hl,{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}),J8=An(X8),Z8=[9,13,27,32],Bh=c&&"CompositionEvent"in window,Na=null;c&&"documentMode"in document&&(Na=document.documentMode);var eM=c&&"TextEvent"in window&&!Na,kb=c&&(!Bh||Na&&8<Na&&11>=Na),Nb=" ",Ob=!1;function Ib(i,s){switch(i){case"keyup":return Z8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Rb(i){return i=i.detail,typeof i=="object"&&"data"in i?i.data:null}var Jo=!1;function tM(i,s){switch(i){case"compositionend":return Rb(s);case"keypress":return s.which!==32?null:(Ob=!0,Nb);case"textInput":return i=s.data,i===Nb&&Ob?null:i;default:return null}}function nM(i,s){if(Jo)return i==="compositionend"||!Bh&&Ib(i,s)?(i=_b(),Fl=Rh=si=null,Jo=!1,i):null;switch(i){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return kb&&s.locale!=="ko"?null:s.data;default:return null}}var rM={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 Pb(i){var s=i&&i.nodeName&&i.nodeName.toLowerCase();return s==="input"?!!rM[i.type]:s==="textarea"}function Lb(i,s,l,f){eb(f),s=ql(s,"onChange"),0<s.length&&(l=new Ph("onChange","change",null,l,f),i.push({event:l,listeners:s}))}var Oa=null,Ia=null;function iM(i){Jb(i,0)}function zl(i){var s=rs(i);if(qi(s))return i}function oM(i,s){if(i==="change")return s}var Db=!1;if(c){var Uh;if(c){var Hh="oninput"in document;if(!Hh){var Mb=document.createElement("div");Mb.setAttribute("oninput","return;"),Hh=typeof Mb.oninput=="function"}Uh=Hh}else Uh=!1;Db=Uh&&(!document.documentMode||9<document.documentMode)}function Fb(){Oa&&(Oa.detachEvent("onpropertychange",Bb),Ia=Oa=null)}function Bb(i){if(i.propertyName==="value"&&zl(Ia)){var s=[];Lb(s,Ia,i,Th(i)),ib(iM,s)}}function sM(i,s,l){i==="focusin"?(Fb(),Oa=s,Ia=l,Oa.attachEvent("onpropertychange",Bb)):i==="focusout"&&Fb()}function aM(i){if(i==="selectionchange"||i==="keyup"||i==="keydown")return zl(Ia)}function uM(i,s){if(i==="click")return zl(s)}function lM(i,s){if(i==="input"||i==="change")return zl(s)}function cM(i,s){return i===s&&(i!==0||1/i===1/s)||i!==i&&s!==s}var Zn=typeof Object.is=="function"?Object.is:cM;function Ra(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 Ub(i){for(;i&&i.firstChild;)i=i.firstChild;return i}function Hb(i,s){var l=Ub(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=Ub(l)}}function zb(i,s){return i&&s?i===s?!0:i&&i.nodeType===3?!1:s&&s.nodeType===3?zb(i,s.parentNode):"contains"in i?i.contains(s):i.compareDocumentPosition?!!(i.compareDocumentPosition(s)&16):!1:!1}function jb(){for(var i=window,s=Jr();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=Jr(i.document)}return s}function zh(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 dM(i){var s=jb(),l=i.focusedElem,f=i.selectionRange;if(s!==l&&l&&l.ownerDocument&&zb(l.ownerDocument.documentElement,l)){if(f!==null&&zh(l)){if(s=f.start,i=f.end,i===void 0&&(i=s),"selectionStart"in l)l.selectionStart=s,l.selectionEnd=Math.min(i,l.value.length);else if(i=(s=l.ownerDocument||document)&&s.defaultView||window,i.getSelection){i=i.getSelection();var g=l.textContent.length,y=Math.min(f.start,g);f=f.end===void 0?y:Math.min(f.end,g),!i.extend&&y>f&&(g=f,f=y,y=g),g=Hb(l,y);var w=Hb(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(),y>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 fM=c&&"documentMode"in document&&11>=document.documentMode,Zo=null,jh=null,Pa=null,$h=!1;function $b(i,s,l){var f=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;$h||Zo==null||Zo!==Jr(f)||(f=Zo,"selectionStart"in f&&zh(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}),Pa&&Ra(Pa,f)||(Pa=f,f=ql(jh,"onSelect"),0<f.length&&(s=new Ph("onSelect","select",null,s,l),i.push({event:s,listeners:f}),s.target=Zo)))}function jl(i,s){var l={};return l[i.toLowerCase()]=s.toLowerCase(),l["Webkit"+i]="webkit"+s,l["Moz"+i]="moz"+s,l}var es={animationend:jl("Animation","AnimationEnd"),animationiteration:jl("Animation","AnimationIteration"),animationstart:jl("Animation","AnimationStart"),transitionend:jl("Transition","TransitionEnd")},Vh={},Vb={};c&&(Vb=document.createElement("div").style,"AnimationEvent"in window||(delete es.animationend.animation,delete es.animationiteration.animation,delete es.animationstart.animation),"TransitionEvent"in window||delete es.transitionend.transition);function $l(i){if(Vh[i])return Vh[i];if(!es[i])return i;var s=es[i],l;for(l in s)if(s.hasOwnProperty(l)&&l in Vb)return Vh[i]=s[l];return i}var qb=$l("animationend"),Yb=$l("animationiteration"),Wb=$l("animationstart"),Gb=$l("transitionend"),Kb=new Map,Qb="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 ai(i,s){Kb.set(i,s),a(s,[i])}for(var qh=0;qh<Qb.length;qh++){var Yh=Qb[qh],hM=Yh.toLowerCase(),pM=Yh[0].toUpperCase()+Yh.slice(1);ai(hM,"on"+pM)}ai(qb,"onAnimationEnd"),ai(Yb,"onAnimationIteration"),ai(Wb,"onAnimationStart"),ai("dblclick","onDoubleClick"),ai("focusin","onFocus"),ai("focusout","onBlur"),ai(Gb,"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 La="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(" "),mM=new Set("cancel close invalid load scroll toggle".split(" ").concat(La));function Xb(i,s,l){var f=i.type||"unknown-event";i.currentTarget=l,h8(f,s,void 0,i),i.currentTarget=null}function Jb(i,s){s=(s&4)!==0;for(var l=0;l<i.length;l++){var f=i[l],g=f.event;f=f.listeners;e:{var y=void 0;if(s)for(var w=f.length-1;0<=w;w--){var R=f[w],F=R.instance,K=R.currentTarget;if(R=R.listener,F!==y&&g.isPropagationStopped())break e;Xb(g,R,K),y=F}else for(w=0;w<f.length;w++){if(R=f[w],F=R.instance,K=R.currentTarget,R=R.listener,F!==y&&g.isPropagationStopped())break e;Xb(g,R,K),y=F}}}if(Cl)throw i=_h,Cl=!1,_h=null,i}function lt(i,s){var l=s[ep];l===void 0&&(l=s[ep]=new Set);var f=i+"__bubble";l.has(f)||(Zb(s,i,2,!1),l.add(f))}function Wh(i,s,l){var f=0;s&&(f|=4),Zb(l,i,f,s)}var Vl="_reactListening"+Math.random().toString(36).slice(2);function Da(i){if(!i[Vl]){i[Vl]=!0,r.forEach(function(l){l!=="selectionchange"&&(mM.has(l)||Wh(l,!1,i),Wh(l,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[Vl]||(s[Vl]=!0,Wh("selectionchange",!1,s))}}function Zb(i,s,l,f){switch(wb(s)){case 1:var g=N8;break;case 4:g=O8;break;default:g=Oh}l=g.bind(null,s,l,i),g=void 0,!wh||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 Gh(i,s,l,f,g){var y=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 R=f.stateNode.containerInfo;if(R===g||R.nodeType===8&&R.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(;R!==null;){if(w=Gi(R),w===null)return;if(F=w.tag,F===5||F===6){f=y=w;continue e}R=R.parentNode}}f=f.return}ib(function(){var K=y,ce=Th(l),pe=[];e:{var ue=Kb.get(i);if(ue!==void 0){var we=Ph,ve=i;switch(i){case"keypress":if(Bl(l)===0)break e;case"keydown":case"keyup":we=q8;break;case"focusin":ve="focus",we=Mh;break;case"focusout":ve="blur",we=Mh;break;case"beforeblur":case"afterblur":we=Mh;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=vb;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":we=P8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":we=G8;break;case qb:case Yb:case Wb:we=M8;break;case Gb:we=Q8;break;case"scroll":we=I8;break;case"wheel":we=J8;break;case"copy":case"cut":case"paste":we=B8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":we=Cb}var Ce=(s&4)!==0,_t=!Ce&&i==="scroll",$=Ce?ue!==null?ue+"Capture":null:ue;Ce=[];for(var H=K,q;H!==null;){q=H;var ye=q.stateNode;if(q.tag===5&&ye!==null&&(q=ye,$!==null&&(ye=Ea(H,$),ye!=null&&Ce.push(Ma(H,ye,q)))),_t)break;H=H.return}0<Ce.length&&(ue=new we(ue,ve,null,l,ce),pe.push({event:ue,listeners:Ce}))}}if((s&7)===0){e:{if(ue=i==="mouseover"||i==="pointerover",we=i==="mouseout"||i==="pointerout",ue&&l!==vn&&(ve=l.relatedTarget||l.fromElement)&&(Gi(ve)||ve[Rr]))break e;if((we||ue)&&(ue=ce.window===ce?ce:(ue=ce.ownerDocument)?ue.defaultView||ue.parentWindow:window,we?(ve=l.relatedTarget||l.toElement,we=K,ve=ve?Gi(ve):null,ve!==null&&(_t=Wi(ve),ve!==_t||ve.tag!==5&&ve.tag!==6)&&(ve=null)):(we=null,ve=K),we!==ve)){if(Ce=vb,ye="onMouseLeave",$="onMouseEnter",H="mouse",(i==="pointerout"||i==="pointerover")&&(Ce=Cb,ye="onPointerLeave",$="onPointerEnter",H="pointer"),_t=we==null?ue:rs(we),q=ve==null?ue:rs(ve),ue=new Ce(ye,H+"leave",we,l,ce),ue.target=_t,ue.relatedTarget=q,ye=null,Gi(ce)===K&&(Ce=new Ce($,H+"enter",ve,l,ce),Ce.target=q,Ce.relatedTarget=_t,ye=Ce),_t=ye,we&&ve)t:{for(Ce=we,$=ve,H=0,q=Ce;q;q=ts(q))H++;for(q=0,ye=$;ye;ye=ts(ye))q++;for(;0<H-q;)Ce=ts(Ce),H--;for(;0<q-H;)$=ts($),q--;for(;H--;){if(Ce===$||$!==null&&Ce===$.alternate)break t;Ce=ts(Ce),$=ts($)}Ce=null}else Ce=null;we!==null&&e2(pe,ue,we,Ce,!1),ve!==null&&_t!==null&&e2(pe,_t,ve,Ce,!0)}}e:{if(ue=K?rs(K):window,we=ue.nodeName&&ue.nodeName.toLowerCase(),we==="select"||we==="input"&&ue.type==="file")var ke=oM;else if(Pb(ue))if(Db)ke=lM;else{ke=aM;var De=sM}else(we=ue.nodeName)&&we.toLowerCase()==="input"&&(ue.type==="checkbox"||ue.type==="radio")&&(ke=uM);if(ke&&(ke=ke(i,K))){Lb(pe,ke,l,ce);break e}De&&De(i,ue,K),i==="focusout"&&(De=ue._wrapperState)&&De.controlled&&ue.type==="number"&&Wo(ue,"number",ue.value)}switch(De=K?rs(K):window,i){case"focusin":(Pb(De)||De.contentEditable==="true")&&(Zo=De,jh=K,Pa=null);break;case"focusout":Pa=jh=Zo=null;break;case"mousedown":$h=!0;break;case"contextmenu":case"mouseup":case"dragend":$h=!1,$b(pe,l,ce);break;case"selectionchange":if(fM)break;case"keydown":case"keyup":$b(pe,l,ce)}var Me;if(Bh)e:{switch(i){case"compositionstart":var Ue="onCompositionStart";break e;case"compositionend":Ue="onCompositionEnd";break e;case"compositionupdate":Ue="onCompositionUpdate";break e}Ue=void 0}else Jo?Ib(i,l)&&(Ue="onCompositionEnd"):i==="keydown"&&l.keyCode===229&&(Ue="onCompositionStart");Ue&&(kb&&l.locale!=="ko"&&(Jo||Ue!=="onCompositionStart"?Ue==="onCompositionEnd"&&Jo&&(Me=_b()):(si=ce,Rh="value"in si?si.value:si.textContent,Jo=!0)),De=ql(K,Ue),0<De.length&&(Ue=new Ab(Ue,i,null,l,ce),pe.push({event:Ue,listeners:De}),Me?Ue.data=Me:(Me=Rb(l),Me!==null&&(Ue.data=Me)))),(Me=eM?tM(i,l):nM(i,l))&&(K=ql(K,"onBeforeInput"),0<K.length&&(ce=new Ab("onBeforeInput","beforeinput",null,l,ce),pe.push({event:ce,listeners:K}),ce.data=Me))}Jb(pe,s)})}function Ma(i,s,l){return{instance:i,listener:s,currentTarget:l}}function ql(i,s){for(var l=s+"Capture",f=[];i!==null;){var g=i,y=g.stateNode;g.tag===5&&y!==null&&(g=y,y=Ea(i,l),y!=null&&f.unshift(Ma(i,y,g)),y=Ea(i,s),y!=null&&f.push(Ma(i,y,g))),i=i.return}return f}function ts(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5);return i||null}function e2(i,s,l,f,g){for(var y=s._reactName,w=[];l!==null&&l!==f;){var R=l,F=R.alternate,K=R.stateNode;if(F!==null&&F===f)break;R.tag===5&&K!==null&&(R=K,g?(F=Ea(l,y),F!=null&&w.unshift(Ma(l,F,R))):g||(F=Ea(l,y),F!=null&&w.push(Ma(l,F,R)))),l=l.return}w.length!==0&&i.push({event:s,listeners:w})}var gM=/\r\n?/g,EM=/\u0000|\uFFFD/g;function t2(i){return(typeof i=="string"?i:""+i).replace(gM,`
|
|
21
|
+
`).replace(EM,"")}function Yl(i,s,l){if(s=t2(s),t2(i)!==s&&l)throw Error(n(425))}function Wl(){}var Kh=null,Qh=null;function Xh(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 Jh=typeof setTimeout=="function"?setTimeout:void 0,yM=typeof clearTimeout=="function"?clearTimeout:void 0,n2=typeof Promise=="function"?Promise:void 0,TM=typeof queueMicrotask=="function"?queueMicrotask:typeof n2!="undefined"?function(i){return n2.resolve(null).then(i).catch(bM)}:Jh;function bM(i){setTimeout(function(){throw i})}function Zh(i,s){var l=s,f=0;do{var g=l.nextSibling;if(i.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(f===0){i.removeChild(g),Aa(s);return}f--}else l!=="$"&&l!=="$?"&&l!=="$!"||f++;l=g}while(l);Aa(s)}function ui(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 r2(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var l=i.data;if(l==="$"||l==="$!"||l==="$?"){if(s===0)return i;s--}else l==="/$"&&s++}i=i.previousSibling}return null}var ns=Math.random().toString(36).slice(2),br="__reactFiber$"+ns,Fa="__reactProps$"+ns,Rr="__reactContainer$"+ns,ep="__reactEvents$"+ns,xM="__reactListeners$"+ns,wM="__reactHandles$"+ns;function Gi(i){var s=i[br];if(s)return s;for(var l=i.parentNode;l;){if(s=l[Rr]||l[br]){if(l=s.alternate,s.child!==null||l!==null&&l.child!==null)for(i=r2(i);i!==null;){if(l=i[br])return l;i=r2(i)}return s}i=l,l=i.parentNode}return null}function Ba(i){return i=i[br]||i[Rr],!i||i.tag!==5&&i.tag!==6&&i.tag!==13&&i.tag!==3?null:i}function rs(i){if(i.tag===5||i.tag===6)return i.stateNode;throw Error(n(33))}function Gl(i){return i[Fa]||null}var tp=[],is=-1;function li(i){return{current:i}}function ct(i){0>is||(i.current=tp[is],tp[is]=null,is--)}function at(i,s){is++,tp[is]=i.current,i.current=s}var ci={},Qt=li(ci),mn=li(!1),Ki=ci;function os(i,s){var l=i.type.contextTypes;if(!l)return ci;var f=i.stateNode;if(f&&f.__reactInternalMemoizedUnmaskedChildContext===s)return f.__reactInternalMemoizedMaskedChildContext;var g={},y;for(y in l)g[y]=s[y];return f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=s,i.__reactInternalMemoizedMaskedChildContext=g),g}function gn(i){return i=i.childContextTypes,i!=null}function Kl(){ct(mn),ct(Qt)}function i2(i,s,l){if(Qt.current!==ci)throw Error(n(168));at(Qt,s),at(mn,l)}function o2(i,s,l){var f=i.stateNode;if(s=s.childContextTypes,typeof f.getChildContext!="function")return l;f=f.getChildContext();for(var g in f)if(!(g in s))throw Error(n(108,He(i)||"Unknown",g));return v({},l,f)}function Ql(i){return i=(i=i.stateNode)&&i.__reactInternalMemoizedMergedChildContext||ci,Ki=Qt.current,at(Qt,i),at(mn,mn.current),!0}function s2(i,s,l){var f=i.stateNode;if(!f)throw Error(n(169));l?(i=o2(i,s,Ki),f.__reactInternalMemoizedMergedChildContext=i,ct(mn),ct(Qt),at(Qt,i)):ct(mn),at(mn,l)}var Pr=null,Xl=!1,np=!1;function a2(i){Pr===null?Pr=[i]:Pr.push(i)}function _M(i){Xl=!0,a2(i)}function di(){if(!np&&Pr!==null){np=!0;var i=0,s=nt;try{var l=Pr;for(nt=1;i<l.length;i++){var f=l[i];do f=f(!0);while(f!==null)}Pr=null,Xl=!1}catch(g){throw Pr!==null&&(Pr=Pr.slice(i+1)),lb(Sh,di),g}finally{nt=s,np=!1}}return null}var ss=[],as=0,Jl=null,Zl=0,Fn=[],Bn=0,Qi=null,Lr=1,Dr="";function Xi(i,s){ss[as++]=Zl,ss[as++]=Jl,Jl=i,Zl=s}function u2(i,s,l){Fn[Bn++]=Lr,Fn[Bn++]=Dr,Fn[Bn++]=Qi,Qi=i;var f=Lr;i=Dr;var g=32-Jn(f)-1;f&=~(1<<g),l+=1;var y=32-Jn(s)+g;if(30<y){var w=g-g%5;y=(f&(1<<w)-1).toString(32),f>>=w,g-=w,Lr=1<<32-Jn(s)+g|l<<g|f,Dr=y+i}else Lr=1<<y|l<<g|f,Dr=i}function rp(i){i.return!==null&&(Xi(i,1),u2(i,1,0))}function ip(i){for(;i===Jl;)Jl=ss[--as],ss[as]=null,Zl=ss[--as],ss[as]=null;for(;i===Qi;)Qi=Fn[--Bn],Fn[Bn]=null,Dr=Fn[--Bn],Fn[Bn]=null,Lr=Fn[--Bn],Fn[Bn]=null}var Cn=null,kn=null,pt=!1,er=null;function l2(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 c2(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=ui(s.firstChild),!0):!1;case 6:return s=i.pendingProps===""||s.nodeType!==3?null:s,s!==null?(i.stateNode=s,Cn=i,kn=null,!0):!1;case 13:return s=s.nodeType!==8?null:s,s!==null?(l=Qi!==null?{id:Lr,overflow:Dr}:null,i.memoizedState={dehydrated:s,treeContext:l,retryLane:1073741824},l=jn(18,null,null,0),l.stateNode=s,l.return=i,i.child=l,Cn=i,kn=null,!0):!1;default:return!1}}function op(i){return(i.mode&1)!==0&&(i.flags&128)===0}function sp(i){if(pt){var s=kn;if(s){var l=s;if(!c2(i,s)){if(op(i))throw Error(n(418));s=ui(l.nextSibling);var f=Cn;s&&c2(i,s)?l2(f,l):(i.flags=i.flags&-4097|2,pt=!1,Cn=i)}}else{if(op(i))throw Error(n(418));i.flags=i.flags&-4097|2,pt=!1,Cn=i}}}function d2(i){for(i=i.return;i!==null&&i.tag!==5&&i.tag!==3&&i.tag!==13;)i=i.return;Cn=i}function ec(i){if(i!==Cn)return!1;if(!pt)return d2(i),pt=!0,!1;var s;if((s=i.tag!==3)&&!(s=i.tag!==5)&&(s=i.type,s=s!=="head"&&s!=="body"&&!Xh(i.type,i.memoizedProps)),s&&(s=kn)){if(op(i))throw f2(),Error(n(418));for(;s;)l2(i,s),s=ui(s.nextSibling)}if(d2(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=ui(i.nextSibling);break e}s--}else l!=="$"&&l!=="$!"&&l!=="$?"||s++}i=i.nextSibling}kn=null}}else kn=Cn?ui(i.stateNode.nextSibling):null;return!0}function f2(){for(var i=kn;i;)i=ui(i.nextSibling)}function us(){kn=Cn=null,pt=!1}function ap(i){er===null?er=[i]:er.push(i)}var SM=z.ReactCurrentBatchConfig;function Ua(i,s,l){if(i=l.ref,i!==null&&typeof i!="function"&&typeof i!="object"){if(l._owner){if(l=l._owner,l){if(l.tag!==1)throw Error(n(309));var f=l.stateNode}if(!f)throw Error(n(147,i));var g=f,y=""+i;return s!==null&&s.ref!==null&&typeof s.ref=="function"&&s.ref._stringRef===y?s.ref:(s=function(w){var R=g.refs;w===null?delete R[y]:R[y]=w},s._stringRef=y,s)}if(typeof i!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,i))}return i}function tc(i,s){throw i=Object.prototype.toString.call(s),Error(n(31,i==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":i))}function h2(i){var s=i._init;return s(i._payload)}function p2(i){function s($,H){if(i){var q=$.deletions;q===null?($.deletions=[H],$.flags|=16):q.push(H)}}function l($,H){if(!i)return null;for(;H!==null;)s($,H),H=H.sibling;return null}function f($,H){for($=new Map;H!==null;)H.key!==null?$.set(H.key,H):$.set(H.index,H),H=H.sibling;return $}function g($,H){return $=Ti($,H),$.index=0,$.sibling=null,$}function y($,H,q){return $.index=q,i?(q=$.alternate,q!==null?(q=q.index,q<H?($.flags|=2,H):q):($.flags|=2,H)):($.flags|=1048576,H)}function w($){return i&&$.alternate===null&&($.flags|=2),$}function R($,H,q,ye){return H===null||H.tag!==6?(H=Jp(q,$.mode,ye),H.return=$,H):(H=g(H,q),H.return=$,H)}function F($,H,q,ye){var ke=q.type;return ke===Q?ce($,H,q.props.children,ye,q.key):H!==null&&(H.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ie&&h2(ke)===H.type)?(ye=g(H,q.props),ye.ref=Ua($,H,q),ye.return=$,ye):(ye=vc(q.type,q.key,q.props,null,$.mode,ye),ye.ref=Ua($,H,q),ye.return=$,ye)}function K($,H,q,ye){return H===null||H.tag!==4||H.stateNode.containerInfo!==q.containerInfo||H.stateNode.implementation!==q.implementation?(H=Zp(q,$.mode,ye),H.return=$,H):(H=g(H,q.children||[]),H.return=$,H)}function ce($,H,q,ye,ke){return H===null||H.tag!==7?(H=oo(q,$.mode,ye,ke),H.return=$,H):(H=g(H,q),H.return=$,H)}function pe($,H,q){if(typeof H=="string"&&H!==""||typeof H=="number")return H=Jp(""+H,$.mode,q),H.return=$,H;if(typeof H=="object"&&H!==null){switch(H.$$typeof){case Y:return q=vc(H.type,H.key,H.props,null,$.mode,q),q.ref=Ua($,null,H),q.return=$,q;case M:return H=Zp(H,$.mode,q),H.return=$,H;case Ie:var ye=H._init;return pe($,ye(H._payload),q)}if(Zr(H)||ie(H))return H=oo(H,$.mode,q,null),H.return=$,H;tc($,H)}return null}function ue($,H,q,ye){var ke=H!==null?H.key:null;if(typeof q=="string"&&q!==""||typeof q=="number")return ke!==null?null:R($,H,""+q,ye);if(typeof q=="object"&&q!==null){switch(q.$$typeof){case Y:return q.key===ke?F($,H,q,ye):null;case M:return q.key===ke?K($,H,q,ye):null;case Ie:return ke=q._init,ue($,H,ke(q._payload),ye)}if(Zr(q)||ie(q))return ke!==null?null:ce($,H,q,ye,null);tc($,q)}return null}function we($,H,q,ye,ke){if(typeof ye=="string"&&ye!==""||typeof ye=="number")return $=$.get(q)||null,R(H,$,""+ye,ke);if(typeof ye=="object"&&ye!==null){switch(ye.$$typeof){case Y:return $=$.get(ye.key===null?q:ye.key)||null,F(H,$,ye,ke);case M:return $=$.get(ye.key===null?q:ye.key)||null,K(H,$,ye,ke);case Ie:var De=ye._init;return we($,H,q,De(ye._payload),ke)}if(Zr(ye)||ie(ye))return $=$.get(q)||null,ce(H,$,ye,ke,null);tc(H,ye)}return null}function ve($,H,q,ye){for(var ke=null,De=null,Me=H,Ue=H=0,Ht=null;Me!==null&&Ue<q.length;Ue++){Me.index>Ue?(Ht=Me,Me=null):Ht=Me.sibling;var et=ue($,Me,q[Ue],ye);if(et===null){Me===null&&(Me=Ht);break}i&&Me&&et.alternate===null&&s($,Me),H=y(et,H,Ue),De===null?ke=et:De.sibling=et,De=et,Me=Ht}if(Ue===q.length)return l($,Me),pt&&Xi($,Ue),ke;if(Me===null){for(;Ue<q.length;Ue++)Me=pe($,q[Ue],ye),Me!==null&&(H=y(Me,H,Ue),De===null?ke=Me:De.sibling=Me,De=Me);return pt&&Xi($,Ue),ke}for(Me=f($,Me);Ue<q.length;Ue++)Ht=we(Me,$,Ue,q[Ue],ye),Ht!==null&&(i&&Ht.alternate!==null&&Me.delete(Ht.key===null?Ue:Ht.key),H=y(Ht,H,Ue),De===null?ke=Ht:De.sibling=Ht,De=Ht);return i&&Me.forEach(function(bi){return s($,bi)}),pt&&Xi($,Ue),ke}function Ce($,H,q,ye){var ke=ie(q);if(typeof ke!="function")throw Error(n(150));if(q=ke.call(q),q==null)throw Error(n(151));for(var De=ke=null,Me=H,Ue=H=0,Ht=null,et=q.next();Me!==null&&!et.done;Ue++,et=q.next()){Me.index>Ue?(Ht=Me,Me=null):Ht=Me.sibling;var bi=ue($,Me,et.value,ye);if(bi===null){Me===null&&(Me=Ht);break}i&&Me&&bi.alternate===null&&s($,Me),H=y(bi,H,Ue),De===null?ke=bi:De.sibling=bi,De=bi,Me=Ht}if(et.done)return l($,Me),pt&&Xi($,Ue),ke;if(Me===null){for(;!et.done;Ue++,et=q.next())et=pe($,et.value,ye),et!==null&&(H=y(et,H,Ue),De===null?ke=et:De.sibling=et,De=et);return pt&&Xi($,Ue),ke}for(Me=f($,Me);!et.done;Ue++,et=q.next())et=we(Me,$,Ue,et.value,ye),et!==null&&(i&&et.alternate!==null&&Me.delete(et.key===null?Ue:et.key),H=y(et,H,Ue),De===null?ke=et:De.sibling=et,De=et);return i&&Me.forEach(function(rF){return s($,rF)}),pt&&Xi($,Ue),ke}function _t($,H,q,ye){if(typeof q=="object"&&q!==null&&q.type===Q&&q.key===null&&(q=q.props.children),typeof q=="object"&&q!==null){switch(q.$$typeof){case Y:e:{for(var ke=q.key,De=H;De!==null;){if(De.key===ke){if(ke=q.type,ke===Q){if(De.tag===7){l($,De.sibling),H=g(De,q.props.children),H.return=$,$=H;break e}}else if(De.elementType===ke||typeof ke=="object"&&ke!==null&&ke.$$typeof===Ie&&h2(ke)===De.type){l($,De.sibling),H=g(De,q.props),H.ref=Ua($,De,q),H.return=$,$=H;break e}l($,De);break}else s($,De);De=De.sibling}q.type===Q?(H=oo(q.props.children,$.mode,ye,q.key),H.return=$,$=H):(ye=vc(q.type,q.key,q.props,null,$.mode,ye),ye.ref=Ua($,H,q),ye.return=$,$=ye)}return w($);case M:e:{for(De=q.key;H!==null;){if(H.key===De)if(H.tag===4&&H.stateNode.containerInfo===q.containerInfo&&H.stateNode.implementation===q.implementation){l($,H.sibling),H=g(H,q.children||[]),H.return=$,$=H;break e}else{l($,H);break}else s($,H);H=H.sibling}H=Zp(q,$.mode,ye),H.return=$,$=H}return w($);case Ie:return De=q._init,_t($,H,De(q._payload),ye)}if(Zr(q))return ve($,H,q,ye);if(ie(q))return Ce($,H,q,ye);tc($,q)}return typeof q=="string"&&q!==""||typeof q=="number"?(q=""+q,H!==null&&H.tag===6?(l($,H.sibling),H=g(H,q),H.return=$,$=H):(l($,H),H=Jp(q,$.mode,ye),H.return=$,$=H),w($)):l($,H)}return _t}var ls=p2(!0),m2=p2(!1),nc=li(null),rc=null,cs=null,up=null;function lp(){up=cs=rc=null}function cp(i){var s=nc.current;ct(nc),i._currentValue=s}function dp(i,s,l){for(;i!==null;){var f=i.alternate;if((i.childLanes&s)!==s?(i.childLanes|=s,f!==null&&(f.childLanes|=s)):f!==null&&(f.childLanes&s)!==s&&(f.childLanes|=s),i===l)break;i=i.return}}function ds(i,s){rc=i,up=cs=null,i=i.dependencies,i!==null&&i.firstContext!==null&&((i.lanes&s)!==0&&(En=!0),i.firstContext=null)}function Un(i){var s=i._currentValue;if(up!==i)if(i={context:i,memoizedValue:s,next:null},cs===null){if(rc===null)throw Error(n(308));cs=i,rc.dependencies={lanes:0,firstContext:i}}else cs=cs.next=i;return s}var Ji=null;function fp(i){Ji===null?Ji=[i]:Ji.push(i)}function g2(i,s,l,f){var g=s.interleaved;return g===null?(l.next=l,fp(s)):(l.next=g.next,g.next=l),s.interleaved=l,Mr(i,f)}function Mr(i,s){i.lanes|=s;var l=i.alternate;for(l!==null&&(l.lanes|=s),l=i,i=i.return;i!==null;)i.childLanes|=s,l=i.alternate,l!==null&&(l.childLanes|=s),l=i,i=i.return;return l.tag===3?l.stateNode:null}var fi=!1;function hp(i){i.updateQueue={baseState:i.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function E2(i,s){i=i.updateQueue,s.updateQueue===i&&(s.updateQueue={baseState:i.baseState,firstBaseUpdate:i.firstBaseUpdate,lastBaseUpdate:i.lastBaseUpdate,shared:i.shared,effects:i.effects})}function Fr(i,s){return{eventTime:i,lane:s,tag:0,payload:null,callback:null,next:null}}function hi(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,Mr(i,l)}return g=f.interleaved,g===null?(s.next=s,fp(f)):(s.next=g.next,g.next=s),f.interleaved=s,Mr(i,l)}function ic(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,Ch(i,l)}}function y2(i,s){var l=i.updateQueue,f=i.alternate;if(f!==null&&(f=f.updateQueue,l===f)){var g=null,y=null;if(l=l.firstBaseUpdate,l!==null){do{var w={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};y===null?g=y=w:y=y.next=w,l=l.next}while(l!==null);y===null?g=y=s:y=y.next=s}else g=y=s;l={baseState:f.baseState,firstBaseUpdate:g,lastBaseUpdate:y,shared:f.shared,effects:f.effects},i.updateQueue=l;return}i=l.lastBaseUpdate,i===null?l.firstBaseUpdate=s:i.next=s,l.lastBaseUpdate=s}function oc(i,s,l,f){var g=i.updateQueue;fi=!1;var y=g.firstBaseUpdate,w=g.lastBaseUpdate,R=g.shared.pending;if(R!==null){g.shared.pending=null;var F=R,K=F.next;F.next=null,w===null?y=K:w.next=K,w=F;var ce=i.alternate;ce!==null&&(ce=ce.updateQueue,R=ce.lastBaseUpdate,R!==w&&(R===null?ce.firstBaseUpdate=K:R.next=K,ce.lastBaseUpdate=F))}if(y!==null){var pe=g.baseState;w=0,ce=K=F=null,R=y;do{var ue=R.lane,we=R.eventTime;if((f&ue)===ue){ce!==null&&(ce=ce.next={eventTime:we,lane:0,tag:R.tag,payload:R.payload,callback:R.callback,next:null});e:{var ve=i,Ce=R;switch(ue=s,we=l,Ce.tag){case 1:if(ve=Ce.payload,typeof ve=="function"){pe=ve.call(we,pe,ue);break e}pe=ve;break e;case 3:ve.flags=ve.flags&-65537|128;case 0:if(ve=Ce.payload,ue=typeof ve=="function"?ve.call(we,pe,ue):ve,ue==null)break e;pe=v({},pe,ue);break e;case 2:fi=!0}}R.callback!==null&&R.lane!==0&&(i.flags|=64,ue=g.effects,ue===null?g.effects=[R]:ue.push(R))}else we={eventTime:we,lane:ue,tag:R.tag,payload:R.payload,callback:R.callback,next:null},ce===null?(K=ce=we,F=pe):ce=ce.next=we,w|=ue;if(R=R.next,R===null){if(R=g.shared.pending,R===null)break;ue=R,R=ue.next,ue.next=null,g.lastBaseUpdate=ue,g.shared.pending=null}}while(!0);if(ce===null&&(F=pe),g.baseState=F,g.firstBaseUpdate=K,g.lastBaseUpdate=ce,s=g.shared.interleaved,s!==null){g=s;do w|=g.lane,g=g.next;while(g!==s)}else y===null&&(g.shared.lanes=0);to|=w,i.lanes=w,i.memoizedState=pe}}function T2(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 Ha={},xr=li(Ha),za=li(Ha),ja=li(Ha);function Zi(i){if(i===Ha)throw Error(n(174));return i}function pp(i,s){switch(at(ja,s),at(za,i),at(xr,Ha),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(xr),at(xr,s)}function fs(){ct(xr),ct(za),ct(ja)}function b2(i){Zi(ja.current);var s=Zi(xr.current),l=Te(s,i.type);s!==l&&(at(za,i),at(xr,l))}function mp(i){za.current===i&&(ct(xr),ct(za))}var mt=li(0);function sc(i){for(var s=i;s!==null;){if(s.tag===13){var l=s.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||l.data==="$!"))return s}else if(s.tag===19&&s.memoizedProps.revealOrder!==void 0){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===i)break;for(;s.sibling===null;){if(s.return===null||s.return===i)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var gp=[];function Ep(){for(var i=0;i<gp.length;i++)gp[i]._workInProgressVersionPrimary=null;gp.length=0}var ac=z.ReactCurrentDispatcher,yp=z.ReactCurrentBatchConfig,eo=0,gt=null,It=null,Bt=null,uc=!1,$a=!1,Va=0,vM=0;function Xt(){throw Error(n(321))}function Tp(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 bp(i,s,l,f,g,y){if(eo=y,gt=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,ac.current=i===null||i.memoizedState===null?NM:OM,i=l(f,g),$a){y=0;do{if($a=!1,Va=0,25<=y)throw Error(n(301));y+=1,Bt=It=null,s.updateQueue=null,ac.current=IM,i=l(f,g)}while($a)}if(ac.current=dc,s=It!==null&&It.next!==null,eo=0,Bt=It=gt=null,uc=!1,s)throw Error(n(300));return i}function xp(){var i=Va!==0;return Va=0,i}function wr(){var i={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Bt===null?gt.memoizedState=Bt=i:Bt=Bt.next=i,Bt}function Hn(){if(It===null){var i=gt.alternate;i=i!==null?i.memoizedState:null}else i=It.next;var s=Bt===null?gt.memoizedState:Bt.next;if(s!==null)Bt=s,It=i;else{if(i===null)throw Error(n(310));It=i,i={memoizedState:It.memoizedState,baseState:It.baseState,baseQueue:It.baseQueue,queue:It.queue,next:null},Bt===null?gt.memoizedState=Bt=i:Bt=Bt.next=i}return Bt}function qa(i,s){return typeof s=="function"?s(i):s}function wp(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=It,g=f.baseQueue,y=l.pending;if(y!==null){if(g!==null){var w=g.next;g.next=y.next,y.next=w}f.baseQueue=g=y,l.pending=null}if(g!==null){y=g.next,f=f.baseState;var R=w=null,F=null,K=y;do{var ce=K.lane;if((eo&ce)===ce)F!==null&&(F=F.next={lane:0,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null}),f=K.hasEagerState?K.eagerState:i(f,K.action);else{var pe={lane:ce,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null};F===null?(R=F=pe,w=f):F=F.next=pe,gt.lanes|=ce,to|=ce}K=K.next}while(K!==null&&K!==y);F===null?w=f:F.next=R,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 y=g.lane,gt.lanes|=y,to|=y,g=g.next;while(g!==i)}else g===null&&(l.lanes=0);return[s.memoizedState,l.dispatch]}function _p(i){var s=Hn(),l=s.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=i;var f=l.dispatch,g=l.pending,y=s.memoizedState;if(g!==null){l.pending=null;var w=g=g.next;do y=i(y,w.action),w=w.next;while(w!==g);Zn(y,s.memoizedState)||(En=!0),s.memoizedState=y,s.baseQueue===null&&(s.baseState=y),l.lastRenderedState=y}return[y,f]}function x2(){}function w2(i,s){var l=gt,f=Hn(),g=s(),y=!Zn(f.memoizedState,g);if(y&&(f.memoizedState=g,En=!0),f=f.queue,Sp(v2.bind(null,l,f,i),[i]),f.getSnapshot!==s||y||Bt!==null&&Bt.memoizedState.tag&1){if(l.flags|=2048,Ya(9,S2.bind(null,l,f,g,s),void 0,null),Ut===null)throw Error(n(349));(eo&30)!==0||_2(l,s,g)}return g}function _2(i,s,l){i.flags|=16384,i={getSnapshot:s,value:l},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.stores=[i]):(l=s.stores,l===null?s.stores=[i]:l.push(i))}function S2(i,s,l,f){s.value=l,s.getSnapshot=f,A2(s)&&C2(i)}function v2(i,s,l){return l(function(){A2(s)&&C2(i)})}function A2(i){var s=i.getSnapshot;i=i.value;try{var l=s();return!Zn(i,l)}catch(f){return!0}}function C2(i){var s=Mr(i,1);s!==null&&ir(s,i,1,-1)}function k2(i){var s=wr();return typeof i=="function"&&(i=i()),s.memoizedState=s.baseState=i,i={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:qa,lastRenderedState:i},s.queue=i,i=i.dispatch=kM.bind(null,gt,i),[s.memoizedState,i]}function Ya(i,s,l,f){return i={tag:i,create:s,destroy:l,deps:f,next:null},s=gt.updateQueue,s===null?(s={lastEffect:null,stores:null},gt.updateQueue=s,s.lastEffect=i.next=i):(l=s.lastEffect,l===null?s.lastEffect=i.next=i:(f=l.next,l.next=i,i.next=f,s.lastEffect=i)),i}function N2(){return Hn().memoizedState}function lc(i,s,l,f){var g=wr();gt.flags|=i,g.memoizedState=Ya(1|s,l,void 0,f===void 0?null:f)}function cc(i,s,l,f){var g=Hn();f=f===void 0?null:f;var y=void 0;if(It!==null){var w=It.memoizedState;if(y=w.destroy,f!==null&&Tp(f,w.deps)){g.memoizedState=Ya(s,l,y,f);return}}gt.flags|=i,g.memoizedState=Ya(1|s,l,y,f)}function O2(i,s){return lc(8390656,8,i,s)}function Sp(i,s){return cc(2048,8,i,s)}function I2(i,s){return cc(4,2,i,s)}function R2(i,s){return cc(4,4,i,s)}function P2(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 L2(i,s,l){return l=l!=null?l.concat([i]):null,cc(4,4,P2.bind(null,s,i),l)}function vp(){}function D2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Tp(s,f[1])?f[0]:(l.memoizedState=[i,s],i)}function M2(i,s){var l=Hn();s=s===void 0?null:s;var f=l.memoizedState;return f!==null&&s!==null&&Tp(s,f[1])?f[0]:(i=i(),l.memoizedState=[i,s],i)}function F2(i,s,l){return(eo&21)===0?(i.baseState&&(i.baseState=!1,En=!0),i.memoizedState=l):(Zn(l,s)||(l=hb(),gt.lanes|=l,to|=l,i.baseState=!0),s)}function AM(i,s){var l=nt;nt=l!==0&&4>l?l:4,i(!0);var f=yp.transition;yp.transition={};try{i(!1),s()}finally{nt=l,yp.transition=f}}function B2(){return Hn().memoizedState}function CM(i,s,l){var f=Ei(i);if(l={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null},U2(i))H2(s,l);else if(l=g2(i,s,l,f),l!==null){var g=on();ir(l,i,f,g),z2(l,s,f)}}function kM(i,s,l){var f=Ei(i),g={lane:f,action:l,hasEagerState:!1,eagerState:null,next:null};if(U2(i))H2(s,g);else{var y=i.alternate;if(i.lanes===0&&(y===null||y.lanes===0)&&(y=s.lastRenderedReducer,y!==null))try{var w=s.lastRenderedState,R=y(w,l);if(g.hasEagerState=!0,g.eagerState=R,Zn(R,w)){var F=s.interleaved;F===null?(g.next=g,fp(s)):(g.next=F.next,F.next=g),s.interleaved=g;return}}catch(K){}l=g2(i,s,g,f),l!==null&&(g=on(),ir(l,i,f,g),z2(l,s,f))}}function U2(i){var s=i.alternate;return i===gt||s!==null&&s===gt}function H2(i,s){$a=uc=!0;var l=i.pending;l===null?s.next=s:(s.next=l.next,l.next=s),i.pending=s}function z2(i,s,l){if((l&4194240)!==0){var f=s.lanes;f&=i.pendingLanes,l|=f,s.lanes=l,Ch(i,l)}}var dc={readContext:Un,useCallback:Xt,useContext:Xt,useEffect:Xt,useImperativeHandle:Xt,useInsertionEffect:Xt,useLayoutEffect:Xt,useMemo:Xt,useReducer:Xt,useRef:Xt,useState:Xt,useDebugValue:Xt,useDeferredValue:Xt,useTransition:Xt,useMutableSource:Xt,useSyncExternalStore:Xt,useId:Xt,unstable_isNewReconciler:!1},NM={readContext:Un,useCallback:function(i,s){return wr().memoizedState=[i,s===void 0?null:s],i},useContext:Un,useEffect:O2,useImperativeHandle:function(i,s,l){return l=l!=null?l.concat([i]):null,lc(4194308,4,P2.bind(null,s,i),l)},useLayoutEffect:function(i,s){return lc(4194308,4,i,s)},useInsertionEffect:function(i,s){return lc(4,2,i,s)},useMemo:function(i,s){var l=wr();return s=s===void 0?null:s,i=i(),l.memoizedState=[i,s],i},useReducer:function(i,s,l){var f=wr();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=CM.bind(null,gt,i),[f.memoizedState,i]},useRef:function(i){var s=wr();return i={current:i},s.memoizedState=i},useState:k2,useDebugValue:vp,useDeferredValue:function(i){return wr().memoizedState=i},useTransition:function(){var i=k2(!1),s=i[0];return i=AM.bind(null,i[1]),wr().memoizedState=i,[s,i]},useMutableSource:function(){},useSyncExternalStore:function(i,s,l){var f=gt,g=wr();if(pt){if(l===void 0)throw Error(n(407));l=l()}else{if(l=s(),Ut===null)throw Error(n(349));(eo&30)!==0||_2(f,s,l)}g.memoizedState=l;var y={value:l,getSnapshot:s};return g.queue=y,O2(v2.bind(null,f,y,i),[i]),f.flags|=2048,Ya(9,S2.bind(null,f,y,l,s),void 0,null),l},useId:function(){var i=wr(),s=Ut.identifierPrefix;if(pt){var l=Dr,f=Lr;l=(f&~(1<<32-Jn(f)-1)).toString(32)+l,s=":"+s+"R"+l,l=Va++,0<l&&(s+="H"+l.toString(32)),s+=":"}else l=vM++,s=":"+s+"r"+l.toString(32)+":";return i.memoizedState=s},unstable_isNewReconciler:!1},OM={readContext:Un,useCallback:D2,useContext:Un,useEffect:Sp,useImperativeHandle:L2,useInsertionEffect:I2,useLayoutEffect:R2,useMemo:M2,useReducer:wp,useRef:N2,useState:function(){return wp(qa)},useDebugValue:vp,useDeferredValue:function(i){var s=Hn();return F2(s,It.memoizedState,i)},useTransition:function(){var i=wp(qa)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:x2,useSyncExternalStore:w2,useId:B2,unstable_isNewReconciler:!1},IM={readContext:Un,useCallback:D2,useContext:Un,useEffect:Sp,useImperativeHandle:L2,useInsertionEffect:I2,useLayoutEffect:R2,useMemo:M2,useReducer:_p,useRef:N2,useState:function(){return _p(qa)},useDebugValue:vp,useDeferredValue:function(i){var s=Hn();return It===null?s.memoizedState=i:F2(s,It.memoizedState,i)},useTransition:function(){var i=_p(qa)[0],s=Hn().memoizedState;return[i,s]},useMutableSource:x2,useSyncExternalStore:w2,useId:B2,unstable_isNewReconciler:!1};function tr(i,s){if(i&&i.defaultProps){s=v({},s),i=i.defaultProps;for(var l in i)s[l]===void 0&&(s[l]=i[l]);return s}return s}function Ap(i,s,l,f){s=i.memoizedState,l=l(f,s),l=l==null?s:v({},s,l),i.memoizedState=l,i.lanes===0&&(i.updateQueue.baseState=l)}var fc={isMounted:function(i){return(i=i._reactInternals)?Wi(i)===i:!1},enqueueSetState:function(i,s,l){i=i._reactInternals;var f=on(),g=Ei(i),y=Fr(f,g);y.payload=s,l!=null&&(y.callback=l),s=hi(i,y,g),s!==null&&(ir(s,i,g,f),ic(s,i,g))},enqueueReplaceState:function(i,s,l){i=i._reactInternals;var f=on(),g=Ei(i),y=Fr(f,g);y.tag=1,y.payload=s,l!=null&&(y.callback=l),s=hi(i,y,g),s!==null&&(ir(s,i,g,f),ic(s,i,g))},enqueueForceUpdate:function(i,s){i=i._reactInternals;var l=on(),f=Ei(i),g=Fr(l,f);g.tag=2,s!=null&&(g.callback=s),s=hi(i,g,f),s!==null&&(ir(s,i,f,l),ic(s,i,f))}};function j2(i,s,l,f,g,y,w){return i=i.stateNode,typeof i.shouldComponentUpdate=="function"?i.shouldComponentUpdate(f,y,w):s.prototype&&s.prototype.isPureReactComponent?!Ra(l,f)||!Ra(g,y):!0}function $2(i,s,l){var f=!1,g=ci,y=s.contextType;return typeof y=="object"&&y!==null?y=Un(y):(g=gn(s)?Ki:Qt.current,f=s.contextTypes,y=(f=f!=null)?os(i,g):ci),s=new s(l,y),i.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,s.updater=fc,i.stateNode=s,s._reactInternals=i,f&&(i=i.stateNode,i.__reactInternalMemoizedUnmaskedChildContext=g,i.__reactInternalMemoizedMaskedChildContext=y),s}function V2(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&&fc.enqueueReplaceState(s,s.state,null)}function Cp(i,s,l,f){var g=i.stateNode;g.props=l,g.state=i.memoizedState,g.refs={},hp(i);var y=s.contextType;typeof y=="object"&&y!==null?g.context=Un(y):(y=gn(s)?Ki:Qt.current,g.context=os(i,y)),g.state=i.memoizedState,y=s.getDerivedStateFromProps,typeof y=="function"&&(Ap(i,s,y,l),g.state=i.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(s=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),s!==g.state&&fc.enqueueReplaceState(g,g.state,null),oc(i,l,g,f),g.state=i.memoizedState),typeof g.componentDidMount=="function"&&(i.flags|=4194308)}function hs(i,s){try{var l="",f=s;do l+=Pe(f),f=f.return;while(f);var g=l}catch(y){g=`
|
|
22
22
|
Error generating stack: `+y.message+`
|
|
23
|
-
`+y.stack}return{value:i,source:s,stack:g,digest:null}}function kp(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function Np(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var RM=typeof WeakMap=="function"?WeakMap:Map;function q2(i,s,l){l=Fr(-1,l),l.tag=3,l.payload={element:null};var f=s.value;return l.callback=function(){Tc||(Tc=!0,Vp=f),Np(i,s)},l}function Y2(i,s,l){l=Fr(-1,l),l.tag=3;var f=i.type.getDerivedStateFromError;if(typeof f=="function"){var g=s.value;l.payload=function(){return f(g)},l.callback=function(){Np(i,s)}}var y=i.stateNode;return y!==null&&typeof y.componentDidCatch=="function"&&(l.callback=function(){Np(i,s),typeof f!="function"&&(mi===null?mi=new Set([this]):mi.add(this));var w=s.stack;this.componentDidCatch(s.value,{componentStack:w!==null?w:""})}),l}function W2(i,s,l){var f=i.pingCache;if(f===null){f=i.pingCache=new RM;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=YM.bind(null,i,s,l),s.then(i,i))}function G2(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 K2(i,s,l,f,g){return(i.mode&1)===0?(i===s?i.flags|=65536:(i.flags|=128,l.flags|=131072,l.flags&=-52805,l.tag===1&&(l.alternate===null?l.tag=17:(s=Fr(-1,1),s.tag=2,hi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var PM=H.ReactCurrentOwner,En=!1;function rn(i,s,l,f){s.child=i===null?m2(s,null,l,f):ls(s,i.child,l,f)}function Q2(i,s,l,f,g){l=l.render;var y=s.ref;return ds(s,g),f=bp(i,s,l,f,y,g),l=xp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Br(i,s,g)):(pt&&l&&rp(s),s.flags|=1,rn(i,s,f,g),s.child)}function X2(i,s,l,f,g){if(i===null){var y=l.type;return typeof y=="function"&&!Xp(y)&&y.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=y,J2(i,s,y,f,g)):(i=vc(l.type,null,f,s,s.mode,g),i.ref=s.ref,i.return=s,s.child=i)}if(y=i.child,(i.lanes&g)===0){var w=y.memoizedProps;if(l=l.compare,l=l!==null?l:Ra,l(w,f)&&i.ref===s.ref)return Br(i,s,g)}return s.flags|=1,i=Ti(y,f),i.ref=s.ref,i.return=s,s.child=i}function J2(i,s,l,f,g){if(i!==null){var y=i.memoizedProps;if(Ra(y,f)&&i.ref===s.ref)if(En=!1,s.pendingProps=f=y,(i.lanes&g)!==0)(i.flags&131072)!==0&&(En=!0);else return s.lanes=i.lanes,Br(i,s,g)}return Op(i,s,l,f,g)}function Z2(i,s,l){var f=s.pendingProps,g=f.children,y=i!==null?i.memoizedState:null;if(f.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},at(ms,Nn),Nn|=l;else{if((l&1073741824)===0)return i=y!==null?y.baseLanes|l:l,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,at(ms,Nn),Nn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},f=y!==null?y.baseLanes:l,at(ms,Nn),Nn|=f}else y!==null?(f=y.baseLanes|l,s.memoizedState=null):f=l,at(ms,Nn),Nn|=f;return rn(i,s,g,l),s.child}function ex(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function Op(i,s,l,f,g){var y=gn(l)?Ki:Qt.current;return y=os(s,y),ds(s,g),l=bp(i,s,l,f,y,g),f=xp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Br(i,s,g)):(pt&&f&&rp(s),s.flags|=1,rn(i,s,l,g),s.child)}function tx(i,s,l,f,g){if(gn(l)){var y=!0;Ql(s)}else y=!1;if(ds(s,g),s.stateNode===null)pc(i,s),$2(s,l,f),Cp(s,l,f,g),f=!0;else if(i===null){var w=s.stateNode,R=s.memoizedProps;w.props=R;var F=w.context,K=l.contextType;typeof K=="object"&&K!==null?K=Un(K):(K=gn(l)?Ki:Qt.current,K=os(s,K));var ce=l.getDerivedStateFromProps,he=typeof ce=="function"||typeof w.getSnapshotBeforeUpdate=="function";he||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(R!==f||F!==K)&&V2(s,w,f,K),fi=!1;var ue=s.memoizedState;w.state=ue,oc(s,f,w,g),F=s.memoizedState,R!==f||ue!==F||mn.current||fi?(typeof ce=="function"&&(Ap(s,l,ce,f),F=s.memoizedState),(R=fi||j2(s,l,R,f,ue,F,K))?(he||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=K,f=R):(typeof w.componentDidMount=="function"&&(s.flags|=4194308),f=!1)}else{w=s.stateNode,E2(i,s),R=s.memoizedProps,K=s.type===s.elementType?R:tr(s.type,R),w.props=K,he=s.pendingProps,ue=w.context,F=l.contextType,typeof F=="object"&&F!==null?F=Un(F):(F=gn(l)?Ki:Qt.current,F=os(s,F));var we=l.getDerivedStateFromProps;(ce=typeof we=="function"||typeof w.getSnapshotBeforeUpdate=="function")||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(R!==he||ue!==F)&&V2(s,w,f,F),fi=!1,ue=s.memoizedState,w.state=ue,oc(s,f,w,g);var ve=s.memoizedState;R!==he||ue!==ve||mn.current||fi?(typeof we=="function"&&(Ap(s,l,we,f),ve=s.memoizedState),(K=fi||j2(s,l,K,f,ue,ve,F)||!1)?(ce||typeof w.UNSAFE_componentWillUpdate!="function"&&typeof w.componentWillUpdate!="function"||(typeof w.componentWillUpdate=="function"&&w.componentWillUpdate(f,ve,F),typeof w.UNSAFE_componentWillUpdate=="function"&&w.UNSAFE_componentWillUpdate(f,ve,F)),typeof w.componentDidUpdate=="function"&&(s.flags|=4),typeof w.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof w.componentDidUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),s.memoizedProps=f,s.memoizedState=ve),w.props=f,w.state=ve,w.context=F,f=K):(typeof w.componentDidUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),f=!1)}return Ip(i,s,l,f,y,g)}function Ip(i,s,l,f,g,y){ex(i,s);var w=(s.flags&128)!==0;if(!f&&!w)return g&&s2(s,l,!1),Br(i,s,y);f=s.stateNode,PM.current=s;var R=w&&typeof l.getDerivedStateFromError!="function"?null:f.render();return s.flags|=1,i!==null&&w?(s.child=ls(s,i.child,null,y),s.child=ls(s,null,R,y)):rn(i,s,R,y),s.memoizedState=f.state,g&&s2(s,l,!0),s.child}function nx(i){var s=i.stateNode;s.pendingContext?i2(i,s.pendingContext,s.pendingContext!==s.context):s.context&&i2(i,s.context,!1),pp(i,s.containerInfo)}function rx(i,s,l,f,g){return us(),ap(g),s.flags|=256,rn(i,s,l,f),s.child}var Rp={dehydrated:null,treeContext:null,retryLane:0};function Pp(i){return{baseLanes:i,cachePool:null,transitions:null}}function ix(i,s,l){var f=s.pendingProps,g=mt.current,y=!1,w=(s.flags&128)!==0,R;if((R=w)||(R=i!==null&&i.memoizedState===null?!1:(g&2)!==0),R?(y=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(g|=1),at(mt,g&1),i===null)return sp(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,y?(f=s.mode,y=s.child,w={mode:"hidden",children:w},(f&1)===0&&y!==null?(y.childLanes=0,y.pendingProps=w):y=Ac(w,f,0,null),i=oo(i,f,l,null),y.return=s,i.return=s,y.sibling=i,s.child=y,s.child.memoizedState=Pp(l),s.memoizedState=Rp,i):Lp(s,w));if(g=i.memoizedState,g!==null&&(R=g.dehydrated,R!==null))return LM(i,s,w,f,R,g,l);if(y){y=f.fallback,w=s.mode,g=i.child,R=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),R!==null?y=Ti(R,y):(y=oo(y,w,l,null),y.flags|=2),y.return=s,f.return=s,f.sibling=y,s.child=f,f=y,y=s.child,w=i.child.memoizedState,w=w===null?Pp(l):{baseLanes:w.baseLanes|l,cachePool:null,transitions:w.transitions},y.memoizedState=w,y.childLanes=i.childLanes&~l,s.memoizedState=Rp,f}return y=i.child,i=y.sibling,f=Ti(y,{mode:"visible",children:f.children}),(s.mode&1)===0&&(f.lanes=l),f.return=s,f.sibling=null,i!==null&&(l=s.deletions,l===null?(s.deletions=[i],s.flags|=16):l.push(i)),s.child=f,s.memoizedState=null,f}function Lp(i,s){return s=Ac({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function hc(i,s,l,f){return f!==null&&ap(f),ls(s,i.child,null,l),i=Lp(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function LM(i,s,l,f,g,y,w){if(l)return s.flags&256?(s.flags&=-257,f=kp(Error(n(422))),hc(i,s,w,f)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(y=f.fallback,g=s.mode,f=Ac({mode:"visible",children:f.children},g,0,null),y=oo(y,g,w,null),y.flags|=2,f.return=s,y.return=s,f.sibling=y,s.child=f,(s.mode&1)!==0&&ls(s,i.child,null,w),s.child.memoizedState=Pp(w),s.memoizedState=Rp,y);if((s.mode&1)===0)return hc(i,s,w,null);if(g.data==="$!"){if(f=g.nextSibling&&g.nextSibling.dataset,f)var R=f.dgst;return f=R,y=Error(n(419)),f=kp(y,f,void 0),hc(i,s,w,f)}if(R=(w&i.childLanes)!==0,En||R){if(f=Ut,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!==y.retryLane&&(y.retryLane=g,Mr(i,g),ir(f,i,g,-1))}return Qp(),f=kp(Error(n(421))),hc(i,s,w,f)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=WM.bind(null,i),g._reactRetry=s,null):(i=y.treeContext,kn=ui(g.nextSibling),Cn=s,pt=!0,er=null,i!==null&&(Fn[Bn++]=Lr,Fn[Bn++]=Dr,Fn[Bn++]=Qi,Lr=i.id,Dr=i.overflow,Qi=s),s=Lp(s,f.children),s.flags|=4096,s)}function ox(i,s,l){i.lanes|=s;var f=i.alternate;f!==null&&(f.lanes|=s),dp(i.return,s,l)}function Dp(i,s,l,f,g){var y=i.memoizedState;y===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:f,tail:l,tailMode:g}:(y.isBackwards=s,y.rendering=null,y.renderingStartTime=0,y.last=f,y.tail=l,y.tailMode=g)}function sx(i,s,l){var f=s.pendingProps,g=f.revealOrder,y=f.tail;if(rn(i,s,f.children,l),f=mt.current,(f&2)!==0)f=f&1|2,s.flags|=128;else{if(i!==null&&(i.flags&128)!==0)e:for(i=s.child;i!==null;){if(i.tag===13)i.memoizedState!==null&&ox(i,l,s);else if(i.tag===19)ox(i,l,s);else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===s)break e;for(;i.sibling===null;){if(i.return===null||i.return===s)break e;i=i.return}i.sibling.return=i.return,i=i.sibling}f&=1}if(at(mt,f),(s.mode&1)===0)s.memoizedState=null;else switch(g){case"forwards":for(l=s.child,g=null;l!==null;)i=l.alternate,i!==null&&sc(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),Dp(s,!1,g,l,y);break;case"backwards":for(l=null,g=s.child,s.child=null;g!==null;){if(i=g.alternate,i!==null&&sc(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}Dp(s,!0,l,null,y);break;case"together":Dp(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function pc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function Br(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),to|=s.lanes,(l&s.childLanes)===0)return null;if(i!==null&&s.child!==i.child)throw Error(n(153));if(s.child!==null){for(i=s.child,l=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 DM(i,s,l){switch(s.tag){case 3:nx(s),us();break;case 5:b2(s);break;case 1:gn(s.type)&&Ql(s);break;case 4:pp(s,s.stateNode.containerInfo);break;case 10:var f=s.type._context,g=s.memoizedProps.value;at(nc,f._currentValue),f._currentValue=g;break;case 13:if(f=s.memoizedState,f!==null)return f.dehydrated!==null?(at(mt,mt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?ix(i,s,l):(at(mt,mt.current&1),i=Br(i,s,l),i!==null?i.sibling:null);at(mt,mt.current&1);break;case 19:if(f=(l&s.childLanes)!==0,(i.flags&128)!==0){if(f)return sx(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),at(mt,mt.current),f)break;return null;case 22:case 23:return s.lanes=0,Z2(i,s,l)}return Br(i,s,l)}var ax,Mp,ux,lx;ax=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}},Mp=function(){},ux=function(i,s,l,f){var g=i.memoizedProps;if(g!==f){i=s.stateNode,Zi(xr.current);var y=null;switch(l){case"input":g=Xn(i,g),f=Xn(i,f),y=[];break;case"select":g=v({},g,{value:void 0}),f=v({},f,{value:void 0}),y=[];break;case"textarea":g=ga(i,g),f=ga(i,f),y=[];break;default:typeof g.onClick!="function"&&typeof f.onClick=="function"&&(i.onclick=Wl)}jt(l,f);var w;l=null;for(K in g)if(!f.hasOwnProperty(K)&&g.hasOwnProperty(K)&&g[K]!=null)if(K==="style"){var R=g[K];for(w in R)R.hasOwnProperty(w)&&(l||(l={}),l[w]="")}else K!=="dangerouslySetInnerHTML"&&K!=="children"&&K!=="suppressContentEditableWarning"&&K!=="suppressHydrationWarning"&&K!=="autoFocus"&&(o.hasOwnProperty(K)?y||(y=[]):(y=y||[]).push(K,null));for(K in f){var F=f[K];if(R=g!=null?g[K]:void 0,f.hasOwnProperty(K)&&F!==R&&(F!=null||R!=null))if(K==="style")if(R){for(w in R)!R.hasOwnProperty(w)||F&&F.hasOwnProperty(w)||(l||(l={}),l[w]="");for(w in F)F.hasOwnProperty(w)&&R[w]!==F[w]&&(l||(l={}),l[w]=F[w])}else l||(y||(y=[]),y.push(K,l)),l=F;else K==="dangerouslySetInnerHTML"?(F=F?F.__html:void 0,R=R?R.__html:void 0,F!=null&&R!==F&&(y=y||[]).push(K,F)):K==="children"?typeof F!="string"&&typeof F!="number"||(y=y||[]).push(K,""+F):K!=="suppressContentEditableWarning"&&K!=="suppressHydrationWarning"&&(o.hasOwnProperty(K)?(F!=null&&K==="onScroll"&<("scroll",i),y||R===F||(y=[])):(y=y||[]).push(K,F))}l&&(y=y||[]).push("style",l);var K=y;(s.updateQueue=K)&&(s.flags|=4)}},lx=function(i,s,l,f){l!==f&&(s.flags|=4)};function Wa(i,s){if(!pt)switch(i.tailMode){case"hidden":s=i.tail;for(var l=null;s!==null;)s.alternate!==null&&(l=s),s=s.sibling;l===null?i.tail=null:l.sibling=null;break;case"collapsed":l=i.tail;for(var f=null;l!==null;)l.alternate!==null&&(f=l),l=l.sibling;f===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:f.sibling=null}}function Jt(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 MM(i,s,l){var f=s.pendingProps;switch(ip(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Jt(s),null;case 1:return gn(s.type)&&Kl(),Jt(s),null;case 3:return f=s.stateNode,fs(),ct(mn),ct(Qt),Ep(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(i===null||i.child===null)&&(ec(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,er!==null&&(Wp(er),er=null))),Mp(i,s),Jt(s),null;case 5:mp(s);var g=Zi(ja.current);if(l=s.type,i!==null&&s.stateNode!=null)ux(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 Jt(s),null}if(i=Zi(xr.current),ec(s)){f=s.stateNode,l=s.type;var y=s.memoizedProps;switch(f[br]=s,f[Fa]=y,i=(s.mode&1)!==0,l){case"dialog":lt("cancel",f),lt("close",f);break;case"iframe":case"object":case"embed":lt("load",f);break;case"video":case"audio":for(g=0;g<La.length;g++)lt(La[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":pa(f,y),lt("invalid",f);break;case"select":f._wrapperState={wasMultiple:!!y.multiple},lt("invalid",f);break;case"textarea":_l(f,y),lt("invalid",f)}jt(l,y),g=null;for(var w in y)if(y.hasOwnProperty(w)){var R=y[w];w==="children"?typeof R=="string"?f.textContent!==R&&(y.suppressHydrationWarning!==!0&&Yl(f.textContent,R,i),g=["children",R]):typeof R=="number"&&f.textContent!==""+R&&(y.suppressHydrationWarning!==!0&&Yl(f.textContent,R,i),g=["children",""+R]):o.hasOwnProperty(w)&&R!=null&&w==="onScroll"&<("scroll",f)}switch(l){case"input":pn(f),wl(f,y,!0);break;case"textarea":pn(f),vl(f);break;case"select":case"option":break;default:typeof y.onClick=="function"&&(f.onclick=Wl)}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=ne(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[br]=s,i[Fa]=f,ax(i,s,!1,!1),s.stateNode=i;e:{switch(w=yr(l,f),l){case"dialog":lt("cancel",i),lt("close",i),g=f;break;case"iframe":case"object":case"embed":lt("load",i),g=f;break;case"video":case"audio":for(g=0;g<La.length;g++)lt(La[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":pa(i,f),g=Xn(i,f),lt("invalid",i);break;case"option":g=f;break;case"select":i._wrapperState={wasMultiple:!!f.multiple},g=v({},f,{value:void 0}),lt("invalid",i);break;case"textarea":_l(i,f),g=ga(i,f),lt("invalid",i);break;default:g=f}jt(l,g),R=g;for(y in R)if(R.hasOwnProperty(y)){var F=R[y];y==="style"?ti(i,F):y==="dangerouslySetInnerHTML"?(F=F?F.__html:void 0,F!=null&&Ye(i,F)):y==="children"?typeof F=="string"?(l!=="textarea"||F!=="")&&Xe(i,F):typeof F=="number"&&Xe(i,""+F):y!=="suppressContentEditableWarning"&&y!=="suppressHydrationWarning"&&y!=="autoFocus"&&(o.hasOwnProperty(y)?F!=null&&y==="onScroll"&<("scroll",i):F!=null&&I(i,y,F,w))}switch(l){case"input":pn(i),wl(i,f,!1);break;case"textarea":pn(i),vl(i);break;case"option":f.value!=null&&i.setAttribute("value",""+Se(f.value));break;case"select":i.multiple=!!f.multiple,y=f.value,y!=null?ei(i,!!f.multiple,y,!1):f.defaultValue!=null&&ei(i,!!f.multiple,f.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=Wl)}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 Jt(s),null;case 6:if(i&&s.stateNode!=null)lx(i,s,i.memoizedProps,f);else{if(typeof f!="string"&&s.stateNode===null)throw Error(n(166));if(l=Zi(ja.current),Zi(xr.current),ec(s)){if(f=s.stateNode,l=s.memoizedProps,f[br]=s,(y=f.nodeValue!==l)&&(i=Cn,i!==null))switch(i.tag){case 3:Yl(f.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Yl(f.nodeValue,l,(i.mode&1)!==0)}y&&(s.flags|=4)}else f=(l.nodeType===9?l:l.ownerDocument).createTextNode(f),f[br]=s,s.stateNode=f}return Jt(s),null;case 13:if(ct(mt),f=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(pt&&kn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)f2(),us(),s.flags|=98560,y=!1;else if(y=ec(s),f!==null&&f.dehydrated!==null){if(i===null){if(!y)throw Error(n(318));if(y=s.memoizedState,y=y!==null?y.dehydrated:null,!y)throw Error(n(317));y[br]=s}else us(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;Jt(s),y=!1}else er!==null&&(Wp(er),er=null),y=!0;if(!y)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=l,s):(f=f!==null,f!==(i!==null&&i.memoizedState!==null)&&f&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(mt.current&1)!==0?Rt===0&&(Rt=3):Qp())),s.updateQueue!==null&&(s.flags|=4),Jt(s),null);case 4:return fs(),Mp(i,s),i===null&&Da(s.stateNode.containerInfo),Jt(s),null;case 10:return cp(s.type._context),Jt(s),null;case 17:return gn(s.type)&&Kl(),Jt(s),null;case 19:if(ct(mt),y=s.memoizedState,y===null)return Jt(s),null;if(f=(s.flags&128)!==0,w=y.rendering,w===null)if(f)Wa(y,!1);else{if(Rt!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(w=sc(i),w!==null){for(s.flags|=128,Wa(y,!1),f=w.updateQueue,f!==null&&(s.updateQueue=f,s.flags|=4),s.subtreeFlags=0,f=l,l=s.child;l!==null;)y=l,i=f,y.flags&=14680066,w=y.alternate,w===null?(y.childLanes=0,y.lanes=i,y.child=null,y.subtreeFlags=0,y.memoizedProps=null,y.memoizedState=null,y.updateQueue=null,y.dependencies=null,y.stateNode=null):(y.childLanes=w.childLanes,y.lanes=w.lanes,y.child=w.child,y.subtreeFlags=0,y.deletions=null,y.memoizedProps=w.memoizedProps,y.memoizedState=w.memoizedState,y.updateQueue=w.updateQueue,y.type=w.type,i=w.dependencies,y.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return at(mt,mt.current&1|2),s.child}i=i.sibling}y.tail!==null&&wt()>gs&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304)}else{if(!f)if(i=sc(w),i!==null){if(s.flags|=128,f=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),Wa(y,!0),y.tail===null&&y.tailMode==="hidden"&&!w.alternate&&!pt)return Jt(s),null}else 2*wt()-y.renderingStartTime>gs&&l!==1073741824&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304);y.isBackwards?(w.sibling=s.child,s.child=w):(l=y.last,l!==null?l.sibling=w:s.child=w,y.last=w)}return y.tail!==null?(s=y.tail,y.rendering=s,y.tail=s.sibling,y.renderingStartTime=wt(),s.sibling=null,l=mt.current,at(mt,f?l&1|2:l&1),s):(Jt(s),null);case 22:case 23:return Kp(),f=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==f&&(s.flags|=8192),f&&(s.mode&1)!==0?(Nn&1073741824)!==0&&(Jt(s),s.subtreeFlags&6&&(s.flags|=8192)):Jt(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function FM(i,s){switch(ip(s),s.tag){case 1:return gn(s.type)&&Kl(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return fs(),ct(mn),ct(Qt),Ep(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return mp(s),null;case 13:if(ct(mt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));us()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ct(mt),null;case 4:return fs(),null;case 10:return cp(s.type._context),null;case 22:case 23:return Kp(),null;case 24:return null;default:return null}}var mc=!1,Zt=!1,BM=typeof WeakSet=="function"?WeakSet:Set,_e=null;function ps(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(f){yt(i,s,f)}else l.current=null}function Fp(i,s,l){try{l()}catch(f){yt(i,s,f)}}var cx=!1;function UM(i,s){if(Kh=Dl,i=jb(),zh(i)){if("selectionStart"in i)var l={start:i.selectionStart,end:i.selectionEnd};else e:{l=(l=i.ownerDocument)&&l.defaultView||window;var f=l.getSelection&&l.getSelection();if(f&&f.rangeCount!==0){l=f.anchorNode;var g=f.anchorOffset,y=f.focusNode;f=f.focusOffset;try{l.nodeType,y.nodeType}catch(ye){l=null;break e}var w=0,R=-1,F=-1,K=0,ce=0,he=i,ue=null;t:for(;;){for(var we;he!==l||g!==0&&he.nodeType!==3||(R=w+g),he!==y||f!==0&&he.nodeType!==3||(F=w+f),he.nodeType===3&&(w+=he.nodeValue.length),(we=he.firstChild)!==null;)ue=he,he=we;for(;;){if(he===i)break t;if(ue===l&&++K===g&&(R=w),ue===y&&++ce===f&&(F=w),(we=he.nextSibling)!==null)break;he=ue,ue=he.parentNode}he=we}l=R===-1||F===-1?null:{start:R,end:F}}else l=null}l=l||{start:0,end:0}}else l=null;for(Qh={focusedElem:i,selectionRange:l},Dl=!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 ve=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(ve!==null){var Ce=ve.memoizedProps,_t=ve.memoizedState,$=s.stateNode,U=$.getSnapshotBeforeUpdate(s.elementType===s.type?Ce:tr(s.type,Ce),_t);$.__reactInternalSnapshotBeforeUpdate=U}break;case 3:var q=s.stateNode.containerInfo;q.nodeType===1?q.textContent="":q.nodeType===9&&q.documentElement&&q.removeChild(q.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(ye){yt(s,s.return,ye)}if(i=s.sibling,i!==null){i.return=s.return,_e=i;break}_e=s.return}return ve=cx,cx=!1,ve}function Ga(i,s,l){var f=s.updateQueue;if(f=f!==null?f.lastEffect:null,f!==null){var g=f=f.next;do{if((g.tag&i)===i){var y=g.destroy;g.destroy=void 0,y!==void 0&&Fp(s,l,y)}g=g.next}while(g!==f)}}function gc(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 Bp(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 dx(i){var s=i.alternate;s!==null&&(i.alternate=null,dx(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[br],delete s[Fa],delete s[ep],delete s[xM],delete s[wM])),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 fx(i){return i.tag===5||i.tag===3||i.tag===4}function hx(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||fx(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 Up(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=Wl));else if(f!==4&&(i=i.child,i!==null))for(Up(i,s,l),i=i.sibling;i!==null;)Up(i,s,l),i=i.sibling}function Hp(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(Hp(i,s,l),i=i.sibling;i!==null;)Hp(i,s,l),i=i.sibling}var $t=null,nr=!1;function pi(i,s,l){for(l=l.child;l!==null;)px(i,s,l),l=l.sibling}function px(i,s,l){if(Tr&&typeof Tr.onCommitFiberUnmount=="function")try{Tr.onCommitFiberUnmount(Nl,l)}catch(R){}switch(l.tag){case 5:Zt||ps(l,s);case 6:var f=$t,g=nr;$t=null,pi(i,s,l),$t=f,nr=g,$t!==null&&(nr?(i=$t,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):$t.removeChild(l.stateNode));break;case 18:$t!==null&&(nr?(i=$t,l=l.stateNode,i.nodeType===8?Zh(i.parentNode,l):i.nodeType===1&&Zh(i,l),Aa(i)):Zh($t,l.stateNode));break;case 4:f=$t,g=nr,$t=l.stateNode.containerInfo,nr=!0,pi(i,s,l),$t=f,nr=g;break;case 0:case 11:case 14:case 15:if(!Zt&&(f=l.updateQueue,f!==null&&(f=f.lastEffect,f!==null))){g=f=f.next;do{var y=g,w=y.destroy;y=y.tag,w!==void 0&&((y&2)!==0||(y&4)!==0)&&Fp(l,s,w),g=g.next}while(g!==f)}pi(i,s,l);break;case 1:if(!Zt&&(ps(l,s),f=l.stateNode,typeof f.componentWillUnmount=="function"))try{f.props=l.memoizedProps,f.state=l.memoizedState,f.componentWillUnmount()}catch(R){yt(l,s,R)}pi(i,s,l);break;case 21:pi(i,s,l);break;case 22:l.mode&1?(Zt=(f=Zt)||l.memoizedState!==null,pi(i,s,l),Zt=f):pi(i,s,l);break;default:pi(i,s,l)}}function mx(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new BM),s.forEach(function(f){var g=GM.bind(null,i,f);l.has(f)||(l.add(f),f.then(g,g))})}}function rr(i,s){var l=s.deletions;if(l!==null)for(var f=0;f<l.length;f++){var g=l[f];try{var y=i,w=s,R=w;e:for(;R!==null;){switch(R.tag){case 5:$t=R.stateNode,nr=!1;break e;case 3:$t=R.stateNode.containerInfo,nr=!0;break e;case 4:$t=R.stateNode.containerInfo,nr=!0;break e}R=R.return}if($t===null)throw Error(n(160));px(y,w,g),$t=null,nr=!1;var F=g.alternate;F!==null&&(F.return=null),g.return=null}catch(K){yt(g,s,K)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)gx(s,i),s=s.sibling}function gx(i,s){var l=i.alternate,f=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(rr(s,i),_r(i),f&4){try{Ga(3,i,i.return),gc(3,i)}catch(Ce){yt(i,i.return,Ce)}try{Ga(5,i,i.return)}catch(Ce){yt(i,i.return,Ce)}}break;case 1:rr(s,i),_r(i),f&512&&l!==null&&ps(l,l.return);break;case 5:if(rr(s,i),_r(i),f&512&&l!==null&&ps(l,l.return),i.flags&32){var g=i.stateNode;try{Xe(g,"")}catch(Ce){yt(i,i.return,Ce)}}if(f&4&&(g=i.stateNode,g!=null)){var y=i.memoizedProps,w=l!==null?l.memoizedProps:y,R=i.type,F=i.updateQueue;if(i.updateQueue=null,F!==null)try{R==="input"&&y.type==="radio"&&y.name!=null&&ma(g,y),yr(R,w);var K=yr(R,y);for(w=0;w<F.length;w+=2){var ce=F[w],he=F[w+1];ce==="style"?ti(g,he):ce==="dangerouslySetInnerHTML"?Ye(g,he):ce==="children"?Xe(g,he):I(g,ce,he,K)}switch(R){case"input":Yo(g,y);break;case"textarea":Sl(g,y);break;case"select":var ue=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!y.multiple;var we=y.value;we!=null?ei(g,!!y.multiple,we,!1):ue!==!!y.multiple&&(y.defaultValue!=null?ei(g,!!y.multiple,y.defaultValue,!0):ei(g,!!y.multiple,y.multiple?[]:"",!1))}g[Fa]=y}catch(Ce){yt(i,i.return,Ce)}}break;case 6:if(rr(s,i),_r(i),f&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,y=i.memoizedProps;try{g.nodeValue=y}catch(Ce){yt(i,i.return,Ce)}}break;case 3:if(rr(s,i),_r(i),f&4&&l!==null&&l.memoizedState.isDehydrated)try{Aa(s.containerInfo)}catch(Ce){yt(i,i.return,Ce)}break;case 4:rr(s,i),_r(i);break;case 13:rr(s,i),_r(i),g=i.child,g.flags&8192&&(y=g.memoizedState!==null,g.stateNode.isHidden=y,!y||g.alternate!==null&&g.alternate.memoizedState!==null||($p=wt())),f&4&&mx(i);break;case 22:if(ce=l!==null&&l.memoizedState!==null,i.mode&1?(Zt=(K=Zt)||ce,rr(s,i),Zt=K):rr(s,i),_r(i),f&8192){if(K=i.memoizedState!==null,(i.stateNode.isHidden=K)&&!ce&&(i.mode&1)!==0)for(_e=i,ce=i.child;ce!==null;){for(he=_e=ce;_e!==null;){switch(ue=_e,we=ue.child,ue.tag){case 0:case 11:case 14:case 15:Ga(4,ue,ue.return);break;case 1:ps(ue,ue.return);var ve=ue.stateNode;if(typeof ve.componentWillUnmount=="function"){f=ue,l=ue.return;try{s=f,ve.props=s.memoizedProps,ve.state=s.memoizedState,ve.componentWillUnmount()}catch(Ce){yt(f,l,Ce)}}break;case 5:ps(ue,ue.return);break;case 22:if(ue.memoizedState!==null){Tx(he);continue}}we!==null?(we.return=ue,_e=we):Tx(he)}ce=ce.sibling}e:for(ce=null,he=i;;){if(he.tag===5){if(ce===null){ce=he;try{g=he.stateNode,K?(y=g.style,typeof y.setProperty=="function"?y.setProperty("display","none","important"):y.display="none"):(R=he.stateNode,F=he.memoizedProps.style,w=F!=null&&F.hasOwnProperty("display")?F.display:null,R.style.display=Mn("display",w))}catch(Ce){yt(i,i.return,Ce)}}}else if(he.tag===6){if(ce===null)try{he.stateNode.nodeValue=K?"":he.memoizedProps}catch(Ce){yt(i,i.return,Ce)}}else if((he.tag!==22&&he.tag!==23||he.memoizedState===null||he===i)&&he.child!==null){he.child.return=he,he=he.child;continue}if(he===i)break e;for(;he.sibling===null;){if(he.return===null||he.return===i)break e;ce===he&&(ce=null),he=he.return}ce===he&&(ce=null),he.sibling.return=he.return,he=he.sibling}}break;case 19:rr(s,i),_r(i),f&4&&mx(i);break;case 21:break;default:rr(s,i),_r(i)}}function _r(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(fx(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 y=hx(i);Hp(i,y,g);break;case 3:case 4:var w=f.stateNode.containerInfo,R=hx(i);Up(i,R,w);break;default:throw Error(n(161))}}catch(F){yt(i,i.return,F)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function HM(i,s,l){_e=i,Ex(i)}function Ex(i,s,l){for(var f=(i.mode&1)!==0;_e!==null;){var g=_e,y=g.child;if(g.tag===22&&f){var w=g.memoizedState!==null||mc;if(!w){var R=g.alternate,F=R!==null&&R.memoizedState!==null||Zt;R=mc;var K=Zt;if(mc=w,(Zt=F)&&!K)for(_e=g;_e!==null;)w=_e,F=w.child,w.tag===22&&w.memoizedState!==null?bx(g):F!==null?(F.return=w,_e=F):bx(g);for(;y!==null;)_e=y,Ex(y),y=y.sibling;_e=g,mc=R,Zt=K}yx(i)}else(g.subtreeFlags&8772)!==0&&y!==null?(y.return=g,_e=y):yx(i)}}function yx(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:Zt||gc(5,s);break;case 1:var f=s.stateNode;if(s.flags&4&&!Zt)if(l===null)f.componentDidMount();else{var g=s.elementType===s.type?l.memoizedProps:tr(s.type,l.memoizedProps);f.componentDidUpdate(g,l.memoizedState,f.__reactInternalSnapshotBeforeUpdate)}var y=s.updateQueue;y!==null&&T2(s,y,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}T2(s,w,l)}break;case 5:var R=s.stateNode;if(l===null&&s.flags&4){l=R;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 K=s.alternate;if(K!==null){var ce=K.memoizedState;if(ce!==null){var he=ce.dehydrated;he!==null&&Aa(he)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Zt||s.flags&512&&Bp(s)}catch(ue){yt(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 Tx(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 bx(i){for(;_e!==null;){var s=_e;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{gc(4,s)}catch(F){yt(s,l,F)}break;case 1:var f=s.stateNode;if(typeof f.componentDidMount=="function"){var g=s.return;try{f.componentDidMount()}catch(F){yt(s,g,F)}}var y=s.return;try{Bp(s)}catch(F){yt(s,y,F)}break;case 5:var w=s.return;try{Bp(s)}catch(F){yt(s,w,F)}}}catch(F){yt(s,s.return,F)}if(s===i){_e=null;break}var R=s.sibling;if(R!==null){R.return=s.return,_e=R;break}_e=s.return}}var zM=Math.ceil,Ec=H.ReactCurrentDispatcher,zp=H.ReactCurrentOwner,zn=H.ReactCurrentBatchConfig,Je=0,Ut=null,Ct=null,Vt=0,Nn=0,ms=li(0),Rt=0,Ka=null,to=0,yc=0,jp=0,Qa=null,yn=null,$p=0,gs=1/0,Ur=null,Tc=!1,Vp=null,mi=null,bc=!1,gi=null,xc=0,Xa=0,qp=null,wc=-1,_c=0;function on(){return(Je&6)!==0?wt():wc!==-1?wc:wc=wt()}function Ei(i){return(i.mode&1)===0?1:(Je&2)!==0&&Vt!==0?Vt&-Vt:SM.transition!==null?(_c===0&&(_c=hb()),_c):(i=nt,i!==0||(i=window.event,i=i===void 0?16:wb(i.type)),i)}function ir(i,s,l,f){if(50<Xa)throw Xa=0,qp=null,Error(n(185));xa(i,l,f),((Je&2)===0||i!==Ut)&&(i===Ut&&((Je&2)===0&&(yc|=l),Rt===4&&yi(i,Vt)),Tn(i,f),l===1&&Je===0&&(s.mode&1)===0&&(gs=wt()+500,Xl&&di()))}function Tn(i,s){var l=i.callbackNode;S8(i,s);var f=Rl(i,i===Ut?Vt:0);if(f===0)l!==null&&cb(l),i.callbackNode=null,i.callbackPriority=0;else if(s=f&-f,i.callbackPriority!==s){if(l!=null&&cb(l),s===1)i.tag===0?_M(wx.bind(null,i)):a2(wx.bind(null,i)),TM(function(){(Je&6)===0&&di()}),l=null;else{switch(pb(f)){case 1:l=Sh;break;case 4:l=db;break;case 16:l=kl;break;case 536870912:l=fb;break;default:l=kl}l=Ox(l,xx.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function xx(i,s){if(wc=-1,_c=0,(Je&6)!==0)throw Error(n(327));var l=i.callbackNode;if(Es()&&i.callbackNode!==l)return null;var f=Rl(i,i===Ut?Vt:0);if(f===0)return null;if((f&30)!==0||(f&i.expiredLanes)!==0||s)s=Sc(i,f);else{s=f;var g=Je;Je|=2;var y=Sx();(Ut!==i||Vt!==s)&&(Ur=null,gs=wt()+500,ro(i,s));do try{VM();break}catch(R){_x(i,R)}while(!0);lp(),Ec.current=y,Je=g,Ct!==null?s=0:(Ut=null,Vt=0,s=Rt)}if(s!==0){if(s===2&&(g=vh(i),g!==0&&(f=g,s=Yp(i,g))),s===1)throw l=Ka,ro(i,0),yi(i,f),Tn(i,wt()),l;if(s===6)yi(i,f);else{if(g=i.current.alternate,(f&30)===0&&!jM(g)&&(s=Sc(i,f),s===2&&(y=vh(i),y!==0&&(f=y,s=Yp(i,y))),s===1))throw l=Ka,ro(i,0),yi(i,f),Tn(i,wt()),l;switch(i.finishedWork=g,i.finishedLanes=f,s){case 0:case 1:throw Error(n(345));case 2:io(i,yn,Ur);break;case 3:if(yi(i,f),(f&130023424)===f&&(s=$p+500-wt(),10<s)){if(Rl(i,0)!==0)break;if(g=i.suspendedLanes,(g&f)!==f){on(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=Jh(io.bind(null,i,yn,Ur),s);break}io(i,yn,Ur);break;case 4:if(yi(i,f),(f&4194240)===f)break;for(s=i.eventTimes,g=-1;0<f;){var w=31-Jn(f);y=1<<w,w=s[w],w>g&&(g=w),f&=~y}if(f=g,f=wt()-f,f=(120>f?120:480>f?480:1080>f?1080:1920>f?1920:3e3>f?3e3:4320>f?4320:1960*zM(f/1960))-f,10<f){i.timeoutHandle=Jh(io.bind(null,i,yn,Ur),f);break}io(i,yn,Ur);break;case 5:io(i,yn,Ur);break;default:throw Error(n(329))}}}return Tn(i,wt()),i.callbackNode===l?xx.bind(null,i):null}function Yp(i,s){var l=Qa;return i.current.memoizedState.isDehydrated&&(ro(i,s).flags|=256),i=Sc(i,s),i!==2&&(s=yn,yn=l,s!==null&&Wp(s)),i}function Wp(i){yn===null?yn=i:yn.push.apply(yn,i)}function jM(i){for(var s=i;;){if(s.flags&16384){var l=s.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var f=0;f<l.length;f++){var g=l[f],y=g.getSnapshot;g=g.value;try{if(!Zn(y(),g))return!1}catch(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 yi(i,s){for(s&=~jp,s&=~yc,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 wx(i){if((Je&6)!==0)throw Error(n(327));Es();var s=Rl(i,0);if((s&1)===0)return Tn(i,wt()),null;var l=Sc(i,s);if(i.tag!==0&&l===2){var f=vh(i);f!==0&&(s=f,l=Yp(i,f))}if(l===1)throw l=Ka,ro(i,0),yi(i,s),Tn(i,wt()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,io(i,yn,Ur),Tn(i,wt()),null}function Gp(i,s){var l=Je;Je|=1;try{return i(s)}finally{Je=l,Je===0&&(gs=wt()+500,Xl&&di())}}function no(i){gi!==null&&gi.tag===0&&(Je&6)===0&&Es();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&&di()}}function Kp(){Nn=ms.current,ct(ms)}function ro(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,yM(l)),Ct!==null)for(l=Ct.return;l!==null;){var f=l;switch(ip(f),f.tag){case 1:f=f.type.childContextTypes,f!=null&&Kl();break;case 3:fs(),ct(mn),ct(Qt),Ep();break;case 5:mp(f);break;case 4:fs();break;case 13:ct(mt);break;case 19:ct(mt);break;case 10:cp(f.type._context);break;case 22:case 23:Kp()}l=l.return}if(Ut=i,Ct=i=Ti(i.current,null),Vt=Nn=s,Rt=0,Ka=null,jp=yc=to=0,yn=Qa=null,Ji!==null){for(s=0;s<Ji.length;s++)if(l=Ji[s],f=l.interleaved,f!==null){l.interleaved=null;var g=f.next,y=l.pending;if(y!==null){var w=y.next;y.next=g,f.next=w}l.pending=f}Ji=null}return i}function _x(i,s){do{var l=Ct;try{if(lp(),ac.current=dc,uc){for(var f=gt.memoizedState;f!==null;){var g=f.queue;g!==null&&(g.pending=null),f=f.next}uc=!1}if(eo=0,Bt=It=gt=null,$a=!1,Va=0,zp.current=null,l===null||l.return===null){Rt=1,Ka=s,Ct=null;break}e:{var y=i,w=l.return,R=l,F=s;if(s=Vt,R.flags|=32768,F!==null&&typeof F=="object"&&typeof F.then=="function"){var K=F,ce=R,he=ce.tag;if((ce.mode&1)===0&&(he===0||he===11||he===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=G2(w);if(we!==null){we.flags&=-257,K2(we,w,R,y,s),we.mode&1&&W2(y,K,s),s=we,F=K;var ve=s.updateQueue;if(ve===null){var Ce=new Set;Ce.add(F),s.updateQueue=Ce}else ve.add(F);break e}else{if((s&1)===0){W2(y,K,s),Qp();break e}F=Error(n(426))}}else if(pt&&R.mode&1){var _t=G2(w);if(_t!==null){(_t.flags&65536)===0&&(_t.flags|=256),K2(_t,w,R,y,s),ap(hs(F,R));break e}}y=F=hs(F,R),Rt!==4&&(Rt=2),Qa===null?Qa=[y]:Qa.push(y),y=w;do{switch(y.tag){case 3:y.flags|=65536,s&=-s,y.lanes|=s;var $=q2(y,F,s);y2(y,$);break e;case 1:R=F;var U=y.type,q=y.stateNode;if((y.flags&128)===0&&(typeof U.getDerivedStateFromError=="function"||q!==null&&typeof q.componentDidCatch=="function"&&(mi===null||!mi.has(q)))){y.flags|=65536,s&=-s,y.lanes|=s;var ye=Y2(y,R,s);y2(y,ye);break e}}y=y.return}while(y!==null)}Ax(l)}catch(ke){s=ke,Ct===l&&l!==null&&(Ct=l=l.return);continue}break}while(!0)}function Sx(){var i=Ec.current;return Ec.current=dc,i===null?dc:i}function Qp(){(Rt===0||Rt===3||Rt===2)&&(Rt=4),Ut===null||(to&268435455)===0&&(yc&268435455)===0||yi(Ut,Vt)}function Sc(i,s){var l=Je;Je|=2;var f=Sx();(Ut!==i||Vt!==s)&&(Ur=null,ro(i,s));do try{$M();break}catch(g){_x(i,g)}while(!0);if(lp(),Je=l,Ec.current=f,Ct!==null)throw Error(n(261));return Ut=null,Vt=0,Rt}function $M(){for(;Ct!==null;)vx(Ct)}function VM(){for(;Ct!==null&&!m8();)vx(Ct)}function vx(i){var s=Nx(i.alternate,i,Nn);i.memoizedProps=i.pendingProps,s===null?Ax(i):Ct=s,zp.current=null}function Ax(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=MM(l,s,Nn),l!==null){Ct=l;return}}else{if(l=FM(l,s),l!==null){l.flags&=32767,Ct=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{Rt=6,Ct=null;return}}if(s=s.sibling,s!==null){Ct=s;return}Ct=s=i}while(s!==null);Rt===0&&(Rt=5)}function io(i,s,l){var f=nt,g=zn.transition;try{zn.transition=null,nt=1,qM(i,s,l,f)}finally{zn.transition=g,nt=f}return null}function qM(i,s,l,f){do Es();while(gi!==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 y=l.lanes|l.childLanes;if(v8(i,y),i===Ut&&(Ct=Ut=null,Vt=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||bc||(bc=!0,Ox(kl,function(){return Es(),null})),y=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||y){y=zn.transition,zn.transition=null;var w=nt;nt=1;var R=Je;Je|=4,zp.current=null,UM(i,l),gx(l,i),dM(Qh),Dl=!!Kh,Qh=Kh=null,i.current=l,HM(l),g8(),Je=R,nt=w,zn.transition=y}else i.current=l;if(bc&&(bc=!1,gi=i,xc=g),y=i.pendingLanes,y===0&&(mi=null),T8(l.stateNode),Tn(i,wt()),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(Tc)throw Tc=!1,i=Vp,Vp=null,i;return(xc&1)!==0&&i.tag!==0&&Es(),y=i.pendingLanes,(y&1)!==0?i===qp?Xa++:(Xa=0,qp=i):Xa=0,di(),null}function Es(){if(gi!==null){var i=pb(xc),s=zn.transition,l=nt;try{if(zn.transition=null,nt=16>i?16:i,gi===null)var f=!1;else{if(i=gi,gi=null,xc=0,(Je&6)!==0)throw Error(n(331));var g=Je;for(Je|=4,_e=i.current;_e!==null;){var y=_e,w=y.child;if((_e.flags&16)!==0){var R=y.deletions;if(R!==null){for(var F=0;F<R.length;F++){var K=R[F];for(_e=K;_e!==null;){var ce=_e;switch(ce.tag){case 0:case 11:case 15:Ga(8,ce,y)}var he=ce.child;if(he!==null)he.return=ce,_e=he;else for(;_e!==null;){ce=_e;var ue=ce.sibling,we=ce.return;if(dx(ce),ce===K){_e=null;break}if(ue!==null){ue.return=we,_e=ue;break}_e=we}}}var ve=y.alternate;if(ve!==null){var Ce=ve.child;if(Ce!==null){ve.child=null;do{var _t=Ce.sibling;Ce.sibling=null,Ce=_t}while(Ce!==null)}}_e=y}}if((y.subtreeFlags&2064)!==0&&w!==null)w.return=y,_e=w;else e:for(;_e!==null;){if(y=_e,(y.flags&2048)!==0)switch(y.tag){case 0:case 11:case 15:Ga(9,y,y.return)}var $=y.sibling;if($!==null){$.return=y.return,_e=$;break e}_e=y.return}}var U=i.current;for(_e=U;_e!==null;){w=_e;var q=w.child;if((w.subtreeFlags&2064)!==0&&q!==null)q.return=w,_e=q;else e:for(w=U;_e!==null;){if(R=_e,(R.flags&2048)!==0)try{switch(R.tag){case 0:case 11:case 15:gc(9,R)}}catch(ke){yt(R,R.return,ke)}if(R===w){_e=null;break e}var ye=R.sibling;if(ye!==null){ye.return=R.return,_e=ye;break e}_e=R.return}}if(Je=g,di(),Tr&&typeof Tr.onPostCommitFiberRoot=="function")try{Tr.onPostCommitFiberRoot(Nl,i)}catch(ke){}f=!0}return f}finally{nt=l,zn.transition=s}}return!1}function Cx(i,s,l){s=hs(l,s),s=q2(i,s,1),i=hi(i,s,1),s=on(),i!==null&&(xa(i,1,s),Tn(i,s))}function yt(i,s,l){if(i.tag===3)Cx(i,i,l);else for(;s!==null;){if(s.tag===3){Cx(s,i,l);break}else if(s.tag===1){var f=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof f.componentDidCatch=="function"&&(mi===null||!mi.has(f))){i=hs(l,i),i=Y2(s,i,1),s=hi(s,i,1),i=on(),s!==null&&(xa(s,1,i),Tn(s,i));break}}s=s.return}}function YM(i,s,l){var f=i.pingCache;f!==null&&f.delete(s),s=on(),i.pingedLanes|=i.suspendedLanes&l,Ut===i&&(Vt&l)===l&&(Rt===4||Rt===3&&(Vt&130023424)===Vt&&500>wt()-$p?ro(i,0):jp|=l),Tn(i,s)}function kx(i,s){s===0&&((i.mode&1)===0?s=1:(s=Il,Il<<=1,(Il&130023424)===0&&(Il=4194304)));var l=on();i=Mr(i,s),i!==null&&(xa(i,s,l),Tn(i,l))}function WM(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),kx(i,l)}function GM(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),kx(i,l)}var Nx;Nx=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,DM(i,s,l);En=(i.flags&131072)!==0}else En=!1,pt&&(s.flags&1048576)!==0&&u2(s,Zl,s.index);switch(s.lanes=0,s.tag){case 2:var f=s.type;pc(i,s),i=s.pendingProps;var g=os(s,Qt.current);ds(s,l),g=bp(null,s,f,i,g,l);var y=xp();return s.flags|=1,typeof g=="object"&&g!==null&&typeof g.render=="function"&&g.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,gn(f)?(y=!0,Ql(s)):y=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,hp(s),g.updater=fc,s.stateNode=g,g._reactInternals=s,Cp(s,f,i,l),s=Ip(null,s,f,!0,y,l)):(s.tag=0,pt&&y&&rp(s),rn(null,s,g,l),s=s.child),s;case 16:f=s.elementType;e:{switch(pc(i,s),i=s.pendingProps,g=f._init,f=g(f._payload),s.type=f,g=s.tag=QM(f),i=tr(f,i),g){case 0:s=Op(null,s,f,i,l);break e;case 1:s=tx(null,s,f,i,l);break e;case 11:s=Q2(null,s,f,i,l);break e;case 14:s=X2(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),Op(i,s,f,g,l);case 1:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),tx(i,s,f,g,l);case 3:e:{if(nx(s),i===null)throw Error(n(387));f=s.pendingProps,y=s.memoizedState,g=y.element,E2(i,s),oc(s,f,null,l);var w=s.memoizedState;if(f=w.element,y.isDehydrated)if(y={element:f,isDehydrated:!1,cache:w.cache,pendingSuspenseBoundaries:w.pendingSuspenseBoundaries,transitions:w.transitions},s.updateQueue.baseState=y,s.memoizedState=y,s.flags&256){g=hs(Error(n(423)),s),s=rx(i,s,f,l,g);break e}else if(f!==g){g=hs(Error(n(424)),s),s=rx(i,s,f,l,g);break e}else for(kn=ui(s.stateNode.containerInfo.firstChild),Cn=s,pt=!0,er=null,l=m2(s,null,f,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(us(),f===g){s=Br(i,s,l);break e}rn(i,s,f,l)}s=s.child}return s;case 5:return b2(s),i===null&&sp(s),f=s.type,g=s.pendingProps,y=i!==null?i.memoizedProps:null,w=g.children,Xh(f,g)?w=null:y!==null&&Xh(f,y)&&(s.flags|=32),ex(i,s),rn(i,s,w,l),s.child;case 6:return i===null&&sp(s),null;case 13:return ix(i,s,l);case 4:return pp(s,s.stateNode.containerInfo),f=s.pendingProps,i===null?s.child=ls(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),Q2(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,y=s.memoizedProps,w=g.value,at(nc,f._currentValue),f._currentValue=w,y!==null)if(Zn(y.value,w)){if(y.children===g.children&&!mn.current){s=Br(i,s,l);break e}}else for(y=s.child,y!==null&&(y.return=s);y!==null;){var R=y.dependencies;if(R!==null){w=y.child;for(var F=R.firstContext;F!==null;){if(F.context===f){if(y.tag===1){F=Fr(-1,l&-l),F.tag=2;var K=y.updateQueue;if(K!==null){K=K.shared;var ce=K.pending;ce===null?F.next=F:(F.next=ce.next,ce.next=F),K.pending=F}}y.lanes|=l,F=y.alternate,F!==null&&(F.lanes|=l),dp(y.return,l,s),R.lanes|=l;break}F=F.next}}else if(y.tag===10)w=y.type===s.type?null:y.child;else if(y.tag===18){if(w=y.return,w===null)throw Error(n(341));w.lanes|=l,R=w.alternate,R!==null&&(R.lanes|=l),dp(w,l,s),w=y.sibling}else w=y.child;if(w!==null)w.return=y;else for(w=y;w!==null;){if(w===s){w=null;break}if(y=w.sibling,y!==null){y.return=w.return,w=y;break}w=w.return}y=w}rn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,f=s.pendingProps.children,ds(s,l),g=Un(g),f=f(g),s.flags|=1,rn(i,s,f,l),s.child;case 14:return f=s.type,g=tr(f,s.pendingProps),g=tr(f.type,g),X2(i,s,f,g,l);case 15:return J2(i,s,s.type,s.pendingProps,l);case 17:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),pc(i,s),s.tag=1,gn(f)?(i=!0,Ql(s)):i=!1,ds(s,l),$2(s,f,g),Cp(s,f,g,l),Ip(null,s,f,!0,i,l);case 19:return sx(i,s,l);case 22:return Z2(i,s,l)}throw Error(n(156,s.tag))};function Ox(i,s){return lb(i,s)}function KM(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 KM(i,s,l,f)}function Xp(i){return i=i.prototype,!(!i||!i.isReactComponent)}function QM(i){if(typeof i=="function")return Xp(i)?1:0;if(i!=null){if(i=i.$$typeof,i===te)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 vc(i,s,l,f,g,y){var w=2;if(f=i,typeof i=="function")Xp(i)&&(w=1);else if(typeof i=="string")w=5;else e:switch(i){case G:return oo(l.children,g,y,s);case pe:w=8,g|=8;break;case re:return i=jn(12,l,s,g|2),i.elementType=re,i.lanes=y,i;case oe:return i=jn(13,l,s,g),i.elementType=oe,i.lanes=y,i;case de:return i=jn(19,l,s,g),i.elementType=de,i.lanes=y,i;case me:return Ac(l,g,y,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case z:w=10;break e;case W:w=9;break e;case te:w=11;break e;case be:w=14;break e;case Ne: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=y,s}function oo(i,s,l,f){return i=jn(7,i,f,s),i.lanes=l,i}function Ac(i,s,l,f){return i=jn(22,i,f,s),i.elementType=me,i.lanes=l,i.stateNode={isHidden:!1},i}function Jp(i,s,l){return i=jn(6,i,null,s),i.lanes=l,i}function Zp(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 XM(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=Ah(0),this.expirationTimes=Ah(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ah(0),this.identifierPrefix=f,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function em(i,s,l,f,g,y,w,R,F){return i=new XM(i,s,l,R,F),s===1?(s=1,y===!0&&(s|=8)):s=0,y=jn(3,null,null,s),i.current=y,y.stateNode=i,y.memoizedState={element:f,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},hp(y),i}function JM(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 Ix(i){if(!i)return ci;i=i._reactInternals;e:{if(Wi(i)!==i||i.tag!==1)throw Error(n(170));var s=i;do{switch(s.tag){case 3:s=s.stateNode.context;break e;case 1:if(gn(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break e}}s=s.return}while(s!==null);throw Error(n(171))}if(i.tag===1){var l=i.type;if(gn(l))return o2(i,l,s)}return s}function Rx(i,s,l,f,g,y,w,R,F){return i=em(l,f,!0,i,g,y,w,R,F),i.context=Ix(null),l=i.current,f=on(),g=Ei(l),y=Fr(f,g),y.callback=s!=null?s:null,hi(l,y,g),i.current.lanes=g,xa(i,g,f),Tn(i,f),i}function Cc(i,s,l,f){var g=s.current,y=on(),w=Ei(g);return l=Ix(l),s.context===null?s.context=l:s.pendingContext=l,s=Fr(y,w),s.payload={element:i},f=f===void 0?null:f,f!==null&&(s.callback=f),i=hi(g,s,w),i!==null&&(ir(i,g,w,y),ic(i,g,w)),w}function kc(i){return i=i.current,i.child?(i.child.tag===5,i.child.stateNode):null}function Px(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function tm(i,s){Px(i,s),(i=i.alternate)&&Px(i,s)}function ZM(){return null}var Lx=typeof reportError=="function"?reportError:function(i){console.error(i)};function nm(i){this._internalRoot=i}Nc.prototype.render=nm.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Cc(i,s,null,null)},Nc.prototype.unmount=nm.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;no(function(){Cc(null,i,null,null)}),s[Rr]=null}};function Nc(i){this._internalRoot=i}Nc.prototype.unstable_scheduleHydration=function(i){if(i){var s=Eb();i={blockedOn:null,target:i,priority:s};for(var l=0;l<oi.length&&s!==0&&s<oi[l].priority;l++);oi.splice(l,0,i),l===0&&bb(i)}};function rm(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function Oc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function Dx(){}function eF(i,s,l,f,g){if(g){if(typeof f=="function"){var y=f;f=function(){var K=kc(w);y.call(K)}}var w=Rx(s,f,i,0,null,!1,!1,"",Dx);return i._reactRootContainer=w,i[Rr]=w.current,Da(i.nodeType===8?i.parentNode:i),no(),w}for(;g=i.lastChild;)i.removeChild(g);if(typeof f=="function"){var R=f;f=function(){var K=kc(F);R.call(K)}}var F=em(i,0,!1,null,null,!1,!1,"",Dx);return i._reactRootContainer=F,i[Rr]=F.current,Da(i.nodeType===8?i.parentNode:i),no(function(){Cc(s,F,l,f)}),F}function Ic(i,s,l,f,g){var y=l._reactRootContainer;if(y){var w=y;if(typeof g=="function"){var R=g;g=function(){var F=kc(w);R.call(F)}}Cc(s,w,i,g)}else w=eF(l,s,i,g,f);return kc(w)}mb=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=ba(s.pendingLanes);l!==0&&(Ch(s,l|1),Tn(s,wt()),(Je&6)===0&&(gs=wt()+500,di()))}break;case 13:no(function(){var f=Mr(i,1);if(f!==null){var g=on();ir(f,i,1,g)}}),tm(i,1)}},kh=function(i){if(i.tag===13){var s=Mr(i,134217728);if(s!==null){var l=on();ir(s,i,134217728,l)}tm(i,134217728)}},gb=function(i){if(i.tag===13){var s=Ei(i),l=Mr(i,s);if(l!==null){var f=on();ir(l,i,s,f)}tm(i,s)}},Eb=function(){return nt},yb=function(i,s){var l=nt;try{return nt=i,s()}finally{nt=l}},bh=function(i,s,l){switch(s){case"input":if(Yo(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=Gl(f);if(!g)throw Error(n(90));qi(f),Yo(f,g)}}}break;case"textarea":Sl(i,l);break;case"select":s=l.value,s!=null&&ei(i,!!l.multiple,s,!1)}},nb=Gp,rb=no;var tF={usingClientEntryPoint:!1,Events:[Ba,rs,Gl,eb,tb,Gp]},Ja={findFiberByHostInstance:Gi,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},nF={bundleType:Ja.bundleType,version:Ja.version,rendererPackageName:Ja.rendererPackageName,rendererConfig:Ja.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=ab(i),i===null?null:i.stateNode},findFiberByHostInstance:Ja.findFiberByHostInstance||ZM,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 Rc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Rc.isDisabled&&Rc.supportsFiber)try{Nl=Rc.inject(nF),Tr=Rc}catch(i){}}return ln.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=tF,ln.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!rm(s))throw Error(n(200));return JM(i,s,null,l)},ln.createRoot=function(i,s){if(!rm(i))throw Error(n(299));var l=!1,f="",g=Lx;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(f=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=em(i,1,!1,null,null,l,!1,f,g),i[Rr]=s.current,Da(i.nodeType===8?i.parentNode:i),new nm(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=ab(s),i=i===null?null:i.stateNode,i},ln.flushSync=function(i){return no(i)},ln.hydrate=function(i,s,l){if(!Oc(s))throw Error(n(200));return Ic(null,i,s,!0,l)},ln.hydrateRoot=function(i,s,l){if(!rm(i))throw Error(n(405));var f=l!=null&&l.hydratedSources||null,g=!1,y="",w=Lx;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(y=l.identifierPrefix),l.onRecoverableError!==void 0&&(w=l.onRecoverableError)),s=Rx(s,null,i,1,l!=null?l:null,g,!1,y,w),i[Rr]=s.current,Da(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 Nc(s)},ln.render=function(i,s,l){if(!Oc(s))throw Error(n(200));return Ic(null,i,s,!1,l)},ln.unmountComponentAtNode=function(i){if(!Oc(i))throw Error(n(40));return i._reactRootContainer?(no(function(){Ic(null,null,i,!1,function(){i._reactRootContainer=null,i[Rr]=null})}),!0):!1},ln.unstable_batchedUpdates=Gp,ln.unstable_renderSubtreeIntoContainer=function(i,s,l,f){if(!Oc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Ic(i,s,l,!1,f)},ln.version="18.3.1-next-f1338f8080-20240426",ln}var x0;function w0(){if(x0)return yd.exports;x0=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(),yd.exports=lv(),yd.exports}var Ns=w0();function _0(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=_0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ae(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=_0(e))&&(r&&(r+=" "),r+=t);return r}var S0={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},v0=xi.createContext&&xi.createContext(S0),cv=["attr","size","title"];function dv(e,t){if(e==null)return{};var n=fv(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 fv(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 wu(){return wu=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},wu.apply(this,arguments)}function A0(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 _u(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?A0(Object(n),!0).forEach(function(r){hv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):A0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hv(e,t,n){return t=pv(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pv(e){var t=mv(e,"string");return typeof t=="symbol"?t:t+""}function mv(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 C0(e){return e&&e.map((t,n)=>xi.createElement(t.tag,_u({key:n},t.attr),C0(t.child)))}function tn(e){return t=>xi.createElement(gv,wu({attr:_u({},e.attr)},t),C0(e.child))}function gv(e){var t=n=>{var{attr:r,size:o,title:a}=e,u=dv(e,cv),c=o||n.size||"1em",d;return n.className&&(d=n.className),e.className&&(d=(d?d+" ":"")+e.className),xi.createElement("svg",wu({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,u,{className:d,style:_u(_u({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&xi.createElement("title",null,a),e.children)};return v0!==void 0?xi.createElement(v0.Consumer,null,n=>t(n)):t(S0)}function Ev(e){return tn({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 $r=({className:e,iconUrl:t,icon:n,type:r="button",ariaLabel:o,title:a,disabled:u=!1,onClick:c})=>!n&&!t?null:P.jsx("button",{className:ae(e,`${ee}-icon-button`),type:r,"aria-label":o,title:a,onClick:c,disabled:u,children:t?P.jsx("img",{className:ae(`${ee}-icon-image`),src:t,alt:o,loading:"lazy"}):n}),yv="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",Tv=({onClick:e})=>{const{globalClassName:t,headerConfig:n,mode:r}=kt(),o=r==="messaging",a=o?"Open Commerce Client":"Open Copilot",u=o?P.jsx(Ev,{className:ae(t,`${ee}-minimized-icon`)}):P.jsx("img",{src:(n==null?void 0:n.logoUrl)||yv,alt:"Copilot",className:ae(t,`${ee}-minimized-icon-img`)});return P.jsx($r,{className:ae(t,`${ee}-minimized-button`),ariaLabel:a,title:a,icon:u,onClick:e})},bv=()=>{const{globalClassName:e,themeVariables:t}=kt(),n=()=>{bu(!1),Ai(!0)};return Ns.createPortal(P.jsx("div",{className:ae(e,`${ee}-minimized-container`),style:t,children:P.jsx(Tv,{onClick:n})}),document.body)};function xv(e){return tn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3.5 8a5.5 5.5 0 1 1 8.596 4.547 9.005 9.005 0 0 1 5.9 8.18.751.751 0 0 1-1.5.045 7.5 7.5 0 0 0-14.993 0 .75.75 0 0 1-1.499-.044 9.005 9.005 0 0 1 5.9-8.181A5.496 5.496 0 0 1 3.5 8ZM9 4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Zm8.29 4c-.148 0-.292.01-.434.03a.75.75 0 1 1-.212-1.484 4.53 4.53 0 0 1 3.38 8.097 6.69 6.69 0 0 1 3.956 6.107.75.75 0 0 1-1.5 0 5.193 5.193 0 0 0-3.696-4.972l-.534-.16v-1.676l.41-.209A3.03 3.03 0 0 0 17.29 8Z"},child:[]}]})(e)}function ki(){const e=X.useContext(d0);if(!e)throw new Error("useMessaging must be used within a MessagingProvider");return e}const wv=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 k0(e){return tn({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 N0(e){return tn({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 _v(e){return tn({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 Sv(e){return tn({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 vv(e){return tn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"},child:[]}]})(e)}const O0=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>P.jsx("button",{className:ae(`${ee}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),Av=({searchConfig:e,globalClassName:t})=>{const n=e.buttonIconUrl;return n?P.jsx("img",{className:ae(`${ee}-search-button-icon-image`,t),src:n,alt:"",loading:"lazy"}):P.jsx(N0,{size:"16px"})},Cv=({className:e,searchConfig:t,globalClassName:n,componentType:r,isLoading:o})=>{if((t==null?void 0:t.buttonType)==="icon")return P.jsx($r,{className:ae(e,n,`cim-${r}-component`,`${ee}-search-button-icon`),type:"submit",disabled:o,ariaLabel:(t==null?void 0:t.buttonAriaLabel)||(t==null?void 0:t.buttonLabel)||"Search Copilot",icon:t!=null&&t.buttonIconUrl?null:P.jsx(N0,{size:"16px"}),iconUrl:t==null?void 0:t.buttonIconUrl});const a=(t==null?void 0:t.buttonType)==="icon-text";return P.jsxs(O0,{className:ae(e,n,`cim-${r}-component`,`${ee}-search-button`),type:"submit","aria-label":(t==null?void 0:t.buttonAriaLabel)||"",disabled:o,children:[a&&P.jsx(Av,{globalClassName:n,searchConfig:t}),(t==null?void 0:t.buttonLabel)||"Search"]})};function PF(){}function LF(){}function I0(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 R0(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const kv=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Nv=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Ov={};function P0(e,t){return(Ov.jsx?Nv:kv).test(e)}const Iv=/[ \t\n\f\r]/g;function Rv(e){return typeof e=="object"?e.type==="text"?L0(e.value):!1:L0(e)}function L0(e){return e.replace(Iv,"")===""}let Os=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Os.prototype.normal={},Os.prototype.property={},Os.prototype.space=void 0;function D0(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Os(n,r,t)}function Is(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 Pv=0;const je=Ni(),vt=Ni(),xd=Ni(),ge=Ni(),ot=Ni(),ho=Ni(),bn=Ni();function Ni(){return Za(2,++Pv)}const wd=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:vt,commaOrSpaceSeparated:bn,commaSeparated:ho,number:ge,overloadedBoolean:xd,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),_d=Object.keys(wd);let Sd=class extends cn{constructor(t,n,r,o){let a=-1;if(super(t,n),M0(this,"space",o),typeof r=="number")for(;++a<_d.length;){const u=_d[a];M0(this,_d[a],(r&wd[u])===wd[u])}}};Sd.prototype.defined=!0;function M0(e,t,n){n&&(e[t]=n)}function po(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const a=new Sd(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Is(r)]=r,n[Is(a.attribute)]=r}return new Os(t,n,e.space)}const F0=po({properties:{ariaActiveDescendant:null,ariaAtomic:vt,ariaAutoComplete:null,ariaBusy:vt,ariaChecked:vt,ariaColCount:ge,ariaColIndex:ge,ariaColSpan:ge,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:vt,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:vt,ariaFlowTo:ot,ariaGrabbed:vt,ariaHasPopup:null,ariaHidden:vt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:ge,ariaLive:null,ariaModal:vt,ariaMultiLine:vt,ariaMultiSelectable:vt,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:ge,ariaPressed:vt,ariaReadOnly:vt,ariaRelevant:null,ariaRequired:vt,ariaRoleDescription:ot,ariaRowCount:ge,ariaRowIndex:ge,ariaRowSpan:ge,ariaSelected:vt,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 B0(e,t){return t in e?e[t]:t}function U0(e,t){return B0(e,t.toLowerCase())}const Lv=po({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:ho,acceptCharset:ot,accessKey:ot,action:null,allow:null,allowFullScreen:je,allowPaymentRequest:je,allowUserMedia:je,alt:null,as:null,async:je,autoCapitalize:null,autoComplete:ot,autoFocus:je,autoPlay:je,blocking:ot,capture:null,charSet:null,checked:je,cite:null,className:ot,cols:ge,colSpan:null,content:null,contentEditable:vt,controls:je,controlsList:ot,coords:ge|ho,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:xd,draggable:vt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:ot,height:ge,hidden:xd,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:vt,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:vt,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:vt,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:U0}),Dv=po({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:bn,accentHeight: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:ho,g2:ho,glyphName:ho,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:bn,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:bn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:bn,rev:bn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:bn,requiredFeatures:bn,requiredFonts:bn,requiredFormats:bn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant: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:bn,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:bn,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:bn,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:B0}),H0=po({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),z0=po({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:U0}),j0=po({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),Mv={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"},Fv=/[A-Z]/g,$0=/-[a-z]/g,Bv=/^data[-\w.:]+$/i;function vd(e,t){const n=Is(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"&&Bv.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace($0,Hv);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!$0.test(a)){let u=a.replace(Fv,Uv);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Sd}return new o(r,t)}function Uv(e){return"-"+e.toLowerCase()}function Hv(e){return e.charAt(1).toUpperCase()}const Su=D0([F0,Lv,H0,z0,j0],"html"),mo=D0([F0,Dv,H0,z0,j0],"svg");function V0(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function q0(e){return e.join(" ").trim()}var go={},Ad,Y0;function zv(){if(Y0)return Ad;Y0=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="",b="comment",T="declaration";Ad=function(_,S){if(typeof _!="string")throw new TypeError("First argument must be a string");if(!_)return[];S=S||{};var A=1,O=1;function I(oe){var de=oe.match(t);de&&(A+=de.length);var be=oe.lastIndexOf(d);O=~be?oe.length-be:O+oe.length}function H(){var oe={line:A,column:O};return function(de){return de.position=new Y(oe),pe(),de}}function Y(oe){this.start=oe,this.end={line:A,column:O},this.source=S.source}Y.prototype.content=_;function M(oe){var de=new Error(S.source+":"+A+":"+O+": "+oe);if(de.reason=oe,de.filename=S.source,de.line=A,de.column=O,de.source=_,!S.silent)throw de}function G(oe){var de=oe.exec(_);if(de){var be=de[0];return I(be),_=_.slice(be.length),de}}function pe(){G(n)}function re(oe){var de;for(oe=oe||[];de=z();)de!==!1&&oe.push(de);return oe}function z(){var oe=H();if(!(h!=_.charAt(0)||p!=_.charAt(1))){for(var de=2;E!=_.charAt(de)&&(p!=_.charAt(de)||h!=_.charAt(de+1));)++de;if(de+=2,E===_.charAt(de-1))return M("End of comment missing");var be=_.slice(2,de-2);return O+=2,I(be),_=_.slice(de),O+=2,oe({type:b,comment:be})}}function W(){var oe=H(),de=G(r);if(de){if(z(),!G(o))return M("property missing ':'");var be=G(a),Ne=oe({type:T,property:x(de[0].replace(e,E)),value:be?x(be[0].replace(e,E)):E});return G(u),Ne}}function te(){var oe=[];re(oe);for(var de;de=W();)de!==!1&&(oe.push(de),re(oe));return oe}return pe(),te()};function x(_){return _?_.replace(c,E):E}return Ad}var W0;function jv(){if(W0)return go;W0=1;var e=go&&go.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(go,"__esModule",{value:!0}),go.default=n;var t=e(zv());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 go}var Rs={},G0;function $v(){if(G0)return Rs;G0=1,Object.defineProperty(Rs,"__esModule",{value:!0}),Rs.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 Rs.camelCase=d,Rs}var Ps,K0;function Vv(){if(K0)return Ps;K0=1;var e=Ps&&Ps.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(jv()),n=$v();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,Ps=r,Ps}var qv=Vv();const Yv=We(qv),vu=Q0("end"),ar=Q0("start");function Q0(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 X0(e){const t=ar(e),n=vu(e);if(t&&n)return{start:t,end:n}}function Ls(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?J0(e.position):"start"in e||"end"in e?J0(e):"line"in e||"column"in e?Cd(e):""}function Cd(e){return Z0(e&&e.line)+":"+Z0(e&&e.column)}function J0(e){return Cd(e&&e.start)+"-"+Cd(e&&e.end)}function Z0(e){return e&&typeof e=="number"?e:1}class Yt extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let o="",a={},u=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a=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=Ls(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=u&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual,this.expected,this.note,this.url}}Yt.prototype.file="",Yt.prototype.name="",Yt.prototype.reason="",Yt.prototype.message="",Yt.prototype.stack="",Yt.prototype.column=void 0,Yt.prototype.line=void 0,Yt.prototype.ancestors=void 0,Yt.prototype.cause=void 0,Yt.prototype.fatal=void 0,Yt.prototype.place=void 0,Yt.prototype.ruleId=void 0,Yt.prototype.source=void 0;const kd={}.hasOwnProperty,Wv=new Map,Gv=/[A-Z]/g,Kv=new Set(["table","tbody","thead","tfoot","tr"]),Qv=new Set(["td","th"]),eg="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function Xv(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=oA(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=iA(n,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?mo:Su,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=tg(o,e,void 0);return a&&typeof a!="string"?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function tg(e,t,n){if(t.type==="element")return Jv(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return Zv(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return tA(e,t,n);if(t.type==="mdxjsEsm")return eA(e,t);if(t.type==="root")return nA(e,t,n);if(t.type==="text")return rA(e,t)}function Jv(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=rg(e,t.tagName,!1),u=sA(e,t);let c=Od(e,t);return Kv.has(t.tagName)&&(c=c.filter(function(d){return typeof d=="string"?!Rv(d):!0})),ng(e,u,a,t),Nd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function Zv(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)}Ds(e,t.position)}function eA(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ds(e,t.position)}function tA(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=t.name===null?e.Fragment:rg(e,t.name,!0),u=aA(e,t),c=Od(e,t);return ng(e,u,a,t),Nd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function nA(e,t,n){const r={};return Nd(r,Od(e,t)),e.create(t,e.Fragment,r,n)}function rA(e,t){return t.value}function ng(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Nd(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function iA(e,t,n){return r;function r(o,a,u,c){const h=Array.isArray(u.children)?n:t;return c?h(a,u,c):h(a,u)}}function oA(e,t){return n;function n(r,o,a,u){const c=Array.isArray(a.children),d=ar(r);return t(o,a,u,c,{columnNumber:d?d.column-1:void 0,fileName:e,lineNumber:d?d.line:void 0},void 0)}}function sA(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&kd.call(t.properties,o)){const a=uA(e,o,t.properties[o]);if(a){const[u,c]=a;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&Qv.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 aA(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 Ds(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 Ds(e,t.position);else a=r.value===null?!0:r.value;n[o]=a}return n}function Od(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:Wv;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=tg(e,a,u);c!==void 0&&n.push(c)}return n}function uA(e,t,n){const r=vd(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?R0(n):q0(n)),r.property==="style"){let o=typeof n=="object"?n:lA(e,String(n));return e.stylePropertyNameCase==="css"&&(o=cA(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?Mv[r.property]||r.property:r.attribute,n]}}function lA(e,t){try{return Yv(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new Yt("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=eg+"#cannot-parse-style-attribute",o}}function rg(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=P0(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=P0(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return kd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);Ds(e)}function Ds(e,t){const n=new Yt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=eg+"#cannot-handle-mdx-estrees-without-createevaluater",n}function cA(e){const t={};let n;for(n in e)kd.call(e,n)&&(t[dA(n)]=e[n]);return t}function dA(e){let t=e.replace(Gv,fA);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function fA(e){return"-"+e.toLowerCase()}const Id={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"]},hA={};function Rd(e,t){const n=hA,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return ig(e,r,o)}function ig(e,t,n){if(pA(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 og(e.children,t,n)}return Array.isArray(e)?og(e,t,n):""}function og(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=ig(e[o],t,n);return r.join("")}function pA(e){return!!(e&&typeof e=="object")}const sg=document.createElement("i");function Pd(e){const t="&"+e+";";sg.innerHTML=t;const n=sg.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 ag={}.hasOwnProperty;function ug(e){const t={};let n=-1;for(;++n<e.length;)mA(t,e[n]);return t}function mA(e,t){let n;for(n in t){const o=(ag.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let u;if(a)for(u in a){ag.call(o,u)||(o[u]=[]);const c=a[u];gA(o[u],Array.isArray(c)?c:c?[c]:[])}}}function gA(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 lg(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=Vr(/[A-Za-z]/),Wt=Vr(/[\dA-Za-z]/),EA=Vr(/[#-'*+\--9=?A-Z^-~]/);function Au(e){return e!==null&&(e<32||e===127)}const Ld=Vr(/\d/),yA=Vr(/[\dA-Fa-f]/),TA=Vr(/[!-/:-@[-`{-~]/);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 Cu=Vr(new RegExp("\\p{P}|\\p{S}","u")),Oi=Vr(/\s/);function Vr(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Eo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let u="";if(a===37&&Wt(e.charCodeAt(n+1))&&Wt(e.charCodeAt(n+2)))o=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(u=String.fromCharCode(a));else if(a>55295&&a<57344){const c=e.charCodeAt(n+1);a<56320&&c>56319&&c<57344?(u=String.fromCharCode(a,c),o=1):u="�"}else u=String.fromCharCode(a);u&&(t.push(e.slice(r,n),encodeURIComponent(u)),r=n+o+1,u=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function 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 bA={tokenize:xA};function xA(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 wA={tokenize:_A},cg={tokenize:SA};function _A(e){const t=this,n=[];let r=0,o,a,u;return c;function c(I){if(r<n.length){const H=n[r];return t.containerState=H[1],e.attempt(H[0].continuation,d,h)(I)}return h(I)}function d(I){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&O();const H=t.events.length;let Y=H,M;for(;Y--;)if(t.events[Y][0]==="exit"&&t.events[Y][1].type==="chunkFlow"){M=t.events[Y][1].end;break}A(r);let G=H;for(;G<t.events.length;)t.events[G][1].end=B({},M),G++;return xn(t.events,Y+1,0,t.events.slice(H)),t.events.length=G,h(I)}return c(I)}function h(I){if(r===n.length){if(!o)return b(I);if(o.currentConstruct&&o.currentConstruct.concrete)return x(I);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(cg,p,E)(I)}function p(I){return o&&O(),A(r),b(I)}function E(I){return t.parser.lazy[t.now().line]=r!==n.length,u=t.now().offset,x(I)}function b(I){return t.containerState={},e.attempt(cg,T,x)(I)}function T(I){return r++,n.push([t.currentConstruct,t.containerState]),b(I)}function x(I){if(I===null){o&&O(),A(0),e.consume(I);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:a}),_(I)}function _(I){if(I===null){S(e.exit("chunkFlow"),!0),A(0),e.consume(I);return}return Le(I)?(e.consume(I),S(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(I),_)}function S(I,H){const Y=t.sliceStream(I);if(H&&Y.push(null),I.previous=a,a&&(a.next=I),a=I,o.defineSkip(I.start),o.write(Y),t.parser.lazy[I.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 G=t.events.length;let pe=G,re,z;for(;pe--;)if(t.events[pe][0]==="exit"&&t.events[pe][1].type==="chunkFlow"){if(re){z=t.events[pe][1].end;break}re=!0}for(A(r),M=G;M<t.events.length;)t.events[M][1].end=B({},z),M++;xn(t.events,pe+1,0,t.events.slice(G)),t.events.length=M}}function A(I){let H=n.length;for(;H-- >I;){const Y=n[H];t.containerState=Y[1],Y[0].exit.call(t,e)}n.length=I}function O(){o.write([null]),a=void 0,o=void 0,t.containerState._closeFlow=void 0}}function SA(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 yo(e){if(e===null||it(e)||Oi(e))return 1;if(Cu(e))return 2}function ku(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 Dd={name:"attention",resolveAll:vA,tokenize:AA};function vA(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),b=B({},e[n][1].start);dg(E,-d),dg(b,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:b},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,ku(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 AA(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=yo(r);let a;return u;function u(d){return a=d,e.enter("attentionSequence"),c(d)}function c(d){if(d===a)return e.consume(d),c;const h=e.exit("attentionSequence"),p=yo(d),E=!p||p===2&&o||n.includes(d),b=!o||o===2&&p||n.includes(r);return h._open=!!(a===42?E:E&&(o||!b)),h._close=!!(a===42?b:b&&(p||!E)),t(d)}}function dg(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const CA={name:"autolink",tokenize:kA};function kA(e,t,n){let r=0;return o;function o(T){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(T){return nn(T)?(e.consume(T),u):T===64?n(T):h(T)}function u(T){return T===43||T===45||T===46||Wt(T)?(r=1,c(T)):h(T)}function c(T){return T===58?(e.consume(T),r=0,d):(T===43||T===45||T===46||Wt(T))&&r++<32?(e.consume(T),c):(r=0,h(T))}function d(T){return T===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):T===null||T===32||T===60||Au(T)?n(T):(e.consume(T),d)}function h(T){return T===64?(e.consume(T),p):EA(T)?(e.consume(T),h):n(T)}function p(T){return Wt(T)?E(T):n(T)}function E(T){return T===46?(e.consume(T),r=0,p):T===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):b(T)}function b(T){if((T===45||Wt(T))&&r++<63){const x=T===45?b:E;return e.consume(T),x}return n(T)}}const Ms={partial:!0,tokenize:NA};function NA(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 fg={continuation:{tokenize:IA},exit:RA,name:"blockQuote",tokenize:OA};function OA(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 IA(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(fg,t,n)(u)}}function RA(e){e.exit("blockQuote")}const hg={name:"characterEscape",tokenize:PA};function PA(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 TA(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const pg={name:"characterReference",tokenize:LA};function LA(e,t,n){const r=this;let o=0,a,u;return c;function c(E){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),d}function d(E){return E===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(E),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),a=31,u=Wt,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=yA,p):(e.enter("characterReferenceValue"),a=7,u=Ld,p(E))}function p(E){if(E===59&&o){const b=e.exit("characterReferenceValue");return u===Wt&&!Pd(r.sliceSerialize(b))?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 mg={partial:!0,tokenize:MA},gg={concrete:!0,name:"codeFenced",tokenize:DA};function DA(e,t,n){const r=this,o={partial:!0,tokenize:Y};let a=0,u=0,c;return d;function d(M){return h(M)}function h(M){const G=r.events[r.events.length-1];return a=G&&G[1].type==="linePrefix"?G[2].sliceSerialize(G[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(mg,_,H)(M)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(M))}function b(M){return M===null||Le(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),E(M)):Ge(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Qe(e,T,"whitespace")(M)):M===96&&M===c?n(M):(e.consume(M),b)}function T(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,H,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(mg,_,H)(M):(e.enter("codeFlowValue"),I(M))}function I(M){return M===null||Le(M)?(e.exit("codeFlowValue"),O(M)):(e.consume(M),I)}function H(M){return e.exit("codeFenced"),t(M)}function Y(M,G,pe){let re=0;return z;function z(be){return M.enter("lineEnding"),M.consume(be),M.exit("lineEnding"),W}function W(be){return M.enter("codeFencedFence"),Ge(be)?Qe(M,te,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(be):te(be)}function te(be){return be===c?(M.enter("codeFencedFenceSequence"),oe(be)):pe(be)}function oe(be){return be===c?(re++,M.consume(be),oe):re>=u?(M.exit("codeFencedFenceSequence"),Ge(be)?Qe(M,de,"whitespace")(be):de(be)):pe(be)}function de(be){return be===null||Le(be)?(M.exit("codeFencedFence"),G(be)):pe(be)}}}function MA(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 Md={name:"codeIndented",tokenize:BA},FA={partial:!0,tokenize:UA};function BA(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(FA,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 UA(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 HA={name:"codeText",previous:jA,resolve:zA,tokenize:$A};function zA(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 jA(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function $A(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 VA{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&&Fs(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),Fs(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Fs(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);Fs(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Fs(this.left,n.reverse())}}}function Fs(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 Eg(e){const t={};let n=-1,r,o,a,u,c,d,h;const p=new VA(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,qA(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 qA(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,b=-1,T=n,x=0,_=0;const S=[_];for(;T;){for(;e.get(++o)[1]!==T;);a.push(o),T._tokenizer||(p=r.sliceStream(T),T.next||p.push(null),E&&u.defineSkip(T.start),T._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=!0),u.write(p),T._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=void 0)),E=T,T=T.next}for(T=n;++b<c.length;)c[b][0]==="exit"&&c[b-1][0]==="enter"&&c[b][1].type===c[b-1][1].type&&c[b][1].start.line!==c[b][1].end.line&&(_=b+1,S.push(_),T._tokenizer=void 0,T.previous=void 0,T=T.next);for(u.events=[],T?(T._tokenizer=void 0,T.previous=void 0):S.pop(),b=S.length;b--;){const A=c.slice(S[b],S[b+1]),O=a.pop();d.push([O,O+A.length-1]),e.splice(O,2,A)}for(d.reverse(),b=-1;++b<d.length;)h[x+d[b][0]]=x+d[b][1],x+=d[b][1]-d[b][0]-1;return h}const YA={resolve:GA,tokenize:KA},WA={partial:!0,tokenize:QA};function GA(e){return Eg(e),e}function KA(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(WA,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 QA(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 yg(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),b):A===null||A===32||A===41||Au(A)?n(A):(e.enter(r),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),_(A))}function b(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"}),T(A))}function T(A){return A===62?(e.exit("chunkString"),e.exit(c),b(A)):A===null||A===60||Le(A)?n(A):(e.consume(A),A===92?x:T)}function x(A){return A===60||A===62||A===92?(e.consume(A),T):T(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||Au(A)?n(A):(e.consume(A),A===92?S:_)}function S(A){return A===40||A===41||A===92?(e.consume(A),_):_(A)}}function Tg(e,t,n,r,o,a){const u=this;let c=0,d;return h;function h(T){return e.enter(r),e.enter(o),e.consume(T),e.exit(o),e.enter(a),p}function p(T){return c>999||T===null||T===91||T===93&&!d||T===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(T):T===93?(e.exit(a),e.enter(o),e.consume(T),e.exit(o),e.exit(r),t):Le(T)?(e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),p):(e.enter("chunkString",{contentType:"string"}),E(T))}function E(T){return T===null||T===91||T===93||Le(T)||c++>999?(e.exit("chunkString"),p(T)):(e.consume(T),d||(d=!Ge(T)),T===92?b:E)}function b(T){return T===91||T===92||T===93?(e.consume(T),c++,E):E(T)}}function bg(e,t,n,r,o,a){let u;return c;function c(b){return b===34||b===39||b===40?(e.enter(r),e.enter(o),e.consume(b),e.exit(o),u=b===40?41:b,d):n(b)}function d(b){return b===u?(e.enter(o),e.consume(b),e.exit(o),e.exit(r),t):(e.enter(a),h(b))}function h(b){return b===u?(e.exit(a),d(u)):b===null?n(b):Le(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Qe(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),p(b))}function p(b){return b===u||b===null||Le(b)?(e.exit("chunkString"),h(b)):(e.consume(b),b===92?E:p)}function E(b){return b===u||b===92?(e.consume(b),p):p(b)}}function Bs(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 XA={name:"definition",tokenize:ZA},JA={partial:!0,tokenize:eC};function ZA(e,t,n){const r=this;let o;return a;function a(T){return e.enter("definition"),u(T)}function u(T){return Tg.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(T)}function c(T){return o=Yn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),T===58?(e.enter("definitionMarker"),e.consume(T),e.exit("definitionMarker"),d):n(T)}function d(T){return it(T)?Bs(e,h)(T):h(T)}function h(T){return yg(e,p,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(T)}function p(T){return e.attempt(JA,E,E)(T)}function E(T){return Ge(T)?Qe(e,b,"whitespace")(T):b(T)}function b(T){return T===null||Le(T)?(e.exit("definition"),r.parser.defined.push(o),t(T)):n(T)}}function eC(e,t,n){return r;function r(c){return it(c)?Bs(e,o)(c):n(c)}function o(c){return bg(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 tC={name:"hardBreakEscape",tokenize:nC};function nC(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 rC={name:"headingAtx",resolve:iC,tokenize:oC};function iC(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 oC(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 sC=["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"],xg=["pre","script","style","textarea"],aC={concrete:!0,name:"htmlFlow",resolveTo:cC,tokenize:dC},uC={partial:!0,tokenize:hC},lC={partial:!0,tokenize:fC};function cC(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),b):k===47?(e.consume(k),a=!0,_):k===63?(e.consume(k),o=3,r.interrupt?t:v):nn(k)?(e.consume(k),u=String.fromCharCode(k),S):n(k)}function b(k){return k===45?(e.consume(k),o=2,T):k===91?(e.consume(k),o=5,c=0,x):nn(k)?(e.consume(k),o=4,r.interrupt?t:v):n(k)}function T(k){return k===45?(e.consume(k),r.interrupt?t:v):n(k)}function x(k){const xe="CDATA[";return k===xe.charCodeAt(c++)?(e.consume(k),c===xe.length?r.interrupt?t:te: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 xe=k===47,Pe=u.toLowerCase();return!xe&&!a&&xg.includes(Pe)?(o=1,r.interrupt?t(k):te(k)):sC.includes(u.toLowerCase())?(o=6,xe?(e.consume(k),A):r.interrupt?t(k):te(k)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?O(k):I(k))}return k===45||Wt(k)?(e.consume(k),u+=String.fromCharCode(k),S):n(k)}function A(k){return k===62?(e.consume(k),r.interrupt?t:te):n(k)}function O(k){return Ge(k)?(e.consume(k),O):z(k)}function I(k){return k===47?(e.consume(k),z):k===58||k===95||nn(k)?(e.consume(k),H):Ge(k)?(e.consume(k),I):z(k)}function H(k){return k===45||k===46||k===58||k===95||Wt(k)?(e.consume(k),H):Y(k)}function Y(k){return k===61?(e.consume(k),M):Ge(k)?(e.consume(k),Y):I(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,G):Ge(k)?(e.consume(k),M):pe(k)}function G(k){return k===d?(e.consume(k),d=null,re):k===null||Le(k)?n(k):(e.consume(k),G)}function pe(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||it(k)?Y(k):(e.consume(k),pe)}function re(k){return k===47||k===62||Ge(k)?I(k):n(k)}function z(k){return k===62?(e.consume(k),W):n(k)}function W(k){return k===null||Le(k)?te(k):Ge(k)?(e.consume(k),W):n(k)}function te(k){return k===45&&o===2?(e.consume(k),Ne):k===60&&o===1?(e.consume(k),me):k===62&&o===4?(e.consume(k),D):k===63&&o===3?(e.consume(k),v):k===93&&o===5?(e.consume(k),ie):Le(k)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(uC,Z,oe)(k)):k===null||Le(k)?(e.exit("htmlFlowData"),oe(k)):(e.consume(k),te)}function oe(k){return e.check(lC,de,Z)(k)}function de(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),be}function be(k){return k===null||Le(k)?oe(k):(e.enter("htmlFlowData"),te(k))}function Ne(k){return k===45?(e.consume(k),v):te(k)}function me(k){return k===47?(e.consume(k),u="",Q):te(k)}function Q(k){if(k===62){const xe=u.toLowerCase();return xg.includes(xe)?(e.consume(k),D):te(k)}return nn(k)&&u.length<8?(e.consume(k),u+=String.fromCharCode(k),Q):te(k)}function ie(k){return k===93?(e.consume(k),v):te(k)}function v(k){return k===62?(e.consume(k),D):k===45&&o===2?(e.consume(k),v):te(k)}function D(k){return k===null||Le(k)?(e.exit("htmlFlowData"),Z(k)):(e.consume(k),D)}function Z(k){return e.exit("htmlFlow"),t(k)}}function fC(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 hC(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ms,t,n)}}const pC={name:"htmlText",tokenize:mC};function mC(e,t,n){const r=this;let o,a,u;return c;function c(v){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(v),d}function d(v){return v===33?(e.consume(v),h):v===47?(e.consume(v),Y):v===63?(e.consume(v),I):nn(v)?(e.consume(v),pe):n(v)}function h(v){return v===45?(e.consume(v),p):v===91?(e.consume(v),a=0,x):nn(v)?(e.consume(v),O):n(v)}function p(v){return v===45?(e.consume(v),T):n(v)}function E(v){return v===null?n(v):v===45?(e.consume(v),b):Le(v)?(u=E,me(v)):(e.consume(v),E)}function b(v){return v===45?(e.consume(v),T):E(v)}function T(v){return v===62?Ne(v):v===45?b(v):E(v)}function x(v){const D="CDATA[";return v===D.charCodeAt(a++)?(e.consume(v),a===D.length?_:x):n(v)}function _(v){return v===null?n(v):v===93?(e.consume(v),S):Le(v)?(u=_,me(v)):(e.consume(v),_)}function S(v){return v===93?(e.consume(v),A):_(v)}function A(v){return v===62?Ne(v):v===93?(e.consume(v),A):_(v)}function O(v){return v===null||v===62?Ne(v):Le(v)?(u=O,me(v)):(e.consume(v),O)}function I(v){return v===null?n(v):v===63?(e.consume(v),H):Le(v)?(u=I,me(v)):(e.consume(v),I)}function H(v){return v===62?Ne(v):I(v)}function Y(v){return nn(v)?(e.consume(v),M):n(v)}function M(v){return v===45||Wt(v)?(e.consume(v),M):G(v)}function G(v){return Le(v)?(u=G,me(v)):Ge(v)?(e.consume(v),G):Ne(v)}function pe(v){return v===45||Wt(v)?(e.consume(v),pe):v===47||v===62||it(v)?re(v):n(v)}function re(v){return v===47?(e.consume(v),Ne):v===58||v===95||nn(v)?(e.consume(v),z):Le(v)?(u=re,me(v)):Ge(v)?(e.consume(v),re):Ne(v)}function z(v){return v===45||v===46||v===58||v===95||Wt(v)?(e.consume(v),z):W(v)}function W(v){return v===61?(e.consume(v),te):Le(v)?(u=W,me(v)):Ge(v)?(e.consume(v),W):re(v)}function te(v){return v===null||v===60||v===61||v===62||v===96?n(v):v===34||v===39?(e.consume(v),o=v,oe):Le(v)?(u=te,me(v)):Ge(v)?(e.consume(v),te):(e.consume(v),de)}function oe(v){return v===o?(e.consume(v),o=void 0,be):v===null?n(v):Le(v)?(u=oe,me(v)):(e.consume(v),oe)}function de(v){return v===null||v===34||v===39||v===60||v===61||v===96?n(v):v===47||v===62||it(v)?re(v):(e.consume(v),de)}function be(v){return v===47||v===62||it(v)?re(v):n(v)}function Ne(v){return v===62?(e.consume(v),e.exit("htmlTextData"),e.exit("htmlText"),t):n(v)}function me(v){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(v),e.exit("lineEnding"),Q}function Q(v){return Ge(v)?Qe(e,ie,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(v):ie(v)}function ie(v){return e.enter("htmlTextData"),u(v)}}const Fd={name:"labelEnd",resolveAll:TC,resolveTo:bC,tokenize:xC},gC={tokenize:wC},EC={tokenize:_C},yC={tokenize:SC};function TC(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 bC(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,ku(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 xC(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(b){return a?a._inactive?E(b):(u=r.parser.defined.includes(Yn(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),d):n(b)}function d(b){return b===40?e.attempt(gC,p,u?p:E)(b):b===91?e.attempt(EC,p,u?h:E)(b):u?p(b):E(b)}function h(b){return e.attempt(yC,p,E)(b)}function p(b){return t(b)}function E(b){return a._balanced=!0,n(b)}}function wC(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)?Bs(e,a)(E):a(E)}function a(E){return E===41?p(E):yg(e,u,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function u(E){return it(E)?Bs(e,d)(E):p(E)}function c(E){return n(E)}function d(E){return E===34||E===39||E===40?bg(e,h,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(E):p(E)}function h(E){return it(E)?Bs(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 _C(e,t,n){const r=this;return o;function o(c){return Tg.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 SC(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 vC={name:"labelStartImage",resolveAll:Fd.resolveAll,tokenize:AC};function AC(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 CC={name:"labelStartLink",resolveAll:Fd.resolveAll,tokenize:kC};function kC(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 Bd={name:"lineEnding",tokenize:NC};function NC(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Qe(e,t,"linePrefix")}}const Nu={name:"thematicBreak",tokenize:OC};function OC(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:LC},exit:MC,name:"list",tokenize:PC},IC={partial:!0,tokenize:FC},RC={partial:!0,tokenize:DC};function PC(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(T){const x=r.containerState.type||(T===42||T===43||T===45?"listUnordered":"listOrdered");if(x==="listUnordered"?!r.containerState.marker||T===r.containerState.marker:Ld(T)){if(r.containerState.type||(r.containerState.type=x,e.enter(x,{_container:!0})),x==="listUnordered")return e.enter("listItemPrefix"),T===42||T===45?e.check(Nu,n,h)(T):h(T);if(!r.interrupt||T===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),d(T)}return n(T)}function d(T){return Ld(T)&&++u<10?(e.consume(T),d):(!r.interrupt||u<2)&&(r.containerState.marker?T===r.containerState.marker:T===41||T===46)?(e.exit("listItemValue"),h(T)):n(T)}function h(T){return e.enter("listItemMarker"),e.consume(T),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||T,e.check(Ms,r.interrupt?n:p,e.attempt(IC,b,E))}function p(T){return r.containerState.initialBlankLine=!0,a++,b(T)}function E(T){return Ge(T)?(e.enter("listItemPrefixWhitespace"),e.consume(T),e.exit("listItemPrefixWhitespace"),b):n(T)}function b(T){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(T)}}function LC(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Ms,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(RC,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 DC(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 MC(e){e.exit(this.containerState.type)}function FC(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 wg={name:"setextUnderline",resolveTo:BC,tokenize:UC};function BC(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 UC(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 HC={tokenize:zC};function zC(e){const t=this,n=e.attempt(Ms,r,e.attempt(this.parser.constructs.flowInitial,o,Qe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(YA,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 jC={resolveAll:Sg()},$C=_g("string"),VC=_g("text");function _g(e){return{resolveAll:Sg(e==="text"?qC: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 b=-1;if(E)for(;++b<E.length;){const T=E[b];if(!T.previous||T.previous.call(r,r.previous))return!0}return!1}}}function Sg(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 qC(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 YC=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:XA},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:fg},flow:{35:rC,42:Nu,45:[wg,Nu],60:aC,61:wg,95:Nu,96:gg,126:gg},flowInitial:{[-2]:Md,[-1]:Md,32:Md},insideSpan:{null:[Dd,jC]},string:{38:pg,92:hg},text:{[-5]:Bd,[-4]:Bd,[-3]:Bd,33:vC,38:pg,42:Dd,60:[CA,pC],91:CC,92:[tC,hg],93:Fd,95:Dd,96:HA}},Symbol.toStringTag,{value:"Module"}));function WC(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:G(Y),check:G(M),consume:O,enter:I,exit:H,interrupt:G(M,{interrupt:!0})},h={code:null,containerState:{},defineSkip:_,events:[],now:x,parser:e,previous:null,sliceSerialize:b,sliceStream:T,write:E};let p=t.tokenize.call(h,d);return t.resolveAll&&a.push(t),h;function E(W){return u=Rn(u,W),S(),u[u.length-1]!==null?[]:(pe(t,0),h.events=ku(a,h.events,h),h.events)}function b(W,te){return KC(T(W),te)}function T(W){return GC(u,W)}function x(){const{_bufferIndex:W,_index:te,line:oe,column:de,offset:be}=r;return{_bufferIndex:W,_index:te,line:oe,column:de,offset:be}}function _(W){o[W.line]=W.column,z()}function S(){let W;for(;r._index<u.length;){const te=u[r._index];if(typeof te=="string")for(W=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===W&&r._bufferIndex<te.length;)A(te.charCodeAt(r._bufferIndex));else A(te)}}function A(W){p=p(W)}function O(W){Le(W)?(r.line++,r.column=1,r.offset+=W===-3?2:1,z()):W!==-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=W}function I(W,te){const oe=te||{};return oe.type=W,oe.start=x(),h.events.push(["enter",oe,h]),c.push(oe),oe}function H(W){const te=c.pop();return te.end=x(),h.events.push(["exit",te,h]),te}function Y(W,te){pe(W,te.from)}function M(W,te){te.restore()}function G(W,te){return oe;function oe(de,be,Ne){let me,Q,ie,v;return Array.isArray(de)?Z(de):"tokenize"in de?Z([de]):D(de);function D(Oe){return He;function He(Se){const qe=Se!==null&&Oe[Se],ut=Se!==null&&Oe.null,pn=[...Array.isArray(qe)?qe:qe?[qe]:[],...Array.isArray(ut)?ut:ut?[ut]:[]];return Z(pn)(Se)}}function Z(Oe){return me=Oe,Q=0,Oe.length===0?Ne:k(Oe[Q])}function k(Oe){return He;function He(Se){return v=re(),ie=Oe,Oe.partial||(h.currentConstruct=Oe),Oe.name&&h.parser.constructs.disable.null.includes(Oe.name)?Pe():Oe.tokenize.call(te?Object.assign(Object.create(h),te):h,d,xe,Pe)(Se)}}function xe(Oe){return W(ie,v),be}function Pe(Oe){return v.restore(),++Q<me.length?k(me[Q]):Ne}}}function pe(W,te){W.resolveAll&&!a.includes(W)&&a.push(W),W.resolve&&xn(h.events,te,h.events.length-te,W.resolve(h.events.slice(te),h)),W.resolveTo&&(h.events=W.resolveTo(h.events,h))}function re(){const W=x(),te=h.previous,oe=h.currentConstruct,de=h.events.length,be=Array.from(c);return{from:de,restore:Ne};function Ne(){r=W,h.previous=te,h.currentConstruct=oe,h.events.length=de,c=be,z()}}function z(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function GC(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 KC(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const a=e[n];let u;if(typeof a=="string")u=a;else switch(a){case-5:{u="\r";break}case-4:{u=`
|
|
23
|
+
`+y.stack}return{value:i,source:s,stack:g,digest:null}}function kp(i,s,l){return{value:i,source:null,stack:l!=null?l:null,digest:s!=null?s:null}}function Np(i,s){try{console.error(s.value)}catch(l){setTimeout(function(){throw l})}}var RM=typeof WeakMap=="function"?WeakMap:Map;function q2(i,s,l){l=Fr(-1,l),l.tag=3,l.payload={element:null};var f=s.value;return l.callback=function(){Tc||(Tc=!0,Vp=f),Np(i,s)},l}function Y2(i,s,l){l=Fr(-1,l),l.tag=3;var f=i.type.getDerivedStateFromError;if(typeof f=="function"){var g=s.value;l.payload=function(){return f(g)},l.callback=function(){Np(i,s)}}var y=i.stateNode;return y!==null&&typeof y.componentDidCatch=="function"&&(l.callback=function(){Np(i,s),typeof f!="function"&&(mi===null?mi=new Set([this]):mi.add(this));var w=s.stack;this.componentDidCatch(s.value,{componentStack:w!==null?w:""})}),l}function W2(i,s,l){var f=i.pingCache;if(f===null){f=i.pingCache=new RM;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=YM.bind(null,i,s,l),s.then(i,i))}function G2(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 K2(i,s,l,f,g){return(i.mode&1)===0?(i===s?i.flags|=65536:(i.flags|=128,l.flags|=131072,l.flags&=-52805,l.tag===1&&(l.alternate===null?l.tag=17:(s=Fr(-1,1),s.tag=2,hi(l,s,1))),l.lanes|=1),i):(i.flags|=65536,i.lanes=g,i)}var PM=z.ReactCurrentOwner,En=!1;function rn(i,s,l,f){s.child=i===null?m2(s,null,l,f):ls(s,i.child,l,f)}function Q2(i,s,l,f,g){l=l.render;var y=s.ref;return ds(s,g),f=bp(i,s,l,f,y,g),l=xp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Br(i,s,g)):(pt&&l&&rp(s),s.flags|=1,rn(i,s,f,g),s.child)}function X2(i,s,l,f,g){if(i===null){var y=l.type;return typeof y=="function"&&!Xp(y)&&y.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(s.tag=15,s.type=y,J2(i,s,y,f,g)):(i=vc(l.type,null,f,s,s.mode,g),i.ref=s.ref,i.return=s,s.child=i)}if(y=i.child,(i.lanes&g)===0){var w=y.memoizedProps;if(l=l.compare,l=l!==null?l:Ra,l(w,f)&&i.ref===s.ref)return Br(i,s,g)}return s.flags|=1,i=Ti(y,f),i.ref=s.ref,i.return=s,s.child=i}function J2(i,s,l,f,g){if(i!==null){var y=i.memoizedProps;if(Ra(y,f)&&i.ref===s.ref)if(En=!1,s.pendingProps=f=y,(i.lanes&g)!==0)(i.flags&131072)!==0&&(En=!0);else return s.lanes=i.lanes,Br(i,s,g)}return Op(i,s,l,f,g)}function Z2(i,s,l){var f=s.pendingProps,g=f.children,y=i!==null?i.memoizedState:null;if(f.mode==="hidden")if((s.mode&1)===0)s.memoizedState={baseLanes:0,cachePool:null,transitions:null},at(ms,Nn),Nn|=l;else{if((l&1073741824)===0)return i=y!==null?y.baseLanes|l:l,s.lanes=s.childLanes=1073741824,s.memoizedState={baseLanes:i,cachePool:null,transitions:null},s.updateQueue=null,at(ms,Nn),Nn|=i,null;s.memoizedState={baseLanes:0,cachePool:null,transitions:null},f=y!==null?y.baseLanes:l,at(ms,Nn),Nn|=f}else y!==null?(f=y.baseLanes|l,s.memoizedState=null):f=l,at(ms,Nn),Nn|=f;return rn(i,s,g,l),s.child}function ex(i,s){var l=s.ref;(i===null&&l!==null||i!==null&&i.ref!==l)&&(s.flags|=512,s.flags|=2097152)}function Op(i,s,l,f,g){var y=gn(l)?Ki:Qt.current;return y=os(s,y),ds(s,g),l=bp(i,s,l,f,y,g),f=xp(),i!==null&&!En?(s.updateQueue=i.updateQueue,s.flags&=-2053,i.lanes&=~g,Br(i,s,g)):(pt&&f&&rp(s),s.flags|=1,rn(i,s,l,g),s.child)}function tx(i,s,l,f,g){if(gn(l)){var y=!0;Ql(s)}else y=!1;if(ds(s,g),s.stateNode===null)pc(i,s),$2(s,l,f),Cp(s,l,f,g),f=!0;else if(i===null){var w=s.stateNode,R=s.memoizedProps;w.props=R;var F=w.context,K=l.contextType;typeof K=="object"&&K!==null?K=Un(K):(K=gn(l)?Ki:Qt.current,K=os(s,K));var ce=l.getDerivedStateFromProps,pe=typeof ce=="function"||typeof w.getSnapshotBeforeUpdate=="function";pe||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(R!==f||F!==K)&&V2(s,w,f,K),fi=!1;var ue=s.memoizedState;w.state=ue,oc(s,f,w,g),F=s.memoizedState,R!==f||ue!==F||mn.current||fi?(typeof ce=="function"&&(Ap(s,l,ce,f),F=s.memoizedState),(R=fi||j2(s,l,R,f,ue,F,K))?(pe||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=K,f=R):(typeof w.componentDidMount=="function"&&(s.flags|=4194308),f=!1)}else{w=s.stateNode,E2(i,s),R=s.memoizedProps,K=s.type===s.elementType?R:tr(s.type,R),w.props=K,pe=s.pendingProps,ue=w.context,F=l.contextType,typeof F=="object"&&F!==null?F=Un(F):(F=gn(l)?Ki:Qt.current,F=os(s,F));var we=l.getDerivedStateFromProps;(ce=typeof we=="function"||typeof w.getSnapshotBeforeUpdate=="function")||typeof w.UNSAFE_componentWillReceiveProps!="function"&&typeof w.componentWillReceiveProps!="function"||(R!==pe||ue!==F)&&V2(s,w,f,F),fi=!1,ue=s.memoizedState,w.state=ue,oc(s,f,w,g);var ve=s.memoizedState;R!==pe||ue!==ve||mn.current||fi?(typeof we=="function"&&(Ap(s,l,we,f),ve=s.memoizedState),(K=fi||j2(s,l,K,f,ue,ve,F)||!1)?(ce||typeof w.UNSAFE_componentWillUpdate!="function"&&typeof w.componentWillUpdate!="function"||(typeof w.componentWillUpdate=="function"&&w.componentWillUpdate(f,ve,F),typeof w.UNSAFE_componentWillUpdate=="function"&&w.UNSAFE_componentWillUpdate(f,ve,F)),typeof w.componentDidUpdate=="function"&&(s.flags|=4),typeof w.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof w.componentDidUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),s.memoizedProps=f,s.memoizedState=ve),w.props=f,w.state=ve,w.context=F,f=K):(typeof w.componentDidUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=4),typeof w.getSnapshotBeforeUpdate!="function"||R===i.memoizedProps&&ue===i.memoizedState||(s.flags|=1024),f=!1)}return Ip(i,s,l,f,y,g)}function Ip(i,s,l,f,g,y){ex(i,s);var w=(s.flags&128)!==0;if(!f&&!w)return g&&s2(s,l,!1),Br(i,s,y);f=s.stateNode,PM.current=s;var R=w&&typeof l.getDerivedStateFromError!="function"?null:f.render();return s.flags|=1,i!==null&&w?(s.child=ls(s,i.child,null,y),s.child=ls(s,null,R,y)):rn(i,s,R,y),s.memoizedState=f.state,g&&s2(s,l,!0),s.child}function nx(i){var s=i.stateNode;s.pendingContext?i2(i,s.pendingContext,s.pendingContext!==s.context):s.context&&i2(i,s.context,!1),pp(i,s.containerInfo)}function rx(i,s,l,f,g){return us(),ap(g),s.flags|=256,rn(i,s,l,f),s.child}var Rp={dehydrated:null,treeContext:null,retryLane:0};function Pp(i){return{baseLanes:i,cachePool:null,transitions:null}}function ix(i,s,l){var f=s.pendingProps,g=mt.current,y=!1,w=(s.flags&128)!==0,R;if((R=w)||(R=i!==null&&i.memoizedState===null?!1:(g&2)!==0),R?(y=!0,s.flags&=-129):(i===null||i.memoizedState!==null)&&(g|=1),at(mt,g&1),i===null)return sp(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,y?(f=s.mode,y=s.child,w={mode:"hidden",children:w},(f&1)===0&&y!==null?(y.childLanes=0,y.pendingProps=w):y=Ac(w,f,0,null),i=oo(i,f,l,null),y.return=s,i.return=s,y.sibling=i,s.child=y,s.child.memoizedState=Pp(l),s.memoizedState=Rp,i):Lp(s,w));if(g=i.memoizedState,g!==null&&(R=g.dehydrated,R!==null))return LM(i,s,w,f,R,g,l);if(y){y=f.fallback,w=s.mode,g=i.child,R=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),R!==null?y=Ti(R,y):(y=oo(y,w,l,null),y.flags|=2),y.return=s,f.return=s,f.sibling=y,s.child=f,f=y,y=s.child,w=i.child.memoizedState,w=w===null?Pp(l):{baseLanes:w.baseLanes|l,cachePool:null,transitions:w.transitions},y.memoizedState=w,y.childLanes=i.childLanes&~l,s.memoizedState=Rp,f}return y=i.child,i=y.sibling,f=Ti(y,{mode:"visible",children:f.children}),(s.mode&1)===0&&(f.lanes=l),f.return=s,f.sibling=null,i!==null&&(l=s.deletions,l===null?(s.deletions=[i],s.flags|=16):l.push(i)),s.child=f,s.memoizedState=null,f}function Lp(i,s){return s=Ac({mode:"visible",children:s},i.mode,0,null),s.return=i,i.child=s}function hc(i,s,l,f){return f!==null&&ap(f),ls(s,i.child,null,l),i=Lp(s,s.pendingProps.children),i.flags|=2,s.memoizedState=null,i}function LM(i,s,l,f,g,y,w){if(l)return s.flags&256?(s.flags&=-257,f=kp(Error(n(422))),hc(i,s,w,f)):s.memoizedState!==null?(s.child=i.child,s.flags|=128,null):(y=f.fallback,g=s.mode,f=Ac({mode:"visible",children:f.children},g,0,null),y=oo(y,g,w,null),y.flags|=2,f.return=s,y.return=s,f.sibling=y,s.child=f,(s.mode&1)!==0&&ls(s,i.child,null,w),s.child.memoizedState=Pp(w),s.memoizedState=Rp,y);if((s.mode&1)===0)return hc(i,s,w,null);if(g.data==="$!"){if(f=g.nextSibling&&g.nextSibling.dataset,f)var R=f.dgst;return f=R,y=Error(n(419)),f=kp(y,f,void 0),hc(i,s,w,f)}if(R=(w&i.childLanes)!==0,En||R){if(f=Ut,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!==y.retryLane&&(y.retryLane=g,Mr(i,g),ir(f,i,g,-1))}return Qp(),f=kp(Error(n(421))),hc(i,s,w,f)}return g.data==="$?"?(s.flags|=128,s.child=i.child,s=WM.bind(null,i),g._reactRetry=s,null):(i=y.treeContext,kn=ui(g.nextSibling),Cn=s,pt=!0,er=null,i!==null&&(Fn[Bn++]=Lr,Fn[Bn++]=Dr,Fn[Bn++]=Qi,Lr=i.id,Dr=i.overflow,Qi=s),s=Lp(s,f.children),s.flags|=4096,s)}function ox(i,s,l){i.lanes|=s;var f=i.alternate;f!==null&&(f.lanes|=s),dp(i.return,s,l)}function Dp(i,s,l,f,g){var y=i.memoizedState;y===null?i.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:f,tail:l,tailMode:g}:(y.isBackwards=s,y.rendering=null,y.renderingStartTime=0,y.last=f,y.tail=l,y.tailMode=g)}function sx(i,s,l){var f=s.pendingProps,g=f.revealOrder,y=f.tail;if(rn(i,s,f.children,l),f=mt.current,(f&2)!==0)f=f&1|2,s.flags|=128;else{if(i!==null&&(i.flags&128)!==0)e:for(i=s.child;i!==null;){if(i.tag===13)i.memoizedState!==null&&ox(i,l,s);else if(i.tag===19)ox(i,l,s);else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===s)break e;for(;i.sibling===null;){if(i.return===null||i.return===s)break e;i=i.return}i.sibling.return=i.return,i=i.sibling}f&=1}if(at(mt,f),(s.mode&1)===0)s.memoizedState=null;else switch(g){case"forwards":for(l=s.child,g=null;l!==null;)i=l.alternate,i!==null&&sc(i)===null&&(g=l),l=l.sibling;l=g,l===null?(g=s.child,s.child=null):(g=l.sibling,l.sibling=null),Dp(s,!1,g,l,y);break;case"backwards":for(l=null,g=s.child,s.child=null;g!==null;){if(i=g.alternate,i!==null&&sc(i)===null){s.child=g;break}i=g.sibling,g.sibling=l,l=g,g=i}Dp(s,!0,l,null,y);break;case"together":Dp(s,!1,null,null,void 0);break;default:s.memoizedState=null}return s.child}function pc(i,s){(s.mode&1)===0&&i!==null&&(i.alternate=null,s.alternate=null,s.flags|=2)}function Br(i,s,l){if(i!==null&&(s.dependencies=i.dependencies),to|=s.lanes,(l&s.childLanes)===0)return null;if(i!==null&&s.child!==i.child)throw Error(n(153));if(s.child!==null){for(i=s.child,l=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 DM(i,s,l){switch(s.tag){case 3:nx(s),us();break;case 5:b2(s);break;case 1:gn(s.type)&&Ql(s);break;case 4:pp(s,s.stateNode.containerInfo);break;case 10:var f=s.type._context,g=s.memoizedProps.value;at(nc,f._currentValue),f._currentValue=g;break;case 13:if(f=s.memoizedState,f!==null)return f.dehydrated!==null?(at(mt,mt.current&1),s.flags|=128,null):(l&s.child.childLanes)!==0?ix(i,s,l):(at(mt,mt.current&1),i=Br(i,s,l),i!==null?i.sibling:null);at(mt,mt.current&1);break;case 19:if(f=(l&s.childLanes)!==0,(i.flags&128)!==0){if(f)return sx(i,s,l);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),at(mt,mt.current),f)break;return null;case 22:case 23:return s.lanes=0,Z2(i,s,l)}return Br(i,s,l)}var ax,Mp,ux,lx;ax=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}},Mp=function(){},ux=function(i,s,l,f){var g=i.memoizedProps;if(g!==f){i=s.stateNode,Zi(xr.current);var y=null;switch(l){case"input":g=Xn(i,g),f=Xn(i,f),y=[];break;case"select":g=v({},g,{value:void 0}),f=v({},f,{value:void 0}),y=[];break;case"textarea":g=ga(i,g),f=ga(i,f),y=[];break;default:typeof g.onClick!="function"&&typeof f.onClick=="function"&&(i.onclick=Wl)}jt(l,f);var w;l=null;for(K in g)if(!f.hasOwnProperty(K)&&g.hasOwnProperty(K)&&g[K]!=null)if(K==="style"){var R=g[K];for(w in R)R.hasOwnProperty(w)&&(l||(l={}),l[w]="")}else K!=="dangerouslySetInnerHTML"&&K!=="children"&&K!=="suppressContentEditableWarning"&&K!=="suppressHydrationWarning"&&K!=="autoFocus"&&(o.hasOwnProperty(K)?y||(y=[]):(y=y||[]).push(K,null));for(K in f){var F=f[K];if(R=g!=null?g[K]:void 0,f.hasOwnProperty(K)&&F!==R&&(F!=null||R!=null))if(K==="style")if(R){for(w in R)!R.hasOwnProperty(w)||F&&F.hasOwnProperty(w)||(l||(l={}),l[w]="");for(w in F)F.hasOwnProperty(w)&&R[w]!==F[w]&&(l||(l={}),l[w]=F[w])}else l||(y||(y=[]),y.push(K,l)),l=F;else K==="dangerouslySetInnerHTML"?(F=F?F.__html:void 0,R=R?R.__html:void 0,F!=null&&R!==F&&(y=y||[]).push(K,F)):K==="children"?typeof F!="string"&&typeof F!="number"||(y=y||[]).push(K,""+F):K!=="suppressContentEditableWarning"&&K!=="suppressHydrationWarning"&&(o.hasOwnProperty(K)?(F!=null&&K==="onScroll"&<("scroll",i),y||R===F||(y=[])):(y=y||[]).push(K,F))}l&&(y=y||[]).push("style",l);var K=y;(s.updateQueue=K)&&(s.flags|=4)}},lx=function(i,s,l,f){l!==f&&(s.flags|=4)};function Wa(i,s){if(!pt)switch(i.tailMode){case"hidden":s=i.tail;for(var l=null;s!==null;)s.alternate!==null&&(l=s),s=s.sibling;l===null?i.tail=null:l.sibling=null;break;case"collapsed":l=i.tail;for(var f=null;l!==null;)l.alternate!==null&&(f=l),l=l.sibling;f===null?s||i.tail===null?i.tail=null:i.tail.sibling=null:f.sibling=null}}function Jt(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 MM(i,s,l){var f=s.pendingProps;switch(ip(s),s.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Jt(s),null;case 1:return gn(s.type)&&Kl(),Jt(s),null;case 3:return f=s.stateNode,fs(),ct(mn),ct(Qt),Ep(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(i===null||i.child===null)&&(ec(s)?s.flags|=4:i===null||i.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,er!==null&&(Wp(er),er=null))),Mp(i,s),Jt(s),null;case 5:mp(s);var g=Zi(ja.current);if(l=s.type,i!==null&&s.stateNode!=null)ux(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 Jt(s),null}if(i=Zi(xr.current),ec(s)){f=s.stateNode,l=s.type;var y=s.memoizedProps;switch(f[br]=s,f[Fa]=y,i=(s.mode&1)!==0,l){case"dialog":lt("cancel",f),lt("close",f);break;case"iframe":case"object":case"embed":lt("load",f);break;case"video":case"audio":for(g=0;g<La.length;g++)lt(La[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":pa(f,y),lt("invalid",f);break;case"select":f._wrapperState={wasMultiple:!!y.multiple},lt("invalid",f);break;case"textarea":_l(f,y),lt("invalid",f)}jt(l,y),g=null;for(var w in y)if(y.hasOwnProperty(w)){var R=y[w];w==="children"?typeof R=="string"?f.textContent!==R&&(y.suppressHydrationWarning!==!0&&Yl(f.textContent,R,i),g=["children",R]):typeof R=="number"&&f.textContent!==""+R&&(y.suppressHydrationWarning!==!0&&Yl(f.textContent,R,i),g=["children",""+R]):o.hasOwnProperty(w)&&R!=null&&w==="onScroll"&<("scroll",f)}switch(l){case"input":pn(f),wl(f,y,!0);break;case"textarea":pn(f),vl(f);break;case"select":case"option":break;default:typeof y.onClick=="function"&&(f.onclick=Wl)}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=ne(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[br]=s,i[Fa]=f,ax(i,s,!1,!1),s.stateNode=i;e:{switch(w=yr(l,f),l){case"dialog":lt("cancel",i),lt("close",i),g=f;break;case"iframe":case"object":case"embed":lt("load",i),g=f;break;case"video":case"audio":for(g=0;g<La.length;g++)lt(La[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":pa(i,f),g=Xn(i,f),lt("invalid",i);break;case"option":g=f;break;case"select":i._wrapperState={wasMultiple:!!f.multiple},g=v({},f,{value:void 0}),lt("invalid",i);break;case"textarea":_l(i,f),g=ga(i,f),lt("invalid",i);break;default:g=f}jt(l,g),R=g;for(y in R)if(R.hasOwnProperty(y)){var F=R[y];y==="style"?ti(i,F):y==="dangerouslySetInnerHTML"?(F=F?F.__html:void 0,F!=null&&Ye(i,F)):y==="children"?typeof F=="string"?(l!=="textarea"||F!=="")&&Xe(i,F):typeof F=="number"&&Xe(i,""+F):y!=="suppressContentEditableWarning"&&y!=="suppressHydrationWarning"&&y!=="autoFocus"&&(o.hasOwnProperty(y)?F!=null&&y==="onScroll"&<("scroll",i):F!=null&&I(i,y,F,w))}switch(l){case"input":pn(i),wl(i,f,!1);break;case"textarea":pn(i),vl(i);break;case"option":f.value!=null&&i.setAttribute("value",""+Se(f.value));break;case"select":i.multiple=!!f.multiple,y=f.value,y!=null?ei(i,!!f.multiple,y,!1):f.defaultValue!=null&&ei(i,!!f.multiple,f.defaultValue,!0);break;default:typeof g.onClick=="function"&&(i.onclick=Wl)}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 Jt(s),null;case 6:if(i&&s.stateNode!=null)lx(i,s,i.memoizedProps,f);else{if(typeof f!="string"&&s.stateNode===null)throw Error(n(166));if(l=Zi(ja.current),Zi(xr.current),ec(s)){if(f=s.stateNode,l=s.memoizedProps,f[br]=s,(y=f.nodeValue!==l)&&(i=Cn,i!==null))switch(i.tag){case 3:Yl(f.nodeValue,l,(i.mode&1)!==0);break;case 5:i.memoizedProps.suppressHydrationWarning!==!0&&Yl(f.nodeValue,l,(i.mode&1)!==0)}y&&(s.flags|=4)}else f=(l.nodeType===9?l:l.ownerDocument).createTextNode(f),f[br]=s,s.stateNode=f}return Jt(s),null;case 13:if(ct(mt),f=s.memoizedState,i===null||i.memoizedState!==null&&i.memoizedState.dehydrated!==null){if(pt&&kn!==null&&(s.mode&1)!==0&&(s.flags&128)===0)f2(),us(),s.flags|=98560,y=!1;else if(y=ec(s),f!==null&&f.dehydrated!==null){if(i===null){if(!y)throw Error(n(318));if(y=s.memoizedState,y=y!==null?y.dehydrated:null,!y)throw Error(n(317));y[br]=s}else us(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;Jt(s),y=!1}else er!==null&&(Wp(er),er=null),y=!0;if(!y)return s.flags&65536?s:null}return(s.flags&128)!==0?(s.lanes=l,s):(f=f!==null,f!==(i!==null&&i.memoizedState!==null)&&f&&(s.child.flags|=8192,(s.mode&1)!==0&&(i===null||(mt.current&1)!==0?Rt===0&&(Rt=3):Qp())),s.updateQueue!==null&&(s.flags|=4),Jt(s),null);case 4:return fs(),Mp(i,s),i===null&&Da(s.stateNode.containerInfo),Jt(s),null;case 10:return cp(s.type._context),Jt(s),null;case 17:return gn(s.type)&&Kl(),Jt(s),null;case 19:if(ct(mt),y=s.memoizedState,y===null)return Jt(s),null;if(f=(s.flags&128)!==0,w=y.rendering,w===null)if(f)Wa(y,!1);else{if(Rt!==0||i!==null&&(i.flags&128)!==0)for(i=s.child;i!==null;){if(w=sc(i),w!==null){for(s.flags|=128,Wa(y,!1),f=w.updateQueue,f!==null&&(s.updateQueue=f,s.flags|=4),s.subtreeFlags=0,f=l,l=s.child;l!==null;)y=l,i=f,y.flags&=14680066,w=y.alternate,w===null?(y.childLanes=0,y.lanes=i,y.child=null,y.subtreeFlags=0,y.memoizedProps=null,y.memoizedState=null,y.updateQueue=null,y.dependencies=null,y.stateNode=null):(y.childLanes=w.childLanes,y.lanes=w.lanes,y.child=w.child,y.subtreeFlags=0,y.deletions=null,y.memoizedProps=w.memoizedProps,y.memoizedState=w.memoizedState,y.updateQueue=w.updateQueue,y.type=w.type,i=w.dependencies,y.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext}),l=l.sibling;return at(mt,mt.current&1|2),s.child}i=i.sibling}y.tail!==null&&wt()>gs&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304)}else{if(!f)if(i=sc(w),i!==null){if(s.flags|=128,f=!0,l=i.updateQueue,l!==null&&(s.updateQueue=l,s.flags|=4),Wa(y,!0),y.tail===null&&y.tailMode==="hidden"&&!w.alternate&&!pt)return Jt(s),null}else 2*wt()-y.renderingStartTime>gs&&l!==1073741824&&(s.flags|=128,f=!0,Wa(y,!1),s.lanes=4194304);y.isBackwards?(w.sibling=s.child,s.child=w):(l=y.last,l!==null?l.sibling=w:s.child=w,y.last=w)}return y.tail!==null?(s=y.tail,y.rendering=s,y.tail=s.sibling,y.renderingStartTime=wt(),s.sibling=null,l=mt.current,at(mt,f?l&1|2:l&1),s):(Jt(s),null);case 22:case 23:return Kp(),f=s.memoizedState!==null,i!==null&&i.memoizedState!==null!==f&&(s.flags|=8192),f&&(s.mode&1)!==0?(Nn&1073741824)!==0&&(Jt(s),s.subtreeFlags&6&&(s.flags|=8192)):Jt(s),null;case 24:return null;case 25:return null}throw Error(n(156,s.tag))}function FM(i,s){switch(ip(s),s.tag){case 1:return gn(s.type)&&Kl(),i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 3:return fs(),ct(mn),ct(Qt),Ep(),i=s.flags,(i&65536)!==0&&(i&128)===0?(s.flags=i&-65537|128,s):null;case 5:return mp(s),null;case 13:if(ct(mt),i=s.memoizedState,i!==null&&i.dehydrated!==null){if(s.alternate===null)throw Error(n(340));us()}return i=s.flags,i&65536?(s.flags=i&-65537|128,s):null;case 19:return ct(mt),null;case 4:return fs(),null;case 10:return cp(s.type._context),null;case 22:case 23:return Kp(),null;case 24:return null;default:return null}}var mc=!1,Zt=!1,BM=typeof WeakSet=="function"?WeakSet:Set,_e=null;function ps(i,s){var l=i.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(f){yt(i,s,f)}else l.current=null}function Fp(i,s,l){try{l()}catch(f){yt(i,s,f)}}var cx=!1;function UM(i,s){if(Kh=Dl,i=jb(),zh(i)){if("selectionStart"in i)var l={start:i.selectionStart,end:i.selectionEnd};else e:{l=(l=i.ownerDocument)&&l.defaultView||window;var f=l.getSelection&&l.getSelection();if(f&&f.rangeCount!==0){l=f.anchorNode;var g=f.anchorOffset,y=f.focusNode;f=f.focusOffset;try{l.nodeType,y.nodeType}catch(ye){l=null;break e}var w=0,R=-1,F=-1,K=0,ce=0,pe=i,ue=null;t:for(;;){for(var we;pe!==l||g!==0&&pe.nodeType!==3||(R=w+g),pe!==y||f!==0&&pe.nodeType!==3||(F=w+f),pe.nodeType===3&&(w+=pe.nodeValue.length),(we=pe.firstChild)!==null;)ue=pe,pe=we;for(;;){if(pe===i)break t;if(ue===l&&++K===g&&(R=w),ue===y&&++ce===f&&(F=w),(we=pe.nextSibling)!==null)break;pe=ue,ue=pe.parentNode}pe=we}l=R===-1||F===-1?null:{start:R,end:F}}else l=null}l=l||{start:0,end:0}}else l=null;for(Qh={focusedElem:i,selectionRange:l},Dl=!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 ve=s.alternate;if((s.flags&1024)!==0)switch(s.tag){case 0:case 11:case 15:break;case 1:if(ve!==null){var Ce=ve.memoizedProps,_t=ve.memoizedState,$=s.stateNode,H=$.getSnapshotBeforeUpdate(s.elementType===s.type?Ce:tr(s.type,Ce),_t);$.__reactInternalSnapshotBeforeUpdate=H}break;case 3:var q=s.stateNode.containerInfo;q.nodeType===1?q.textContent="":q.nodeType===9&&q.documentElement&&q.removeChild(q.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(ye){yt(s,s.return,ye)}if(i=s.sibling,i!==null){i.return=s.return,_e=i;break}_e=s.return}return ve=cx,cx=!1,ve}function Ga(i,s,l){var f=s.updateQueue;if(f=f!==null?f.lastEffect:null,f!==null){var g=f=f.next;do{if((g.tag&i)===i){var y=g.destroy;g.destroy=void 0,y!==void 0&&Fp(s,l,y)}g=g.next}while(g!==f)}}function gc(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 Bp(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 dx(i){var s=i.alternate;s!==null&&(i.alternate=null,dx(s)),i.child=null,i.deletions=null,i.sibling=null,i.tag===5&&(s=i.stateNode,s!==null&&(delete s[br],delete s[Fa],delete s[ep],delete s[xM],delete s[wM])),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 fx(i){return i.tag===5||i.tag===3||i.tag===4}function hx(i){e:for(;;){for(;i.sibling===null;){if(i.return===null||fx(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 Up(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=Wl));else if(f!==4&&(i=i.child,i!==null))for(Up(i,s,l),i=i.sibling;i!==null;)Up(i,s,l),i=i.sibling}function Hp(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(Hp(i,s,l),i=i.sibling;i!==null;)Hp(i,s,l),i=i.sibling}var $t=null,nr=!1;function pi(i,s,l){for(l=l.child;l!==null;)px(i,s,l),l=l.sibling}function px(i,s,l){if(Tr&&typeof Tr.onCommitFiberUnmount=="function")try{Tr.onCommitFiberUnmount(Nl,l)}catch(R){}switch(l.tag){case 5:Zt||ps(l,s);case 6:var f=$t,g=nr;$t=null,pi(i,s,l),$t=f,nr=g,$t!==null&&(nr?(i=$t,l=l.stateNode,i.nodeType===8?i.parentNode.removeChild(l):i.removeChild(l)):$t.removeChild(l.stateNode));break;case 18:$t!==null&&(nr?(i=$t,l=l.stateNode,i.nodeType===8?Zh(i.parentNode,l):i.nodeType===1&&Zh(i,l),Aa(i)):Zh($t,l.stateNode));break;case 4:f=$t,g=nr,$t=l.stateNode.containerInfo,nr=!0,pi(i,s,l),$t=f,nr=g;break;case 0:case 11:case 14:case 15:if(!Zt&&(f=l.updateQueue,f!==null&&(f=f.lastEffect,f!==null))){g=f=f.next;do{var y=g,w=y.destroy;y=y.tag,w!==void 0&&((y&2)!==0||(y&4)!==0)&&Fp(l,s,w),g=g.next}while(g!==f)}pi(i,s,l);break;case 1:if(!Zt&&(ps(l,s),f=l.stateNode,typeof f.componentWillUnmount=="function"))try{f.props=l.memoizedProps,f.state=l.memoizedState,f.componentWillUnmount()}catch(R){yt(l,s,R)}pi(i,s,l);break;case 21:pi(i,s,l);break;case 22:l.mode&1?(Zt=(f=Zt)||l.memoizedState!==null,pi(i,s,l),Zt=f):pi(i,s,l);break;default:pi(i,s,l)}}function mx(i){var s=i.updateQueue;if(s!==null){i.updateQueue=null;var l=i.stateNode;l===null&&(l=i.stateNode=new BM),s.forEach(function(f){var g=GM.bind(null,i,f);l.has(f)||(l.add(f),f.then(g,g))})}}function rr(i,s){var l=s.deletions;if(l!==null)for(var f=0;f<l.length;f++){var g=l[f];try{var y=i,w=s,R=w;e:for(;R!==null;){switch(R.tag){case 5:$t=R.stateNode,nr=!1;break e;case 3:$t=R.stateNode.containerInfo,nr=!0;break e;case 4:$t=R.stateNode.containerInfo,nr=!0;break e}R=R.return}if($t===null)throw Error(n(160));px(y,w,g),$t=null,nr=!1;var F=g.alternate;F!==null&&(F.return=null),g.return=null}catch(K){yt(g,s,K)}}if(s.subtreeFlags&12854)for(s=s.child;s!==null;)gx(s,i),s=s.sibling}function gx(i,s){var l=i.alternate,f=i.flags;switch(i.tag){case 0:case 11:case 14:case 15:if(rr(s,i),_r(i),f&4){try{Ga(3,i,i.return),gc(3,i)}catch(Ce){yt(i,i.return,Ce)}try{Ga(5,i,i.return)}catch(Ce){yt(i,i.return,Ce)}}break;case 1:rr(s,i),_r(i),f&512&&l!==null&&ps(l,l.return);break;case 5:if(rr(s,i),_r(i),f&512&&l!==null&&ps(l,l.return),i.flags&32){var g=i.stateNode;try{Xe(g,"")}catch(Ce){yt(i,i.return,Ce)}}if(f&4&&(g=i.stateNode,g!=null)){var y=i.memoizedProps,w=l!==null?l.memoizedProps:y,R=i.type,F=i.updateQueue;if(i.updateQueue=null,F!==null)try{R==="input"&&y.type==="radio"&&y.name!=null&&ma(g,y),yr(R,w);var K=yr(R,y);for(w=0;w<F.length;w+=2){var ce=F[w],pe=F[w+1];ce==="style"?ti(g,pe):ce==="dangerouslySetInnerHTML"?Ye(g,pe):ce==="children"?Xe(g,pe):I(g,ce,pe,K)}switch(R){case"input":Yo(g,y);break;case"textarea":Sl(g,y);break;case"select":var ue=g._wrapperState.wasMultiple;g._wrapperState.wasMultiple=!!y.multiple;var we=y.value;we!=null?ei(g,!!y.multiple,we,!1):ue!==!!y.multiple&&(y.defaultValue!=null?ei(g,!!y.multiple,y.defaultValue,!0):ei(g,!!y.multiple,y.multiple?[]:"",!1))}g[Fa]=y}catch(Ce){yt(i,i.return,Ce)}}break;case 6:if(rr(s,i),_r(i),f&4){if(i.stateNode===null)throw Error(n(162));g=i.stateNode,y=i.memoizedProps;try{g.nodeValue=y}catch(Ce){yt(i,i.return,Ce)}}break;case 3:if(rr(s,i),_r(i),f&4&&l!==null&&l.memoizedState.isDehydrated)try{Aa(s.containerInfo)}catch(Ce){yt(i,i.return,Ce)}break;case 4:rr(s,i),_r(i);break;case 13:rr(s,i),_r(i),g=i.child,g.flags&8192&&(y=g.memoizedState!==null,g.stateNode.isHidden=y,!y||g.alternate!==null&&g.alternate.memoizedState!==null||($p=wt())),f&4&&mx(i);break;case 22:if(ce=l!==null&&l.memoizedState!==null,i.mode&1?(Zt=(K=Zt)||ce,rr(s,i),Zt=K):rr(s,i),_r(i),f&8192){if(K=i.memoizedState!==null,(i.stateNode.isHidden=K)&&!ce&&(i.mode&1)!==0)for(_e=i,ce=i.child;ce!==null;){for(pe=_e=ce;_e!==null;){switch(ue=_e,we=ue.child,ue.tag){case 0:case 11:case 14:case 15:Ga(4,ue,ue.return);break;case 1:ps(ue,ue.return);var ve=ue.stateNode;if(typeof ve.componentWillUnmount=="function"){f=ue,l=ue.return;try{s=f,ve.props=s.memoizedProps,ve.state=s.memoizedState,ve.componentWillUnmount()}catch(Ce){yt(f,l,Ce)}}break;case 5:ps(ue,ue.return);break;case 22:if(ue.memoizedState!==null){Tx(pe);continue}}we!==null?(we.return=ue,_e=we):Tx(pe)}ce=ce.sibling}e:for(ce=null,pe=i;;){if(pe.tag===5){if(ce===null){ce=pe;try{g=pe.stateNode,K?(y=g.style,typeof y.setProperty=="function"?y.setProperty("display","none","important"):y.display="none"):(R=pe.stateNode,F=pe.memoizedProps.style,w=F!=null&&F.hasOwnProperty("display")?F.display:null,R.style.display=Mn("display",w))}catch(Ce){yt(i,i.return,Ce)}}}else if(pe.tag===6){if(ce===null)try{pe.stateNode.nodeValue=K?"":pe.memoizedProps}catch(Ce){yt(i,i.return,Ce)}}else if((pe.tag!==22&&pe.tag!==23||pe.memoizedState===null||pe===i)&&pe.child!==null){pe.child.return=pe,pe=pe.child;continue}if(pe===i)break e;for(;pe.sibling===null;){if(pe.return===null||pe.return===i)break e;ce===pe&&(ce=null),pe=pe.return}ce===pe&&(ce=null),pe.sibling.return=pe.return,pe=pe.sibling}}break;case 19:rr(s,i),_r(i),f&4&&mx(i);break;case 21:break;default:rr(s,i),_r(i)}}function _r(i){var s=i.flags;if(s&2){try{e:{for(var l=i.return;l!==null;){if(fx(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 y=hx(i);Hp(i,y,g);break;case 3:case 4:var w=f.stateNode.containerInfo,R=hx(i);Up(i,R,w);break;default:throw Error(n(161))}}catch(F){yt(i,i.return,F)}i.flags&=-3}s&4096&&(i.flags&=-4097)}function HM(i,s,l){_e=i,Ex(i)}function Ex(i,s,l){for(var f=(i.mode&1)!==0;_e!==null;){var g=_e,y=g.child;if(g.tag===22&&f){var w=g.memoizedState!==null||mc;if(!w){var R=g.alternate,F=R!==null&&R.memoizedState!==null||Zt;R=mc;var K=Zt;if(mc=w,(Zt=F)&&!K)for(_e=g;_e!==null;)w=_e,F=w.child,w.tag===22&&w.memoizedState!==null?bx(g):F!==null?(F.return=w,_e=F):bx(g);for(;y!==null;)_e=y,Ex(y),y=y.sibling;_e=g,mc=R,Zt=K}yx(i)}else(g.subtreeFlags&8772)!==0&&y!==null?(y.return=g,_e=y):yx(i)}}function yx(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:Zt||gc(5,s);break;case 1:var f=s.stateNode;if(s.flags&4&&!Zt)if(l===null)f.componentDidMount();else{var g=s.elementType===s.type?l.memoizedProps:tr(s.type,l.memoizedProps);f.componentDidUpdate(g,l.memoizedState,f.__reactInternalSnapshotBeforeUpdate)}var y=s.updateQueue;y!==null&&T2(s,y,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}T2(s,w,l)}break;case 5:var R=s.stateNode;if(l===null&&s.flags&4){l=R;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 K=s.alternate;if(K!==null){var ce=K.memoizedState;if(ce!==null){var pe=ce.dehydrated;pe!==null&&Aa(pe)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Zt||s.flags&512&&Bp(s)}catch(ue){yt(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 Tx(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 bx(i){for(;_e!==null;){var s=_e;try{switch(s.tag){case 0:case 11:case 15:var l=s.return;try{gc(4,s)}catch(F){yt(s,l,F)}break;case 1:var f=s.stateNode;if(typeof f.componentDidMount=="function"){var g=s.return;try{f.componentDidMount()}catch(F){yt(s,g,F)}}var y=s.return;try{Bp(s)}catch(F){yt(s,y,F)}break;case 5:var w=s.return;try{Bp(s)}catch(F){yt(s,w,F)}}}catch(F){yt(s,s.return,F)}if(s===i){_e=null;break}var R=s.sibling;if(R!==null){R.return=s.return,_e=R;break}_e=s.return}}var zM=Math.ceil,Ec=z.ReactCurrentDispatcher,zp=z.ReactCurrentOwner,zn=z.ReactCurrentBatchConfig,Je=0,Ut=null,Ct=null,Vt=0,Nn=0,ms=li(0),Rt=0,Ka=null,to=0,yc=0,jp=0,Qa=null,yn=null,$p=0,gs=1/0,Ur=null,Tc=!1,Vp=null,mi=null,bc=!1,gi=null,xc=0,Xa=0,qp=null,wc=-1,_c=0;function on(){return(Je&6)!==0?wt():wc!==-1?wc:wc=wt()}function Ei(i){return(i.mode&1)===0?1:(Je&2)!==0&&Vt!==0?Vt&-Vt:SM.transition!==null?(_c===0&&(_c=hb()),_c):(i=nt,i!==0||(i=window.event,i=i===void 0?16:wb(i.type)),i)}function ir(i,s,l,f){if(50<Xa)throw Xa=0,qp=null,Error(n(185));xa(i,l,f),((Je&2)===0||i!==Ut)&&(i===Ut&&((Je&2)===0&&(yc|=l),Rt===4&&yi(i,Vt)),Tn(i,f),l===1&&Je===0&&(s.mode&1)===0&&(gs=wt()+500,Xl&&di()))}function Tn(i,s){var l=i.callbackNode;S8(i,s);var f=Rl(i,i===Ut?Vt:0);if(f===0)l!==null&&cb(l),i.callbackNode=null,i.callbackPriority=0;else if(s=f&-f,i.callbackPriority!==s){if(l!=null&&cb(l),s===1)i.tag===0?_M(wx.bind(null,i)):a2(wx.bind(null,i)),TM(function(){(Je&6)===0&&di()}),l=null;else{switch(pb(f)){case 1:l=Sh;break;case 4:l=db;break;case 16:l=kl;break;case 536870912:l=fb;break;default:l=kl}l=Ox(l,xx.bind(null,i))}i.callbackPriority=s,i.callbackNode=l}}function xx(i,s){if(wc=-1,_c=0,(Je&6)!==0)throw Error(n(327));var l=i.callbackNode;if(Es()&&i.callbackNode!==l)return null;var f=Rl(i,i===Ut?Vt:0);if(f===0)return null;if((f&30)!==0||(f&i.expiredLanes)!==0||s)s=Sc(i,f);else{s=f;var g=Je;Je|=2;var y=Sx();(Ut!==i||Vt!==s)&&(Ur=null,gs=wt()+500,ro(i,s));do try{VM();break}catch(R){_x(i,R)}while(!0);lp(),Ec.current=y,Je=g,Ct!==null?s=0:(Ut=null,Vt=0,s=Rt)}if(s!==0){if(s===2&&(g=vh(i),g!==0&&(f=g,s=Yp(i,g))),s===1)throw l=Ka,ro(i,0),yi(i,f),Tn(i,wt()),l;if(s===6)yi(i,f);else{if(g=i.current.alternate,(f&30)===0&&!jM(g)&&(s=Sc(i,f),s===2&&(y=vh(i),y!==0&&(f=y,s=Yp(i,y))),s===1))throw l=Ka,ro(i,0),yi(i,f),Tn(i,wt()),l;switch(i.finishedWork=g,i.finishedLanes=f,s){case 0:case 1:throw Error(n(345));case 2:io(i,yn,Ur);break;case 3:if(yi(i,f),(f&130023424)===f&&(s=$p+500-wt(),10<s)){if(Rl(i,0)!==0)break;if(g=i.suspendedLanes,(g&f)!==f){on(),i.pingedLanes|=i.suspendedLanes&g;break}i.timeoutHandle=Jh(io.bind(null,i,yn,Ur),s);break}io(i,yn,Ur);break;case 4:if(yi(i,f),(f&4194240)===f)break;for(s=i.eventTimes,g=-1;0<f;){var w=31-Jn(f);y=1<<w,w=s[w],w>g&&(g=w),f&=~y}if(f=g,f=wt()-f,f=(120>f?120:480>f?480:1080>f?1080:1920>f?1920:3e3>f?3e3:4320>f?4320:1960*zM(f/1960))-f,10<f){i.timeoutHandle=Jh(io.bind(null,i,yn,Ur),f);break}io(i,yn,Ur);break;case 5:io(i,yn,Ur);break;default:throw Error(n(329))}}}return Tn(i,wt()),i.callbackNode===l?xx.bind(null,i):null}function Yp(i,s){var l=Qa;return i.current.memoizedState.isDehydrated&&(ro(i,s).flags|=256),i=Sc(i,s),i!==2&&(s=yn,yn=l,s!==null&&Wp(s)),i}function Wp(i){yn===null?yn=i:yn.push.apply(yn,i)}function jM(i){for(var s=i;;){if(s.flags&16384){var l=s.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var f=0;f<l.length;f++){var g=l[f],y=g.getSnapshot;g=g.value;try{if(!Zn(y(),g))return!1}catch(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 yi(i,s){for(s&=~jp,s&=~yc,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 wx(i){if((Je&6)!==0)throw Error(n(327));Es();var s=Rl(i,0);if((s&1)===0)return Tn(i,wt()),null;var l=Sc(i,s);if(i.tag!==0&&l===2){var f=vh(i);f!==0&&(s=f,l=Yp(i,f))}if(l===1)throw l=Ka,ro(i,0),yi(i,s),Tn(i,wt()),l;if(l===6)throw Error(n(345));return i.finishedWork=i.current.alternate,i.finishedLanes=s,io(i,yn,Ur),Tn(i,wt()),null}function Gp(i,s){var l=Je;Je|=1;try{return i(s)}finally{Je=l,Je===0&&(gs=wt()+500,Xl&&di())}}function no(i){gi!==null&&gi.tag===0&&(Je&6)===0&&Es();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&&di()}}function Kp(){Nn=ms.current,ct(ms)}function ro(i,s){i.finishedWork=null,i.finishedLanes=0;var l=i.timeoutHandle;if(l!==-1&&(i.timeoutHandle=-1,yM(l)),Ct!==null)for(l=Ct.return;l!==null;){var f=l;switch(ip(f),f.tag){case 1:f=f.type.childContextTypes,f!=null&&Kl();break;case 3:fs(),ct(mn),ct(Qt),Ep();break;case 5:mp(f);break;case 4:fs();break;case 13:ct(mt);break;case 19:ct(mt);break;case 10:cp(f.type._context);break;case 22:case 23:Kp()}l=l.return}if(Ut=i,Ct=i=Ti(i.current,null),Vt=Nn=s,Rt=0,Ka=null,jp=yc=to=0,yn=Qa=null,Ji!==null){for(s=0;s<Ji.length;s++)if(l=Ji[s],f=l.interleaved,f!==null){l.interleaved=null;var g=f.next,y=l.pending;if(y!==null){var w=y.next;y.next=g,f.next=w}l.pending=f}Ji=null}return i}function _x(i,s){do{var l=Ct;try{if(lp(),ac.current=dc,uc){for(var f=gt.memoizedState;f!==null;){var g=f.queue;g!==null&&(g.pending=null),f=f.next}uc=!1}if(eo=0,Bt=It=gt=null,$a=!1,Va=0,zp.current=null,l===null||l.return===null){Rt=1,Ka=s,Ct=null;break}e:{var y=i,w=l.return,R=l,F=s;if(s=Vt,R.flags|=32768,F!==null&&typeof F=="object"&&typeof F.then=="function"){var K=F,ce=R,pe=ce.tag;if((ce.mode&1)===0&&(pe===0||pe===11||pe===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=G2(w);if(we!==null){we.flags&=-257,K2(we,w,R,y,s),we.mode&1&&W2(y,K,s),s=we,F=K;var ve=s.updateQueue;if(ve===null){var Ce=new Set;Ce.add(F),s.updateQueue=Ce}else ve.add(F);break e}else{if((s&1)===0){W2(y,K,s),Qp();break e}F=Error(n(426))}}else if(pt&&R.mode&1){var _t=G2(w);if(_t!==null){(_t.flags&65536)===0&&(_t.flags|=256),K2(_t,w,R,y,s),ap(hs(F,R));break e}}y=F=hs(F,R),Rt!==4&&(Rt=2),Qa===null?Qa=[y]:Qa.push(y),y=w;do{switch(y.tag){case 3:y.flags|=65536,s&=-s,y.lanes|=s;var $=q2(y,F,s);y2(y,$);break e;case 1:R=F;var H=y.type,q=y.stateNode;if((y.flags&128)===0&&(typeof H.getDerivedStateFromError=="function"||q!==null&&typeof q.componentDidCatch=="function"&&(mi===null||!mi.has(q)))){y.flags|=65536,s&=-s,y.lanes|=s;var ye=Y2(y,R,s);y2(y,ye);break e}}y=y.return}while(y!==null)}Ax(l)}catch(ke){s=ke,Ct===l&&l!==null&&(Ct=l=l.return);continue}break}while(!0)}function Sx(){var i=Ec.current;return Ec.current=dc,i===null?dc:i}function Qp(){(Rt===0||Rt===3||Rt===2)&&(Rt=4),Ut===null||(to&268435455)===0&&(yc&268435455)===0||yi(Ut,Vt)}function Sc(i,s){var l=Je;Je|=2;var f=Sx();(Ut!==i||Vt!==s)&&(Ur=null,ro(i,s));do try{$M();break}catch(g){_x(i,g)}while(!0);if(lp(),Je=l,Ec.current=f,Ct!==null)throw Error(n(261));return Ut=null,Vt=0,Rt}function $M(){for(;Ct!==null;)vx(Ct)}function VM(){for(;Ct!==null&&!m8();)vx(Ct)}function vx(i){var s=Nx(i.alternate,i,Nn);i.memoizedProps=i.pendingProps,s===null?Ax(i):Ct=s,zp.current=null}function Ax(i){var s=i;do{var l=s.alternate;if(i=s.return,(s.flags&32768)===0){if(l=MM(l,s,Nn),l!==null){Ct=l;return}}else{if(l=FM(l,s),l!==null){l.flags&=32767,Ct=l;return}if(i!==null)i.flags|=32768,i.subtreeFlags=0,i.deletions=null;else{Rt=6,Ct=null;return}}if(s=s.sibling,s!==null){Ct=s;return}Ct=s=i}while(s!==null);Rt===0&&(Rt=5)}function io(i,s,l){var f=nt,g=zn.transition;try{zn.transition=null,nt=1,qM(i,s,l,f)}finally{zn.transition=g,nt=f}return null}function qM(i,s,l,f){do Es();while(gi!==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 y=l.lanes|l.childLanes;if(v8(i,y),i===Ut&&(Ct=Ut=null,Vt=0),(l.subtreeFlags&2064)===0&&(l.flags&2064)===0||bc||(bc=!0,Ox(kl,function(){return Es(),null})),y=(l.flags&15990)!==0,(l.subtreeFlags&15990)!==0||y){y=zn.transition,zn.transition=null;var w=nt;nt=1;var R=Je;Je|=4,zp.current=null,UM(i,l),gx(l,i),dM(Qh),Dl=!!Kh,Qh=Kh=null,i.current=l,HM(l),g8(),Je=R,nt=w,zn.transition=y}else i.current=l;if(bc&&(bc=!1,gi=i,xc=g),y=i.pendingLanes,y===0&&(mi=null),T8(l.stateNode),Tn(i,wt()),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(Tc)throw Tc=!1,i=Vp,Vp=null,i;return(xc&1)!==0&&i.tag!==0&&Es(),y=i.pendingLanes,(y&1)!==0?i===qp?Xa++:(Xa=0,qp=i):Xa=0,di(),null}function Es(){if(gi!==null){var i=pb(xc),s=zn.transition,l=nt;try{if(zn.transition=null,nt=16>i?16:i,gi===null)var f=!1;else{if(i=gi,gi=null,xc=0,(Je&6)!==0)throw Error(n(331));var g=Je;for(Je|=4,_e=i.current;_e!==null;){var y=_e,w=y.child;if((_e.flags&16)!==0){var R=y.deletions;if(R!==null){for(var F=0;F<R.length;F++){var K=R[F];for(_e=K;_e!==null;){var ce=_e;switch(ce.tag){case 0:case 11:case 15:Ga(8,ce,y)}var pe=ce.child;if(pe!==null)pe.return=ce,_e=pe;else for(;_e!==null;){ce=_e;var ue=ce.sibling,we=ce.return;if(dx(ce),ce===K){_e=null;break}if(ue!==null){ue.return=we,_e=ue;break}_e=we}}}var ve=y.alternate;if(ve!==null){var Ce=ve.child;if(Ce!==null){ve.child=null;do{var _t=Ce.sibling;Ce.sibling=null,Ce=_t}while(Ce!==null)}}_e=y}}if((y.subtreeFlags&2064)!==0&&w!==null)w.return=y,_e=w;else e:for(;_e!==null;){if(y=_e,(y.flags&2048)!==0)switch(y.tag){case 0:case 11:case 15:Ga(9,y,y.return)}var $=y.sibling;if($!==null){$.return=y.return,_e=$;break e}_e=y.return}}var H=i.current;for(_e=H;_e!==null;){w=_e;var q=w.child;if((w.subtreeFlags&2064)!==0&&q!==null)q.return=w,_e=q;else e:for(w=H;_e!==null;){if(R=_e,(R.flags&2048)!==0)try{switch(R.tag){case 0:case 11:case 15:gc(9,R)}}catch(ke){yt(R,R.return,ke)}if(R===w){_e=null;break e}var ye=R.sibling;if(ye!==null){ye.return=R.return,_e=ye;break e}_e=R.return}}if(Je=g,di(),Tr&&typeof Tr.onPostCommitFiberRoot=="function")try{Tr.onPostCommitFiberRoot(Nl,i)}catch(ke){}f=!0}return f}finally{nt=l,zn.transition=s}}return!1}function Cx(i,s,l){s=hs(l,s),s=q2(i,s,1),i=hi(i,s,1),s=on(),i!==null&&(xa(i,1,s),Tn(i,s))}function yt(i,s,l){if(i.tag===3)Cx(i,i,l);else for(;s!==null;){if(s.tag===3){Cx(s,i,l);break}else if(s.tag===1){var f=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof f.componentDidCatch=="function"&&(mi===null||!mi.has(f))){i=hs(l,i),i=Y2(s,i,1),s=hi(s,i,1),i=on(),s!==null&&(xa(s,1,i),Tn(s,i));break}}s=s.return}}function YM(i,s,l){var f=i.pingCache;f!==null&&f.delete(s),s=on(),i.pingedLanes|=i.suspendedLanes&l,Ut===i&&(Vt&l)===l&&(Rt===4||Rt===3&&(Vt&130023424)===Vt&&500>wt()-$p?ro(i,0):jp|=l),Tn(i,s)}function kx(i,s){s===0&&((i.mode&1)===0?s=1:(s=Il,Il<<=1,(Il&130023424)===0&&(Il=4194304)));var l=on();i=Mr(i,s),i!==null&&(xa(i,s,l),Tn(i,l))}function WM(i){var s=i.memoizedState,l=0;s!==null&&(l=s.retryLane),kx(i,l)}function GM(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),kx(i,l)}var Nx;Nx=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,DM(i,s,l);En=(i.flags&131072)!==0}else En=!1,pt&&(s.flags&1048576)!==0&&u2(s,Zl,s.index);switch(s.lanes=0,s.tag){case 2:var f=s.type;pc(i,s),i=s.pendingProps;var g=os(s,Qt.current);ds(s,l),g=bp(null,s,f,i,g,l);var y=xp();return s.flags|=1,typeof g=="object"&&g!==null&&typeof g.render=="function"&&g.$$typeof===void 0?(s.tag=1,s.memoizedState=null,s.updateQueue=null,gn(f)?(y=!0,Ql(s)):y=!1,s.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,hp(s),g.updater=fc,s.stateNode=g,g._reactInternals=s,Cp(s,f,i,l),s=Ip(null,s,f,!0,y,l)):(s.tag=0,pt&&y&&rp(s),rn(null,s,g,l),s=s.child),s;case 16:f=s.elementType;e:{switch(pc(i,s),i=s.pendingProps,g=f._init,f=g(f._payload),s.type=f,g=s.tag=QM(f),i=tr(f,i),g){case 0:s=Op(null,s,f,i,l);break e;case 1:s=tx(null,s,f,i,l);break e;case 11:s=Q2(null,s,f,i,l);break e;case 14:s=X2(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),Op(i,s,f,g,l);case 1:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),tx(i,s,f,g,l);case 3:e:{if(nx(s),i===null)throw Error(n(387));f=s.pendingProps,y=s.memoizedState,g=y.element,E2(i,s),oc(s,f,null,l);var w=s.memoizedState;if(f=w.element,y.isDehydrated)if(y={element:f,isDehydrated:!1,cache:w.cache,pendingSuspenseBoundaries:w.pendingSuspenseBoundaries,transitions:w.transitions},s.updateQueue.baseState=y,s.memoizedState=y,s.flags&256){g=hs(Error(n(423)),s),s=rx(i,s,f,l,g);break e}else if(f!==g){g=hs(Error(n(424)),s),s=rx(i,s,f,l,g);break e}else for(kn=ui(s.stateNode.containerInfo.firstChild),Cn=s,pt=!0,er=null,l=m2(s,null,f,l),s.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(us(),f===g){s=Br(i,s,l);break e}rn(i,s,f,l)}s=s.child}return s;case 5:return b2(s),i===null&&sp(s),f=s.type,g=s.pendingProps,y=i!==null?i.memoizedProps:null,w=g.children,Xh(f,g)?w=null:y!==null&&Xh(f,y)&&(s.flags|=32),ex(i,s),rn(i,s,w,l),s.child;case 6:return i===null&&sp(s),null;case 13:return ix(i,s,l);case 4:return pp(s,s.stateNode.containerInfo),f=s.pendingProps,i===null?s.child=ls(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),Q2(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,y=s.memoizedProps,w=g.value,at(nc,f._currentValue),f._currentValue=w,y!==null)if(Zn(y.value,w)){if(y.children===g.children&&!mn.current){s=Br(i,s,l);break e}}else for(y=s.child,y!==null&&(y.return=s);y!==null;){var R=y.dependencies;if(R!==null){w=y.child;for(var F=R.firstContext;F!==null;){if(F.context===f){if(y.tag===1){F=Fr(-1,l&-l),F.tag=2;var K=y.updateQueue;if(K!==null){K=K.shared;var ce=K.pending;ce===null?F.next=F:(F.next=ce.next,ce.next=F),K.pending=F}}y.lanes|=l,F=y.alternate,F!==null&&(F.lanes|=l),dp(y.return,l,s),R.lanes|=l;break}F=F.next}}else if(y.tag===10)w=y.type===s.type?null:y.child;else if(y.tag===18){if(w=y.return,w===null)throw Error(n(341));w.lanes|=l,R=w.alternate,R!==null&&(R.lanes|=l),dp(w,l,s),w=y.sibling}else w=y.child;if(w!==null)w.return=y;else for(w=y;w!==null;){if(w===s){w=null;break}if(y=w.sibling,y!==null){y.return=w.return,w=y;break}w=w.return}y=w}rn(i,s,g.children,l),s=s.child}return s;case 9:return g=s.type,f=s.pendingProps.children,ds(s,l),g=Un(g),f=f(g),s.flags|=1,rn(i,s,f,l),s.child;case 14:return f=s.type,g=tr(f,s.pendingProps),g=tr(f.type,g),X2(i,s,f,g,l);case 15:return J2(i,s,s.type,s.pendingProps,l);case 17:return f=s.type,g=s.pendingProps,g=s.elementType===f?g:tr(f,g),pc(i,s),s.tag=1,gn(f)?(i=!0,Ql(s)):i=!1,ds(s,l),$2(s,f,g),Cp(s,f,g,l),Ip(null,s,f,!0,i,l);case 19:return sx(i,s,l);case 22:return Z2(i,s,l)}throw Error(n(156,s.tag))};function Ox(i,s){return lb(i,s)}function KM(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 KM(i,s,l,f)}function Xp(i){return i=i.prototype,!(!i||!i.isReactComponent)}function QM(i){if(typeof i=="function")return Xp(i)?1:0;if(i!=null){if(i=i.$$typeof,i===te)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 vc(i,s,l,f,g,y){var w=2;if(f=i,typeof i=="function")Xp(i)&&(w=1);else if(typeof i=="string")w=5;else e:switch(i){case Q:return oo(l.children,g,y,s);case Ee:w=8,g|=8;break;case re:return i=jn(12,l,s,g|2),i.elementType=re,i.lanes=y,i;case oe:return i=jn(13,l,s,g),i.elementType=oe,i.lanes=y,i;case de:return i=jn(19,l,s,g),i.elementType=de,i.lanes=y,i;case he:return Ac(l,g,y,s);default:if(typeof i=="object"&&i!==null)switch(i.$$typeof){case U:w=10;break e;case W:w=9;break e;case te: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=y,s}function oo(i,s,l,f){return i=jn(7,i,f,s),i.lanes=l,i}function Ac(i,s,l,f){return i=jn(22,i,f,s),i.elementType=he,i.lanes=l,i.stateNode={isHidden:!1},i}function Jp(i,s,l){return i=jn(6,i,null,s),i.lanes=l,i}function Zp(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 XM(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=Ah(0),this.expirationTimes=Ah(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ah(0),this.identifierPrefix=f,this.onRecoverableError=g,this.mutableSourceEagerHydrationData=null}function em(i,s,l,f,g,y,w,R,F){return i=new XM(i,s,l,R,F),s===1?(s=1,y===!0&&(s|=8)):s=0,y=jn(3,null,null,s),i.current=y,y.stateNode=i,y.memoizedState={element:f,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},hp(y),i}function JM(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 Ix(i){if(!i)return ci;i=i._reactInternals;e:{if(Wi(i)!==i||i.tag!==1)throw Error(n(170));var s=i;do{switch(s.tag){case 3:s=s.stateNode.context;break e;case 1:if(gn(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break e}}s=s.return}while(s!==null);throw Error(n(171))}if(i.tag===1){var l=i.type;if(gn(l))return o2(i,l,s)}return s}function Rx(i,s,l,f,g,y,w,R,F){return i=em(l,f,!0,i,g,y,w,R,F),i.context=Ix(null),l=i.current,f=on(),g=Ei(l),y=Fr(f,g),y.callback=s!=null?s:null,hi(l,y,g),i.current.lanes=g,xa(i,g,f),Tn(i,f),i}function Cc(i,s,l,f){var g=s.current,y=on(),w=Ei(g);return l=Ix(l),s.context===null?s.context=l:s.pendingContext=l,s=Fr(y,w),s.payload={element:i},f=f===void 0?null:f,f!==null&&(s.callback=f),i=hi(g,s,w),i!==null&&(ir(i,g,w,y),ic(i,g,w)),w}function kc(i){return i=i.current,i.child?(i.child.tag===5,i.child.stateNode):null}function Px(i,s){if(i=i.memoizedState,i!==null&&i.dehydrated!==null){var l=i.retryLane;i.retryLane=l!==0&&l<s?l:s}}function tm(i,s){Px(i,s),(i=i.alternate)&&Px(i,s)}function ZM(){return null}var Lx=typeof reportError=="function"?reportError:function(i){console.error(i)};function nm(i){this._internalRoot=i}Nc.prototype.render=nm.prototype.render=function(i){var s=this._internalRoot;if(s===null)throw Error(n(409));Cc(i,s,null,null)},Nc.prototype.unmount=nm.prototype.unmount=function(){var i=this._internalRoot;if(i!==null){this._internalRoot=null;var s=i.containerInfo;no(function(){Cc(null,i,null,null)}),s[Rr]=null}};function Nc(i){this._internalRoot=i}Nc.prototype.unstable_scheduleHydration=function(i){if(i){var s=Eb();i={blockedOn:null,target:i,priority:s};for(var l=0;l<oi.length&&s!==0&&s<oi[l].priority;l++);oi.splice(l,0,i),l===0&&bb(i)}};function rm(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11)}function Oc(i){return!(!i||i.nodeType!==1&&i.nodeType!==9&&i.nodeType!==11&&(i.nodeType!==8||i.nodeValue!==" react-mount-point-unstable "))}function Dx(){}function eF(i,s,l,f,g){if(g){if(typeof f=="function"){var y=f;f=function(){var K=kc(w);y.call(K)}}var w=Rx(s,f,i,0,null,!1,!1,"",Dx);return i._reactRootContainer=w,i[Rr]=w.current,Da(i.nodeType===8?i.parentNode:i),no(),w}for(;g=i.lastChild;)i.removeChild(g);if(typeof f=="function"){var R=f;f=function(){var K=kc(F);R.call(K)}}var F=em(i,0,!1,null,null,!1,!1,"",Dx);return i._reactRootContainer=F,i[Rr]=F.current,Da(i.nodeType===8?i.parentNode:i),no(function(){Cc(s,F,l,f)}),F}function Ic(i,s,l,f,g){var y=l._reactRootContainer;if(y){var w=y;if(typeof g=="function"){var R=g;g=function(){var F=kc(w);R.call(F)}}Cc(s,w,i,g)}else w=eF(l,s,i,g,f);return kc(w)}mb=function(i){switch(i.tag){case 3:var s=i.stateNode;if(s.current.memoizedState.isDehydrated){var l=ba(s.pendingLanes);l!==0&&(Ch(s,l|1),Tn(s,wt()),(Je&6)===0&&(gs=wt()+500,di()))}break;case 13:no(function(){var f=Mr(i,1);if(f!==null){var g=on();ir(f,i,1,g)}}),tm(i,1)}},kh=function(i){if(i.tag===13){var s=Mr(i,134217728);if(s!==null){var l=on();ir(s,i,134217728,l)}tm(i,134217728)}},gb=function(i){if(i.tag===13){var s=Ei(i),l=Mr(i,s);if(l!==null){var f=on();ir(l,i,s,f)}tm(i,s)}},Eb=function(){return nt},yb=function(i,s){var l=nt;try{return nt=i,s()}finally{nt=l}},bh=function(i,s,l){switch(s){case"input":if(Yo(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=Gl(f);if(!g)throw Error(n(90));qi(f),Yo(f,g)}}}break;case"textarea":Sl(i,l);break;case"select":s=l.value,s!=null&&ei(i,!!l.multiple,s,!1)}},nb=Gp,rb=no;var tF={usingClientEntryPoint:!1,Events:[Ba,rs,Gl,eb,tb,Gp]},Ja={findFiberByHostInstance:Gi,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},nF={bundleType:Ja.bundleType,version:Ja.version,rendererPackageName:Ja.rendererPackageName,rendererConfig:Ja.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=ab(i),i===null?null:i.stateNode},findFiberByHostInstance:Ja.findFiberByHostInstance||ZM,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 Rc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Rc.isDisabled&&Rc.supportsFiber)try{Nl=Rc.inject(nF),Tr=Rc}catch(i){}}return ln.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=tF,ln.createPortal=function(i,s){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!rm(s))throw Error(n(200));return JM(i,s,null,l)},ln.createRoot=function(i,s){if(!rm(i))throw Error(n(299));var l=!1,f="",g=Lx;return s!=null&&(s.unstable_strictMode===!0&&(l=!0),s.identifierPrefix!==void 0&&(f=s.identifierPrefix),s.onRecoverableError!==void 0&&(g=s.onRecoverableError)),s=em(i,1,!1,null,null,l,!1,f,g),i[Rr]=s.current,Da(i.nodeType===8?i.parentNode:i),new nm(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=ab(s),i=i===null?null:i.stateNode,i},ln.flushSync=function(i){return no(i)},ln.hydrate=function(i,s,l){if(!Oc(s))throw Error(n(200));return Ic(null,i,s,!0,l)},ln.hydrateRoot=function(i,s,l){if(!rm(i))throw Error(n(405));var f=l!=null&&l.hydratedSources||null,g=!1,y="",w=Lx;if(l!=null&&(l.unstable_strictMode===!0&&(g=!0),l.identifierPrefix!==void 0&&(y=l.identifierPrefix),l.onRecoverableError!==void 0&&(w=l.onRecoverableError)),s=Rx(s,null,i,1,l!=null?l:null,g,!1,y,w),i[Rr]=s.current,Da(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 Nc(s)},ln.render=function(i,s,l){if(!Oc(s))throw Error(n(200));return Ic(null,i,s,!1,l)},ln.unmountComponentAtNode=function(i){if(!Oc(i))throw Error(n(40));return i._reactRootContainer?(no(function(){Ic(null,null,i,!1,function(){i._reactRootContainer=null,i[Rr]=null})}),!0):!1},ln.unstable_batchedUpdates=Gp,ln.unstable_renderSubtreeIntoContainer=function(i,s,l,f){if(!Oc(l))throw Error(n(200));if(i==null||i._reactInternals===void 0)throw Error(n(38));return Ic(i,s,l,!1,f)},ln.version="18.3.1-next-f1338f8080-20240426",ln}var x0;function w0(){if(x0)return yd.exports;x0=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(),yd.exports=lv(),yd.exports}var Ns=w0();function _0(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=_0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ae(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=_0(e))&&(r&&(r+=" "),r+=t);return r}var S0={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},v0=xi.createContext&&xi.createContext(S0),cv=["attr","size","title"];function dv(e,t){if(e==null)return{};var n=fv(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 fv(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 wu(){return wu=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},wu.apply(this,arguments)}function A0(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 _u(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?A0(Object(n),!0).forEach(function(r){hv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):A0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hv(e,t,n){return t=pv(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pv(e){var t=mv(e,"string");return typeof t=="symbol"?t:t+""}function mv(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 C0(e){return e&&e.map((t,n)=>xi.createElement(t.tag,_u({key:n},t.attr),C0(t.child)))}function tn(e){return t=>xi.createElement(gv,wu({attr:_u({},e.attr)},t),C0(e.child))}function gv(e){var t=n=>{var{attr:r,size:o,title:a}=e,u=dv(e,cv),c=o||n.size||"1em",d;return n.className&&(d=n.className),e.className&&(d=(d?d+" ":"")+e.className),xi.createElement("svg",wu({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,u,{className:d,style:_u(_u({color:e.color||n.color},n.style),e.style),height:c,width:c,xmlns:"http://www.w3.org/2000/svg"}),a&&xi.createElement("title",null,a),e.children)};return v0!==void 0?xi.createElement(v0.Consumer,null,n=>t(n)):t(S0)}function Ev(e){return tn({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 $r=({className:e,iconUrl:t,icon:n,type:r="button",ariaLabel:o,title:a,disabled:u=!1,onClick:c})=>!n&&!t?null:P.jsx("button",{className:ae(e,`${ee}-icon-button`),type:r,"aria-label":o,title:a,onClick:c,disabled:u,children:t?P.jsx("img",{className:ae(`${ee}-icon-image`),src:t,alt:o,loading:"lazy"}):n}),yv="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",Tv=({onClick:e})=>{const{globalClassName:t,headerConfig:n,mode:r}=kt(),o=r==="messaging",a=o?"Open Commerce Client":"Open Copilot",u=o?P.jsx(Ev,{className:ae(t,`${ee}-minimized-icon`)}):P.jsx("img",{src:(n==null?void 0:n.logoUrl)||yv,alt:"Copilot",className:ae(t,`${ee}-minimized-icon-img`)});return P.jsx($r,{className:ae(t,`${ee}-minimized-button`),ariaLabel:a,title:a,icon:u,onClick:e})},bv=()=>{const{globalClassName:e,themeVariables:t}=kt(),n=()=>{bu(!1),Ai(!0)};return Ns.createPortal(P.jsx("div",{className:ae(e,`${ee}-minimized-container`),style:t,children:P.jsx(Tv,{onClick:n})}),document.body)};function xv(e){return tn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3.5 8a5.5 5.5 0 1 1 8.596 4.547 9.005 9.005 0 0 1 5.9 8.18.751.751 0 0 1-1.5.045 7.5 7.5 0 0 0-14.993 0 .75.75 0 0 1-1.499-.044 9.005 9.005 0 0 1 5.9-8.181A5.496 5.496 0 0 1 3.5 8ZM9 4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Zm8.29 4c-.148 0-.292.01-.434.03a.75.75 0 1 1-.212-1.484 4.53 4.53 0 0 1 3.38 8.097 6.69 6.69 0 0 1 3.956 6.107.75.75 0 0 1-1.5 0 5.193 5.193 0 0 0-3.696-4.972l-.534-.16v-1.676l.41-.209A3.03 3.03 0 0 0 17.29 8Z"},child:[]}]})(e)}function ki(){const e=X.useContext(d0);if(!e)throw new Error("useMessaging must be used within a MessagingProvider");return e}const wv=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 k0(e){return tn({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 N0(e){return tn({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 _v(e){return tn({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 Sv(e){return tn({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 vv(e){return tn({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"},child:[]}]})(e)}const O0=({className:e,children:t,type:n,disabled:r=!1,onClick:o})=>P.jsx("button",{className:ae(`${ee}-button`,e,{disabled:r}),type:n||"button",disabled:r,onClick:o,children:t}),Av=({searchConfig:e,globalClassName:t})=>{const n=e.buttonIconUrl;return n?P.jsx("img",{className:ae(`${ee}-search-button-icon-image`,t),src:n,alt:"",loading:"lazy"}):P.jsx(N0,{size:"16px"})},Cv=({className:e,searchConfig:t,globalClassName:n,componentType:r,isLoading:o})=>{if((t==null?void 0:t.buttonType)==="icon")return P.jsx($r,{className:ae(e,n,`cim-${r}-component`,`${ee}-search-button-icon`),type:"submit",disabled:o,ariaLabel:(t==null?void 0:t.buttonAriaLabel)||(t==null?void 0:t.buttonLabel)||"Search Copilot",icon:t!=null&&t.buttonIconUrl?null:P.jsx(N0,{size:"16px"}),iconUrl:t==null?void 0:t.buttonIconUrl});const a=(t==null?void 0:t.buttonType)==="icon-text";return P.jsxs(O0,{className:ae(e,n,`cim-${r}-component`,`${ee}-search-button`),type:"submit","aria-label":(t==null?void 0:t.buttonAriaLabel)||"",disabled:o,children:[a&&P.jsx(Av,{globalClassName:n,searchConfig:t}),(t==null?void 0:t.buttonLabel)||"Search"]})};function PF(){}function LF(){}function I0(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 R0(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const kv=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Nv=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Ov={};function P0(e,t){return(Ov.jsx?Nv:kv).test(e)}const Iv=/[ \t\n\f\r]/g;function Rv(e){return typeof e=="object"?e.type==="text"?L0(e.value):!1:L0(e)}function L0(e){return e.replace(Iv,"")===""}let Os=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};Os.prototype.normal={},Os.prototype.property={},Os.prototype.space=void 0;function D0(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new Os(n,r,t)}function Is(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 Pv=0;const je=Ni(),vt=Ni(),xd=Ni(),me=Ni(),ot=Ni(),ho=Ni(),bn=Ni();function Ni(){return Za(2,++Pv)}const wd=Object.freeze(Object.defineProperty({__proto__:null,boolean:je,booleanish:vt,commaOrSpaceSeparated:bn,commaSeparated:ho,number:me,overloadedBoolean:xd,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),_d=Object.keys(wd);let Sd=class extends cn{constructor(t,n,r,o){let a=-1;if(super(t,n),M0(this,"space",o),typeof r=="number")for(;++a<_d.length;){const u=_d[a];M0(this,_d[a],(r&wd[u])===wd[u])}}};Sd.prototype.defined=!0;function M0(e,t,n){n&&(e[t]=n)}function po(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const a=new Sd(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Is(r)]=r,n[Is(a.attribute)]=r}return new Os(t,n,e.space)}const F0=po({properties:{ariaActiveDescendant:null,ariaAtomic:vt,ariaAutoComplete:null,ariaBusy:vt,ariaChecked:vt,ariaColCount:me,ariaColIndex:me,ariaColSpan:me,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:vt,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:vt,ariaFlowTo:ot,ariaGrabbed:vt,ariaHasPopup:null,ariaHidden:vt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:me,ariaLive:null,ariaModal:vt,ariaMultiLine:vt,ariaMultiSelectable:vt,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:me,ariaPressed:vt,ariaReadOnly:vt,ariaRelevant:null,ariaRequired:vt,ariaRoleDescription:ot,ariaRowCount:me,ariaRowIndex:me,ariaRowSpan:me,ariaSelected:vt,ariaSetSize:me,ariaSort:null,ariaValueMax:me,ariaValueMin:me,ariaValueNow:me,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function B0(e,t){return t in e?e[t]:t}function U0(e,t){return B0(e,t.toLowerCase())}const Lv=po({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:ho,acceptCharset:ot,accessKey:ot,action:null,allow:null,allowFullScreen:je,allowPaymentRequest:je,allowUserMedia:je,alt:null,as:null,async:je,autoCapitalize:null,autoComplete:ot,autoFocus:je,autoPlay:je,blocking:ot,capture:null,charSet:null,checked:je,cite:null,className:ot,cols:me,colSpan:null,content:null,contentEditable:vt,controls:je,controlsList:ot,coords:me|ho,crossOrigin:null,data:null,dateTime:null,decoding:null,default:je,defer:je,dir:null,dirName:null,disabled:je,download:xd,draggable:vt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:je,formTarget:null,headers:ot,height:me,hidden:xd,high:me,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:me,manifest:null,max:null,maxLength:me,media:null,method:null,min:null,minLength:me,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:me,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:me,rowSpan:me,sandbox:ot,scope:null,scoped:je,seamless:je,selected:je,shadowRootClonable:je,shadowRootDelegatesFocus:je,shadowRootMode:null,shape:null,size:me,sizes:null,slot:null,span:me,spellCheck:vt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:me,step:null,style:null,tabIndex:me,target:null,title:null,translate:null,type:null,typeMustMatch:je,useMap:null,value:vt,width:me,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ot,axis:null,background:null,bgColor:null,border:me,borderColor:null,bottomMargin:me,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:je,declare:je,event:null,face:null,frame:null,frameBorder:null,hSpace:me,leftMargin:me,link:null,longDesc:null,lowSrc:null,marginHeight:me,marginWidth:me,noResize:je,noHref:je,noShade:je,noWrap:je,object:null,profile:null,prompt:null,rev:null,rightMargin:me,rules:null,scheme:null,scrolling:vt,standby:null,summary:null,text:null,topMargin:me,valueType:null,version:null,vAlign:null,vLink:null,vSpace:me,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:je,disableRemotePlayback:je,prefix:null,property:null,results:me,security:null,unselectable:null},space:"html",transform:U0}),Dv=po({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:bn,accentHeight:me,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:me,amplitude:me,arabicForm:null,ascent:me,attributeName:null,attributeType:null,azimuth:me,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:me,by:null,calcMode:null,capHeight:me,className: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:me,diffuseConstant:me,direction:null,display:null,dur:null,divisor:me,dominantBaseline:null,download:je,dx:null,dy:null,edgeMode:null,editable:null,elevation:me,enableBackground:null,end:null,event:null,exponent:me,externalResourcesRequired:null,fill:null,fillOpacity:me,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:ho,g2:ho,glyphName:ho,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:me,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:me,horizOriginX:me,horizOriginY:me,id:null,ideographic:me,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:me,k:me,k1:me,k2:me,k3:me,k4:me,kernelMatrix:bn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:me,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:me,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:me,overlineThickness:me,paintOrder:null,panose1:null,path:null,pathLength:me,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:me,pointsAtY:me,pointsAtZ:me,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:bn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:bn,rev:bn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:bn,requiredFeatures:bn,requiredFonts:bn,requiredFormats:bn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:me,specularExponent:me,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:me,strikethroughThickness:me,string:null,stroke:null,strokeDashArray:bn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:me,strokeOpacity:me,strokeWidth:null,style:null,surfaceScale:me,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:bn,tabIndex:me,tableValues:null,target:null,targetX:me,targetY:me,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:bn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:me,underlineThickness:me,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:me,values:null,vAlphabetic:me,vMathematical:me,vectorEffect:null,vHanging:me,vIdeographic:me,version:null,vertAdvY:me,vertOriginX:me,vertOriginY:me,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:me,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:B0}),H0=po({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),z0=po({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:U0}),j0=po({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),Mv={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"},Fv=/[A-Z]/g,$0=/-[a-z]/g,Bv=/^data[-\w.:]+$/i;function vd(e,t){const n=Is(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"&&Bv.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace($0,Hv);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!$0.test(a)){let u=a.replace(Fv,Uv);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Sd}return new o(r,t)}function Uv(e){return"-"+e.toLowerCase()}function Hv(e){return e.charAt(1).toUpperCase()}const Su=D0([F0,Lv,H0,z0,j0],"html"),mo=D0([F0,Dv,H0,z0,j0],"svg");function V0(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function q0(e){return e.join(" ").trim()}var go={},Ad,Y0;function zv(){if(Y0)return Ad;Y0=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="",b="comment",T="declaration";Ad=function(_,S){if(typeof _!="string")throw new TypeError("First argument must be a string");if(!_)return[];S=S||{};var A=1,O=1;function I(oe){var de=oe.match(t);de&&(A+=de.length);var be=oe.lastIndexOf(d);O=~be?oe.length-be:O+oe.length}function z(){var oe={line:A,column:O};return function(de){return de.position=new Y(oe),Ee(),de}}function Y(oe){this.start=oe,this.end={line:A,column:O},this.source=S.source}Y.prototype.content=_;function M(oe){var de=new Error(S.source+":"+A+":"+O+": "+oe);if(de.reason=oe,de.filename=S.source,de.line=A,de.column=O,de.source=_,!S.silent)throw de}function Q(oe){var de=oe.exec(_);if(de){var be=de[0];return I(be),_=_.slice(be.length),de}}function Ee(){Q(n)}function re(oe){var de;for(oe=oe||[];de=U();)de!==!1&&oe.push(de);return oe}function U(){var oe=z();if(!(h!=_.charAt(0)||p!=_.charAt(1))){for(var de=2;E!=_.charAt(de)&&(p!=_.charAt(de)||h!=_.charAt(de+1));)++de;if(de+=2,E===_.charAt(de-1))return M("End of comment missing");var be=_.slice(2,de-2);return O+=2,I(be),_=_.slice(de),O+=2,oe({type:b,comment:be})}}function W(){var oe=z(),de=Q(r);if(de){if(U(),!Q(o))return M("property missing ':'");var be=Q(a),Ie=oe({type:T,property:x(de[0].replace(e,E)),value:be?x(be[0].replace(e,E)):E});return Q(u),Ie}}function te(){var oe=[];re(oe);for(var de;de=W();)de!==!1&&(oe.push(de),re(oe));return oe}return Ee(),te()};function x(_){return _?_.replace(c,E):E}return Ad}var W0;function jv(){if(W0)return go;W0=1;var e=go&&go.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(go,"__esModule",{value:!0}),go.default=n;var t=e(zv());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 go}var Rs={},G0;function $v(){if(G0)return Rs;G0=1,Object.defineProperty(Rs,"__esModule",{value:!0}),Rs.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 Rs.camelCase=d,Rs}var Ps,K0;function Vv(){if(K0)return Ps;K0=1;var e=Ps&&Ps.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(jv()),n=$v();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,Ps=r,Ps}var qv=Vv();const Yv=We(qv),vu=Q0("end"),ar=Q0("start");function Q0(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 X0(e){const t=ar(e),n=vu(e);if(t&&n)return{start:t,end:n}}function Ls(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?J0(e.position):"start"in e||"end"in e?J0(e):"line"in e||"column"in e?Cd(e):""}function Cd(e){return Z0(e&&e.line)+":"+Z0(e&&e.column)}function J0(e){return Cd(e&&e.start)+"-"+Cd(e&&e.end)}function Z0(e){return e&&typeof e=="number"?e:1}class Yt extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let o="",a={},u=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a=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=Ls(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=u&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual,this.expected,this.note,this.url}}Yt.prototype.file="",Yt.prototype.name="",Yt.prototype.reason="",Yt.prototype.message="",Yt.prototype.stack="",Yt.prototype.column=void 0,Yt.prototype.line=void 0,Yt.prototype.ancestors=void 0,Yt.prototype.cause=void 0,Yt.prototype.fatal=void 0,Yt.prototype.place=void 0,Yt.prototype.ruleId=void 0,Yt.prototype.source=void 0;const kd={}.hasOwnProperty,Wv=new Map,Gv=/[A-Z]/g,Kv=new Set(["table","tbody","thead","tfoot","tr"]),Qv=new Set(["td","th"]),eg="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function Xv(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=oA(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=iA(n,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?mo:Su,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=tg(o,e,void 0);return a&&typeof a!="string"?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function tg(e,t,n){if(t.type==="element")return Jv(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return Zv(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return tA(e,t,n);if(t.type==="mdxjsEsm")return eA(e,t);if(t.type==="root")return nA(e,t,n);if(t.type==="text")return rA(e,t)}function Jv(e,t,n){const r=e.schema;let o=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=rg(e,t.tagName,!1),u=sA(e,t);let c=Od(e,t);return Kv.has(t.tagName)&&(c=c.filter(function(d){return typeof d=="string"?!Rv(d):!0})),ng(e,u,a,t),Nd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function Zv(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)}Ds(e,t.position)}function eA(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ds(e,t.position)}function tA(e,t,n){const r=e.schema;let o=r;t.name==="svg"&&r.space==="html"&&(o=mo,e.schema=o),e.ancestors.push(t);const a=t.name===null?e.Fragment:rg(e,t.name,!0),u=aA(e,t),c=Od(e,t);return ng(e,u,a,t),Nd(u,c),e.ancestors.pop(),e.schema=r,e.create(t,a,u,n)}function nA(e,t,n){const r={};return Nd(r,Od(e,t)),e.create(t,e.Fragment,r,n)}function rA(e,t){return t.value}function ng(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Nd(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function iA(e,t,n){return r;function r(o,a,u,c){const h=Array.isArray(u.children)?n:t;return c?h(a,u,c):h(a,u)}}function oA(e,t){return n;function n(r,o,a,u){const c=Array.isArray(a.children),d=ar(r);return t(o,a,u,c,{columnNumber:d?d.column-1:void 0,fileName:e,lineNumber:d?d.line:void 0},void 0)}}function sA(e,t){const n={};let r,o;for(o in t.properties)if(o!=="children"&&kd.call(t.properties,o)){const a=uA(e,o,t.properties[o]);if(a){const[u,c]=a;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&Qv.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 aA(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 Ds(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 Ds(e,t.position);else a=r.value===null?!0:r.value;n[o]=a}return n}function Od(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:Wv;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=tg(e,a,u);c!==void 0&&n.push(c)}return n}function uA(e,t,n){const r=vd(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?R0(n):q0(n)),r.property==="style"){let o=typeof n=="object"?n:lA(e,String(n));return e.stylePropertyNameCase==="css"&&(o=cA(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&r.space?Mv[r.property]||r.property:r.attribute,n]}}function lA(e,t){try{return Yv(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,o=new Yt("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=eg+"#cannot-parse-style-attribute",o}}function rg(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=P0(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=P0(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const o=r.value;return kd.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(r);Ds(e)}function Ds(e,t){const n=new Yt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=eg+"#cannot-handle-mdx-estrees-without-createevaluater",n}function cA(e){const t={};let n;for(n in e)kd.call(e,n)&&(t[dA(n)]=e[n]);return t}function dA(e){let t=e.replace(Gv,fA);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function fA(e){return"-"+e.toLowerCase()}const Id={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"]},hA={};function Rd(e,t){const n=hA,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return ig(e,r,o)}function ig(e,t,n){if(pA(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 og(e.children,t,n)}return Array.isArray(e)?og(e,t,n):""}function og(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=ig(e[o],t,n);return r.join("")}function pA(e){return!!(e&&typeof e=="object")}const sg=document.createElement("i");function Pd(e){const t="&"+e+";";sg.innerHTML=t;const n=sg.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 ag={}.hasOwnProperty;function ug(e){const t={};let n=-1;for(;++n<e.length;)mA(t,e[n]);return t}function mA(e,t){let n;for(n in t){const o=(ag.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let u;if(a)for(u in a){ag.call(o,u)||(o[u]=[]);const c=a[u];gA(o[u],Array.isArray(c)?c:c?[c]:[])}}}function gA(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 lg(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=Vr(/[A-Za-z]/),Wt=Vr(/[\dA-Za-z]/),EA=Vr(/[#-'*+\--9=?A-Z^-~]/);function Au(e){return e!==null&&(e<32||e===127)}const Ld=Vr(/\d/),yA=Vr(/[\dA-Fa-f]/),TA=Vr(/[!-/:-@[-`{-~]/);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 Cu=Vr(new RegExp("\\p{P}|\\p{S}","u")),Oi=Vr(/\s/);function Vr(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Eo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let u="";if(a===37&&Wt(e.charCodeAt(n+1))&&Wt(e.charCodeAt(n+2)))o=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(u=String.fromCharCode(a));else if(a>55295&&a<57344){const c=e.charCodeAt(n+1);a<56320&&c>56319&&c<57344?(u=String.fromCharCode(a,c),o=1):u="�"}else u=String.fromCharCode(a);u&&(t.push(e.slice(r,n),encodeURIComponent(u)),r=n+o+1,u=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function 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 bA={tokenize:xA};function xA(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 wA={tokenize:_A},cg={tokenize:SA};function _A(e){const t=this,n=[];let r=0,o,a,u;return c;function c(I){if(r<n.length){const z=n[r];return t.containerState=z[1],e.attempt(z[0].continuation,d,h)(I)}return h(I)}function d(I){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&O();const z=t.events.length;let Y=z,M;for(;Y--;)if(t.events[Y][0]==="exit"&&t.events[Y][1].type==="chunkFlow"){M=t.events[Y][1].end;break}A(r);let Q=z;for(;Q<t.events.length;)t.events[Q][1].end=B({},M),Q++;return xn(t.events,Y+1,0,t.events.slice(z)),t.events.length=Q,h(I)}return c(I)}function h(I){if(r===n.length){if(!o)return b(I);if(o.currentConstruct&&o.currentConstruct.concrete)return x(I);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(cg,p,E)(I)}function p(I){return o&&O(),A(r),b(I)}function E(I){return t.parser.lazy[t.now().line]=r!==n.length,u=t.now().offset,x(I)}function b(I){return t.containerState={},e.attempt(cg,T,x)(I)}function T(I){return r++,n.push([t.currentConstruct,t.containerState]),b(I)}function x(I){if(I===null){o&&O(),A(0),e.consume(I);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:a}),_(I)}function _(I){if(I===null){S(e.exit("chunkFlow"),!0),A(0),e.consume(I);return}return Le(I)?(e.consume(I),S(e.exit("chunkFlow")),r=0,t.interrupt=void 0,c):(e.consume(I),_)}function S(I,z){const Y=t.sliceStream(I);if(z&&Y.push(null),I.previous=a,a&&(a.next=I),a=I,o.defineSkip(I.start),o.write(Y),t.parser.lazy[I.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 Q=t.events.length;let Ee=Q,re,U;for(;Ee--;)if(t.events[Ee][0]==="exit"&&t.events[Ee][1].type==="chunkFlow"){if(re){U=t.events[Ee][1].end;break}re=!0}for(A(r),M=Q;M<t.events.length;)t.events[M][1].end=B({},U),M++;xn(t.events,Ee+1,0,t.events.slice(Q)),t.events.length=M}}function A(I){let z=n.length;for(;z-- >I;){const Y=n[z];t.containerState=Y[1],Y[0].exit.call(t,e)}n.length=I}function O(){o.write([null]),a=void 0,o=void 0,t.containerState._closeFlow=void 0}}function SA(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 yo(e){if(e===null||it(e)||Oi(e))return 1;if(Cu(e))return 2}function ku(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 Dd={name:"attention",resolveAll:vA,tokenize:AA};function vA(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),b=B({},e[n][1].start);dg(E,-d),dg(b,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:b},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,ku(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 AA(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=yo(r);let a;return u;function u(d){return a=d,e.enter("attentionSequence"),c(d)}function c(d){if(d===a)return e.consume(d),c;const h=e.exit("attentionSequence"),p=yo(d),E=!p||p===2&&o||n.includes(d),b=!o||o===2&&p||n.includes(r);return h._open=!!(a===42?E:E&&(o||!b)),h._close=!!(a===42?b:b&&(p||!E)),t(d)}}function dg(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const CA={name:"autolink",tokenize:kA};function kA(e,t,n){let r=0;return o;function o(T){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(T){return nn(T)?(e.consume(T),u):T===64?n(T):h(T)}function u(T){return T===43||T===45||T===46||Wt(T)?(r=1,c(T)):h(T)}function c(T){return T===58?(e.consume(T),r=0,d):(T===43||T===45||T===46||Wt(T))&&r++<32?(e.consume(T),c):(r=0,h(T))}function d(T){return T===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):T===null||T===32||T===60||Au(T)?n(T):(e.consume(T),d)}function h(T){return T===64?(e.consume(T),p):EA(T)?(e.consume(T),h):n(T)}function p(T){return Wt(T)?E(T):n(T)}function E(T){return T===46?(e.consume(T),r=0,p):T===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(T),e.exit("autolinkMarker"),e.exit("autolink"),t):b(T)}function b(T){if((T===45||Wt(T))&&r++<63){const x=T===45?b:E;return e.consume(T),x}return n(T)}}const Ms={partial:!0,tokenize:NA};function NA(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 fg={continuation:{tokenize:IA},exit:RA,name:"blockQuote",tokenize:OA};function OA(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 IA(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(fg,t,n)(u)}}function RA(e){e.exit("blockQuote")}const hg={name:"characterEscape",tokenize:PA};function PA(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 TA(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const pg={name:"characterReference",tokenize:LA};function LA(e,t,n){const r=this;let o=0,a,u;return c;function c(E){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(E),e.exit("characterReferenceMarker"),d}function d(E){return E===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(E),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),a=31,u=Wt,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=yA,p):(e.enter("characterReferenceValue"),a=7,u=Ld,p(E))}function p(E){if(E===59&&o){const b=e.exit("characterReferenceValue");return u===Wt&&!Pd(r.sliceSerialize(b))?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 mg={partial:!0,tokenize:MA},gg={concrete:!0,name:"codeFenced",tokenize:DA};function DA(e,t,n){const r=this,o={partial:!0,tokenize:Y};let a=0,u=0,c;return d;function d(M){return h(M)}function h(M){const Q=r.events[r.events.length-1];return a=Q&&Q[1].type==="linePrefix"?Q[2].sliceSerialize(Q[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(mg,_,z)(M)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(M))}function b(M){return M===null||Le(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),E(M)):Ge(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Qe(e,T,"whitespace")(M)):M===96&&M===c?n(M):(e.consume(M),b)}function T(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(mg,_,z)(M):(e.enter("codeFlowValue"),I(M))}function I(M){return M===null||Le(M)?(e.exit("codeFlowValue"),O(M)):(e.consume(M),I)}function z(M){return e.exit("codeFenced"),t(M)}function Y(M,Q,Ee){let re=0;return U;function U(be){return M.enter("lineEnding"),M.consume(be),M.exit("lineEnding"),W}function W(be){return M.enter("codeFencedFence"),Ge(be)?Qe(M,te,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(be):te(be)}function te(be){return be===c?(M.enter("codeFencedFenceSequence"),oe(be)):Ee(be)}function oe(be){return be===c?(re++,M.consume(be),oe):re>=u?(M.exit("codeFencedFenceSequence"),Ge(be)?Qe(M,de,"whitespace")(be):de(be)):Ee(be)}function de(be){return be===null||Le(be)?(M.exit("codeFencedFence"),Q(be)):Ee(be)}}}function MA(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 Md={name:"codeIndented",tokenize:BA},FA={partial:!0,tokenize:UA};function BA(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(FA,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 UA(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 HA={name:"codeText",previous:jA,resolve:zA,tokenize:$A};function zA(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 jA(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function $A(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 VA{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&&Fs(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),Fs(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Fs(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);Fs(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Fs(this.left,n.reverse())}}}function Fs(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 Eg(e){const t={};let n=-1,r,o,a,u,c,d,h;const p=new VA(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,qA(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 qA(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,b=-1,T=n,x=0,_=0;const S=[_];for(;T;){for(;e.get(++o)[1]!==T;);a.push(o),T._tokenizer||(p=r.sliceStream(T),T.next||p.push(null),E&&u.defineSkip(T.start),T._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=!0),u.write(p),T._isInFirstContentOfListItem&&(u._gfmTasklistFirstContentOfListItem=void 0)),E=T,T=T.next}for(T=n;++b<c.length;)c[b][0]==="exit"&&c[b-1][0]==="enter"&&c[b][1].type===c[b-1][1].type&&c[b][1].start.line!==c[b][1].end.line&&(_=b+1,S.push(_),T._tokenizer=void 0,T.previous=void 0,T=T.next);for(u.events=[],T?(T._tokenizer=void 0,T.previous=void 0):S.pop(),b=S.length;b--;){const A=c.slice(S[b],S[b+1]),O=a.pop();d.push([O,O+A.length-1]),e.splice(O,2,A)}for(d.reverse(),b=-1;++b<d.length;)h[x+d[b][0]]=x+d[b][1],x+=d[b][1]-d[b][0]-1;return h}const YA={resolve:GA,tokenize:KA},WA={partial:!0,tokenize:QA};function GA(e){return Eg(e),e}function KA(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(WA,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 QA(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 yg(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),b):A===null||A===32||A===41||Au(A)?n(A):(e.enter(r),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),_(A))}function b(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"}),T(A))}function T(A){return A===62?(e.exit("chunkString"),e.exit(c),b(A)):A===null||A===60||Le(A)?n(A):(e.consume(A),A===92?x:T)}function x(A){return A===60||A===62||A===92?(e.consume(A),T):T(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||Au(A)?n(A):(e.consume(A),A===92?S:_)}function S(A){return A===40||A===41||A===92?(e.consume(A),_):_(A)}}function Tg(e,t,n,r,o,a){const u=this;let c=0,d;return h;function h(T){return e.enter(r),e.enter(o),e.consume(T),e.exit(o),e.enter(a),p}function p(T){return c>999||T===null||T===91||T===93&&!d||T===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(T):T===93?(e.exit(a),e.enter(o),e.consume(T),e.exit(o),e.exit(r),t):Le(T)?(e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),p):(e.enter("chunkString",{contentType:"string"}),E(T))}function E(T){return T===null||T===91||T===93||Le(T)||c++>999?(e.exit("chunkString"),p(T)):(e.consume(T),d||(d=!Ge(T)),T===92?b:E)}function b(T){return T===91||T===92||T===93?(e.consume(T),c++,E):E(T)}}function bg(e,t,n,r,o,a){let u;return c;function c(b){return b===34||b===39||b===40?(e.enter(r),e.enter(o),e.consume(b),e.exit(o),u=b===40?41:b,d):n(b)}function d(b){return b===u?(e.enter(o),e.consume(b),e.exit(o),e.exit(r),t):(e.enter(a),h(b))}function h(b){return b===u?(e.exit(a),d(u)):b===null?n(b):Le(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Qe(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),p(b))}function p(b){return b===u||b===null||Le(b)?(e.exit("chunkString"),h(b)):(e.consume(b),b===92?E:p)}function E(b){return b===u||b===92?(e.consume(b),p):p(b)}}function Bs(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 XA={name:"definition",tokenize:ZA},JA={partial:!0,tokenize:eC};function ZA(e,t,n){const r=this;let o;return a;function a(T){return e.enter("definition"),u(T)}function u(T){return Tg.call(r,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(T)}function c(T){return o=Yn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),T===58?(e.enter("definitionMarker"),e.consume(T),e.exit("definitionMarker"),d):n(T)}function d(T){return it(T)?Bs(e,h)(T):h(T)}function h(T){return yg(e,p,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(T)}function p(T){return e.attempt(JA,E,E)(T)}function E(T){return Ge(T)?Qe(e,b,"whitespace")(T):b(T)}function b(T){return T===null||Le(T)?(e.exit("definition"),r.parser.defined.push(o),t(T)):n(T)}}function eC(e,t,n){return r;function r(c){return it(c)?Bs(e,o)(c):n(c)}function o(c){return bg(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 tC={name:"hardBreakEscape",tokenize:nC};function nC(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 rC={name:"headingAtx",resolve:iC,tokenize:oC};function iC(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 oC(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 sC=["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"],xg=["pre","script","style","textarea"],aC={concrete:!0,name:"htmlFlow",resolveTo:cC,tokenize:dC},uC={partial:!0,tokenize:hC},lC={partial:!0,tokenize:fC};function cC(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),b):k===47?(e.consume(k),a=!0,_):k===63?(e.consume(k),o=3,r.interrupt?t:v):nn(k)?(e.consume(k),u=String.fromCharCode(k),S):n(k)}function b(k){return k===45?(e.consume(k),o=2,T):k===91?(e.consume(k),o=5,c=0,x):nn(k)?(e.consume(k),o=4,r.interrupt?t:v):n(k)}function T(k){return k===45?(e.consume(k),r.interrupt?t:v):n(k)}function x(k){const xe="CDATA[";return k===xe.charCodeAt(c++)?(e.consume(k),c===xe.length?r.interrupt?t:te: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 xe=k===47,Pe=u.toLowerCase();return!xe&&!a&&xg.includes(Pe)?(o=1,r.interrupt?t(k):te(k)):sC.includes(u.toLowerCase())?(o=6,xe?(e.consume(k),A):r.interrupt?t(k):te(k)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?O(k):I(k))}return k===45||Wt(k)?(e.consume(k),u+=String.fromCharCode(k),S):n(k)}function A(k){return k===62?(e.consume(k),r.interrupt?t:te):n(k)}function O(k){return Ge(k)?(e.consume(k),O):U(k)}function I(k){return k===47?(e.consume(k),U):k===58||k===95||nn(k)?(e.consume(k),z):Ge(k)?(e.consume(k),I):U(k)}function z(k){return k===45||k===46||k===58||k===95||Wt(k)?(e.consume(k),z):Y(k)}function Y(k){return k===61?(e.consume(k),M):Ge(k)?(e.consume(k),Y):I(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,Q):Ge(k)?(e.consume(k),M):Ee(k)}function Q(k){return k===d?(e.consume(k),d=null,re):k===null||Le(k)?n(k):(e.consume(k),Q)}function Ee(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||it(k)?Y(k):(e.consume(k),Ee)}function re(k){return k===47||k===62||Ge(k)?I(k):n(k)}function U(k){return k===62?(e.consume(k),W):n(k)}function W(k){return k===null||Le(k)?te(k):Ge(k)?(e.consume(k),W):n(k)}function te(k){return k===45&&o===2?(e.consume(k),Ie):k===60&&o===1?(e.consume(k),he):k===62&&o===4?(e.consume(k),D):k===63&&o===3?(e.consume(k),v):k===93&&o===5?(e.consume(k),ie):Le(k)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(uC,Z,oe)(k)):k===null||Le(k)?(e.exit("htmlFlowData"),oe(k)):(e.consume(k),te)}function oe(k){return e.check(lC,de,Z)(k)}function de(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),be}function be(k){return k===null||Le(k)?oe(k):(e.enter("htmlFlowData"),te(k))}function Ie(k){return k===45?(e.consume(k),v):te(k)}function he(k){return k===47?(e.consume(k),u="",G):te(k)}function G(k){if(k===62){const xe=u.toLowerCase();return xg.includes(xe)?(e.consume(k),D):te(k)}return nn(k)&&u.length<8?(e.consume(k),u+=String.fromCharCode(k),G):te(k)}function ie(k){return k===93?(e.consume(k),v):te(k)}function v(k){return k===62?(e.consume(k),D):k===45&&o===2?(e.consume(k),v):te(k)}function D(k){return k===null||Le(k)?(e.exit("htmlFlowData"),Z(k)):(e.consume(k),D)}function Z(k){return e.exit("htmlFlow"),t(k)}}function fC(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 hC(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ms,t,n)}}const pC={name:"htmlText",tokenize:mC};function mC(e,t,n){const r=this;let o,a,u;return c;function c(v){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(v),d}function d(v){return v===33?(e.consume(v),h):v===47?(e.consume(v),Y):v===63?(e.consume(v),I):nn(v)?(e.consume(v),Ee):n(v)}function h(v){return v===45?(e.consume(v),p):v===91?(e.consume(v),a=0,x):nn(v)?(e.consume(v),O):n(v)}function p(v){return v===45?(e.consume(v),T):n(v)}function E(v){return v===null?n(v):v===45?(e.consume(v),b):Le(v)?(u=E,he(v)):(e.consume(v),E)}function b(v){return v===45?(e.consume(v),T):E(v)}function T(v){return v===62?Ie(v):v===45?b(v):E(v)}function x(v){const D="CDATA[";return v===D.charCodeAt(a++)?(e.consume(v),a===D.length?_:x):n(v)}function _(v){return v===null?n(v):v===93?(e.consume(v),S):Le(v)?(u=_,he(v)):(e.consume(v),_)}function S(v){return v===93?(e.consume(v),A):_(v)}function A(v){return v===62?Ie(v):v===93?(e.consume(v),A):_(v)}function O(v){return v===null||v===62?Ie(v):Le(v)?(u=O,he(v)):(e.consume(v),O)}function I(v){return v===null?n(v):v===63?(e.consume(v),z):Le(v)?(u=I,he(v)):(e.consume(v),I)}function z(v){return v===62?Ie(v):I(v)}function Y(v){return nn(v)?(e.consume(v),M):n(v)}function M(v){return v===45||Wt(v)?(e.consume(v),M):Q(v)}function Q(v){return Le(v)?(u=Q,he(v)):Ge(v)?(e.consume(v),Q):Ie(v)}function Ee(v){return v===45||Wt(v)?(e.consume(v),Ee):v===47||v===62||it(v)?re(v):n(v)}function re(v){return v===47?(e.consume(v),Ie):v===58||v===95||nn(v)?(e.consume(v),U):Le(v)?(u=re,he(v)):Ge(v)?(e.consume(v),re):Ie(v)}function U(v){return v===45||v===46||v===58||v===95||Wt(v)?(e.consume(v),U):W(v)}function W(v){return v===61?(e.consume(v),te):Le(v)?(u=W,he(v)):Ge(v)?(e.consume(v),W):re(v)}function te(v){return v===null||v===60||v===61||v===62||v===96?n(v):v===34||v===39?(e.consume(v),o=v,oe):Le(v)?(u=te,he(v)):Ge(v)?(e.consume(v),te):(e.consume(v),de)}function oe(v){return v===o?(e.consume(v),o=void 0,be):v===null?n(v):Le(v)?(u=oe,he(v)):(e.consume(v),oe)}function de(v){return v===null||v===34||v===39||v===60||v===61||v===96?n(v):v===47||v===62||it(v)?re(v):(e.consume(v),de)}function be(v){return v===47||v===62||it(v)?re(v):n(v)}function Ie(v){return v===62?(e.consume(v),e.exit("htmlTextData"),e.exit("htmlText"),t):n(v)}function he(v){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(v),e.exit("lineEnding"),G}function G(v){return Ge(v)?Qe(e,ie,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(v):ie(v)}function ie(v){return e.enter("htmlTextData"),u(v)}}const Fd={name:"labelEnd",resolveAll:TC,resolveTo:bC,tokenize:xC},gC={tokenize:wC},EC={tokenize:_C},yC={tokenize:SC};function TC(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 bC(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,ku(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 xC(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(b){return a?a._inactive?E(b):(u=r.parser.defined.includes(Yn(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),d):n(b)}function d(b){return b===40?e.attempt(gC,p,u?p:E)(b):b===91?e.attempt(EC,p,u?h:E)(b):u?p(b):E(b)}function h(b){return e.attempt(yC,p,E)(b)}function p(b){return t(b)}function E(b){return a._balanced=!0,n(b)}}function wC(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)?Bs(e,a)(E):a(E)}function a(E){return E===41?p(E):yg(e,u,c,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(E)}function u(E){return it(E)?Bs(e,d)(E):p(E)}function c(E){return n(E)}function d(E){return E===34||E===39||E===40?bg(e,h,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(E):p(E)}function h(E){return it(E)?Bs(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 _C(e,t,n){const r=this;return o;function o(c){return Tg.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 SC(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 vC={name:"labelStartImage",resolveAll:Fd.resolveAll,tokenize:AC};function AC(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 CC={name:"labelStartLink",resolveAll:Fd.resolveAll,tokenize:kC};function kC(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 Bd={name:"lineEnding",tokenize:NC};function NC(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Qe(e,t,"linePrefix")}}const Nu={name:"thematicBreak",tokenize:OC};function OC(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:LC},exit:MC,name:"list",tokenize:PC},IC={partial:!0,tokenize:FC},RC={partial:!0,tokenize:DC};function PC(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(T){const x=r.containerState.type||(T===42||T===43||T===45?"listUnordered":"listOrdered");if(x==="listUnordered"?!r.containerState.marker||T===r.containerState.marker:Ld(T)){if(r.containerState.type||(r.containerState.type=x,e.enter(x,{_container:!0})),x==="listUnordered")return e.enter("listItemPrefix"),T===42||T===45?e.check(Nu,n,h)(T):h(T);if(!r.interrupt||T===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),d(T)}return n(T)}function d(T){return Ld(T)&&++u<10?(e.consume(T),d):(!r.interrupt||u<2)&&(r.containerState.marker?T===r.containerState.marker:T===41||T===46)?(e.exit("listItemValue"),h(T)):n(T)}function h(T){return e.enter("listItemMarker"),e.consume(T),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||T,e.check(Ms,r.interrupt?n:p,e.attempt(IC,b,E))}function p(T){return r.containerState.initialBlankLine=!0,a++,b(T)}function E(T){return Ge(T)?(e.enter("listItemPrefixWhitespace"),e.consume(T),e.exit("listItemPrefixWhitespace"),b):n(T)}function b(T){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(T)}}function LC(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Ms,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(RC,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 DC(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 MC(e){e.exit(this.containerState.type)}function FC(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 wg={name:"setextUnderline",resolveTo:BC,tokenize:UC};function BC(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 UC(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 HC={tokenize:zC};function zC(e){const t=this,n=e.attempt(Ms,r,e.attempt(this.parser.constructs.flowInitial,o,Qe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(YA,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 jC={resolveAll:Sg()},$C=_g("string"),VC=_g("text");function _g(e){return{resolveAll:Sg(e==="text"?qC: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 b=-1;if(E)for(;++b<E.length;){const T=E[b];if(!T.previous||T.previous.call(r,r.previous))return!0}return!1}}}function Sg(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 qC(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 YC=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:XA},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:fg},flow:{35:rC,42:Nu,45:[wg,Nu],60:aC,61:wg,95:Nu,96:gg,126:gg},flowInitial:{[-2]:Md,[-1]:Md,32:Md},insideSpan:{null:[Dd,jC]},string:{38:pg,92:hg},text:{[-5]:Bd,[-4]:Bd,[-3]:Bd,33:vC,38:pg,42:Dd,60:[CA,pC],91:CC,92:[tC,hg],93:Fd,95:Dd,96:HA}},Symbol.toStringTag,{value:"Module"}));function WC(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const o={},a=[];let u=[],c=[];const d={attempt:Q(Y),check:Q(M),consume:O,enter:I,exit:z,interrupt:Q(M,{interrupt:!0})},h={code:null,containerState:{},defineSkip:_,events:[],now:x,parser:e,previous:null,sliceSerialize:b,sliceStream:T,write:E};let p=t.tokenize.call(h,d);return t.resolveAll&&a.push(t),h;function E(W){return u=Rn(u,W),S(),u[u.length-1]!==null?[]:(Ee(t,0),h.events=ku(a,h.events,h),h.events)}function b(W,te){return KC(T(W),te)}function T(W){return GC(u,W)}function x(){const{_bufferIndex:W,_index:te,line:oe,column:de,offset:be}=r;return{_bufferIndex:W,_index:te,line:oe,column:de,offset:be}}function _(W){o[W.line]=W.column,U()}function S(){let W;for(;r._index<u.length;){const te=u[r._index];if(typeof te=="string")for(W=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===W&&r._bufferIndex<te.length;)A(te.charCodeAt(r._bufferIndex));else A(te)}}function A(W){p=p(W)}function O(W){Le(W)?(r.line++,r.column=1,r.offset+=W===-3?2:1,U()):W!==-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=W}function I(W,te){const oe=te||{};return oe.type=W,oe.start=x(),h.events.push(["enter",oe,h]),c.push(oe),oe}function z(W){const te=c.pop();return te.end=x(),h.events.push(["exit",te,h]),te}function Y(W,te){Ee(W,te.from)}function M(W,te){te.restore()}function Q(W,te){return oe;function oe(de,be,Ie){let he,G,ie,v;return Array.isArray(de)?Z(de):"tokenize"in de?Z([de]):D(de);function D(Ne){return He;function He(Se){const qe=Se!==null&&Ne[Se],ut=Se!==null&&Ne.null,pn=[...Array.isArray(qe)?qe:qe?[qe]:[],...Array.isArray(ut)?ut:ut?[ut]:[]];return Z(pn)(Se)}}function Z(Ne){return he=Ne,G=0,Ne.length===0?Ie:k(Ne[G])}function k(Ne){return He;function He(Se){return v=re(),ie=Ne,Ne.partial||(h.currentConstruct=Ne),Ne.name&&h.parser.constructs.disable.null.includes(Ne.name)?Pe():Ne.tokenize.call(te?Object.assign(Object.create(h),te):h,d,xe,Pe)(Se)}}function xe(Ne){return W(ie,v),be}function Pe(Ne){return v.restore(),++G<he.length?k(he[G]):Ie}}}function Ee(W,te){W.resolveAll&&!a.includes(W)&&a.push(W),W.resolve&&xn(h.events,te,h.events.length-te,W.resolve(h.events.slice(te),h)),W.resolveTo&&(h.events=W.resolveTo(h.events,h))}function re(){const W=x(),te=h.previous,oe=h.currentConstruct,de=h.events.length,be=Array.from(c);return{from:de,restore:Ie};function Ie(){r=W,h.previous=te,h.currentConstruct=oe,h.events.length=de,c=be,U()}}function U(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function GC(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 KC(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 QC(e){const r={constructs:ug([YC,...(e||{}).extensions||[]]),content:o(bA),defined:[],document:o(wA),flow:o(HC),lazy:{},string:o($C),text:o(VC)};return r;function o(a){return u;function u(c){return WC(r,a,c)}}}function XC(e){for(;!Eg(e););return e}const vg=/[\0\t\n\r]/g;function JC(){let e=1,t="",n=!0,r;return o;function o(a,u,c){const d=[];let h,p,E,b,T;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(vg.lastIndex=E,h=vg.exec(a),b=h&&h.index!==void 0?h.index:a.length,T=a.charCodeAt(b),!h){t=a.slice(E);break}if(T===10&&E===b&&r)d.push(-3),r=void 0;else switch(r&&(d.push(-5),r=void 0),E<b&&(d.push(a.slice(E,b)),e+=b-E),T){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=b+1}return c&&(r&&d.push(-5),t&&d.push(t),d.push(null)),d}}const ZC=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function ek(e){return e.replace(ZC,tk)}function tk(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return lg(n.slice(a?2:1),a?16:10)}return Pd(n)||e}const Ag={}.hasOwnProperty;function nk(e,t,n){return typeof t!="string"&&(n=t,t=void 0),rk(n)(XC(QC(n).document().write(JC()(e,t,!0))))}function rk(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Wo),autolinkProtocol:re,autolinkEmail:re,atxHeading:a(pa),blockQuote:a(ut),characterEscape:re,characterReference:re,codeFenced:a(pn),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(pn,u),codeText:a(qi,u),codeTextData:re,data:re,codeFlowValue:re,definition:a(Jr),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(Xn),hardBreakEscape:a(ma),hardBreakTrailing:a(ma),htmlFlow:a(Yo,u),htmlFlowData:re,htmlText:a(Yo,u),htmlTextData:re,image:a(wl),label:u,link:a(Wo),listItem:a(ei),listItemValue:b,listOrdered:a(Zr,E),listUnordered:a(Zr),paragraph:a(ga),reference:k,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(pa),strong:a(_l),thematicBreak:a(vl)},exit:{atxHeading:d(),atxHeadingSequence:Y,autolink:d(),autolinkEmail:qe,autolinkProtocol:Se,blockQuote:d(),characterEscapeValue:z,characterReferenceMarkerHexadecimal:Pe,characterReferenceMarkerNumeric:Pe,characterReferenceValue:Oe,characterReference:He,codeFenced:d(S),codeFencedFence:_,codeFencedFenceInfo:T,codeFencedFenceMeta:x,codeFlowValue:z,codeIndented:d(A),codeText:d(be),codeTextData:z,data:z,definition:d(),definitionDestinationString:H,definitionLabelString:O,definitionTitleString:I,emphasis:d(),hardBreakEscape:d(te),hardBreakTrailing:d(te),htmlFlow:d(oe),htmlFlowData:z,htmlText:d(de),htmlTextData:z,image:d(me),label:ie,labelText:Q,lineEnding:W,link:d(Ne),listItem:d(),listOrdered:d(),listUnordered:d(),paragraph:d(),referenceString:xe,resourceDestinationString:v,resourceTitleString:D,resource:Z,setextHeading:d(pe),setextHeadingLineSequence:G,setextHeadingText:M,strong:d(),thematicBreak:d()}};Cg(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(ne){let Te={type:"root",children:[]};const Be={stack:[Te],tokenStack:[],config:t,enter:c,exit:h,buffer:u,resume:p,data:n},Ye=[];let Xe=-1;for(;++Xe<ne.length;)if(ne[Xe][1].type==="listOrdered"||ne[Xe][1].type==="listUnordered")if(ne[Xe][0]==="enter")Ye.push(Xe);else{const zt=Ye.pop();Xe=o(ne,zt,Xe)}for(Xe=-1;++Xe<ne.length;){const zt=t[ne[Xe][0]];Ag.call(zt,ne[Xe][1].type)&&zt[ne[Xe][1].type].call(Object.assign({sliceSerialize:ne[Xe][2].sliceSerialize},Be),ne[Xe][1])}if(Be.tokenStack.length>0){const zt=Be.tokenStack[Be.tokenStack.length-1];(zt[1]||kg).call(Be,void 0,zt[0])}for(Te.position={start:qr(ne.length>0?ne[0][1].start:{line:1,column:1,offset:0}),end:qr(ne.length>0?ne[ne.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(ne,Te,Be){let Ye=Te-1,Xe=-1,zt=!1,Ir,Mn,ti,Yi;for(;++Ye<=Be;){const jt=ne[Ye];switch(jt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{jt[0]==="enter"?Xe++:Xe--,Yi=void 0;break}case"lineEndingBlank":{jt[0]==="enter"&&(Ir&&!Yi&&!Xe&&!ti&&(ti=Ye),Yi=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Yi=void 0}if(!Xe&&jt[0]==="enter"&&jt[1].type==="listItemPrefix"||Xe===-1&&jt[0]==="exit"&&(jt[1].type==="listUnordered"||jt[1].type==="listOrdered")){if(Ir){let yr=Ye;for(Mn=void 0;yr--;){const vn=ne[yr];if(vn[1].type==="lineEnding"||vn[1].type==="lineEndingBlank"){if(vn[0]==="exit")continue;Mn&&(ne[Mn][1].type="lineEndingBlank",zt=!0),vn[1].type="lineEnding",Mn=yr}else if(!(vn[1].type==="linePrefix"||vn[1].type==="blockQuotePrefix"||vn[1].type==="blockQuotePrefixWhitespace"||vn[1].type==="blockQuoteMarker"||vn[1].type==="listItemIndent"))break}ti&&(!Mn||ti<Mn)&&(Ir._spread=!0),Ir.end=Object.assign({},Mn?ne[Mn][1].start:jt[1].end),ne.splice(Mn||Ye,0,["exit",Ir,jt[2]]),Ye++,Be++}if(jt[1].type==="listItemPrefix"){const yr={type:"listItem",_spread:!1,start:Object.assign({},jt[1].start),end:void 0};Ir=yr,ne.splice(Ye,0,["enter",yr,jt[2]]),Ye++,Be++,ti=void 0,Yi=!0}}}return ne[Te][1]._spread=zt,Be}function a(ne,Te){return Be;function Be(Ye){c.call(this,ne(Ye),Ye),Te&&Te.call(this,Ye)}}function u(){this.stack.push({type:"fragment",children:[]})}function c(ne,Te,Be){this.stack[this.stack.length-1].children.push(ne),this.stack.push(ne),this.tokenStack.push([Te,Be||void 0]),ne.position={start:qr(Te.start),end:void 0}}function d(ne){return Te;function Te(Be){ne&&ne.call(this,Be),h.call(this,Be)}}function h(ne,Te){const Be=this.stack.pop(),Ye=this.tokenStack.pop();if(Ye)Ye[0].type!==ne.type&&(Te?Te.call(this,ne,Ye[0]):(Ye[1]||kg).call(this,ne,Ye[0]));else throw new Error("Cannot close `"+ne.type+"` ("+Ls({start:ne.start,end:ne.end})+"): it’s not open");Be.position.end=qr(ne.end)}function p(){return Rd(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function b(ne){if(this.data.expectingFirstListItemValue){const Te=this.stack[this.stack.length-2];Te.start=Number.parseInt(this.sliceSerialize(ne),10),this.data.expectingFirstListItemValue=void 0}}function T(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.lang=ne}function x(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.meta=ne}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function S(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function A(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne.replace(/(\r?\n|\r)$/g,"")}function O(ne){const Te=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Te,Be.identifier=Yn(this.sliceSerialize(ne)).toLowerCase()}function I(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.title=ne}function H(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.url=ne}function Y(ne){const Te=this.stack[this.stack.length-1];if(!Te.depth){const Be=this.sliceSerialize(ne).length;Te.depth=Be}}function M(){this.data.setextHeadingSlurpLineEnding=!0}function G(ne){const Te=this.stack[this.stack.length-1];Te.depth=this.sliceSerialize(ne).codePointAt(0)===61?1:2}function pe(){this.data.setextHeadingSlurpLineEnding=void 0}function re(ne){const Be=this.stack[this.stack.length-1].children;let Ye=Be[Be.length-1];(!Ye||Ye.type!=="text")&&(Ye=Sl(),Ye.position={start:qr(ne.start),end:void 0},Be.push(Ye)),this.stack.push(Ye)}function z(ne){const Te=this.stack.pop();Te.value+=this.sliceSerialize(ne),Te.position.end=qr(ne.end)}function W(ne){const Te=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=Te.children[Te.children.length-1];Be.position.end=qr(ne.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(Te.type)&&(re.call(this,ne),z.call(this,ne))}function te(){this.data.atHardBreak=!0}function oe(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne}function de(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne}function be(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne}function Ne(){const ne=this.stack[this.stack.length-1];if(this.data.inReference){const Te=this.data.referenceType||"shortcut";ne.type+="Reference",ne.referenceType=Te,delete ne.url,delete ne.title}else delete ne.identifier,delete ne.label;this.data.referenceType=void 0}function me(){const ne=this.stack[this.stack.length-1];if(this.data.inReference){const Te=this.data.referenceType||"shortcut";ne.type+="Reference",ne.referenceType=Te,delete ne.url,delete ne.title}else delete ne.identifier,delete ne.label;this.data.referenceType=void 0}function Q(ne){const Te=this.sliceSerialize(ne),Be=this.stack[this.stack.length-2];Be.label=ek(Te),Be.identifier=Yn(Te).toLowerCase()}function ie(){const ne=this.stack[this.stack.length-1],Te=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const Ye=ne.children;Be.children=Ye}else Be.alt=Te}function v(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.url=ne}function D(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.title=ne}function Z(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function xe(ne){const Te=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Te,Be.identifier=Yn(this.sliceSerialize(ne)).toLowerCase(),this.data.referenceType="full"}function Pe(ne){this.data.characterReferenceType=ne.type}function Oe(ne){const Te=this.sliceSerialize(ne),Be=this.data.characterReferenceType;let Ye;Be?(Ye=lg(Te,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ye=Pd(Te);const Xe=this.stack[this.stack.length-1];Xe.value+=Ye}function He(ne){const Te=this.stack.pop();Te.position.end=qr(ne.end)}function Se(ne){z.call(this,ne);const Te=this.stack[this.stack.length-1];Te.url=this.sliceSerialize(ne)}function qe(ne){z.call(this,ne);const Te=this.stack[this.stack.length-1];Te.url="mailto:"+this.sliceSerialize(ne)}function ut(){return{type:"blockquote",children:[]}}function pn(){return{type:"code",lang:null,meta:null,value:""}}function qi(){return{type:"inlineCode",value:""}}function Jr(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Xn(){return{type:"emphasis",children:[]}}function pa(){return{type:"heading",depth:0,children:[]}}function ma(){return{type:"break"}}function Yo(){return{type:"html",value:""}}function wl(){return{type:"image",title:null,url:"",alt:null}}function Wo(){return{type:"link",title:null,url:"",children:[]}}function Zr(ne){return{type:"list",ordered:ne.type==="listOrdered",start:null,spread:ne._spread,children:[]}}function ei(ne){return{type:"listItem",spread:ne._spread,checked:null,children:[]}}function ga(){return{type:"paragraph",children:[]}}function _l(){return{type:"strong",children:[]}}function Sl(){return{type:"text",value:""}}function vl(){return{type:"thematicBreak"}}}function qr(e){return{line:e.line,column:e.column,offset:e.offset}}function Cg(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Cg(e,r):ik(e,r)}}function ik(e,t){let n;for(n in t)if(Ag.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 kg(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Ls({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ls({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Ls({start:t.start,end:t.end})+") is still open")}function ok(e){const t=this;t.parser=n;function n(r){return nk(r,se(B(B({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function sk(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 ak(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 QC(e){const r={constructs:ug([YC,...(e||{}).extensions||[]]),content:o(bA),defined:[],document:o(wA),flow:o(HC),lazy:{},string:o($C),text:o(VC)};return r;function o(a){return u;function u(c){return WC(r,a,c)}}}function XC(e){for(;!Eg(e););return e}const vg=/[\0\t\n\r]/g;function JC(){let e=1,t="",n=!0,r;return o;function o(a,u,c){const d=[];let h,p,E,b,T;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(vg.lastIndex=E,h=vg.exec(a),b=h&&h.index!==void 0?h.index:a.length,T=a.charCodeAt(b),!h){t=a.slice(E);break}if(T===10&&E===b&&r)d.push(-3),r=void 0;else switch(r&&(d.push(-5),r=void 0),E<b&&(d.push(a.slice(E,b)),e+=b-E),T){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=b+1}return c&&(r&&d.push(-5),t&&d.push(t),d.push(null)),d}}const ZC=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function ek(e){return e.replace(ZC,tk)}function tk(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),a=o===120||o===88;return lg(n.slice(a?2:1),a?16:10)}return Pd(n)||e}const Ag={}.hasOwnProperty;function nk(e,t,n){return typeof t!="string"&&(n=t,t=void 0),rk(n)(XC(QC(n).document().write(JC()(e,t,!0))))}function rk(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Wo),autolinkProtocol:re,autolinkEmail:re,atxHeading:a(pa),blockQuote:a(ut),characterEscape:re,characterReference:re,codeFenced:a(pn),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(pn,u),codeText:a(qi,u),codeTextData:re,data:re,codeFlowValue:re,definition:a(Jr),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(Xn),hardBreakEscape:a(ma),hardBreakTrailing:a(ma),htmlFlow:a(Yo,u),htmlFlowData:re,htmlText:a(Yo,u),htmlTextData:re,image:a(wl),label:u,link:a(Wo),listItem:a(ei),listItemValue:b,listOrdered:a(Zr,E),listUnordered:a(Zr),paragraph:a(ga),reference:k,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(pa),strong:a(_l),thematicBreak:a(vl)},exit:{atxHeading:d(),atxHeadingSequence:Y,autolink:d(),autolinkEmail:qe,autolinkProtocol:Se,blockQuote:d(),characterEscapeValue:U,characterReferenceMarkerHexadecimal:Pe,characterReferenceMarkerNumeric:Pe,characterReferenceValue:Ne,characterReference:He,codeFenced:d(S),codeFencedFence:_,codeFencedFenceInfo:T,codeFencedFenceMeta:x,codeFlowValue:U,codeIndented:d(A),codeText:d(be),codeTextData:U,data:U,definition:d(),definitionDestinationString:z,definitionLabelString:O,definitionTitleString:I,emphasis:d(),hardBreakEscape:d(te),hardBreakTrailing:d(te),htmlFlow:d(oe),htmlFlowData:U,htmlText:d(de),htmlTextData:U,image:d(he),label:ie,labelText:G,lineEnding:W,link:d(Ie),listItem:d(),listOrdered:d(),listUnordered:d(),paragraph:d(),referenceString:xe,resourceDestinationString:v,resourceTitleString:D,resource:Z,setextHeading:d(Ee),setextHeadingLineSequence:Q,setextHeadingText:M,strong:d(),thematicBreak:d()}};Cg(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(ne){let Te={type:"root",children:[]};const Be={stack:[Te],tokenStack:[],config:t,enter:c,exit:h,buffer:u,resume:p,data:n},Ye=[];let Xe=-1;for(;++Xe<ne.length;)if(ne[Xe][1].type==="listOrdered"||ne[Xe][1].type==="listUnordered")if(ne[Xe][0]==="enter")Ye.push(Xe);else{const zt=Ye.pop();Xe=o(ne,zt,Xe)}for(Xe=-1;++Xe<ne.length;){const zt=t[ne[Xe][0]];Ag.call(zt,ne[Xe][1].type)&&zt[ne[Xe][1].type].call(Object.assign({sliceSerialize:ne[Xe][2].sliceSerialize},Be),ne[Xe][1])}if(Be.tokenStack.length>0){const zt=Be.tokenStack[Be.tokenStack.length-1];(zt[1]||kg).call(Be,void 0,zt[0])}for(Te.position={start:qr(ne.length>0?ne[0][1].start:{line:1,column:1,offset:0}),end:qr(ne.length>0?ne[ne.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(ne,Te,Be){let Ye=Te-1,Xe=-1,zt=!1,Ir,Mn,ti,Yi;for(;++Ye<=Be;){const jt=ne[Ye];switch(jt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{jt[0]==="enter"?Xe++:Xe--,Yi=void 0;break}case"lineEndingBlank":{jt[0]==="enter"&&(Ir&&!Yi&&!Xe&&!ti&&(ti=Ye),Yi=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Yi=void 0}if(!Xe&&jt[0]==="enter"&&jt[1].type==="listItemPrefix"||Xe===-1&&jt[0]==="exit"&&(jt[1].type==="listUnordered"||jt[1].type==="listOrdered")){if(Ir){let yr=Ye;for(Mn=void 0;yr--;){const vn=ne[yr];if(vn[1].type==="lineEnding"||vn[1].type==="lineEndingBlank"){if(vn[0]==="exit")continue;Mn&&(ne[Mn][1].type="lineEndingBlank",zt=!0),vn[1].type="lineEnding",Mn=yr}else if(!(vn[1].type==="linePrefix"||vn[1].type==="blockQuotePrefix"||vn[1].type==="blockQuotePrefixWhitespace"||vn[1].type==="blockQuoteMarker"||vn[1].type==="listItemIndent"))break}ti&&(!Mn||ti<Mn)&&(Ir._spread=!0),Ir.end=Object.assign({},Mn?ne[Mn][1].start:jt[1].end),ne.splice(Mn||Ye,0,["exit",Ir,jt[2]]),Ye++,Be++}if(jt[1].type==="listItemPrefix"){const yr={type:"listItem",_spread:!1,start:Object.assign({},jt[1].start),end:void 0};Ir=yr,ne.splice(Ye,0,["enter",yr,jt[2]]),Ye++,Be++,ti=void 0,Yi=!0}}}return ne[Te][1]._spread=zt,Be}function a(ne,Te){return Be;function Be(Ye){c.call(this,ne(Ye),Ye),Te&&Te.call(this,Ye)}}function u(){this.stack.push({type:"fragment",children:[]})}function c(ne,Te,Be){this.stack[this.stack.length-1].children.push(ne),this.stack.push(ne),this.tokenStack.push([Te,Be||void 0]),ne.position={start:qr(Te.start),end:void 0}}function d(ne){return Te;function Te(Be){ne&&ne.call(this,Be),h.call(this,Be)}}function h(ne,Te){const Be=this.stack.pop(),Ye=this.tokenStack.pop();if(Ye)Ye[0].type!==ne.type&&(Te?Te.call(this,ne,Ye[0]):(Ye[1]||kg).call(this,ne,Ye[0]));else throw new Error("Cannot close `"+ne.type+"` ("+Ls({start:ne.start,end:ne.end})+"): it’s not open");Be.position.end=qr(ne.end)}function p(){return Rd(this.stack.pop())}function E(){this.data.expectingFirstListItemValue=!0}function b(ne){if(this.data.expectingFirstListItemValue){const Te=this.stack[this.stack.length-2];Te.start=Number.parseInt(this.sliceSerialize(ne),10),this.data.expectingFirstListItemValue=void 0}}function T(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.lang=ne}function x(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.meta=ne}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function S(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function A(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne.replace(/(\r?\n|\r)$/g,"")}function O(ne){const Te=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Te,Be.identifier=Yn(this.sliceSerialize(ne)).toLowerCase()}function I(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.title=ne}function z(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.url=ne}function Y(ne){const Te=this.stack[this.stack.length-1];if(!Te.depth){const Be=this.sliceSerialize(ne).length;Te.depth=Be}}function M(){this.data.setextHeadingSlurpLineEnding=!0}function Q(ne){const Te=this.stack[this.stack.length-1];Te.depth=this.sliceSerialize(ne).codePointAt(0)===61?1:2}function Ee(){this.data.setextHeadingSlurpLineEnding=void 0}function re(ne){const Be=this.stack[this.stack.length-1].children;let Ye=Be[Be.length-1];(!Ye||Ye.type!=="text")&&(Ye=Sl(),Ye.position={start:qr(ne.start),end:void 0},Be.push(Ye)),this.stack.push(Ye)}function U(ne){const Te=this.stack.pop();Te.value+=this.sliceSerialize(ne),Te.position.end=qr(ne.end)}function W(ne){const Te=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=Te.children[Te.children.length-1];Be.position.end=qr(ne.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(Te.type)&&(re.call(this,ne),U.call(this,ne))}function te(){this.data.atHardBreak=!0}function oe(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne}function de(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne}function be(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.value=ne}function Ie(){const ne=this.stack[this.stack.length-1];if(this.data.inReference){const Te=this.data.referenceType||"shortcut";ne.type+="Reference",ne.referenceType=Te,delete ne.url,delete ne.title}else delete ne.identifier,delete ne.label;this.data.referenceType=void 0}function he(){const ne=this.stack[this.stack.length-1];if(this.data.inReference){const Te=this.data.referenceType||"shortcut";ne.type+="Reference",ne.referenceType=Te,delete ne.url,delete ne.title}else delete ne.identifier,delete ne.label;this.data.referenceType=void 0}function G(ne){const Te=this.sliceSerialize(ne),Be=this.stack[this.stack.length-2];Be.label=ek(Te),Be.identifier=Yn(Te).toLowerCase()}function ie(){const ne=this.stack[this.stack.length-1],Te=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const Ye=ne.children;Be.children=Ye}else Be.alt=Te}function v(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.url=ne}function D(){const ne=this.resume(),Te=this.stack[this.stack.length-1];Te.title=ne}function Z(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function xe(ne){const Te=this.resume(),Be=this.stack[this.stack.length-1];Be.label=Te,Be.identifier=Yn(this.sliceSerialize(ne)).toLowerCase(),this.data.referenceType="full"}function Pe(ne){this.data.characterReferenceType=ne.type}function Ne(ne){const Te=this.sliceSerialize(ne),Be=this.data.characterReferenceType;let Ye;Be?(Ye=lg(Te,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ye=Pd(Te);const Xe=this.stack[this.stack.length-1];Xe.value+=Ye}function He(ne){const Te=this.stack.pop();Te.position.end=qr(ne.end)}function Se(ne){U.call(this,ne);const Te=this.stack[this.stack.length-1];Te.url=this.sliceSerialize(ne)}function qe(ne){U.call(this,ne);const Te=this.stack[this.stack.length-1];Te.url="mailto:"+this.sliceSerialize(ne)}function ut(){return{type:"blockquote",children:[]}}function pn(){return{type:"code",lang:null,meta:null,value:""}}function qi(){return{type:"inlineCode",value:""}}function Jr(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Xn(){return{type:"emphasis",children:[]}}function pa(){return{type:"heading",depth:0,children:[]}}function ma(){return{type:"break"}}function Yo(){return{type:"html",value:""}}function wl(){return{type:"image",title:null,url:"",alt:null}}function Wo(){return{type:"link",title:null,url:"",children:[]}}function Zr(ne){return{type:"list",ordered:ne.type==="listOrdered",start:null,spread:ne._spread,children:[]}}function ei(ne){return{type:"listItem",spread:ne._spread,checked:null,children:[]}}function ga(){return{type:"paragraph",children:[]}}function _l(){return{type:"strong",children:[]}}function Sl(){return{type:"text",value:""}}function vl(){return{type:"thematicBreak"}}}function qr(e){return{line:e.line,column:e.column,offset:e.offset}}function Cg(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Cg(e,r):ik(e,r)}}function ik(e,t){let n;for(n in t)if(Ag.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 kg(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Ls({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ls({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Ls({start:t.start,end:t.end})+") is still open")}function ok(e){const t=this;t.parser=n;function n(r){return nk(r,se(B(B({},t.data("settings")),e),{extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]}))}}function sk(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 ak(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 uk(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 lk(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function ck(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=Eo(r.toLowerCase()),a=e.footnoteOrder.indexOf(r);let u,c=e.footnoteCounts.get(r);c===void 0?(c=0,e.footnoteOrder.push(r),u=e.footnoteOrder.length):u=a+1,c+=1,e.footnoteCounts.set(r,c);const d={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(c>1?"-"+c:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(u)}]};e.patch(t,d);const h={type:"element",tagName:"sup",properties:{},children:[d]};return e.patch(t,h),e.applyData(t,h)}function fk(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 hk(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function Ng(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 pk(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Ng(e,t);const o={src:Eo(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(o.title=r.title);const a={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,a),e.applyData(t,a)}function mk(e,t){const n={src:Eo(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function gk(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 Ek(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Ng(e,t);const o={href:Eo(r.url||"")};r.title!==null&&r.title!==void 0&&(o.title=r.title);const a={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function yk(e,t){const n={href:Eo(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function Tk(e,t,n){const r=e.all(t),o=n?bk(n):Og(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:`
|
|
@@ -34,8 +34,8 @@ Error generating stack: `+y.message+`
|
|
|
34
34
|
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
|
|
35
35
|
`}),n}function jg(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function $g(e,t){const n=Gk(e,t),r=n.one(e,void 0),o=Bk(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&a.children.push({type:"text",value:`
|
|
36
36
|
`},o),a}function Zk(e,t){return e&&"run"in e?function(n,r){return $e(this,null,function*(){const o=$g(n,B({file:r},t));yield e.run(o,r)})}:function(n,r){return $g(n,B({file:r},e||t))}}function Vg(e){if(e)throw e}var qd,qg;function eN(){if(qg)return qd;qg=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 b;for(b in h);return typeof b=="undefined"||e.call(h,b)},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,b,T,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),b=c(h,p),_!==b&&(O&&b&&(a(b)||(T=o(b)))?(T?(T=!1,x=E&&o(E)?E:[]):x=E&&a(E)?E:{},u(_,{name:p,newValue:d(O,x,b)})):typeof b!="undefined"&&u(_,{name:p,newValue:b}));return _},qd}var tN=eN();const Yd=We(tN);function Wd(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 nN(){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?rN(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 rN(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 ur={basename:iN,dirname:oN,extname:sN,join:aN,sep:"/"};function iN(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');zs(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 oN(e){if(zs(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 sN(e){zs(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 aN(...e){let t=-1,n;for(;++t<e.length;)zs(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":uN(n)}function uN(e){zs(e);const t=e.codePointAt(0)===47;let n=lN(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function lN(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 zs(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const cN={cwd:dN};function dN(){return"/"}function Gd(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function fN(e){if(typeof e=="string")e=new URL(e);else if(!Gd(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 hN(e)}function hN(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 Kd=["history","path","basename","stem","extname","dirname"];class Yg{constructor(t){let n;t?Gd(t)?n={path:t}:typeof t=="string"||pN(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":cN.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<Kd.length;){const a=Kd[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)Kd.includes(o)||(this[o]=n[o])}get basename(){return typeof this.path=="string"?ur.basename(this.path):void 0}set basename(t){Xd(t,"basename"),Qd(t,"basename"),this.path=ur.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?ur.dirname(this.path):void 0}set dirname(t){Wg(this.basename,"dirname"),this.path=ur.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?ur.extname(this.path):void 0}set extname(t){if(Qd(t,"extname"),Wg(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=ur.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Gd(t)&&(t=fN(t)),Xd(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?ur.basename(this.path,this.extname):void 0}set stem(t){Xd(t,"stem"),Qd(t,"stem"),this.path=ur.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const o=this.message(t,n,r);throw o.fatal=!0,o}info(t,n,r){const o=this.message(t,n,r);return o.fatal=void 0,o}message(t,n,r){const o=new Yt(t,n,r);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function Qd(e,t){if(e&&e.includes(ur.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+ur.sep+"`")}function Xd(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Wg(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function pN(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const mN=(function(e){const r=this.constructor.prototype,o=r[e],a=function(){return o.apply(a,arguments)};return Object.setPrototypeOf(a,r),a}),gN={}.hasOwnProperty;class Jd extends mN{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=nN()}copy(){const t=new Jd;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Yd(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(tf("data",this.frozen),this.namespace[t]=n,this):gN.call(this.namespace,t)&&this.namespace[t]||void 0:t?(tf("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=Fu(t),r=this.parser||this.Parser;return Zd("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Zd("process",this.parser||this.Parser),ef("process",this.compiler||this.Compiler),n?o(void 0,n):new Promise(o);function o(a,u){const c=Fu(t),d=r.parse(c);r.run(d,c,function(p,E,b){if(p||!E||!b)return h(p);const T=E,x=r.stringify(T,b);TN(x)?b.value=x:b.result=x,h(p,b)});function h(p,E){p||!E?u(p):a?a(E):n(void 0,E)}}}processSync(t){let n=!1,r;return this.freeze(),Zd("processSync",this.parser||this.Parser),ef("processSync",this.compiler||this.Compiler),this.process(t,o),Kg("processSync","process",n),r;function o(a,u){n=!0,Vg(a),r=u}}run(t,n,r){Gg(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=Fu(n);o.run(t,d,h);function h(p,E,b){const T=E||t;p?c(p):u?u(T):r(void 0,T,b)}}}runSync(t,n){let r=!1,o;return this.run(t,n,a),Kg("runSync","run",r),o;function a(u,c){Vg(u),o=c,r=!0}}stringify(t,n){this.freeze();const r=Fu(n),o=this.compiler||this.Compiler;return ef("stringify",o),Gg(t),o(t,r)}use(t,...n){const r=this.attachers,o=this.namespace;if(tf("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=Yd(!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,b=-1;for(;++E<r.length;)if(r[E][0]===h){b=E;break}if(b===-1)r.push([h,...p]);else if(p.length>0){let[T,...x]=p;const _=r[b][1];Wd(_)&&Wd(T)&&(T=Yd(!0,_,T)),r[b]=[h,T,...x]}}}}const EN=new Jd().freeze();function Zd(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function ef(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function tf(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 Gg(e){if(!Wd(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Kg(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Fu(e){return yN(e)?e:new Yg(e)}function yN(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function TN(e){return typeof e=="string"||bN(e)}function bN(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const xN="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",Qg=[],Xg={allowDangerousHtml:!0},wN=/^(https?|ircs?|mailto|xmpp)$/i,_N=[{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 Jg(e){const t=SN(e),n=vN(e);return AN(t.runSync(t.parse(n),n),e)}function SN(e){const t=e.rehypePlugins||Qg,n=e.remarkPlugins||Qg,r=e.remarkRehypeOptions?B(B({},e.remarkRehypeOptions),Xg):Xg;return EN().use(ok).use(n).use(Zk,r).use(t)}function vN(e){const t=e.children||"",n=new Yg;return typeof t=="string"&&(n.value=t),n}function AN(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,a=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,d=t.urlTransform||CN;for(const p of _N)Object.hasOwn(t,p.from)&&(""+p.from+(p.to?"use `"+p.to+"` instead":"remove it")+xN+p.id,void 0);return Mu(e,h),Xv(e,{Fragment:P.Fragment,components:o,ignoreInvalidStyle:!0,jsx:P.jsx,jsxs:P.jsxs,passKeys:!0,passNode:!0});function h(p,E,b){if(p.type==="raw"&&b&&typeof E=="number")return u?b.children.splice(E,1):b.children[E]={type:"text",value:p.value},E;if(p.type==="element"){let T;for(T in Id)if(Object.hasOwn(Id,T)&&Object.hasOwn(p.properties,T)){const x=p.properties[T],_=Id[T];(_===null||_.includes(p.tagName))&&(p.properties[T]=d(String(x||""),T,p))}}if(p.type==="element"){let T=n?!n.includes(p.tagName):a?a.includes(p.tagName):!1;if(!T&&r&&typeof E=="number"&&(T=!r(p,E,b)),T&&b&&typeof E=="number")return c&&p.children?b.children.splice(E,1,...p.children):b.children.splice(E,1),E}}}function CN(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||wN.test(e.slice(0,t))?e:""}const Zg=/[#.]/g;function kN(e,t){const n=e||"",r={};let o=0,a,u;for(;o<n.length;){Zg.lastIndex=o;const c=Zg.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 e1(e,t,n){const r=n?RN(n):void 0;function o(a,u,...c){let d;if(a==null){d={type:"root",children:[]};const h=u;c.unshift(h)}else{d=kN(a,t);const h=d.tagName.toLowerCase(),p=r?r.get(h):void 0;if(d.tagName=p||h,NN(u))c.unshift(u);else for(const[E,b]of Object.entries(u))ON(e,d.properties,E,b)}for(const h of c)nf(d.children,h);return d.type==="element"&&d.tagName==="template"&&(d.content={type:"root",children:d.children},d.children=[]),d}return o}function NN(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 ON(e,t,n,r){const o=vd(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=V0(r):o.commaSeparated?a=I0(r):o.commaOrSpaceSeparated?a=V0(I0(r).join(" ")):a=t1(o,o.property,r):Array.isArray(r)?a=[...r]:a=o.property==="style"?IN(r):String(r);if(Array.isArray(a)){const u=[];for(const c of a)u.push(t1(o,o.property,c));a=u}o.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[o.property]=a}}function nf(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)nf(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?nf(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function t1(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||Is(n)===Is(t)))return!0}return n}function IN(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function RN(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const PN=["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"],LN=e1(Su,"div"),DN=e1(mo,"g",PN);function MN(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=n1(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=n1(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 n1(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
|
|
37
|
-
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ri={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},r1={}.hasOwnProperty,FN=Object.prototype;function BN(e,t){const n=t||{};return rf({file:n.file||void 0,location:!1,schema:n.space==="svg"?mo:Su,verbose:n.verbose||!1},e)}function rf(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Bu(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:i1(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const a=String(e.file),u=MN(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"},Bu(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Bu(e,r,n),n}default:return n=UN(e,t),n}}function i1(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=rf(e,t[n]);r.push(o)}return r}function UN(e,t){const n=e.schema;e.schema=t.namespaceURI===Ri.svg?mo:Su;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],d=(c.prefix?c.prefix+":":"")+c.name;r1.call(FN,d)||(o[d]=c.value)}const u=(e.schema.space==="svg"?DN:LN)(t.tagName,o,i1(e,t.childNodes));if(Bu(e,t,u),u.tagName==="template"){const c=t,d=c.sourceCodeLocation,h=d&&d.startTag&&bo(d.startTag),p=d&&d.endTag&&bo(d.endTag),E=rf(e,c.content);h&&p&&e.file&&(E.position={start:h.end,end:p.start}),u.content=E}return e.schema=n,u}function Bu(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=HN(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function HN(e,t,n){const r=bo(n);if(t.type==="element"){const o=t.children[t.children.length-1];if(r&&!n.endTag&&o&&o.position&&o.position.end&&(r.end=Object.assign({},o.position.end)),e.verbose){const a={};let u;if(n.attrs)for(u in n.attrs)r1.call(n.attrs,u)&&(a[vd(e.schema,u).property]=bo(n.attrs[u]));n.startTag;const c=bo(n.startTag),d=n.endTag?bo(n.endTag):void 0,h={opening:c};d&&(h.closing=d),h.properties=a,t.data={position:h}}}return r}function bo(e){const t=o1({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=o1({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function o1(e){return e.line&&e.column?e:void 0}class js{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}js.prototype.property={},js.prototype.normal={},js.prototype.space=null;function s1(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 js(n,r,t)}function of(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 zN=0;const ze=Pi(),At=Pi(),a1=Pi(),Ee=Pi(),st=Pi(),xo=Pi(),wn=Pi();function Pi(){return Za(2,++zN)}const sf=Object.freeze(Object.defineProperty({__proto__:null,boolean:ze,booleanish:At,commaOrSpaceSeparated:wn,commaSeparated:xo,number:Ee,overloadedBoolean:a1,spaceSeparated:st},Symbol.toStringTag,{value:"Module"})),af=Object.keys(sf);class uf extends Pn{constructor(t,n,r,o){let a=-1;if(super(t,n),u1(this,"space",o),typeof r=="number")for(;++a<af.length;){const u=af[a];u1(this,af[a],(r&sf[u])===sf[u])}}}uf.prototype.defined=!0;function u1(e,t,n){n&&(e[t]=n)}const jN={}.hasOwnProperty;function wo(e){const t={},n={};let r;for(r in e.properties)if(jN.call(e.properties,r)){const o=e.properties[r],a=new uf(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[of(r)]=r,n[of(a.attribute)]=r}return new js(t,n,e.space)}const l1=wo({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}}),c1=wo({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function d1(e,t){return t in e?e[t]:t}function f1(e,t){return d1(e,t.toLowerCase())}const h1=wo({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:f1,properties:{xmlns:null,xmlnsXLink:null}}),p1=wo({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:At,ariaAutoComplete:null,ariaBusy:At,ariaChecked:At,ariaColCount:Ee,ariaColIndex:Ee,ariaColSpan:Ee,ariaControls:st,ariaCurrent:null,ariaDescribedBy:st,ariaDetails:null,ariaDisabled:At,ariaDropEffect:st,ariaErrorMessage:null,ariaExpanded:At,ariaFlowTo:st,ariaGrabbed:At,ariaHasPopup:null,ariaHidden:At,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:st,ariaLevel:Ee,ariaLive:null,ariaModal:At,ariaMultiLine:At,ariaMultiSelectable:At,ariaOrientation:null,ariaOwns:st,ariaPlaceholder:null,ariaPosInSet:Ee,ariaPressed:At,ariaReadOnly:At,ariaRelevant:null,ariaRequired:At,ariaRoleDescription:st,ariaRowCount:Ee,ariaRowIndex:Ee,ariaRowSpan:Ee,ariaSelected:At,ariaSetSize:Ee,ariaSort:null,ariaValueMax:Ee,ariaValueMin:Ee,ariaValueNow:Ee,ariaValueText:null,role:null}}),$N=wo({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:f1,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:xo,acceptCharset:st,accessKey:st,action:null,allow:null,allowFullScreen:ze,allowPaymentRequest:ze,allowUserMedia:ze,alt:null,as:null,async:ze,autoCapitalize:null,autoComplete:st,autoFocus:ze,autoPlay:ze,blocking:st,capture:null,charSet:null,checked:ze,cite:null,className:st,cols:Ee,colSpan:null,content:null,contentEditable:At,controls:ze,controlsList:st,coords:Ee|xo,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ze,defer:ze,dir:null,dirName:null,disabled:ze,download:a1,draggable:At,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:At,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:At,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:At,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}}),VN=wo({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:d1,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:xo,g2:xo,glyphName:xo,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}}),qN=/^data[-\w.:]+$/i,m1=/-[a-z]/g,YN=/[A-Z]/g;function WN(e,t){const n=of(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"&&qN.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(m1,KN);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!m1.test(a)){let u=a.replace(YN,GN);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=uf}return new o(r,t)}function GN(e){return"-"+e.toLowerCase()}function KN(e){return e.charAt(1).toUpperCase()}const QN=s1([c1,l1,h1,p1,$N],"html"),g1=s1([c1,l1,h1,p1,VN],"svg"),E1={}.hasOwnProperty;function y1(e,t){const n=t||{};function r(o,...a){let u=r.invalid;const c=r.handlers;if(o&&E1.call(o,e)){const d=String(o[e]);u=E1.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={},JN={}.hasOwnProperty,T1=y1("type",{handlers:{root:e3,element:o3,text:r3,comment:i3,doctype:n3}});function ZN(e,t){const r=(t||XN).space;return T1(e,r==="svg"?g1:QN)}function e3(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=lf(e.children,n,t),_o(e,n),n}function t3(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=lf(e.children,n,t),_o(e,n),n}function n3(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return _o(e,t),t}function r3(e){const t={nodeName:"#text",value:e.value,parentNode:null};return _o(e,t),t}function i3(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return _o(e,t),t}function o3(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=g1);const o=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&JN.call(e.properties,a)){const d=s3(r,a,e.properties[a]);d&&o.push(d)}}const u=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Ri[u],childNodes:[],parentNode:null};return c.childNodes=lf(e.children,c,r),_o(e,c),e.tagName==="template"&&e.content&&(c.content=t3(e.content,r)),c}function s3(e,t,n){const r=WN(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?R0(n):q0(n));const o={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=o.name.indexOf(":");a<0?o.prefix="":(o.name=o.name.slice(a+1),o.prefix=r.attribute.slice(0,a)),o.namespace=Ri[r.space]}return o}function lf(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const a=T1(e[r],n);a.parentNode=t,o.push(a)}return o}function _o(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 a3=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],u3=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 C;(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"})(C||(C={}));const fn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function b1(e){return e>=55296&&e<=57343}function l3(e){return e>=56320&&e<=57343}function c3(e,t){return(e-55296)*1024+9216+t}function x1(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function w1(e){return e>=64976&&e<=65007||u3.has(e)}var J;(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"})(J||(J={}));const d3=65536;class f3{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=d3,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(l3(n))return this.pos++,this._addGap(),c3(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,C.EOF;return this._err(J.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,C.EOF;const r=this.html.charCodeAt(n);return r===C.CARRIAGE_RETURN?C.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,C.EOF;let t=this.html.charCodeAt(this.pos);return t===C.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,C.LINE_FEED):t===C.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,b1(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===C.LINE_FEED||t===C.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){x1(t)?this._err(J.controlCharacterInInputStream):w1(t)&&this._err(J.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 _1(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 h3=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୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢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;怳Ādpuct;戏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ǣጓ\0y;䐎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Ā;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀ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Ā;elƀ;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\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»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ↄⅪ←ٖ↛ǰ↉\0proø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;䅓Ācrir;榿;쀀𝔬ͯ\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\0m;櫳;櫽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))),p3=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 m3(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=p3.get(e))!==null&&t!==void 0?t:e}var Lt;(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"})(Lt||(Lt={}));const g3=32;var Yr;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Yr||(Yr={}));function cf(e){return e>=Lt.ZERO&&e<=Lt.NINE}function E3(e){return e>=Lt.UPPER_A&&e<=Lt.UPPER_F||e>=Lt.LOWER_A&&e<=Lt.LOWER_F}function y3(e){return e>=Lt.UPPER_A&&e<=Lt.UPPER_Z||e>=Lt.LOWER_A&&e<=Lt.LOWER_Z||cf(e)}function T3(e){return e===Lt.EQUALS||y3(e)}var Dt;(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"})(Dt||(Dt={}));var vr;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(vr||(vr={}));class b3{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Dt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=vr.Strict}startEntity(t){this.decodeMode=t,this.state=Dt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Dt.EntityStart:return t.charCodeAt(n)===Lt.NUM?(this.state=Dt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Dt.NamedEntity,this.stateNamedEntity(t,n));case Dt.NumericStart:return this.stateNumericStart(t,n);case Dt.NumericDecimal:return this.stateNumericDecimal(t,n);case Dt.NumericHex:return this.stateNumericHex(t,n);case Dt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|g3)===Lt.LOWER_X?(this.state=Dt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Dt.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(cf(o)||E3(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(cf(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===Lt.SEMI)this.consumed+=1;else if(this.decodeMode===vr.Strict)return 0;return this.emitCodePoint(m3(this.result),this.consumed),this.errors&&(t!==Lt.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const u=t.charCodeAt(n);if(this.treeIndex=x3(r,o,this.treeIndex+Math.max(1,a),u),this.treeIndex<0)return this.result===0||this.decodeMode===vr.Attribute&&(a===0||T3(u))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14,a!==0){if(u===Lt.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==vr.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,o=(r[n]&Yr.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,o,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:o}=this;return this.emitCodePoint(n===1?o[t]&~Yr.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Dt.NamedEntity:return this.result!==0&&(this.decodeMode!==vr.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Dt.NumericDecimal:return this.emitNumericEntity(0,2);case Dt.NumericHex:return this.emitNumericEntity(0,3);case Dt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Dt.EntityStart:return 0}}}function x3(e,t,n,r){const o=(t&Yr.BRANCH_LENGTH)>>7,a=t&Yr.JUMP_TABLE;if(o===0)return a!==0&&r===a?n:-1;if(a){const d=r-a;return d<0||d>=o?-1:e[n+d]-1}let u=n,c=u+o-1;for(;u<=c;){const d=u+c>>>1,h=e[d];if(h<r)u=d+1;else if(h>r)c=d-1;else return e[d+o]}return-1}var 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 Li;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Li||(Li={}));var Ln;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Ln||(Ln={}));var V;(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"})(V||(V={}));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 w3=new Map([[V.A,m.A],[V.ADDRESS,m.ADDRESS],[V.ANNOTATION_XML,m.ANNOTATION_XML],[V.APPLET,m.APPLET],[V.AREA,m.AREA],[V.ARTICLE,m.ARTICLE],[V.ASIDE,m.ASIDE],[V.B,m.B],[V.BASE,m.BASE],[V.BASEFONT,m.BASEFONT],[V.BGSOUND,m.BGSOUND],[V.BIG,m.BIG],[V.BLOCKQUOTE,m.BLOCKQUOTE],[V.BODY,m.BODY],[V.BR,m.BR],[V.BUTTON,m.BUTTON],[V.CAPTION,m.CAPTION],[V.CENTER,m.CENTER],[V.CODE,m.CODE],[V.COL,m.COL],[V.COLGROUP,m.COLGROUP],[V.DD,m.DD],[V.DESC,m.DESC],[V.DETAILS,m.DETAILS],[V.DIALOG,m.DIALOG],[V.DIR,m.DIR],[V.DIV,m.DIV],[V.DL,m.DL],[V.DT,m.DT],[V.EM,m.EM],[V.EMBED,m.EMBED],[V.FIELDSET,m.FIELDSET],[V.FIGCAPTION,m.FIGCAPTION],[V.FIGURE,m.FIGURE],[V.FONT,m.FONT],[V.FOOTER,m.FOOTER],[V.FOREIGN_OBJECT,m.FOREIGN_OBJECT],[V.FORM,m.FORM],[V.FRAME,m.FRAME],[V.FRAMESET,m.FRAMESET],[V.H1,m.H1],[V.H2,m.H2],[V.H3,m.H3],[V.H4,m.H4],[V.H5,m.H5],[V.H6,m.H6],[V.HEAD,m.HEAD],[V.HEADER,m.HEADER],[V.HGROUP,m.HGROUP],[V.HR,m.HR],[V.HTML,m.HTML],[V.I,m.I],[V.IMG,m.IMG],[V.IMAGE,m.IMAGE],[V.INPUT,m.INPUT],[V.IFRAME,m.IFRAME],[V.KEYGEN,m.KEYGEN],[V.LABEL,m.LABEL],[V.LI,m.LI],[V.LINK,m.LINK],[V.LISTING,m.LISTING],[V.MAIN,m.MAIN],[V.MALIGNMARK,m.MALIGNMARK],[V.MARQUEE,m.MARQUEE],[V.MATH,m.MATH],[V.MENU,m.MENU],[V.META,m.META],[V.MGLYPH,m.MGLYPH],[V.MI,m.MI],[V.MO,m.MO],[V.MN,m.MN],[V.MS,m.MS],[V.MTEXT,m.MTEXT],[V.NAV,m.NAV],[V.NOBR,m.NOBR],[V.NOFRAMES,m.NOFRAMES],[V.NOEMBED,m.NOEMBED],[V.NOSCRIPT,m.NOSCRIPT],[V.OBJECT,m.OBJECT],[V.OL,m.OL],[V.OPTGROUP,m.OPTGROUP],[V.OPTION,m.OPTION],[V.P,m.P],[V.PARAM,m.PARAM],[V.PLAINTEXT,m.PLAINTEXT],[V.PRE,m.PRE],[V.RB,m.RB],[V.RP,m.RP],[V.RT,m.RT],[V.RTC,m.RTC],[V.RUBY,m.RUBY],[V.S,m.S],[V.SCRIPT,m.SCRIPT],[V.SEARCH,m.SEARCH],[V.SECTION,m.SECTION],[V.SELECT,m.SELECT],[V.SOURCE,m.SOURCE],[V.SMALL,m.SMALL],[V.SPAN,m.SPAN],[V.STRIKE,m.STRIKE],[V.STRONG,m.STRONG],[V.STYLE,m.STYLE],[V.SUB,m.SUB],[V.SUMMARY,m.SUMMARY],[V.SUP,m.SUP],[V.TABLE,m.TABLE],[V.TBODY,m.TBODY],[V.TEMPLATE,m.TEMPLATE],[V.TEXTAREA,m.TEXTAREA],[V.TFOOT,m.TFOOT],[V.TD,m.TD],[V.TH,m.TH],[V.THEAD,m.THEAD],[V.TITLE,m.TITLE],[V.TR,m.TR],[V.TRACK,m.TRACK],[V.TT,m.TT],[V.U,m.U],[V.UL,m.UL],[V.SVG,m.SVG],[V.VAR,m.VAR],[V.WBR,m.WBR],[V.XMP,m.XMP]]);function So(e){var t;return(t=w3.get(e))!==null&&t!==void 0?t:m.UNKNOWN}const fe=m,_3={[le.HTML]:new Set([fe.ADDRESS,fe.APPLET,fe.AREA,fe.ARTICLE,fe.ASIDE,fe.BASE,fe.BASEFONT,fe.BGSOUND,fe.BLOCKQUOTE,fe.BODY,fe.BR,fe.BUTTON,fe.CAPTION,fe.CENTER,fe.COL,fe.COLGROUP,fe.DD,fe.DETAILS,fe.DIR,fe.DIV,fe.DL,fe.DT,fe.EMBED,fe.FIELDSET,fe.FIGCAPTION,fe.FIGURE,fe.FOOTER,fe.FORM,fe.FRAME,fe.FRAMESET,fe.H1,fe.H2,fe.H3,fe.H4,fe.H5,fe.H6,fe.HEAD,fe.HEADER,fe.HGROUP,fe.HR,fe.HTML,fe.IFRAME,fe.IMG,fe.INPUT,fe.LI,fe.LINK,fe.LISTING,fe.MAIN,fe.MARQUEE,fe.MENU,fe.META,fe.NAV,fe.NOEMBED,fe.NOFRAMES,fe.NOSCRIPT,fe.OBJECT,fe.OL,fe.P,fe.PARAM,fe.PLAINTEXT,fe.PRE,fe.SCRIPT,fe.SECTION,fe.SELECT,fe.SOURCE,fe.STYLE,fe.SUMMARY,fe.TABLE,fe.TBODY,fe.TD,fe.TEMPLATE,fe.TEXTAREA,fe.TFOOT,fe.TH,fe.THEAD,fe.TITLE,fe.TR,fe.TRACK,fe.UL,fe.WBR,fe.XMP]),[le.MATHML]:new Set([fe.MI,fe.MO,fe.MN,fe.MS,fe.MTEXT,fe.ANNOTATION_XML]),[le.SVG]:new Set([fe.TITLE,fe.FOREIGN_OBJECT,fe.DESC]),[le.XLINK]:new Set,[le.XML]:new Set,[le.XMLNS]:new Set},df=new Set([fe.H1,fe.H2,fe.H3,fe.H4,fe.H5,fe.H6]);V.STYLE,V.SCRIPT,V.XMP,V.IFRAME,V.NOEMBED,V.NOFRAMES,V.PLAINTEXT;var N;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(N||(N={}));const xt={DATA:N.DATA,RCDATA:N.RCDATA,RAWTEXT:N.RAWTEXT,SCRIPT_DATA:N.SCRIPT_DATA,PLAINTEXT:N.PLAINTEXT,CDATA_SECTION:N.CDATA_SECTION};function S3(e){return e>=C.DIGIT_0&&e<=C.DIGIT_9}function $s(e){return e>=C.LATIN_CAPITAL_A&&e<=C.LATIN_CAPITAL_Z}function v3(e){return e>=C.LATIN_SMALL_A&&e<=C.LATIN_SMALL_Z}function Wr(e){return v3(e)||$s(e)}function S1(e){return Wr(e)||S3(e)}function Uu(e){return e+32}function v1(e){return e===C.SPACE||e===C.LINE_FEED||e===C.TABULATION||e===C.FORM_FEED}function A1(e){return v1(e)||e===C.SOLIDUS||e===C.GREATER_THAN_SIGN}function A3(e){return e===C.NULL?J.nullCharacterReference:e>1114111?J.characterReferenceOutsideUnicodeRange:b1(e)?J.surrogateCharacterReference:w1(e)?J.noncharacterCharacterReference:x1(e)||e===C.CARRIAGE_RETURN?J.controlCharacterReference:null}class C3{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=N.DATA,this.returnState=N.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new f3(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new b3(h3,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(J.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(J.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=A3(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(_1(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(J.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=So(t.tagName),t.type===Ve.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(J.endTagWithAttributes),t.selfClosing&&this._err(J.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=v1(t)?Ve.WHITESPACE_CHARACTER:t===C.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=N.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?vr.Attribute:vr.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===N.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case N.DATA:{this._stateData(t);break}case N.RCDATA:{this._stateRcdata(t);break}case N.RAWTEXT:{this._stateRawtext(t);break}case N.SCRIPT_DATA:{this._stateScriptData(t);break}case N.PLAINTEXT:{this._statePlaintext(t);break}case N.TAG_OPEN:{this._stateTagOpen(t);break}case N.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case N.TAG_NAME:{this._stateTagName(t);break}case N.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case N.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case N.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case N.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case N.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case N.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case N.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case N.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case N.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case N.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case N.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case N.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case N.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case N.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case N.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case N.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case N.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case N.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case N.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case N.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case N.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case N.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case N.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case N.BOGUS_COMMENT:{this._stateBogusComment(t);break}case N.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case N.COMMENT_START:{this._stateCommentStart(t);break}case N.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case N.COMMENT:{this._stateComment(t);break}case N.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case N.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case N.COMMENT_END:{this._stateCommentEnd(t);break}case N.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case N.DOCTYPE:{this._stateDoctype(t);break}case N.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case N.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case N.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case N.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case N.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case N.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case N.CDATA_SECTION:{this._stateCdataSection(t);break}case N.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case N.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case N.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case N.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case C.LESS_THAN_SIGN:{this.state=N.TAG_OPEN;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitCodePoint(t);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case C.AMPERSAND:{this._startCharacterReference();break}case C.LESS_THAN_SIGN:{this.state=N.RCDATA_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case C.LESS_THAN_SIGN:{this.state=N.RAWTEXT_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Wr(t))this._createStartTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case C.EXCLAMATION_MARK:{this.state=N.MARKUP_DECLARATION_OPEN;break}case C.SOLIDUS:{this.state=N.END_TAG_OPEN;break}case C.QUESTION_MARK:{this._err(J.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t);break}case C.EOF:{this._err(J.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(J.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=N.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Wr(t))this._createEndTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case C.GREATER_THAN_SIGN:{this._err(J.missingEndTagName),this.state=N.DATA;break}case C.EOF:{this._err(J.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(J.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_ATTRIBUTE_NAME;break}case C.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.tagName+=ft;break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint($s(t)?Uu(t):t)}}_stateRcdataLessThanSign(t){t===C.SOLIDUS?this.state=N.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Wr(t)?(this.state=N.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=N.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=N.BEFORE_ATTRIBUTE_NAME,!1;case C.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=N.SELF_CLOSING_START_TAG,!1;case C.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=N.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===C.SOLIDUS?this.state=N.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Wr(t)?(this.state=N.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case C.SOLIDUS:{this.state=N.SCRIPT_DATA_END_TAG_OPEN;break}case C.EXCLAMATION_MARK:{this.state=N.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=N.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===C.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===C.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case C.HYPHEN_MINUS:{this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case C.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===C.SOLIDUS?this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Wr(t)?(this._emitChars("<"),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&A1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case C.HYPHEN_MINUS:{this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case C.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===C.SOLIDUS?(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&A1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.SOLIDUS:case C.GREATER_THAN_SIGN:case C.EOF:{this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case C.EQUALS_SIGN:{this._err(J.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=N.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:case C.SOLIDUS:case C.GREATER_THAN_SIGN:case C.EOF:{this._leaveAttrName(),this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case C.EQUALS_SIGN:{this._leaveAttrName(),this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case C.QUOTATION_MARK:case C.APOSTROPHE:case C.LESS_THAN_SIGN:{this._err(J.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.name+=ft;break}default:this.currentAttr.name+=String.fromCodePoint($s(t)?Uu(t):t)}}_stateAfterAttributeName(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case C.EQUALS_SIGN:{this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.QUOTATION_MARK:{this.state=N.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this.state=N.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingAttributeValue),this.state=N.DATA,this.emitCurrentTagToken();break}default:this.state=N.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case C.QUOTATION_MARK:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case C.APOSTROPHE:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case C.QUOTATION_MARK:case C.APOSTROPHE:case C.LESS_THAN_SIGN:case C.EQUALS_SIGN:case C.GRAVE_ACCENT:{this._err(J.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case C.SOLIDUS:{this._leaveAttrValue(),this.state=N.SELF_CLOSING_START_TAG;break}case C.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this._err(J.missingWhitespaceBetweenAttributes),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case C.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=N.DATA,this.emitCurrentTagToken();break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this._err(J.unexpectedSolidusInTag),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case C.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.data+=ft;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(fn.DASH_DASH,!0)?(this._createCommentToken(fn.DASH_DASH.length+1),this.state=N.COMMENT_START):this._consumeSequenceIfMatch(fn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(fn.DOCTYPE.length+1),this.state=N.DOCTYPE):this._consumeSequenceIfMatch(fn.CDATA_START,!0)?this.inForeignNode?this.state=N.CDATA_SECTION:(this._err(J.cdataInHtmlContent),this._createCommentToken(fn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=N.BOGUS_COMMENT):this._ensureHibernation()||(this._err(J.incorrectlyOpenedComment),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_START_DASH;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptClosingOfEmptyComment),this.state=N.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptClosingOfEmptyComment),this.state=N.DATA,this.emitCurrentComment(n);break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_END_DASH;break}case C.LESS_THAN_SIGN:{n.data+="<",this.state=N.COMMENT_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.data+=ft;break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case C.EXCLAMATION_MARK:{n.data+="!",this.state=N.COMMENT_LESS_THAN_SIGN_BANG;break}case C.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===C.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=N.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===C.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=N.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==C.GREATER_THAN_SIGN&&t!==C.EOF&&this._err(J.nestedComment),this.state=N.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case C.EXCLAMATION_MARK:{this.state=N.COMMENT_END_BANG;break}case C.HYPHEN_MINUS:{n.data+="-";break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{n.data+="--!",this.state=N.COMMENT_END_DASH;break}case C.GREATER_THAN_SIGN:{this._err(J.incorrectlyClosedComment),this.state=N.DATA,this.emitCurrentComment(n);break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=N.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_NAME;break}case C.GREATER_THAN_SIGN:{this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case C.EOF:{this._err(J.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingWhitespaceBeforeDoctypeName),this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if($s(t))this._createDoctypeToken(String.fromCharCode(Uu(t))),this.state=N.DOCTYPE_NAME;else switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.NULL:{this._err(J.unexpectedNullCharacter),this._createDoctypeToken(ft),this.state=N.DOCTYPE_NAME;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=N.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.AFTER_DOCTYPE_NAME;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.name+=ft;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint($s(t)?Uu(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(fn.PUBLIC,!1)?this.state=N.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(fn.SYSTEM,!1)?this.state=N.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(J.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case C.QUOTATION_MARK:{this._err(J.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this._err(J.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.QUOTATION_MARK:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case C.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.publicId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.publicId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.QUOTATION_MARK:{this._err(J.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this._err(J.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case C.QUOTATION_MARK:{this._err(J.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this._err(J.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case C.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.systemId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.systemId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case C.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.NULL:{this._err(J.unexpectedNullCharacter);break}case C.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case C.RIGHT_SQUARE_BRACKET:{this.state=N.CDATA_SECTION_BRACKET;break}case C.EOF:{this._err(J.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===C.RIGHT_SQUARE_BRACKET?this.state=N.CDATA_SECTION_END:(this._emitChars("]"),this.state=N.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case C.GREATER_THAN_SIGN:{this.state=N.DATA;break}case C.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=N.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(C.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&S1(this.preprocessor.peek(1))?N.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){S1(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===C.SEMICOLON&&this._err(J.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const C1=new Set([m.DD,m.DT,m.LI,m.OPTGROUP,m.OPTION,m.P,m.RB,m.RP,m.RT,m.RTC]),k1=new Set([...C1,m.CAPTION,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]),Hu=new Set([m.APPLET,m.CAPTION,m.HTML,m.MARQUEE,m.OBJECT,m.TABLE,m.TD,m.TEMPLATE,m.TH]),k3=new Set([...Hu,m.OL,m.UL]),N3=new Set([...Hu,m.BUTTON]),N1=new Set([m.ANNOTATION_XML,m.MI,m.MN,m.MO,m.MS,m.MTEXT]),O1=new Set([m.DESC,m.FOREIGN_OBJECT,m.TITLE]),O3=new Set([m.TR,m.TEMPLATE,m.HTML]),I3=new Set([m.TBODY,m.TFOOT,m.THEAD,m.TEMPLATE,m.HTML]),R3=new Set([m.TABLE,m.TEMPLATE,m.HTML]),P3=new Set([m.TD,m.TH]);class L3{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(df,le.HTML)}popUntilTableCellPopped(){this.popUntilPopped(P3,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(R3,le.HTML)}clearBackToTableBodyContext(){this.clearBackTo(I3,le.HTML)}clearBackToTableRowContext(){this.clearBackTo(O3,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(O1.has(o))return!1;break}case le.MATHML:{if(N1.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Hu)}hasInListItemScope(t){return this.hasInDynamicScope(t,k3)}hasInButtonScope(t){return this.hasInDynamicScope(t,N3)}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(df.has(n))return!0;if(Hu.has(n))return!1;break}case le.SVG:{if(O1.has(n))return!1;break}case le.MATHML:{if(N1.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&&C1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&k1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&k1.has(this.currentTagId);)this.pop()}}const ff=3;var lr;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(lr||(lr={}));const I1={type:lr.Marker};class D3{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],o=n.length,a=this.treeAdapter.getTagName(t),u=this.treeAdapter.getNamespaceURI(t);for(let c=0;c<this.entries.length;c++){const d=this.entries[c];if(d.type===lr.Marker)break;const{element:h}=d;if(this.treeAdapter.getTagName(h)===a&&this.treeAdapter.getNamespaceURI(h)===u){const p=this.treeAdapter.getAttrList(h);p.length===o&&r.push({idx:c,attrs:p})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<ff)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<ff)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>=ff&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(I1)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:lr.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:lr.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(I1);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===lr.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===lr.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===lr.Element&&n.element===t)}}const Gr={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};Gr.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(Gr.isTextNode(n)){n.value+=t;return}}Gr.appendChild(e,Gr.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Gr.isTextNode(r)?r.value+=t:Gr.insertBefore(e,Gr.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)}},R1="html",M3="about:legacy-compat",F3="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",P1=["+//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//"],B3=[...P1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],U3=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),L1=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],H3=[...L1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function D1(e,t){return t.some(n=>e.startsWith(n))}function z3(e){return e.name===R1&&e.publicId===null&&(e.systemId===null||e.systemId===M3)}function j3(e){if(e.name!==R1)return Ln.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===F3)return Ln.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),U3.has(n))return Ln.QUIRKS;let r=t===null?B3:P1;if(D1(n,r))return Ln.QUIRKS;if(r=t===null?L1:H3,D1(n,r))return Ln.LIMITED_QUIRKS}return Ln.NO_QUIRKS}const M1={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},$3="definitionurl",V3="definitionURL",q3=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])),Y3=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}]]),W3=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])),G3=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 K3(e){const t=e.tagID;return t===m.FONT&&e.attrs.some(({name:r})=>r===Li.COLOR||r===Li.SIZE||r===Li.FACE)||G3.has(t)}function F1(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===$3){e.attrs[t].name=V3;break}}function B1(e){for(let t=0;t<e.attrs.length;t++){const n=q3.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function hf(e){for(let t=0;t<e.attrs.length;t++){const n=Y3.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 Q3(e){const t=W3.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=So(e.tagName))}function X3(e,t){return t===le.MATHML&&(e===m.MI||e===m.MO||e===m.MN||e===m.MS||e===m.MTEXT)}function J3(e,t,n){if(t===le.MATHML&&e===m.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Li.ENCODING){const o=n[r].value.toLowerCase();return o===M1.TEXT_HTML||o===M1.APPLICATION_XML}}return t===le.SVG&&(e===m.FOREIGN_OBJECT||e===m.DESC||e===m.TITLE)}function Z3(e,t,n,r){return(!r||r===le.HTML)&&J3(e,t,n)||(!r||r===le.MATHML)&&X3(e,t)}const eO="hidden",tO=8,nO=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 rO={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},U1=new Set([m.TABLE,m.TBODY,m.TFOOT,m.THEAD,m.TR]),H1={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Gr,onParseError:null};class z1{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({},H1),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 C3(this.options,this),this.activeFormattingElements=new D3(this.treeAdapter),this.fragmentContextID=r?So(this.treeAdapter.getTagName(r)):m.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new L3(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({},H1),n);t!=null||(t=r.treeAdapter.createElement(V.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:rO,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=xt.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===V.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=xt.RCDATA;break}case m.STYLE:case m.XMP:case m.IFRAME:case m.NOEMBED:case m.NOFRAMES:case m.NOSCRIPT:{this.tokenizer.state=xt.RAWTEXT;break}case m.SCRIPT:{this.tokenizer.state=xt.SCRIPT_DATA;break}case m.PLAINTEXT:{this.tokenizer.state=xt.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",o=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,o),t.location){const u=this.treeAdapter.getChildNodes(this.document).find(c=>this.treeAdapter.isDocumentTypeNode(c));u&&this.treeAdapter.setNodeSourceCodeLocation(u,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&se(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(V.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)===V.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 Z3(t,o,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===lr.Marker||this.openElements.contains(o.element)),r=n===-1?t-1:n-1;for(let o=r;o>=0;o--){const a=this.activeFormattingElements.entries[o];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=L.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(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 U1.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 _3[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){PI(this,t);return}switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{qs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Gs(this,t);break}case L.AFTER_HEAD:{Ks(this,t);break}case L.IN_BODY:case L.IN_CAPTION:case L.IN_CELL:case L.IN_TEMPLATE:{$1(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:{Ef(this,t);break}case L.IN_TABLE_TEXT:{X1(this,t);break}case L.IN_COLUMN_GROUP:{$u(this,t);break}case L.AFTER_BODY:{Yu(this,t);break}case L.AFTER_AFTER_BODY:{Wu(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){RI(this,t);return}switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{qs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Gs(this,t);break}case L.AFTER_HEAD:{Ks(this,t);break}case L.TEXT:{this._insertCharacters(t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{Ef(this,t);break}case L.IN_COLUMN_GROUP:{$u(this,t);break}case L.AFTER_BODY:{Yu(this,t);break}case L.AFTER_AFTER_BODY:{Wu(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){mf(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:{mf(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.AFTER_BODY:{cO(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:{fO(this,t);break}case L.BEFORE_HEAD:case L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:{this._err(t,J.misplacedDoctype);break}case L.IN_TABLE_TEXT:{Js(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,J.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?LI(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{hO(this,t);break}case L.BEFORE_HEAD:{mO(this,t);break}case L.IN_HEAD:{Wn(this,t);break}case L.IN_HEAD_NO_SCRIPT:{yO(this,t);break}case L.AFTER_HEAD:{bO(this,t);break}case L.IN_BODY:{Gt(this,t);break}case L.IN_TABLE:{vo(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.IN_CAPTION:{gI(this,t);break}case L.IN_COLUMN_GROUP:{yf(this,t);break}case L.IN_TABLE_BODY:{Vu(this,t);break}case L.IN_ROW:{qu(this,t);break}case L.IN_CELL:{TI(this,t);break}case L.IN_SELECT:{eE(this,t);break}case L.IN_SELECT_IN_TABLE:{xI(this,t);break}case L.IN_TEMPLATE:{_I(this,t);break}case L.AFTER_BODY:{vI(this,t);break}case L.IN_FRAMESET:{AI(this,t);break}case L.AFTER_FRAMESET:{kI(this,t);break}case L.AFTER_AFTER_BODY:{OI(this,t);break}case L.AFTER_AFTER_FRAMESET:{II(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?DI(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{pO(this,t);break}case L.BEFORE_HEAD:{gO(this,t);break}case L.IN_HEAD:{EO(this,t);break}case L.IN_HEAD_NO_SCRIPT:{TO(this,t);break}case L.AFTER_HEAD:{xO(this,t);break}case L.IN_BODY:{ju(this,t);break}case L.TEXT:{sI(this,t);break}case L.IN_TABLE:{Qs(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.IN_CAPTION:{EI(this,t);break}case L.IN_COLUMN_GROUP:{yI(this,t);break}case L.IN_TABLE_BODY:{Tf(this,t);break}case L.IN_ROW:{Z1(this,t);break}case L.IN_CELL:{bI(this,t);break}case L.IN_SELECT:{tE(this,t);break}case L.IN_SELECT_IN_TABLE:{wI(this,t);break}case L.IN_TEMPLATE:{SI(this,t);break}case L.AFTER_BODY:{rE(this,t);break}case L.IN_FRAMESET:{CI(this,t);break}case L.AFTER_FRAMESET:{NI(this,t);break}case L.AFTER_AFTER_BODY:{Wu(this,t);break}}}onEof(t){switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{qs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Gs(this,t);break}case L.AFTER_HEAD:{Ks(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:{K1(this,t);break}case L.TEXT:{aI(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.IN_TEMPLATE:{nE(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:{gf(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===C.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:{j1(this,t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{Ef(this,t);break}case L.IN_TABLE_TEXT:{Q1(this,t);break}}}}function iO(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):G1(e,t),n}function oO(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 sO(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>=nO;!c||d?(d&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(u)):(u=aO(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(u,r),r=u)}return r}function aO(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 uO(e,t,n){const r=e.treeAdapter.getTagName(t),o=So(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);o===m.TEMPLATE&&a===le.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function lO(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 pf(e,t){for(let n=0;n<tO;n++){const r=iO(e,t);if(!r)break;const o=oO(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const a=sO(e,o,r.element),u=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),u&&uO(e,u,a),lO(e,o,r)}}function mf(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function cO(e,t){e._appendCommentNode(t,e.openElements.items[0])}function dO(e,t){e._appendCommentNode(t,e.document)}function gf(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 fO(e,t){e._setDocumentType(t);const n=t.forceQuirks?Ln.QUIRKS:j3(t);z3(t)||e._err(t,J.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=L.BEFORE_HTML}function Vs(e,t){e._err(t,J.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Ln.QUIRKS),e.insertionMode=L.BEFORE_HTML,e._processToken(t)}function hO(e,t){t.tagID===m.HTML?(e._insertElement(t,le.HTML),e.insertionMode=L.BEFORE_HEAD):qs(e,t)}function pO(e,t){const n=t.tagID;(n===m.HTML||n===m.HEAD||n===m.BODY||n===m.BR)&&qs(e,t)}function qs(e,t){e._insertFakeRootElement(),e.insertionMode=L.BEFORE_HEAD,e._processToken(t)}function mO(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.HEAD:{e._insertElement(t,le.HTML),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD;break}default:Ys(e,t)}}function gO(e,t){const n=t.tagID;n===m.HEAD||n===m.BODY||n===m.HTML||n===m.BR?Ys(e,t):e._err(t,J.endTagWithoutMatchingOpenElement)}function Ys(e,t){e._insertFakeElement(V.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:{Gt(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,xt.RCDATA);break}case m.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,xt.RAWTEXT):(e._insertElement(t,le.HTML),e.insertionMode=L.IN_HEAD_NO_SCRIPT);break}case m.NOFRAMES:case m.STYLE:{e._switchToTextParsing(t,xt.RAWTEXT);break}case m.SCRIPT:{e._switchToTextParsing(t,xt.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,J.misplacedStartTagForHeadElement);break}default:Ws(e,t)}}function EO(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:{Ws(e,t);break}case m.TEMPLATE:{Di(e,t);break}default:e._err(t,J.endTagWithoutMatchingOpenElement)}}function Di(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==m.TEMPLATE&&e._err(t,J.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,J.endTagWithoutMatchingOpenElement)}function Ws(e,t){e.openElements.pop(),e.insertionMode=L.AFTER_HEAD,e._processToken(t)}function yO(e,t){switch(t.tagID){case m.HTML:{Gt(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,J.nestedNoscriptInHead);break}default:Gs(e,t)}}function TO(e,t){switch(t.tagID){case m.NOSCRIPT:{e.openElements.pop(),e.insertionMode=L.IN_HEAD;break}case m.BR:{Gs(e,t);break}default:e._err(t,J.endTagWithoutMatchingOpenElement)}}function Gs(e,t){const n=t.type===Ve.EOF?J.openElementsLeftAfterEof:J.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=L.IN_HEAD,e._processToken(t)}function bO(e,t){switch(t.tagID){case m.HTML:{Gt(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,J.abandonedHeadElementChild),e.openElements.push(e.headElement,m.HEAD),Wn(e,t),e.openElements.remove(e.headElement);break}case m.HEAD:{e._err(t,J.misplacedStartTagForHeadElement);break}default:Ks(e,t)}}function xO(e,t){switch(t.tagID){case m.BODY:case m.HTML:case m.BR:{Ks(e,t);break}case m.TEMPLATE:{Di(e,t);break}default:e._err(t,J.endTagWithoutMatchingOpenElement)}}function Ks(e,t){e._insertFakeElement(V.BODY,m.BODY),e.insertionMode=L.IN_BODY,zu(e,t)}function zu(e,t){switch(t.type){case Ve.CHARACTER:{$1(e,t);break}case Ve.WHITESPACE_CHARACTER:{j1(e,t);break}case Ve.COMMENT:{mf(e,t);break}case Ve.START_TAG:{Gt(e,t);break}case Ve.END_TAG:{ju(e,t);break}case Ve.EOF:{K1(e,t);break}}}function j1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function $1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function wO(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function _O(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function SO(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 vO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML)}function AO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&df.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,le.HTML)}function CO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function kO(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 NO(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 OO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.tokenizer.state=xt.PLAINTEXT}function IO(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 RO(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(V.A);n&&(pf(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 PO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function LO(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(m.NOBR)&&(pf(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function DO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function MO(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 V1(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function q1(e){const t=_1(e,Li.TYPE);return t!=null&&t.toLowerCase()===eO}function FO(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),q1(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function BO(e,t){e._appendElement(t,le.HTML),t.ackSelfClosing=!0}function UO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function HO(e,t){t.tagName=V.IMG,t.tagID=m.IMG,V1(e,t)}function zO(e,t){e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.tokenizer.state=xt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=L.TEXT}function jO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function $O(e,t){e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function Y1(e,t){e._switchToTextParsing(t,xt.RAWTEXT)}function VO(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 qO(e,t){e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function YO(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,le.HTML)}function WO(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(m.RTC),e._insertElement(t,le.HTML)}function GO(e,t){e._reconstructActiveFormattingElements(),F1(t),hf(t),t.selfClosing?e._appendElement(t,le.MATHML):e._insertElement(t,le.MATHML),t.ackSelfClosing=!0}function KO(e,t){e._reconstructActiveFormattingElements(),B1(t),hf(t),t.selfClosing?e._appendElement(t,le.SVG):e._insertElement(t,le.SVG),t.ackSelfClosing=!0}function W1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function Gt(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:{PO(e,t);break}case m.A:{RO(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{AO(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:{vO(e,t);break}case m.LI:case m.DD:case m.DT:{NO(e,t);break}case m.BR:case m.IMG:case m.WBR:case m.AREA:case m.EMBED:case m.KEYGEN:{V1(e,t);break}case m.HR:{UO(e,t);break}case m.RB:case m.RTC:{YO(e,t);break}case m.RT:case m.RP:{WO(e,t);break}case m.PRE:case m.LISTING:{CO(e,t);break}case m.XMP:{jO(e,t);break}case m.SVG:{KO(e,t);break}case m.HTML:{wO(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:{_O(e,t);break}case m.FORM:{kO(e,t);break}case m.NOBR:{LO(e,t);break}case m.MATH:{GO(e,t);break}case m.TABLE:{MO(e,t);break}case m.INPUT:{FO(e,t);break}case m.PARAM:case m.TRACK:case m.SOURCE:{BO(e,t);break}case m.IMAGE:{HO(e,t);break}case m.BUTTON:{IO(e,t);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{DO(e,t);break}case m.IFRAME:{$O(e,t);break}case m.SELECT:{VO(e,t);break}case m.OPTION:case m.OPTGROUP:{qO(e,t);break}case m.NOEMBED:case m.NOFRAMES:{Y1(e,t);break}case m.FRAMESET:{SO(e,t);break}case m.TEXTAREA:{zO(e,t);break}case m.NOSCRIPT:{e.options.scriptingEnabled?Y1(e,t):W1(e,t);break}case m.PLAINTEXT:{OO(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:W1(e,t)}}function QO(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 XO(e,t){e.openElements.hasInScope(m.BODY)&&(e.insertionMode=L.AFTER_BODY,rE(e,t))}function JO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function ZO(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 eI(e){e.openElements.hasInButtonScope(m.P)||e._insertFakeElement(V.P,m.P),e._closePElement()}function tI(e){e.openElements.hasInListItemScope(m.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(m.LI),e.openElements.popUntilTagNamePopped(m.LI))}function nI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function rI(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function iI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function oI(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(V.BR,m.BR),e.openElements.pop(),e.framesetOk=!1}function G1(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 ju(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:{pf(e,t);break}case m.P:{eI(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:{JO(e,t);break}case m.LI:{tI(e);break}case m.DD:case m.DT:{nI(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{rI(e);break}case m.BR:{oI(e);break}case m.BODY:{QO(e,t);break}case m.HTML:{XO(e,t);break}case m.FORM:{ZO(e);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{iI(e,t);break}case m.TEMPLATE:{Di(e,t);break}default:G1(e,t)}}function K1(e,t){e.tmplInsertionModeStack.length>0?nE(e,t):gf(e,t)}function sI(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 aI(e,t){e._err(t,J.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Ef(e,t){if(e.openElements.currentTagId!==void 0&&U1.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:{X1(e,t);break}case Ve.WHITESPACE_CHARACTER:{Q1(e,t);break}}else Xs(e,t)}function uI(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_CAPTION}function lI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_COLUMN_GROUP}function cI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(V.COLGROUP,m.COLGROUP),e.insertionMode=L.IN_COLUMN_GROUP,yf(e,t)}function dI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_TABLE_BODY}function fI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(V.TBODY,m.TBODY),e.insertionMode=L.IN_TABLE_BODY,Vu(e,t)}function hI(e,t){e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function pI(e,t){q1(t)?e._appendElement(t,le.HTML):Xs(e,t),t.ackSelfClosing=!0}function mI(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,le.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function vo(e,t){switch(t.tagID){case m.TD:case m.TH:case m.TR:{fI(e,t);break}case m.STYLE:case m.SCRIPT:case m.TEMPLATE:{Wn(e,t);break}case m.COL:{cI(e,t);break}case m.FORM:{mI(e,t);break}case m.TABLE:{hI(e,t);break}case m.TBODY:case m.TFOOT:case m.THEAD:{dI(e,t);break}case m.INPUT:{pI(e,t);break}case m.CAPTION:{uI(e,t);break}case m.COLGROUP:{lI(e,t);break}default:Xs(e,t)}}function Qs(e,t){switch(t.tagID){case m.TABLE:{e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode());break}case m.TEMPLATE:{Di(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:Xs(e,t)}}function Xs(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,zu(e,t),e.fosterParentingEnabled=n}function Q1(e,t){e.pendingCharacterTokens.push(t)}function X1(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Js(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Xs(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const J1=new Set([m.CAPTION,m.COL,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]);function gI(e,t){const n=t.tagID;J1.has(n)?e.openElements.hasInTableScope(m.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,vo(e,t)):Gt(e,t)}function EI(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&&Qs(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:ju(e,t)}}function yf(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.COL:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.TEMPLATE:{Wn(e,t);break}default:$u(e,t)}}function yI(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:{Di(e,t);break}case m.COL:break;default:$u(e,t)}}function $u(e,t){e.openElements.currentTagId===m.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE,e._processToken(t))}function Vu(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(V.TR,m.TR),e.insertionMode=L.IN_ROW,qu(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,vo(e,t));break}default:vo(e,t)}}function Tf(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,Qs(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:Qs(e,t)}}function qu(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,Vu(e,t));break}default:vo(e,t)}}function Z1(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,Tf(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,Tf(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:Qs(e,t)}}function TI(e,t){const n=t.tagID;J1.has(n)?(e.openElements.hasInTableScope(m.TD)||e.openElements.hasInTableScope(m.TH))&&(e._closeTableCell(),qu(e,t)):Gt(e,t)}function bI(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(),Z1(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:break;default:ju(e,t)}}function eE(e,t){switch(t.tagID){case m.HTML:{Gt(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 tE(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:{Di(e,t);break}}}function xI(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)):eE(e,t)}function wI(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)):tE(e,t)}function _I(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,vo(e,t);break}case m.COL:{e.tmplInsertionModeStack[0]=L.IN_COLUMN_GROUP,e.insertionMode=L.IN_COLUMN_GROUP,yf(e,t);break}case m.TR:{e.tmplInsertionModeStack[0]=L.IN_TABLE_BODY,e.insertionMode=L.IN_TABLE_BODY,Vu(e,t);break}case m.TD:case m.TH:{e.tmplInsertionModeStack[0]=L.IN_ROW,e.insertionMode=L.IN_ROW,qu(e,t);break}default:e.tmplInsertionModeStack[0]=L.IN_BODY,e.insertionMode=L.IN_BODY,Gt(e,t)}}function SI(e,t){t.tagID===m.TEMPLATE&&Di(e,t)}function nE(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):gf(e,t)}function vI(e,t){t.tagID===m.HTML?Gt(e,t):Yu(e,t)}function rE(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 Yu(e,t)}function Yu(e,t){e.insertionMode=L.IN_BODY,zu(e,t)}function AI(e,t){switch(t.tagID){case m.HTML:{Gt(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 CI(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 kI(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function NI(e,t){t.tagID===m.HTML&&(e.insertionMode=L.AFTER_AFTER_FRAMESET)}function OI(e,t){t.tagID===m.HTML?Gt(e,t):Wu(e,t)}function Wu(e,t){e.insertionMode=L.IN_BODY,zu(e,t)}function II(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function RI(e,t){t.chars=ft,e._insertCharacters(t)}function PI(e,t){e._insertCharacters(t),e.framesetOk=!1}function iE(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 LI(e,t){if(K3(t))iE(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===le.MATHML?F1(t):r===le.SVG&&(Q3(t),B1(t)),hf(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function DI(e,t){if(t.tagID===m.P||t.tagID===m.BR){iE(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}}}V.AREA,V.BASE,V.BASEFONT,V.BGSOUND,V.BR,V.COL,V.EMBED,V.FRAME,V.HR,V.IMG,V.INPUT,V.KEYGEN,V.LINK,V.META,V.PARAM,V.SOURCE,V.TRACK,V.WBR;const MI=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,FI=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),oE={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function sE(e,t){const n=WI(e),r=y1("type",{handlers:{root:BI,element:UI,text:HI,comment:uE,doctype:zI,raw:$I},unknown:VI}),o={parser:n?new z1(oE):z1.getFragmentParser(void 0,oE),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),Ao(o,ar());const a=n?o.parser.document:o.parser.getFragment(),u=BN(a,{file:o.options.file});return o.stitches&&Mu(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 aE(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function BI(e,t){aE(e.children,t)}function UI(e,t){qI(e,t),aE(e.children,t),YI(e,t)}function HI(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:Ve.CHARACTER,chars:e.value,location:Zs(e)};Ao(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function zI(e,t){const n={type:Ve.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Zs(e)};Ao(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function jI(e,t){t.stitches=!0;const n=GI(e);if("children"in e&&"children"in n){const r=sE({type:"root",children:e.children},t.options);n.children=r.children}uE({type:"comment",value:{stitch:n}},t)}function uE(e,t){const n=e.value,r={type:Ve.COMMENT,data:n,location:Zs(e)};Ao(t,ar(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function $I(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,lE(t,ar(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(MI,"<$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 VI(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))jI(n,t);else{let r="";throw FI.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 Ao(e,t){lE(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=xt.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function lE(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 qI(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===xt.PLAINTEXT)return;Ao(t,ar(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Ri.html;o===Ri.html&&n==="svg"&&(o=Ri.svg);const a=ZN(se(B({},e),{children:[]}),{space:o===Ri.svg?"svg":"html"}),u={type:Ve.START_TAG,tagName:n,tagID:So(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Zs(e)};t.parser.currentToken=u,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function YI(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&a3.includes(n)||t.parser.tokenizer.state===xt.PLAINTEXT)return;Ao(t,vu(e));const r={type:Ve.END_TAG,tagName:n,tagID:So(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Zs(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===xt.RCDATA||t.parser.tokenizer.state===xt.RAWTEXT||t.parser.tokenizer.state===xt.SCRIPT_DATA)&&(t.parser.tokenizer.state=xt.DATA)}function WI(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Zs(e){const t=ar(e)||{line:void 0,column:void 0,offset:void 0},n=vu(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 GI(e){return"children"in e?Ii(se(B({},e),{children:[]})):Ii(e)}function cE(e){return function(t,n){return sE(t,se(B({},e),{file:n}))}}const Mi=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],dE={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Mi,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Mi],h2:[["className","sr-only"]],img:[...Mi,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Mi,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Mi],table:[...Mi],ul:[...Mi,["className","contains-task-list"]],"*":["abbr","accept","acceptCharset","accessKey","action","align","alt","axis","border","cellPadding","cellSpacing","char","charOff","charSet","checked","clear","colSpan","color","cols","compact","coords","dateTime","dir","encType","frame","hSpace","headers","height","hrefLang","htmlFor","id","isMap","itemProp","label","lang","maxLength","media","method","multiple","name","noHref","noShade","noWrap","open","prompt","readOnly","rev","rowSpan","rows","rules","scope","selected","shape","size","span","start","summary","tabIndex","title","useMap","vAlign","value","width"]},clobber:["ariaDescribedBy","ariaLabelledBy","id","name"],clobberPrefix:"user-content-",protocols:{cite:["http","https"],href:["http","https","irc","ircs","mailto","xmpp"],longDesc:["http","https"],src:["http","https"]},required:{input:{disabled:!0,type:"checkbox"}},strip:["script"],tagNames:["a","b","blockquote","br","code","dd","del","details","div","dl","dt","em","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","li","ol","p","picture","pre","q","rp","rt","ruby","s","samp","section","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","tr","tt","ul","var"]},Kr={}.hasOwnProperty;function KI(e,t){let n={type:"root",children:[]};const r={schema:t?B(B({},dE),t):dE,stack:[]},o=fE(r,e);return o&&(Array.isArray(o)?o.length===1?n=o[0]:n.children=o:n=o),n}function fE(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return QI(e,n);case"doctype":return XI(e,n);case"element":return JI(e,n);case"root":return ZI(e,n);case"text":return eR(e,n)}}}function QI(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 ea(a,t),a}}function XI(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return ea(n,t),n}}function JI(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=hE(e,t.children),o=tR(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&&Kr.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 ea(u,t),u}function ZI(e,t){const r={type:"root",children:hE(e,t.children)};return ea(r,t),r}function eR(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return ea(r,t),r}function hE(e,t){const n=[];if(Array.isArray(t)){const r=t;let o=-1;for(;++o<r.length;){const a=fE(e,r[o]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function tR(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,o=e.schema.required,a=r&&Kr.call(r,n)?r[n]:void 0,u=r&&Kr.call(r,"*")?r["*"]:void 0,c=t&&typeof t=="object"?t:{},d={};let h;for(h in c)if(Kr.call(c,h)){const p=c[h];let E=pE(e,gE(a,h),h,p);E==null&&(E=pE(e,gE(u,h),h,p)),E!=null&&(d[h]=E)}if(o&&Kr.call(o,n)){const p=o[n];for(h in p)Kr.call(p,h)&&!Kr.call(d,h)&&(d[h]=p[h])}return d}function pE(e,t,n,r){return t?Array.isArray(r)?nR(e,t,n,r):mE(e,t,n,r):void 0}function nR(e,t,n,r){let o=-1;const a=[];for(;++o<r.length;){const u=mE(e,t,n,r[o]);(typeof u=="number"||typeof u=="string")&&a.push(u)}return a}function mE(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&rR(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 rR(e,t,n){const r=e.schema.protocols&&Kr.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 ea(e,t){const n=X0(t);t.data&&(e.data=Ii(t.data)),n&&(e.position=n)}function gE(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 iR(e){return function(t){return KI(t,e)}}const EE=({globalClassName:e,openLinksInNewTab:t,href:n,title:r,children:o})=>{const a=n?t?"_blank":"_self":void 0;return P.jsx("a",se(B(B({className:ae(e,`${ee}-link`)},n?{href:n,target:a}:{}),r?{title:r}:{}),{rel:"noopener noreferrer",children:o}))},oR=()=>{const{disclaimerText:e,disclaimerMarkdown:t,globalClassName:n}=kt();return!e&&!t?null:P.jsx("div",{className:ae(n,`${ee}-disclaimer`),children:t?P.jsx(Jg,{rehypePlugins:[cE,iR],components:{ul:({children:r})=>P.jsx("ul",{className:ae(n,`${ee}-ul`),children:r}),ol:({children:r})=>P.jsx("ol",{className:ae(n,`${ee}-ol`),children:r}),li:({children:r})=>P.jsx("li",{className:ae(n,`${ee}-li`),children:r}),a:({href:r,title:o,children:a})=>P.jsx(EE,{globalClassName:n,openLinksInNewTab:!0,href:r,title:o,children:a}),img:({src:r,alt:o})=>P.jsx("img",{className:ae(n,`${ee}-disclaimer-image`),src:r,alt:o}),p:({children:r})=>P.jsx("p",{className:ae(n,`${ee}-disclaimer-text`),children:r}),span:({children:r})=>P.jsx("span",{className:ae(n,`${ee}-disclaimer-text-span`),children:r})},children:t}):P.jsx("p",{className:ae(n,`${ee}-disclaimer-text`),children:e})})},bf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{isConnected:o}=ki(),{globalClassName:a,searchConfig:u}=kt(),c=X.useRef(null),d=t||!o,h=E=>{var T;E.preventDefault();const b=(((T=c.current)==null?void 0:T.value)||"").trim();b&&(c.current.value="",r(b))},p=()=>{r("Can you connect me to a human?")};return P.jsxs("div",{className:ae(a,e,`cim-${n}-component`,`${ee}-search-bar-wrapper`),children:[P.jsxs("form",{className:ae(a,e,`cim-${n}-component`,`${ee}-search-bar`),name:`${ee}-search-form`,onSubmit:h,children:[P.jsx("input",{className:ae(a,e,`cim-${n}-component`,`${ee}-search-input`),type:"text",ref:c,placeholder:(u==null?void 0:u.placeholder)||"Ask us anything",name:`${ee}-user-input`,disabled:d}),P.jsx(Cv,{className:e,globalClassName:a,searchConfig:u,componentType:n,isLoading:d}),P.jsx($r,{className:ae(a,`${ee}-escalate-btn`),ariaLabel:"Connect to a human agent",title:"Connect to a human agent",disabled:d,onClick:p,icon:P.jsx(xv,{})})]}),P.jsx(oR,{})]})};function sR(e){return tn({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 yE=X.createContext({isOpen:!1}),xf=X.createContext(null),TE=X.createContext(null),ta=()=>{var n,r;const e=X.useContext(xf),t=X.useContext(TE);return(r=(n=e==null?void 0:e.closeMenu)!=null?n:t==null?void 0:t.closeMenu)!=null?r:(()=>{})},bE=({onClearChat:e,componentType:t})=>{const n=ta(),r=()=>{e(),n()};return P.jsxs("button",{className:ae(`${ee}-overflow-menu-button`,"clear-chat-button",`cim-${t}-component`),onClick:r,children:[P.jsx(sR,{}),"Clear chat"]})};function aR(e){return e==null?[]:Array.isArray(e)?e:[e]}var uR=(e,...t)=>e.concat(t),lR=(e,...t)=>e.filter(n=>!t.includes(n)),cR=e=>Array.from(new Set(e));function xE(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 xE(e,t,{step:-r,loop:o})}var fR=e=>Array.isArray(e),wE=e=>e!=null&&typeof e=="object",hR=e=>wE(e)&&!fR(e),Gu=e=>typeof e=="string",Co=e=>typeof e=="function",pR=e=>e==null,mR=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),gR=e=>Object.prototype.toString.call(e),_E=Function.prototype.toString,ER=_E.call(Object),yR=e=>{if(!wE(e)||gR(e)!="[object Object]"||xR(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=mR(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&_E.call(n)==ER},TR=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,bR=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,xR=e=>TR(e)||bR(e),wR=e=>e(),_R=()=>{},wf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function SR(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:vR,max:AR}=Math,CR=e=>Number.isNaN(e),kR=e=>CR(e)?0:e,SE=(e,t,n)=>vR(AR(kR(e),t),n);function _f(e){if(!yR(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]=_f(o))}return n}function Sf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function NR(e,t){if(e==null)throw new Error(t())}function OR(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 IR=Object.defineProperty,RR=(e,t,n)=>t in e?IR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vf=(e,t,n)=>RR(e,typeof t!="symbol"?t+"":t,n),vE=()=>{},Ku=e=>typeof e=="object"&&e!==null,ko=e=>e?"":void 0,AE=e=>e?"true":void 0,PR=1,LR=9,DR=11,Mt=e=>Ku(e)&&e.nodeType===PR&&typeof e.nodeName=="string",Qu=e=>Ku(e)&&e.nodeType===LR,MR=e=>Ku(e)&&e===e.window,CE=e=>Mt(e)?e.localName||"":"#document";function FR(e){return["html","body","#document"].includes(CE(e))}var BR=e=>Ku(e)&&e.nodeType!==void 0,Fi=e=>BR(e)&&e.nodeType===DR&&"host"in e,UR=e=>Mt(e)&&e.localName==="input",HR=e=>Mt(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function na(e){if(!e)return!1;const t=e.getRootNode();return Io(t)===e}var zR=/(textarea|select)/;function jR(e){if(e==null||!Mt(e))return!1;try{return UR(e)&&e.selectionStart!=null||zR.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function No(e,t){var r;if(!e||!t||!Mt(e)||!Mt(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Fi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function cr(e){var t;return Qu(e)?e:MR(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function $R(e){return cr(e).documentElement}function Oo(e){var t,n,r;return Fi(e)?Oo(e.host):Qu(e)?(t=e.defaultView)!=null?t:window:Mt(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Io(e){let t=e.activeElement;for(;t!=null&&t.shadowRoot;){const n=t.shadowRoot.activeElement;if(!n||n===t)break;t=n}return t}function VR(e){if(CE(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Fi(e)&&e.host||$R(e);return Fi(t)?t.host:t}function Af(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),Qu(t)||Fi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var Cf=new WeakMap;function Ro(e){return Cf.has(e)||Cf.set(e,Oo(e).getComputedStyle(e)),Cf.get(e)}var kf=new Set(["menu","listbox","dialog","grid","tree","region"]),qR=e=>kf.has(e),kE=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function NE(e,t){const n=new Set,r=Af(e),o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=kE(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"),b=p.getAttribute("aria-modal")==="true";if(E&&qR(E)&&!b&&(p===t||p.contains(t)||o(p)))return!0}}}return!1};return o(e)}function OE(e,t){const n=Af(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=kE(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"),b=p.getAttribute("aria-modal")==="true";E&&kf.has(E)&&!b&&(t(p),o(p))}}}};o(e)}function YR(e){const t=new Set;return OE(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function WR(e){const t=e.getAttribute("role");return!!(t&&kf.has(t))}function GR(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function KR(e){var t;return GR(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function QR(e){if(!e.id)return!1;const t=Af(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&WR(e))}var Nf=()=>typeof document!="undefined";function XR(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Of=e=>Nf()&&e.test(XR()),JR=e=>Nf()&&e.test(navigator.vendor),IE=()=>Nf()&&!!navigator.maxTouchPoints,ZR=()=>Of(/^iPhone/i),eP=()=>Of(/^iPad/i)||If()&&navigator.maxTouchPoints>1,Xu=()=>ZR()||eP(),tP=()=>If()||Xu(),If=()=>Of(/^Mac/i),nP=()=>tP()&&JR(/apple/i);function rP(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=rP(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var RE=e=>e.button===0,iP=e=>e.button===2||If()&&e.ctrlKey&&e.button===0,oP=e=>"touches"in e&&e.touches.length>0,sP={Up:"ArrowUp",Down:"ArrowDown",Esc:"Escape"," ":"Space",",":"Comma",Left:"ArrowLeft",Right:"ArrowRight"},PE={ArrowLeft:"ArrowRight",ArrowRight:"ArrowLeft"};function aP(e,t={}){var u;const{dir:n="ltr",orientation:r="horizontal"}=t;let o=e.key;return o=(u=sP[o])!=null?u:o,n==="rtl"&&r==="horizontal"&&o in PE&&(o=PE[o]),o}function LE(e,t="client"){const n=oP(e)?e.touches[0]||e.changedTouches[0]:e;return{x:n[`${t}X`],y:n[`${t}Y`]}}var Ft=(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)}},DE=e=>Mt(e)&&e.tagName==="IFRAME",uP=/^(audio|video|details)$/;function ME(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var lP=e=>!Number.isNaN(ME(e)),cP=e=>ME(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 FE(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(Ju)).filter(n),E=u.get(d);if(E!==void 0){const b=E+1;r.splice(b,0,...p),p.forEach((T,x)=>{u.set(T,b+x)});for(let T=b+p.length;T<r.length;T++)u.set(r[T],T)}else{const b=r.length;r.push(...p),p.forEach((T,x)=>{u.set(T,b+x)})}o.push(...p)}}return r}var Ju="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",BE=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ju));(n==!0||n=="if-empty"&&o.length===0)&&Mt(e)&&dr(e)&&o.unshift(e);const u=[];for(const c of o)if(dr(c)){if(DE(c)&&c.contentDocument){const d=c.contentDocument.body;u.push(...BE(d,{getShadowRoot:r}));continue}u.push(c)}return r?FE(u,r,dr):u};function dr(e){return!Mt(e)||e.closest("[inert]")?!1:e.matches(Ju)&&HR(e)}function Po(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ju));n&&Bi(e)&&o.unshift(e);const a=[];for(const u of o)if(Bi(u)){if(DE(u)&&u.contentDocument){const c=u.contentDocument.body;a.push(...Po(c,{getShadowRoot:r}));continue}a.push(u)}if(r){const u=FE(a,r,Bi);return!u.length&&n?o:u}return!a.length&&n?o:a}function Bi(e){return Mt(e)&&e.tabIndex>0?!0:dr(e)&&!cP(e)}function fP(e,t={}){const n=Po(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function hP(e,t={}){const{current:n,getShadowRoot:r}=t,o=Po(e,{getShadowRoot:r}),a=(e==null?void 0:e.ownerDocument)||document,u=n!=null?n:Io(a);if(!u)return null;const c=o.indexOf(u);return o[c+1]||null}function ra(e){return e.tabIndex<0&&(uP.test(e.localName)||jR(e))&&!lP(e)?0:e.tabIndex}function UE(e){const{root:t,getInitialEl:n,filter:r,enabled:o=!0}=e;if(!o)return;let a=null;if(a||(a=typeof n=="function"?n():n),a||(a=t==null?void 0:t.querySelector("[data-autofocus],[autofocus]")),!a){const u=Po(t);a=r?u.filter(r)[0]:u[0]}return a||t||void 0}var pP=class zx{constructor(){vf(this,"id",null),vf(this,"fn_cleanup"),vf(this,"cleanup",()=>{this.cancel()})}static create(){return new zx}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 Nt(e){const t=pP.create();return t.request(e),t.cleanup}function HE(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 Rf(e){const t=VR(e);return FR(t)?cr(t).body:Mt(t)&&EP(t)?t:Rf(t)}var mP=/auto|scroll|overlay|hidden|clip/,gP=new Set(["inline","contents"]);function EP(e){const t=Oo(e),{overflow:n,overflowX:r,overflowY:o,display:a}=t.getComputedStyle(e);return mP.test(n+o+r)&&!gP.has(a)}var Lo="default",Pf="",Zu=new WeakMap;function yP(e={}){const{target:t,doc:n}=e,r=n!=null?n:document,o=r.documentElement;return Xu()?(Lo==="default"&&(Pf=o.style.webkitUserSelect,o.style.webkitUserSelect="none"),Lo="disabled"):t&&(Zu.set(t,t.style.userSelect),t.style.userSelect="none"),()=>TP({target:t,doc:r})}function TP(e={}){const{target:t,doc:n}=e,o=(n!=null?n:document).documentElement;if(Xu()){if(Lo!=="disabled")return;Lo="restoring",setTimeout(()=>{HE(()=>{Lo==="restoring"&&(o.style.webkitUserSelect==="none"&&(o.style.webkitUserSelect=Pf||""),Pf="",Lo="default")})},300)}else if(t&&Zu.has(t)){const a=Zu.get(t);t.style.userSelect==="none"&&(t.style.userSelect=a!=null?a:""),t.getAttribute("style")===""&&t.removeAttribute("style"),Zu.delete(t)}}function bP(e={}){const u=e,{defer:t,target:n}=u,r=sn(u,["defer","target"]),o=t?Nt:c=>c(),a=[];return a.push(o(()=>{const c=typeof n=="function"?n():n;a.push(yP(se(B({},r),{target:c})))})),()=>{a.forEach(c=>c==null?void 0:c())}}function xP(e,t){const{onPointerMove:n,onPointerUp:r}=t,o=c=>{const d=LE(c),h=Math.sqrt(Za(d.x,2)+Za(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=LE(c);r({point:d,event:c})},u=[Ft(e,"pointermove",o,!1),Ft(e,"pointerup",a,!1),Ft(e,"pointercancel",a,!1),Ft(e,"contextmenu",a,!1),bP({doc:e})];return()=>{u.forEach(c=>c())}}function wP(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,b]=fP(e,{includeContainer:!0,getShadowRoot:a}),T=hP(c,{current:n,getShadowRoot:a}),x=!E&&!b;h.shiftKey&&na(T)?(o==null||o(),p=b):h.shiftKey&&(na(E)||x)?p=n:!h.shiftKey&&na(n)?(o==null||o(),p=E):!h.shiftKey&&(na(b)||x)&&(p=T),p&&(h.preventDefault(),typeof r=="function"?r(p):p.focus())}return Ft(u,"keydown",d,!0)}function _P(e,t){const c=t,{defer:n,triggerElement:r}=c,o=sn(c,["defer","triggerElement"]),a=n?Nt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof r=="function"?r():r;u.push(wP(d,B({triggerElement:h},o)))})),()=>{u.forEach(d=>d==null?void 0:d())}}function SP(e,t){var n;return Array.from((n=e==null?void 0:e.querySelectorAll(t))!=null?n:[])}function el(e,t){if(!e)return vE;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 vP(e,t,n){if(!e)return vE;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 AP(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 CP(e,t){const{timeout:n,rootNode:r}=t,o=Oo(r),a=cr(r),u=new o.AbortController;return AP(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 kP=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),NP=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,zE=e=>{const t={};let n;for(;n=NP.exec(e);)t[n[1]]=n[2];return t},OP=(e,t)=>{if(Gu(e)){if(Gu(t))return`${e};${t}`;e=zE(e)}else Gu(t)&&(t=zE(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function Ot(...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]=wf(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=kP(t[o],n[o]);continue}if(o==="style"){t[o]=OP(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 qF(e){return e}var Do=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Do||{}),Lf="__init__";function IP(e){const t=()=>{var u,c;return(c=(u=e.getRootNode)==null?void 0:u.call(e))!=null?c:document},n=()=>cr(t()),r=()=>{var u;return(u=n().defaultView)!=null?u:window},o=()=>Io(t()),a=u=>t().getElementById(u);return se(B({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:na,getById:a})}function RP(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var Mo=()=>e=>Array.from(new Set(e)),jE=typeof globalThis.document!="undefined"?X.useLayoutEffect:X.useEffect;function tl(e){var E,b;const t=(E=e().value)!=null?E:e().defaultValue,n=(b=e().isEqual)!=null?b:Object.is,[r]=X.useState(t),[o,a]=X.useState(r),u=e().value!==void 0,c=X.useRef(o);c.current=u?e().value:o;const d=X.useRef(c.current);jE(()=>{d.current=c.current},[o,e().value]);const h=T=>{var S,A;const x=d.current,_=Co(T)?T(x):T;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(T){(e().sync?Ns.flushSync:wR)(()=>h(T))},invoke(T,x){var _,S;(S=(_=e()).onChange)==null||S.call(_,T,x)},hash(T){var x,_,S;return(S=(_=(x=e()).hash)==null?void 0:_.call(x,T))!=null?S:String(T)}}}tl.cleanup=e=>{X.useEffect(()=>e,[])},tl.ref=e=>{const t=X.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function PP(e){const t=X.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var LP=(e,t)=>{const n=X.useRef(!1),r=X.useRef(!1);X.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),X.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function nl(e,t={}){var W,te,oe,de,be,Ne;const n=X.useMemo(()=>{const{id:me,ids:Q,getRootNode:ie}=t;return IP({id:me,ids:Q,getRootNode:ie})},[t]),r=(...me)=>{e.debug&&console.log(...me)},o=(te=(W=e.props)==null?void 0:W.call(e,{props:_f(t),scope:n}))!=null?te:t,a=DP(o),u=(oe=e.context)==null?void 0:oe.call(e,{prop:a,bindable:tl,scope:n,flush:VE,getContext(){return d},getComputed(){return Y},getRefs(){return _},getEvent(){return T()}}),c=$E(u),d={get(me){var Q;return(Q=c.current)==null?void 0:Q[me].ref.current},set(me,Q){var ie;(ie=c.current)==null||ie[me].set(Q)},initial(me){var Q;return(Q=c.current)==null?void 0:Q[me].initial},hash(me){var ie,v;const Q=(ie=c.current)==null?void 0:ie[me].get();return(v=c.current)==null?void 0:v[me].hash(Q)}},h=X.useRef(new Map),p=X.useRef(null),E=X.useRef(null),b=X.useRef({type:""}),T=()=>se(B({},b.current),{current(){return b.current},previous(){return E.current}}),x=()=>se(B({},M),{matches(...me){return me.includes(M.ref.current)},hasTag(me){var Q,ie;return!!((ie=(Q=e.states[M.ref.current])==null?void 0:Q.tags)!=null&&ie.includes(me))}}),_=PP((be=(de=e.refs)==null?void 0:de.call(e,{prop:a,context:d}))!=null?be:{}),S=()=>({state:x(),context:d,event:T(),prop:a,send:z,action:A,guard:O,track:LP,refs:_,computed:Y,flush:VE,scope:n,choose:H}),A=me=>{const Q=Co(me)?me(S()):me;if(!Q)return;const ie=Q.map(v=>{var Z,k;const D=(k=(Z=e.implementations)==null?void 0:Z.actions)==null?void 0:k[v];return D||Sf(`[zag-js] No implementation found for action "${JSON.stringify(v)}"`),D});for(const v of ie)v==null||v(S())},O=me=>{var Q,ie;return Co(me)?me(S()):(ie=(Q=e.implementations)==null?void 0:Q.guards)==null?void 0:ie[me](S())},I=me=>{const Q=Co(me)?me(S()):me;if(!Q)return;const ie=Q.map(D=>{var k,xe;const Z=(xe=(k=e.implementations)==null?void 0:k.effects)==null?void 0:xe[D];return Z||Sf(`[zag-js] No implementation found for effect "${JSON.stringify(D)}"`),Z}),v=[];for(const D of ie){const Z=D==null?void 0:D(S());Z&&v.push(Z)}return()=>v.forEach(D=>D==null?void 0:D())},H=me=>aR(me).find(Q=>{let ie=!Q.guard;return Gu(Q.guard)?ie=!!O(Q.guard):Co(Q.guard)&&(ie=Q.guard(S())),ie}),Y=me=>{NR(e.computed,()=>"[zag-js] No computed object found on machine");const Q=e.computed[me];return Q({context:d,event:T(),prop:a,refs:_,scope:n,computed:Y})},M=tl(()=>({defaultValue:e.initialState({prop:a}),onChange(me,Q){var v,D,Z,k;if(Q){const xe=h.current.get(Q);xe==null||xe(),h.current.delete(Q)}Q&&A((v=e.states[Q])==null?void 0:v.exit),A((D=p.current)==null?void 0:D.actions);const ie=I((Z=e.states[me])==null?void 0:Z.effects);if(ie&&h.current.set(me,ie),Q===Lf){A(e.entry);const xe=I(e.effects);xe&&h.current.set(Lf,xe)}A((k=e.states[me])==null?void 0:k.entry)}})),G=X.useRef(void 0),pe=X.useRef(Do.NotStarted);jE(()=>{queueMicrotask(()=>{var D;const ie=pe.current===Do.Started;pe.current=Do.Started,r(ie?"rehydrating...":"initializing...");const v=(D=G.current)!=null?D:M.initial;M.invoke(v,ie?M.get():Lf)});const me=h.current,Q=M.ref.current;return()=>{r("unmounting..."),G.current=Q,pe.current=Do.Stopped,me.forEach(ie=>ie==null?void 0:ie()),h.current=new Map,p.current=null,queueMicrotask(()=>{A(e.exit)})}},[]);const re=()=>"ref"in M?M.ref.current:M.get(),z=me=>{queueMicrotask(()=>{var k,xe,Pe,Oe,He;if(pe.current!==Do.Started)return;E.current=b.current,b.current=me;let Q=re();const ie=(Pe=(k=e.states[Q].on)==null?void 0:k[me.type])!=null?Pe:(xe=e.on)==null?void 0:xe[me.type],v=H(ie);if(!v)return;p.current=v;const D=(Oe=v.target)!=null?Oe:Q;r("transition",me.type,v.target||Q,`(${v.actions})`);const Z=D!==Q;Z?Ns.flushSync(()=>M.set(D)):v.reenter&&!Z?M.invoke(Q,Q):A((He=v.actions)!=null?He:[])})};return(Ne=e.watch)==null||Ne.call(e,S()),{state:x(),send:z,context:d,prop:a,scope:n,refs:_,computed:Y,event:T(),getStatus:()=>pe.current}}function $E(e){const t=X.useRef(e);return t.current=e,t}function DP(e){const t=$E(e);return function(r){return t.current[r]}}function VE(e){queueMicrotask(()=>{Ns.flushSync(()=>e())})}var Df=RP(e=>e);function rl(...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 MP(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 Mf=e=>{const t=X.memo(X.forwardRef((n,r)=>{const h=n,{asChild:o,children:a}=h,u=sn(h,["asChild","children"]);if(!o)return X.createElement(e,se(B({},u),{ref:r}),a);if(!X.isValidElement(a))return null;const c=X.Children.only(a),d=MP(c);return X.cloneElement(c,se(B({},Ot(u,c.props)),{ref:r?rl(r,d):d}))}));return t.displayName=e.displayName||e.name,t},Kt=(()=>{const e=new Map;return new Proxy(Mf,{apply(t,n,r){return Mf(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,Mf(r)),e.get(r)}})})();function FP(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Ui(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:a,defaultValue:u}=e,c=X.createContext(u);c.displayName=t;function d(){var p;const h=X.useContext(c);if(!h&&n){const E=new Error(a!=null?a:FP(r,o));throw E.name="ContextError",(p=Error.captureStackTrace)==null||p.call(Error,E,d),E}return h}return[c.Provider,d,c]}const[BP,Ff]=Ui({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[qE,ia]=Ui({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),YE=X.forwardRef((e,t)=>{const n=Ff(),r=ia(),o=Ot(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:P.jsx(Kt.div,se(B({},o),{ref:rl(r.ref,t)}))});YE.displayName="PopoverContent";const WE=X.forwardRef((e,t)=>{const n=Ff(),r=ia(),o=Ot(n.getPositionerProps(),e);return r.unmounted?null:P.jsx(Kt.div,se(B({},o),{ref:t}))});WE.displayName="PopoverPositioner";const oa=()=>(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)]),GE=e=>oa()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function UP(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 HP={props({props:e}){return se(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",Ro(t.node)))},cleanupNode:({refs:e})=>{e.set("node",null),e.set("styles",null)},syncPresence:({context:e,refs:t,send:n,prop:r})=>{const o=r("present");if(o)return n({type:"MOUNT",src:"presence.changed"});const a=t.get("node");if(!o&&(a==null?void 0:a.ownerDocument.visibilityState)==="hidden")return n({type:"UNMOUNT",src:"visibilitychange"});Nt(()=>{var c,d;const u=il(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})=>{Nt(()=>{e.set("prevAnimationName",il(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,b;((b=(E=(p=d.composedPath)==null?void 0:p.call(d))==null?void 0:E[0])!=null?b:d.target)===o&&e.set("prevAnimationName",il(t.get("styles")))},u=d=>{const h=il(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=el(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",a),o.removeEventListener("animationcancel",u),o.removeEventListener("animationend",u),HE(()=>c())}}}}};function il(e){return(e==null?void 0:e.animationName)||"none"}Mo()(["onExitComplete","present","immediate"]);function zP(e,t={}){const{sync:n=!1}=t,r=jP(e);return X.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 jP(e){const t=X.useRef(e);return t.current=e,t}const Bf=(e={})=>{const b=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=b,a=sn(b,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),u=X.useRef(!1),c=se(B({},a),{present:r,onExitComplete:zP(e.onExitComplete)}),d=nl(HP,c),h=UP(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 Hi=(e,t=[])=>({parts:(...n)=>{if($P(t))return Hi(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>Hi(e,[...t,...n]),omit:(...n)=>Hi(e,t.filter(r=>!n.includes(r))),rename:n=>Hi(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`,`& [data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`].join(", "),attrs:{"data-scope":Fo(e),"data-part":Fo(r)}}}),{})}),Fo=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),$P=e=>e.length===0;const VP=["top","right","bottom","left"],Qr=Math.min,_n=Math.max,ol=Math.round,sl=Math.floor,fr=e=>({x:e,y:e}),qP={left:"right",right:"left",bottom:"top",top:"bottom"},YP={start:"end",end:"start"};function Uf(e,t,n){return _n(e,Qr(t,n))}function Ar(e,t){return typeof e=="function"?e(t):e}function Cr(e){return e.split("-")[0]}function Bo(e){return e.split("-")[1]}function Hf(e){return e==="x"?"y":"x"}function zf(e){return e==="y"?"height":"width"}const WP=new Set(["top","bottom"]);function hr(e){return WP.has(Cr(e))?"y":"x"}function jf(e){return Hf(hr(e))}function GP(e,t,n){n===void 0&&(n=!1);const r=Bo(e),o=jf(e),a=zf(o);let u=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(u=al(u)),[u,al(u)]}function KP(e){const t=al(e);return[$f(e),t,$f(t)]}function $f(e){return e.replace(/start|end/g,t=>YP[t])}const KE=["left","right"],QE=["right","left"],QP=["top","bottom"],XP=["bottom","top"];function JP(e,t,n){switch(e){case"top":case"bottom":return n?t?QE:KE:t?KE:QE;case"left":case"right":return t?QP:XP;default:return[]}}function ZP(e,t,n,r){const o=Bo(e);let a=JP(Cr(e),n==="start",r);return o&&(a=a.map(u=>u+"-"+o),t&&(a=a.concat(a.map($f)))),a}function al(e){return e.replace(/left|right|bottom|top/g,t=>qP[t])}function eL(e){return B({top:0,right:0,bottom:0,left:0},e)}function XE(e){return typeof e!="number"?eL(e):{top:e,right:e,bottom:e,left:e}}function ul(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function JE(e,t,n){let{reference:r,floating:o}=e;const a=hr(t),u=jf(t),c=zf(u),d=Cr(t),h=a==="y",p=r.x+r.width/2-o.width/2,E=r.y+r.height/2-o.height/2,b=r[c]/2-o[c]/2;let T;switch(d){case"top":T={x:p,y:r.y-o.height};break;case"bottom":T={x:p,y:r.y+r.height};break;case"right":T={x:r.x+r.width,y:E};break;case"left":T={x:r.x-o.width,y:E};break;default:T={x:r.x,y:r.y}}switch(Bo(t)){case"start":T[u]-=b*(n&&h?-1:1);break;case"end":T[u]+=b*(n&&h?-1:1);break}return T}const tL=(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}=JE(h,r,d),b=r,T={},x=0;for(let _=0;_<c.length;_++){const{name:S,fn:A}=c[_],{x:O,y:I,data:H,reset:Y}=yield A({x:p,y:E,initialPlacement:r,placement:b,strategy:o,middlewareData:T,rects:h,platform:u,elements:{reference:e,floating:t}});p=O!=null?O:p,E=I!=null?I:E,T=se(B({},T),{[S]:B(B({},T[S]),H)}),Y&&x<=50&&(x++,typeof Y=="object"&&(Y.placement&&(b=Y.placement),Y.rects&&(h=Y.rects===!0?yield u.getElementRects({reference:e,floating:t,strategy:o}):Y.rects),{x:p,y:E}=JE(h,b,d)),_=-1)}return{x:p,y:E,placement:b,strategy:o,middlewareData:T}});function sa(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:b=!1,padding:T=0}=Ar(t,e),x=XE(T),S=c[b?E==="floating"?"reference":"floating":E],A=ul(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,I=yield a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating),H=(yield a.isElement==null?void 0:a.isElement(I))?(yield a.getScale==null?void 0:a.getScale(I))||{x:1,y:1}:{x:1,y:1},Y=ul(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:O,offsetParent:I,strategy:d}):O);return{top:(A.top-Y.top+x.top)/H.y,bottom:(Y.bottom-A.bottom+x.bottom)/H.y,left:(A.left-Y.left+x.left)/H.x,right:(Y.right-A.right+x.right)/H.x}})}const nL=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}=Ar(e,n)||{};if(p==null)return{};const b=XE(E),T={x:r,y:o},x=jf(a),_=zf(x),S=yield c.getDimensions(p),A=x==="y",O=A?"top":"left",I=A?"bottom":"right",H=A?"clientHeight":"clientWidth",Y=u.reference[_]+u.reference[x]-T[x]-u.floating[_],M=T[x]-u.reference[x],G=yield c.getOffsetParent==null?void 0:c.getOffsetParent(p);let pe=G?G[H]:0;(!pe||!(yield c.isElement==null?void 0:c.isElement(G)))&&(pe=d.floating[H]||u.floating[_]);const re=Y/2-M/2,z=pe/2-S[_]/2-1,W=Qr(b[O],z),te=Qr(b[I],z),oe=W,de=pe-S[_]-te,be=pe/2-S[_]/2+re,Ne=Uf(oe,be,de),me=!h.arrow&&Bo(a)!=null&&be!==Ne&&u.reference[_]/2-(be<oe?W:te)-S[_]/2<0,Q=me?be<oe?be-oe:be-de:0;return{[x]:T[x]+Q,data:B({[x]:Ne,centerOffset:be-Ne-Q},me&&{alignmentOffset:Q}),reset:me}})}}),rL=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=Ar(e,n),{mainAxis:E=!0,crossAxis:b=!0,fallbackPlacements:T,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=Cr(a),I=hr(d),H=Cr(d)===d,Y=yield h.isRTL==null?void 0:h.isRTL(p.floating),M=T||(H||!S?[al(d)]:KP(d)),G=_!=="none";!T&&G&&M.push(...ZP(d,S,_,Y));const pe=[d,...M],re=yield sa(n,A),z=[];let W=((o=u.flip)==null?void 0:o.overflows)||[];if(E&&z.push(re[O]),b){const Ne=GP(a,c,Y);z.push(re[Ne[0]],re[Ne[1]])}if(W=[...W,{placement:a,overflows:z}],!z.every(Ne=>Ne<=0)){var te,oe;const Ne=(((te=u.flip)==null?void 0:te.index)||0)+1,me=pe[Ne];if(me&&(!(b==="alignment"?I!==hr(me):!1)||W.every(v=>hr(v.placement)===I?v.overflows[0]>0:!0)))return{data:{index:Ne,overflows:W},reset:{placement:me}};let Q=(oe=W.filter(ie=>ie.overflows[0]<=0).sort((ie,v)=>ie.overflows[1]-v.overflows[1])[0])==null?void 0:oe.placement;if(!Q)switch(x){case"bestFit":{var de;const ie=(de=W.filter(v=>{if(G){const D=hr(v.placement);return D===I||D==="y"}return!0}).map(v=>[v.placement,v.overflows.filter(D=>D>0).reduce((D,Z)=>D+Z,0)]).sort((v,D)=>v[1]-D[1])[0])==null?void 0:de[0];ie&&(Q=ie);break}case"initialPlacement":Q=d;break}if(a!==Q)return{reset:{placement:Q}}}return{}})}}};function ZE(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ey(e){return VP.some(t=>e[t]>=0)}const iL=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return $e(this,null,function*(){const{rects:r}=n,u=Ar(e,n),{strategy:o="referenceHidden"}=u,a=sn(u,["strategy"]);switch(o){case"referenceHidden":{const c=yield sa(n,se(B({},a),{elementContext:"reference"})),d=ZE(c,r.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:ey(d)}}}case"escaped":{const c=yield sa(n,se(B({},a),{altBoundary:!0})),d=ZE(c,r.floating);return{data:{escapedOffsets:d,escaped:ey(d)}}}default:return{}}})}}},ty=new Set(["left","top"]);function oL(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=Cr(n),c=Bo(n),d=hr(n)==="y",h=ty.has(u)?-1:1,p=a&&d?-1:1,E=Ar(t,e);let{mainAxis:b,crossAxis:T,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"&&(T=c==="end"?x*-1:x),d?{x:T*p,y:b*h}:{x:b*h,y:T*p}})}const sL=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 oL(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:se(B({},h),{placement:c})}})}}},aL=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=Ar(e,n),{mainAxis:u=!0,crossAxis:c=!1,limiter:d={fn:O=>{let{x:I,y:H}=O;return{x:I,y:H}}}}=A,h=sn(A,["mainAxis","crossAxis","limiter"]),p={x:r,y:o},E=yield sa(n,h),b=hr(Cr(a)),T=Hf(b);let x=p[T],_=p[b];if(u){const O=T==="y"?"top":"left",I=T==="y"?"bottom":"right",H=x+E[O],Y=x-E[I];x=Uf(H,x,Y)}if(c){const O=b==="y"?"top":"left",I=b==="y"?"bottom":"right",H=_+E[O],Y=_-E[I];_=Uf(H,_,Y)}const S=d.fn(se(B({},n),{[T]:x,[b]:_}));return se(B({},S),{data:{x:S.x-r,y:S.y-o,enabled:{[T]:u,[b]:c}}})})}}},uL=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:u}=t,{offset:c=0,mainAxis:d=!0,crossAxis:h=!0}=Ar(e,t),p={x:n,y:r},E=hr(o),b=Hf(E);let T=p[b],x=p[E];const _=Ar(c,t),S=typeof _=="number"?{mainAxis:_,crossAxis:0}:B({mainAxis:0,crossAxis:0},_);if(d){const I=b==="y"?"height":"width",H=a.reference[b]-a.floating[I]+S.mainAxis,Y=a.reference[b]+a.reference[I]-S.mainAxis;T<H?T=H:T>Y&&(T=Y)}if(h){var A,O;const I=b==="y"?"width":"height",H=ty.has(Cr(o)),Y=a.reference[E]-a.floating[I]+(H&&((A=u.offset)==null?void 0:A[E])||0)+(H?0:S.crossAxis),M=a.reference[E]+a.reference[I]+(H?0:((O=u.offset)==null?void 0:O[E])||0)-(H?S.crossAxis:0);x<Y?x=Y:x>M&&(x=M)}return{[b]:T,[E]:x}}}},lL=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,W=Ar(e,n),{apply:h=()=>{}}=W,p=sn(W,["apply"]),E=yield sa(n,p),b=Cr(a),T=Bo(a),x=hr(a)==="y",{width:_,height:S}=u.floating;let A,O;b==="top"||b==="bottom"?(A=b,O=T===((yield c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(O=b,A=T==="end"?"top":"bottom");const I=S-E.top-E.bottom,H=_-E.left-E.right,Y=Qr(S-E[A],I),M=Qr(_-E[O],H),G=!n.middlewareData.shift;let pe=Y,re=M;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(re=H),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(pe=I),G&&!T){const te=_n(E.left,0),oe=_n(E.right,0),de=_n(E.top,0),be=_n(E.bottom,0);x?re=_-2*(te!==0||oe!==0?te+oe:_n(E.left,E.right)):pe=S-2*(de!==0||be!==0?de+be:_n(E.top,E.bottom))}yield h(se(B({},n),{availableWidth:re,availableHeight:pe}));const z=yield c.getDimensions(d.floating);return _!==z.width||S!==z.height?{reset:{rects:!0}}:{}})}}};function ll(){return typeof window!="undefined"}function Uo(e){return ny(e)?(e.nodeName||"").toLowerCase():"#document"}function Sn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function pr(e){var t;return(t=(ny(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function ny(e){return ll()?e instanceof Node||e instanceof Sn(e).Node:!1}function Kn(e){return ll()?e instanceof Element||e instanceof Sn(e).Element:!1}function mr(e){return ll()?e instanceof HTMLElement||e instanceof Sn(e).HTMLElement:!1}function ry(e){return!ll()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof Sn(e).ShadowRoot}const cL=new Set(["inline","contents"]);function aa(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!cL.has(o)}const dL=new Set(["table","td","th"]);function fL(e){return dL.has(Uo(e))}const hL=[":popover-open",":modal"];function cl(e){return hL.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const pL=["transform","translate","scale","rotate","perspective"],mL=["transform","translate","scale","rotate","perspective","filter"],gL=["paint","layout","strict","content"];function Vf(e){const t=qf(),n=Kn(e)?Qn(e):e;return pL.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)||mL.some(r=>(n.willChange||"").includes(r))||gL.some(r=>(n.contain||"").includes(r))}function EL(e){let t=Xr(e);for(;mr(t)&&!Ho(t);){if(Vf(t))return t;if(cl(t))return null;t=Xr(t)}return null}function qf(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const yL=new Set(["html","body","#document"]);function Ho(e){return yL.has(Uo(e))}function Qn(e){return Sn(e).getComputedStyle(e)}function dl(e){return Kn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Xr(e){if(Uo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ry(e)&&e.host||pr(e);return ry(t)?t.host:t}function iy(e){const t=Xr(e);return Ho(t)?e.ownerDocument?e.ownerDocument.body:e.body:mr(t)&&aa(t)?t:iy(t)}function ua(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=iy(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),u=Sn(o);if(a){const c=Yf(u);return t.concat(u,u.visualViewport||[],aa(o)?o:[],c&&n?ua(c):[])}return t.concat(o,ua(o,[],n))}function Yf(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function oy(e){const t=Qn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=mr(e),a=o?e.offsetWidth:n,u=o?e.offsetHeight:r,c=ol(n)!==a||ol(r)!==u;return c&&(n=a,r=u),{width:n,height:r,$:c}}function Wf(e){return Kn(e)?e:e.contextElement}function zo(e){const t=Wf(e);if(!mr(t))return fr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=oy(t);let u=(a?ol(n.width):n.width)/r,c=(a?ol(n.height):n.height)/o;return(!u||!Number.isFinite(u))&&(u=1),(!c||!Number.isFinite(c))&&(c=1),{x:u,y:c}}const TL=fr(0);function sy(e){const t=Sn(e);return!qf()||!t.visualViewport?TL:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function bL(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Sn(e)?!1:t}function zi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=Wf(e);let u=fr(1);t&&(r?Kn(r)&&(u=zo(r)):u=zo(e));const c=bL(a,n,r)?sy(a):fr(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 b=Sn(a),T=r&&Kn(r)?Sn(r):r;let x=b,_=Yf(x);for(;_&&r&&T!==x;){const S=zo(_),A=_.getBoundingClientRect(),O=Qn(_),I=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+=I,h+=H,x=Sn(_),_=Yf(x)}}return ul({width:p,height:E,x:d,y:h})}function fl(e,t){const n=dl(e).scrollLeft;return t?t.left+n:zi(pr(e)).left+n}function ay(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-fl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function xL(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",u=pr(r),c=t?cl(t.floating):!1;if(r===u||c&&a)return n;let d={scrollLeft:0,scrollTop:0},h=fr(1);const p=fr(0),E=mr(r);if((E||!E&&!a)&&((Uo(r)!=="body"||aa(u))&&(d=dl(r)),mr(r))){const T=zi(r);h=zo(r),p.x=T.x+r.clientLeft,p.y=T.y+r.clientTop}const b=u&&!E&&!a?ay(u,d):fr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+p.x+b.x,y:n.y*h.y-d.scrollTop*h.y+p.y+b.y}}function wL(e){return Array.from(e.getClientRects())}function _L(e){const t=pr(e),n=dl(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+fl(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 uy=25;function SL(e,t){const n=Sn(e),r=pr(e),o=n.visualViewport;let a=r.clientWidth,u=r.clientHeight,c=0,d=0;if(o){a=o.width,u=o.height;const p=qf();(!p||p&&t==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const h=fl(r);if(h<=0){const p=r.ownerDocument,E=p.body,b=getComputedStyle(E),T=p.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,x=Math.abs(r.clientWidth-E.clientWidth-T);x<=uy&&(a-=x)}else h<=uy&&(a+=h);return{width:a,height:u,x:c,y:d}}const vL=new Set(["absolute","fixed"]);function AL(e,t){const n=zi(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=mr(e)?zo(e):fr(1),u=e.clientWidth*a.x,c=e.clientHeight*a.y,d=o*a.x,h=r*a.y;return{width:u,height:c,x:d,y:h}}function ly(e,t,n){let r;if(t==="viewport")r=SL(e,n);else if(t==="document")r=_L(pr(e));else if(Kn(t))r=AL(t,n);else{const o=sy(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return ul(r)}function cy(e,t){const n=Xr(e);return n===t||!Kn(n)||Ho(n)?!1:Qn(n).position==="fixed"||cy(n,t)}function CL(e,t){const n=t.get(e);if(n)return n;let r=ua(e,[],!1).filter(c=>Kn(c)&&Uo(c)!=="body"),o=null;const a=Qn(e).position==="fixed";let u=a?Xr(e):e;for(;Kn(u)&&!Ho(u);){const c=Qn(u),d=Vf(u);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&vL.has(o.position)||aa(u)&&!d&&cy(e,u))?r=r.filter(p=>p!==u):o=c,u=Xr(u)}return t.set(e,r),r}function kL(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const u=[...n==="clippingAncestors"?cl(t)?[]:CL(t,this._c):[].concat(n),r],c=u[0],d=u.reduce((h,p)=>{const E=ly(t,p,o);return h.top=_n(E.top,h.top),h.right=Qr(E.right,h.right),h.bottom=Qr(E.bottom,h.bottom),h.left=_n(E.left,h.left),h},ly(t,c,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function NL(e){const{width:t,height:n}=oy(e);return{width:t,height:n}}function OL(e,t,n){const r=mr(t),o=pr(t),a=n==="fixed",u=zi(e,!0,a,t);let c={scrollLeft:0,scrollTop:0};const d=fr(0);function h(){d.x=fl(o)}if(r||!r&&!a)if((Uo(t)!=="body"||aa(o))&&(c=dl(t)),r){const T=zi(t,!0,a,t);d.x=T.x+t.clientLeft,d.y=T.y+t.clientTop}else o&&h();a&&!r&&o&&h();const p=o&&!r&&!a?ay(o,c):fr(0),E=u.left+c.scrollLeft-d.x-p.x,b=u.top+c.scrollTop-d.y-p.y;return{x:E,y:b,width:u.width,height:u.height}}function Gf(e){return Qn(e).position==="static"}function dy(e,t){if(!mr(e)||Qn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return pr(e)===n&&(n=n.ownerDocument.body),n}function fy(e,t){const n=Sn(e);if(cl(e))return n;if(!mr(e)){let o=Xr(e);for(;o&&!Ho(o);){if(Kn(o)&&!Gf(o))return o;o=Xr(o)}return n}let r=dy(e,t);for(;r&&fL(r)&&Gf(r);)r=dy(r,t);return r&&Ho(r)&&Gf(r)&&!Vf(r)?n:r||EL(e)||n}const IL=function(e){return $e(this,null,function*(){const t=this.getOffsetParent||fy,n=this.getDimensions,r=yield n(e.floating);return{reference:OL(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function RL(e){return Qn(e).direction==="rtl"}const PL={convertOffsetParentRelativeRectToViewportRelativeRect:xL,getDocumentElement:pr,getClippingRect:kL,getOffsetParent:fy,getElementRects:IL,getClientRects:wL,getDimensions:NL,getScale:zo,isElement:Kn,isRTL:RL};function hy(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function LL(e,t){let n=null,r;const o=pr(e);function a(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function u(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),a();const h=e.getBoundingClientRect(),{left:p,top:E,width:b,height:T}=h;if(c||t(),!b||!T)return;const x=sl(E),_=sl(o.clientWidth-(p+b)),S=sl(o.clientHeight-(E+T)),A=sl(p),I={rootMargin:-x+"px "+-_+"px "+-S+"px "+-A+"px",threshold:_n(0,Qr(1,d))||1};let H=!0;function Y(M){const G=M[0].intersectionRatio;if(G!==d){if(!H)return u();G?u(!1,G):r=setTimeout(()=>{u(!1,1e-7)},1e3)}G===1&&!hy(h,e.getBoundingClientRect())&&u(),H=!1}try{n=new IntersectionObserver(Y,se(B({},I),{root:o.ownerDocument}))}catch(M){n=new IntersectionObserver(Y,I)}n.observe(e)}return u(!0),a}function DL(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=Wf(e),p=o||a?[...h?ua(h):[],...ua(t)]:[];p.forEach(A=>{o&&A.addEventListener("scroll",n,{passive:!0}),a&&A.addEventListener("resize",n)});const E=h&&c?LL(h,n):null;let b=-1,T=null;u&&(T=new ResizeObserver(A=>{let[O]=A;O&&O.target===h&&T&&(T.unobserve(t),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var I;(I=T)==null||I.observe(t)})),n()}),h&&!d&&T.observe(h),T.observe(t));let x,_=d?zi(e):null;d&&S();function S(){const A=zi(e);_&&!hy(_,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=T)==null||A.disconnect(),T=null,d&&cancelAnimationFrame(x)}}const ML=sL,FL=aL,BL=rL,UL=lL,HL=iL,zL=nL,jL=uL,$L=(e,t,n)=>{const r=new Map,o=B({platform:PL},n),a=se(B({},o.platform),{_c:r});return tL(e,t,se(B({},o),{platform:a}))};function py(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 se(B({},o),{toJSON:()=>o})}function VL(e){if(!e)return py();const{x:t,y:n,width:r,height:o}=e;return py(t,n,r,o)}function qL(e,t){return{contextElement:Mt(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?VL(r):n.getBoundingClientRect()}}}var la=e=>({variable:e,reference:`var(${e})`}),kr={arrowSize:la("--arrow-size"),arrowSizeHalf:la("--arrow-size-half"),arrowBg:la("--arrow-background"),transformOrigin:la("--transform-origin"),arrowOffset:la("--arrow-offset")},YL=e=>e==="top"||e==="bottom"?"y":"x";function WL(e,t){return{name:"transformOrigin",fn(n){var re,z,W,te,oe;const{elements:r,middlewareData:o,placement:a,rects:u,y:c}=n,d=a.split("-")[0],h=YL(d),p=((re=o.arrow)==null?void 0:re.x)||0,E=((z=o.arrow)==null?void 0:z.y)||0,b=(t==null?void 0:t.clientWidth)||0,T=(t==null?void 0:t.clientHeight)||0,x=p+b/2,_=E+T/2,S=Math.abs(((W=o.shift)==null?void 0:W.y)||0),A=u.reference.height/2,O=T/2,I=(oe=(te=e.offset)==null?void 0:te.mainAxis)!=null?oe:e.gutter,H=typeof I=="number"?I+O:I!=null?I:O,Y=S>H,M={top:`${x}px calc(100% + ${H}px)`,bottom:`${x}px ${-H}px`,left:`calc(100% + ${H}px) ${_}px`,right:`${-H}px ${_}px`}[d],G=`${x}px ${u.reference.y+A-c}px`,pe=!!e.overlap&&h==="y"&&Y;return r.floating.style.setProperty(kr.transformOrigin.variable,pe?G:M),{data:{transformOrigin:pe?G:M}}}}}var GL={name:"rects",fn({rects:e}){return{data:e}}},KL=e=>{if(e)return{name:"shiftArrow",fn({placement:t,middlewareData:n}){if(!n.arrow)return{};const{x:r,y:o}=n.arrow,a=t.split("-")[0];return Object.assign(e.style,{left:r!=null?`${r}px`:"",top:o!=null?`${o}px`:"",[a]:`calc(100% + ${kr.arrowOffset.reference})`}),{}}}};function QL(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var XL={strategy:"absolute",placement:"bottom",listeners:!0,gutter:8,flip:!0,slide:!0,overlap:!1,sameWidth:!1,fitViewport:!1,overflowPadding:8,arrowPadding:4};function my(e,t){const n=e.devicePixelRatio||1;return Math.round(t*n)/n}function Kf(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function JL(e,t,n){const r=e||t.createElement("div");return zL({element:r,padding:n.arrowPadding})}function ZL(e,t){var n;if(!pR((n=t.offset)!=null?n:t.gutter))return ML(({placement:r})=>{var p,E,b,T;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}=QL(r),d=c?void 0:t.shift,h=(T=(b=t.offset)==null?void 0:b.crossAxis)!=null?T:d;return _f({crossAxis:h,mainAxis:u,alignmentAxis:t.shift})})}function e6(e){if(!e.flip)return;const t=Kf(e.boundary);return BL(se(B({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function t6(e){if(!e.slide&&!e.overlap)return;const t=Kf(e.boundary);return FL(se(B({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:jL()}))}function n6(e){return UL({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 r6(e){var t;if(e.hideWhenDetached)return HL({strategy:"referenceHidden",boundary:(t=Kf(e.boundary))!=null?t:"clippingAncestors"})}function i6(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function o6(e,t,n={}){const r=qL(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},XL,n),a=t.querySelector("[data-part=arrow]"),u=[ZL(a,o),e6(o),t6(o),JL(a,t.ownerDocument,o),KL(a),WL({gutter:o.gutter,offset:o.offset,overlap:o.overlap},a),n6(o),r6(o),GL],{placement:c,strategy:d,onComplete:h,onPositioned:p}=o,E=()=>$e(null,null,function*(){var H;if(!r||!t)return;const _=yield $L(r,t,{placement:c,middleware:u,strategy:d});h==null||h(_),p==null||p({placed:!0});const S=Oo(t),A=my(S,_.x),O=my(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 I=t.firstElementChild;if(I){const Y=Ro(I);t.style.setProperty("--z-index",Y.zIndex)}}),b=()=>$e(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),p==null||p({placed:!0})):yield E()}),T=i6(o.listeners),x=o.listeners?DL(r,t,b,T):_R;return b(),()=>{x==null||x(),p==null||p({placed:!1})}}function gy(e,t,n={}){const c=n,{defer:r}=c,o=sn(c,["defer"]),a=r?Nt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof t=="function"?t():t;u.push(o6(d,h,o))})),()=>{u.forEach(d=>d==null?void 0:d())}}var s6={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function a6(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:kr.arrowSize.reference,height:kr.arrowSize.reference,[kr.arrowSizeHalf.variable]:`calc(${kr.arrowSize.reference} / 2)`,[kr.arrowOffset.variable]:`calc(${kr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?s6[t.split("-")[0]]:void 0,background:kr.arrowBg.reference,top:"0",left:"0",width:"100%",height:"100%",position:"absolute",zIndex:"inherit"},floating:{position:o,isolation:"isolate",minWidth:n?void 0:"max-content",width:n?"var(--reference-width)":void 0,maxWidth:r?"var(--available-width)":void 0,maxHeight:r?"var(--available-height)":void 0,pointerEvents:t?void 0:"none",top:"0px",left:"0px",transform:t?"translate3d(var(--x), var(--y), 0)":"translate3d(0, -100vh, 0)",zIndex:"var(--z-index)"}}}var jo=new WeakMap,hl=new WeakMap,pl={},Qf=0,Ey=e=>e&&(e.host||Ey(e.parentNode)),u6=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=Ey(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),l6=new Set(["script","output","status","next-route-announcer"]),c6=e=>l6.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=u6(n,Array.isArray(e)?e:[e]);pl[r]||(pl[r]=new WeakMap);const c=pl[r],d=[],h=new Set,p=new Set(u),E=T=>{!T||h.has(T)||(h.add(T),E(T.parentNode))};u.forEach(T=>{E(T),a&&Mt(T)&&OE(T,x=>{E(x)})});const b=T=>{!T||p.has(T)||Array.prototype.forEach.call(T.children,x=>{if(h.has(x))b(x);else try{if(c6(x))return;const S=x.getAttribute(o)==="true",A=(jo.get(x)||0)+1,O=(c.get(x)||0)+1;jo.set(x,A),c.set(x,O),d.push(x),A===1&&S&&hl.set(x,!0),O===1&&x.setAttribute(r,""),S||x.setAttribute(o,"true")}catch(_){console.error("[zag-js > ariaHidden] cannot operate on ",x,_)}})};return b(n),h.clear(),Qf++,()=>{d.forEach(T=>{const x=jo.get(T)-1,_=c.get(T)-1;jo.set(T,x),c.set(T,_),x||(hl.has(T)||T.removeAttribute(o),hl.delete(T)),_||T.removeAttribute(r)}),Qf--,Qf||(jo=new WeakMap,jo=new WeakMap,hl=new WeakMap,pl={})}},f6=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,h6=(e,t=f6(e),n="data-aria-hidden",r=!0)=>{if(t)return d6(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},p6=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function yy(e,t={}){const{defer:n=!0}=t,r=n?p6:a=>a(),o=[];return o.push(r(()=>{const u=(typeof e=="function"?e():e).filter(Boolean);u.length!==0&&o.push(h6(u))})),()=>{o.forEach(a=>a==null?void 0:a())}}function m6(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 g6(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 Ty="pointerdown.outside",by="focus.outside";function E6(e){for(const t of e)if(Mt(t)&&dr(t))return!0;return!1}var xy=e=>"clientY"in e;function y6(e,t){if(!xy(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 T6(e,t){return e.y<=t.y&&t.y<=e.y+e.height&&e.x<=t.x&&t.x<=e.x+e.width}function wy(e,t){if(!t||!xy(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 T6(u,c)?r||a:!1}function b6(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:a,defer:u,followControlledElements:c=!0}=t;if(!e)return;const d=cr(e),h=Oo(e),p=m6(h),E=g6(h);function b(I,H){if(!Mt(H)||!H.isConnected||No(e,H)||y6(e,I)||c&&NE(e,H))return!1;const Y=d.querySelector(`[aria-controls="${e.id}"]`);if(Y){const G=Rf(Y);if(wy(I,G))return!1}const M=Rf(e);return wy(I,M)?!1:!(n!=null&&n(H))}const T=new Set,x=Fi(e==null?void 0:e.getRootNode());function _(I){function H(Y){var re,z;const M=u&&!IE()?Nt:W=>W(),G=Y!=null?Y:I,pe=(z=(re=G==null?void 0:G.composedPath)==null?void 0:re.call(G))!=null?z:[G==null?void 0:G.target];M(()=>{const W=x?pe[0]:Gn(I);if(!(!e||!b(I,W))){if(o||a){const te=wf(o,a);e.addEventListener(Ty,te,{once:!0})}_y(e,Ty,{bubbles:!1,cancelable:!0,detail:{originalEvent:G,contextmenu:iP(G),focusable:E6(pe),target:W}})}})}I.pointerType==="touch"?(T.forEach(Y=>Y()),T.add(Ft(d,"click",H,{once:!0})),T.add(E.addEventListener("click",H,{once:!0})),T.add(p.addEventListener("click",H,{once:!0}))):H()}const S=new Set,A=setTimeout(()=>{S.add(Ft(d,"pointerdown",_,!0)),S.add(E.addEventListener("pointerdown",_,!0)),S.add(p.addEventListener("pointerdown",_,!0))},0);function O(I){(u?Nt:Y=>Y())(()=>{var G,pe;const Y=(pe=(G=I==null?void 0:I.composedPath)==null?void 0:G.call(I))!=null?pe:[I==null?void 0:I.target],M=x?Y[0]:Gn(I);if(!(!e||!b(I,M))){if(r||a){const re=wf(r,a);e.addEventListener(by,re,{once:!0})}_y(e,by,{bubbles:!1,cancelable:!0,detail:{originalEvent:I,contextmenu:!1,focusable:dr(M),target:M}})}})}return IE()||(S.add(Ft(d,"focusin",O,!0)),S.add(E.addEventListener("focusin",O,!0)),S.add(p.addEventListener("focusin",O,!0))),()=>{clearTimeout(A),T.forEach(I=>I()),S.forEach(I=>I())}}function x6(e,t){const{defer:n}=t,r=n?Nt:a=>a(),o=[];return o.push(r(()=>{const a=typeof e=="function"?e():e;o.push(b6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}function _y(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function w6(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return Ft(cr(e),"keydown",n,{capture:!0})}var Sy="layer:request-dismiss",Dn={layers:[],branches:[],count(){return this.layers.length},pointerBlockingLayers(){return this.layers.filter(e=>e.pointerBlocking)},topMostPointerBlockingLayer(){return[...this.pointerBlockingLayers()].slice(-1)[0]},hasPointerBlockingLayer(){return this.pointerBlockingLayers().length>0},isBelowPointerBlockingLayer(e){var r;const t=this.indexOf(e),n=this.topMostPointerBlockingLayer()?this.indexOf((r=this.topMostPointerBlockingLayer())==null?void 0:r.node):-1;return t<n},isTopMost(e){const t=this.layers[this.count()-1];return(t==null?void 0:t.node)===e},getNestedLayers(e){return Array.from(this.layers).slice(this.indexOf(e)+1)},getLayersByType(e){return this.layers.filter(t=>t.type===e)},getNestedLayersByType(e,t){const n=this.indexOf(e);return n===-1?[]:this.layers.slice(n+1).filter(r=>r.type===t)},getParentLayerOfType(e,t){const n=this.indexOf(e);if(!(n<=0))return this.layers.slice(0,n).reverse().find(r=>r.type===t)},countNestedLayersOfType(e,t){return this.getNestedLayersByType(e,t).length},isInNestedLayer(e,t){return this.getNestedLayers(e).some(n=>No(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>No(t,e))},add(e){this.layers.push(e),this.syncLayers()},addBranch(e){this.branches.push(e)},remove(e){const t=this.indexOf(e);t<0||(t<this.count()-1&&this.getNestedLayers(e).forEach(r=>Dn.dismiss(r.node,e)),this.layers.splice(t,1),this.syncLayers())},removeBranch(e){const t=this.branches.indexOf(e);t>=0&&this.branches.splice(t,1)},syncLayers(){this.layers.forEach((e,t)=>{e.node.style.setProperty("--layer-index",`${t}`),e.node.removeAttribute("data-nested"),e.node.removeAttribute("data-has-nested"),this.getParentLayerOfType(e.node,e.type)&&e.node.setAttribute("data-nested",e.type);const r=this.countNestedLayersOfType(e.node,e.type);r>0&&e.node.setAttribute("data-has-nested",e.type),e.node.style.setProperty("--nested-layer-count",`${r}`)})},indexOf(e){return this.layers.findIndex(t=>t.node===e)},dismiss(e,t){const n=this.indexOf(e);if(n===-1)return;const r=this.layers[n];S6(e,Sy,o=>{var a;(a=r.requestDismiss)==null||a.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),_6(e,Sy,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function _6(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 S6(e,t,n){e.addEventListener(t,n,{once:!0})}var vy;function Ay(){Dn.layers.forEach(({node:e})=>{e.style.pointerEvents=Dn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function v6(e){e.style.pointerEvents=""}function A6(e,t){const n=cr(e),r=[];return Dn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(vy=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[a,u]=CP(()=>{const c=o();return Mt(c)?c:null},{timeout:1e3});a.then(c=>r.push(el(c,{pointerEvents:"auto"}))),r.push(u)}),()=>{Dn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=vy,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function C6(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Sf("[@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),Ay();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 b(_){var S;Dn.isTopMost(e)&&((S=t.onEscapeKeyDown)==null||S.call(t,_),!_.defaultPrevented&&r&&(_.preventDefault(),r()))}function T(_){var I;if(!e)return!1;const S=typeof u=="function"?u():u,A=Array.isArray(S)?S:[S],O=(I=t.persistentElements)==null?void 0:I.map(H=>H()).filter(Mt);return O&&A.push(...O),A.some(H=>No(H,_))||Dn.isInNestedLayer(e,_)}const x=[a?A6(e,t.persistentElements):void 0,w6(e,b),x6(e,{exclude:T,onFocusOutside:E,onPointerDownOutside:p,defer:t.defer})];return()=>{Dn.remove(e),Ay(),v6(e),x.forEach(_=>_==null?void 0:_())}}function Cy(e,t){const{defer:n}=t,r=n?Nt:a=>a(),o=[];return o.push(r(()=>{const a=Co(e)?e():e;o.push(C6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}var k6=Object.defineProperty,N6=(e,t,n)=>t in e?k6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ht=(e,t,n)=>N6(e,typeof t!="symbol"?t+"":t,n),ky={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()}},O6=[],I6=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||Qu(o))a&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let u,c=!0;if(this.state.mostRecentlyFocusedNode)if(ra(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=>ra(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(da(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}da(this.config.allowOutsideClick,r)||r.preventDefault()}}),ht(this,"handleClick",r=>{const o=Gn(r);this.findContainerIndex(o,r)>=0||da(this.config.clickOutsideDeactivates,r)||da(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;ca(r)&&r.preventDefault(),this.tryFocus(a)}}),ht(this,"handleEscapeKey",r=>{R6(r)&&da(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 KR(h)?!0:h.id&&!this.state.containers.some(p=>p.contains(h))?QR(h):!1}):!1)&&this.state.active&&!this.state.paused&&(this.updateTabbableNodes(),this.updatePortalContainers())})}),ht(this,"updateObservedNodes",()=>{var r;(r=this._mutationObserver)==null||r.disconnect(),this.state.active&&!this.state.paused&&(this.state.containers.map(o=>{var a;(a=this._mutationObserver)==null||a.observe(o,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}),this.portalContainers.forEach(o=>{this.observePortalContainer(o)}))}),ht(this,"getInitialFocusNode",()=>{let r=this.getNodeForOption("initialFocus",{hasFallback:!0});if(r===!1)return!1;if(r===void 0||r&&!dr(r)){const o=Io(this.doc);if(o&&this.findContainerIndex(o)>=0)r=o;else{const a=this.state.tabbableGroups[0];r=a&&a.firstTabbableNode||this.getNodeForOption("fallbackFocus")}}else r===null&&(r=this.getNodeForOption("fallbackFocus"));if(!r)throw new Error("Your focus-trap needs to have at least one focusable element");return r.isConnected||(r=this.getNodeForOption("fallbackFocus")),r}),ht(this,"tryFocus",r=>{if(r!==!1&&r!==Io(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,P6(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(),ky.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=()=>{Ny(()=>{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||dr(u)&&!Bi(u)&&!(h!=null&&h.nextTabbableNode(u,!1)))&&(p=d),p>=0){const E=p===0?this.state.tabbableGroups.length-1:p-1,b=this.state.tabbableGroups[E];c=ra(u)>=0?b.lastTabbableNode:b.lastDomTabbableNode}else ca(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||dr(u)&&!Bi(u)&&!(h!=null&&h.nextTabbableNode(u)))&&(p=d),p>=0){const E=p===this.state.tabbableGroups.length-1?0:p+1,b=this.state.tabbableGroups[E];c=ra(u)>=0?b.firstTabbableNode:b.firstDomTabbableNode}else ca(o)||(c=h==null?void 0:h.nextTabbableNode(u))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||O6;const n=B({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return ca(r)&&!r.shiftKey},isKeyBackward(r){return ca(r)&&r.shiftKey}},t);this.doc=n.document||cr(Array.isArray(e)?e[0]:e),this.config=n,this.updateContainerElements(e),this.setupMutationObserver()}addPortalContainer(e){const t=e.parentElement;t&&!this.portalContainers.has(t)&&(this.portalContainers.add(t),this.state.active&&!this.state.paused&&this.observePortalContainer(t))}observePortalContainer(e){var t;(t=this._mutationObserver)==null||t.observe(e,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}updatePortalContainers(){this.config.followControlledElements&&this.state.containers.forEach(e=>{YR(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?NE(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Po(e,{getShadowRoot:this.config.getShadowRoot}),n=BE(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(ra(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 b=n.indexOf(h);if(!(b<0)){if(p){for(let T=b+1;T<n.length;T++)if(Bi(n[T]))return n[T]}else for(let T=b-1;T>=0;T--)if(Bi(n[T]))return n[T]}}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 ky.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Ny(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(Ft(this.doc,"focusin",this.handleFocus,!0),Ft(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),Ft(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),Ft(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),Ft(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),Ft(this.doc,"keydown",this.handleEscapeKey)),this}removeListeners(){if(this.state.active)return this.listenerCleanups.forEach(e=>e()),this.listenerCleanups=[],this}activate(e){if(this.state.active)return this;const t=this.getOption(e,"onActivate"),n=this.getOption(e,"onPostActivate"),r=this.getOption(e,"checkCanFocusTrap");r||this.updateTabbableNodes(),this.state.active=!0,this.state.paused=!1,this.state.nodeFocusedBeforeActivation=Io(this.doc),t==null||t();const o=()=>{r&&this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),n==null||n()};return r?(r(this.state.containers.concat()).then(o,o),this):(o(),this)}},ca=e=>e.key==="Tab",da=(e,...t)=>typeof e=="function"?e(...t):e,R6=e=>!e.isComposing&&e.key==="Escape",Ny=e=>setTimeout(e,0),P6=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function Oy(e,t={}){let n;const r=Nt(()=>{const o=typeof e=="function"?e():e;if(o){n=new I6(o,se(B({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:cr(o)}));try{n.activate()}catch(a){}}});return function(){n==null||n.deactivate(),r()}}var Xf="data-scroll-lock";function L6(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function Iy(e){const t=Ro(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function Ry(e){var T;const t=e!=null?e:document,n=(T=t.defaultView)!=null?T:window,{documentElement:r,body:o}=t;if(o.hasAttribute(Xf))return;const u=Iy(r)||Iy(o),c=n.innerWidth-r.clientWidth;o.setAttribute(Xf,"");const d=()=>vP(r,"--scrollbar-width",`${c}px`),h=L6(r),p=()=>{const x={overflow:"hidden"};return!u&&c>0&&(x[h]=`${c}px`),el(o,x)},E=()=>{var Y,M;const{scrollX:x,scrollY:_,visualViewport:S}=n,A=(Y=S==null?void 0:S.offsetLeft)!=null?Y:0,O=(M=S==null?void 0:S.offsetTop)!=null?M:0,I={position:"fixed",overflow:"hidden",top:`${-(_-Math.floor(O))}px`,left:`${-(x-Math.floor(A))}px`,right:"0"};!u&&c>0&&(I[h]=`${c}px`);const H=el(o,I);return()=>{H==null||H(),n.scrollTo({left:x,top:_,behavior:"instant"})}},b=[d(),Xu()?E():p()];return()=>{b.forEach(x=>x==null?void 0:x()),o.removeAttribute(Xf)}}var D6=Hi("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),gr=D6.build(),Py=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},Ly=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},Jf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},Dy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},M6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},Zf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},eh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},F6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},My=e=>e.getById(Py(e)),$o=e=>e.getById(Ly(e)),Vo=e=>e.getById(Jf(e)),Fy=e=>e.getById(Dy(e)),B6=e=>e.getById(Zf(e)),U6=e=>e.getById(eh(e));function H6(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"),b=a6(se(B({},u("positioning")),{placement:h}));return{portalled:p,open:d,setOpen(T){n.matches("open")!==T&&o({type:T?"OPEN":"CLOSE"})},reposition(T={}){o({type:"POSITIONING.SET",options:T})},getArrowProps(){return t.element(se(B({id:M6(c)},gr.arrow.attrs),{dir:u("dir"),style:b.arrow}))},getArrowTipProps(){return t.element(se(B({},gr.arrowTip.attrs),{dir:u("dir"),style:b.arrowTip}))},getAnchorProps(){return t.element(se(B({},gr.anchor.attrs),{dir:u("dir"),id:Py(c)}))},getTriggerProps(){return t.button(se(B({},gr.trigger.attrs),{dir:u("dir"),type:"button","data-placement":h,id:Ly(c),"aria-haspopup":"dialog","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":Jf(c),onPointerDown(T){RE(T)&&nP()&&T.currentTarget.focus()},onClick(T){T.defaultPrevented||o({type:"TOGGLE"})},onBlur(T){o({type:"TRIGGER_BLUR",target:T.relatedTarget})}}))},getIndicatorProps(){return t.element(se(B({},gr.indicator.attrs),{dir:u("dir"),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(se(B({id:Dy(c)},gr.positioner.attrs),{dir:u("dir"),style:b.floating}))},getContentProps(){return t.element(se(B({},gr.content.attrs),{dir:u("dir"),id:Jf(c),tabIndex:-1,role:"dialog","aria-modal":AE(u("modal")),hidden:!d,"data-state":d?"open":"closed","data-expanded":ko(d),"aria-labelledby":E.title?Zf(c):void 0,"aria-describedby":E.description?eh(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(se(B({},gr.title.attrs),{id:Zf(c),dir:u("dir")}))},getDescriptionProps(){return t.element(se(B({},gr.description.attrs),{id:eh(c),dir:u("dir")}))},getCloseTriggerProps(){return t.button(se(B({},gr.closeTrigger.attrs),{dir:u("dir"),id:F6(c),type:"button","aria-label":"close",onClick(T){T.defaultPrevented||(T.stopPropagation(),o({type:"CLOSE"}))}}))}}}var z6={props({props:e}){return se(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=My(n))!=null?a:$o(n);return gy(r,()=>Fy(n),se(B({},t("positioning")),{defer:!0,onComplete(u){e.set("currentPlacement",u.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Vo(n);let o=!0;return Cy(r,{type:"popover",pointerBlocking:t("modal"),exclude:$o(n),defer:!0,onEscapeKeyDown(a){var u;(u=t("onEscapeKeyDown"))==null||u(a),!t("closeOnEscape")&&a.preventDefault()},onInteractOutside(a){var u;(u=t("onInteractOutside"))==null||u(a),!a.defaultPrevented&&(o=!(a.detail.focusable||a.detail.contextmenu),t("closeOnInteractOutside")||a.preventDefault())},onPointerDownOutside:t("onPointerDownOutside"),onFocusOutside:t("onFocusOutside"),persistentElements:t("persistentElements"),onRequestDismiss:t("onRequestDismiss"),onDismiss(){e({type:"CLOSE",src:"interact-outside",restoreFocus:o})}})},proxyTabFocus({prop:e,scope:t}){return e("modal")||!e("portalled")?void 0:_P(()=>Vo(t),{triggerElement:$o(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?yy(()=>[Vo(t),$o(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return Ry(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?Oy(()=>Vo(t),{initialFocus:()=>UE({root:Vo(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")}),getShadowRoot:!0}):void 0}},actions:{reposition({event:e,prop:t,scope:n,context:r}){var u;const o=(u=My(n))!=null?u:$o(n);gy(o,()=>Fy(n),se(B(B({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){Nt(()=>{Object.assign(e.get("renderedElements"),{title:!!B6(t),description:!!U6(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||Nt(()=>{const n=UE({root:Vo(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")});n==null||n.focus({preventScroll:!0})})},setFinalFocus({event:e,scope:t}){var r,o;const n=(o=e.restoreFocus)!=null?o:(r=e.previousEvent)==null?void 0:r.restoreFocus;n!=null&&!n||Nt(()=>{const a=$o(t);a==null||a.focus({preventScroll:!0})})},invokeOnOpen({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!0})})},invokeOnClose({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!1})})},toggleVisibility({event:e,send:t,prop:n}){t({type:n("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:e})}}}};Mo()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[WF,ml]=Ui({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[GF,th]=Ui({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),j6=e=>{const t=X.useId(),{getRootNode:n}=ml(),{dir:r}=th(),o=B({id:t,dir:r,getRootNode:n},e),a=nl(z6,o);return H6(a,Df)},$6=e=>{const[t,u]=GE(e),c=u,{children:n}=c,r=sn(c,["children"]),o=j6(r),a=Bf(Ot({present:o.open},t));return P.jsx(BP,{value:o,children:P.jsx(qE,{value:a,children:n})})},By=X.forwardRef((e,t)=>{const n=Ff(),r=ia(),o=Ot(se(B({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return P.jsx(Kt.button,se(B({},o),{ref:t}))});By.displayName="PopoverTrigger";function V6(e){return tn({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 q6(e){return tn({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 Y6(e){return tn({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 W6(e){return tn({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 Uy(e){return tn({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 G6=({className:e,componentType:t,children:n})=>{const[r,o]=X.useState(!1),{globalClassName:a}=kt(),u=h=>{o(h.open)},c=X.useCallback(()=>{o(!1)},[]),d=X.useMemo(()=>({closeMenu:c}),[c]);return P.jsxs($6,{open:r,onOpenChange:u,positioning:{placement:"bottom-end"},children:[P.jsx(By,{"aria-label":`Overflow menu for ${t}`,className:ae(`${ee}-overflow-menu-button-trigger`,`${ee}-icon-button`,a,e,`cim-${t}-component`),children:P.jsx(Uy,{})}),P.jsx(WE,{children:P.jsx(YE,{className:ae(`${ee}-overflow-menu-list`,a,`cim-${t}-component`),children:P.jsx(TE.Provider,{value:d,children:n})})})]})};function Hy(e){return tn({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 zy(e){return tn({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[K6,ji]=Ui({name:"CarouselContext",hookName:"useCarouselContext",providerName:"<CarouselProvider />"}),jy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getControlProps(),e);return P.jsx(Kt.div,se(B(B({},r),e),{ref:t}))});jy.displayName="CarouselControl";const $y=X.forwardRef((e,t)=>{const[n,r]=oa()(e,["readOnly","index"]),o=ji(),a=Ot(o.getIndicatorProps(n),r);return P.jsx(Kt.button,se(B({},a),{ref:t}))});$y.displayName="CarouselIndicator";const Vy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getIndicatorGroupProps(),e);return P.jsx(Kt.div,se(B({},r),{ref:t}))});Vy.displayName="CarouselIndicatorGroup";const qy=X.forwardRef((e,t)=>{const[n,r]=oa()(e,["index","snapAlign"]),o=ji(),a=Ot(o.getItemProps(n),r);return P.jsx(Kt.div,se(B({},a),{ref:t}))});qy.displayName="CarouselItem";const Yy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getItemGroupProps(),e);return P.jsx(Kt.div,se(B({},r),{ref:t}))});Yy.displayName="CarouselItemGroup";const Wy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getNextTriggerProps(),e);return P.jsx(Kt.button,se(B({},r),{ref:t}))});Wy.displayName="CarouselNextTrigger";const Gy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getPrevTriggerProps(),e);return P.jsx(Kt.button,se(B({},r),{ref:t}))});Gy.displayName="CarouselPrevTrigger";function Q6(e){const t=Ro(e),n=e.getBoundingClientRect();let r=t.getPropertyValue("scroll-padding-left").replace("auto","0px"),o=t.getPropertyValue("scroll-padding-top").replace("auto","0px"),a=t.getPropertyValue("scroll-padding-right").replace("auto","0px"),u=t.getPropertyValue("scroll-padding-bottom").replace("auto","0px");function c(b,T){let x=parseFloat(b);return/%/.test(b)&&(x/=100,x*=T),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 X6(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 Ky(e){let t=[];for(const n of e.children)t=t.concat(n,Ky(n));return t}function Qy(e,t=!1){const n=e.getBoundingClientRect(),r={x:{start:[],center:[],end:[]},y:{start:[],center:[],end:[]}},o=t?Ky(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(!X6(n,E,u))continue;const b=Ro(p);let[T,x]=b.getPropertyValue("scroll-snap-align").split(" ");typeof x=="undefined"&&(x=T);const _=a==="x"?x:T,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 Xy(e){const t=e.getBoundingClientRect(),n=Q6(e),r=Qy(e),o={x:e.scrollWidth-e.offsetWidth,y:e.scrollHeight-e.offsetHeight};return{x:Jy([...r.x.start.map(a=>a.position-n.x.before),...r.x.center.map(a=>a.position-t.width/2),...r.x.end.map(a=>a.position-t.width+n.x.after)].map(Zy(0,o.x))),y:Jy([...r.y.start.map(a=>a.position-n.y.before),...r.y.center.map(a=>a.position-t.height/2),...r.y.end.map(a=>a.position-t.height+n.y.after)].map(Zy(0,o.y)))}}function J6(e,t,n){const r=Qy(e),o=[...r[t].start,...r[t].center,...r[t].end];for(const a of o)if(n(a.node))return a.position}var Jy=e=>[...new Set(e)],Zy=(e,t)=>n=>Math.max(e,Math.min(t,n)),Z6=Hi("carousel").parts("root","itemGroup","item","control","nextTrigger","prevTrigger","indicatorGroup","indicator","autoplayTrigger"),Nr=Z6.build(),e4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.root)!=null?n:`carousel:${e.id}`},t4=(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}`},gl=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.itemGroup)!=null?n:`carousel:${e.id}:item-group`},n4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.nextTrigger)!=null?n:`carousel:${e.id}:next-trigger`},r4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.prevTrigger)!=null?n:`carousel:${e.id}:prev-trigger`},i4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.indicatorGroup)!=null?n:`carousel:${e.id}:indicator-group`},eT=(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(gl(e)),tT=e=>SP(hn(e),"[data-part=item]"),o4=(e,t)=>e.getById(eT(e,t)),nT=e=>{const t=hn(e);if(!t)return;const n=Po(t);t.setAttribute("tabindex",n.length>0?"-1":"0")};function s4(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"),b=o("isHorizontal"),T=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:T,canScrollNext:p,canScrollPrev:E,getProgress(){return x/T.length},scrollToIndex(O,I){a({type:"INDEX.SET",index:O,instant:I})},scrollTo(O,I){a({type:"PAGE.SET",index:O,instant:I})},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(se(B({},Nr.root.attrs),{id:e4(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(se(B({},Nr.itemGroup.attrs),{id:gl(u),"data-orientation":c("orientation"),"data-dragging":ko(h),dir:c("dir"),"aria-live":d?"off":"polite",onFocus(O){No(O.currentTarget,Gn(O))&&a({type:"VIEWPORT.FOCUS"})},onBlur(O){No(O.currentTarget,O.relatedTarget)||a({type:"VIEWPORT.BLUR"})},onMouseDown(O){if(O.defaultPrevented||!c("allowMouseDrag")||!RE(O))return;const I=Gn(O);dr(I)&&I!==O.currentTarget||(O.preventDefault(),a({type:"DRAGGING.START"}))},onWheel:SR(O=>{const I=c("orientation")==="horizontal"?"deltaX":"deltaY";O[I]<0&&!o("canScrollPrev")||O[I]>0&&!o("canScrollNext")||a({type:"USER.SCROLL"})},150),onTouchStart(){a({type:"USER.SCROLL"})},style:{display:"grid",gap:"var(--slide-spacing)",scrollSnapType:[b?"x":"y",c("snapType")].join(" "),gridAutoFlow:b?"column":"row",scrollbarWidth:"none",overscrollBehaviorX:"contain",[b?"gridAutoColumns":"gridAutoRows"]:"var(--slide-item-size)",[b?"scrollPaddingInline":"scrollPaddingBlock"]:S,[b?"paddingInline":"paddingBlock"]:S,[b?"overflowX":"overflowY"]:"auto"}}))},getItemProps(O){const I=r.get("slidesInView").includes(O.index);return t.element(se(B({},Nr.item.attrs),{id:t4(u,O.index),dir:c("dir"),role:"group","data-index":O.index,"data-inview":ko(I),"aria-roledescription":"slide","data-orientation":c("orientation"),"aria-label":A.item(O.index,c("slideCount")),"aria-hidden":AE(!I),style:{scrollSnapAlign:(()=>{var pe;const H=(pe=O.snapAlign)!=null?pe:"start",Y=c("slidesPerMove"),M=Y==="auto"?Math.floor(c("slidesPerPage")):Y;return(O.index+M)%M===0?H:void 0})()}}))},getControlProps(){return t.element(se(B({},Nr.control.attrs),{"data-orientation":c("orientation")}))},getPrevTriggerProps(){return t.button(se(B({},Nr.prevTrigger.attrs),{id:r4(u),type:"button",disabled:!E,dir:c("dir"),"aria-label":A.prevTrigger,"data-orientation":c("orientation"),"aria-controls":gl(u),onClick(O){O.defaultPrevented||a({type:"PAGE.PREV",src:"trigger"})}}))},getNextTriggerProps(){return t.button(se(B({},Nr.nextTrigger.attrs),{dir:c("dir"),id:n4(u),type:"button","aria-label":A.nextTrigger,"data-orientation":c("orientation"),"aria-controls":gl(u),disabled:!p,onClick(O){O.defaultPrevented||a({type:"PAGE.NEXT",src:"trigger"})}}))},getIndicatorGroupProps(){return t.element(se(B({},Nr.indicatorGroup.attrs),{dir:c("dir"),id:i4(u),"data-orientation":c("orientation"),onKeyDown(O){if(O.defaultPrevented)return;const I="indicator",H={ArrowDown(G){b||(a({type:"PAGE.NEXT",src:I}),G.preventDefault())},ArrowUp(G){b||(a({type:"PAGE.PREV",src:I}),G.preventDefault())},ArrowRight(G){b&&(a({type:"PAGE.NEXT",src:I}),G.preventDefault())},ArrowLeft(G){b&&(a({type:"PAGE.PREV",src:I}),G.preventDefault())},Home(G){a({type:"PAGE.SET",index:0,src:I}),G.preventDefault()},End(G){a({type:"PAGE.SET",index:T.length-1,src:I}),G.preventDefault()}},Y=aP(O,{dir:c("dir"),orientation:c("orientation")}),M=H[Y];M==null||M(O)}}))},getIndicatorProps(O){return t.button(se(B({},Nr.indicator.attrs),{dir:c("dir"),id:eT(u,O.index),type:"button","data-orientation":c("orientation"),"data-index":O.index,"data-readonly":ko(O.readOnly),"data-current":ko(O.index===x),"aria-label":A.indicator(O.index),onClick(I){I.defaultPrevented||O.readOnly||a({type:"PAGE.SET",index:O.index,src:"indicator"})}}))},getAutoplayTriggerProps(){return t.button(se(B({},Nr.autoplayTrigger.attrs),{type:"button","data-orientation":c("orientation"),"data-pressed":ko(d),"aria-label":d?A.autoplayStop:A.autoplayStart,onClick(O){O.defaultPrevented||a({type:d?"AUTOPLAY.PAUSE":"AUTOPLAY.START"})}}))}}}var a4={props({props:e}){return OR(e,["slideCount"],"carousel"),se(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:u4(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 hR(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"}),nT(e)});return nT(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"})};Nt(()=>{o(),Nt(()=>{t({type:"PAGE.SCROLL",instant:!0})})});const a=new r.ResizeObserver(o);return tT(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 b;const p=h.target,E=Number((b=p.dataset.index)!=null?b:"-1");return E==null||Number.isNaN(E)||E===-1?d:h.isIntersecting?uR(d,E):lR(d,E)},n.get("slidesInView"));n.set("slidesInView",cR(c))},{root:r,threshold:t("inViewThreshold")});return tT(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackScroll({send:e,refs:t,scope:n}){const r=hn(n);return r?Ft(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 Ft(n,"visibilitychange",()=>{n.visibilityState!=="visible"&&t({type:"AUTOPLAY.PAUSE",src:"doc.hidden"})})},trackPointerMove({scope:e,send:t}){const n=e.getDoc();return xP(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 Ft(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=SE((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=xE(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=J6(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=SE(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=Xy(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=Xy(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]);Nt(()=>{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=o4(n,e.get("page"));r&&Nt(()=>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 u4(e,t,n){if(e==null||n<=0)return[];const r=[],o=t==="auto"?Math.floor(n):t;if(o<=0)return[];for(let a=0;a<e&&!(a+n>e);a+=o)r.push(a);return r}Mo()(["dir","getRootNode","id","ids","loop","page","defaultPage","onPageChange","orientation","slideCount","slidesPerPage","slidesPerMove","spacing","padding","autoplay","allowMouseDrag","inViewThreshold","translations","snapType","onDragStatusChange","onAutoplayStatusChange"]),Mo()(["index","readOnly"]),Mo()(["index","snapAlign"]);const l4=e=>{const t=X.useId(),{getRootNode:n}=ml(),{dir:r}=th(),o=B({id:t,dir:r,getRootNode:n},e),a=nl(a4,o);return s4(a,Df)},rT=X.forwardRef((e,t)=>{const[n,r]=oa()(e,["allowMouseDrag","autoplay","defaultPage","id","ids","inViewThreshold","loop","onAutoplayStatusChange","onDragStatusChange","onPageChange","orientation","padding","page","slideCount","slidesPerMove","slidesPerPage","snapType","spacing","translations"]),o=l4(n),a=Ot(o.getRootProps(),r);return P.jsx(K6,{value:o,children:P.jsx(Kt.div,se(B({},a),{ref:t}))})});rT.displayName="CarouselRoot";const c4=180,d4=e=>{const t=e.trim(),n=parseFloat(t);return Number.isNaN(n)?0:t.endsWith("rem")?n*16:n},f4=({globalClassName:e,className:t,itemMinWidth:n=c4,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),b=E.length,T=X.useRef(null),[x,_]=X.useState(0),{width:S}=ev();X.useLayoutEffect(()=>{T.current&&_(T.current.getBoundingClientRect().width)},[S,b]);const A=d4(r),O=n+A,I=x>0?(x+A)/O:1,H=Math.max(1,Math.floor(I));if(b===0)return null;const Y=b>H,M=Math.ceil(b/H),G=Y?Math.max(1,I):H;return P.jsxs(rT,{ref:T,className:ae(e,t,`${ee}-carousel`),slidesPerPage:G,slidesPerMove:H,spacing:r,loop:o,allowMouseDrag:a,slideCount:b,onPageChange:d,"aria-label":h,children:[P.jsx(Yy,{className:ae(e,`${ee}-carousel__item-group`,{"carousel-row-container":!Y}),children:E.map((pe,re)=>P.jsx(qy,{index:re,className:ae(e,`${ee}-carousel__item`),children:pe},re))}),c&&Y&&P.jsxs(jy,{className:ae(e,`${ee}-carousel__control`),children:[P.jsx(Gy,{className:ae(e,`${ee}-carousel__prev-trigger`),"aria-label":"Previous slide",children:P.jsx(Y6,{})}),P.jsx(Wy,{className:ae(e,`${ee}-carousel__next-trigger`),"aria-label":"Next slide",children:P.jsx(W6,{})})]}),u&&Y&&P.jsx(Vy,{className:ae(e,`${ee}-carousel__indicator-group`),children:Array.from({length:M},(pe,re)=>P.jsx($y,{index:re,className:ae(e,`${ee}-carousel__indicator`),"aria-label":`Go to slide group ${re+1}`},re))})]})},h4=({className:e,label:t="Close",onClick:n,disabled:r=!1})=>P.jsx("button",{"aria-label":t,title:t,className:ae(e,`${ee}-close-button`),disabled:r,onClick:n,children:P.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:P.jsx("path",{d:"M18.3 5.7a1 1 0 0 0-1.4-1.4L12 9.6 7.1 4.7a1 1 0 1 0-1.4 1.4l4.9 4.9-4.9 4.9a1 1 0 1 0 1.4 1.4l4.9-4.9 4.9 4.9a1 1 0 0 0 1.4-1.4l-4.9-4.9 4.9-4.9z"})})}),[p4,m4]=Ui({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),g4=e=>oa()(e,["lazyMount","unmountOnExit"]),[E4,fa]=Ui({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),iT=X.forwardRef((e,t)=>{const n=fa(),r=m4(),o=Bf(se(B({},r),{present:n.open})),a=Ot(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:P.jsx(Kt.div,se(B({},a),{ref:rl(o.ref,t)}))});iT.displayName="DialogBackdrop";const nh=X.forwardRef((e,t)=>{const n=fa(),r=ia(),o=Ot(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:P.jsx(Kt.div,se(B({},o),{ref:rl(r.ref,t)}))});nh.displayName="DialogContent";const rh=X.forwardRef((e,t)=>{const n=fa(),r=Ot(n.getDescriptionProps(),e);return P.jsx(Kt.div,se(B({},r),{ref:t}))});rh.displayName="DialogDescription";const ih=X.forwardRef((e,t)=>{const n=fa(),r=Ot(n.getPositionerProps(),e);return ia().unmounted?null:P.jsx(Kt.div,se(B({},r),{ref:t}))});ih.displayName="DialogPositioner";var y4=Hi("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),$i=y4.build(),oT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},sT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},oh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},aT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},sh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`dialog:${e.id}:title`},ah=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`dialog:${e.id}:description`},uT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},El=e=>e.getById(oh(e)),T4=e=>e.getById(oT(e)),b4=e=>e.getById(sT(e)),x4=e=>e.getById(aT(e)),w4=e=>e.getById(sh(e)),_4=e=>e.getById(ah(e)),S4=e=>e.getById(uT(e));function v4(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(se(B({},$i.trigger.attrs),{dir:a("dir"),id:aT(u),"aria-haspopup":"dialog",type:"button","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":oh(u),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(se(B({},$i.backdrop.attrs),{dir:a("dir"),hidden:!d,id:sT(u),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(se(B({},$i.positioner.attrs),{dir:a("dir"),id:oT(u),style:{pointerEvents:d?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(se(B({},$i.content.attrs),{dir:a("dir"),role:a("role"),hidden:!d,id:oh(u),tabIndex:-1,"data-state":d?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:sh(u),"aria-describedby":h.description?ah(u):void 0}))},getTitleProps(){return t.element(se(B({},$i.title.attrs),{dir:a("dir"),id:sh(u)}))},getDescriptionProps(){return t.element(se(B({},$i.description.attrs),{dir:a("dir"),id:ah(u)}))},getCloseTriggerProps(){return t.button(se(B({},$i.closeTrigger.attrs),{dir:a("dir"),id:uT(u),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var A4={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>S4(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 Cy(()=>El(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[x4(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 Ry(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?Oy(()=>El(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")?yy(()=>[El(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){Nt(()=>{e.set("rendered",{title:!!w4(t),description:!!_4(t)})})},syncZIndex({scope:e}){Nt(()=>{const t=El(e);if(!t)return;const n=Ro(t);[T4(e),b4(e)].forEach(o=>{o==null||o.style.setProperty("--z-index",n.zIndex),o==null||o.style.setProperty("--layer-index",n.getPropertyValue("--layer-index"))})})},invokeOnClose({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!1})},invokeOnOpen({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!0})},toggleVisibility({prop:e,send:t,event:n}){t({type:e("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:n})}}}};Mo()(["aria-label","closeOnEscape","closeOnInteractOutside","dir","finalFocusEl","getRootNode","getRootNode","id","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","preventScroll","restoreFocus","role","trapFocus"]);const C4=e=>{const t=X.useId(),{getRootNode:n}=ml(),{dir:r}=th(),o=B({id:t,getRootNode:n,dir:r},e),a=nl(A4,o);return v4(a,Df)},lT=e=>{const[t,c]=GE(e),d=c,{children:n}=d,r=sn(d,["children"]),[o]=g4(t),a=C4(r),u=Bf(Ot({present:a.open},t));return P.jsx(E4,{value:a,children:P.jsx(p4,{value:o,children:P.jsx(qE,{value:u,children:n})})})},cT=X.forwardRef((e,t)=>{const n=fa(),r=Ot(n.getTitleProps(),e);return P.jsx(Kt.h2,se(B({},r),{ref:t}))});cT.displayName="DialogTitle";const k4=({children:e})=>{const[t,n]=X.useState(!1),r=X.useMemo(()=>({toggleMenu:()=>n(a=>!a),closeMenu:()=>n(!1)}),[]),o=X.useMemo(()=>({isOpen:t}),[t]);return P.jsx(xf.Provider,{value:r,children:P.jsx(yE.Provider,{value:o,children:e})})},dT=()=>X.useContext(yE),fT=()=>{const e=X.useContext(xf);if(!e)throw new Error("useOverflowMenuDispatch must be used within an OverflowMenuProvider");return e},N4=`${ee}-overflow-menu-button-trigger`,O4=({componentType:e,children:t})=>{const{isOpen:n}=dT(),{closeMenu:r}=fT(),{globalClassName:o}=kt(),a=X.useRef(null);return X.useEffect(()=>{if(!n)return;const u=d=>{d.key==="Escape"&&r()},c=d=>{const h=d.target;h instanceof Element&&h.closest(`.${N4}`)||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?P.jsx("div",{ref:a,role:"menu","aria-label":`Overflow menu for ${e}`,className:ae(`${ee}-overflow-panel`,o,`cim-${e}-component`),children:t}):null},I4=({componentType:e,className:t})=>{const{toggleMenu:n}=fT(),{isOpen:r}=dT(),{globalClassName:o}=kt();return P.jsx("button",{"aria-label":`Overflow menu for ${e}`,title:"More options","aria-expanded":r,"aria-haspopup":"menu",className:ae(`${ee}-overflow-menu-button-trigger`,`${ee}-icon-button`,o,t,`cim-${e}-component`),onClick:n,children:P.jsx(Uy,{})})},R4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),{previousComponentType:r}=Ci(),o=ta(),a=()=>{xu(r||"dialog"),o()};return t?P.jsx($r,{className:ae(n,`${ee}-toggle-dialog-button`,`cim-${e}-component`),ariaLabel:"Collapse",title:"Collapse",onClick:a,icon:P.jsx(Hy,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-toggle-dialog-button`,`cim-${e}-component`),onClick:a,children:[P.jsx(Hy,{}),"Show ",r||"dialog"]})},P4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),{isModalFullscreen:r}=Ci(),o=ta(),a=()=>{gd(!r),o()},u=r?Sv:vv,c="Toggle Fullscreen";return t?P.jsx($r,{ariaLabel:c,title:c,className:ae(n,`${ee}-modal-fullscreen-button`,`cim-${e}-component`),icon:P.jsx(u,{}),onClick:a}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-modal-fullscreen-button`,`cim-${e}-component`),onClick:a,children:[P.jsx(u,{}),c]})},L4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),{dialogPosition:r}=Ci(),o=ta(),a=r==="bottom-left",u=()=>{Ed(a?"bottom-right":"bottom-left"),o()},c=a?q6:V6,d=a?"Move right":"Move left";return t?P.jsx($r,{className:ae(n,`${ee}-left-right-toggle-button`,`cim-${e}-component`),ariaLabel:d,title:d,onClick:u,icon:P.jsx(c,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-left-right-toggle-button`,`cim-${e}-component`),onClick:u,children:[P.jsx(c,{}),d]})},hT=({componentType:e,onClearChat:t,onClose:n})=>{const{headerConfig:r,globalClassName:o}=kt(),{mode:a}=Ci(),u=a==="standalone",c=e==="modal",d=c?R4:pT,h=c?P4:L4,p=X.useMemo(()=>r?wv(r):{},[r]);return P.jsx(k4,{children:P.jsxs("div",{className:ae(o,`${ee}-${e}-header-wrapper`),style:{display:"flex",flexDirection:"column",position:"relative"},children:[P.jsxs("div",{className:ae(o,`${ee}-${e}-header`,{standalone:u,embedded:!u}),style:p,children:[(r==null?void 0:r.logoUrl)&&P.jsx("img",{alt:"",role:"img",className:ae(o,`${ee}-${e}-logo`,{standalone:u,embedded:!u}),src:r.logoUrl}),P.jsx(cT,{className:ae(o,`${ee}-${e}-title`,{standalone:u,embedded:!u}),children:r==null?void 0:r.headerText}),P.jsxs("div",{className:ae(o,`${ee}-${e}-controls`),children:[P.jsx(d,{componentType:e,isIcon:!0}),P.jsx(I4,{componentType:e}),P.jsx(h4,{className:ae(o,`cim-${e}-component`),onClick:n})]})]}),P.jsxs(O4,{componentType:e,children:[P.jsx(h,{componentType:e}),P.jsx(M4,{componentType:e}),P.jsx(bE,{componentType:e,onClearChat:t})]})]})})},D4=({className:e,globalClassName:t,suggestions:n,disabled:r,isWidgetStandalone:o,onSuggestionClick:a})=>{const u=o?"standalone":"embedded",c=d=>()=>{a(d)};return P.jsx("div",{className:ae(t,`${ee}-suggestion-container ${u}`,e),children:n.map(d=>o?P.jsx(O0,{disabled:r,className:ae(t,`${ee}-suggestion-button standalone`),onClick:c(d),children:d},d):P.jsx("button",{disabled:r,className:ae(t,`${ee}-suggestion-button embedded`),onClick:c(d),children:d},d))})},M4=({componentType:e,isIcon:t})=>{const{globalClassName:n,enableMinimize:r}=kt();if(!r)return null;const o=()=>{Ai(!1),bu(!0)};return t?P.jsx($r,{className:ae(n,`${ee}-toggle-minimize-button`,`cim-${e}-component`),ariaLabel:"Toggle Minimize",title:"Minimize",onClick:o,icon:P.jsx(k0,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-toggle-minimize-button`,`cim-${e}-component`),onClick:o,children:[P.jsx(k0,{}),"Minimize"]})},pT=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),r=ta(),o=()=>{xu("modal"),r()};return t?P.jsx($r,{className:ae(n,`${ee}-toggle-modal-button`,`cim-${e}-component`),ariaLabel:"Expand",title:"Expand",onClick:o,icon:P.jsx(zy,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-toggle-modal-button`,`cim-${e}-component`),onClick:o,children:[P.jsx(zy,{}),"Show modal"]})};function mT(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 F4(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function B4(e,t,n){const o=Lu((n||{}).ignore||[]),a=U4(t);let u=-1;for(;++u<a.length;)zg(e,"text",c);function c(h,p){let E=-1,b;for(;++E<p.length;){const T=p[E],x=b?b.children:void 0;if(o(T,x?x.indexOf(T):void 0,b))return;b=T}if(b)return d(h,p)}function d(h,p){const E=p[p.length-1],b=a[u][0],T=a[u][1];let x=0;const S=E.children.indexOf(h);let A=!1,O=[];b.lastIndex=0;let I=b.exec(h.value);for(;I;){const H=I.index,Y={index:I.index,input:I.input,stack:[...p,h]};let M=T(...I,Y);if(typeof M=="string"&&(M=M.length>0?{type:"text",value:M}:void 0),M===!1?b.lastIndex=H+1:(x!==H&&O.push({type:"text",value:h.value.slice(x,H)}),Array.isArray(M)?O.push(...M):M&&O.push(M),x=H+I[0].length,A=!0),!b.global)break;I=b.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 U4(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([H4(o[0]),z4(o[1])])}return t}function H4(e){return typeof e=="string"?new RegExp(F4(e),"g"):e}function z4(e){return typeof e=="function"?e:function(){return e}}const uh="phrasing",lh=["autolink","link","image","label"];function j4(){return{transforms:[K4],enter:{literalAutolink:V4,literalAutolinkEmail:ch,literalAutolinkHttp:ch,literalAutolinkWww:ch},exit:{literalAutolink:G4,literalAutolinkEmail:W4,literalAutolinkHttp:q4,literalAutolinkWww:Y4}}}function $4(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:uh,notInConstruct:lh},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:uh,notInConstruct:lh},{character:":",before:"[ps]",after:"\\/",inConstruct:uh,notInConstruct:lh}]}}function V4(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function ch(e){this.config.enter.autolinkProtocol.call(this,e)}function q4(e){this.config.exit.autolinkProtocol.call(this,e)}function Y4(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 W4(e){this.config.exit.autolinkEmail.call(this,e)}function G4(e){this.exit(e)}function K4(e){B4(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Q4],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),X4]],{ignore:["link","linkReference"]})}function Q4(e,t,n,r,o){let a="";if(!gT(o)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!J4(n)))return!1;const u=Z4(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 X4(e,t,n,r){return!gT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function J4(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 Z4(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=mT(e,"(");let a=mT(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 gT(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Oi(n)||Cu(n))&&(!t||n!==47)}ET.peek=uD;function eD(){this.buffer()}function tD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function nD(){this.buffer()}function rD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function iD(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 oD(e){this.exit(e)}function sD(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 aD(e){this.exit(e)}function uD(){return"["}function ET(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 lD(){return{enter:{gfmFootnoteCallString:eD,gfmFootnoteCall:tD,gfmFootnoteDefinitionLabelString:nD,gfmFootnoteDefinition:rD},exit:{gfmFootnoteCallString:iD,gfmFootnoteCall:oD,gfmFootnoteDefinitionLabelString:sD,gfmFootnoteDefinition:aD}}}function cD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:ET},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?yT:dD))),h(),d}}function dD(e,t,n){return t===0?e:yT(e,t,n)}function yT(e,t,n){return(n?"":" ")+e}const fD=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];TT.peek=ED;function hD(){return{canContainEols:["delete"],enter:{strikethrough:mD},exit:{strikethrough:gD}}}function pD(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:fD}],handlers:{delete:TT}}}function mD(e){this.enter({type:"delete",children:[]},e)}function gD(e){this.exit(e)}function TT(e,t,n,r){const o=n.createTracker(r),a=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,se(B({},o.current()),{before:u,after:"~"})),u+=o.move("~~"),a(),u}function ED(){return"~"}function yD(e){return e.length}function TD(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||yD,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=bD(e[p][A]);if(n.alignDelimiters!==!1){const I=o(O);S[A]=I,(d[A]===void 0||I>d[A])&&(d[A]=I)}_.push(O)}u[p]=_,c[p]=S}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)a[E]=bT(r[E]);else{const _=bT(r);for(;++E<h;)a[E]=_}E=-1;const b=[],T=[];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 I=S+"-".repeat(O)+A;n.alignDelimiters!==!1&&(O=S.length+O+A.length,O>d[E]&&(d[E]=O),T[E]=O),b[E]=I}u.splice(1,0,b),c.splice(1,0,T),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 I="",
|
|
37
|
+
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ri={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},r1={}.hasOwnProperty,FN=Object.prototype;function BN(e,t){const n=t||{};return rf({file:n.file||void 0,location:!1,schema:n.space==="svg"?mo:Su,verbose:n.verbose||!1},e)}function rf(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Bu(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:i1(e,t.childNodes),data:{quirksMode:o}},e.file&&e.location){const a=String(e.file),u=MN(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"},Bu(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Bu(e,r,n),n}default:return n=UN(e,t),n}}function i1(e,t){let n=-1;const r=[];for(;++n<t.length;){const o=rf(e,t[n]);r.push(o)}return r}function UN(e,t){const n=e.schema;e.schema=t.namespaceURI===Ri.svg?mo:Su;let r=-1;const o={};for(;++r<t.attrs.length;){const c=t.attrs[r],d=(c.prefix?c.prefix+":":"")+c.name;r1.call(FN,d)||(o[d]=c.value)}const u=(e.schema.space==="svg"?DN:LN)(t.tagName,o,i1(e,t.childNodes));if(Bu(e,t,u),u.tagName==="template"){const c=t,d=c.sourceCodeLocation,h=d&&d.startTag&&bo(d.startTag),p=d&&d.endTag&&bo(d.endTag),E=rf(e,c.content);h&&p&&e.file&&(E.position={start:h.end,end:p.start}),u.content=E}return e.schema=n,u}function Bu(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=HN(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function HN(e,t,n){const r=bo(n);if(t.type==="element"){const o=t.children[t.children.length-1];if(r&&!n.endTag&&o&&o.position&&o.position.end&&(r.end=Object.assign({},o.position.end)),e.verbose){const a={};let u;if(n.attrs)for(u in n.attrs)r1.call(n.attrs,u)&&(a[vd(e.schema,u).property]=bo(n.attrs[u]));n.startTag;const c=bo(n.startTag),d=n.endTag?bo(n.endTag):void 0,h={opening:c};d&&(h.closing=d),h.properties=a,t.data={position:h}}}return r}function bo(e){const t=o1({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=o1({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function o1(e){return e.line&&e.column?e:void 0}class js{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}js.prototype.property={},js.prototype.normal={},js.prototype.space=null;function s1(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 js(n,r,t)}function of(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 zN=0;const ze=Pi(),At=Pi(),a1=Pi(),ge=Pi(),st=Pi(),xo=Pi(),wn=Pi();function Pi(){return Za(2,++zN)}const sf=Object.freeze(Object.defineProperty({__proto__:null,boolean:ze,booleanish:At,commaOrSpaceSeparated:wn,commaSeparated:xo,number:ge,overloadedBoolean:a1,spaceSeparated:st},Symbol.toStringTag,{value:"Module"})),af=Object.keys(sf);class uf extends Pn{constructor(t,n,r,o){let a=-1;if(super(t,n),u1(this,"space",o),typeof r=="number")for(;++a<af.length;){const u=af[a];u1(this,af[a],(r&sf[u])===sf[u])}}}uf.prototype.defined=!0;function u1(e,t,n){n&&(e[t]=n)}const jN={}.hasOwnProperty;function wo(e){const t={},n={};let r;for(r in e.properties)if(jN.call(e.properties,r)){const o=e.properties[r],a=new uf(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[of(r)]=r,n[of(a.attribute)]=r}return new js(t,n,e.space)}const l1=wo({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}}),c1=wo({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function d1(e,t){return t in e?e[t]:t}function f1(e,t){return d1(e,t.toLowerCase())}const h1=wo({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:f1,properties:{xmlns:null,xmlnsXLink:null}}),p1=wo({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:At,ariaAutoComplete:null,ariaBusy:At,ariaChecked:At,ariaColCount:ge,ariaColIndex:ge,ariaColSpan:ge,ariaControls:st,ariaCurrent:null,ariaDescribedBy:st,ariaDetails:null,ariaDisabled:At,ariaDropEffect:st,ariaErrorMessage:null,ariaExpanded:At,ariaFlowTo:st,ariaGrabbed:At,ariaHasPopup:null,ariaHidden:At,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:st,ariaLevel:ge,ariaLive:null,ariaModal:At,ariaMultiLine:At,ariaMultiSelectable:At,ariaOrientation:null,ariaOwns:st,ariaPlaceholder:null,ariaPosInSet:ge,ariaPressed:At,ariaReadOnly:At,ariaRelevant:null,ariaRequired:At,ariaRoleDescription:st,ariaRowCount:ge,ariaRowIndex:ge,ariaRowSpan:ge,ariaSelected:At,ariaSetSize:ge,ariaSort:null,ariaValueMax:ge,ariaValueMin:ge,ariaValueNow:ge,ariaValueText:null,role:null}}),$N=wo({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:f1,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:xo,acceptCharset:st,accessKey:st,action:null,allow:null,allowFullScreen:ze,allowPaymentRequest:ze,allowUserMedia:ze,alt:null,as:null,async:ze,autoCapitalize:null,autoComplete:st,autoFocus:ze,autoPlay:ze,blocking:st,capture:null,charSet:null,checked:ze,cite:null,className:st,cols:ge,colSpan:null,content:null,contentEditable:At,controls:ze,controlsList:st,coords:ge|xo,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ze,defer:ze,dir:null,dirName:null,disabled:ze,download:a1,draggable:At,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:ze,formTarget:null,headers:st,height:ge,hidden:ze,high:ge,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:ge,manifest:null,max:null,maxLength:ge,media:null,method:null,min:null,minLength:ge,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:ge,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:ge,rowSpan:ge,sandbox:st,scope:null,scoped:ze,seamless:ze,selected:ze,shadowRootClonable:ze,shadowRootDelegatesFocus:ze,shadowRootMode:null,shape:null,size:ge,sizes:null,slot:null,span:ge,spellCheck:At,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:ze,useMap:null,value:At,width:ge,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:st,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:ze,declare:ze,event:null,face:null,frame:null,frameBorder:null,hSpace:ge,leftMargin:ge,link:null,longDesc:null,lowSrc:null,marginHeight:ge,marginWidth:ge,noResize:ze,noHref:ze,noShade:ze,noWrap:ze,object:null,profile:null,prompt:null,rev:null,rightMargin:ge,rules:null,scheme:null,scrolling:At,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:ze,disableRemotePlayback:ze,prefix:null,property:null,results:ge,security:null,unselectable:null}}),VN=wo({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:d1,properties:{about:wn,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: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:ge,diffuseConstant:ge,direction:null,display:null,dur:null,divisor:ge,dominantBaseline:null,download:ze,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:xo,g2:xo,glyphName:xo,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:wn,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:st,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ge,pointsAtY:ge,pointsAtZ:ge,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: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:wn,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:wn,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:wn,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}}),qN=/^data[-\w.:]+$/i,m1=/-[a-z]/g,YN=/[A-Z]/g;function WN(e,t){const n=of(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"&&qN.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(m1,KN);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!m1.test(a)){let u=a.replace(YN,GN);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=uf}return new o(r,t)}function GN(e){return"-"+e.toLowerCase()}function KN(e){return e.charAt(1).toUpperCase()}const QN=s1([c1,l1,h1,p1,$N],"html"),g1=s1([c1,l1,h1,p1,VN],"svg"),E1={}.hasOwnProperty;function y1(e,t){const n=t||{};function r(o,...a){let u=r.invalid;const c=r.handlers;if(o&&E1.call(o,e)){const d=String(o[e]);u=E1.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={},JN={}.hasOwnProperty,T1=y1("type",{handlers:{root:e3,element:o3,text:r3,comment:i3,doctype:n3}});function ZN(e,t){const r=(t||XN).space;return T1(e,r==="svg"?g1:QN)}function e3(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=lf(e.children,n,t),_o(e,n),n}function t3(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=lf(e.children,n,t),_o(e,n),n}function n3(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return _o(e,t),t}function r3(e){const t={nodeName:"#text",value:e.value,parentNode:null};return _o(e,t),t}function i3(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return _o(e,t),t}function o3(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=g1);const o=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&JN.call(e.properties,a)){const d=s3(r,a,e.properties[a]);d&&o.push(d)}}const u=r.space,c={nodeName:e.tagName,tagName:e.tagName,attrs:o,namespaceURI:Ri[u],childNodes:[],parentNode:null};return c.childNodes=lf(e.children,c,r),_o(e,c),e.tagName==="template"&&e.content&&(c.content=t3(e.content,r)),c}function s3(e,t,n){const r=WN(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?R0(n):q0(n));const o={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=o.name.indexOf(":");a<0?o.prefix="":(o.name=o.name.slice(a+1),o.prefix=r.attribute.slice(0,a)),o.namespace=Ri[r.space]}return o}function lf(e,t,n){let r=-1;const o=[];if(e)for(;++r<e.length;){const a=T1(e[r],n);a.parentNode=t,o.push(a)}return o}function _o(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 a3=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],u3=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 C;(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"})(C||(C={}));const fn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function b1(e){return e>=55296&&e<=57343}function l3(e){return e>=56320&&e<=57343}function c3(e,t){return(e-55296)*1024+9216+t}function x1(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function w1(e){return e>=64976&&e<=65007||u3.has(e)}var J;(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"})(J||(J={}));const d3=65536;class f3{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=d3,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(l3(n))return this.pos++,this._addGap(),c3(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,C.EOF;return this._err(J.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,C.EOF;const r=this.html.charCodeAt(n);return r===C.CARRIAGE_RETURN?C.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,C.EOF;let t=this.html.charCodeAt(this.pos);return t===C.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,C.LINE_FEED):t===C.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,b1(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===C.LINE_FEED||t===C.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){x1(t)?this._err(J.controlCharacterInInputStream):w1(t)&&this._err(J.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 _1(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 h3=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୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢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;怳Ādpuct;戏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ǣጓ\0y;䐎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Ā;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀ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Ā;elƀ;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\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»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ↄⅪ←ٖ↛ǰ↉\0proø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;䅓Ācrir;榿;쀀𝔬ͯ\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\0m;櫳;櫽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))),p3=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 m3(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=p3.get(e))!==null&&t!==void 0?t:e}var Lt;(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"})(Lt||(Lt={}));const g3=32;var Yr;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Yr||(Yr={}));function cf(e){return e>=Lt.ZERO&&e<=Lt.NINE}function E3(e){return e>=Lt.UPPER_A&&e<=Lt.UPPER_F||e>=Lt.LOWER_A&&e<=Lt.LOWER_F}function y3(e){return e>=Lt.UPPER_A&&e<=Lt.UPPER_Z||e>=Lt.LOWER_A&&e<=Lt.LOWER_Z||cf(e)}function T3(e){return e===Lt.EQUALS||y3(e)}var Dt;(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"})(Dt||(Dt={}));var vr;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(vr||(vr={}));class b3{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Dt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=vr.Strict}startEntity(t){this.decodeMode=t,this.state=Dt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Dt.EntityStart:return t.charCodeAt(n)===Lt.NUM?(this.state=Dt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Dt.NamedEntity,this.stateNamedEntity(t,n));case Dt.NumericStart:return this.stateNumericStart(t,n);case Dt.NumericDecimal:return this.stateNumericDecimal(t,n);case Dt.NumericHex:return this.stateNumericHex(t,n);case Dt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|g3)===Lt.LOWER_X?(this.state=Dt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Dt.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(cf(o)||E3(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(cf(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===Lt.SEMI)this.consumed+=1;else if(this.decodeMode===vr.Strict)return 0;return this.emitCodePoint(m3(this.result),this.consumed),this.errors&&(t!==Lt.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const u=t.charCodeAt(n);if(this.treeIndex=x3(r,o,this.treeIndex+Math.max(1,a),u),this.treeIndex<0)return this.result===0||this.decodeMode===vr.Attribute&&(a===0||T3(u))?0:this.emitNotTerminatedNamedEntity();if(o=r[this.treeIndex],a=(o&Yr.VALUE_LENGTH)>>14,a!==0){if(u===Lt.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==vr.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,o=(r[n]&Yr.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,o,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:o}=this;return this.emitCodePoint(n===1?o[t]&~Yr.VALUE_LENGTH:o[t+1],r),n===3&&this.emitCodePoint(o[t+2],r),r}end(){var t;switch(this.state){case Dt.NamedEntity:return this.result!==0&&(this.decodeMode!==vr.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Dt.NumericDecimal:return this.emitNumericEntity(0,2);case Dt.NumericHex:return this.emitNumericEntity(0,3);case Dt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Dt.EntityStart:return 0}}}function x3(e,t,n,r){const o=(t&Yr.BRANCH_LENGTH)>>7,a=t&Yr.JUMP_TABLE;if(o===0)return a!==0&&r===a?n:-1;if(a){const d=r-a;return d<0||d>=o?-1:e[n+d]-1}let u=n,c=u+o-1;for(;u<=c;){const d=u+c>>>1,h=e[d];if(h<r)u=d+1;else if(h>r)c=d-1;else return e[d+o]}return-1}var 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 Li;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Li||(Li={}));var Ln;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Ln||(Ln={}));var V;(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"})(V||(V={}));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 w3=new Map([[V.A,m.A],[V.ADDRESS,m.ADDRESS],[V.ANNOTATION_XML,m.ANNOTATION_XML],[V.APPLET,m.APPLET],[V.AREA,m.AREA],[V.ARTICLE,m.ARTICLE],[V.ASIDE,m.ASIDE],[V.B,m.B],[V.BASE,m.BASE],[V.BASEFONT,m.BASEFONT],[V.BGSOUND,m.BGSOUND],[V.BIG,m.BIG],[V.BLOCKQUOTE,m.BLOCKQUOTE],[V.BODY,m.BODY],[V.BR,m.BR],[V.BUTTON,m.BUTTON],[V.CAPTION,m.CAPTION],[V.CENTER,m.CENTER],[V.CODE,m.CODE],[V.COL,m.COL],[V.COLGROUP,m.COLGROUP],[V.DD,m.DD],[V.DESC,m.DESC],[V.DETAILS,m.DETAILS],[V.DIALOG,m.DIALOG],[V.DIR,m.DIR],[V.DIV,m.DIV],[V.DL,m.DL],[V.DT,m.DT],[V.EM,m.EM],[V.EMBED,m.EMBED],[V.FIELDSET,m.FIELDSET],[V.FIGCAPTION,m.FIGCAPTION],[V.FIGURE,m.FIGURE],[V.FONT,m.FONT],[V.FOOTER,m.FOOTER],[V.FOREIGN_OBJECT,m.FOREIGN_OBJECT],[V.FORM,m.FORM],[V.FRAME,m.FRAME],[V.FRAMESET,m.FRAMESET],[V.H1,m.H1],[V.H2,m.H2],[V.H3,m.H3],[V.H4,m.H4],[V.H5,m.H5],[V.H6,m.H6],[V.HEAD,m.HEAD],[V.HEADER,m.HEADER],[V.HGROUP,m.HGROUP],[V.HR,m.HR],[V.HTML,m.HTML],[V.I,m.I],[V.IMG,m.IMG],[V.IMAGE,m.IMAGE],[V.INPUT,m.INPUT],[V.IFRAME,m.IFRAME],[V.KEYGEN,m.KEYGEN],[V.LABEL,m.LABEL],[V.LI,m.LI],[V.LINK,m.LINK],[V.LISTING,m.LISTING],[V.MAIN,m.MAIN],[V.MALIGNMARK,m.MALIGNMARK],[V.MARQUEE,m.MARQUEE],[V.MATH,m.MATH],[V.MENU,m.MENU],[V.META,m.META],[V.MGLYPH,m.MGLYPH],[V.MI,m.MI],[V.MO,m.MO],[V.MN,m.MN],[V.MS,m.MS],[V.MTEXT,m.MTEXT],[V.NAV,m.NAV],[V.NOBR,m.NOBR],[V.NOFRAMES,m.NOFRAMES],[V.NOEMBED,m.NOEMBED],[V.NOSCRIPT,m.NOSCRIPT],[V.OBJECT,m.OBJECT],[V.OL,m.OL],[V.OPTGROUP,m.OPTGROUP],[V.OPTION,m.OPTION],[V.P,m.P],[V.PARAM,m.PARAM],[V.PLAINTEXT,m.PLAINTEXT],[V.PRE,m.PRE],[V.RB,m.RB],[V.RP,m.RP],[V.RT,m.RT],[V.RTC,m.RTC],[V.RUBY,m.RUBY],[V.S,m.S],[V.SCRIPT,m.SCRIPT],[V.SEARCH,m.SEARCH],[V.SECTION,m.SECTION],[V.SELECT,m.SELECT],[V.SOURCE,m.SOURCE],[V.SMALL,m.SMALL],[V.SPAN,m.SPAN],[V.STRIKE,m.STRIKE],[V.STRONG,m.STRONG],[V.STYLE,m.STYLE],[V.SUB,m.SUB],[V.SUMMARY,m.SUMMARY],[V.SUP,m.SUP],[V.TABLE,m.TABLE],[V.TBODY,m.TBODY],[V.TEMPLATE,m.TEMPLATE],[V.TEXTAREA,m.TEXTAREA],[V.TFOOT,m.TFOOT],[V.TD,m.TD],[V.TH,m.TH],[V.THEAD,m.THEAD],[V.TITLE,m.TITLE],[V.TR,m.TR],[V.TRACK,m.TRACK],[V.TT,m.TT],[V.U,m.U],[V.UL,m.UL],[V.SVG,m.SVG],[V.VAR,m.VAR],[V.WBR,m.WBR],[V.XMP,m.XMP]]);function So(e){var t;return(t=w3.get(e))!==null&&t!==void 0?t:m.UNKNOWN}const fe=m,_3={[le.HTML]:new Set([fe.ADDRESS,fe.APPLET,fe.AREA,fe.ARTICLE,fe.ASIDE,fe.BASE,fe.BASEFONT,fe.BGSOUND,fe.BLOCKQUOTE,fe.BODY,fe.BR,fe.BUTTON,fe.CAPTION,fe.CENTER,fe.COL,fe.COLGROUP,fe.DD,fe.DETAILS,fe.DIR,fe.DIV,fe.DL,fe.DT,fe.EMBED,fe.FIELDSET,fe.FIGCAPTION,fe.FIGURE,fe.FOOTER,fe.FORM,fe.FRAME,fe.FRAMESET,fe.H1,fe.H2,fe.H3,fe.H4,fe.H5,fe.H6,fe.HEAD,fe.HEADER,fe.HGROUP,fe.HR,fe.HTML,fe.IFRAME,fe.IMG,fe.INPUT,fe.LI,fe.LINK,fe.LISTING,fe.MAIN,fe.MARQUEE,fe.MENU,fe.META,fe.NAV,fe.NOEMBED,fe.NOFRAMES,fe.NOSCRIPT,fe.OBJECT,fe.OL,fe.P,fe.PARAM,fe.PLAINTEXT,fe.PRE,fe.SCRIPT,fe.SECTION,fe.SELECT,fe.SOURCE,fe.STYLE,fe.SUMMARY,fe.TABLE,fe.TBODY,fe.TD,fe.TEMPLATE,fe.TEXTAREA,fe.TFOOT,fe.TH,fe.THEAD,fe.TITLE,fe.TR,fe.TRACK,fe.UL,fe.WBR,fe.XMP]),[le.MATHML]:new Set([fe.MI,fe.MO,fe.MN,fe.MS,fe.MTEXT,fe.ANNOTATION_XML]),[le.SVG]:new Set([fe.TITLE,fe.FOREIGN_OBJECT,fe.DESC]),[le.XLINK]:new Set,[le.XML]:new Set,[le.XMLNS]:new Set},df=new Set([fe.H1,fe.H2,fe.H3,fe.H4,fe.H5,fe.H6]);V.STYLE,V.SCRIPT,V.XMP,V.IFRAME,V.NOEMBED,V.NOFRAMES,V.PLAINTEXT;var N;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(N||(N={}));const xt={DATA:N.DATA,RCDATA:N.RCDATA,RAWTEXT:N.RAWTEXT,SCRIPT_DATA:N.SCRIPT_DATA,PLAINTEXT:N.PLAINTEXT,CDATA_SECTION:N.CDATA_SECTION};function S3(e){return e>=C.DIGIT_0&&e<=C.DIGIT_9}function $s(e){return e>=C.LATIN_CAPITAL_A&&e<=C.LATIN_CAPITAL_Z}function v3(e){return e>=C.LATIN_SMALL_A&&e<=C.LATIN_SMALL_Z}function Wr(e){return v3(e)||$s(e)}function S1(e){return Wr(e)||S3(e)}function Uu(e){return e+32}function v1(e){return e===C.SPACE||e===C.LINE_FEED||e===C.TABULATION||e===C.FORM_FEED}function A1(e){return v1(e)||e===C.SOLIDUS||e===C.GREATER_THAN_SIGN}function A3(e){return e===C.NULL?J.nullCharacterReference:e>1114111?J.characterReferenceOutsideUnicodeRange:b1(e)?J.surrogateCharacterReference:w1(e)?J.noncharacterCharacterReference:x1(e)||e===C.CARRIAGE_RETURN?J.controlCharacterReference:null}class C3{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=N.DATA,this.returnState=N.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new f3(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new b3(h3,(r,o)=>{this.preprocessor.pos=this.entityStartPos+o-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(J.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(J.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const o=A3(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(_1(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(J.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=So(t.tagName),t.type===Ve.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(J.endTagWithAttributes),t.selfClosing&&this._err(J.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=v1(t)?Ve.WHITESPACE_CHARACTER:t===C.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=N.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?vr.Attribute:vr.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===N.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===N.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case N.DATA:{this._stateData(t);break}case N.RCDATA:{this._stateRcdata(t);break}case N.RAWTEXT:{this._stateRawtext(t);break}case N.SCRIPT_DATA:{this._stateScriptData(t);break}case N.PLAINTEXT:{this._statePlaintext(t);break}case N.TAG_OPEN:{this._stateTagOpen(t);break}case N.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case N.TAG_NAME:{this._stateTagName(t);break}case N.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case N.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case N.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case N.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case N.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case N.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case N.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case N.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case N.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case N.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case N.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case N.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case N.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case N.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case N.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case N.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case N.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case N.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case N.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case N.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case N.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case N.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case N.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case N.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case N.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case N.BOGUS_COMMENT:{this._stateBogusComment(t);break}case N.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case N.COMMENT_START:{this._stateCommentStart(t);break}case N.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case N.COMMENT:{this._stateComment(t);break}case N.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case N.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case N.COMMENT_END:{this._stateCommentEnd(t);break}case N.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case N.DOCTYPE:{this._stateDoctype(t);break}case N.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case N.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case N.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case N.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case N.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case N.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case N.CDATA_SECTION:{this._stateCdataSection(t);break}case N.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case N.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case N.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case N.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case C.LESS_THAN_SIGN:{this.state=N.TAG_OPEN;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitCodePoint(t);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case C.AMPERSAND:{this._startCharacterReference();break}case C.LESS_THAN_SIGN:{this.state=N.RCDATA_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case C.LESS_THAN_SIGN:{this.state=N.RAWTEXT_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Wr(t))this._createStartTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case C.EXCLAMATION_MARK:{this.state=N.MARKUP_DECLARATION_OPEN;break}case C.SOLIDUS:{this.state=N.END_TAG_OPEN;break}case C.QUESTION_MARK:{this._err(J.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t);break}case C.EOF:{this._err(J.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(J.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=N.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Wr(t))this._createEndTagToken(),this.state=N.TAG_NAME,this._stateTagName(t);else switch(t){case C.GREATER_THAN_SIGN:{this._err(J.missingEndTagName),this.state=N.DATA;break}case C.EOF:{this._err(J.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(J.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_ATTRIBUTE_NAME;break}case C.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.tagName+=ft;break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint($s(t)?Uu(t):t)}}_stateRcdataLessThanSign(t){t===C.SOLIDUS?this.state=N.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Wr(t)?(this.state=N.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=N.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=N.BEFORE_ATTRIBUTE_NAME,!1;case C.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=N.SELF_CLOSING_START_TAG,!1;case C.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=N.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===C.SOLIDUS?this.state=N.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Wr(t)?(this.state=N.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case C.SOLIDUS:{this.state=N.SCRIPT_DATA_END_TAG_OPEN;break}case C.EXCLAMATION_MARK:{this.state=N.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=N.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===C.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===C.HYPHEN_MINUS?(this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=N.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case C.HYPHEN_MINUS:{this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case C.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===C.SOLIDUS?this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Wr(t)?(this._emitChars("<"),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Wr(t)?(this.state=N.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&A1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case C.HYPHEN_MINUS:{this._emitChars("-");break}case C.LESS_THAN_SIGN:{this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case C.GREATER_THAN_SIGN:{this.state=N.SCRIPT_DATA,this._emitChars(">");break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ft);break}case C.EOF:{this._err(J.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===C.SOLIDUS?(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(fn.SCRIPT,!1)&&A1(this.preprocessor.peek(fn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<fn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=N.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=N.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.SOLIDUS:case C.GREATER_THAN_SIGN:case C.EOF:{this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case C.EQUALS_SIGN:{this._err(J.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=N.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:case C.SOLIDUS:case C.GREATER_THAN_SIGN:case C.EOF:{this._leaveAttrName(),this.state=N.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case C.EQUALS_SIGN:{this._leaveAttrName(),this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case C.QUOTATION_MARK:case C.APOSTROPHE:case C.LESS_THAN_SIGN:{this._err(J.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.name+=ft;break}default:this.currentAttr.name+=String.fromCodePoint($s(t)?Uu(t):t)}}_stateAfterAttributeName(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.SOLIDUS:{this.state=N.SELF_CLOSING_START_TAG;break}case C.EQUALS_SIGN:{this.state=N.BEFORE_ATTRIBUTE_VALUE;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentTagToken();break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=N.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.QUOTATION_MARK:{this.state=N.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this.state=N.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingAttributeValue),this.state=N.DATA,this.emitCurrentTagToken();break}default:this.state=N.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case C.QUOTATION_MARK:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case C.APOSTROPHE:{this.state=N.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case C.AMPERSAND:{this._startCharacterReference();break}case C.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case C.NULL:{this._err(J.unexpectedNullCharacter),this.currentAttr.value+=ft;break}case C.QUOTATION_MARK:case C.APOSTROPHE:case C.LESS_THAN_SIGN:case C.EQUALS_SIGN:case C.GRAVE_ACCENT:{this._err(J.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this._leaveAttrValue(),this.state=N.BEFORE_ATTRIBUTE_NAME;break}case C.SOLIDUS:{this._leaveAttrValue(),this.state=N.SELF_CLOSING_START_TAG;break}case C.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=N.DATA,this.emitCurrentTagToken();break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this._err(J.missingWhitespaceBetweenAttributes),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case C.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=N.DATA,this.emitCurrentTagToken();break}case C.EOF:{this._err(J.eofInTag),this._emitEOFToken();break}default:this._err(J.unexpectedSolidusInTag),this.state=N.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case C.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.data+=ft;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(fn.DASH_DASH,!0)?(this._createCommentToken(fn.DASH_DASH.length+1),this.state=N.COMMENT_START):this._consumeSequenceIfMatch(fn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(fn.DOCTYPE.length+1),this.state=N.DOCTYPE):this._consumeSequenceIfMatch(fn.CDATA_START,!0)?this.inForeignNode?this.state=N.CDATA_SECTION:(this._err(J.cdataInHtmlContent),this._createCommentToken(fn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=N.BOGUS_COMMENT):this._ensureHibernation()||(this._err(J.incorrectlyOpenedComment),this._createCommentToken(2),this.state=N.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_START_DASH;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptClosingOfEmptyComment),this.state=N.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptClosingOfEmptyComment),this.state=N.DATA,this.emitCurrentComment(n);break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_END_DASH;break}case C.LESS_THAN_SIGN:{n.data+="<",this.state=N.COMMENT_LESS_THAN_SIGN;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.data+=ft;break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case C.EXCLAMATION_MARK:{n.data+="!",this.state=N.COMMENT_LESS_THAN_SIGN_BANG;break}case C.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=N.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===C.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=N.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===C.HYPHEN_MINUS?this.state=N.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=N.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==C.GREATER_THAN_SIGN&&t!==C.EOF&&this._err(J.nestedComment),this.state=N.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{this.state=N.COMMENT_END;break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentComment(n);break}case C.EXCLAMATION_MARK:{this.state=N.COMMENT_END_BANG;break}case C.HYPHEN_MINUS:{n.data+="-";break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=N.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case C.HYPHEN_MINUS:{n.data+="--!",this.state=N.COMMENT_END_DASH;break}case C.GREATER_THAN_SIGN:{this._err(J.incorrectlyClosedComment),this.state=N.DATA,this.emitCurrentComment(n);break}case C.EOF:{this._err(J.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=N.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_NAME;break}case C.GREATER_THAN_SIGN:{this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case C.EOF:{this._err(J.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingWhitespaceBeforeDoctypeName),this.state=N.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if($s(t))this._createDoctypeToken(String.fromCharCode(Uu(t))),this.state=N.DOCTYPE_NAME;else switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.NULL:{this._err(J.unexpectedNullCharacter),this._createDoctypeToken(ft),this.state=N.DOCTYPE_NAME;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=N.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.AFTER_DOCTYPE_NAME;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.name+=ft;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint($s(t)?Uu(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(fn.PUBLIC,!1)?this.state=N.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(fn.SYSTEM,!1)?this.state=N.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(J.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case C.QUOTATION_MARK:{this._err(J.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this._err(J.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.QUOTATION_MARK:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{n.publicId="",this.state=N.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case C.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.publicId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.publicId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case C.GREATER_THAN_SIGN:{this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.QUOTATION_MARK:{this._err(J.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this._err(J.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:{this.state=N.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case C.QUOTATION_MARK:{this._err(J.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{this._err(J.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.QUOTATION_MARK:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case C.APOSTROPHE:{n.systemId="",this.state=N.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case C.GREATER_THAN_SIGN:{this._err(J.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.DATA,this.emitCurrentDoctype(n);break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case C.QUOTATION_MARK:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.systemId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.APOSTROPHE:{this.state=N.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case C.NULL:{this._err(J.unexpectedNullCharacter),n.systemId+=ft;break}case C.GREATER_THAN_SIGN:{this._err(J.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.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 C.SPACE:case C.LINE_FEED:case C.TABULATION:case C.FORM_FEED:break;case C.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.EOF:{this._err(J.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(J.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=N.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case C.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=N.DATA;break}case C.NULL:{this._err(J.unexpectedNullCharacter);break}case C.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case C.RIGHT_SQUARE_BRACKET:{this.state=N.CDATA_SECTION_BRACKET;break}case C.EOF:{this._err(J.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===C.RIGHT_SQUARE_BRACKET?this.state=N.CDATA_SECTION_END:(this._emitChars("]"),this.state=N.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case C.GREATER_THAN_SIGN:{this.state=N.DATA;break}case C.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=N.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(C.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&S1(this.preprocessor.peek(1))?N.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){S1(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===C.SEMICOLON&&this._err(J.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const C1=new Set([m.DD,m.DT,m.LI,m.OPTGROUP,m.OPTION,m.P,m.RB,m.RP,m.RT,m.RTC]),k1=new Set([...C1,m.CAPTION,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]),Hu=new Set([m.APPLET,m.CAPTION,m.HTML,m.MARQUEE,m.OBJECT,m.TABLE,m.TD,m.TEMPLATE,m.TH]),k3=new Set([...Hu,m.OL,m.UL]),N3=new Set([...Hu,m.BUTTON]),N1=new Set([m.ANNOTATION_XML,m.MI,m.MN,m.MO,m.MS,m.MTEXT]),O1=new Set([m.DESC,m.FOREIGN_OBJECT,m.TITLE]),O3=new Set([m.TR,m.TEMPLATE,m.HTML]),I3=new Set([m.TBODY,m.TFOOT,m.THEAD,m.TEMPLATE,m.HTML]),R3=new Set([m.TABLE,m.TEMPLATE,m.HTML]),P3=new Set([m.TD,m.TH]);class L3{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(df,le.HTML)}popUntilTableCellPopped(){this.popUntilPopped(P3,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(R3,le.HTML)}clearBackToTableBodyContext(){this.clearBackTo(I3,le.HTML)}clearBackToTableRowContext(){this.clearBackTo(O3,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(O1.has(o))return!1;break}case le.MATHML:{if(N1.has(o))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Hu)}hasInListItemScope(t){return this.hasInDynamicScope(t,k3)}hasInButtonScope(t){return this.hasInDynamicScope(t,N3)}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(df.has(n))return!0;if(Hu.has(n))return!1;break}case le.SVG:{if(O1.has(n))return!1;break}case le.MATHML:{if(N1.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&&C1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&k1.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&k1.has(this.currentTagId);)this.pop()}}const ff=3;var lr;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(lr||(lr={}));const I1={type:lr.Marker};class D3{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],o=n.length,a=this.treeAdapter.getTagName(t),u=this.treeAdapter.getNamespaceURI(t);for(let c=0;c<this.entries.length;c++){const d=this.entries[c];if(d.type===lr.Marker)break;const{element:h}=d;if(this.treeAdapter.getTagName(h)===a&&this.treeAdapter.getNamespaceURI(h)===u){const p=this.treeAdapter.getAttrList(h);p.length===o&&r.push({idx:c,attrs:p})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<ff)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<ff)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>=ff&&this.entries.splice(c.idx,1))}}insertMarker(){this.entries.unshift(I1)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:lr.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:lr.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(I1);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===lr.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===lr.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===lr.Element&&n.element===t)}}const Gr={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};Gr.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(Gr.isTextNode(n)){n.value+=t;return}}Gr.appendChild(e,Gr.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Gr.isTextNode(r)?r.value+=t:Gr.insertBefore(e,Gr.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)}},R1="html",M3="about:legacy-compat",F3="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",P1=["+//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//"],B3=[...P1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],U3=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),L1=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],H3=[...L1,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function D1(e,t){return t.some(n=>e.startsWith(n))}function z3(e){return e.name===R1&&e.publicId===null&&(e.systemId===null||e.systemId===M3)}function j3(e){if(e.name!==R1)return Ln.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===F3)return Ln.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),U3.has(n))return Ln.QUIRKS;let r=t===null?B3:P1;if(D1(n,r))return Ln.QUIRKS;if(r=t===null?L1:H3,D1(n,r))return Ln.LIMITED_QUIRKS}return Ln.NO_QUIRKS}const M1={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},$3="definitionurl",V3="definitionURL",q3=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])),Y3=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}]]),W3=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])),G3=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 K3(e){const t=e.tagID;return t===m.FONT&&e.attrs.some(({name:r})=>r===Li.COLOR||r===Li.SIZE||r===Li.FACE)||G3.has(t)}function F1(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===$3){e.attrs[t].name=V3;break}}function B1(e){for(let t=0;t<e.attrs.length;t++){const n=q3.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function hf(e){for(let t=0;t<e.attrs.length;t++){const n=Y3.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 Q3(e){const t=W3.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=So(e.tagName))}function X3(e,t){return t===le.MATHML&&(e===m.MI||e===m.MO||e===m.MN||e===m.MS||e===m.MTEXT)}function J3(e,t,n){if(t===le.MATHML&&e===m.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Li.ENCODING){const o=n[r].value.toLowerCase();return o===M1.TEXT_HTML||o===M1.APPLICATION_XML}}return t===le.SVG&&(e===m.FOREIGN_OBJECT||e===m.DESC||e===m.TITLE)}function Z3(e,t,n,r){return(!r||r===le.HTML)&&J3(e,t,n)||(!r||r===le.MATHML)&&X3(e,t)}const eO="hidden",tO=8,nO=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 rO={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},U1=new Set([m.TABLE,m.TBODY,m.TFOOT,m.THEAD,m.TR]),H1={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Gr,onParseError:null};class z1{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({},H1),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 C3(this.options,this),this.activeFormattingElements=new D3(this.treeAdapter),this.fragmentContextID=r?So(this.treeAdapter.getTagName(r)):m.UNKNOWN,this._setContextModes(r!=null?r:this.document,this.fragmentContextID),this.openElements=new L3(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({},H1),n);t!=null||(t=r.treeAdapter.createElement(V.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:rO,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=xt.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===V.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=xt.RCDATA;break}case m.STYLE:case m.XMP:case m.IFRAME:case m.NOEMBED:case m.NOFRAMES:case m.NOSCRIPT:{this.tokenizer.state=xt.RAWTEXT;break}case m.SCRIPT:{this.tokenizer.state=xt.SCRIPT_DATA;break}case m.PLAINTEXT:{this.tokenizer.state=xt.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",o=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,o),t.location){const u=this.treeAdapter.getChildNodes(this.document).find(c=>this.treeAdapter.isDocumentTypeNode(c));u&&this.treeAdapter.setNodeSourceCodeLocation(u,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&se(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(V.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)===V.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 Z3(t,o,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(o=>o.type===lr.Marker||this.openElements.contains(o.element)),r=n===-1?t-1:n-1;for(let o=r;o>=0;o--){const a=this.activeFormattingElements.entries[o];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=L.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(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 U1.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 _3[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){PI(this,t);return}switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{qs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Gs(this,t);break}case L.AFTER_HEAD:{Ks(this,t);break}case L.IN_BODY:case L.IN_CAPTION:case L.IN_CELL:case L.IN_TEMPLATE:{$1(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:{Ef(this,t);break}case L.IN_TABLE_TEXT:{X1(this,t);break}case L.IN_COLUMN_GROUP:{$u(this,t);break}case L.AFTER_BODY:{Yu(this,t);break}case L.AFTER_AFTER_BODY:{Wu(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){RI(this,t);return}switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{qs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Gs(this,t);break}case L.AFTER_HEAD:{Ks(this,t);break}case L.TEXT:{this._insertCharacters(t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{Ef(this,t);break}case L.IN_COLUMN_GROUP:{$u(this,t);break}case L.AFTER_BODY:{Yu(this,t);break}case L.AFTER_AFTER_BODY:{Wu(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){mf(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:{mf(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.AFTER_BODY:{cO(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:{fO(this,t);break}case L.BEFORE_HEAD:case L.IN_HEAD:case L.IN_HEAD_NO_SCRIPT:case L.AFTER_HEAD:{this._err(t,J.misplacedDoctype);break}case L.IN_TABLE_TEXT:{Js(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,J.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?LI(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{hO(this,t);break}case L.BEFORE_HEAD:{mO(this,t);break}case L.IN_HEAD:{Wn(this,t);break}case L.IN_HEAD_NO_SCRIPT:{yO(this,t);break}case L.AFTER_HEAD:{bO(this,t);break}case L.IN_BODY:{Gt(this,t);break}case L.IN_TABLE:{vo(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.IN_CAPTION:{gI(this,t);break}case L.IN_COLUMN_GROUP:{yf(this,t);break}case L.IN_TABLE_BODY:{Vu(this,t);break}case L.IN_ROW:{qu(this,t);break}case L.IN_CELL:{TI(this,t);break}case L.IN_SELECT:{eE(this,t);break}case L.IN_SELECT_IN_TABLE:{xI(this,t);break}case L.IN_TEMPLATE:{_I(this,t);break}case L.AFTER_BODY:{vI(this,t);break}case L.IN_FRAMESET:{AI(this,t);break}case L.AFTER_FRAMESET:{kI(this,t);break}case L.AFTER_AFTER_BODY:{OI(this,t);break}case L.AFTER_AFTER_FRAMESET:{II(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?DI(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{pO(this,t);break}case L.BEFORE_HEAD:{gO(this,t);break}case L.IN_HEAD:{EO(this,t);break}case L.IN_HEAD_NO_SCRIPT:{TO(this,t);break}case L.AFTER_HEAD:{xO(this,t);break}case L.IN_BODY:{ju(this,t);break}case L.TEXT:{sI(this,t);break}case L.IN_TABLE:{Qs(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.IN_CAPTION:{EI(this,t);break}case L.IN_COLUMN_GROUP:{yI(this,t);break}case L.IN_TABLE_BODY:{Tf(this,t);break}case L.IN_ROW:{Z1(this,t);break}case L.IN_CELL:{bI(this,t);break}case L.IN_SELECT:{tE(this,t);break}case L.IN_SELECT_IN_TABLE:{wI(this,t);break}case L.IN_TEMPLATE:{SI(this,t);break}case L.AFTER_BODY:{rE(this,t);break}case L.IN_FRAMESET:{CI(this,t);break}case L.AFTER_FRAMESET:{NI(this,t);break}case L.AFTER_AFTER_BODY:{Wu(this,t);break}}}onEof(t){switch(this.insertionMode){case L.INITIAL:{Vs(this,t);break}case L.BEFORE_HTML:{qs(this,t);break}case L.BEFORE_HEAD:{Ys(this,t);break}case L.IN_HEAD:{Ws(this,t);break}case L.IN_HEAD_NO_SCRIPT:{Gs(this,t);break}case L.AFTER_HEAD:{Ks(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:{K1(this,t);break}case L.TEXT:{aI(this,t);break}case L.IN_TABLE_TEXT:{Js(this,t);break}case L.IN_TEMPLATE:{nE(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:{gf(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===C.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:{j1(this,t);break}case L.IN_TABLE:case L.IN_TABLE_BODY:case L.IN_ROW:{Ef(this,t);break}case L.IN_TABLE_TEXT:{Q1(this,t);break}}}}function iO(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):G1(e,t),n}function oO(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 sO(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>=nO;!c||d?(d&&e.activeFormattingElements.removeEntry(c),e.openElements.remove(u)):(u=aO(e,c),r===t&&(e.activeFormattingElements.bookmark=c),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(u,r),r=u)}return r}function aO(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 uO(e,t,n){const r=e.treeAdapter.getTagName(t),o=So(r);if(e._isElementCausesFosterParenting(o))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);o===m.TEMPLATE&&a===le.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function lO(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 pf(e,t){for(let n=0;n<tO;n++){const r=iO(e,t);if(!r)break;const o=oO(e,r);if(!o)break;e.activeFormattingElements.bookmark=r;const a=sO(e,o,r.element),u=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),u&&uO(e,u,a),lO(e,o,r)}}function mf(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function cO(e,t){e._appendCommentNode(t,e.openElements.items[0])}function dO(e,t){e._appendCommentNode(t,e.document)}function gf(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 fO(e,t){e._setDocumentType(t);const n=t.forceQuirks?Ln.QUIRKS:j3(t);z3(t)||e._err(t,J.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=L.BEFORE_HTML}function Vs(e,t){e._err(t,J.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Ln.QUIRKS),e.insertionMode=L.BEFORE_HTML,e._processToken(t)}function hO(e,t){t.tagID===m.HTML?(e._insertElement(t,le.HTML),e.insertionMode=L.BEFORE_HEAD):qs(e,t)}function pO(e,t){const n=t.tagID;(n===m.HTML||n===m.HEAD||n===m.BODY||n===m.BR)&&qs(e,t)}function qs(e,t){e._insertFakeRootElement(),e.insertionMode=L.BEFORE_HEAD,e._processToken(t)}function mO(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.HEAD:{e._insertElement(t,le.HTML),e.headElement=e.openElements.current,e.insertionMode=L.IN_HEAD;break}default:Ys(e,t)}}function gO(e,t){const n=t.tagID;n===m.HEAD||n===m.BODY||n===m.HTML||n===m.BR?Ys(e,t):e._err(t,J.endTagWithoutMatchingOpenElement)}function Ys(e,t){e._insertFakeElement(V.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:{Gt(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,xt.RCDATA);break}case m.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,xt.RAWTEXT):(e._insertElement(t,le.HTML),e.insertionMode=L.IN_HEAD_NO_SCRIPT);break}case m.NOFRAMES:case m.STYLE:{e._switchToTextParsing(t,xt.RAWTEXT);break}case m.SCRIPT:{e._switchToTextParsing(t,xt.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,J.misplacedStartTagForHeadElement);break}default:Ws(e,t)}}function EO(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:{Ws(e,t);break}case m.TEMPLATE:{Di(e,t);break}default:e._err(t,J.endTagWithoutMatchingOpenElement)}}function Di(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==m.TEMPLATE&&e._err(t,J.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,J.endTagWithoutMatchingOpenElement)}function Ws(e,t){e.openElements.pop(),e.insertionMode=L.AFTER_HEAD,e._processToken(t)}function yO(e,t){switch(t.tagID){case m.HTML:{Gt(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,J.nestedNoscriptInHead);break}default:Gs(e,t)}}function TO(e,t){switch(t.tagID){case m.NOSCRIPT:{e.openElements.pop(),e.insertionMode=L.IN_HEAD;break}case m.BR:{Gs(e,t);break}default:e._err(t,J.endTagWithoutMatchingOpenElement)}}function Gs(e,t){const n=t.type===Ve.EOF?J.openElementsLeftAfterEof:J.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=L.IN_HEAD,e._processToken(t)}function bO(e,t){switch(t.tagID){case m.HTML:{Gt(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,J.abandonedHeadElementChild),e.openElements.push(e.headElement,m.HEAD),Wn(e,t),e.openElements.remove(e.headElement);break}case m.HEAD:{e._err(t,J.misplacedStartTagForHeadElement);break}default:Ks(e,t)}}function xO(e,t){switch(t.tagID){case m.BODY:case m.HTML:case m.BR:{Ks(e,t);break}case m.TEMPLATE:{Di(e,t);break}default:e._err(t,J.endTagWithoutMatchingOpenElement)}}function Ks(e,t){e._insertFakeElement(V.BODY,m.BODY),e.insertionMode=L.IN_BODY,zu(e,t)}function zu(e,t){switch(t.type){case Ve.CHARACTER:{$1(e,t);break}case Ve.WHITESPACE_CHARACTER:{j1(e,t);break}case Ve.COMMENT:{mf(e,t);break}case Ve.START_TAG:{Gt(e,t);break}case Ve.END_TAG:{ju(e,t);break}case Ve.EOF:{K1(e,t);break}}}function j1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function $1(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function wO(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function _O(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function SO(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 vO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML)}function AO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&df.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,le.HTML)}function CO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function kO(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 NO(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 OO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._insertElement(t,le.HTML),e.tokenizer.state=xt.PLAINTEXT}function IO(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 RO(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(V.A);n&&(pf(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 PO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function LO(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(m.NOBR)&&(pf(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,le.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function DO(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function MO(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 V1(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function q1(e){const t=_1(e,Li.TYPE);return t!=null&&t.toLowerCase()===eO}function FO(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,le.HTML),q1(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function BO(e,t){e._appendElement(t,le.HTML),t.ackSelfClosing=!0}function UO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._appendElement(t,le.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function HO(e,t){t.tagName=V.IMG,t.tagID=m.IMG,V1(e,t)}function zO(e,t){e._insertElement(t,le.HTML),e.skipNextNewLine=!0,e.tokenizer.state=xt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=L.TEXT}function jO(e,t){e.openElements.hasInButtonScope(m.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function $O(e,t){e.framesetOk=!1,e._switchToTextParsing(t,xt.RAWTEXT)}function Y1(e,t){e._switchToTextParsing(t,xt.RAWTEXT)}function VO(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 qO(e,t){e.openElements.currentTagId===m.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function YO(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,le.HTML)}function WO(e,t){e.openElements.hasInScope(m.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(m.RTC),e._insertElement(t,le.HTML)}function GO(e,t){e._reconstructActiveFormattingElements(),F1(t),hf(t),t.selfClosing?e._appendElement(t,le.MATHML):e._insertElement(t,le.MATHML),t.ackSelfClosing=!0}function KO(e,t){e._reconstructActiveFormattingElements(),B1(t),hf(t),t.selfClosing?e._appendElement(t,le.SVG):e._insertElement(t,le.SVG),t.ackSelfClosing=!0}function W1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,le.HTML)}function Gt(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:{PO(e,t);break}case m.A:{RO(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{AO(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:{vO(e,t);break}case m.LI:case m.DD:case m.DT:{NO(e,t);break}case m.BR:case m.IMG:case m.WBR:case m.AREA:case m.EMBED:case m.KEYGEN:{V1(e,t);break}case m.HR:{UO(e,t);break}case m.RB:case m.RTC:{YO(e,t);break}case m.RT:case m.RP:{WO(e,t);break}case m.PRE:case m.LISTING:{CO(e,t);break}case m.XMP:{jO(e,t);break}case m.SVG:{KO(e,t);break}case m.HTML:{wO(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:{_O(e,t);break}case m.FORM:{kO(e,t);break}case m.NOBR:{LO(e,t);break}case m.MATH:{GO(e,t);break}case m.TABLE:{MO(e,t);break}case m.INPUT:{FO(e,t);break}case m.PARAM:case m.TRACK:case m.SOURCE:{BO(e,t);break}case m.IMAGE:{HO(e,t);break}case m.BUTTON:{IO(e,t);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{DO(e,t);break}case m.IFRAME:{$O(e,t);break}case m.SELECT:{VO(e,t);break}case m.OPTION:case m.OPTGROUP:{qO(e,t);break}case m.NOEMBED:case m.NOFRAMES:{Y1(e,t);break}case m.FRAMESET:{SO(e,t);break}case m.TEXTAREA:{zO(e,t);break}case m.NOSCRIPT:{e.options.scriptingEnabled?Y1(e,t):W1(e,t);break}case m.PLAINTEXT:{OO(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:W1(e,t)}}function QO(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 XO(e,t){e.openElements.hasInScope(m.BODY)&&(e.insertionMode=L.AFTER_BODY,rE(e,t))}function JO(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function ZO(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 eI(e){e.openElements.hasInButtonScope(m.P)||e._insertFakeElement(V.P,m.P),e._closePElement()}function tI(e){e.openElements.hasInListItemScope(m.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(m.LI),e.openElements.popUntilTagNamePopped(m.LI))}function nI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function rI(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function iI(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function oI(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(V.BR,m.BR),e.openElements.pop(),e.framesetOk=!1}function G1(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 ju(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:{pf(e,t);break}case m.P:{eI(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:{JO(e,t);break}case m.LI:{tI(e);break}case m.DD:case m.DT:{nI(e,t);break}case m.H1:case m.H2:case m.H3:case m.H4:case m.H5:case m.H6:{rI(e);break}case m.BR:{oI(e);break}case m.BODY:{QO(e,t);break}case m.HTML:{XO(e,t);break}case m.FORM:{ZO(e);break}case m.APPLET:case m.OBJECT:case m.MARQUEE:{iI(e,t);break}case m.TEMPLATE:{Di(e,t);break}default:G1(e,t)}}function K1(e,t){e.tmplInsertionModeStack.length>0?nE(e,t):gf(e,t)}function sI(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 aI(e,t){e._err(t,J.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Ef(e,t){if(e.openElements.currentTagId!==void 0&&U1.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:{X1(e,t);break}case Ve.WHITESPACE_CHARACTER:{Q1(e,t);break}}else Xs(e,t)}function uI(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_CAPTION}function lI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_COLUMN_GROUP}function cI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(V.COLGROUP,m.COLGROUP),e.insertionMode=L.IN_COLUMN_GROUP,yf(e,t)}function dI(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,le.HTML),e.insertionMode=L.IN_TABLE_BODY}function fI(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(V.TBODY,m.TBODY),e.insertionMode=L.IN_TABLE_BODY,Vu(e,t)}function hI(e,t){e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function pI(e,t){q1(t)?e._appendElement(t,le.HTML):Xs(e,t),t.ackSelfClosing=!0}function mI(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,le.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function vo(e,t){switch(t.tagID){case m.TD:case m.TH:case m.TR:{fI(e,t);break}case m.STYLE:case m.SCRIPT:case m.TEMPLATE:{Wn(e,t);break}case m.COL:{cI(e,t);break}case m.FORM:{mI(e,t);break}case m.TABLE:{hI(e,t);break}case m.TBODY:case m.TFOOT:case m.THEAD:{dI(e,t);break}case m.INPUT:{pI(e,t);break}case m.CAPTION:{uI(e,t);break}case m.COLGROUP:{lI(e,t);break}default:Xs(e,t)}}function Qs(e,t){switch(t.tagID){case m.TABLE:{e.openElements.hasInTableScope(m.TABLE)&&(e.openElements.popUntilTagNamePopped(m.TABLE),e._resetInsertionMode());break}case m.TEMPLATE:{Di(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:Xs(e,t)}}function Xs(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,zu(e,t),e.fosterParentingEnabled=n}function Q1(e,t){e.pendingCharacterTokens.push(t)}function X1(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Js(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Xs(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const J1=new Set([m.CAPTION,m.COL,m.COLGROUP,m.TBODY,m.TD,m.TFOOT,m.TH,m.THEAD,m.TR]);function gI(e,t){const n=t.tagID;J1.has(n)?e.openElements.hasInTableScope(m.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(m.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=L.IN_TABLE,vo(e,t)):Gt(e,t)}function EI(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&&Qs(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:ju(e,t)}}function yf(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.COL:{e._appendElement(t,le.HTML),t.ackSelfClosing=!0;break}case m.TEMPLATE:{Wn(e,t);break}default:$u(e,t)}}function yI(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:{Di(e,t);break}case m.COL:break;default:$u(e,t)}}function $u(e,t){e.openElements.currentTagId===m.COLGROUP&&(e.openElements.pop(),e.insertionMode=L.IN_TABLE,e._processToken(t))}function Vu(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(V.TR,m.TR),e.insertionMode=L.IN_ROW,qu(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,vo(e,t));break}default:vo(e,t)}}function Tf(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,Qs(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:Qs(e,t)}}function qu(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,Vu(e,t));break}default:vo(e,t)}}function Z1(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,Tf(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,Tf(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:Qs(e,t)}}function TI(e,t){const n=t.tagID;J1.has(n)?(e.openElements.hasInTableScope(m.TD)||e.openElements.hasInTableScope(m.TH))&&(e._closeTableCell(),qu(e,t)):Gt(e,t)}function bI(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(),Z1(e,t));break}case m.BODY:case m.CAPTION:case m.COL:case m.COLGROUP:case m.HTML:break;default:ju(e,t)}}function eE(e,t){switch(t.tagID){case m.HTML:{Gt(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 tE(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:{Di(e,t);break}}}function xI(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)):eE(e,t)}function wI(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)):tE(e,t)}function _I(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,vo(e,t);break}case m.COL:{e.tmplInsertionModeStack[0]=L.IN_COLUMN_GROUP,e.insertionMode=L.IN_COLUMN_GROUP,yf(e,t);break}case m.TR:{e.tmplInsertionModeStack[0]=L.IN_TABLE_BODY,e.insertionMode=L.IN_TABLE_BODY,Vu(e,t);break}case m.TD:case m.TH:{e.tmplInsertionModeStack[0]=L.IN_ROW,e.insertionMode=L.IN_ROW,qu(e,t);break}default:e.tmplInsertionModeStack[0]=L.IN_BODY,e.insertionMode=L.IN_BODY,Gt(e,t)}}function SI(e,t){t.tagID===m.TEMPLATE&&Di(e,t)}function nE(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(m.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):gf(e,t)}function vI(e,t){t.tagID===m.HTML?Gt(e,t):Yu(e,t)}function rE(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 Yu(e,t)}function Yu(e,t){e.insertionMode=L.IN_BODY,zu(e,t)}function AI(e,t){switch(t.tagID){case m.HTML:{Gt(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 CI(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 kI(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function NI(e,t){t.tagID===m.HTML&&(e.insertionMode=L.AFTER_AFTER_FRAMESET)}function OI(e,t){t.tagID===m.HTML?Gt(e,t):Wu(e,t)}function Wu(e,t){e.insertionMode=L.IN_BODY,zu(e,t)}function II(e,t){switch(t.tagID){case m.HTML:{Gt(e,t);break}case m.NOFRAMES:{Wn(e,t);break}}}function RI(e,t){t.chars=ft,e._insertCharacters(t)}function PI(e,t){e._insertCharacters(t),e.framesetOk=!1}function iE(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 LI(e,t){if(K3(t))iE(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===le.MATHML?F1(t):r===le.SVG&&(Q3(t),B1(t)),hf(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function DI(e,t){if(t.tagID===m.P||t.tagID===m.BR){iE(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}}}V.AREA,V.BASE,V.BASEFONT,V.BGSOUND,V.BR,V.COL,V.EMBED,V.FRAME,V.HR,V.IMG,V.INPUT,V.KEYGEN,V.LINK,V.META,V.PARAM,V.SOURCE,V.TRACK,V.WBR;const MI=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,FI=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),oE={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function sE(e,t){const n=WI(e),r=y1("type",{handlers:{root:BI,element:UI,text:HI,comment:uE,doctype:zI,raw:$I},unknown:VI}),o={parser:n?new z1(oE):z1.getFragmentParser(void 0,oE),handle(c){r(c,o)},stitches:!1,options:t||{}};r(e,o),Ao(o,ar());const a=n?o.parser.document:o.parser.getFragment(),u=BN(a,{file:o.options.file});return o.stitches&&Mu(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 aE(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function BI(e,t){aE(e.children,t)}function UI(e,t){qI(e,t),aE(e.children,t),YI(e,t)}function HI(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:Ve.CHARACTER,chars:e.value,location:Zs(e)};Ao(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function zI(e,t){const n={type:Ve.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Zs(e)};Ao(t,ar(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function jI(e,t){t.stitches=!0;const n=GI(e);if("children"in e&&"children"in n){const r=sE({type:"root",children:e.children},t.options);n.children=r.children}uE({type:"comment",value:{stitch:n}},t)}function uE(e,t){const n=e.value,r={type:Ve.COMMENT,data:n,location:Zs(e)};Ao(t,ar(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function $I(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,lE(t,ar(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(MI,"<$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 VI(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))jI(n,t);else{let r="";throw FI.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 Ao(e,t){lE(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=xt.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function lE(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 qI(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===xt.PLAINTEXT)return;Ao(t,ar(e));const r=t.parser.openElements.current;let o="namespaceURI"in r?r.namespaceURI:Ri.html;o===Ri.html&&n==="svg"&&(o=Ri.svg);const a=ZN(se(B({},e),{children:[]}),{space:o===Ri.svg?"svg":"html"}),u={type:Ve.START_TAG,tagName:n,tagID:So(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Zs(e)};t.parser.currentToken=u,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function YI(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&a3.includes(n)||t.parser.tokenizer.state===xt.PLAINTEXT)return;Ao(t,vu(e));const r={type:Ve.END_TAG,tagName:n,tagID:So(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Zs(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===xt.RCDATA||t.parser.tokenizer.state===xt.RAWTEXT||t.parser.tokenizer.state===xt.SCRIPT_DATA)&&(t.parser.tokenizer.state=xt.DATA)}function WI(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Zs(e){const t=ar(e)||{line:void 0,column:void 0,offset:void 0},n=vu(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 GI(e){return"children"in e?Ii(se(B({},e),{children:[]})):Ii(e)}function cE(e){return function(t,n){return sE(t,se(B({},e),{file:n}))}}const Mi=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],dE={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Mi,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Mi],h2:[["className","sr-only"]],img:[...Mi,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Mi,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Mi],table:[...Mi],ul:[...Mi,["className","contains-task-list"]],"*":["abbr","accept","acceptCharset","accessKey","action","align","alt","axis","border","cellPadding","cellSpacing","char","charOff","charSet","checked","clear","colSpan","color","cols","compact","coords","dateTime","dir","encType","frame","hSpace","headers","height","hrefLang","htmlFor","id","isMap","itemProp","label","lang","maxLength","media","method","multiple","name","noHref","noShade","noWrap","open","prompt","readOnly","rev","rowSpan","rows","rules","scope","selected","shape","size","span","start","summary","tabIndex","title","useMap","vAlign","value","width"]},clobber:["ariaDescribedBy","ariaLabelledBy","id","name"],clobberPrefix:"user-content-",protocols:{cite:["http","https"],href:["http","https","irc","ircs","mailto","xmpp"],longDesc:["http","https"],src:["http","https"]},required:{input:{disabled:!0,type:"checkbox"}},strip:["script"],tagNames:["a","b","blockquote","br","code","dd","del","details","div","dl","dt","em","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","li","ol","p","picture","pre","q","rp","rt","ruby","s","samp","section","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","tr","tt","ul","var"]},Kr={}.hasOwnProperty;function KI(e,t){let n={type:"root",children:[]};const r={schema:t?B(B({},dE),t):dE,stack:[]},o=fE(r,e);return o&&(Array.isArray(o)?o.length===1?n=o[0]:n.children=o:n=o),n}function fE(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return QI(e,n);case"doctype":return XI(e,n);case"element":return JI(e,n);case"root":return ZI(e,n);case"text":return eR(e,n)}}}function QI(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 ea(a,t),a}}function XI(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return ea(n,t),n}}function JI(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=hE(e,t.children),o=tR(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&&Kr.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 ea(u,t),u}function ZI(e,t){const r={type:"root",children:hE(e,t.children)};return ea(r,t),r}function eR(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return ea(r,t),r}function hE(e,t){const n=[];if(Array.isArray(t)){const r=t;let o=-1;for(;++o<r.length;){const a=fE(e,r[o]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function tR(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,o=e.schema.required,a=r&&Kr.call(r,n)?r[n]:void 0,u=r&&Kr.call(r,"*")?r["*"]:void 0,c=t&&typeof t=="object"?t:{},d={};let h;for(h in c)if(Kr.call(c,h)){const p=c[h];let E=pE(e,gE(a,h),h,p);E==null&&(E=pE(e,gE(u,h),h,p)),E!=null&&(d[h]=E)}if(o&&Kr.call(o,n)){const p=o[n];for(h in p)Kr.call(p,h)&&!Kr.call(d,h)&&(d[h]=p[h])}return d}function pE(e,t,n,r){return t?Array.isArray(r)?nR(e,t,n,r):mE(e,t,n,r):void 0}function nR(e,t,n,r){let o=-1;const a=[];for(;++o<r.length;){const u=mE(e,t,n,r[o]);(typeof u=="number"||typeof u=="string")&&a.push(u)}return a}function mE(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&rR(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 rR(e,t,n){const r=e.schema.protocols&&Kr.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 ea(e,t){const n=X0(t);t.data&&(e.data=Ii(t.data)),n&&(e.position=n)}function gE(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 iR(e){return function(t){return KI(t,e)}}const EE=({globalClassName:e,openLinksInNewTab:t,href:n,title:r,children:o})=>{const a=n?t?"_blank":"_self":void 0;return P.jsx("a",se(B(B({className:ae(e,`${ee}-link`)},n?{href:n,target:a}:{}),r?{title:r}:{}),{rel:"noopener noreferrer",children:o}))},oR=()=>{const{disclaimerText:e,disclaimerMarkdown:t,globalClassName:n}=kt();return!e&&!t?null:P.jsx("div",{className:ae(n,`${ee}-disclaimer`),children:t?P.jsx(Jg,{rehypePlugins:[cE,iR],components:{ul:({children:r})=>P.jsx("ul",{className:ae(n,`${ee}-ul`),children:r}),ol:({children:r})=>P.jsx("ol",{className:ae(n,`${ee}-ol`),children:r}),li:({children:r})=>P.jsx("li",{className:ae(n,`${ee}-li`),children:r}),a:({href:r,title:o,children:a})=>P.jsx(EE,{globalClassName:n,openLinksInNewTab:!0,href:r,title:o,children:a}),img:({src:r,alt:o})=>P.jsx("img",{className:ae(n,`${ee}-disclaimer-image`),src:r,alt:o}),p:({children:r})=>P.jsx("p",{className:ae(n,`${ee}-disclaimer-text`),children:r}),span:({children:r})=>P.jsx("span",{className:ae(n,`${ee}-disclaimer-text-span`),children:r})},children:t}):P.jsx("p",{className:ae(n,`${ee}-disclaimer-text`),children:e})})},bf=({className:e,isLoading:t,componentType:n,onSubmit:r})=>{const{isConnected:o}=ki(),{globalClassName:a,searchConfig:u}=kt(),c=X.useRef(null),d=t||!o,h=E=>{var T;E.preventDefault();const b=(((T=c.current)==null?void 0:T.value)||"").trim();b&&(c.current.value="",r(b))},p=()=>{r("Can you connect me to a human?")};return P.jsxs("div",{className:ae(a,e,`cim-${n}-component`,`${ee}-search-bar-wrapper`),children:[P.jsxs("form",{className:ae(a,e,`cim-${n}-component`,`${ee}-search-bar`),name:`${ee}-search-form`,onSubmit:h,children:[P.jsx("input",{className:ae(a,e,`cim-${n}-component`,`${ee}-search-input`),type:"text",ref:c,placeholder:(u==null?void 0:u.placeholder)||"Ask us anything",name:`${ee}-user-input`,disabled:d}),P.jsx(Cv,{className:e,globalClassName:a,searchConfig:u,componentType:n,isLoading:d}),P.jsx($r,{className:ae(a,`${ee}-escalate-btn`),ariaLabel:"Connect to a human agent",title:"Connect to a human agent",disabled:d,onClick:p,icon:P.jsx(xv,{})})]}),P.jsx(oR,{})]})};function sR(e){return tn({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 yE=X.createContext({isOpen:!1}),xf=X.createContext(null),TE=X.createContext(null),ta=()=>{var n,r;const e=X.useContext(xf),t=X.useContext(TE);return(r=(n=e==null?void 0:e.closeMenu)!=null?n:t==null?void 0:t.closeMenu)!=null?r:(()=>{})},bE=({onClearChat:e,componentType:t})=>{const n=ta(),r=()=>{e(),n()};return P.jsxs("button",{className:ae(`${ee}-overflow-menu-button`,"clear-chat-button",`cim-${t}-component`),onClick:r,children:[P.jsx(sR,{}),"Clear chat"]})};function aR(e){return e==null?[]:Array.isArray(e)?e:[e]}var uR=(e,...t)=>e.concat(t),lR=(e,...t)=>e.filter(n=>!t.includes(n)),cR=e=>Array.from(new Set(e));function xE(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 xE(e,t,{step:-r,loop:o})}var fR=e=>Array.isArray(e),wE=e=>e!=null&&typeof e=="object",hR=e=>wE(e)&&!fR(e),Gu=e=>typeof e=="string",Co=e=>typeof e=="function",pR=e=>e==null,mR=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),gR=e=>Object.prototype.toString.call(e),_E=Function.prototype.toString,ER=_E.call(Object),yR=e=>{if(!wE(e)||gR(e)!="[object Object]"||xR(e))return!1;const t=Object.getPrototypeOf(e);if(t===null)return!0;const n=mR(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&_E.call(n)==ER},TR=e=>typeof e=="object"&&e!==null&&"$$typeof"in e&&"props"in e,bR=e=>typeof e=="object"&&e!==null&&"__v_isVNode"in e,xR=e=>TR(e)||bR(e),wR=e=>e(),_R=()=>{},wf=(...e)=>(...t)=>{e.forEach(function(n){n==null||n(...t)})};function SR(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:vR,max:AR}=Math,CR=e=>Number.isNaN(e),kR=e=>CR(e)?0:e,SE=(e,t,n)=>vR(AR(kR(e),t),n);function _f(e){if(!yR(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]=_f(o))}return n}function Sf(...e){e.length===1?e[0]:e[1],e.length===2&&e[0]}function NR(e,t){if(e==null)throw new Error(t())}function OR(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 IR=Object.defineProperty,RR=(e,t,n)=>t in e?IR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vf=(e,t,n)=>RR(e,typeof t!="symbol"?t+"":t,n),vE=()=>{},Ku=e=>typeof e=="object"&&e!==null,ko=e=>e?"":void 0,AE=e=>e?"true":void 0,PR=1,LR=9,DR=11,Mt=e=>Ku(e)&&e.nodeType===PR&&typeof e.nodeName=="string",Qu=e=>Ku(e)&&e.nodeType===LR,MR=e=>Ku(e)&&e===e.window,CE=e=>Mt(e)?e.localName||"":"#document";function FR(e){return["html","body","#document"].includes(CE(e))}var BR=e=>Ku(e)&&e.nodeType!==void 0,Fi=e=>BR(e)&&e.nodeType===DR&&"host"in e,UR=e=>Mt(e)&&e.localName==="input",HR=e=>Mt(e)?e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0:!1;function na(e){if(!e)return!1;const t=e.getRootNode();return Io(t)===e}var zR=/(textarea|select)/;function jR(e){if(e==null||!Mt(e))return!1;try{return UR(e)&&e.selectionStart!=null||zR.test(e.localName)||e.isContentEditable||e.getAttribute("contenteditable")==="true"||e.getAttribute("contenteditable")===""}catch(t){return!1}}function No(e,t){var r;if(!e||!t||!Mt(e)||!Mt(t))return!1;const n=(r=t.getRootNode)==null?void 0:r.call(t);if(e===t||e.contains(t))return!0;if(n&&Fi(n)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function cr(e){var t;return Qu(e)?e:MR(e)?e.document:(t=e==null?void 0:e.ownerDocument)!=null?t:document}function $R(e){return cr(e).documentElement}function Oo(e){var t,n,r;return Fi(e)?Oo(e.host):Qu(e)?(t=e.defaultView)!=null?t:window:Mt(e)&&(r=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?r:window}function Io(e){let t=e.activeElement;for(;t!=null&&t.shadowRoot;){const n=t.shadowRoot.activeElement;if(!n||n===t)break;t=n}return t}function VR(e){if(CE(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Fi(e)&&e.host||$R(e);return Fi(t)?t.host:t}function Af(e){var n;let t;try{if(t=e.getRootNode({composed:!0}),Qu(t)||Fi(t))return t}catch(r){}return(n=e.ownerDocument)!=null?n:document}var Cf=new WeakMap;function Ro(e){return Cf.has(e)||Cf.set(e,Oo(e).getComputedStyle(e)),Cf.get(e)}var kf=new Set(["menu","listbox","dialog","grid","tree","region"]),qR=e=>kf.has(e),kE=e=>{var t;return((t=e.getAttribute("aria-controls"))==null?void 0:t.split(" "))||[]};function NE(e,t){const n=new Set,r=Af(e),o=a=>{const u=a.querySelectorAll("[aria-controls]");for(const c of u){if(c.getAttribute("aria-expanded")!=="true")continue;const d=kE(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"),b=p.getAttribute("aria-modal")==="true";if(E&&qR(E)&&!b&&(p===t||p.contains(t)||o(p)))return!0}}}return!1};return o(e)}function OE(e,t){const n=Af(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=kE(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"),b=p.getAttribute("aria-modal")==="true";E&&kf.has(E)&&!b&&(t(p),o(p))}}}};o(e)}function YR(e){const t=new Set;return OE(e,n=>{e.contains(n)||t.add(n)}),Array.from(t)}function WR(e){const t=e.getAttribute("role");return!!(t&&kf.has(t))}function GR(e){return e.hasAttribute("aria-controls")&&e.getAttribute("aria-expanded")==="true"}function KR(e){var t;return GR(e)?!0:!!((t=e.querySelector)!=null&&t.call(e,'[aria-controls][aria-expanded="true"]'))}function QR(e){if(!e.id)return!1;const t=Af(e),n=CSS.escape(e.id),r=`[aria-controls~="${n}"][aria-expanded="true"], [aria-controls="${n}"][aria-expanded="true"]`;return!!(t.querySelector(r)&&WR(e))}var Nf=()=>typeof document!="undefined";function XR(){var t;const e=navigator.userAgentData;return(t=e==null?void 0:e.platform)!=null?t:navigator.platform}var Of=e=>Nf()&&e.test(XR()),JR=e=>Nf()&&e.test(navigator.vendor),IE=()=>Nf()&&!!navigator.maxTouchPoints,ZR=()=>Of(/^iPhone/i),eP=()=>Of(/^iPad/i)||If()&&navigator.maxTouchPoints>1,Xu=()=>ZR()||eP(),tP=()=>If()||Xu(),If=()=>Of(/^Mac/i),nP=()=>tP()&&JR(/apple/i);function rP(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=rP(e);return(n=t==null?void 0:t[0])!=null?n:e.target}var RE=e=>e.button===0,iP=e=>e.button===2||If()&&e.ctrlKey&&e.button===0,oP=e=>"touches"in e&&e.touches.length>0,sP={Up:"ArrowUp",Down:"ArrowDown",Esc:"Escape"," ":"Space",",":"Comma",Left:"ArrowLeft",Right:"ArrowRight"},PE={ArrowLeft:"ArrowRight",ArrowRight:"ArrowLeft"};function aP(e,t={}){var u;const{dir:n="ltr",orientation:r="horizontal"}=t;let o=e.key;return o=(u=sP[o])!=null?u:o,n==="rtl"&&r==="horizontal"&&o in PE&&(o=PE[o]),o}function LE(e,t="client"){const n=oP(e)?e.touches[0]||e.changedTouches[0]:e;return{x:n[`${t}X`],y:n[`${t}Y`]}}var Ft=(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)}},DE=e=>Mt(e)&&e.tagName==="IFRAME",uP=/^(audio|video|details)$/;function ME(e){const t=e.getAttribute("tabindex");return t?parseInt(t,10):NaN}var lP=e=>!Number.isNaN(ME(e)),cP=e=>ME(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 FE(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(Ju)).filter(n),E=u.get(d);if(E!==void 0){const b=E+1;r.splice(b,0,...p),p.forEach((T,x)=>{u.set(T,b+x)});for(let T=b+p.length;T<r.length;T++)u.set(r[T],T)}else{const b=r.length;r.push(...p),p.forEach((T,x)=>{u.set(T,b+x)})}o.push(...p)}}return r}var Ju="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",BE=(e,t={})=>{if(!e)return[];const{includeContainer:n=!1,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ju));(n==!0||n=="if-empty"&&o.length===0)&&Mt(e)&&dr(e)&&o.unshift(e);const u=[];for(const c of o)if(dr(c)){if(DE(c)&&c.contentDocument){const d=c.contentDocument.body;u.push(...BE(d,{getShadowRoot:r}));continue}u.push(c)}return r?FE(u,r,dr):u};function dr(e){return!Mt(e)||e.closest("[inert]")?!1:e.matches(Ju)&&HR(e)}function Po(e,t={}){if(!e)return[];const{includeContainer:n,getShadowRoot:r}=t,o=Array.from(e.querySelectorAll(Ju));n&&Bi(e)&&o.unshift(e);const a=[];for(const u of o)if(Bi(u)){if(DE(u)&&u.contentDocument){const c=u.contentDocument.body;a.push(...Po(c,{getShadowRoot:r}));continue}a.push(u)}if(r){const u=FE(a,r,Bi);return!u.length&&n?o:u}return!a.length&&n?o:a}function Bi(e){return Mt(e)&&e.tabIndex>0?!0:dr(e)&&!cP(e)}function fP(e,t={}){const n=Po(e,t),r=n[0]||null,o=n[n.length-1]||null;return[r,o]}function hP(e,t={}){const{current:n,getShadowRoot:r}=t,o=Po(e,{getShadowRoot:r}),a=(e==null?void 0:e.ownerDocument)||document,u=n!=null?n:Io(a);if(!u)return null;const c=o.indexOf(u);return o[c+1]||null}function ra(e){return e.tabIndex<0&&(uP.test(e.localName)||jR(e))&&!lP(e)?0:e.tabIndex}function UE(e){const{root:t,getInitialEl:n,filter:r,enabled:o=!0}=e;if(!o)return;let a=null;if(a||(a=typeof n=="function"?n():n),a||(a=t==null?void 0:t.querySelector("[data-autofocus],[autofocus]")),!a){const u=Po(t);a=r?u.filter(r)[0]:u[0]}return a||t||void 0}var pP=class zx{constructor(){vf(this,"id",null),vf(this,"fn_cleanup"),vf(this,"cleanup",()=>{this.cancel()})}static create(){return new zx}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 Nt(e){const t=pP.create();return t.request(e),t.cleanup}function HE(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 Rf(e){const t=VR(e);return FR(t)?cr(t).body:Mt(t)&&EP(t)?t:Rf(t)}var mP=/auto|scroll|overlay|hidden|clip/,gP=new Set(["inline","contents"]);function EP(e){const t=Oo(e),{overflow:n,overflowX:r,overflowY:o,display:a}=t.getComputedStyle(e);return mP.test(n+o+r)&&!gP.has(a)}var Lo="default",Pf="",Zu=new WeakMap;function yP(e={}){const{target:t,doc:n}=e,r=n!=null?n:document,o=r.documentElement;return Xu()?(Lo==="default"&&(Pf=o.style.webkitUserSelect,o.style.webkitUserSelect="none"),Lo="disabled"):t&&(Zu.set(t,t.style.userSelect),t.style.userSelect="none"),()=>TP({target:t,doc:r})}function TP(e={}){const{target:t,doc:n}=e,o=(n!=null?n:document).documentElement;if(Xu()){if(Lo!=="disabled")return;Lo="restoring",setTimeout(()=>{HE(()=>{Lo==="restoring"&&(o.style.webkitUserSelect==="none"&&(o.style.webkitUserSelect=Pf||""),Pf="",Lo="default")})},300)}else if(t&&Zu.has(t)){const a=Zu.get(t);t.style.userSelect==="none"&&(t.style.userSelect=a!=null?a:""),t.getAttribute("style")===""&&t.removeAttribute("style"),Zu.delete(t)}}function bP(e={}){const u=e,{defer:t,target:n}=u,r=sn(u,["defer","target"]),o=t?Nt:c=>c(),a=[];return a.push(o(()=>{const c=typeof n=="function"?n():n;a.push(yP(se(B({},r),{target:c})))})),()=>{a.forEach(c=>c==null?void 0:c())}}function xP(e,t){const{onPointerMove:n,onPointerUp:r}=t,o=c=>{const d=LE(c),h=Math.sqrt(Za(d.x,2)+Za(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=LE(c);r({point:d,event:c})},u=[Ft(e,"pointermove",o,!1),Ft(e,"pointerup",a,!1),Ft(e,"pointercancel",a,!1),Ft(e,"contextmenu",a,!1),bP({doc:e})];return()=>{u.forEach(c=>c())}}function wP(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,b]=fP(e,{includeContainer:!0,getShadowRoot:a}),T=hP(c,{current:n,getShadowRoot:a}),x=!E&&!b;h.shiftKey&&na(T)?(o==null||o(),p=b):h.shiftKey&&(na(E)||x)?p=n:!h.shiftKey&&na(n)?(o==null||o(),p=E):!h.shiftKey&&(na(b)||x)&&(p=T),p&&(h.preventDefault(),typeof r=="function"?r(p):p.focus())}return Ft(u,"keydown",d,!0)}function _P(e,t){const c=t,{defer:n,triggerElement:r}=c,o=sn(c,["defer","triggerElement"]),a=n?Nt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof r=="function"?r():r;u.push(wP(d,B({triggerElement:h},o)))})),()=>{u.forEach(d=>d==null?void 0:d())}}function SP(e,t){var n;return Array.from((n=e==null?void 0:e.querySelectorAll(t))!=null?n:[])}function el(e,t){if(!e)return vE;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 vP(e,t,n){if(!e)return vE;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 AP(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 CP(e,t){const{timeout:n,rootNode:r}=t,o=Oo(r),a=cr(r),u=new o.AbortController;return AP(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 kP=(...e)=>e.map(t=>{var n;return(n=t==null?void 0:t.trim)==null?void 0:n.call(t)}).filter(Boolean).join(" "),NP=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,zE=e=>{const t={};let n;for(;n=NP.exec(e);)t[n[1]]=n[2];return t},OP=(e,t)=>{if(Gu(e)){if(Gu(t))return`${e};${t}`;e=zE(e)}else Gu(t)&&(t=zE(t));return Object.assign({},e!=null?e:{},t!=null?t:{})};function Ot(...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]=wf(n[o],t[o]);continue}if(o==="className"||o==="class"){t[o]=kP(t[o],n[o]);continue}if(o==="style"){t[o]=OP(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 qF(e){return e}var Do=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(Do||{}),Lf="__init__";function IP(e){const t=()=>{var u,c;return(c=(u=e.getRootNode)==null?void 0:u.call(e))!=null?c:document},n=()=>cr(t()),r=()=>{var u;return(u=n().defaultView)!=null?u:window},o=()=>Io(t()),a=u=>t().getElementById(u);return se(B({},e),{getRootNode:t,getDoc:n,getWin:r,getActiveElement:o,isActiveElement:na,getById:a})}function RP(e){return new Proxy({},{get(t,n){return n==="style"?r=>e({style:r}).style:e}})}var Mo=()=>e=>Array.from(new Set(e)),jE=typeof globalThis.document!="undefined"?X.useLayoutEffect:X.useEffect;function tl(e){var E,b;const t=(E=e().value)!=null?E:e().defaultValue,n=(b=e().isEqual)!=null?b:Object.is,[r]=X.useState(t),[o,a]=X.useState(r),u=e().value!==void 0,c=X.useRef(o);c.current=u?e().value:o;const d=X.useRef(c.current);jE(()=>{d.current=c.current},[o,e().value]);const h=T=>{var S,A;const x=d.current,_=Co(T)?T(x):T;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(T){(e().sync?Ns.flushSync:wR)(()=>h(T))},invoke(T,x){var _,S;(S=(_=e()).onChange)==null||S.call(_,T,x)},hash(T){var x,_,S;return(S=(_=(x=e()).hash)==null?void 0:_.call(x,T))!=null?S:String(T)}}}tl.cleanup=e=>{X.useEffect(()=>e,[])},tl.ref=e=>{const t=X.useRef(e);return{get:()=>t.current,set:n=>{t.current=n}}};function PP(e){const t=X.useRef(e);return{get(n){return t.current[n]},set(n,r){t.current[n]=r}}}var LP=(e,t)=>{const n=X.useRef(!1),r=X.useRef(!1);X.useEffect(()=>{if(n.current&&r.current)return t();r.current=!0},[...(e!=null?e:[]).map(o=>typeof o=="function"?o():o)]),X.useEffect(()=>(n.current=!0,()=>{n.current=!1}),[])};function nl(e,t={}){var W,te,oe,de,be,Ie;const n=X.useMemo(()=>{const{id:he,ids:G,getRootNode:ie}=t;return IP({id:he,ids:G,getRootNode:ie})},[t]),r=(...he)=>{e.debug&&console.log(...he)},o=(te=(W=e.props)==null?void 0:W.call(e,{props:_f(t),scope:n}))!=null?te:t,a=DP(o),u=(oe=e.context)==null?void 0:oe.call(e,{prop:a,bindable:tl,scope:n,flush:VE,getContext(){return d},getComputed(){return Y},getRefs(){return _},getEvent(){return T()}}),c=$E(u),d={get(he){var G;return(G=c.current)==null?void 0:G[he].ref.current},set(he,G){var ie;(ie=c.current)==null||ie[he].set(G)},initial(he){var G;return(G=c.current)==null?void 0:G[he].initial},hash(he){var ie,v;const G=(ie=c.current)==null?void 0:ie[he].get();return(v=c.current)==null?void 0:v[he].hash(G)}},h=X.useRef(new Map),p=X.useRef(null),E=X.useRef(null),b=X.useRef({type:""}),T=()=>se(B({},b.current),{current(){return b.current},previous(){return E.current}}),x=()=>se(B({},M),{matches(...he){return he.includes(M.ref.current)},hasTag(he){var G,ie;return!!((ie=(G=e.states[M.ref.current])==null?void 0:G.tags)!=null&&ie.includes(he))}}),_=PP((be=(de=e.refs)==null?void 0:de.call(e,{prop:a,context:d}))!=null?be:{}),S=()=>({state:x(),context:d,event:T(),prop:a,send:U,action:A,guard:O,track:LP,refs:_,computed:Y,flush:VE,scope:n,choose:z}),A=he=>{const G=Co(he)?he(S()):he;if(!G)return;const ie=G.map(v=>{var Z,k;const D=(k=(Z=e.implementations)==null?void 0:Z.actions)==null?void 0:k[v];return D||Sf(`[zag-js] No implementation found for action "${JSON.stringify(v)}"`),D});for(const v of ie)v==null||v(S())},O=he=>{var G,ie;return Co(he)?he(S()):(ie=(G=e.implementations)==null?void 0:G.guards)==null?void 0:ie[he](S())},I=he=>{const G=Co(he)?he(S()):he;if(!G)return;const ie=G.map(D=>{var k,xe;const Z=(xe=(k=e.implementations)==null?void 0:k.effects)==null?void 0:xe[D];return Z||Sf(`[zag-js] No implementation found for effect "${JSON.stringify(D)}"`),Z}),v=[];for(const D of ie){const Z=D==null?void 0:D(S());Z&&v.push(Z)}return()=>v.forEach(D=>D==null?void 0:D())},z=he=>aR(he).find(G=>{let ie=!G.guard;return Gu(G.guard)?ie=!!O(G.guard):Co(G.guard)&&(ie=G.guard(S())),ie}),Y=he=>{NR(e.computed,()=>"[zag-js] No computed object found on machine");const G=e.computed[he];return G({context:d,event:T(),prop:a,refs:_,scope:n,computed:Y})},M=tl(()=>({defaultValue:e.initialState({prop:a}),onChange(he,G){var v,D,Z,k;if(G){const xe=h.current.get(G);xe==null||xe(),h.current.delete(G)}G&&A((v=e.states[G])==null?void 0:v.exit),A((D=p.current)==null?void 0:D.actions);const ie=I((Z=e.states[he])==null?void 0:Z.effects);if(ie&&h.current.set(he,ie),G===Lf){A(e.entry);const xe=I(e.effects);xe&&h.current.set(Lf,xe)}A((k=e.states[he])==null?void 0:k.entry)}})),Q=X.useRef(void 0),Ee=X.useRef(Do.NotStarted);jE(()=>{queueMicrotask(()=>{var D;const ie=Ee.current===Do.Started;Ee.current=Do.Started,r(ie?"rehydrating...":"initializing...");const v=(D=Q.current)!=null?D:M.initial;M.invoke(v,ie?M.get():Lf)});const he=h.current,G=M.ref.current;return()=>{r("unmounting..."),Q.current=G,Ee.current=Do.Stopped,he.forEach(ie=>ie==null?void 0:ie()),h.current=new Map,p.current=null,queueMicrotask(()=>{A(e.exit)})}},[]);const re=()=>"ref"in M?M.ref.current:M.get(),U=he=>{queueMicrotask(()=>{var k,xe,Pe,Ne,He;if(Ee.current!==Do.Started)return;E.current=b.current,b.current=he;let G=re();const ie=(Pe=(k=e.states[G].on)==null?void 0:k[he.type])!=null?Pe:(xe=e.on)==null?void 0:xe[he.type],v=z(ie);if(!v)return;p.current=v;const D=(Ne=v.target)!=null?Ne:G;r("transition",he.type,v.target||G,`(${v.actions})`);const Z=D!==G;Z?Ns.flushSync(()=>M.set(D)):v.reenter&&!Z?M.invoke(G,G):A((He=v.actions)!=null?He:[])})};return(Ie=e.watch)==null||Ie.call(e,S()),{state:x(),send:U,context:d,prop:a,scope:n,refs:_,computed:Y,event:T(),getStatus:()=>Ee.current}}function $E(e){const t=X.useRef(e);return t.current=e,t}function DP(e){const t=$E(e);return function(r){return t.current[r]}}function VE(e){queueMicrotask(()=>{Ns.flushSync(()=>e())})}var Df=RP(e=>e);function rl(...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 MP(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 Mf=e=>{const t=X.memo(X.forwardRef((n,r)=>{const h=n,{asChild:o,children:a}=h,u=sn(h,["asChild","children"]);if(!o)return X.createElement(e,se(B({},u),{ref:r}),a);if(!X.isValidElement(a))return null;const c=X.Children.only(a),d=MP(c);return X.cloneElement(c,se(B({},Ot(u,c.props)),{ref:r?rl(r,d):d}))}));return t.displayName=e.displayName||e.name,t},Kt=(()=>{const e=new Map;return new Proxy(Mf,{apply(t,n,r){return Mf(r[0])},get(t,n){const r=n;return e.has(r)||e.set(r,Mf(r)),e.get(r)}})})();function FP(e,t){return`${e} returned \`undefined\`. Seems you forgot to wrap component within ${t}`}function Ui(e={}){const{name:t,strict:n=!0,hookName:r="useContext",providerName:o="Provider",errorMessage:a,defaultValue:u}=e,c=X.createContext(u);c.displayName=t;function d(){var p;const h=X.useContext(c);if(!h&&n){const E=new Error(a!=null?a:FP(r,o));throw E.name="ContextError",(p=Error.captureStackTrace)==null||p.call(Error,E,d),E}return h}return[c.Provider,d,c]}const[BP,Ff]=Ui({name:"PopoverContext",hookName:"usePopoverContext",providerName:"<PopoverProvider />"}),[qE,ia]=Ui({name:"PresenceContext",hookName:"usePresenceContext",providerName:"<PresenceProvider />"}),YE=X.forwardRef((e,t)=>{const n=Ff(),r=ia(),o=Ot(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:P.jsx(Kt.div,se(B({},o),{ref:rl(r.ref,t)}))});YE.displayName="PopoverContent";const WE=X.forwardRef((e,t)=>{const n=Ff(),r=ia(),o=Ot(n.getPositionerProps(),e);return r.unmounted?null:P.jsx(Kt.div,se(B({},o),{ref:t}))});WE.displayName="PopoverPositioner";const oa=()=>(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)]),GE=e=>oa()(e,["immediate","lazyMount","onExitComplete","present","skipAnimationOnMount","unmountOnExit"]);function UP(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 HP={props({props:e}){return se(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",Ro(t.node)))},cleanupNode:({refs:e})=>{e.set("node",null),e.set("styles",null)},syncPresence:({context:e,refs:t,send:n,prop:r})=>{const o=r("present");if(o)return n({type:"MOUNT",src:"presence.changed"});const a=t.get("node");if(!o&&(a==null?void 0:a.ownerDocument.visibilityState)==="hidden")return n({type:"UNMOUNT",src:"visibilitychange"});Nt(()=>{var c,d;const u=il(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})=>{Nt(()=>{e.set("prevAnimationName",il(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,b;((b=(E=(p=d.composedPath)==null?void 0:p.call(d))==null?void 0:E[0])!=null?b:d.target)===o&&e.set("prevAnimationName",il(t.get("styles")))},u=d=>{const h=il(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=el(o,{animationFillMode:"forwards"});return()=>{o.removeEventListener("animationstart",a),o.removeEventListener("animationcancel",u),o.removeEventListener("animationend",u),HE(()=>c())}}}}};function il(e){return(e==null?void 0:e.animationName)||"none"}Mo()(["onExitComplete","present","immediate"]);function zP(e,t={}){const{sync:n=!1}=t,r=jP(e);return X.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 jP(e){const t=X.useRef(e);return t.current=e,t}const Bf=(e={})=>{const b=e,{lazyMount:t,unmountOnExit:n,present:r,skipAnimationOnMount:o=!1}=b,a=sn(b,["lazyMount","unmountOnExit","present","skipAnimationOnMount"]),u=X.useRef(!1),c=se(B({},a),{present:r,onExitComplete:zP(e.onExitComplete)}),d=nl(HP,c),h=UP(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 Hi=(e,t=[])=>({parts:(...n)=>{if($P(t))return Hi(e,n);throw new Error("createAnatomy().parts(...) should only be called once. Did you mean to use .extendWith(...) ?")},extendWith:(...n)=>Hi(e,[...t,...n]),omit:(...n)=>Hi(e,t.filter(r=>!n.includes(r))),rename:n=>Hi(n,t),keys:()=>t,build:()=>[...new Set(t)].reduce((n,r)=>Object.assign(n,{[r]:{selector:[`&[data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`,`& [data-scope="${Fo(e)}"][data-part="${Fo(r)}"]`].join(", "),attrs:{"data-scope":Fo(e),"data-part":Fo(r)}}}),{})}),Fo=e=>e.replace(/([A-Z])([A-Z])/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),$P=e=>e.length===0;const VP=["top","right","bottom","left"],Qr=Math.min,_n=Math.max,ol=Math.round,sl=Math.floor,fr=e=>({x:e,y:e}),qP={left:"right",right:"left",bottom:"top",top:"bottom"},YP={start:"end",end:"start"};function Uf(e,t,n){return _n(e,Qr(t,n))}function Ar(e,t){return typeof e=="function"?e(t):e}function Cr(e){return e.split("-")[0]}function Bo(e){return e.split("-")[1]}function Hf(e){return e==="x"?"y":"x"}function zf(e){return e==="y"?"height":"width"}const WP=new Set(["top","bottom"]);function hr(e){return WP.has(Cr(e))?"y":"x"}function jf(e){return Hf(hr(e))}function GP(e,t,n){n===void 0&&(n=!1);const r=Bo(e),o=jf(e),a=zf(o);let u=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(u=al(u)),[u,al(u)]}function KP(e){const t=al(e);return[$f(e),t,$f(t)]}function $f(e){return e.replace(/start|end/g,t=>YP[t])}const KE=["left","right"],QE=["right","left"],QP=["top","bottom"],XP=["bottom","top"];function JP(e,t,n){switch(e){case"top":case"bottom":return n?t?QE:KE:t?KE:QE;case"left":case"right":return t?QP:XP;default:return[]}}function ZP(e,t,n,r){const o=Bo(e);let a=JP(Cr(e),n==="start",r);return o&&(a=a.map(u=>u+"-"+o),t&&(a=a.concat(a.map($f)))),a}function al(e){return e.replace(/left|right|bottom|top/g,t=>qP[t])}function eL(e){return B({top:0,right:0,bottom:0,left:0},e)}function XE(e){return typeof e!="number"?eL(e):{top:e,right:e,bottom:e,left:e}}function ul(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function JE(e,t,n){let{reference:r,floating:o}=e;const a=hr(t),u=jf(t),c=zf(u),d=Cr(t),h=a==="y",p=r.x+r.width/2-o.width/2,E=r.y+r.height/2-o.height/2,b=r[c]/2-o[c]/2;let T;switch(d){case"top":T={x:p,y:r.y-o.height};break;case"bottom":T={x:p,y:r.y+r.height};break;case"right":T={x:r.x+r.width,y:E};break;case"left":T={x:r.x-o.width,y:E};break;default:T={x:r.x,y:r.y}}switch(Bo(t)){case"start":T[u]-=b*(n&&h?-1:1);break;case"end":T[u]+=b*(n&&h?-1:1);break}return T}const tL=(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}=JE(h,r,d),b=r,T={},x=0;for(let _=0;_<c.length;_++){const{name:S,fn:A}=c[_],{x:O,y:I,data:z,reset:Y}=yield A({x:p,y:E,initialPlacement:r,placement:b,strategy:o,middlewareData:T,rects:h,platform:u,elements:{reference:e,floating:t}});p=O!=null?O:p,E=I!=null?I:E,T=se(B({},T),{[S]:B(B({},T[S]),z)}),Y&&x<=50&&(x++,typeof Y=="object"&&(Y.placement&&(b=Y.placement),Y.rects&&(h=Y.rects===!0?yield u.getElementRects({reference:e,floating:t,strategy:o}):Y.rects),{x:p,y:E}=JE(h,b,d)),_=-1)}return{x:p,y:E,placement:b,strategy:o,middlewareData:T}});function sa(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:b=!1,padding:T=0}=Ar(t,e),x=XE(T),S=c[b?E==="floating"?"reference":"floating":E],A=ul(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,I=yield a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating),z=(yield a.isElement==null?void 0:a.isElement(I))?(yield a.getScale==null?void 0:a.getScale(I))||{x:1,y:1}:{x:1,y:1},Y=ul(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:O,offsetParent:I,strategy:d}):O);return{top:(A.top-Y.top+x.top)/z.y,bottom:(Y.bottom-A.bottom+x.bottom)/z.y,left:(A.left-Y.left+x.left)/z.x,right:(Y.right-A.right+x.right)/z.x}})}const nL=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}=Ar(e,n)||{};if(p==null)return{};const b=XE(E),T={x:r,y:o},x=jf(a),_=zf(x),S=yield c.getDimensions(p),A=x==="y",O=A?"top":"left",I=A?"bottom":"right",z=A?"clientHeight":"clientWidth",Y=u.reference[_]+u.reference[x]-T[x]-u.floating[_],M=T[x]-u.reference[x],Q=yield c.getOffsetParent==null?void 0:c.getOffsetParent(p);let Ee=Q?Q[z]:0;(!Ee||!(yield c.isElement==null?void 0:c.isElement(Q)))&&(Ee=d.floating[z]||u.floating[_]);const re=Y/2-M/2,U=Ee/2-S[_]/2-1,W=Qr(b[O],U),te=Qr(b[I],U),oe=W,de=Ee-S[_]-te,be=Ee/2-S[_]/2+re,Ie=Uf(oe,be,de),he=!h.arrow&&Bo(a)!=null&&be!==Ie&&u.reference[_]/2-(be<oe?W:te)-S[_]/2<0,G=he?be<oe?be-oe:be-de:0;return{[x]:T[x]+G,data:B({[x]:Ie,centerOffset:be-Ie-G},he&&{alignmentOffset:G}),reset:he}})}}),rL=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=Ar(e,n),{mainAxis:E=!0,crossAxis:b=!0,fallbackPlacements:T,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=Cr(a),I=hr(d),z=Cr(d)===d,Y=yield h.isRTL==null?void 0:h.isRTL(p.floating),M=T||(z||!S?[al(d)]:KP(d)),Q=_!=="none";!T&&Q&&M.push(...ZP(d,S,_,Y));const Ee=[d,...M],re=yield sa(n,A),U=[];let W=((o=u.flip)==null?void 0:o.overflows)||[];if(E&&U.push(re[O]),b){const Ie=GP(a,c,Y);U.push(re[Ie[0]],re[Ie[1]])}if(W=[...W,{placement:a,overflows:U}],!U.every(Ie=>Ie<=0)){var te,oe;const Ie=(((te=u.flip)==null?void 0:te.index)||0)+1,he=Ee[Ie];if(he&&(!(b==="alignment"?I!==hr(he):!1)||W.every(v=>hr(v.placement)===I?v.overflows[0]>0:!0)))return{data:{index:Ie,overflows:W},reset:{placement:he}};let G=(oe=W.filter(ie=>ie.overflows[0]<=0).sort((ie,v)=>ie.overflows[1]-v.overflows[1])[0])==null?void 0:oe.placement;if(!G)switch(x){case"bestFit":{var de;const ie=(de=W.filter(v=>{if(Q){const D=hr(v.placement);return D===I||D==="y"}return!0}).map(v=>[v.placement,v.overflows.filter(D=>D>0).reduce((D,Z)=>D+Z,0)]).sort((v,D)=>v[1]-D[1])[0])==null?void 0:de[0];ie&&(G=ie);break}case"initialPlacement":G=d;break}if(a!==G)return{reset:{placement:G}}}return{}})}}};function ZE(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ey(e){return VP.some(t=>e[t]>=0)}const iL=function(e){return e===void 0&&(e={}),{name:"hide",options:e,fn(n){return $e(this,null,function*(){const{rects:r}=n,u=Ar(e,n),{strategy:o="referenceHidden"}=u,a=sn(u,["strategy"]);switch(o){case"referenceHidden":{const c=yield sa(n,se(B({},a),{elementContext:"reference"})),d=ZE(c,r.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:ey(d)}}}case"escaped":{const c=yield sa(n,se(B({},a),{altBoundary:!0})),d=ZE(c,r.floating);return{data:{escapedOffsets:d,escaped:ey(d)}}}default:return{}}})}}},ty=new Set(["left","top"]);function oL(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=Cr(n),c=Bo(n),d=hr(n)==="y",h=ty.has(u)?-1:1,p=a&&d?-1:1,E=Ar(t,e);let{mainAxis:b,crossAxis:T,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"&&(T=c==="end"?x*-1:x),d?{x:T*p,y:b*h}:{x:b*h,y:T*p}})}const sL=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 oL(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:se(B({},h),{placement:c})}})}}},aL=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=Ar(e,n),{mainAxis:u=!0,crossAxis:c=!1,limiter:d={fn:O=>{let{x:I,y:z}=O;return{x:I,y:z}}}}=A,h=sn(A,["mainAxis","crossAxis","limiter"]),p={x:r,y:o},E=yield sa(n,h),b=hr(Cr(a)),T=Hf(b);let x=p[T],_=p[b];if(u){const O=T==="y"?"top":"left",I=T==="y"?"bottom":"right",z=x+E[O],Y=x-E[I];x=Uf(z,x,Y)}if(c){const O=b==="y"?"top":"left",I=b==="y"?"bottom":"right",z=_+E[O],Y=_-E[I];_=Uf(z,_,Y)}const S=d.fn(se(B({},n),{[T]:x,[b]:_}));return se(B({},S),{data:{x:S.x-r,y:S.y-o,enabled:{[T]:u,[b]:c}}})})}}},uL=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:u}=t,{offset:c=0,mainAxis:d=!0,crossAxis:h=!0}=Ar(e,t),p={x:n,y:r},E=hr(o),b=Hf(E);let T=p[b],x=p[E];const _=Ar(c,t),S=typeof _=="number"?{mainAxis:_,crossAxis:0}:B({mainAxis:0,crossAxis:0},_);if(d){const I=b==="y"?"height":"width",z=a.reference[b]-a.floating[I]+S.mainAxis,Y=a.reference[b]+a.reference[I]-S.mainAxis;T<z?T=z:T>Y&&(T=Y)}if(h){var A,O;const I=b==="y"?"width":"height",z=ty.has(Cr(o)),Y=a.reference[E]-a.floating[I]+(z&&((A=u.offset)==null?void 0:A[E])||0)+(z?0:S.crossAxis),M=a.reference[E]+a.reference[I]+(z?0:((O=u.offset)==null?void 0:O[E])||0)-(z?S.crossAxis:0);x<Y?x=Y:x>M&&(x=M)}return{[b]:T,[E]:x}}}},lL=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,W=Ar(e,n),{apply:h=()=>{}}=W,p=sn(W,["apply"]),E=yield sa(n,p),b=Cr(a),T=Bo(a),x=hr(a)==="y",{width:_,height:S}=u.floating;let A,O;b==="top"||b==="bottom"?(A=b,O=T===((yield c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(O=b,A=T==="end"?"top":"bottom");const I=S-E.top-E.bottom,z=_-E.left-E.right,Y=Qr(S-E[A],I),M=Qr(_-E[O],z),Q=!n.middlewareData.shift;let Ee=Y,re=M;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(re=z),(o=n.middlewareData.shift)!=null&&o.enabled.y&&(Ee=I),Q&&!T){const te=_n(E.left,0),oe=_n(E.right,0),de=_n(E.top,0),be=_n(E.bottom,0);x?re=_-2*(te!==0||oe!==0?te+oe:_n(E.left,E.right)):Ee=S-2*(de!==0||be!==0?de+be:_n(E.top,E.bottom))}yield h(se(B({},n),{availableWidth:re,availableHeight:Ee}));const U=yield c.getDimensions(d.floating);return _!==U.width||S!==U.height?{reset:{rects:!0}}:{}})}}};function ll(){return typeof window!="undefined"}function Uo(e){return ny(e)?(e.nodeName||"").toLowerCase():"#document"}function Sn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function pr(e){var t;return(t=(ny(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function ny(e){return ll()?e instanceof Node||e instanceof Sn(e).Node:!1}function Kn(e){return ll()?e instanceof Element||e instanceof Sn(e).Element:!1}function mr(e){return ll()?e instanceof HTMLElement||e instanceof Sn(e).HTMLElement:!1}function ry(e){return!ll()||typeof ShadowRoot=="undefined"?!1:e instanceof ShadowRoot||e instanceof Sn(e).ShadowRoot}const cL=new Set(["inline","contents"]);function aa(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!cL.has(o)}const dL=new Set(["table","td","th"]);function fL(e){return dL.has(Uo(e))}const hL=[":popover-open",":modal"];function cl(e){return hL.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const pL=["transform","translate","scale","rotate","perspective"],mL=["transform","translate","scale","rotate","perspective","filter"],gL=["paint","layout","strict","content"];function Vf(e){const t=qf(),n=Kn(e)?Qn(e):e;return pL.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)||mL.some(r=>(n.willChange||"").includes(r))||gL.some(r=>(n.contain||"").includes(r))}function EL(e){let t=Xr(e);for(;mr(t)&&!Ho(t);){if(Vf(t))return t;if(cl(t))return null;t=Xr(t)}return null}function qf(){return typeof CSS=="undefined"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const yL=new Set(["html","body","#document"]);function Ho(e){return yL.has(Uo(e))}function Qn(e){return Sn(e).getComputedStyle(e)}function dl(e){return Kn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Xr(e){if(Uo(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ry(e)&&e.host||pr(e);return ry(t)?t.host:t}function iy(e){const t=Xr(e);return Ho(t)?e.ownerDocument?e.ownerDocument.body:e.body:mr(t)&&aa(t)?t:iy(t)}function ua(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=iy(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),u=Sn(o);if(a){const c=Yf(u);return t.concat(u,u.visualViewport||[],aa(o)?o:[],c&&n?ua(c):[])}return t.concat(o,ua(o,[],n))}function Yf(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function oy(e){const t=Qn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=mr(e),a=o?e.offsetWidth:n,u=o?e.offsetHeight:r,c=ol(n)!==a||ol(r)!==u;return c&&(n=a,r=u),{width:n,height:r,$:c}}function Wf(e){return Kn(e)?e:e.contextElement}function zo(e){const t=Wf(e);if(!mr(t))return fr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=oy(t);let u=(a?ol(n.width):n.width)/r,c=(a?ol(n.height):n.height)/o;return(!u||!Number.isFinite(u))&&(u=1),(!c||!Number.isFinite(c))&&(c=1),{x:u,y:c}}const TL=fr(0);function sy(e){const t=Sn(e);return!qf()||!t.visualViewport?TL:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function bL(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Sn(e)?!1:t}function zi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=Wf(e);let u=fr(1);t&&(r?Kn(r)&&(u=zo(r)):u=zo(e));const c=bL(a,n,r)?sy(a):fr(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 b=Sn(a),T=r&&Kn(r)?Sn(r):r;let x=b,_=Yf(x);for(;_&&r&&T!==x;){const S=zo(_),A=_.getBoundingClientRect(),O=Qn(_),I=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+=I,h+=z,x=Sn(_),_=Yf(x)}}return ul({width:p,height:E,x:d,y:h})}function fl(e,t){const n=dl(e).scrollLeft;return t?t.left+n:zi(pr(e)).left+n}function ay(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-fl(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function xL(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",u=pr(r),c=t?cl(t.floating):!1;if(r===u||c&&a)return n;let d={scrollLeft:0,scrollTop:0},h=fr(1);const p=fr(0),E=mr(r);if((E||!E&&!a)&&((Uo(r)!=="body"||aa(u))&&(d=dl(r)),mr(r))){const T=zi(r);h=zo(r),p.x=T.x+r.clientLeft,p.y=T.y+r.clientTop}const b=u&&!E&&!a?ay(u,d):fr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+p.x+b.x,y:n.y*h.y-d.scrollTop*h.y+p.y+b.y}}function wL(e){return Array.from(e.getClientRects())}function _L(e){const t=pr(e),n=dl(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+fl(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 uy=25;function SL(e,t){const n=Sn(e),r=pr(e),o=n.visualViewport;let a=r.clientWidth,u=r.clientHeight,c=0,d=0;if(o){a=o.width,u=o.height;const p=qf();(!p||p&&t==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const h=fl(r);if(h<=0){const p=r.ownerDocument,E=p.body,b=getComputedStyle(E),T=p.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,x=Math.abs(r.clientWidth-E.clientWidth-T);x<=uy&&(a-=x)}else h<=uy&&(a+=h);return{width:a,height:u,x:c,y:d}}const vL=new Set(["absolute","fixed"]);function AL(e,t){const n=zi(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=mr(e)?zo(e):fr(1),u=e.clientWidth*a.x,c=e.clientHeight*a.y,d=o*a.x,h=r*a.y;return{width:u,height:c,x:d,y:h}}function ly(e,t,n){let r;if(t==="viewport")r=SL(e,n);else if(t==="document")r=_L(pr(e));else if(Kn(t))r=AL(t,n);else{const o=sy(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return ul(r)}function cy(e,t){const n=Xr(e);return n===t||!Kn(n)||Ho(n)?!1:Qn(n).position==="fixed"||cy(n,t)}function CL(e,t){const n=t.get(e);if(n)return n;let r=ua(e,[],!1).filter(c=>Kn(c)&&Uo(c)!=="body"),o=null;const a=Qn(e).position==="fixed";let u=a?Xr(e):e;for(;Kn(u)&&!Ho(u);){const c=Qn(u),d=Vf(u);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&vL.has(o.position)||aa(u)&&!d&&cy(e,u))?r=r.filter(p=>p!==u):o=c,u=Xr(u)}return t.set(e,r),r}function kL(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const u=[...n==="clippingAncestors"?cl(t)?[]:CL(t,this._c):[].concat(n),r],c=u[0],d=u.reduce((h,p)=>{const E=ly(t,p,o);return h.top=_n(E.top,h.top),h.right=Qr(E.right,h.right),h.bottom=Qr(E.bottom,h.bottom),h.left=_n(E.left,h.left),h},ly(t,c,o));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function NL(e){const{width:t,height:n}=oy(e);return{width:t,height:n}}function OL(e,t,n){const r=mr(t),o=pr(t),a=n==="fixed",u=zi(e,!0,a,t);let c={scrollLeft:0,scrollTop:0};const d=fr(0);function h(){d.x=fl(o)}if(r||!r&&!a)if((Uo(t)!=="body"||aa(o))&&(c=dl(t)),r){const T=zi(t,!0,a,t);d.x=T.x+t.clientLeft,d.y=T.y+t.clientTop}else o&&h();a&&!r&&o&&h();const p=o&&!r&&!a?ay(o,c):fr(0),E=u.left+c.scrollLeft-d.x-p.x,b=u.top+c.scrollTop-d.y-p.y;return{x:E,y:b,width:u.width,height:u.height}}function Gf(e){return Qn(e).position==="static"}function dy(e,t){if(!mr(e)||Qn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return pr(e)===n&&(n=n.ownerDocument.body),n}function fy(e,t){const n=Sn(e);if(cl(e))return n;if(!mr(e)){let o=Xr(e);for(;o&&!Ho(o);){if(Kn(o)&&!Gf(o))return o;o=Xr(o)}return n}let r=dy(e,t);for(;r&&fL(r)&&Gf(r);)r=dy(r,t);return r&&Ho(r)&&Gf(r)&&!Vf(r)?n:r||EL(e)||n}const IL=function(e){return $e(this,null,function*(){const t=this.getOffsetParent||fy,n=this.getDimensions,r=yield n(e.floating);return{reference:OL(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}})};function RL(e){return Qn(e).direction==="rtl"}const PL={convertOffsetParentRelativeRectToViewportRelativeRect:xL,getDocumentElement:pr,getClippingRect:kL,getOffsetParent:fy,getElementRects:IL,getClientRects:wL,getDimensions:NL,getScale:zo,isElement:Kn,isRTL:RL};function hy(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function LL(e,t){let n=null,r;const o=pr(e);function a(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function u(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),a();const h=e.getBoundingClientRect(),{left:p,top:E,width:b,height:T}=h;if(c||t(),!b||!T)return;const x=sl(E),_=sl(o.clientWidth-(p+b)),S=sl(o.clientHeight-(E+T)),A=sl(p),I={rootMargin:-x+"px "+-_+"px "+-S+"px "+-A+"px",threshold:_n(0,Qr(1,d))||1};let z=!0;function Y(M){const Q=M[0].intersectionRatio;if(Q!==d){if(!z)return u();Q?u(!1,Q):r=setTimeout(()=>{u(!1,1e-7)},1e3)}Q===1&&!hy(h,e.getBoundingClientRect())&&u(),z=!1}try{n=new IntersectionObserver(Y,se(B({},I),{root:o.ownerDocument}))}catch(M){n=new IntersectionObserver(Y,I)}n.observe(e)}return u(!0),a}function DL(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=Wf(e),p=o||a?[...h?ua(h):[],...ua(t)]:[];p.forEach(A=>{o&&A.addEventListener("scroll",n,{passive:!0}),a&&A.addEventListener("resize",n)});const E=h&&c?LL(h,n):null;let b=-1,T=null;u&&(T=new ResizeObserver(A=>{let[O]=A;O&&O.target===h&&T&&(T.unobserve(t),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var I;(I=T)==null||I.observe(t)})),n()}),h&&!d&&T.observe(h),T.observe(t));let x,_=d?zi(e):null;d&&S();function S(){const A=zi(e);_&&!hy(_,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=T)==null||A.disconnect(),T=null,d&&cancelAnimationFrame(x)}}const ML=sL,FL=aL,BL=rL,UL=lL,HL=iL,zL=nL,jL=uL,$L=(e,t,n)=>{const r=new Map,o=B({platform:PL},n),a=se(B({},o.platform),{_c:r});return tL(e,t,se(B({},o),{platform:a}))};function py(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 se(B({},o),{toJSON:()=>o})}function VL(e){if(!e)return py();const{x:t,y:n,width:r,height:o}=e;return py(t,n,r,o)}function qL(e,t){return{contextElement:Mt(e)?e:void 0,getBoundingClientRect:()=>{const n=e,r=t==null?void 0:t(n);return r||!n?VL(r):n.getBoundingClientRect()}}}var la=e=>({variable:e,reference:`var(${e})`}),kr={arrowSize:la("--arrow-size"),arrowSizeHalf:la("--arrow-size-half"),arrowBg:la("--arrow-background"),transformOrigin:la("--transform-origin"),arrowOffset:la("--arrow-offset")},YL=e=>e==="top"||e==="bottom"?"y":"x";function WL(e,t){return{name:"transformOrigin",fn(n){var re,U,W,te,oe;const{elements:r,middlewareData:o,placement:a,rects:u,y:c}=n,d=a.split("-")[0],h=YL(d),p=((re=o.arrow)==null?void 0:re.x)||0,E=((U=o.arrow)==null?void 0:U.y)||0,b=(t==null?void 0:t.clientWidth)||0,T=(t==null?void 0:t.clientHeight)||0,x=p+b/2,_=E+T/2,S=Math.abs(((W=o.shift)==null?void 0:W.y)||0),A=u.reference.height/2,O=T/2,I=(oe=(te=e.offset)==null?void 0:te.mainAxis)!=null?oe:e.gutter,z=typeof I=="number"?I+O:I!=null?I:O,Y=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],Q=`${x}px ${u.reference.y+A-c}px`,Ee=!!e.overlap&&h==="y"&&Y;return r.floating.style.setProperty(kr.transformOrigin.variable,Ee?Q:M),{data:{transformOrigin:Ee?Q:M}}}}}var GL={name:"rects",fn({rects:e}){return{data:e}}},KL=e=>{if(e)return{name:"shiftArrow",fn({placement:t,middlewareData:n}){if(!n.arrow)return{};const{x:r,y:o}=n.arrow,a=t.split("-")[0];return Object.assign(e.style,{left:r!=null?`${r}px`:"",top:o!=null?`${o}px`:"",[a]:`calc(100% + ${kr.arrowOffset.reference})`}),{}}}};function QL(e){const[t,n]=e.split("-");return{side:t,align:n,hasAlign:n!=null}}var XL={strategy:"absolute",placement:"bottom",listeners:!0,gutter:8,flip:!0,slide:!0,overlap:!1,sameWidth:!1,fitViewport:!1,overflowPadding:8,arrowPadding:4};function my(e,t){const n=e.devicePixelRatio||1;return Math.round(t*n)/n}function Kf(e){return typeof e=="function"?e():e==="clipping-ancestors"?"clippingAncestors":e}function JL(e,t,n){const r=e||t.createElement("div");return zL({element:r,padding:n.arrowPadding})}function ZL(e,t){var n;if(!pR((n=t.offset)!=null?n:t.gutter))return ML(({placement:r})=>{var p,E,b,T;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}=QL(r),d=c?void 0:t.shift,h=(T=(b=t.offset)==null?void 0:b.crossAxis)!=null?T:d;return _f({crossAxis:h,mainAxis:u,alignmentAxis:t.shift})})}function e6(e){if(!e.flip)return;const t=Kf(e.boundary);return BL(se(B({},t?{boundary:t}:void 0),{padding:e.overflowPadding,fallbackPlacements:e.flip===!0?void 0:e.flip}))}function t6(e){if(!e.slide&&!e.overlap)return;const t=Kf(e.boundary);return FL(se(B({},t?{boundary:t}:void 0),{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:jL()}))}function n6(e){return UL({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 r6(e){var t;if(e.hideWhenDetached)return HL({strategy:"referenceHidden",boundary:(t=Kf(e.boundary))!=null?t:"clippingAncestors"})}function i6(e){return e?e===!0?{ancestorResize:!0,ancestorScroll:!0,elementResize:!0,layoutShift:!0}:e:{}}function o6(e,t,n={}){const r=qL(e,n.getAnchorRect);if(!t||!r)return;const o=Object.assign({},XL,n),a=t.querySelector("[data-part=arrow]"),u=[ZL(a,o),e6(o),t6(o),JL(a,t.ownerDocument,o),KL(a),WL({gutter:o.gutter,offset:o.offset,overlap:o.overlap},a),n6(o),r6(o),GL],{placement:c,strategy:d,onComplete:h,onPositioned:p}=o,E=()=>$e(null,null,function*(){var z;if(!r||!t)return;const _=yield $L(r,t,{placement:c,middleware:u,strategy:d});h==null||h(_),p==null||p({placed:!0});const S=Oo(t),A=my(S,_.x),O=my(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 I=t.firstElementChild;if(I){const Y=Ro(I);t.style.setProperty("--z-index",Y.zIndex)}}),b=()=>$e(null,null,function*(){n.updatePosition?(yield n.updatePosition({updatePosition:E,floatingElement:t}),p==null||p({placed:!0})):yield E()}),T=i6(o.listeners),x=o.listeners?DL(r,t,b,T):_R;return b(),()=>{x==null||x(),p==null||p({placed:!1})}}function gy(e,t,n={}){const c=n,{defer:r}=c,o=sn(c,["defer"]),a=r?Nt:d=>d(),u=[];return u.push(a(()=>{const d=typeof e=="function"?e():e,h=typeof t=="function"?t():t;u.push(o6(d,h,o))})),()=>{u.forEach(d=>d==null?void 0:d())}}var s6={bottom:"rotate(45deg)",left:"rotate(135deg)",top:"rotate(225deg)",right:"rotate(315deg)"};function a6(e={}){const{placement:t,sameWidth:n,fitViewport:r,strategy:o="absolute"}=e;return{arrow:{position:"absolute",width:kr.arrowSize.reference,height:kr.arrowSize.reference,[kr.arrowSizeHalf.variable]:`calc(${kr.arrowSize.reference} / 2)`,[kr.arrowOffset.variable]:`calc(${kr.arrowSizeHalf.reference} * -1)`},arrowTip:{transform:t?s6[t.split("-")[0]]:void 0,background:kr.arrowBg.reference,top:"0",left:"0",width:"100%",height:"100%",position:"absolute",zIndex:"inherit"},floating:{position:o,isolation:"isolate",minWidth:n?void 0:"max-content",width:n?"var(--reference-width)":void 0,maxWidth:r?"var(--available-width)":void 0,maxHeight:r?"var(--available-height)":void 0,pointerEvents:t?void 0:"none",top:"0px",left:"0px",transform:t?"translate3d(var(--x), var(--y), 0)":"translate3d(0, -100vh, 0)",zIndex:"var(--z-index)"}}}var jo=new WeakMap,hl=new WeakMap,pl={},Qf=0,Ey=e=>e&&(e.host||Ey(e.parentNode)),u6=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=Ey(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),l6=new Set(["script","output","status","next-route-announcer"]),c6=e=>l6.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=u6(n,Array.isArray(e)?e:[e]);pl[r]||(pl[r]=new WeakMap);const c=pl[r],d=[],h=new Set,p=new Set(u),E=T=>{!T||h.has(T)||(h.add(T),E(T.parentNode))};u.forEach(T=>{E(T),a&&Mt(T)&&OE(T,x=>{E(x)})});const b=T=>{!T||p.has(T)||Array.prototype.forEach.call(T.children,x=>{if(h.has(x))b(x);else try{if(c6(x))return;const S=x.getAttribute(o)==="true",A=(jo.get(x)||0)+1,O=(c.get(x)||0)+1;jo.set(x,A),c.set(x,O),d.push(x),A===1&&S&&hl.set(x,!0),O===1&&x.setAttribute(r,""),S||x.setAttribute(o,"true")}catch(_){console.error("[zag-js > ariaHidden] cannot operate on ",x,_)}})};return b(n),h.clear(),Qf++,()=>{d.forEach(T=>{const x=jo.get(T)-1,_=c.get(T)-1;jo.set(T,x),c.set(T,_),x||(hl.has(T)||T.removeAttribute(o),hl.delete(T)),_||T.removeAttribute(r)}),Qf--,Qf||(jo=new WeakMap,jo=new WeakMap,hl=new WeakMap,pl={})}},f6=e=>(Array.isArray(e)?e[0]:e).ownerDocument.body,h6=(e,t=f6(e),n="data-aria-hidden",r=!0)=>{if(t)return d6(e,{parentNode:t,markerName:n,controlAttribute:"aria-hidden",followControlledElements:r})},p6=e=>{const t=requestAnimationFrame(()=>e());return()=>cancelAnimationFrame(t)};function yy(e,t={}){const{defer:n=!0}=t,r=n?p6:a=>a(),o=[];return o.push(r(()=>{const u=(typeof e=="function"?e():e).filter(Boolean);u.length!==0&&o.push(h6(u))})),()=>{o.forEach(a=>a==null?void 0:a())}}function m6(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 g6(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 Ty="pointerdown.outside",by="focus.outside";function E6(e){for(const t of e)if(Mt(t)&&dr(t))return!0;return!1}var xy=e=>"clientY"in e;function y6(e,t){if(!xy(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 T6(e,t){return e.y<=t.y&&t.y<=e.y+e.height&&e.x<=t.x&&t.x<=e.x+e.width}function wy(e,t){if(!t||!xy(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 T6(u,c)?r||a:!1}function b6(e,t){const{exclude:n,onFocusOutside:r,onPointerDownOutside:o,onInteractOutside:a,defer:u,followControlledElements:c=!0}=t;if(!e)return;const d=cr(e),h=Oo(e),p=m6(h),E=g6(h);function b(I,z){if(!Mt(z)||!z.isConnected||No(e,z)||y6(e,I)||c&&NE(e,z))return!1;const Y=d.querySelector(`[aria-controls="${e.id}"]`);if(Y){const Q=Rf(Y);if(wy(I,Q))return!1}const M=Rf(e);return wy(I,M)?!1:!(n!=null&&n(z))}const T=new Set,x=Fi(e==null?void 0:e.getRootNode());function _(I){function z(Y){var re,U;const M=u&&!IE()?Nt:W=>W(),Q=Y!=null?Y:I,Ee=(U=(re=Q==null?void 0:Q.composedPath)==null?void 0:re.call(Q))!=null?U:[Q==null?void 0:Q.target];M(()=>{const W=x?Ee[0]:Gn(I);if(!(!e||!b(I,W))){if(o||a){const te=wf(o,a);e.addEventListener(Ty,te,{once:!0})}_y(e,Ty,{bubbles:!1,cancelable:!0,detail:{originalEvent:Q,contextmenu:iP(Q),focusable:E6(Ee),target:W}})}})}I.pointerType==="touch"?(T.forEach(Y=>Y()),T.add(Ft(d,"click",z,{once:!0})),T.add(E.addEventListener("click",z,{once:!0})),T.add(p.addEventListener("click",z,{once:!0}))):z()}const S=new Set,A=setTimeout(()=>{S.add(Ft(d,"pointerdown",_,!0)),S.add(E.addEventListener("pointerdown",_,!0)),S.add(p.addEventListener("pointerdown",_,!0))},0);function O(I){(u?Nt:Y=>Y())(()=>{var Q,Ee;const Y=(Ee=(Q=I==null?void 0:I.composedPath)==null?void 0:Q.call(I))!=null?Ee:[I==null?void 0:I.target],M=x?Y[0]:Gn(I);if(!(!e||!b(I,M))){if(r||a){const re=wf(r,a);e.addEventListener(by,re,{once:!0})}_y(e,by,{bubbles:!1,cancelable:!0,detail:{originalEvent:I,contextmenu:!1,focusable:dr(M),target:M}})}})}return IE()||(S.add(Ft(d,"focusin",O,!0)),S.add(E.addEventListener("focusin",O,!0)),S.add(p.addEventListener("focusin",O,!0))),()=>{clearTimeout(A),T.forEach(I=>I()),S.forEach(I=>I())}}function x6(e,t){const{defer:n}=t,r=n?Nt:a=>a(),o=[];return o.push(r(()=>{const a=typeof e=="function"?e():e;o.push(b6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}function _y(e,t,n){const r=e.ownerDocument.defaultView||window,o=new r.CustomEvent(t,n);return e.dispatchEvent(o)}function w6(e,t){const n=r=>{r.key==="Escape"&&(r.isComposing||t==null||t(r))};return Ft(cr(e),"keydown",n,{capture:!0})}var Sy="layer:request-dismiss",Dn={layers:[],branches:[],count(){return this.layers.length},pointerBlockingLayers(){return this.layers.filter(e=>e.pointerBlocking)},topMostPointerBlockingLayer(){return[...this.pointerBlockingLayers()].slice(-1)[0]},hasPointerBlockingLayer(){return this.pointerBlockingLayers().length>0},isBelowPointerBlockingLayer(e){var r;const t=this.indexOf(e),n=this.topMostPointerBlockingLayer()?this.indexOf((r=this.topMostPointerBlockingLayer())==null?void 0:r.node):-1;return t<n},isTopMost(e){const t=this.layers[this.count()-1];return(t==null?void 0:t.node)===e},getNestedLayers(e){return Array.from(this.layers).slice(this.indexOf(e)+1)},getLayersByType(e){return this.layers.filter(t=>t.type===e)},getNestedLayersByType(e,t){const n=this.indexOf(e);return n===-1?[]:this.layers.slice(n+1).filter(r=>r.type===t)},getParentLayerOfType(e,t){const n=this.indexOf(e);if(!(n<=0))return this.layers.slice(0,n).reverse().find(r=>r.type===t)},countNestedLayersOfType(e,t){return this.getNestedLayersByType(e,t).length},isInNestedLayer(e,t){return this.getNestedLayers(e).some(n=>No(n.node,t))},isInBranch(e){return Array.from(this.branches).some(t=>No(t,e))},add(e){this.layers.push(e),this.syncLayers()},addBranch(e){this.branches.push(e)},remove(e){const t=this.indexOf(e);t<0||(t<this.count()-1&&this.getNestedLayers(e).forEach(r=>Dn.dismiss(r.node,e)),this.layers.splice(t,1),this.syncLayers())},removeBranch(e){const t=this.branches.indexOf(e);t>=0&&this.branches.splice(t,1)},syncLayers(){this.layers.forEach((e,t)=>{e.node.style.setProperty("--layer-index",`${t}`),e.node.removeAttribute("data-nested"),e.node.removeAttribute("data-has-nested"),this.getParentLayerOfType(e.node,e.type)&&e.node.setAttribute("data-nested",e.type);const r=this.countNestedLayersOfType(e.node,e.type);r>0&&e.node.setAttribute("data-has-nested",e.type),e.node.style.setProperty("--nested-layer-count",`${r}`)})},indexOf(e){return this.layers.findIndex(t=>t.node===e)},dismiss(e,t){const n=this.indexOf(e);if(n===-1)return;const r=this.layers[n];S6(e,Sy,o=>{var a;(a=r.requestDismiss)==null||a.call(r,o),o.defaultPrevented||r==null||r.dismiss()}),_6(e,Sy,{originalLayer:e,targetLayer:t,originalIndex:n,targetIndex:t?this.indexOf(t):-1}),this.syncLayers()},clear(){this.remove(this.layers[0].node)}};function _6(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 S6(e,t,n){e.addEventListener(t,n,{once:!0})}var vy;function Ay(){Dn.layers.forEach(({node:e})=>{e.style.pointerEvents=Dn.isBelowPointerBlockingLayer(e)?"none":"auto"})}function v6(e){e.style.pointerEvents=""}function A6(e,t){const n=cr(e),r=[];return Dn.hasPointerBlockingLayer()&&!n.body.hasAttribute("data-inert")&&(vy=document.body.style.pointerEvents,queueMicrotask(()=>{n.body.style.pointerEvents="none",n.body.setAttribute("data-inert","")})),t==null||t.forEach(o=>{const[a,u]=CP(()=>{const c=o();return Mt(c)?c:null},{timeout:1e3});a.then(c=>r.push(el(c,{pointerEvents:"auto"}))),r.push(u)}),()=>{Dn.hasPointerBlockingLayer()||(queueMicrotask(()=>{n.body.style.pointerEvents=vy,n.body.removeAttribute("data-inert"),n.body.style.length===0&&n.body.removeAttribute("style")}),r.forEach(o=>o()))}}function C6(e,t){const{warnOnMissingNode:n=!0}=t;if(n&&!e){Sf("[@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),Ay();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 b(_){var S;Dn.isTopMost(e)&&((S=t.onEscapeKeyDown)==null||S.call(t,_),!_.defaultPrevented&&r&&(_.preventDefault(),r()))}function T(_){var I;if(!e)return!1;const S=typeof u=="function"?u():u,A=Array.isArray(S)?S:[S],O=(I=t.persistentElements)==null?void 0:I.map(z=>z()).filter(Mt);return O&&A.push(...O),A.some(z=>No(z,_))||Dn.isInNestedLayer(e,_)}const x=[a?A6(e,t.persistentElements):void 0,w6(e,b),x6(e,{exclude:T,onFocusOutside:E,onPointerDownOutside:p,defer:t.defer})];return()=>{Dn.remove(e),Ay(),v6(e),x.forEach(_=>_==null?void 0:_())}}function Cy(e,t){const{defer:n}=t,r=n?Nt:a=>a(),o=[];return o.push(r(()=>{const a=Co(e)?e():e;o.push(C6(a,t))})),()=>{o.forEach(a=>a==null?void 0:a())}}var k6=Object.defineProperty,N6=(e,t,n)=>t in e?k6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ht=(e,t,n)=>N6(e,typeof t!="symbol"?t+"":t,n),ky={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()}},O6=[],I6=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||Qu(o))a&&(this.state.mostRecentlyFocusedNode=o);else{r.stopImmediatePropagation();let u,c=!0;if(this.state.mostRecentlyFocusedNode)if(ra(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=>ra(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(da(this.config.clickOutsideDeactivates,r)){this.deactivate({returnFocus:this.config.returnFocusOnDeactivate});return}da(this.config.allowOutsideClick,r)||r.preventDefault()}}),ht(this,"handleClick",r=>{const o=Gn(r);this.findContainerIndex(o,r)>=0||da(this.config.clickOutsideDeactivates,r)||da(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;ca(r)&&r.preventDefault(),this.tryFocus(a)}}),ht(this,"handleEscapeKey",r=>{R6(r)&&da(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 KR(h)?!0:h.id&&!this.state.containers.some(p=>p.contains(h))?QR(h):!1}):!1)&&this.state.active&&!this.state.paused&&(this.updateTabbableNodes(),this.updatePortalContainers())})}),ht(this,"updateObservedNodes",()=>{var r;(r=this._mutationObserver)==null||r.disconnect(),this.state.active&&!this.state.paused&&(this.state.containers.map(o=>{var a;(a=this._mutationObserver)==null||a.observe(o,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}),this.portalContainers.forEach(o=>{this.observePortalContainer(o)}))}),ht(this,"getInitialFocusNode",()=>{let r=this.getNodeForOption("initialFocus",{hasFallback:!0});if(r===!1)return!1;if(r===void 0||r&&!dr(r)){const o=Io(this.doc);if(o&&this.findContainerIndex(o)>=0)r=o;else{const a=this.state.tabbableGroups[0];r=a&&a.firstTabbableNode||this.getNodeForOption("fallbackFocus")}}else r===null&&(r=this.getNodeForOption("fallbackFocus"));if(!r)throw new Error("Your focus-trap needs to have at least one focusable element");return r.isConnected||(r=this.getNodeForOption("fallbackFocus")),r}),ht(this,"tryFocus",r=>{if(r!==!1&&r!==Io(this.doc)){if(!r||!r.focus){this.tryFocus(this.getInitialFocusNode());return}r.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=r,P6(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(),ky.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=()=>{Ny(()=>{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||dr(u)&&!Bi(u)&&!(h!=null&&h.nextTabbableNode(u,!1)))&&(p=d),p>=0){const E=p===0?this.state.tabbableGroups.length-1:p-1,b=this.state.tabbableGroups[E];c=ra(u)>=0?b.lastTabbableNode:b.lastDomTabbableNode}else ca(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||dr(u)&&!Bi(u)&&!(h!=null&&h.nextTabbableNode(u)))&&(p=d),p>=0){const E=p===this.state.tabbableGroups.length-1?0:p+1,b=this.state.tabbableGroups[E];c=ra(u)>=0?b.firstTabbableNode:b.firstDomTabbableNode}else ca(o)||(c=h==null?void 0:h.nextTabbableNode(u))}}else c=this.getNodeForOption("fallbackFocus");return c}),this.trapStack=t.trapStack||O6;const n=B({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,followControlledElements:!0,isKeyForward(r){return ca(r)&&!r.shiftKey},isKeyBackward(r){return ca(r)&&r.shiftKey}},t);this.doc=n.document||cr(Array.isArray(e)?e[0]:e),this.config=n,this.updateContainerElements(e),this.setupMutationObserver()}addPortalContainer(e){const t=e.parentElement;t&&!this.portalContainers.has(t)&&(this.portalContainers.add(t),this.state.active&&!this.state.paused&&this.observePortalContainer(t))}observePortalContainer(e){var t;(t=this._mutationObserver)==null||t.observe(e,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["aria-controls","aria-expanded"]})}updatePortalContainers(){this.config.followControlledElements&&this.state.containers.forEach(e=>{YR(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?NE(e,t):!1}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map(e=>{const t=Po(e,{getShadowRoot:this.config.getShadowRoot}),n=BE(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(ra(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 b=n.indexOf(h);if(!(b<0)){if(p){for(let T=b+1;T<n.length;T++)if(Bi(n[T]))return n[T]}else for(let T=b-1;T>=0;T--)if(Bi(n[T]))return n[T]}}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 ky.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Ny(()=>{this.tryFocus(this.getInitialFocusNode())}):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(Ft(this.doc,"focusin",this.handleFocus,!0),Ft(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),Ft(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),Ft(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),Ft(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),Ft(this.doc,"keydown",this.handleEscapeKey)),this}removeListeners(){if(this.state.active)return this.listenerCleanups.forEach(e=>e()),this.listenerCleanups=[],this}activate(e){if(this.state.active)return this;const t=this.getOption(e,"onActivate"),n=this.getOption(e,"onPostActivate"),r=this.getOption(e,"checkCanFocusTrap");r||this.updateTabbableNodes(),this.state.active=!0,this.state.paused=!1,this.state.nodeFocusedBeforeActivation=Io(this.doc),t==null||t();const o=()=>{r&&this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),n==null||n()};return r?(r(this.state.containers.concat()).then(o,o),this):(o(),this)}},ca=e=>e.key==="Tab",da=(e,...t)=>typeof e=="function"?e(...t):e,R6=e=>!e.isComposing&&e.key==="Escape",Ny=e=>setTimeout(e,0),P6=e=>e.localName==="input"&&"select"in e&&typeof e.select=="function";function Oy(e,t={}){let n;const r=Nt(()=>{const o=typeof e=="function"?e():e;if(o){n=new I6(o,se(B({escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:o},t),{document:cr(o)}));try{n.activate()}catch(a){}}});return function(){n==null||n.deactivate(),r()}}var Xf="data-scroll-lock";function L6(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}function Iy(e){const t=Ro(e),n=t==null?void 0:t.scrollbarGutter;return n==="stable"||(n==null?void 0:n.startsWith("stable "))===!0}function Ry(e){var T;const t=e!=null?e:document,n=(T=t.defaultView)!=null?T:window,{documentElement:r,body:o}=t;if(o.hasAttribute(Xf))return;const u=Iy(r)||Iy(o),c=n.innerWidth-r.clientWidth;o.setAttribute(Xf,"");const d=()=>vP(r,"--scrollbar-width",`${c}px`),h=L6(r),p=()=>{const x={overflow:"hidden"};return!u&&c>0&&(x[h]=`${c}px`),el(o,x)},E=()=>{var Y,M;const{scrollX:x,scrollY:_,visualViewport:S}=n,A=(Y=S==null?void 0:S.offsetLeft)!=null?Y:0,O=(M=S==null?void 0:S.offsetTop)!=null?M:0,I={position:"fixed",overflow:"hidden",top:`${-(_-Math.floor(O))}px`,left:`${-(x-Math.floor(A))}px`,right:"0"};!u&&c>0&&(I[h]=`${c}px`);const z=el(o,I);return()=>{z==null||z(),n.scrollTo({left:x,top:_,behavior:"instant"})}},b=[d(),Xu()?E():p()];return()=>{b.forEach(x=>x==null?void 0:x()),o.removeAttribute(Xf)}}var D6=Hi("popover").parts("arrow","arrowTip","anchor","trigger","indicator","positioner","content","title","description","closeTrigger"),gr=D6.build(),Py=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.anchor)!=null?n:`popover:${e.id}:anchor`},Ly=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`popover:${e.id}:trigger`},Jf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`popover:${e.id}:content`},Dy=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`popover:${e.id}:popper`},M6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.arrow)!=null?n:`popover:${e.id}:arrow`},Zf=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`popover:${e.id}:title`},eh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`popover:${e.id}:desc`},F6=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`popover:${e.id}:close`},My=e=>e.getById(Py(e)),$o=e=>e.getById(Ly(e)),Vo=e=>e.getById(Jf(e)),Fy=e=>e.getById(Dy(e)),B6=e=>e.getById(Zf(e)),U6=e=>e.getById(eh(e));function H6(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"),b=a6(se(B({},u("positioning")),{placement:h}));return{portalled:p,open:d,setOpen(T){n.matches("open")!==T&&o({type:T?"OPEN":"CLOSE"})},reposition(T={}){o({type:"POSITIONING.SET",options:T})},getArrowProps(){return t.element(se(B({id:M6(c)},gr.arrow.attrs),{dir:u("dir"),style:b.arrow}))},getArrowTipProps(){return t.element(se(B({},gr.arrowTip.attrs),{dir:u("dir"),style:b.arrowTip}))},getAnchorProps(){return t.element(se(B({},gr.anchor.attrs),{dir:u("dir"),id:Py(c)}))},getTriggerProps(){return t.button(se(B({},gr.trigger.attrs),{dir:u("dir"),type:"button","data-placement":h,id:Ly(c),"aria-haspopup":"dialog","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":Jf(c),onPointerDown(T){RE(T)&&nP()&&T.currentTarget.focus()},onClick(T){T.defaultPrevented||o({type:"TOGGLE"})},onBlur(T){o({type:"TRIGGER_BLUR",target:T.relatedTarget})}}))},getIndicatorProps(){return t.element(se(B({},gr.indicator.attrs),{dir:u("dir"),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(se(B({id:Dy(c)},gr.positioner.attrs),{dir:u("dir"),style:b.floating}))},getContentProps(){return t.element(se(B({},gr.content.attrs),{dir:u("dir"),id:Jf(c),tabIndex:-1,role:"dialog","aria-modal":AE(u("modal")),hidden:!d,"data-state":d?"open":"closed","data-expanded":ko(d),"aria-labelledby":E.title?Zf(c):void 0,"aria-describedby":E.description?eh(c):void 0,"data-placement":h}))},getTitleProps(){return t.element(se(B({},gr.title.attrs),{id:Zf(c),dir:u("dir")}))},getDescriptionProps(){return t.element(se(B({},gr.description.attrs),{id:eh(c),dir:u("dir")}))},getCloseTriggerProps(){return t.button(se(B({},gr.closeTrigger.attrs),{dir:u("dir"),id:F6(c),type:"button","aria-label":"close",onClick(T){T.defaultPrevented||(T.stopPropagation(),o({type:"CLOSE"}))}}))}}}var z6={props({props:e}){return se(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=My(n))!=null?a:$o(n);return gy(r,()=>Fy(n),se(B({},t("positioning")),{defer:!0,onComplete(u){e.set("currentPlacement",u.placement)}}))},trackDismissableElement({send:e,prop:t,scope:n}){const r=()=>Vo(n);let o=!0;return Cy(r,{type:"popover",pointerBlocking:t("modal"),exclude:$o(n),defer:!0,onEscapeKeyDown(a){var u;(u=t("onEscapeKeyDown"))==null||u(a),!t("closeOnEscape")&&a.preventDefault()},onInteractOutside(a){var u;(u=t("onInteractOutside"))==null||u(a),!a.defaultPrevented&&(o=!(a.detail.focusable||a.detail.contextmenu),t("closeOnInteractOutside")||a.preventDefault())},onPointerDownOutside:t("onPointerDownOutside"),onFocusOutside:t("onFocusOutside"),persistentElements:t("persistentElements"),onRequestDismiss:t("onRequestDismiss"),onDismiss(){e({type:"CLOSE",src:"interact-outside",restoreFocus:o})}})},proxyTabFocus({prop:e,scope:t}){return e("modal")||!e("portalled")?void 0:_P(()=>Vo(t),{triggerElement:$o(t),defer:!0,getShadowRoot:!0,onFocus(r){r.focus({preventScroll:!0})}})},hideContentBelow({prop:e,scope:t}){return e("modal")?yy(()=>[Vo(t),$o(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("modal"))return Ry(t.getDoc())},trapFocus({prop:e,scope:t}){return e("modal")?Oy(()=>Vo(t),{initialFocus:()=>UE({root:Vo(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")}),getShadowRoot:!0}):void 0}},actions:{reposition({event:e,prop:t,scope:n,context:r}){var u;const o=(u=My(n))!=null?u:$o(n);gy(o,()=>Fy(n),se(B(B({},t("positioning")),e.options),{defer:!0,listeners:!1,onComplete(c){r.set("currentPlacement",c.placement)}}))},checkRenderedElements({context:e,scope:t}){Nt(()=>{Object.assign(e.get("renderedElements"),{title:!!B6(t),description:!!U6(t)})})},setInitialFocus({prop:e,scope:t}){e("modal")||Nt(()=>{const n=UE({root:Vo(t),getInitialEl:e("initialFocusEl"),enabled:e("autoFocus")});n==null||n.focus({preventScroll:!0})})},setFinalFocus({event:e,scope:t}){var r,o;const n=(o=e.restoreFocus)!=null?o:(r=e.previousEvent)==null?void 0:r.restoreFocus;n!=null&&!n||Nt(()=>{const a=$o(t);a==null||a.focus({preventScroll:!0})})},invokeOnOpen({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!0})})},invokeOnClose({prop:e,flush:t}){t(()=>{var n;(n=e("onOpenChange"))==null||n({open:!1})})},toggleVisibility({event:e,send:t,prop:n}){t({type:n("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:e})}}}};Mo()(["autoFocus","closeOnEscape","closeOnInteractOutside","dir","getRootNode","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","portalled","positioning"]);const[WF,ml]=Ui({name:"EnvironmentContext",hookName:"useEnvironmentContext",providerName:"<EnvironmentProvider />",strict:!1,defaultValue:{getRootNode:()=>document,getDocument:()=>document,getWindow:()=>window}}),[GF,th]=Ui({name:"LocaleContext",hookName:"useLocaleContext",providerName:"<LocaleProvider />",strict:!1,defaultValue:{dir:"ltr",locale:"en-US"}}),j6=e=>{const t=X.useId(),{getRootNode:n}=ml(),{dir:r}=th(),o=B({id:t,dir:r,getRootNode:n},e),a=nl(z6,o);return H6(a,Df)},$6=e=>{const[t,u]=GE(e),c=u,{children:n}=c,r=sn(c,["children"]),o=j6(r),a=Bf(Ot({present:o.open},t));return P.jsx(BP,{value:o,children:P.jsx(qE,{value:a,children:n})})},By=X.forwardRef((e,t)=>{const n=Ff(),r=ia(),o=Ot(se(B({},n.getTriggerProps()),{"aria-controls":r.unmounted?void 0:n.getTriggerProps()["aria-controls"]}),e);return P.jsx(Kt.button,se(B({},o),{ref:t}))});By.displayName="PopoverTrigger";function V6(e){return tn({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 q6(e){return tn({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 Y6(e){return tn({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 W6(e){return tn({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 Uy(e){return tn({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 G6=({className:e,componentType:t,children:n})=>{const[r,o]=X.useState(!1),{globalClassName:a}=kt(),u=h=>{o(h.open)},c=X.useCallback(()=>{o(!1)},[]),d=X.useMemo(()=>({closeMenu:c}),[c]);return P.jsxs($6,{open:r,onOpenChange:u,positioning:{placement:"bottom-end"},children:[P.jsx(By,{"aria-label":`Overflow menu for ${t}`,className:ae(`${ee}-overflow-menu-button-trigger`,`${ee}-icon-button`,a,e,`cim-${t}-component`),children:P.jsx(Uy,{})}),P.jsx(WE,{children:P.jsx(YE,{className:ae(`${ee}-overflow-menu-list`,a,`cim-${t}-component`),children:P.jsx(TE.Provider,{value:d,children:n})})})]})};function Hy(e){return tn({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 zy(e){return tn({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[K6,ji]=Ui({name:"CarouselContext",hookName:"useCarouselContext",providerName:"<CarouselProvider />"}),jy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getControlProps(),e);return P.jsx(Kt.div,se(B(B({},r),e),{ref:t}))});jy.displayName="CarouselControl";const $y=X.forwardRef((e,t)=>{const[n,r]=oa()(e,["readOnly","index"]),o=ji(),a=Ot(o.getIndicatorProps(n),r);return P.jsx(Kt.button,se(B({},a),{ref:t}))});$y.displayName="CarouselIndicator";const Vy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getIndicatorGroupProps(),e);return P.jsx(Kt.div,se(B({},r),{ref:t}))});Vy.displayName="CarouselIndicatorGroup";const qy=X.forwardRef((e,t)=>{const[n,r]=oa()(e,["index","snapAlign"]),o=ji(),a=Ot(o.getItemProps(n),r);return P.jsx(Kt.div,se(B({},a),{ref:t}))});qy.displayName="CarouselItem";const Yy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getItemGroupProps(),e);return P.jsx(Kt.div,se(B({},r),{ref:t}))});Yy.displayName="CarouselItemGroup";const Wy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getNextTriggerProps(),e);return P.jsx(Kt.button,se(B({},r),{ref:t}))});Wy.displayName="CarouselNextTrigger";const Gy=X.forwardRef((e,t)=>{const n=ji(),r=Ot(n.getPrevTriggerProps(),e);return P.jsx(Kt.button,se(B({},r),{ref:t}))});Gy.displayName="CarouselPrevTrigger";function Q6(e){const t=Ro(e),n=e.getBoundingClientRect();let r=t.getPropertyValue("scroll-padding-left").replace("auto","0px"),o=t.getPropertyValue("scroll-padding-top").replace("auto","0px"),a=t.getPropertyValue("scroll-padding-right").replace("auto","0px"),u=t.getPropertyValue("scroll-padding-bottom").replace("auto","0px");function c(b,T){let x=parseFloat(b);return/%/.test(b)&&(x/=100,x*=T),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 X6(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 Ky(e){let t=[];for(const n of e.children)t=t.concat(n,Ky(n));return t}function Qy(e,t=!1){const n=e.getBoundingClientRect(),r={x:{start:[],center:[],end:[]},y:{start:[],center:[],end:[]}},o=t?Ky(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(!X6(n,E,u))continue;const b=Ro(p);let[T,x]=b.getPropertyValue("scroll-snap-align").split(" ");typeof x=="undefined"&&(x=T);const _=a==="x"?x:T,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 Xy(e){const t=e.getBoundingClientRect(),n=Q6(e),r=Qy(e),o={x:e.scrollWidth-e.offsetWidth,y:e.scrollHeight-e.offsetHeight};return{x:Jy([...r.x.start.map(a=>a.position-n.x.before),...r.x.center.map(a=>a.position-t.width/2),...r.x.end.map(a=>a.position-t.width+n.x.after)].map(Zy(0,o.x))),y:Jy([...r.y.start.map(a=>a.position-n.y.before),...r.y.center.map(a=>a.position-t.height/2),...r.y.end.map(a=>a.position-t.height+n.y.after)].map(Zy(0,o.y)))}}function J6(e,t,n){const r=Qy(e),o=[...r[t].start,...r[t].center,...r[t].end];for(const a of o)if(n(a.node))return a.position}var Jy=e=>[...new Set(e)],Zy=(e,t)=>n=>Math.max(e,Math.min(t,n)),Z6=Hi("carousel").parts("root","itemGroup","item","control","nextTrigger","prevTrigger","indicatorGroup","indicator","autoplayTrigger"),Nr=Z6.build(),e4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.root)!=null?n:`carousel:${e.id}`},t4=(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}`},gl=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.itemGroup)!=null?n:`carousel:${e.id}:item-group`},n4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.nextTrigger)!=null?n:`carousel:${e.id}:next-trigger`},r4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.prevTrigger)!=null?n:`carousel:${e.id}:prev-trigger`},i4=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.indicatorGroup)!=null?n:`carousel:${e.id}:indicator-group`},eT=(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(gl(e)),tT=e=>SP(hn(e),"[data-part=item]"),o4=(e,t)=>e.getById(eT(e,t)),nT=e=>{const t=hn(e);if(!t)return;const n=Po(t);t.setAttribute("tabindex",n.length>0?"-1":"0")};function s4(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"),b=o("isHorizontal"),T=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:T,canScrollNext:p,canScrollPrev:E,getProgress(){return x/T.length},scrollToIndex(O,I){a({type:"INDEX.SET",index:O,instant:I})},scrollTo(O,I){a({type:"PAGE.SET",index:O,instant:I})},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(se(B({},Nr.root.attrs),{id:e4(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(se(B({},Nr.itemGroup.attrs),{id:gl(u),"data-orientation":c("orientation"),"data-dragging":ko(h),dir:c("dir"),"aria-live":d?"off":"polite",onFocus(O){No(O.currentTarget,Gn(O))&&a({type:"VIEWPORT.FOCUS"})},onBlur(O){No(O.currentTarget,O.relatedTarget)||a({type:"VIEWPORT.BLUR"})},onMouseDown(O){if(O.defaultPrevented||!c("allowMouseDrag")||!RE(O))return;const I=Gn(O);dr(I)&&I!==O.currentTarget||(O.preventDefault(),a({type:"DRAGGING.START"}))},onWheel:SR(O=>{const I=c("orientation")==="horizontal"?"deltaX":"deltaY";O[I]<0&&!o("canScrollPrev")||O[I]>0&&!o("canScrollNext")||a({type:"USER.SCROLL"})},150),onTouchStart(){a({type:"USER.SCROLL"})},style:{display:"grid",gap:"var(--slide-spacing)",scrollSnapType:[b?"x":"y",c("snapType")].join(" "),gridAutoFlow:b?"column":"row",scrollbarWidth:"none",overscrollBehaviorX:"contain",[b?"gridAutoColumns":"gridAutoRows"]:"var(--slide-item-size)",[b?"scrollPaddingInline":"scrollPaddingBlock"]:S,[b?"paddingInline":"paddingBlock"]:S,[b?"overflowX":"overflowY"]:"auto"}}))},getItemProps(O){const I=r.get("slidesInView").includes(O.index);return t.element(se(B({},Nr.item.attrs),{id:t4(u,O.index),dir:c("dir"),role:"group","data-index":O.index,"data-inview":ko(I),"aria-roledescription":"slide","data-orientation":c("orientation"),"aria-label":A.item(O.index,c("slideCount")),"aria-hidden":AE(!I),style:{scrollSnapAlign:(()=>{var Ee;const z=(Ee=O.snapAlign)!=null?Ee:"start",Y=c("slidesPerMove"),M=Y==="auto"?Math.floor(c("slidesPerPage")):Y;return(O.index+M)%M===0?z:void 0})()}}))},getControlProps(){return t.element(se(B({},Nr.control.attrs),{"data-orientation":c("orientation")}))},getPrevTriggerProps(){return t.button(se(B({},Nr.prevTrigger.attrs),{id:r4(u),type:"button",disabled:!E,dir:c("dir"),"aria-label":A.prevTrigger,"data-orientation":c("orientation"),"aria-controls":gl(u),onClick(O){O.defaultPrevented||a({type:"PAGE.PREV",src:"trigger"})}}))},getNextTriggerProps(){return t.button(se(B({},Nr.nextTrigger.attrs),{dir:c("dir"),id:n4(u),type:"button","aria-label":A.nextTrigger,"data-orientation":c("orientation"),"aria-controls":gl(u),disabled:!p,onClick(O){O.defaultPrevented||a({type:"PAGE.NEXT",src:"trigger"})}}))},getIndicatorGroupProps(){return t.element(se(B({},Nr.indicatorGroup.attrs),{dir:c("dir"),id:i4(u),"data-orientation":c("orientation"),onKeyDown(O){if(O.defaultPrevented)return;const I="indicator",z={ArrowDown(Q){b||(a({type:"PAGE.NEXT",src:I}),Q.preventDefault())},ArrowUp(Q){b||(a({type:"PAGE.PREV",src:I}),Q.preventDefault())},ArrowRight(Q){b&&(a({type:"PAGE.NEXT",src:I}),Q.preventDefault())},ArrowLeft(Q){b&&(a({type:"PAGE.PREV",src:I}),Q.preventDefault())},Home(Q){a({type:"PAGE.SET",index:0,src:I}),Q.preventDefault()},End(Q){a({type:"PAGE.SET",index:T.length-1,src:I}),Q.preventDefault()}},Y=aP(O,{dir:c("dir"),orientation:c("orientation")}),M=z[Y];M==null||M(O)}}))},getIndicatorProps(O){return t.button(se(B({},Nr.indicator.attrs),{dir:c("dir"),id:eT(u,O.index),type:"button","data-orientation":c("orientation"),"data-index":O.index,"data-readonly":ko(O.readOnly),"data-current":ko(O.index===x),"aria-label":A.indicator(O.index),onClick(I){I.defaultPrevented||O.readOnly||a({type:"PAGE.SET",index:O.index,src:"indicator"})}}))},getAutoplayTriggerProps(){return t.button(se(B({},Nr.autoplayTrigger.attrs),{type:"button","data-orientation":c("orientation"),"data-pressed":ko(d),"aria-label":d?A.autoplayStop:A.autoplayStart,onClick(O){O.defaultPrevented||a({type:d?"AUTOPLAY.PAUSE":"AUTOPLAY.START"})}}))}}}var a4={props({props:e}){return OR(e,["slideCount"],"carousel"),se(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:u4(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 hR(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"}),nT(e)});return nT(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"})};Nt(()=>{o(),Nt(()=>{t({type:"PAGE.SCROLL",instant:!0})})});const a=new r.ResizeObserver(o);return tT(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 b;const p=h.target,E=Number((b=p.dataset.index)!=null?b:"-1");return E==null||Number.isNaN(E)||E===-1?d:h.isIntersecting?uR(d,E):lR(d,E)},n.get("slidesInView"));n.set("slidesInView",cR(c))},{root:r,threshold:t("inViewThreshold")});return tT(e).forEach(u=>a.observe(u)),()=>a.disconnect()},trackScroll({send:e,refs:t,scope:n}){const r=hn(n);return r?Ft(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 Ft(n,"visibilitychange",()=>{n.visibilityState!=="visible"&&t({type:"AUTOPLAY.PAUSE",src:"doc.hidden"})})},trackPointerMove({scope:e,send:t}){const n=e.getDoc();return xP(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 Ft(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=SE((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=xE(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=J6(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=SE(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=Xy(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=Xy(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]);Nt(()=>{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=o4(n,e.get("page"));r&&Nt(()=>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 u4(e,t,n){if(e==null||n<=0)return[];const r=[],o=t==="auto"?Math.floor(n):t;if(o<=0)return[];for(let a=0;a<e&&!(a+n>e);a+=o)r.push(a);return r}Mo()(["dir","getRootNode","id","ids","loop","page","defaultPage","onPageChange","orientation","slideCount","slidesPerPage","slidesPerMove","spacing","padding","autoplay","allowMouseDrag","inViewThreshold","translations","snapType","onDragStatusChange","onAutoplayStatusChange"]),Mo()(["index","readOnly"]),Mo()(["index","snapAlign"]);const l4=e=>{const t=X.useId(),{getRootNode:n}=ml(),{dir:r}=th(),o=B({id:t,dir:r,getRootNode:n},e),a=nl(a4,o);return s4(a,Df)},rT=X.forwardRef((e,t)=>{const[n,r]=oa()(e,["allowMouseDrag","autoplay","defaultPage","id","ids","inViewThreshold","loop","onAutoplayStatusChange","onDragStatusChange","onPageChange","orientation","padding","page","slideCount","slidesPerMove","slidesPerPage","snapType","spacing","translations"]),o=l4(n),a=Ot(o.getRootProps(),r);return P.jsx(K6,{value:o,children:P.jsx(Kt.div,se(B({},a),{ref:t}))})});rT.displayName="CarouselRoot";const c4=180,d4=e=>{const t=e.trim(),n=parseFloat(t);return Number.isNaN(n)?0:t.endsWith("rem")?n*16:n},f4=({globalClassName:e,className:t,itemMinWidth:n=c4,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),b=E.length,T=X.useRef(null),[x,_]=X.useState(0),{width:S}=ev();X.useLayoutEffect(()=>{T.current&&_(T.current.getBoundingClientRect().width)},[S,b]);const A=d4(r),O=n+A,I=x>0?(x+A)/O:1,z=Math.max(1,Math.floor(I));if(b===0)return null;const Y=b>z,M=Math.ceil(b/z),Q=Y?Math.max(1,I):z;return P.jsxs(rT,{ref:T,className:ae(e,t,`${ee}-carousel`),slidesPerPage:Q,slidesPerMove:z,spacing:r,loop:o,allowMouseDrag:a,slideCount:b,onPageChange:d,"aria-label":h,children:[P.jsx(Yy,{className:ae(e,`${ee}-carousel__item-group`,{"carousel-row-container":!Y}),children:E.map((Ee,re)=>P.jsx(qy,{index:re,className:ae(e,`${ee}-carousel__item`),children:Ee},re))}),c&&Y&&P.jsxs(jy,{className:ae(e,`${ee}-carousel__control`),children:[P.jsx(Gy,{className:ae(e,`${ee}-carousel__prev-trigger`),"aria-label":"Previous slide",children:P.jsx(Y6,{})}),P.jsx(Wy,{className:ae(e,`${ee}-carousel__next-trigger`),"aria-label":"Next slide",children:P.jsx(W6,{})})]}),u&&Y&&P.jsx(Vy,{className:ae(e,`${ee}-carousel__indicator-group`),children:Array.from({length:M},(Ee,re)=>P.jsx($y,{index:re,className:ae(e,`${ee}-carousel__indicator`),"aria-label":`Go to slide group ${re+1}`},re))})]})},h4=({className:e,label:t="Close",onClick:n,disabled:r=!1})=>P.jsx("button",{"aria-label":t,title:t,className:ae(e,`${ee}-close-button`),disabled:r,onClick:n,children:P.jsx("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20",width:"16",height:"16",fill:"currentColor",children:P.jsx("path",{d:"M18.3 5.7a1 1 0 0 0-1.4-1.4L12 9.6 7.1 4.7a1 1 0 1 0-1.4 1.4l4.9 4.9-4.9 4.9a1 1 0 1 0 1.4 1.4l4.9-4.9 4.9 4.9a1 1 0 0 0 1.4-1.4l-4.9-4.9 4.9-4.9z"})})}),[p4,m4]=Ui({name:"RenderStrategyContext",hookName:"useRenderStrategyContext",providerName:"<RenderStrategyPropsProvider />"}),g4=e=>oa()(e,["lazyMount","unmountOnExit"]),[E4,fa]=Ui({name:"DialogContext",hookName:"useDialogContext",providerName:"<DialogProvider />"}),iT=X.forwardRef((e,t)=>{const n=fa(),r=m4(),o=Bf(se(B({},r),{present:n.open})),a=Ot(n.getBackdropProps(),o.getPresenceProps(),e);return o.unmounted?null:P.jsx(Kt.div,se(B({},a),{ref:rl(o.ref,t)}))});iT.displayName="DialogBackdrop";const nh=X.forwardRef((e,t)=>{const n=fa(),r=ia(),o=Ot(n.getContentProps(),r.getPresenceProps(),e);return r.unmounted?null:P.jsx(Kt.div,se(B({},o),{ref:rl(r.ref,t)}))});nh.displayName="DialogContent";const rh=X.forwardRef((e,t)=>{const n=fa(),r=Ot(n.getDescriptionProps(),e);return P.jsx(Kt.div,se(B({},r),{ref:t}))});rh.displayName="DialogDescription";const ih=X.forwardRef((e,t)=>{const n=fa(),r=Ot(n.getPositionerProps(),e);return ia().unmounted?null:P.jsx(Kt.div,se(B({},r),{ref:t}))});ih.displayName="DialogPositioner";var y4=Hi("dialog").parts("trigger","backdrop","positioner","content","title","description","closeTrigger"),$i=y4.build(),oT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.positioner)!=null?n:`dialog:${e.id}:positioner`},sT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.backdrop)!=null?n:`dialog:${e.id}:backdrop`},oh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.content)!=null?n:`dialog:${e.id}:content`},aT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.trigger)!=null?n:`dialog:${e.id}:trigger`},sh=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.title)!=null?n:`dialog:${e.id}:title`},ah=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.description)!=null?n:`dialog:${e.id}:description`},uT=e=>{var t,n;return(n=(t=e.ids)==null?void 0:t.closeTrigger)!=null?n:`dialog:${e.id}:close`},El=e=>e.getById(oh(e)),T4=e=>e.getById(oT(e)),b4=e=>e.getById(sT(e)),x4=e=>e.getById(aT(e)),w4=e=>e.getById(sh(e)),_4=e=>e.getById(ah(e)),S4=e=>e.getById(uT(e));function v4(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(se(B({},$i.trigger.attrs),{dir:a("dir"),id:aT(u),"aria-haspopup":"dialog",type:"button","aria-expanded":d,"data-state":d?"open":"closed","aria-controls":oh(u),onClick(h){h.defaultPrevented||r({type:"TOGGLE"})}}))},getBackdropProps(){return t.element(se(B({},$i.backdrop.attrs),{dir:a("dir"),hidden:!d,id:sT(u),"data-state":d?"open":"closed"}))},getPositionerProps(){return t.element(se(B({},$i.positioner.attrs),{dir:a("dir"),id:oT(u),style:{pointerEvents:d?void 0:"none"}}))},getContentProps(){const h=o.get("rendered");return t.element(se(B({},$i.content.attrs),{dir:a("dir"),role:a("role"),hidden:!d,id:oh(u),tabIndex:-1,"data-state":d?"open":"closed","aria-modal":!0,"aria-label":c||void 0,"aria-labelledby":c||!h.title?void 0:sh(u),"aria-describedby":h.description?ah(u):void 0}))},getTitleProps(){return t.element(se(B({},$i.title.attrs),{dir:a("dir"),id:sh(u)}))},getDescriptionProps(){return t.element(se(B({},$i.description.attrs),{dir:a("dir"),id:ah(u)}))},getCloseTriggerProps(){return t.button(se(B({},$i.closeTrigger.attrs),{dir:a("dir"),id:uT(u),type:"button",onClick(h){h.defaultPrevented||(h.stopPropagation(),r({type:"CLOSE"}))}}))}}}var A4={props({props:e,scope:t}){const n=e.role==="alertdialog",r=n?()=>S4(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 Cy(()=>El(e),{type:"dialog",defer:!0,pointerBlocking:n("modal"),exclude:[x4(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 Ry(e.getDoc())},trapFocus({scope:e,prop:t}){return t("trapFocus")?Oy(()=>El(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")?yy(()=>[El(e)],{defer:!0}):void 0}},actions:{checkRenderedElements({context:e,scope:t}){Nt(()=>{e.set("rendered",{title:!!w4(t),description:!!_4(t)})})},syncZIndex({scope:e}){Nt(()=>{const t=El(e);if(!t)return;const n=Ro(t);[T4(e),b4(e)].forEach(o=>{o==null||o.style.setProperty("--z-index",n.zIndex),o==null||o.style.setProperty("--layer-index",n.getPropertyValue("--layer-index"))})})},invokeOnClose({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!1})},invokeOnOpen({prop:e}){var t;(t=e("onOpenChange"))==null||t({open:!0})},toggleVisibility({prop:e,send:t,event:n}){t({type:e("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE",previousEvent:n})}}}};Mo()(["aria-label","closeOnEscape","closeOnInteractOutside","dir","finalFocusEl","getRootNode","getRootNode","id","id","ids","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","defaultOpen","open","persistentElements","preventScroll","restoreFocus","role","trapFocus"]);const C4=e=>{const t=X.useId(),{getRootNode:n}=ml(),{dir:r}=th(),o=B({id:t,getRootNode:n,dir:r},e),a=nl(A4,o);return v4(a,Df)},lT=e=>{const[t,c]=GE(e),d=c,{children:n}=d,r=sn(d,["children"]),[o]=g4(t),a=C4(r),u=Bf(Ot({present:a.open},t));return P.jsx(E4,{value:a,children:P.jsx(p4,{value:o,children:P.jsx(qE,{value:u,children:n})})})},cT=X.forwardRef((e,t)=>{const n=fa(),r=Ot(n.getTitleProps(),e);return P.jsx(Kt.h2,se(B({},r),{ref:t}))});cT.displayName="DialogTitle";const k4=({children:e})=>{const[t,n]=X.useState(!1),r=X.useMemo(()=>({toggleMenu:()=>n(a=>!a),closeMenu:()=>n(!1)}),[]),o=X.useMemo(()=>({isOpen:t}),[t]);return P.jsx(xf.Provider,{value:r,children:P.jsx(yE.Provider,{value:o,children:e})})},dT=()=>X.useContext(yE),fT=()=>{const e=X.useContext(xf);if(!e)throw new Error("useOverflowMenuDispatch must be used within an OverflowMenuProvider");return e},N4=`${ee}-overflow-menu-button-trigger`,O4=({componentType:e,children:t})=>{const{isOpen:n}=dT(),{closeMenu:r}=fT(),{globalClassName:o}=kt(),a=X.useRef(null);return X.useEffect(()=>{if(!n)return;const u=d=>{d.key==="Escape"&&r()},c=d=>{const h=d.target;h instanceof Element&&h.closest(`.${N4}`)||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?P.jsx("div",{ref:a,role:"menu","aria-label":`Overflow menu for ${e}`,className:ae(`${ee}-overflow-panel`,o,`cim-${e}-component`),children:t}):null},I4=({componentType:e,className:t})=>{const{toggleMenu:n}=fT(),{isOpen:r}=dT(),{globalClassName:o}=kt();return P.jsx("button",{"aria-label":`Overflow menu for ${e}`,title:"More options","aria-expanded":r,"aria-haspopup":"menu",className:ae(`${ee}-overflow-menu-button-trigger`,`${ee}-icon-button`,o,t,`cim-${e}-component`),onClick:n,children:P.jsx(Uy,{})})},R4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),{previousComponentType:r}=Ci(),o=ta(),a=()=>{xu(r||"dialog"),o()};return t?P.jsx($r,{className:ae(n,`${ee}-toggle-dialog-button`,`cim-${e}-component`),ariaLabel:"Collapse",title:"Collapse",onClick:a,icon:P.jsx(Hy,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-toggle-dialog-button`,`cim-${e}-component`),onClick:a,children:[P.jsx(Hy,{}),"Show ",r||"dialog"]})},P4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),{isModalFullscreen:r}=Ci(),o=ta(),a=()=>{gd(!r),o()},u=r?Sv:vv,c="Toggle Fullscreen";return t?P.jsx($r,{ariaLabel:c,title:c,className:ae(n,`${ee}-modal-fullscreen-button`,`cim-${e}-component`),icon:P.jsx(u,{}),onClick:a}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-modal-fullscreen-button`,`cim-${e}-component`),onClick:a,children:[P.jsx(u,{}),c]})},L4=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),{dialogPosition:r}=Ci(),o=ta(),a=r==="bottom-left",u=()=>{Ed(a?"bottom-right":"bottom-left"),o()},c=a?q6:V6,d=a?"Move right":"Move left";return t?P.jsx($r,{className:ae(n,`${ee}-left-right-toggle-button`,`cim-${e}-component`),ariaLabel:d,title:d,onClick:u,icon:P.jsx(c,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-left-right-toggle-button`,`cim-${e}-component`),onClick:u,children:[P.jsx(c,{}),d]})},hT=({componentType:e,onClearChat:t,onClose:n})=>{const{headerConfig:r,globalClassName:o}=kt(),{mode:a}=Ci(),u=a==="standalone",c=e==="modal",d=c?R4:pT,h=c?P4:L4,p=X.useMemo(()=>r?wv(r):{},[r]);return P.jsx(k4,{children:P.jsxs("div",{className:ae(o,`${ee}-${e}-header-wrapper`),style:{display:"flex",flexDirection:"column",position:"relative"},children:[P.jsxs("div",{className:ae(o,`${ee}-${e}-header`,{standalone:u,embedded:!u}),style:p,children:[(r==null?void 0:r.logoUrl)&&P.jsx("img",{alt:"",role:"img",className:ae(o,`${ee}-${e}-logo`,{standalone:u,embedded:!u}),src:r.logoUrl}),P.jsx(cT,{className:ae(o,`${ee}-${e}-title`,{standalone:u,embedded:!u}),children:r==null?void 0:r.headerText}),P.jsxs("div",{className:ae(o,`${ee}-${e}-controls`),children:[P.jsx(d,{componentType:e,isIcon:!0}),P.jsx(I4,{componentType:e}),P.jsx(h4,{className:ae(o,`cim-${e}-component`),onClick:n})]})]}),P.jsxs(O4,{componentType:e,children:[P.jsx(h,{componentType:e}),P.jsx(M4,{componentType:e}),P.jsx(bE,{componentType:e,onClearChat:t})]})]})})},D4=({className:e,globalClassName:t,suggestions:n,disabled:r,isWidgetStandalone:o,onSuggestionClick:a})=>{const u=o?"standalone":"embedded",c=d=>()=>{a(d)};return P.jsx("div",{className:ae(t,`${ee}-suggestion-container ${u}`,e),children:n.map(d=>o?P.jsx(O0,{disabled:r,className:ae(t,`${ee}-suggestion-button standalone`),onClick:c(d),children:d},d):P.jsx("button",{disabled:r,className:ae(t,`${ee}-suggestion-button embedded`),onClick:c(d),children:d},d))})},M4=({componentType:e,isIcon:t})=>{const{globalClassName:n,enableMinimize:r}=kt();if(!r)return null;const o=()=>{Ai(!1),bu(!0)};return t?P.jsx($r,{className:ae(n,`${ee}-toggle-minimize-button`,`cim-${e}-component`),ariaLabel:"Toggle Minimize",title:"Minimize",onClick:o,icon:P.jsx(k0,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-toggle-minimize-button`,`cim-${e}-component`),onClick:o,children:[P.jsx(k0,{}),"Minimize"]})},pT=({componentType:e,isIcon:t})=>{const{globalClassName:n}=kt(),r=ta(),o=()=>{xu("modal"),r()};return t?P.jsx($r,{className:ae(n,`${ee}-toggle-modal-button`,`cim-${e}-component`),ariaLabel:"Expand",title:"Expand",onClick:o,icon:P.jsx(zy,{})}):P.jsxs("button",{className:ae(n,`${ee}-overflow-menu-button`,`${ee}-toggle-modal-button`,`cim-${e}-component`),onClick:o,children:[P.jsx(zy,{}),"Show modal"]})};function mT(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 F4(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function B4(e,t,n){const o=Lu((n||{}).ignore||[]),a=U4(t);let u=-1;for(;++u<a.length;)zg(e,"text",c);function c(h,p){let E=-1,b;for(;++E<p.length;){const T=p[E],x=b?b.children:void 0;if(o(T,x?x.indexOf(T):void 0,b))return;b=T}if(b)return d(h,p)}function d(h,p){const E=p[p.length-1],b=a[u][0],T=a[u][1];let x=0;const S=E.children.indexOf(h);let A=!1,O=[];b.lastIndex=0;let I=b.exec(h.value);for(;I;){const z=I.index,Y={index:I.index,input:I.input,stack:[...p,h]};let M=T(...I,Y);if(typeof M=="string"&&(M=M.length>0?{type:"text",value:M}:void 0),M===!1?b.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+I[0].length,A=!0),!b.global)break;I=b.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 U4(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([H4(o[0]),z4(o[1])])}return t}function H4(e){return typeof e=="string"?new RegExp(F4(e),"g"):e}function z4(e){return typeof e=="function"?e:function(){return e}}const uh="phrasing",lh=["autolink","link","image","label"];function j4(){return{transforms:[K4],enter:{literalAutolink:V4,literalAutolinkEmail:ch,literalAutolinkHttp:ch,literalAutolinkWww:ch},exit:{literalAutolink:G4,literalAutolinkEmail:W4,literalAutolinkHttp:q4,literalAutolinkWww:Y4}}}function $4(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:uh,notInConstruct:lh},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:uh,notInConstruct:lh},{character:":",before:"[ps]",after:"\\/",inConstruct:uh,notInConstruct:lh}]}}function V4(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function ch(e){this.config.enter.autolinkProtocol.call(this,e)}function q4(e){this.config.exit.autolinkProtocol.call(this,e)}function Y4(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 W4(e){this.config.exit.autolinkEmail.call(this,e)}function G4(e){this.exit(e)}function K4(e){B4(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Q4],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),X4]],{ignore:["link","linkReference"]})}function Q4(e,t,n,r,o){let a="";if(!gT(o)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!J4(n)))return!1;const u=Z4(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 X4(e,t,n,r){return!gT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function J4(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 Z4(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=mT(e,"(");let a=mT(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 gT(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Oi(n)||Cu(n))&&(!t||n!==47)}ET.peek=uD;function eD(){this.buffer()}function tD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function nD(){this.buffer()}function rD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function iD(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 oD(e){this.exit(e)}function sD(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 aD(e){this.exit(e)}function uD(){return"["}function ET(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 lD(){return{enter:{gfmFootnoteCallString:eD,gfmFootnoteCall:tD,gfmFootnoteDefinitionLabelString:nD,gfmFootnoteDefinition:rD},exit:{gfmFootnoteCallString:iD,gfmFootnoteCall:oD,gfmFootnoteDefinitionLabelString:sD,gfmFootnoteDefinition:aD}}}function cD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:ET},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?yT:dD))),h(),d}}function dD(e,t,n){return t===0?e:yT(e,t,n)}function yT(e,t,n){return(n?"":" ")+e}const fD=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];TT.peek=ED;function hD(){return{canContainEols:["delete"],enter:{strikethrough:mD},exit:{strikethrough:gD}}}function pD(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:fD}],handlers:{delete:TT}}}function mD(e){this.enter({type:"delete",children:[]},e)}function gD(e){this.exit(e)}function TT(e,t,n,r){const o=n.createTracker(r),a=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,se(B({},o.current()),{before:u,after:"~"})),u+=o.move("~~"),a(),u}function ED(){return"~"}function yD(e){return e.length}function TD(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||yD,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=bD(e[p][A]);if(n.alignDelimiters!==!1){const I=o(O);S[A]=I,(d[A]===void 0||I>d[A])&&(d[A]=I)}_.push(O)}u[p]=_,c[p]=S}let E=-1;if(typeof r=="object"&&"length"in r)for(;++E<h;)a[E]=bT(r[E]);else{const _=bT(r);for(;++E<h;)a[E]=_}E=-1;const b=[],T=[];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 I=S+"-".repeat(O)+A;n.alignDelimiters!==!1&&(O=S.length+O+A.length,O>d[E]&&(d[E]=O),T[E]=O),b[E]=I}u.splice(1,0,b),c.splice(1,0,T),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 I="",z="";if(n.alignDelimiters!==!1){const Y=d[E]-(S[E]||0),M=a[E];M===114?I=" ".repeat(Y):M===99?Y%2?(I=" ".repeat(Y/2+.5),z=" ".repeat(Y/2-.5)):(I=" ".repeat(Y/2),z=I):z=" ".repeat(Y)}n.delimiterStart!==!1&&!E&&A.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&O==="")&&(n.delimiterStart!==!1||E)&&A.push(" "),n.alignDelimiters!==!1&&A.push(I),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(`
|
|
39
39
|
`)}function bD(e){return e==null?"":String(e)}function bT(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function xD(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()),wD);return o(),u}function wD(e,t,n){return">"+(n?"":" ")+e}function _D(e,t){return xT(e,t.inConstruct,!0)&&!xT(e,t.notInConstruct,!1)}function xT(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 wT(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if(n.unsafe[o].character===`
|
|
40
40
|
`&&_D(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return`\\
|
|
41
41
|
`}function SD(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 vD(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 AD(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 CD(e,t,n,r){const o=AD(n),a=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(vD(e,n)){const E=n.enter("codeIndented"),b=n.indentLines(a,kD);return E(),b}const c=n.createTracker(r),d=o.repeat(Math.max(SD(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:`
|
|
@@ -49,4 +49,4 @@ Error generating stack: `+y.message+`
|
|
|
49
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
50
|
`},a.current()));return/^[\t ]/.test(h)&&(h=ha(h.charCodeAt(0))+h.slice(1)),h=h?u+" "+h:u,n.options.closeAtx&&(h+=" "+u),d(),c(),h}ST.peek=LD;function ST(e){return e.value||""}function LD(){return"<"}vT.peek=DD;function vT(e,t,n,r){const o=dh(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 DD(){return"!"}AT.peek=MD;function AT(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 MD(){return"!"}CT.peek=FD;function CT(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 FD(){return"`"}function kT(e,t){const n=Rd(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))}NT.peek=BD;function NT(e,t,n,r){const o=dh(n),a=o==='"'?"Quote":"Apostrophe",u=n.createTracker(r);let c,d;if(kT(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 BD(e,t,n){return kT(e,n)?"<":"["}OT.peek=UD;function OT(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 UD(){return"["}function fh(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 HD(e){const t=fh(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 zD(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 IT(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 jD(e,t,n,r){const o=n.enter("list"),a=n.bulletCurrent;let u=e.ordered?zD(n):fh(n);const c=e.ordered?u==="."?")":".":HD(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),IT(n)===u&&p){let E=-1;for(;++E<e.children.length;){const b=e.children[E];if(b&&b.type==="listItem"&&b.children&&b.children[0]&&b.children[0].type==="thematicBreak"){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 $D(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 VD(e,t,n,r){const o=$D(n);let a=n.bulletCurrent||fh(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,b,T){return b?(T?"":" ".repeat(u))+E:(T?a:a+" ".repeat(u-a.length))+E}}function qD(e,t,n,r){const o=n.enter("paragraph"),a=n.enter("phrasing"),u=n.containerPhrasing(e,r);return a(),o(),u}const YD=Lu(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function WD(e,t,n,r){return(e.children.some(function(u){return YD(u)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function GD(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}RT.peek=KD;function RT(e,t,n,r){const o=GD(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=yl(r.before.charCodeAt(r.before.length-1),h,o);p.inside&&(d=ha(h)+d.slice(1));const E=d.charCodeAt(d.length-1),b=yl(r.after.charCodeAt(0),E,o);b.inside&&(d=d.slice(0,-1)+ha(E));const T=u.move(o+o);return a(),n.attentionEncodeSurroundingInfo={after:b.outside,before:p.outside},c+d+T}function KD(e,t,n){return n.options.strong||"*"}function QD(e,t,n,r){return n.safe(e.value,r)}function XD(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 JD(e,t,n){const r=(IT(n)+(n.options.ruleSpaces?" ":"")).repeat(XD(n));return n.options.ruleSpaces?r.slice(0,-1):r}const PT={blockquote:xD,break:wT,code:CD,definition:ND,emphasis:_T,hardBreak:wT,heading:PD,html:ST,image:vT,imageReference:AT,inlineCode:CT,link:NT,linkReference:OT,list:jD,listItem:VD,paragraph:qD,root:WD,strong:RT,text:QD,thematicBreak:JD};function ZD(){return{enter:{table:e5,tableData:LT,tableHeader:LT,tableRow:n5},exit:{codeText:r5,table:t5,tableData:hh,tableHeader:hh,tableRow:hh}}}function e5(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 t5(e){this.exit(e),this.data.inTable=void 0}function n5(e){this.enter({type:"tableRow",children:[]},e)}function hh(e){this.exit(e)}function LT(e){this.enter({type:"tableCell",children:[]},e)}function r5(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,i5));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function i5(e,t){return t==="|"?t:e}function o5(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:b,table:u,tableCell:d,tableRow:c}};function u(T,x,_,S){return h(p(T,_,S),T.align)}function c(T,x,_,S){const A=E(T,_,S),O=h([A]);return O.slice(0,O.indexOf(`
|
|
52
|
-
`))}function d(T,x,_,S){const A=_.enter("tableCell"),O=_.enter("phrasing"),I=_.containerPhrasing(T,se(B({},S),{before:a,after:a}));return O(),A(),I}function h(T,x){return TD(T,{align:x,alignDelimiters:r,padding:n,stringLength:o})}function p(T,x,_){const S=T.children;let A=-1;const O=[],I=x.enter("table");for(;++A<S.length;)O[A]=E(S[A],x,_);return I(),O}function E(T,x,_){const S=T.children;let A=-1;const O=[],I=x.enter("tableRow");for(;++A<S.length;)O[A]=d(S[A],T,x,_);return I(),O}function b(T,x,_){let S=PT.inlineCode(T,x,_);return _.stack.includes("tableCell")&&(S=S.replace(/\|/g,"\\$&")),S}}function s5(){return{exit:{taskListCheckValueChecked:DT,taskListCheckValueUnchecked:DT,paragraph:u5}}}function a5(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:l5}}}function DT(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function u5(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 l5(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=PT.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 c5(){return[j4(),lD(),hD(),ZD(),s5()]}function d5(e){return{extensions:[$4(),cD(e),pD(),o5(e),a5()]}}const f5={tokenize:y5,partial:!0},MT={tokenize:T5,partial:!0},FT={tokenize:b5,partial:!0},BT={tokenize:x5,partial:!0},h5={tokenize:w5,partial:!0},UT={name:"wwwAutolink",tokenize:g5,previous:zT},HT={name:"protocolAutolink",tokenize:E5,previous:jT},Or={name:"emailAutolink",tokenize:m5,previous:$T},Er={};function p5(){return{text:Er}}let Vi=48;for(;Vi<123;)Er[Vi]=Or,Vi++,Vi===58?Vi=65:Vi===91&&(Vi=97);Er[43]=Or,Er[45]=Or,Er[46]=Or,Er[95]=Or,Er[72]=[Or,HT],Er[104]=[Or,HT],Er[87]=[Or,UT],Er[119]=[Or,UT];function m5(e,t,n){const r=this;let o,a;return u;function u(E){return!ph(E)||!$T.call(r,r.previous)||mh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return ph(E)?(e.consume(E),c):E===64?(e.consume(E),d):n(E)}function d(E){return E===46?e.check(h5,p,h)(E):E===45||E===95||Wt(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 g5(e,t,n){const r=this;return o;function o(u){return u!==87&&u!==119||!zT.call(r,r.previous)||mh(r.events)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(f5,e.attempt(MT,e.attempt(FT,a),n),n)(u))}function a(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function E5(e,t,n){const r=this;let o="",a=!1;return u;function u(E){return(E===72||E===104)&&jT.call(r,r.previous)&&!mh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(nn(E)&&o.length<5)return o+=String.fromCodePoint(E),e.consume(E),c;if(E===58){const b=o.toLowerCase();if(b==="http"||b==="https")return e.consume(E),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||Au(E)||it(E)||Oi(E)||Cu(E)?n(E):e.attempt(MT,e.attempt(FT,p),n)(E)}function p(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function y5(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 T5(e,t,n){let r,o,a;return u;function u(h){return h===46||h===95?e.check(BT,d,c)(h):h===null||it(h)||Oi(h)||h!==45&&Cu(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 b5(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(BT,t,a)(u):u===null||it(u)||Oi(u)?t(u):(e.consume(u),o)}function a(u){return u===41&&r++,e.consume(u),o}}function x5(e,t,n){return r;function r(c){return c===33||c===34||c===39||c===41||c===42||c===44||c===46||c===58||c===59||c===63||c===95||c===126?(e.consume(c),r):c===38?(e.consume(c),a):c===93?(e.consume(c),o):c===60||c===null||it(c)||Oi(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||it(c)||Oi(c)?t(c):r(c)}function a(c){return 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 w5(e,t,n){return r;function r(a){return e.consume(a),o}function o(a){return Wt(a)?n(a):t(a)}}function zT(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||it(e)}function jT(e){return!nn(e)}function $T(e){return!(e===47||ph(e))}function ph(e){return e===43||e===45||e===46||e===95||Wt(e)}function mh(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const _5={tokenize:I5,partial:!0};function S5(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:k5,continuation:{tokenize:N5},exit:O5}},text:{91:{name:"gfmFootnoteCall",tokenize:C5},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:v5,resolveTo:A5}}}}function v5(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 A5(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 C5(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 b=e.exit("gfmFootnoteCallString");return o.includes(Yn(r.sliceSerialize(b)))?(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 k5(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"),b}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 b(x){return x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),o.includes(a)||o.push(a),Qe(e,T,"gfmFootnoteDefinitionWhitespace")):n(x)}function T(x){return t(x)}}function N5(e,t,n){return e.check(Ms,t,e.attempt(_5,t,n))}function O5(e){e.exit("gfmFootnoteDefinition")}function I5(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 R5(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)},b=[["enter",p,c],["enter",u[h][1],c],["exit",u[h][1],c],["enter",E,c]],T=c.parser.constructs.insideSpan.null;T&&xn(b,b.length,0,ku(T,u.slice(h+1,d),c)),xn(b,b.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,b),d=h+b.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 b;function b(x){return h===126&&p[p.length-1][1].type!=="characterEscape"?d(x):(u.enter("strikethroughSequenceTemporary"),T(x))}function T(x){const _=yo(h);if(x===126)return E>1?d(x):(u.consume(x),E++,T);if(E<2&&!n)return d(x);const S=u.exit("strikethroughSequenceTemporary"),A=yo(x);return S._open=!A||A===2&&!!_,S._close=!_||_===2&&!!A,c(x)}}}class P5{constructor(){this.map=[]}add(t,n,r){L5(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 L5(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 D5(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 M5(){return{flow:{null:{name:"table",tokenize:F5,resolveAll:B5}}}}function F5(e,t,n){const r=this;let o=0,a=0,u;return c;function c(z){let W=r.events.length-1;for(;W>-1;){const de=r.events[W][1].type;if(de==="lineEnding"||de==="linePrefix")W--;else break}const te=W>-1?r.events[W][1].type:null,oe=te==="tableHead"||te==="tableRow"?M:d;return oe===M&&r.parser.lazy[r.now().line]?n(z):oe(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"),T):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?b:E)}function b(z){return z===92||z===124?(e.consume(z),E):E(z)}function T(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"),_):Y(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):Y(z)}function A(z){return z===45?(e.enter("tableDelimiterFiller"),O(z)):Y(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"),I):(e.exit("tableDelimiterFiller"),I(z))}function I(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?Y(z):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(z)):Y(z)}function Y(z){return n(z)}function M(z){return e.enter("tableRow"),G(z)}function G(z){return z===124?(e.enter("tableCellDivider"),e.consume(z),e.exit("tableCellDivider"),G):z===null||Le(z)?(e.exit("tableRow"),t(z)):Ge(z)?Qe(e,G,"whitespace")(z):(e.enter("data"),pe(z))}function pe(z){return z===null||z===124||it(z)?(e.exit("data"),G(z)):(e.consume(z),z===92?re:pe)}function re(z){return z===92||z===124?(e.consume(z),pe):pe(z)}}function B5(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 b=new P5;for(;++n<e.length;){const T=e[n],x=T[1];T[0]==="enter"?x.type==="tableHead"?(c=!1,d!==0&&(VT(b,t,d,h,p),p=void 0,d=0),h={type:"table",start:Object.assign({},x.start),end:Object.assign({},x.end)},b.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)},b.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=Tl(b,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=Tl(b,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=Tl(b,t,a,o,n,E)):u[1]!==0&&(E=Tl(b,t,u,o,n,E)),o=0):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")&&(u[3]=n)}for(d!==0&&VT(b,t,d,h,p),b.consume(t.events),n=-1;++n<t.events.length;){const T=t.events[n];T[0]==="enter"&&T[1].type==="table"&&(T[1]._align=D5(t.events,n))}return e}function Tl(e,t,n,r,o,a){const u=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(a.end=Object.assign({},qo(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const d=qo(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=qo(t.events,n[2]),p=qo(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 b=t.events[n[2]],T=t.events[n[3]];if(b[1].end=Object.assign({},T[1].end),b[1].type="chunkText",b[1].contentType="text",n[3]>n[2]+1){const 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({},qo(t.events,o)),e.add(o,0,[["exit",a,t]]),a=void 0),a}function VT(e,t,n,r,o){const a=[],u=qo(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 qo(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const U5={name:"tasklistCheck",tokenize:z5};function H5(){return{text:{91:U5}}}function z5(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:j5},t,n)(d):n(d)}}function j5(e,t,n){return Qe(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function $5(e){return ug([p5(),S5(),R5(e),M5(),H5()])}const V5={};function q5(e){const t=this,n=e||V5,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),u=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push($5(n)),a.push(c5()),u.push(d5(n))}const Y5=()=>P.jsx("span",{className:`${ee}-blinking-cursor`,children:P.jsx("svg",{height:"16px",width:"16px",xmlns:"http://www.w3.org/2000/svg",children:P.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),gh=({globalClassName:e,openLinksInNewTab:t,showIsLoading:n,text:r})=>P.jsx(Jg,{remarkPlugins:[q5],rehypePlugins:[cE],components:{h1:({children:o})=>P.jsx("h1",{className:ae(e,`${ee}-header h1`),children:o}),h2:({children:o})=>P.jsx("h2",{className:ae(e,`${ee}-header h2`),children:o}),h3:({children:o})=>P.jsx("h3",{className:ae(e,`${ee}-header h3`),children:o}),ul:({children:o})=>P.jsx("ul",{className:ae(e,`${ee}-ul`),children:o}),ol:({children:o})=>P.jsx("ol",{className:ae(e,`${ee}-ol`),children:o}),li:({children:o})=>P.jsx("li",{className:ae(e,`${ee}-li`),children:o}),a:({href:o,children:a})=>P.jsx(EE,{globalClassName:e,openLinksInNewTab:t,href:o,children:a}),table:({children:o})=>P.jsx("div",{className:ae(e,`${ee}-table-container`),children:P.jsx("table",{className:ae(e,`${ee}-table`),children:o})}),thead:({children:o})=>P.jsx("thead",{className:ae(e,`${ee}-thead`),children:o}),tbody:({children:o})=>P.jsx("tbody",{className:ae(e,`${ee}-tbody`),children:o}),tr:({children:o})=>P.jsx("tr",{className:ae(e,`${ee}-tr`),children:o}),th:({children:o})=>P.jsx("th",{className:ae(e,`${ee}-th`),children:o}),td:({children:o})=>P.jsx("td",{className:ae(e,`${ee}-td`),children:o}),span:({className:o,children:a})=>o===`${ee}-blinking-cursor`?P.jsx(Y5,{}):P.jsx("span",{children:a})},children:r+(n?`<span className='${ee}-blinking-cursor'></span>`:"")}),W5=["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"],G5=3e3,K5=400,Q5=({globalClassName:e,isWidgetStandalone:t,messages:n=W5})=>{const[r,o]=X.useState(0),[a,u]=X.useState(!0);return X.useEffect(()=>{let c;const d=setInterval(()=>{u(!1),c=setTimeout(()=>{o(h=>(h+1)%n.length),u(!0)},K5)},G5);return()=>{clearInterval(d),clearTimeout(c)}},[n.length]),P.jsxs("div",{className:ae(e,`${ee}-connecting-indicator`,t?"standalone":"embedded"),role:"status","aria-label":"Connecting to assistant",children:[P.jsxs("div",{className:`${ee}-connecting-pulse-wrapper`,children:[P.jsx("div",{className:`${ee}-connecting-pulse`}),P.jsx("div",{className:`${ee}-connecting-ring`})]}),P.jsx("span",{className:ae(`${ee}-connecting-text`,a&&`${ee}-connecting-text--visible`),children:n[r]})]})},X5=({shouldShow:e,loadingText:t})=>e?P.jsx("span",{className:`${ee}-processing-text`,children:t}):null,J5=({shouldShow:e})=>e?P.jsxs(P.Fragment,{children:[P.jsx("div",{className:`${ee}-processing-shimmer-bar`}),P.jsx("div",{className:`${ee}-processing-shimmer-bar`}),P.jsx("div",{className:`${ee}-processing-shimmer-bar`})]}):null,Z5=({globalClassName:e,isWidgetStandalone:t,loadingText:n})=>P.jsxs("div",{className:ae(e,`${ee}-processing-indicator`,t?"standalone":"embedded"),role:"status","aria-label":n||"Loading response",children:[P.jsx(X5,{shouldShow:!!n,loadingText:n}),P.jsx(J5,{shouldShow:!n})]}),bl=(e,t)=>{if(typeof e!="number")return null;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t||"USD"}).format(e)}catch(n){return`${e}`}},qT=({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,b=bl(E?d:c,p),T=bl(E?c:h,p);return P.jsxs("div",{className:ae(t,`${ee}-msg-product-card`,{"card-full-width":n}),children:[P.jsx("div",{className:ae(t,`${ee}-msg-product-card__image-wrapper`),children:a&&(u?P.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer","aria-label":`Go to product page for ${o}`,children:P.jsx("img",{className:ae(t,`${ee}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"})}):P.jsx("img",{className:ae(t,`${ee}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"}))}),P.jsxs("div",{className:ae(t,`${ee}-msg-product-card__content`),children:[u?P.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer",className:ae(t,`${ee}-msg-product-card__title-link`),"aria-label":`Go to product page for ${o}`,children:o}):P.jsx("p",{className:ae(t,`${ee}-msg-product-card__title`),children:o}),P.jsx("div",{className:ae(t,`${ee}-msg-product-card__price-row`),children:P.jsxs("div",{className:ae(t,`${ee}-msg-product-card__prices`),children:[b&&P.jsx("span",{className:ae(t,`${ee}-msg-product-card__price`),children:b}),T&&P.jsx("span",{className:ae(t,`${ee}-msg-product-card__compare-price`),children:T})]})})]})]})},YT=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}),e8=({title:e,products:t,globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o})=>{if(t.length===1){const a=t[0];return P.jsxs("div",{children:[e&&P.jsx("p",{className:ae(n,`${ee}-product-carousel-title`),children:e}),P.jsx(qT,{product:YT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o,isFullWidth:!o})]})}return P.jsxs("div",{style:{marginBottom:"1rem"},children:[e&&P.jsx("p",{className:ae(n,`${ee}-product-carousel-title`),children:e}),P.jsx(f4,{globalClassName:n,spacing:o?"0.5rem":"6px",ariaLabel:e||"Product recommendations",children:t.map(a=>P.jsx(qT,{product:YT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o},a.id))})]})},t8=({content:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{sendMessage:o,loading:a}=ki();return P.jsx(P.Fragment,{children:e.response.map((u,c)=>{var d,h;switch(u.type){case"markdown":return P.jsx(gh,{text:u.data.content,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1},`${u.type}-${c}`);case"product_carousel":return P.jsx(e8,{title:u.data.title,products:u.data.products,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(d=u.index)!=null?d:c}`);case"suggestions":return P.jsx("div",{style:{marginTop:"0.5rem"},children:P.jsx(D4,{disabled:a,suggestions:u.data.display_text,globalClassName:t,isWidgetStandalone:r,onSuggestionClick:o})},`${u.type}-${(h=u.index)!=null?h:c}`);default:return null}})})},n8=({message:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{logger:o}=kt(),a=X.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=X.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 P.jsx("div",{className:ae(t,`${ee}-message`,r?"standalone":"embedded"),children:P.jsx("div",{className:ae(t,`${ee}-user-message`,r?"standalone":"embedded"),children:P.jsxs("div",{className:ae(t,`${ee}-user-message-row`,r?"standalone":"embedded"),children:[P.jsx("span",{className:ae(t,`${ee}-message-icon user-message-icon`,r?"standalone":"embedded"),children:P.jsx(_v,{})}),P.jsx("p",{className:ae(t,`${ee}-user-message-text`,r?"standalone":"embedded"),children:e.content})]})})});case"agent":return P.jsx("div",{className:ae(t,`${ee}-message-group`,r?"standalone":"embedded"),children:P.jsx("div",{className:`${ee}-message-group-child`,children:a?P.jsx(t8,{content:a,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r}):P.jsx(gh,{text:u,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})})});case"system":return P.jsx("div",{className:ae(t,`${ee}-message`,r?"standalone":"embedded"),children:P.jsx("p",{className:ae(t,`${ee}-reset-message`),children:e.content})})}},Eh=({isWidgetStandalone:e})=>{const{globalClassName:t,openLinksInNewTab:n}=kt(),{messages:r,streamingContent:o,isAgentTyping:a,loading:u,progressMessage:c}=ki(),d=X.useRef(null),h=r.length>0;return X.useEffect(()=>{var p;(p=d.current)==null||p.scrollIntoView({behavior:"smooth"})},[r,o]),P.jsxs(P.Fragment,{children:[u&&!h&&P.jsx(Q5,{globalClassName:t,isWidgetStandalone:e}),r.map(p=>P.jsx(n8,{message:p,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e},p.id)),o&&P.jsx("div",{className:ae(t,`${ee}-message-group`,e?"standalone":"embedded"),children:P.jsx(gh,{text:o,globalClassName:t,openLinksInNewTab:n,showIsLoading:!0})}),h&&(u||a)&&!o&&P.jsx(Z5,{globalClassName:t,isWidgetStandalone:e,loadingText:c}),P.jsx("div",{ref:d})]})},WT=()=>{const{globalClassName:e,themeVariables:t}=kt(),{isAgentTyping:n,sendMessage:r,resetConversation:o}=ki(),a=n;return P.jsxs("div",{className:ae(e,`${ee}-container`,`${ee}-embedded-chat`),style:t,children:[P.jsx("div",{className:ae(e,`${ee}-message-container`,"embedded"),children:P.jsx(Eh,{isWidgetStandalone:!1})}),P.jsx(bf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:u=>r(u)}),P.jsx("div",{className:ae(`${ee}-embedded-chat-menu`),children:P.jsxs(G6,{componentType:"chat",children:[P.jsx(pT,{componentType:"chat"}),P.jsx(bE,{componentType:"chat",onClearChat:o})]})})]})},GT=e=>{var d;const{children:t,disabled:n}=e,[r,o]=X.useState((d=e.container)==null?void 0:d.current),a=X.useSyncExternalStore(i8,()=>!1,()=>!0),{getRootNode:u}=ml();if(X.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),a||n)return P.jsx(P.Fragment,{children:t});const c=r!=null?r:r8(u);return P.jsx(P.Fragment,{children:X.Children.map(t,h=>Ns.createPortal(h,c))})},r8=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Fi(n)?n:cr(t).body},i8=()=>()=>{},KT=()=>{const{globalClassName:e,themeVariables:t}=kt(),{mode:n,status:r,dialogPosition:o,isDialogFullHeight:a,dialogWidth:u}=Ci(),{loading:c,isAgentTyping:d,sendMessage:h,resetConversation:p}=ki(),{isOpen:E}=r||{},b=!!r.isOpen,T=n==="standalone",x=d||c,_=()=>{Ai(!1)};return P.jsx(lT,{lazyMount:!0,unmountOnExit:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:b,children:P.jsx(GT,{children:P.jsx(ih,{className:ae(e,`${ee}-container`,`${ee}-dialog`,o,a&&"full-height"),style:B(B({},t),u&&{width:u}),children:P.jsxs(nh,{className:ae(e,`${ee}-dialog-content`,{standalone:T,embedded:!T}),children:[P.jsx(hT,{componentType:"dialog",onClearChat:p,onClose:_}),P.jsx(rh,{className:ae(e,`${ee}-message-container`,{standalone:T,embedded:!T}),children:P.jsx(Eh,{isWidgetStandalone:T,isOpen:E})}),P.jsx(bf,{componentType:"dialog",isLoading:x,onSubmit:S=>h(S)})]})})})})},QT=()=>{const{globalClassName:e,themeVariables:t}=kt(),{mode:n,status:r,isModalFullscreen:o}=Ci(),{isAgentTyping:a,sendMessage:u,resetConversation:c}=ki(),{isOpen:d}=r||{},h=!!r.isOpen,p=n==="standalone",E=a,b=({open:x})=>{Ai(x)},T=()=>{Ai(!1)};return h?P.jsx(lT,{lazyMount:!0,unmountOnExit:!0,open:h,onOpenChange:b,children:P.jsx(GT,{children:P.jsxs("div",{className:ae(e,`${ee}-modal-container`),style:t,children:[P.jsx(iT,{className:ae(e,`${ee}-modal-backdrop`)}),P.jsx(ih,{className:ae(e,`${ee}-container`,`${ee}-modal`,{fullscreen:o,standalone:p,embedded:!p}),children:P.jsxs(nh,{className:ae(e,`${ee}-modal-content`,{standalone:p,embedded:!p}),children:[P.jsx(hT,{componentType:"modal",onClearChat:c,onClose:T}),P.jsx(rh,{className:ae(e,`${ee}-message-container`,{standalone:p,embedded:!p}),children:P.jsx(Eh,{isWidgetStandalone:p,isOpen:d})}),P.jsx(bf,{componentType:"modal",isLoading:E,onSubmit:x=>u(x)})]})})]})})}):null},o8=()=>{const e=Ci(),{status:{type:t,isMinimized:n}}=e||{status:{}};return n?P.jsx(bv,{}):t==="dialog"?P.jsx(KT,{}):t==="modal"?P.jsx(QT,{}):P.jsx(WT,{})},yh=e=>P.jsx(E0,se(B({},e),{children:P.jsx(o8,{})}));var xl={},XT;function s8(){if(XT)return xl;XT=1;var e=w0();return xl.createRoot=e.createRoot,xl.hydrateRoot=e.hydrateRoot,xl}var JT=s8();const a8=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 b of E.addedNodes)b.nodeType===Node.ELEMENT_NODE&&b.id===e&&(vi(!0,"log","Target element found, rendering Messaging Widget"),h.disconnect(),clearTimeout(a),(p=JT.createRoot(b))==null||p.render(P.jsx(yh,se(B({},n),{mode:"messaging"}))))},c=new MutationObserver(u);return c.observe(document.body,{childList:!0,subtree:!0}),a=setTimeout(()=>{c.disconnect(),vi(!0,"error",`Element with id: ${e} not found within ${t} milliseconds, stopping observation`)},t),c},u8=r=>{var o=r,{timeout:e,elementId:t}=o,n=sn(o,["timeout","elementId"]);if(!n.messagingConfig){vi(!0,"error","Messaging Widget requires messagingConfig");return}if(!n.messagingConfig.scrt2Url||!n.messagingConfig.orgId||!n.messagingConfig.esDeveloperName){vi(!0,"error","Messaging Widget requires messagingConfig.scrt2Url, messagingConfig.orgId, and messagingConfig.esDeveloperName");return}const a=document.getElementById(t);if(!a){vi(!0,"warn","Container element not found for id:",t),vi(!0,"warn","Beginning observation for element"),a8(B({elementId:t,timeout:e},n));return}JT.createRoot(a).render(P.jsx(yh,se(B({},n),{mode:"messaging"})))},l8={components:{setEntryType:m0,toggleWidgetOpen:Ai,toggleWidgetMinimized:bu,toggleModalFullscreen:gd,setWidgetType:xu,setWidgetDialogPosition:Ed}};Ie.AgentForceWidget=yh,Ie.AgentforceWidgetProvider=E0,Ie.MessagingDialog=KT,Ie.MessagingEmbed=WT,Ie.MessagingModal=QT,Ie.MessagingProvider=p0,Ie.eventHandlers=l8,Ie.injectMessagingWidget=u8,Ie.useMessaging=ki,Object.defineProperty(Ie,Symbol.toStringTag,{value:"Module"})}));
|
|
52
|
+
`))}function d(T,x,_,S){const A=_.enter("tableCell"),O=_.enter("phrasing"),I=_.containerPhrasing(T,se(B({},S),{before:a,after:a}));return O(),A(),I}function h(T,x){return TD(T,{align:x,alignDelimiters:r,padding:n,stringLength:o})}function p(T,x,_){const S=T.children;let A=-1;const O=[],I=x.enter("table");for(;++A<S.length;)O[A]=E(S[A],x,_);return I(),O}function E(T,x,_){const S=T.children;let A=-1;const O=[],I=x.enter("tableRow");for(;++A<S.length;)O[A]=d(S[A],T,x,_);return I(),O}function b(T,x,_){let S=PT.inlineCode(T,x,_);return _.stack.includes("tableCell")&&(S=S.replace(/\|/g,"\\$&")),S}}function s5(){return{exit:{taskListCheckValueChecked:DT,taskListCheckValueUnchecked:DT,paragraph:u5}}}function a5(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:l5}}}function DT(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function u5(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 l5(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=PT.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 c5(){return[j4(),lD(),hD(),ZD(),s5()]}function d5(e){return{extensions:[$4(),cD(e),pD(),o5(e),a5()]}}const f5={tokenize:y5,partial:!0},MT={tokenize:T5,partial:!0},FT={tokenize:b5,partial:!0},BT={tokenize:x5,partial:!0},h5={tokenize:w5,partial:!0},UT={name:"wwwAutolink",tokenize:g5,previous:zT},HT={name:"protocolAutolink",tokenize:E5,previous:jT},Or={name:"emailAutolink",tokenize:m5,previous:$T},Er={};function p5(){return{text:Er}}let Vi=48;for(;Vi<123;)Er[Vi]=Or,Vi++,Vi===58?Vi=65:Vi===91&&(Vi=97);Er[43]=Or,Er[45]=Or,Er[46]=Or,Er[95]=Or,Er[72]=[Or,HT],Er[104]=[Or,HT],Er[87]=[Or,UT],Er[119]=[Or,UT];function m5(e,t,n){const r=this;let o,a;return u;function u(E){return!ph(E)||!$T.call(r,r.previous)||mh(r.events)?n(E):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),c(E))}function c(E){return ph(E)?(e.consume(E),c):E===64?(e.consume(E),d):n(E)}function d(E){return E===46?e.check(h5,p,h)(E):E===45||E===95||Wt(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 g5(e,t,n){const r=this;return o;function o(u){return u!==87&&u!==119||!zT.call(r,r.previous)||mh(r.events)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(f5,e.attempt(MT,e.attempt(FT,a),n),n)(u))}function a(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function E5(e,t,n){const r=this;let o="",a=!1;return u;function u(E){return(E===72||E===104)&&jT.call(r,r.previous)&&!mh(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(E),e.consume(E),c):n(E)}function c(E){if(nn(E)&&o.length<5)return o+=String.fromCodePoint(E),e.consume(E),c;if(E===58){const b=o.toLowerCase();if(b==="http"||b==="https")return e.consume(E),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||Au(E)||it(E)||Oi(E)||Cu(E)?n(E):e.attempt(MT,e.attempt(FT,p),n)(E)}function p(E){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(E)}}function y5(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 T5(e,t,n){let r,o,a;return u;function u(h){return h===46||h===95?e.check(BT,d,c)(h):h===null||it(h)||Oi(h)||h!==45&&Cu(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 b5(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(BT,t,a)(u):u===null||it(u)||Oi(u)?t(u):(e.consume(u),o)}function a(u){return u===41&&r++,e.consume(u),o}}function x5(e,t,n){return r;function r(c){return c===33||c===34||c===39||c===41||c===42||c===44||c===46||c===58||c===59||c===63||c===95||c===126?(e.consume(c),r):c===38?(e.consume(c),a):c===93?(e.consume(c),o):c===60||c===null||it(c)||Oi(c)?t(c):n(c)}function o(c){return c===null||c===40||c===91||it(c)||Oi(c)?t(c):r(c)}function a(c){return 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 w5(e,t,n){return r;function r(a){return e.consume(a),o}function o(a){return Wt(a)?n(a):t(a)}}function zT(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||it(e)}function jT(e){return!nn(e)}function $T(e){return!(e===47||ph(e))}function ph(e){return e===43||e===45||e===46||e===95||Wt(e)}function mh(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const _5={tokenize:I5,partial:!0};function S5(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:k5,continuation:{tokenize:N5},exit:O5}},text:{91:{name:"gfmFootnoteCall",tokenize:C5},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:v5,resolveTo:A5}}}}function v5(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 A5(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 C5(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 b=e.exit("gfmFootnoteCallString");return o.includes(Yn(r.sliceSerialize(b)))?(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 k5(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"),b}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 b(x){return x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),o.includes(a)||o.push(a),Qe(e,T,"gfmFootnoteDefinitionWhitespace")):n(x)}function T(x){return t(x)}}function N5(e,t,n){return e.check(Ms,t,e.attempt(_5,t,n))}function O5(e){e.exit("gfmFootnoteDefinition")}function I5(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 R5(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)},b=[["enter",p,c],["enter",u[h][1],c],["exit",u[h][1],c],["enter",E,c]],T=c.parser.constructs.insideSpan.null;T&&xn(b,b.length,0,ku(T,u.slice(h+1,d),c)),xn(b,b.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,b),d=h+b.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 b;function b(x){return h===126&&p[p.length-1][1].type!=="characterEscape"?d(x):(u.enter("strikethroughSequenceTemporary"),T(x))}function T(x){const _=yo(h);if(x===126)return E>1?d(x):(u.consume(x),E++,T);if(E<2&&!n)return d(x);const S=u.exit("strikethroughSequenceTemporary"),A=yo(x);return S._open=!A||A===2&&!!_,S._close=!_||_===2&&!!A,c(x)}}}class P5{constructor(){this.map=[]}add(t,n,r){L5(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 L5(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 D5(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 M5(){return{flow:{null:{name:"table",tokenize:F5,resolveAll:B5}}}}function F5(e,t,n){const r=this;let o=0,a=0,u;return c;function c(U){let W=r.events.length-1;for(;W>-1;){const de=r.events[W][1].type;if(de==="lineEnding"||de==="linePrefix")W--;else break}const te=W>-1?r.events[W][1].type:null,oe=te==="tableHead"||te==="tableRow"?M:d;return oe===M&&r.parser.lazy[r.now().line]?n(U):oe(U)}function d(U){return e.enter("tableHead"),e.enter("tableRow"),h(U)}function h(U){return U===124||(u=!0,a+=1),p(U)}function p(U){return U===null?n(U):Le(U)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(U),e.exit("lineEnding"),T):n(U):Ge(U)?Qe(e,p,"whitespace")(U):(a+=1,u&&(u=!1,o+=1),U===124?(e.enter("tableCellDivider"),e.consume(U),e.exit("tableCellDivider"),u=!0,p):(e.enter("data"),E(U)))}function E(U){return U===null||U===124||it(U)?(e.exit("data"),p(U)):(e.consume(U),U===92?b:E)}function b(U){return U===92||U===124?(e.consume(U),E):E(U)}function T(U){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(U):(e.enter("tableDelimiterRow"),u=!1,Ge(U)?Qe(e,x,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(U):x(U))}function x(U){return U===45||U===58?S(U):U===124?(u=!0,e.enter("tableCellDivider"),e.consume(U),e.exit("tableCellDivider"),_):Y(U)}function _(U){return Ge(U)?Qe(e,S,"whitespace")(U):S(U)}function S(U){return U===58?(a+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(U),e.exit("tableDelimiterMarker"),A):U===45?(a+=1,A(U)):U===null||Le(U)?z(U):Y(U)}function A(U){return U===45?(e.enter("tableDelimiterFiller"),O(U)):Y(U)}function O(U){return U===45?(e.consume(U),O):U===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(U),e.exit("tableDelimiterMarker"),I):(e.exit("tableDelimiterFiller"),I(U))}function I(U){return Ge(U)?Qe(e,z,"whitespace")(U):z(U)}function z(U){return U===124?x(U):U===null||Le(U)?!u||o!==a?Y(U):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(U)):Y(U)}function Y(U){return n(U)}function M(U){return e.enter("tableRow"),Q(U)}function Q(U){return U===124?(e.enter("tableCellDivider"),e.consume(U),e.exit("tableCellDivider"),Q):U===null||Le(U)?(e.exit("tableRow"),t(U)):Ge(U)?Qe(e,Q,"whitespace")(U):(e.enter("data"),Ee(U))}function Ee(U){return U===null||U===124||it(U)?(e.exit("data"),Q(U)):(e.consume(U),U===92?re:Ee)}function re(U){return U===92||U===124?(e.consume(U),Ee):Ee(U)}}function B5(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 b=new P5;for(;++n<e.length;){const T=e[n],x=T[1];T[0]==="enter"?x.type==="tableHead"?(c=!1,d!==0&&(VT(b,t,d,h,p),p=void 0,d=0),h={type:"table",start:Object.assign({},x.start),end:Object.assign({},x.end)},b.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)},b.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=Tl(b,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=Tl(b,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=Tl(b,t,a,o,n,E)):u[1]!==0&&(E=Tl(b,t,u,o,n,E)),o=0):o&&(x.type==="data"||x.type==="tableDelimiterMarker"||x.type==="tableDelimiterFiller")&&(u[3]=n)}for(d!==0&&VT(b,t,d,h,p),b.consume(t.events),n=-1;++n<t.events.length;){const T=t.events[n];T[0]==="enter"&&T[1].type==="table"&&(T[1]._align=D5(t.events,n))}return e}function Tl(e,t,n,r,o,a){const u=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",c="tableContent";n[0]!==0&&(a.end=Object.assign({},qo(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const d=qo(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=qo(t.events,n[2]),p=qo(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 b=t.events[n[2]],T=t.events[n[3]];if(b[1].end=Object.assign({},T[1].end),b[1].type="chunkText",b[1].contentType="text",n[3]>n[2]+1){const 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({},qo(t.events,o)),e.add(o,0,[["exit",a,t]]),a=void 0),a}function VT(e,t,n,r,o){const a=[],u=qo(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 qo(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const U5={name:"tasklistCheck",tokenize:z5};function H5(){return{text:{91:U5}}}function z5(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:j5},t,n)(d):n(d)}}function j5(e,t,n){return Qe(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function $5(e){return ug([p5(),S5(),R5(e),M5(),H5()])}const V5={};function q5(e){const t=this,n=e||V5,r=t.data(),o=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),u=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);o.push($5(n)),a.push(c5()),u.push(d5(n))}const Y5=()=>P.jsx("span",{className:`${ee}-blinking-cursor`,children:P.jsx("svg",{height:"16px",width:"16px",xmlns:"http://www.w3.org/2000/svg",children:P.jsx("circle",{r:"0.45rem",cx:"0.5rem",cy:"0.55rem",fill:"black"})})}),gh=({globalClassName:e,openLinksInNewTab:t,showIsLoading:n,text:r})=>P.jsx(Jg,{remarkPlugins:[q5],rehypePlugins:[cE],components:{h1:({children:o})=>P.jsx("h1",{className:ae(e,`${ee}-header h1`),children:o}),h2:({children:o})=>P.jsx("h2",{className:ae(e,`${ee}-header h2`),children:o}),h3:({children:o})=>P.jsx("h3",{className:ae(e,`${ee}-header h3`),children:o}),ul:({children:o})=>P.jsx("ul",{className:ae(e,`${ee}-ul`),children:o}),ol:({children:o})=>P.jsx("ol",{className:ae(e,`${ee}-ol`),children:o}),li:({children:o})=>P.jsx("li",{className:ae(e,`${ee}-li`),children:o}),a:({href:o,children:a})=>P.jsx(EE,{globalClassName:e,openLinksInNewTab:t,href:o,children:a}),table:({children:o})=>P.jsx("div",{className:ae(e,`${ee}-table-container`),children:P.jsx("table",{className:ae(e,`${ee}-table`),children:o})}),thead:({children:o})=>P.jsx("thead",{className:ae(e,`${ee}-thead`),children:o}),tbody:({children:o})=>P.jsx("tbody",{className:ae(e,`${ee}-tbody`),children:o}),tr:({children:o})=>P.jsx("tr",{className:ae(e,`${ee}-tr`),children:o}),th:({children:o})=>P.jsx("th",{className:ae(e,`${ee}-th`),children:o}),td:({children:o})=>P.jsx("td",{className:ae(e,`${ee}-td`),children:o}),span:({className:o,children:a})=>o===`${ee}-blinking-cursor`?P.jsx(Y5,{}):P.jsx("span",{children:a})},children:r+(n?`<span className='${ee}-blinking-cursor'></span>`:"")}),W5=["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"],G5=3e3,K5=400,Q5=({globalClassName:e,isWidgetStandalone:t,messages:n=W5})=>{const[r,o]=X.useState(0),[a,u]=X.useState(!0);return X.useEffect(()=>{let c;const d=setInterval(()=>{u(!1),c=setTimeout(()=>{o(h=>(h+1)%n.length),u(!0)},K5)},G5);return()=>{clearInterval(d),clearTimeout(c)}},[n.length]),P.jsxs("div",{className:ae(e,`${ee}-connecting-indicator`,t?"standalone":"embedded"),role:"status","aria-label":"Connecting to assistant",children:[P.jsxs("div",{className:`${ee}-connecting-pulse-wrapper`,children:[P.jsx("div",{className:`${ee}-connecting-pulse`}),P.jsx("div",{className:`${ee}-connecting-ring`})]}),P.jsx("span",{className:ae(`${ee}-connecting-text`,a&&`${ee}-connecting-text--visible`),children:n[r]})]})},X5=({shouldShow:e,loadingText:t})=>e?P.jsx("span",{className:`${ee}-processing-text`,children:t}):null,J5=({shouldShow:e})=>e?P.jsxs(P.Fragment,{children:[P.jsx("div",{className:`${ee}-processing-shimmer-bar`}),P.jsx("div",{className:`${ee}-processing-shimmer-bar`}),P.jsx("div",{className:`${ee}-processing-shimmer-bar`})]}):null,Z5=({globalClassName:e,isWidgetStandalone:t,loadingText:n})=>P.jsxs("div",{className:ae(e,`${ee}-processing-indicator`,t?"standalone":"embedded"),role:"status","aria-label":n||"Loading response",children:[P.jsx(X5,{shouldShow:!!n,loadingText:n}),P.jsx(J5,{shouldShow:!n})]}),bl=(e,t)=>{if(typeof e!="number")return null;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t||"USD"}).format(e)}catch(n){return`${e}`}},qT=({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,b=bl(E?d:c,p),T=bl(E?c:h,p);return P.jsxs("div",{className:ae(t,`${ee}-msg-product-card`,{"card-full-width":n}),children:[P.jsx("div",{className:ae(t,`${ee}-msg-product-card__image-wrapper`),children:a&&(u?P.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer","aria-label":`Go to product page for ${o}`,children:P.jsx("img",{className:ae(t,`${ee}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"})}):P.jsx("img",{className:ae(t,`${ee}-msg-product-card__image`),src:a,alt:o||"Product image",loading:"lazy"}))}),P.jsxs("div",{className:ae(t,`${ee}-msg-product-card__content`),children:[u?P.jsx("a",{href:u,target:r?"_blank":"_self",rel:"noopener noreferrer",className:ae(t,`${ee}-msg-product-card__title-link`),"aria-label":`Go to product page for ${o}`,children:o}):P.jsx("p",{className:ae(t,`${ee}-msg-product-card__title`),children:o}),P.jsx("div",{className:ae(t,`${ee}-msg-product-card__price-row`),children:P.jsxs("div",{className:ae(t,`${ee}-msg-product-card__prices`),children:[b&&P.jsx("span",{className:ae(t,`${ee}-msg-product-card__price`),children:b}),T&&P.jsx("span",{className:ae(t,`${ee}-msg-product-card__compare-price`),children:T})]})})]})]})},YT=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}),e8=({title:e,products:t,globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o})=>{if(t.length===1){const a=t[0];return P.jsxs("div",{children:[e&&P.jsx("p",{className:ae(n,`${ee}-product-carousel-title`),children:e}),P.jsx(qT,{product:YT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o,isFullWidth:!o})]})}return P.jsxs("div",{style:{marginBottom:"1rem"},children:[e&&P.jsx("p",{className:ae(n,`${ee}-product-carousel-title`),children:e}),P.jsx(f4,{globalClassName:n,spacing:o?"0.5rem":"6px",ariaLabel:e||"Product recommendations",children:t.map(a=>P.jsx(qT,{product:YT(a),globalClassName:n,openLinksInNewTab:r,isWidgetStandalone:o},a.id))})]})},t8=({content:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{sendMessage:o,loading:a}=ki();return P.jsx(P.Fragment,{children:e.response.map((u,c)=>{var d,h;switch(u.type){case"markdown":return P.jsx(gh,{text:u.data.content,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1},`${u.type}-${c}`);case"product_carousel":return P.jsx(e8,{title:u.data.title,products:u.data.products,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r},`${u.type}-${(d=u.index)!=null?d:c}`);case"suggestions":return P.jsx("div",{style:{marginTop:"0.5rem"},children:P.jsx(D4,{disabled:a,suggestions:u.data.display_text,globalClassName:t,isWidgetStandalone:r,onSuggestionClick:o})},`${u.type}-${(h=u.index)!=null?h:c}`);default:return null}})})},n8=({message:e,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r})=>{const{logger:o}=kt(),a=X.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=X.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 P.jsx("div",{className:ae(t,`${ee}-message`,r?"standalone":"embedded"),children:P.jsx("div",{className:ae(t,`${ee}-user-message`,r?"standalone":"embedded"),children:P.jsxs("div",{className:ae(t,`${ee}-user-message-row`,r?"standalone":"embedded"),children:[P.jsx("span",{className:ae(t,`${ee}-message-icon user-message-icon`,r?"standalone":"embedded"),children:P.jsx(_v,{})}),P.jsx("p",{className:ae(t,`${ee}-user-message-text`,r?"standalone":"embedded"),children:e.content})]})})});case"agent":return P.jsx("div",{className:ae(t,`${ee}-message-group`,r?"standalone":"embedded"),children:P.jsx("div",{className:`${ee}-message-group-child`,children:a?P.jsx(t8,{content:a,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:r}):P.jsx(gh,{text:u,globalClassName:t,openLinksInNewTab:n,showIsLoading:!1})})});case"system":return P.jsx("div",{className:ae(t,`${ee}-message`,r?"standalone":"embedded"),children:P.jsx("p",{className:ae(t,`${ee}-reset-message`),children:e.content})})}},Eh=({isWidgetStandalone:e})=>{const{globalClassName:t,openLinksInNewTab:n}=kt(),{messages:r,streamingContent:o,isAgentTyping:a,loading:u,progressMessage:c}=ki(),d=X.useRef(null),h=r.length>0;return X.useEffect(()=>{var p;(p=d.current)==null||p.scrollIntoView({behavior:"smooth"})},[r,o]),P.jsxs(P.Fragment,{children:[u&&!h&&P.jsx(Q5,{globalClassName:t,isWidgetStandalone:e}),r.map(p=>P.jsx(n8,{message:p,globalClassName:t,openLinksInNewTab:n,isWidgetStandalone:e},p.id)),o&&P.jsx("div",{className:ae(t,`${ee}-message-group`,e?"standalone":"embedded"),children:P.jsx(gh,{text:o,globalClassName:t,openLinksInNewTab:n,showIsLoading:!0})}),h&&(u||a)&&!o&&P.jsx(Z5,{globalClassName:t,isWidgetStandalone:e,loadingText:c}),P.jsx("div",{ref:d})]})},WT=()=>{const{globalClassName:e,themeVariables:t}=kt(),{isAgentTyping:n,sendMessage:r,resetConversation:o}=ki(),a=n;return P.jsxs("div",{className:ae(e,`${ee}-container`,`${ee}-embedded-chat`),style:t,children:[P.jsx("div",{className:ae(e,`${ee}-message-container`,"embedded"),children:P.jsx(Eh,{isWidgetStandalone:!1})}),P.jsx(bf,{componentType:"chat",className:"embedded-chat",isLoading:a,onSubmit:u=>r(u)}),P.jsx("div",{className:ae(`${ee}-embedded-chat-menu`),children:P.jsxs(G6,{componentType:"chat",children:[P.jsx(pT,{componentType:"chat"}),P.jsx(bE,{componentType:"chat",onClearChat:o})]})})]})},GT=e=>{var d;const{children:t,disabled:n}=e,[r,o]=X.useState((d=e.container)==null?void 0:d.current),a=X.useSyncExternalStore(i8,()=>!1,()=>!0),{getRootNode:u}=ml();if(X.useEffect(()=>{o(()=>{var h;return(h=e.container)==null?void 0:h.current})},[e.container]),a||n)return P.jsx(P.Fragment,{children:t});const c=r!=null?r:r8(u);return P.jsx(P.Fragment,{children:X.Children.map(t,h=>Ns.createPortal(h,c))})},r8=e=>{const t=e==null?void 0:e(),n=t.getRootNode();return Fi(n)?n:cr(t).body},i8=()=>()=>{},KT=()=>{const{globalClassName:e,themeVariables:t}=kt(),{mode:n,status:r,dialogPosition:o,isDialogFullHeight:a,dialogWidth:u}=Ci(),{loading:c,isAgentTyping:d,sendMessage:h,resetConversation:p}=ki(),{isOpen:E}=r||{},b=!!r.isOpen,T=n==="standalone",x=d||c,_=()=>{Ai(!1)};return P.jsx(lT,{lazyMount:!0,unmountOnExit:!0,modal:!1,closeOnEscape:!1,closeOnInteractOutside:!1,open:b,children:P.jsx(GT,{children:P.jsx(ih,{className:ae(e,`${ee}-container`,`${ee}-dialog`,o,a&&"full-height"),style:B(B({},t),u&&{width:u}),children:P.jsxs(nh,{className:ae(e,`${ee}-dialog-content`,{standalone:T,embedded:!T}),children:[P.jsx(hT,{componentType:"dialog",onClearChat:p,onClose:_}),P.jsx(rh,{className:ae(e,`${ee}-message-container`,{standalone:T,embedded:!T}),children:P.jsx(Eh,{isWidgetStandalone:T,isOpen:E})}),P.jsx(bf,{componentType:"dialog",isLoading:x,onSubmit:S=>h(S)})]})})})})},QT=()=>{const{globalClassName:e,themeVariables:t}=kt(),{mode:n,status:r,isModalFullscreen:o}=Ci(),{isAgentTyping:a,sendMessage:u,resetConversation:c}=ki(),{isOpen:d}=r||{},h=!!r.isOpen,p=n==="standalone",E=a,b=({open:x})=>{Ai(x)},T=()=>{Ai(!1)};return h?P.jsx(lT,{lazyMount:!0,unmountOnExit:!0,open:h,onOpenChange:b,children:P.jsx(GT,{children:P.jsxs("div",{className:ae(e,`${ee}-modal-container`),style:t,children:[P.jsx(iT,{className:ae(e,`${ee}-modal-backdrop`)}),P.jsx(ih,{className:ae(e,`${ee}-container`,`${ee}-modal`,{fullscreen:o,standalone:p,embedded:!p}),children:P.jsxs(nh,{className:ae(e,`${ee}-modal-content`,{standalone:p,embedded:!p}),children:[P.jsx(hT,{componentType:"modal",onClearChat:c,onClose:T}),P.jsx(rh,{className:ae(e,`${ee}-message-container`,{standalone:p,embedded:!p}),children:P.jsx(Eh,{isWidgetStandalone:p,isOpen:d})}),P.jsx(bf,{componentType:"modal",isLoading:E,onSubmit:x=>u(x)})]})})]})})}):null},o8=()=>{const e=Ci(),{status:{type:t,isMinimized:n}}=e||{status:{}};return n?P.jsx(bv,{}):t==="dialog"?P.jsx(KT,{}):t==="modal"?P.jsx(QT,{}):P.jsx(WT,{})},yh=e=>P.jsx(E0,se(B({},e),{children:P.jsx(o8,{})}));var xl={},XT;function s8(){if(XT)return xl;XT=1;var e=w0();return xl.createRoot=e.createRoot,xl.hydrateRoot=e.hydrateRoot,xl}var JT=s8();const a8=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 b of E.addedNodes)b.nodeType===Node.ELEMENT_NODE&&b.id===e&&(vi(!0,"log","Target element found, rendering Messaging Widget"),h.disconnect(),clearTimeout(a),(p=JT.createRoot(b))==null||p.render(P.jsx(yh,se(B({},n),{mode:"messaging"}))))},c=new MutationObserver(u);return c.observe(document.body,{childList:!0,subtree:!0}),a=setTimeout(()=>{c.disconnect(),vi(!0,"error",`Element with id: ${e} not found within ${t} milliseconds, stopping observation`)},t),c},u8=r=>{var o=r,{timeout:e,elementId:t}=o,n=sn(o,["timeout","elementId"]);if(!n.messagingConfig){vi(!0,"error","Messaging Widget requires messagingConfig");return}if(!n.messagingConfig.scrt2Url||!n.messagingConfig.orgId||!n.messagingConfig.esDeveloperName){vi(!0,"error","Messaging Widget requires messagingConfig.scrt2Url, messagingConfig.orgId, and messagingConfig.esDeveloperName");return}const a=document.getElementById(t);if(!a){vi(!0,"warn","Container element not found for id:",t),vi(!0,"warn","Beginning observation for element"),a8(B({elementId:t,timeout:e},n));return}JT.createRoot(a).render(P.jsx(yh,se(B({},n),{mode:"messaging"})))},l8={components:{setEntryType:m0,toggleWidgetOpen:Ai,toggleWidgetMinimized:bu,toggleModalFullscreen:gd,setWidgetType:xu,setWidgetDialogPosition:Ed}};Oe.AgentForceWidget=yh,Oe.AgentforceWidgetProvider=E0,Oe.MessagingDialog=KT,Oe.MessagingEmbed=WT,Oe.MessagingModal=QT,Oe.MessagingProvider=p0,Oe.eventHandlers=l8,Oe.injectMessagingWidget=u8,Oe.useMessaging=ki,Object.defineProperty(Oe,Symbol.toStringTag,{value:"Module"})}));
|