@farris/x-ui 0.0.3 → 0.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,99 +1,99 @@
1
- (function(T,i){typeof exports=="object"&&typeof module<"u"?i(exports,require("vue"),require("@farris/x-surface"),require("@a2ui/web_core/v0_9")):typeof define=="function"&&define.amd?define(["exports","vue","@farris/x-surface","@a2ui/web_core/v0_9"],i):(T=typeof globalThis<"u"?globalThis:T||self,i(T.FarrisX={},T.vue,T.xSurface,T.v0_9))})(this,function(T,i,ye,un){"use strict";var Sp=Object.defineProperty;var Bc=T=>{throw TypeError(T)};var Fp=(T,i,ye)=>i in T?Sp(T,i,{enumerable:!0,configurable:!0,writable:!0,value:ye}):T[i]=ye;var fe=(T,i,ye)=>Fp(T,typeof i!="symbol"?i+"":i,ye),Qo=(T,i,ye)=>i.has(T)||Bc("Cannot "+ye);var A=(T,i,ye)=>(Qo(T,i,"read from private field"),ye?ye.call(T):i.get(T)),ie=(T,i,ye)=>i.has(T)?Bc("Cannot add the same private member more than once"):i instanceof WeakSet?i.add(T):i.set(T,ye),ee=(T,i,ye,un)=>(Qo(T,i,"write to private field"),un?un.call(T,ye):i.set(T,ye),ye),X=(T,i,ye)=>(Qo(T,i,"access private method"),ye);var Au=(T,i,ye,un)=>({set _(Er){ee(T,i,Er,ye)},get _(){return A(T,i,un)}});var xc,kt,kn,wc,vc,nt,Ze,ot,en,it,Cn,En,at,ke,st,we,he,ne,ze,Ye,Ie,Se,ct,Fe,lt,dt,Ke,Qe,ft,jt,je,_n,G,Jo,tn,_t,wr,Je,zc,nn,Sn,vr,$t,Ut,ei,ku,Cu,pe,ti,Cr,Wt,ni,Fn;const Er={content:{type:Object,required:!0},onOpen:{type:Function,default:void 0}},on=i.defineComponent({name:"AppPreviewMessage",props:Er,setup(e){const t=i.ref(!1);function n(){var p;const a=(p=e.content)==null?void 0:p.appConfig;if(!a)return"";const s=a.ws??"",c=a.appPath??"",d=a.appObjectId??"";return`${a.appBuilderUri??"/apps/platform/development-platform/ide/app-builder/index.html"}?path=${c}&boId=${d}&ws=${s}&version=2.0#/home`}function u(){var s,c;const a=(s=e.content)==null?void 0:s.previewConfig;a&&e.onOpen&&e.onOpen({...a,title:a.title??((c=e.content)==null?void 0:c.appName)})}function o(a){const s=a.target;s!=null&&s.closest(".f-chat-app-preview-open-btn")||a.preventDefault()}function r(a){a.stopPropagation();const s=n();s&&window.open(s,"_blank")}return()=>{const a=e.content;if(!a)return null;const{message:s,appName:c,createdDatetime:d}=a;return i.createVNode("div",{class:"f-chat-message-app-preview"},[i.createVNode("div",{class:"f-chat-app-preview-message"},[s]),i.createVNode("div",{class:"f-chat-app-preview-card",onMouseenter:()=>t.value=!0,onMouseleave:()=>t.value=!1,onMousedown:o,onClick:u,role:"button",tabindex:0,onKeydown:f=>f.key==="Enter"&&u()},[i.createVNode("div",{class:"f-chat-app-preview-card-left"},[i.createVNode("span",{class:"f-chat-app-preview-icon"},[i.createVNode("i",{class:"f-icon f-icon-page-title-administer"},null)])]),i.createVNode("div",{class:"f-chat-app-preview-card-middle"},[i.createVNode("div",{class:"f-chat-app-preview-app-name"},[c]),i.createVNode("div",{class:"f-chat-app-preview-datetime"},[d])]),i.createVNode("div",{class:"f-chat-app-preview-card-right"},[i.createVNode("div",{class:"f-chat-app-preview-action-area"},null),t.value&&i.createVNode("button",{type:"button",class:"f-chat-app-preview-open-btn",onClick:r,title:"在新页签中打开","aria-label":"在新页签中打开"},[i.createVNode("i",{class:"f-icon f-icon-folder-open"},null)])])])])}}});on.install=e=>{e.component(on.name,on)};const ri={content:{type:Object,required:!0},outputMode:{type:String,default:"streaming"},classNames:{type:Object,default:()=>({})},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},header:{type:String,default:"sender"},placement:{type:String,default:"start"},showAvatar:{type:Boolean,default:!0},styles:{type:Object,default:()=>({})},attachments:{type:Array,default:()=>[]},onPreview:{type:Function,default:void 0},onUserAuthConfirm:{type:Function,default:void 0},compositeTailRender:{type:Function,default:void 0},onDynamicComponentsDetected:{type:Function,default:void 0},onShowDynamicComponent:{type:Function,default:void 0}},Eu={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},jc="/api/runtime/attachment";function Hc(){try{const e=Eu==null?void 0:Eu.VITE_ATTACHMENT_API_BASE;if(typeof e=="string"&&e.trim()!=="")return e.replace(/\/+$/,"")}catch{}return""}function $c(e){var n;const t=e.trim();return t.startsWith("http://")||t.startsWith("https://")?t:typeof window<"u"&&((n=window.location)!=null&&n.origin)&&t.startsWith("/")?`${window.location.origin}${t}`:t}function Uc(e){return`${jc}/${encodeURIComponent(e)}/download`}function _u(e){const t=String(e??"").trim();if(!t)return"";const n=Uc(t),u=Hc();return u?`${u}${n}`:n}function ui(e){const t=e.trim().match(/\/api\/runtime\/attachment\/([^/]+)\/download(?:\?|#|$)/i);if(!(t!=null&&t[1]))return"";try{return decodeURIComponent(t[1]).trim()}catch{return t[1].trim()}}function an(e){const t=String(e.fileId??"").trim();if(t)return _u(t);const n=String(e.url??"").trim();if(!n)return;const u=ui(n);if(u)return _u(u);if(n.startsWith("http://")||n.startsWith("https://")||n.startsWith("/"))return n}async function _r(e,t){const n=String(t??"").replace(/[/\\]/g,"_").trim()||"download",u=$c(e);try{const o=await fetch(u,{credentials:"include",mode:"cors"});if(!o.ok)throw new Error(`download_http_${o.status}`);const r=await o.blob(),a=URL.createObjectURL(r),s=document.createElement("a");s.href=a,s.download=n,s.rel="noopener noreferrer",document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(a)}catch{const o=document.createElement("a");o.href=u,o.target="_blank",o.rel="noopener noreferrer",document.body.appendChild(o),o.click(),document.body.removeChild(o)}}function be(e,t){return t&&(typeof t=="string"?t.split(" ").filter(Boolean).forEach(u=>{e[u]=!0}):Array.isArray(t)?t.forEach(n=>{n&&(e[n]=!0)}):typeof t=="object"&&Object.entries(t).forEach(([n,u])=>{n&&u&&(e[n]=!0)})),e}function Ae(e,t){return t&&(typeof t=="string"?t.split(";").filter(Boolean).forEach(u=>{var r,a;const o=u.split(":");if(o.length>=2&&((r=o[0])!=null&&r.trim())&&((a=o[1])!=null&&a.trim())){const s=o[0].trim(),c=o.slice(1).join(":").trim();e[s]=c}}):typeof t=="object"&&Object.entries(t).forEach(([n,u])=>{n&&u!==void 0&&u!==null&&(e[n]=u)})),e}function In(e){return e||null}function oi(e){return e?/\.(jpg|jpeg|png|gif|svg|webp|bmp|ico)$/i.test(e)||e.startsWith("http")||e.startsWith("data:image"):!1}function Sr(e){return e?typeof e!="string"?e:oi(e)?i.h("img",{src:e,alt:"icon",class:"fx-prompt--item-icon-image",onError:t=>{const n=t.target;n.style.display="none",n.parentElement.innerHTML='<i class="f-icon f-icon-warning"></i>'}}):e.includes("f-icon")||e.includes("icon-")?i.h("i",{class:e}):e:null}function ii(e,t,n,u={}){const{charInterval:o=30}=u,r=i.ref({});let a=[],s=new Set;const c=()=>typeof t=="function"?t():t.value,d=()=>typeof n=="function"?n():n.value,f=()=>{a.forEach(h=>clearInterval(h)),a=[]},l=()=>{f(),r.value={},s.clear()},p=()=>{f(),r.value={},s.clear()},m=()=>{const h=e();if(!h||Object.keys(h).length===0){r.value={};return}if(!d()){r.value={...h},s=new Set(Object.keys(h));return}const y=Object.keys(h);y.forEach(b=>{r.value.hasOwnProperty(b)||(r.value[b]="")});const x=y.filter(b=>!s.has(b));if(x.length===0)return;let v=0;const g=()=>{var _;if(v>=x.length)return;const b=x[v],w=h[b];if(!w){s.add(b),v++,g();return}let k=((_=r.value[b])==null?void 0:_.length)||0;const S=setInterval(()=>{k<w.length?(r.value={...r.value,[b]:w.slice(0,k+1)},k++):(clearInterval(S),a=a.filter(E=>E!==S),s.add(b),v++,g())},o);a.push(S)};g()};return i.watch(()=>e(),()=>{c()&&m()},{immediate:!0}),i.watch(n,()=>{p(),c()&&m()}),i.watch(t,h=>{h?m():l()}),i.onMounted(()=>{c()&&m()}),{displayContent:r}}function Fr(){const e=i.reactive({}),t=[],n=i.ref(null);let u=null;const o=30,r=h=>{const y=e[h];return!y||y.displayedLength>=y.rawValue.length},a=i.computed(()=>Object.keys(e).length===0?!1:Object.keys(e).every(h=>r(h))),s=()=>{for(const h of t)if(!r(h))return h;return null},c=()=>{if(!n.value&&(n.value=s(),!n.value)){d();return}const h=e[n.value];h&&(h.displayedLength<h.rawValue.length?(h.displayedLength++,h.displayedValue=h.rawValue.slice(0,h.displayedLength),h.isStreaming=!0):(h.isStreaming=!1,h.displayedValue=h.rawValue,n.value=s(),n.value||d()))},d=()=>{u&&(clearInterval(u),u=null)},f=()=>{u||(u=setInterval(c,o))},l=()=>{d(),Object.keys(e).forEach(h=>{delete e[h]}),t.length=0,n.value=null},p=(h,y)=>{if(e[h]){m(h,y);return}t.push(h),e[h]={rawValue:y??"",displayedLength:0,isStreaming:!1,displayedValue:""},u||(!n.value||n.value===h)&&f()},m=(h,y)=>{const x=e[h];if(!x){p(h,y);return}x.rawValue=y??"",!u&&!r(h)&&(!n.value||n.value===h)&&f()};return i.onUnmounted(()=>{d()}),{propertyStates:e,currentProperty:n,get isAnyStreaming(){return Object.values(e).some(h=>h.isStreaming)},isAllDone:a,startStreaming:f,reset:l,registerProperty:p,updatePropertyValue:m}}function Su(){const e=i.ref(null),t=i.ref(0),n=i.ref(!1);let u=null;const o=()=>{e.value=Date.now(),n.value=!0,u=setInterval(()=>{e.value&&(t.value=Math.floor((Date.now()-e.value)/1e3))},1e3)},r=()=>{u&&(clearInterval(u),u=null),e.value&&(t.value=Math.floor((Date.now()-e.value)/1e3))};return{elapsedSeconds:t,hasEverStarted:n,start:o,stop:r,reset:()=>{r(),e.value=null,t.value=0,n.value=!1}}}function Wc(e,t){const n=i.computed(()=>{var o;return Ae({},(o=e.styles)==null?void 0:o.header)});function u(){return t.slots.header&&i.createVNode("div",{class:`f-chat-bubble-header ${e.placement}`,style:n.value},[t.slots.header()])}return{renderHeader:u}}function Gc(e,t){var r;const n=i.ref(((r=e.content)==null?void 0:r.sender)??"发送人"),u=i.computed(()=>{var a;return Ae({},(a=e.styles)==null?void 0:a.header)});function o(){return i.createVNode("div",{class:`f-chat-bubble-header ${e.placement}`,style:u.value},[n.value])}return{renderHeader:o}}const qc={file:{type:Object,required:!0},customStyle:{type:Object,default:()=>({})},onPreviewFile:{type:Function,default:void 0},onBatchPreviewFile:{type:Function,default:void 0}},Xc={attachments:{type:Array,default:()=>[]},enableBatchPreview:{type:Boolean,default:!1},enableFixedWidth:{type:Boolean,default:!1},onPreview:{type:Function,default:void 0},onBatchPreview:{type:Function,default:void 0}};function Zc(){return{getFileIcon:u=>({pdf:"file-type-pdf",doc:"file-type-doc",docx:"file-type-doc",xls:"file-type-xls",xlsx:"file-type-xls",ppt:"file-type-ppt",pptx:"file-type-ppt",txt:"file-type-txt",zip:"file-type-zip",rar:"file-type-zip",image:"file-type-img",img:"file-type-img",md:"file-type-md",video:"file-type-any",audio:"file-type-any"})[u.toLowerCase()]||"file-type-any",formatFileName:u=>(u==null?void 0:u.replace(/\.[^.]+$/,""))??"",formatFileSize:u=>u<1024?u+" B":u<1048576?(u/1024).toFixed(1)+" KB":(u/1048576).toFixed(1)+" MB"}}const ai=i.defineComponent({name:"FXBubbleAttachment",props:Xc,emits:["preview","batchPreview"],setup(e,t){const n=i.computed(()=>e.attachments??[]),u=i.computed(()=>{var m;return((m=n.value)==null?void 0:m.length)>0}),{getFileIcon:o,formatFileName:r,formatFileSize:a}=Zc(),s=i.computed(()=>({"f-chat-bubble-attachment-info":!0,"f-utils-fill":e.enableFixedWidth})),c=i.computed(()=>({"f-chat-bubble-attachment-name":!0,"name-tip":e.enableFixedWidth})),d=i.computed(()=>e.enableFixedWidth?{width:"200px"}:{flex:"0 0 calc(50% - 4px)"});function f(m,h){t.emit("preview",h)}async function l(m,h){m.stopPropagation(),m.preventDefault();const y=an(h);y&&await _r(y,h.name)}function p(m){t.emit("batchPreview",n.value)}return()=>u.value?i.createVNode("div",{class:"f-chat-bubble-attachments"},[n.value.map((m,h)=>{const y=an(m);return i.createVNode("div",{class:"f-chat-bubble-attachment-item",style:d.value,key:h},[i.createVNode("div",{class:"f-chat-bubble-attachment-main",role:"presentation",onClick:x=>f(x,m)},[i.createVNode("span",{class:`f-chat-bubble-attachment-icon ${o(m.type)}`},null),i.createVNode("div",{class:s.value},[i.createVNode("span",{class:c.value,title:m.name},[r(m.name)]),m.size?i.createVNode("span",{class:"f-chat-bubble-attachment-size"},[a(m.size)]):null])]),y?i.createVNode("button",{type:"button",class:"f-chat-bubble-attachment-download-btn","aria-label":"下载附件",title:"下载",onClick:x=>l(x,m)},[i.createVNode("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","aria-hidden":"true"},[i.createVNode("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("polyline",{points:"7 10 12 15 17 10","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("line",{x1:"12",y1:"15",x2:"12",y2:"3","stroke-linecap":"round","stroke-linejoin":"round"},null)])]):null])}),e.enableBatchPreview&&i.createVNode("div",{class:"f-chat-bubble-attachment-preview-btn",onClick:p},[i.createVNode("span",{class:"f-chat-bubble-attachment-preview-btn-text"},[i.createTextVNode("查看全部文件")]),i.createVNode("i",{class:"f-icon f-icon-sort-asc-sm",style:{transform:"rotate(90deg)"}},null)])]):null}}),Yc=i.defineComponent({name:"FXBubbleFileContentFooter",props:qc,setup(e,t){const n=i.computed(()=>e.file?Array.isArray(e.file)?[...e.file]:[e.file]:[]);return Ae({},e.customStyle),()=>i.createVNode(ai,{attachments:n.value,onPreview:u=>{var o;return(o=e.onPreviewFile)==null?void 0:o.call(e,u)},onBatchPreview:u=>{var o;return(o=e.onBatchPreviewFile)==null?void 0:o.call(e,u)}},null)}}),Kc={pageUrl:{type:String,required:!0},customStyle:{type:Object,default:()=>({})},onNavigate:{type:Function,default:void 0}},Qc=i.defineComponent({name:"FXBubblePageContentFooter",props:Kc,setup(e,t){const n=i.ref(),u=i.computed(()=>{var a,s;const r={width:"100%",height:"100%",border:"none"};return(a=e.customStyle)!=null&&a.width&&(r.width=e.customStyle.width),(s=e.customStyle)!=null&&s.height&&(r.height=`${e.customStyle.height}px`),r}),o=r=>{var a,s;((a=r.data)==null?void 0:a.type)==="navigation"&&((s=r.data)!=null&&s.url)&&e.onNavigate&&e.onNavigate(r.data.url)};return i.onMounted(()=>{window.addEventListener("message",o)}),i.onUnmounted(()=>{window.removeEventListener("message",o)}),()=>i.createVNode("iframe",{ref:n,src:e.pageUrl,style:u.value,scrolling:"auto"},null)}});function si(){function e(o,r){const{fileContent:a,height:s,width:c}=o;return{file:a,customStyle:{width:c||"100%",height:s||"100%"},onPreviewFile:r==null?void 0:r.onPreviewFile,onBatchPreviewFile:r==null?void 0:r.onBatchPreviewFile}}function t(o,r){const{pageUrl:a,height:s,width:c}=o;return{pageUrl:a,customStyle:{width:c||"100%",height:s||"100%"},onNavigate:r==null?void 0:r.onNavigate}}function n(o,r){const a=e(o,r);return i.h(Yc,a)}function u(o,r){const a=t(o,r);return i.h(Qc,a)}return{renderFileEmbeddedContent:n,renderPageEmbeddedContent:u}}const Jc={title:{type:String,default:""},subtitle:{type:String,default:""},text:{type:String,default:""},textFormat:{type:String,default:"plain"},placement:{type:String,default:"start"},onDynamicComponentsDetected:{type:Function,default:void 0},onShowDynamicComponent:{type:Function,default:void 0}};function el(e){return e.replace(/```\s*\n+\s*assistant-widget/g,"``` assistant-widget").replace(/```\s*\n+\s*A2UI/g,"``` A2UI")}function Fu(e){if(!e)return!1;const t=/^```\s*(?:assistant-widget|A2UI)[\s\S]*?```$/,n=/^```\s*(?:assistant-widget|A2UI)/;return t.test(e)||n.test(e)}function tl(e){if(!e)return[];const t=/(```[\s]*(?:assistant-widget|A2UI)[\s\S]*?```)/g,n=[];let u=0,o;for(;(o=t.exec(e))!==null;){if(o.index>u){const r=e.slice(u,o.index),a=/(```[\s]*(?:assistant-widget|A2UI))/,s=r.match(a);if(s){const c=r.indexOf(s[0]);c>0&&n.push(r.slice(0,c)),n.push(r.slice(c));const d=r.slice(c+s[0].length);d.trim().length>0&&n.push(d)}else n.push(r)}n.push(el(o[0])),u=o.index+o[0].length}if(u<e.length){const r=e.slice(u),a=/(```[\s]*(?:assistant-widget|A2UI))/,s=r.match(a);if(s){const c=r.indexOf(s[0]);c>0&&n.push(r.slice(0,c)),n.push(r.slice(c))}else n.push(r)}return n.filter(r=>r.trim().length>0)}function ci(e){const t=e.replace("``` assistant-widget","").replace("```","").trim();try{return JSON.parse(t)}catch(n){return console.error("Failed to parse JSON:",n),null}}function nl(e){const t=e.replace("```A2UI","").replace("```","").trim();try{const n=JSON.parse(t);return n!=null&&n.components&&Array.isArray(n.components)&&n.components.length>0&&n.components[0].component!=="Card"&&(n.components[0].id="x01",n.components.unshift({id:"root",component:"Card",align:"center",child:"x01"})),n}catch(n){return console.error("Failed to parse JSON:",n),null}}function rl(e){var n;const t=ci(e);return((n=t==null?void 0:t.renderer)==null?void 0:n.widgetImplOptions)||{}}const li={};function ul(e){let t=li[e];if(t)return t;t=li[e]=[];for(let n=0;n<128;n++){const u=String.fromCharCode(n);t.push(u)}for(let n=0;n<e.length;n++){const u=e.charCodeAt(n);t[u]="%"+("0"+u.toString(16).toUpperCase()).slice(-2)}return t}function sn(e,t){typeof t!="string"&&(t=sn.defaultChars);const n=ul(t);return e.replace(/(%[a-f0-9]{2})+/gi,function(u){let o="";for(let r=0,a=u.length;r<a;r+=3){const s=parseInt(u.slice(r+1,r+3),16);if(s<128){o+=n[s];continue}if((s&224)===192&&r+3<a){const c=parseInt(u.slice(r+4,r+6),16);if((c&192)===128){const d=s<<6&1984|c&63;d<128?o+="��":o+=String.fromCharCode(d),r+=3;continue}}if((s&240)===224&&r+6<a){const c=parseInt(u.slice(r+4,r+6),16),d=parseInt(u.slice(r+7,r+9),16);if((c&192)===128&&(d&192)===128){const f=s<<12&61440|c<<6&4032|d&63;f<2048||f>=55296&&f<=57343?o+="���":o+=String.fromCharCode(f),r+=6;continue}}if((s&248)===240&&r+9<a){const c=parseInt(u.slice(r+4,r+6),16),d=parseInt(u.slice(r+7,r+9),16),f=parseInt(u.slice(r+10,r+12),16);if((c&192)===128&&(d&192)===128&&(f&192)===128){let l=s<<18&1835008|c<<12&258048|d<<6&4032|f&63;l<65536||l>1114111?o+="����":(l-=65536,o+=String.fromCharCode(55296+(l>>10),56320+(l&1023))),r+=9;continue}}o+="�"}return o})}sn.defaultChars=";/?:@&=+$,#",sn.componentChars="";const di={};function ol(e){let t=di[e];if(t)return t;t=di[e]=[];for(let n=0;n<128;n++){const u=String.fromCharCode(n);/^[0-9a-z]$/i.test(u)?t.push(u):t.push("%"+("0"+n.toString(16).toUpperCase()).slice(-2))}for(let n=0;n<e.length;n++)t[e.charCodeAt(n)]=e[n];return t}function Pn(e,t,n){typeof t!="string"&&(n=t,t=Pn.defaultChars),typeof n>"u"&&(n=!0);const u=ol(t);let o="";for(let r=0,a=e.length;r<a;r++){const s=e.charCodeAt(r);if(n&&s===37&&r+2<a&&/^[0-9a-f]{2}$/i.test(e.slice(r+1,r+3))){o+=e.slice(r,r+3),r+=2;continue}if(s<128){o+=u[s];continue}if(s>=55296&&s<=57343){if(s>=55296&&s<=56319&&r+1<a){const c=e.charCodeAt(r+1);if(c>=56320&&c<=57343){o+=encodeURIComponent(e[r]+e[r+1]),r++;continue}}o+="%EF%BF%BD";continue}o+=encodeURIComponent(e[r])}return o}Pn.defaultChars=";/?:@&=+$,-_.!~*'()#",Pn.componentChars="-_.!~*'()";function Du(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&e.hostname.indexOf(":")!==-1?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t}function Dr(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}const il=/^([a-z0-9.+-]+:)/i,al=/:[0-9]*$/,sl=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,cl=["<",">",'"',"`"," ","\r",`
2
- `," "],ll=["{","}","|","\\","^","`"].concat(cl),dl=["'"].concat(ll),fi=["%","/","?",";","#"].concat(dl),hi=["/","?","#"],fl=255,pi=/^[+a-z0-9A-Z_-]{0,63}$/,hl=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,mi={javascript:!0,"javascript:":!0},gi={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};function Tu(e,t){if(e&&e instanceof Dr)return e;const n=new Dr;return n.parse(e,t),n}Dr.prototype.parse=function(e,t){let n,u,o,r=e;if(r=r.trim(),!t&&e.split("#").length===1){const d=sl.exec(r);if(d)return this.pathname=d[1],d[2]&&(this.search=d[2]),this}let a=il.exec(r);if(a&&(a=a[0],n=a.toLowerCase(),this.protocol=a,r=r.substr(a.length)),(t||a||r.match(/^\/\/[^@\/]+@[^@\/]+/))&&(o=r.substr(0,2)==="//",o&&!(a&&mi[a])&&(r=r.substr(2),this.slashes=!0)),!mi[a]&&(o||a&&!gi[a])){let d=-1;for(let h=0;h<hi.length;h++)u=r.indexOf(hi[h]),u!==-1&&(d===-1||u<d)&&(d=u);let f,l;d===-1?l=r.lastIndexOf("@"):l=r.lastIndexOf("@",d),l!==-1&&(f=r.slice(0,l),r=r.slice(l+1),this.auth=f),d=-1;for(let h=0;h<fi.length;h++)u=r.indexOf(fi[h]),u!==-1&&(d===-1||u<d)&&(d=u);d===-1&&(d=r.length),r[d-1]===":"&&d--;const p=r.slice(0,d);r=r.slice(d),this.parseHost(p),this.hostname=this.hostname||"";const m=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!m){const h=this.hostname.split(/\./);for(let y=0,x=h.length;y<x;y++){const v=h[y];if(v&&!v.match(pi)){let g="";for(let b=0,w=v.length;b<w;b++)v.charCodeAt(b)>127?g+="x":g+=v[b];if(!g.match(pi)){const b=h.slice(0,y),w=h.slice(y+1),k=v.match(hl);k&&(b.push(k[1]),w.unshift(k[2])),w.length&&(r=w.join(".")+r),this.hostname=b.join(".");break}}}}this.hostname.length>fl&&(this.hostname=""),m&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}const s=r.indexOf("#");s!==-1&&(this.hash=r.substr(s),r=r.slice(0,s));const c=r.indexOf("?");return c!==-1&&(this.search=r.substr(c),r=r.slice(0,c)),r&&(this.pathname=r),gi[n]&&this.hostname&&!this.pathname&&(this.pathname=""),this},Dr.prototype.parseHost=function(e){let t=al.exec(e);t&&(t=t[0],t!==":"&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};const pl=Object.freeze(Object.defineProperty({__proto__:null,decode:sn,encode:Pn,format:Du,parse:Tu},Symbol.toStringTag,{value:"Module"})),bi=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,yi=/[\0-\x1F\x7F-\x9F]/,ml=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,Nu=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,xi=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/,wi=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,gl=Object.freeze(Object.defineProperty({__proto__:null,Any:bi,Cc:yi,Cf:ml,P:Nu,S:xi,Z:wi},Symbol.toStringTag,{value:"Module"})),bl=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),yl=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var Lu;const xl=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]]),wl=(Lu=String.fromCodePoint)!==null&&Lu!==void 0?Lu:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function vl(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=xl.get(e))!==null&&t!==void 0?t:e}var Ee;(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"})(Ee||(Ee={}));const Al=32;var Nt;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Nt||(Nt={}));function Ou(e){return e>=Ee.ZERO&&e<=Ee.NINE}function kl(e){return e>=Ee.UPPER_A&&e<=Ee.UPPER_F||e>=Ee.LOWER_A&&e<=Ee.LOWER_F}function Cl(e){return e>=Ee.UPPER_A&&e<=Ee.UPPER_Z||e>=Ee.LOWER_A&&e<=Ee.LOWER_Z||Ou(e)}function El(e){return e===Ee.EQUALS||Cl(e)}var _e;(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"})(_e||(_e={}));var Lt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Lt||(Lt={}));class _l{constructor(t,n,u){this.decodeTree=t,this.emitCodePoint=n,this.errors=u,this.state=_e.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Lt.Strict}startEntity(t){this.decodeMode=t,this.state=_e.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case _e.EntityStart:return t.charCodeAt(n)===Ee.NUM?(this.state=_e.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=_e.NamedEntity,this.stateNamedEntity(t,n));case _e.NumericStart:return this.stateNumericStart(t,n);case _e.NumericDecimal:return this.stateNumericDecimal(t,n);case _e.NumericHex:return this.stateNumericHex(t,n);case _e.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|Al)===Ee.LOWER_X?(this.state=_e.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=_e.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,u,o){if(n!==u){const r=u-n;this.result=this.result*Math.pow(o,r)+parseInt(t.substr(n,r),o),this.consumed+=r}}stateNumericHex(t,n){const u=n;for(;n<t.length;){const o=t.charCodeAt(n);if(Ou(o)||kl(o))n+=1;else return this.addToNumericResult(t,u,n,16),this.emitNumericEntity(o,3)}return this.addToNumericResult(t,u,n,16),-1}stateNumericDecimal(t,n){const u=n;for(;n<t.length;){const o=t.charCodeAt(n);if(Ou(o))n+=1;else return this.addToNumericResult(t,u,n,10),this.emitNumericEntity(o,2)}return this.addToNumericResult(t,u,n,10),-1}emitNumericEntity(t,n){var u;if(this.consumed<=n)return(u=this.errors)===null||u===void 0||u.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===Ee.SEMI)this.consumed+=1;else if(this.decodeMode===Lt.Strict)return 0;return this.emitCodePoint(vl(this.result),this.consumed),this.errors&&(t!==Ee.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:u}=this;let o=u[this.treeIndex],r=(o&Nt.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const a=t.charCodeAt(n);if(this.treeIndex=Sl(u,o,this.treeIndex+Math.max(1,r),a),this.treeIndex<0)return this.result===0||this.decodeMode===Lt.Attribute&&(r===0||El(a))?0:this.emitNotTerminatedNamedEntity();if(o=u[this.treeIndex],r=(o&Nt.VALUE_LENGTH)>>14,r!==0){if(a===Ee.SEMI)return this.emitNamedEntityData(this.treeIndex,r,this.consumed+this.excess);this.decodeMode!==Lt.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:u}=this,o=(u[n]&Nt.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,o,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,u){const{decodeTree:o}=this;return this.emitCodePoint(n===1?o[t]&~Nt.VALUE_LENGTH:o[t+1],u),n===3&&this.emitCodePoint(o[t+2],u),u}end(){var t;switch(this.state){case _e.NamedEntity:return this.result!==0&&(this.decodeMode!==Lt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case _e.NumericDecimal:return this.emitNumericEntity(0,2);case _e.NumericHex:return this.emitNumericEntity(0,3);case _e.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case _e.EntityStart:return 0}}}function vi(e){let t="";const n=new _l(e,u=>t+=wl(u));return function(o,r){let a=0,s=0;for(;(s=o.indexOf("&",s))>=0;){t+=o.slice(a,s),n.startEntity(r);const d=n.write(o,s+1);if(d<0){a=s+n.end();break}a=s+d,s=d===0?a+1:a}const c=t+o.slice(a);return t="",c}}function Sl(e,t,n,u){const o=(t&Nt.BRANCH_LENGTH)>>7,r=t&Nt.JUMP_TABLE;if(o===0)return r!==0&&u===r?n:-1;if(r){const c=u-r;return c<0||c>=o?-1:e[n+c]-1}let a=n,s=a+o-1;for(;a<=s;){const c=a+s>>>1,d=e[c];if(d<u)a=c+1;else if(d>u)s=c-1;else return e[c+o]}return-1}const Fl=vi(bl);vi(yl);function Ai(e,t=Lt.Legacy){return Fl(e,t)}function Dl(e){return Object.prototype.toString.call(e)}function Iu(e){return Dl(e)==="[object String]"}const Tl=Object.prototype.hasOwnProperty;function Nl(e,t){return Tl.call(e,t)}function Tr(e){return Array.prototype.slice.call(arguments,1).forEach(function(n){if(n){if(typeof n!="object")throw new TypeError(n+"must be object");Object.keys(n).forEach(function(u){e[u]=n[u]})}}),e}function ki(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))}function Pu(e){return!(e>=55296&&e<=57343||e>=64976&&e<=65007||(e&65535)===65535||(e&65535)===65534||e>=0&&e<=8||e===11||e>=14&&e<=31||e>=127&&e<=159||e>1114111)}function Nr(e){if(e>65535){e-=65536;const t=55296+(e>>10),n=56320+(e&1023);return String.fromCharCode(t,n)}return String.fromCharCode(e)}const Ci=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,Ll=/&([a-z#][a-z0-9]{1,31});/gi,Ol=new RegExp(Ci.source+"|"+Ll.source,"gi"),Il=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function Pl(e,t){if(t.charCodeAt(0)===35&&Il.test(t)){const u=t[1].toLowerCase()==="x"?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return Pu(u)?Nr(u):e}const n=Ai(e);return n!==e?n:e}function Rl(e){return e.indexOf("\\")<0?e:e.replace(Ci,"$1")}function cn(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(Ol,function(t,n,u){return n||Pl(t,u)})}const Vl=/[&<>"]/,Ml=/[&<>"]/g,Bl={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;"};function zl(e){return Bl[e]}function Ot(e){return Vl.test(e)?e.replace(Ml,zl):e}const jl=/[.?*+^$[\]\\(){}|-]/g;function Hl(e){return e.replace(jl,"\\$&")}function le(e){switch(e){case 9:case 32:return!0}return!1}function Rn(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function Vn(e){return Nu.test(e)||xi.test(e)}function Mn(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function Lr(e){return e=e.trim().replace(/\s+/g," "),"ẞ".toLowerCase()==="Ṿ"&&(e=e.replace(/ẞ/g,"ß")),e.toLowerCase().toUpperCase()}const $l=Object.freeze(Object.defineProperty({__proto__:null,arrayReplaceAt:ki,assign:Tr,escapeHtml:Ot,escapeRE:Hl,fromCodePoint:Nr,has:Nl,isMdAsciiPunct:Mn,isPunctChar:Vn,isSpace:le,isString:Iu,isValidEntityCode:Pu,isWhiteSpace:Rn,lib:{mdurl:pl,ucmicro:gl},normalizeReference:Lr,unescapeAll:cn,unescapeMd:Rl},Symbol.toStringTag,{value:"Module"}));function Ul(e,t,n){let u,o,r,a;const s=e.posMax,c=e.pos;for(e.pos=t+1,u=1;e.pos<s;){if(r=e.src.charCodeAt(e.pos),r===93&&(u--,u===0)){o=!0;break}if(a=e.pos,e.md.inline.skipToken(e),r===91){if(a===e.pos-1)u++;else if(n)return e.pos=c,-1}}let d=-1;return o&&(d=e.pos),e.pos=c,d}function Wl(e,t,n){let u,o=t;const r={ok:!1,pos:0,str:""};if(e.charCodeAt(o)===60){for(o++;o<n;){if(u=e.charCodeAt(o),u===10||u===60)return r;if(u===62)return r.pos=o+1,r.str=cn(e.slice(t+1,o)),r.ok=!0,r;if(u===92&&o+1<n){o+=2;continue}o++}return r}let a=0;for(;o<n&&(u=e.charCodeAt(o),!(u===32||u<32||u===127));){if(u===92&&o+1<n){if(e.charCodeAt(o+1)===32)break;o+=2;continue}if(u===40&&(a++,a>32))return r;if(u===41){if(a===0)break;a--}o++}return t===o||a!==0||(r.str=cn(e.slice(t,o)),r.pos=o,r.ok=!0),r}function Gl(e,t,n,u){let o,r=t;const a={ok:!1,can_continue:!1,pos:0,str:"",marker:0};if(u)a.str=u.str,a.marker=u.marker;else{if(r>=n)return a;let s=e.charCodeAt(r);if(s!==34&&s!==39&&s!==40)return a;t++,r++,s===40&&(s=41),a.marker=s}for(;r<n;){if(o=e.charCodeAt(r),o===a.marker)return a.pos=r+1,a.str+=cn(e.slice(t,r)),a.ok=!0,a;if(o===40&&a.marker===41)return a;o===92&&r+1<n&&r++,r++}return a.can_continue=!0,a.str+=cn(e.slice(t,r)),a}const ql=Object.freeze(Object.defineProperty({__proto__:null,parseLinkDestination:Wl,parseLinkLabel:Ul,parseLinkTitle:Gl},Symbol.toStringTag,{value:"Module"})),pt={};pt.code_inline=function(e,t,n,u,o){const r=e[t];return"<code"+o.renderAttrs(r)+">"+Ot(r.content)+"</code>"},pt.code_block=function(e,t,n,u,o){const r=e[t];return"<pre"+o.renderAttrs(r)+"><code>"+Ot(e[t].content)+`</code></pre>
3
- `},pt.fence=function(e,t,n,u,o){const r=e[t],a=r.info?cn(r.info).trim():"";let s="",c="";if(a){const f=a.split(/(\s+)/g);s=f[0],c=f.slice(2).join("")}let d;if(n.highlight?d=n.highlight(r.content,s,c)||Ot(r.content):d=Ot(r.content),d.indexOf("<pre")===0)return d+`
1
+ (function(N,i){typeof exports=="object"&&typeof module<"u"?i(exports,require("vue"),require("@farris/x-surface"),require("@a2ui/web_core/v0_9")):typeof define=="function"&&define.amd?define(["exports","vue","@farris/x-surface","@a2ui/web_core/v0_9"],i):(N=typeof globalThis<"u"?globalThis:N||self,i(N.FarrisX={},N.vue,N.xSurface,N.v0_9))})(this,function(N,i,ye,rn){"use strict";var Tp=Object.defineProperty;var Mc=N=>{throw TypeError(N)};var Np=(N,i,ye)=>i in N?Tp(N,i,{enumerable:!0,configurable:!0,writable:!0,value:ye}):N[i]=ye;var fe=(N,i,ye)=>Np(N,typeof i!="symbol"?i+"":i,ye),Zo=(N,i,ye)=>i.has(N)||Mc("Cannot "+ye);var A=(N,i,ye)=>(Zo(N,i,"read from private field"),ye?ye.call(N):i.get(N)),ie=(N,i,ye)=>i.has(N)?Mc("Cannot add the same private member more than once"):i instanceof WeakSet?i.add(N):i.set(N,ye),ee=(N,i,ye,rn)=>(Zo(N,i,"write to private field"),rn?rn.call(N,ye):i.set(N,ye),ye),X=(N,i,ye)=>(Zo(N,i,"access private method"),ye);var vu=(N,i,ye,rn)=>({set _(Er){ee(N,i,Er,ye)},get _(){return A(N,i,rn)}});var bc,Ct,An,yc,xc,rt,Ye,it,Jt,at,kn,Cn,st,Ce,ct,we,he,ne,je,Ke,Pe,Fe,lt,De,dt,ft,Qe,Je,ht,Ht,He,En,G,Yo,en,St,wr,et,Vc,tn,_n,vr,$t,Wt,Ko,Au,ku,pe,Qo,Cr,Gt,Jo,Sn;const Er={content:{type:Object,required:!0},onOpen:{type:Function,default:void 0}},un=i.defineComponent({name:"AppPreviewMessage",props:Er,setup(e){const t=i.ref(!1);function n(){var p;const a=(p=e.content)==null?void 0:p.appConfig;if(!a)return"";const s=a.ws??"",c=a.appPath??"",d=a.appObjectId??"";return`${a.appBuilderUri??"/apps/platform/development-platform/ide/app-builder/index.html"}?path=${c}&boId=${d}&ws=${s}&version=2.0#/home`}function u(){var s,c;const a=(s=e.content)==null?void 0:s.previewConfig;a&&e.onOpen&&e.onOpen({...a,title:a.title??((c=e.content)==null?void 0:c.appName)})}function o(a){const s=a.target;s!=null&&s.closest(".f-chat-app-preview-open-btn")||a.preventDefault()}function r(a){a.stopPropagation();const s=n();s&&window.open(s,"_blank")}return()=>{const a=e.content;if(!a)return null;const{message:s,appName:c,createdDatetime:d}=a;return i.createVNode("div",{class:"f-chat-message-app-preview"},[i.createVNode("div",{class:"f-chat-app-preview-message"},[s]),i.createVNode("div",{class:"f-chat-app-preview-card",onMouseenter:()=>t.value=!0,onMouseleave:()=>t.value=!1,onMousedown:o,onClick:u,role:"button",tabindex:0,onKeydown:f=>f.key==="Enter"&&u()},[i.createVNode("div",{class:"f-chat-app-preview-card-left"},[i.createVNode("span",{class:"f-chat-app-preview-icon"},[i.createVNode("i",{class:"fx-icon fx-icon-bubble_star"},null)])]),i.createVNode("div",{class:"f-chat-app-preview-card-middle"},[i.createVNode("div",{class:"f-chat-app-preview-app-name"},[c]),i.createVNode("div",{class:"f-chat-app-preview-datetime"},[d])]),i.createVNode("div",{class:"f-chat-app-preview-card-right"},[i.createVNode("div",{class:"f-chat-app-preview-action-area"},null),t.value&&i.createVNode("button",{type:"button",class:"f-chat-app-preview-open-btn",onClick:r,title:"在新页签中打开","aria-label":"在新页签中打开"},[i.createVNode("i",{class:"fx-icon fx-icon-folder-open"},null)])])])])}}});un.install=e=>{e.component(un.name,un)};const ei={content:{type:Object,required:!0},outputMode:{type:String,default:"streaming"},classNames:{type:Object,default:()=>({})},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},header:{type:String,default:"sender"},placement:{type:String,default:"start"},showAvatar:{type:Boolean,default:!0},styles:{type:Object,default:()=>({})},attachments:{type:Array,default:()=>[]},onPreview:{type:Function,default:void 0},onUserAuthConfirm:{type:Function,default:void 0},compositeTailRender:{type:Function,default:void 0},onDynamicComponentsDetected:{type:Function,default:void 0},onShowDynamicComponent:{type:Function,default:void 0}},Cu={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},Bc="/api/runtime/attachment";function zc(){try{const e=Cu==null?void 0:Cu.VITE_ATTACHMENT_API_BASE;if(typeof e=="string"&&e.trim()!=="")return e.replace(/\/+$/,"")}catch{}return""}function jc(e){var n;const t=e.trim();return t.startsWith("http://")||t.startsWith("https://")?t:typeof window<"u"&&((n=window.location)!=null&&n.origin)&&t.startsWith("/")?`${window.location.origin}${t}`:t}function Hc(e){return`${Bc}/${encodeURIComponent(e)}/download`}function Eu(e){const t=String(e??"").trim();if(!t)return"";const n=Hc(t),u=zc();return u?`${u}${n}`:n}function ti(e){const t=e.trim().match(/\/api\/runtime\/attachment\/([^/]+)\/download(?:\?|#|$)/i);if(!(t!=null&&t[1]))return"";try{return decodeURIComponent(t[1]).trim()}catch{return t[1].trim()}}function on(e){const t=String(e.fileId??"").trim();if(t)return Eu(t);const n=String(e.url??"").trim();if(!n)return;const u=ti(n);if(u)return Eu(u);if(n.startsWith("http://")||n.startsWith("https://")||n.startsWith("/"))return n}async function _r(e,t){const n=String(t??"").replace(/[/\\]/g,"_").trim()||"download",u=jc(e);try{const o=await fetch(u,{credentials:"include",mode:"cors"});if(!o.ok)throw new Error(`download_http_${o.status}`);const r=await o.blob(),a=URL.createObjectURL(r),s=document.createElement("a");s.href=a,s.download=n,s.rel="noopener noreferrer",document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(a)}catch{const o=document.createElement("a");o.href=u,o.target="_blank",o.rel="noopener noreferrer",document.body.appendChild(o),o.click(),document.body.removeChild(o)}}function be(e,t){return t&&(typeof t=="string"?t.split(" ").filter(Boolean).forEach(u=>{e[u]=!0}):Array.isArray(t)?t.forEach(n=>{n&&(e[n]=!0)}):typeof t=="object"&&Object.entries(t).forEach(([n,u])=>{n&&u&&(e[n]=!0)})),e}function Ae(e,t){return t&&(typeof t=="string"?t.split(";").filter(Boolean).forEach(u=>{var r,a;const o=u.split(":");if(o.length>=2&&((r=o[0])!=null&&r.trim())&&((a=o[1])!=null&&a.trim())){const s=o[0].trim(),c=o.slice(1).join(":").trim();e[s]=c}}):typeof t=="object"&&Object.entries(t).forEach(([n,u])=>{n&&u!==void 0&&u!==null&&(e[n]=u)})),e}function In(e){return e||null}function ni(e){return e?/\.(jpg|jpeg|png|gif|svg|webp|bmp|ico)$/i.test(e)||e.startsWith("http")||e.startsWith("data:image"):!1}function Sr(e){return e?typeof e!="string"?e:ni(e)?i.h("img",{src:e,alt:"icon",class:"fx-prompt--item-icon-image",onError:t=>{const n=t.target;n.style.display="none",n.parentElement.innerHTML='<i class="fx-icon fx-icon-warning"></i>'}}):e.includes("fx-icon")||e.includes("icon-")?i.h("i",{class:e}):e:null}function ri(e,t,n,u={}){const{charInterval:o=30}=u,r=i.ref({});let a=[],s=new Set;const c=()=>typeof t=="function"?t():t.value,d=()=>typeof n=="function"?n():n.value,f=()=>{a.forEach(h=>clearInterval(h)),a=[]},l=()=>{f(),r.value={},s.clear()},p=()=>{f(),r.value={},s.clear()},m=()=>{const h=e();if(!h||Object.keys(h).length===0){r.value={};return}if(!d()){r.value={...h},s=new Set(Object.keys(h));return}const x=Object.keys(h);x.forEach(b=>{r.value.hasOwnProperty(b)||(r.value[b]="")});const y=x.filter(b=>!s.has(b));if(y.length===0)return;let v=0;const g=()=>{var _;if(v>=y.length)return;const b=y[v],w=h[b];if(!w){s.add(b),v++,g();return}let k=((_=r.value[b])==null?void 0:_.length)||0;const S=setInterval(()=>{k<w.length?(r.value={...r.value,[b]:w.slice(0,k+1)},k++):(clearInterval(S),a=a.filter(E=>E!==S),s.add(b),v++,g())},o);a.push(S)};g()};return i.watch(()=>e(),()=>{c()&&m()},{immediate:!0}),i.watch(n,()=>{p(),c()&&m()}),i.watch(t,h=>{h?m():l()}),i.onMounted(()=>{c()&&m()}),{displayContent:r}}function Fr(){const e=i.reactive({}),t=[],n=i.ref(null);let u=null;const o=30,r=h=>{const x=e[h];return!x||x.displayedLength>=x.rawValue.length},a=i.computed(()=>Object.keys(e).length===0?!1:Object.keys(e).every(h=>r(h))),s=()=>{for(const h of t)if(!r(h))return h;return null},c=()=>{if(!n.value&&(n.value=s(),!n.value)){d();return}const h=e[n.value];h&&(h.displayedLength<h.rawValue.length?(h.displayedLength++,h.displayedValue=h.rawValue.slice(0,h.displayedLength),h.isStreaming=!0):(h.isStreaming=!1,h.displayedValue=h.rawValue,n.value=s(),n.value||d()))},d=()=>{u&&(clearInterval(u),u=null)},f=()=>{u||(u=setInterval(c,o))},l=()=>{d(),Object.keys(e).forEach(h=>{delete e[h]}),t.length=0,n.value=null},p=(h,x)=>{if(e[h]){m(h,x);return}t.push(h),e[h]={rawValue:x??"",displayedLength:0,isStreaming:!1,displayedValue:""},u||(!n.value||n.value===h)&&f()},m=(h,x)=>{const y=e[h];if(!y){p(h,x);return}y.rawValue=x??"",!u&&!r(h)&&(!n.value||n.value===h)&&f()};return i.onUnmounted(()=>{d()}),{propertyStates:e,currentProperty:n,get isAnyStreaming(){return Object.values(e).some(h=>h.isStreaming)},isAllDone:a,startStreaming:f,reset:l,registerProperty:p,updatePropertyValue:m}}function _u(){const e=i.ref(null),t=i.ref(0),n=i.ref(!1);let u=null;const o=()=>{e.value=Date.now(),n.value=!0,u=setInterval(()=>{e.value&&(t.value=Math.floor((Date.now()-e.value)/1e3))},1e3)},r=()=>{u&&(clearInterval(u),u=null),e.value&&(t.value=Math.floor((Date.now()-e.value)/1e3))};return{elapsedSeconds:t,hasEverStarted:n,start:o,stop:r,reset:()=>{r(),e.value=null,t.value=0,n.value=!1}}}function Uc(e,t){const n=i.computed(()=>{var o;return Ae({},(o=e.styles)==null?void 0:o.header)});function u(){return t.slots.header&&i.createVNode("div",{class:`f-chat-bubble-header ${e.placement}`,style:n.value},[t.slots.header()])}return{renderHeader:u}}function $c(e,t){var r;const n=i.ref(((r=e.content)==null?void 0:r.sender)??"发送人"),u=i.computed(()=>{var a;return Ae({},(a=e.styles)==null?void 0:a.header)});function o(){return i.createVNode("div",{class:`f-chat-bubble-header ${e.placement}`,style:u.value},[n.value])}return{renderHeader:o}}const Wc={file:{type:Object,required:!0},customStyle:{type:Object,default:()=>({})},onPreviewFile:{type:Function,default:void 0},onBatchPreviewFile:{type:Function,default:void 0}},Gc={attachments:{type:Array,default:()=>[]},enableBatchPreview:{type:Boolean,default:!1},enableFixedWidth:{type:Boolean,default:!1},onPreview:{type:Function,default:void 0},onBatchPreview:{type:Function,default:void 0}};function qc(){return{getFileIcon:u=>({pdf:"file-type-pdf",doc:"file-type-doc",docx:"file-type-doc",xls:"file-type-xls",xlsx:"file-type-xls",ppt:"file-type-ppt",pptx:"file-type-ppt",txt:"file-type-txt",zip:"file-type-zip",rar:"file-type-zip",image:"file-type-img",img:"file-type-img",md:"file-type-md",video:"file-type-any",audio:"file-type-any"})[u.toLowerCase()]||"file-type-any",formatFileName:u=>(u==null?void 0:u.replace(/\.[^.]+$/,""))??"",formatFileSize:u=>u<1024?u+" B":u<1048576?(u/1024).toFixed(1)+" KB":(u/1048576).toFixed(1)+" MB"}}const ui=i.defineComponent({name:"FXBubbleAttachment",props:Gc,emits:["preview","batchPreview"],setup(e,t){const n=i.computed(()=>e.attachments??[]),u=i.computed(()=>{var m;return((m=n.value)==null?void 0:m.length)>0}),{getFileIcon:o,formatFileName:r,formatFileSize:a}=qc(),s=i.computed(()=>({"f-chat-bubble-attachment-info":!0,"f-utils-fill":e.enableFixedWidth})),c=i.computed(()=>({"f-chat-bubble-attachment-name":!0,"name-tip":e.enableFixedWidth})),d=i.computed(()=>e.enableFixedWidth?{width:"200px"}:{flex:"0 0 calc(50% - 4px)"});function f(m,h){t.emit("preview",h)}async function l(m,h){m.stopPropagation(),m.preventDefault();const x=on(h);x&&await _r(x,h.name)}function p(m){t.emit("batchPreview",n.value)}return()=>u.value?i.createVNode("div",{class:"f-chat-bubble-attachments"},[n.value.map((m,h)=>{const x=on(m);return i.createVNode("div",{class:"f-chat-bubble-attachment-item",style:d.value,key:h},[i.createVNode("div",{class:"f-chat-bubble-attachment-main",role:"presentation",onClick:y=>f(y,m)},[i.createVNode("span",{class:`f-chat-bubble-attachment-icon ${o(m.type)}`},null),i.createVNode("div",{class:s.value},[i.createVNode("span",{class:c.value,title:m.name},[r(m.name)]),m.size?i.createVNode("span",{class:"f-chat-bubble-attachment-size"},[a(m.size)]):null])]),x?i.createVNode("button",{type:"button",class:"f-chat-bubble-attachment-download-btn","aria-label":"下载附件",title:"下载",onClick:y=>l(y,m)},[i.createVNode("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","aria-hidden":"true"},[i.createVNode("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("polyline",{points:"7 10 12 15 17 10","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("line",{x1:"12",y1:"15",x2:"12",y2:"3","stroke-linecap":"round","stroke-linejoin":"round"},null)])]):null])}),e.enableBatchPreview&&i.createVNode("div",{class:"f-chat-bubble-attachment-preview-btn",onClick:p},[i.createVNode("span",{class:"f-chat-bubble-attachment-preview-btn-text"},[i.createTextVNode("查看全部文件")]),i.createVNode("i",{class:"fx-icon fx-icon-sort-asc-sm",style:{transform:"rotate(90deg)"}},null)])]):null}}),Xc=i.defineComponent({name:"FXBubbleFileContentFooter",props:Wc,setup(e,t){const n=i.computed(()=>e.file?Array.isArray(e.file)?[...e.file]:[e.file]:[]);return Ae({},e.customStyle),()=>i.createVNode(ui,{attachments:n.value,onPreview:u=>{var o;return(o=e.onPreviewFile)==null?void 0:o.call(e,u)},onBatchPreview:u=>{var o;return(o=e.onBatchPreviewFile)==null?void 0:o.call(e,u)}},null)}}),Zc={pageUrl:{type:String,required:!0},customStyle:{type:Object,default:()=>({})},onNavigate:{type:Function,default:void 0}},Yc=i.defineComponent({name:"FXBubblePageContentFooter",props:Zc,setup(e,t){const n=i.ref(),u=i.computed(()=>{var a,s;const r={width:"100%",height:"100%",border:"none"};return(a=e.customStyle)!=null&&a.width&&(r.width=e.customStyle.width),(s=e.customStyle)!=null&&s.height&&(r.height=`${e.customStyle.height}px`),r}),o=r=>{var a,s;((a=r.data)==null?void 0:a.type)==="navigation"&&((s=r.data)!=null&&s.url)&&e.onNavigate&&e.onNavigate(r.data.url)};return i.onMounted(()=>{window.addEventListener("message",o)}),i.onUnmounted(()=>{window.removeEventListener("message",o)}),()=>i.createVNode("iframe",{ref:n,src:e.pageUrl,style:u.value,scrolling:"auto"},null)}});function oi(){function e(o,r){const{fileContent:a,height:s,width:c}=o;return{file:a,customStyle:{width:c||"100%",height:s||"100%"},onPreviewFile:r==null?void 0:r.onPreviewFile,onBatchPreviewFile:r==null?void 0:r.onBatchPreviewFile}}function t(o,r){const{pageUrl:a,height:s,width:c}=o;return{pageUrl:a,customStyle:{width:c||"100%",height:s||"100%"},onNavigate:r==null?void 0:r.onNavigate}}function n(o,r){const a=e(o,r);return i.h(Xc,a)}function u(o,r){const a=t(o,r);return i.h(Yc,a)}return{renderFileEmbeddedContent:n,renderPageEmbeddedContent:u}}const Kc={title:{type:String,default:""},subtitle:{type:String,default:""},text:{type:String,default:""},textFormat:{type:String,default:"plain"},placement:{type:String,default:"start"},onDynamicComponentsDetected:{type:Function,default:void 0},onShowDynamicComponent:{type:Function,default:void 0}};function Qc(e){return e.replace(/```\s*\n+\s*assistant-widget/g,"``` assistant-widget").replace(/```\s*\n+\s*A2UI/g,"``` A2UI")}function Jc(e){if(!e)return!1;const t=/^```\s*(?:assistant-widget|A2UI)[\s\S]*?```$/,n=/^```\s*(?:assistant-widget|A2UI)/;return t.test(e)||n.test(e)}function el(e){if(!e)return[];const t=/(```[\s]*(?:assistant-widget|A2UI)[\s\S]*?```)/g,n=[];let u=0,o;for(;(o=t.exec(e))!==null;){if(o.index>u){const r=e.slice(u,o.index),a=/(```[\s]*(?:assistant-widget|A2UI))/,s=r.match(a);if(s){const c=r.indexOf(s[0]);c>0&&n.push(r.slice(0,c)),n.push(r.slice(c));const d=r.slice(c+s[0].length);d.trim().length>0&&n.push(d)}else n.push(r)}n.push(Qc(o[0])),u=o.index+o[0].length}if(u<e.length){const r=e.slice(u),a=/(```[\s]*(?:assistant-widget|A2UI))/,s=r.match(a);if(s){const c=r.indexOf(s[0]);c>0&&n.push(r.slice(0,c)),n.push(r.slice(c))}else n.push(r)}return n.filter(r=>r.trim().length>0)}function ii(e){const t=e.replace("``` assistant-widget","").replace("```","").trim();try{return JSON.parse(t)}catch(n){return console.error("Failed to parse JSON:",n),null}}function tl(e){const t=e.replace("```A2UI","").replace("```","").trim();try{const n=JSON.parse(t);return n!=null&&n.components&&Array.isArray(n.components)&&n.components.length>0&&n.components[0].component!=="Card"&&(n.components[0].id="x01",n.components.unshift({id:"root",component:"Card",align:"center",child:"x01"})),n}catch(n){return console.error("Failed to parse JSON:",n),null}}function nl(e){var n;const t=ii(e);return((n=t==null?void 0:t.renderer)==null?void 0:n.widgetImplOptions)||{}}const rl=/^```\s*dynamic-component[\s\S]*?```$/,ul=/^```\s*dynamic-component/;function ol(e){return e.replace(/```\s*\n*\s*dynamic-component/g,"``` dynamic-component")}function il(e){return e?rl.test(e)||ul.test(e):!1}function al(e){const t=e.replace(/```\s*dynamic-component\s*\n?/,"").replace(/\n?\s*```/,"").trim();if(!t)return null;let n;try{n=JSON.parse(t)}catch{return null}if(!n||typeof n!="object"||Array.isArray(n))return null;const u=n;return typeof u.instanceId!="string"?null:{...u,instanceId:u.instanceId,name:typeof u.name=="string"?u.name:void 0,componentId:typeof u.componentId=="string"?u.componentId:void 0,jsUrl:typeof u.jsUrl=="string"?u.jsUrl:"",url:typeof u.url=="string"?u.url:"",title:typeof u.title=="string"?u.title:"预览",position:u.position==="inline"?"inline":"right",width:typeof u.width=="string"?u.width:void 0,isFullscreen:typeof u.isFullscreen=="boolean"?u.isFullscreen:!1,autoOpen:typeof u.autoOpen=="boolean"?u.autoOpen:!1,fileRe:typeof u.fileRe=="string"?u.fileRe:void 0}}function sl(e){const t=e.replace(/```\s*dynamic-component\s*\n?/,"").replace(/\n?\s*```/,"").trim();if(!t)return null;const n=t.match(/"position"\s*:\s*"(inline|right)"/);return n?{position:n[1]}:null}function cl(e){if(!e)return[];const t="``` dynamic-component",n="```",u=[];let o=0;for(;o<e.length;){const r=e.indexOf(t,o);if(r===-1){const m=e.slice(o);m&&u.push(m);break}let a=r+t.length;const s=e.lastIndexOf("```",r),c=s>=0&&s<r+3?s:r,d=e.slice(o,c);d&&u.push(d);const f=e.indexOf(n,a);if(f===-1){u.push(e.slice(c));break}const l=f+n.length,p=e.slice(c,l);u.push(ol(p)),o=l}return u.filter(r=>r.length>0)}var ke=(e=>(e.Text="text",e.A2UIComplete="a2ui-complete",e.AssistantWidgetComplete="assistant-widget-complete",e.AssistantWidgetPending="assistant-widget-pending",e.DynamicComponentComplete="dynamic-component-complete",e.DynamicComponentPending="dynamic-component-pending",e))(ke||{});function ll(e){var o;if(!e)return[];const t=[],n=new Set,u=el(e);for(const r of u)if(Jc(r))if(r.endsWith("```"))if(r.startsWith("```A2UI")){const a=tl(r);t.push({type:ke.A2UIComplete,raw:r,a2uiData:a})}else{const a=ii(r);t.push({type:ke.AssistantWidgetComplete,raw:r,widgetData:a,widgetUrl:(o=a==null?void 0:a.renderer)==null?void 0:o.url,widgetImplOptions:nl(r)})}else t.push({type:ke.AssistantWidgetPending,raw:r});else{const a=cl(r);for(const s of a)if(il(s))if(s.endsWith("```")){const c=al(s);if(c!=null&&c.instanceId){if(n.has(c.instanceId))continue;n.add(c.instanceId),t.push({type:ke.DynamicComponentComplete,raw:s,config:c})}}else{const c=sl(s);t.push({type:ke.DynamicComponentPending,raw:s,position:(c==null?void 0:c.position)??null})}else s.trim()&&t.push({type:ke.Text,raw:s})}return t}const ai={};function dl(e){let t=ai[e];if(t)return t;t=ai[e]=[];for(let n=0;n<128;n++){const u=String.fromCharCode(n);t.push(u)}for(let n=0;n<e.length;n++){const u=e.charCodeAt(n);t[u]="%"+("0"+u.toString(16).toUpperCase()).slice(-2)}return t}function an(e,t){typeof t!="string"&&(t=an.defaultChars);const n=dl(t);return e.replace(/(%[a-f0-9]{2})+/gi,function(u){let o="";for(let r=0,a=u.length;r<a;r+=3){const s=parseInt(u.slice(r+1,r+3),16);if(s<128){o+=n[s];continue}if((s&224)===192&&r+3<a){const c=parseInt(u.slice(r+4,r+6),16);if((c&192)===128){const d=s<<6&1984|c&63;d<128?o+="��":o+=String.fromCharCode(d),r+=3;continue}}if((s&240)===224&&r+6<a){const c=parseInt(u.slice(r+4,r+6),16),d=parseInt(u.slice(r+7,r+9),16);if((c&192)===128&&(d&192)===128){const f=s<<12&61440|c<<6&4032|d&63;f<2048||f>=55296&&f<=57343?o+="���":o+=String.fromCharCode(f),r+=6;continue}}if((s&248)===240&&r+9<a){const c=parseInt(u.slice(r+4,r+6),16),d=parseInt(u.slice(r+7,r+9),16),f=parseInt(u.slice(r+10,r+12),16);if((c&192)===128&&(d&192)===128&&(f&192)===128){let l=s<<18&1835008|c<<12&258048|d<<6&4032|f&63;l<65536||l>1114111?o+="����":(l-=65536,o+=String.fromCharCode(55296+(l>>10),56320+(l&1023))),r+=9;continue}}o+="�"}return o})}an.defaultChars=";/?:@&=+$,#",an.componentChars="";const si={};function fl(e){let t=si[e];if(t)return t;t=si[e]=[];for(let n=0;n<128;n++){const u=String.fromCharCode(n);/^[0-9a-z]$/i.test(u)?t.push(u):t.push("%"+("0"+n.toString(16).toUpperCase()).slice(-2))}for(let n=0;n<e.length;n++)t[e.charCodeAt(n)]=e[n];return t}function On(e,t,n){typeof t!="string"&&(n=t,t=On.defaultChars),typeof n>"u"&&(n=!0);const u=fl(t);let o="";for(let r=0,a=e.length;r<a;r++){const s=e.charCodeAt(r);if(n&&s===37&&r+2<a&&/^[0-9a-f]{2}$/i.test(e.slice(r+1,r+3))){o+=e.slice(r,r+3),r+=2;continue}if(s<128){o+=u[s];continue}if(s>=55296&&s<=57343){if(s>=55296&&s<=56319&&r+1<a){const c=e.charCodeAt(r+1);if(c>=56320&&c<=57343){o+=encodeURIComponent(e[r]+e[r+1]),r++;continue}}o+="%EF%BF%BD";continue}o+=encodeURIComponent(e[r])}return o}On.defaultChars=";/?:@&=+$,-_.!~*'()#",On.componentChars="-_.!~*'()";function Su(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&e.hostname.indexOf(":")!==-1?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t}function Dr(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}const hl=/^([a-z0-9.+-]+:)/i,pl=/:[0-9]*$/,ml=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,gl=["<",">",'"',"`"," ","\r",`
2
+ `," "],bl=["{","}","|","\\","^","`"].concat(gl),yl=["'"].concat(bl),ci=["%","/","?",";","#"].concat(yl),li=["/","?","#"],xl=255,di=/^[+a-z0-9A-Z_-]{0,63}$/,wl=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,fi={javascript:!0,"javascript:":!0},hi={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};function Fu(e,t){if(e&&e instanceof Dr)return e;const n=new Dr;return n.parse(e,t),n}Dr.prototype.parse=function(e,t){let n,u,o,r=e;if(r=r.trim(),!t&&e.split("#").length===1){const d=ml.exec(r);if(d)return this.pathname=d[1],d[2]&&(this.search=d[2]),this}let a=hl.exec(r);if(a&&(a=a[0],n=a.toLowerCase(),this.protocol=a,r=r.substr(a.length)),(t||a||r.match(/^\/\/[^@\/]+@[^@\/]+/))&&(o=r.substr(0,2)==="//",o&&!(a&&fi[a])&&(r=r.substr(2),this.slashes=!0)),!fi[a]&&(o||a&&!hi[a])){let d=-1;for(let h=0;h<li.length;h++)u=r.indexOf(li[h]),u!==-1&&(d===-1||u<d)&&(d=u);let f,l;d===-1?l=r.lastIndexOf("@"):l=r.lastIndexOf("@",d),l!==-1&&(f=r.slice(0,l),r=r.slice(l+1),this.auth=f),d=-1;for(let h=0;h<ci.length;h++)u=r.indexOf(ci[h]),u!==-1&&(d===-1||u<d)&&(d=u);d===-1&&(d=r.length),r[d-1]===":"&&d--;const p=r.slice(0,d);r=r.slice(d),this.parseHost(p),this.hostname=this.hostname||"";const m=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!m){const h=this.hostname.split(/\./);for(let x=0,y=h.length;x<y;x++){const v=h[x];if(v&&!v.match(di)){let g="";for(let b=0,w=v.length;b<w;b++)v.charCodeAt(b)>127?g+="x":g+=v[b];if(!g.match(di)){const b=h.slice(0,x),w=h.slice(x+1),k=v.match(wl);k&&(b.push(k[1]),w.unshift(k[2])),w.length&&(r=w.join(".")+r),this.hostname=b.join(".");break}}}}this.hostname.length>xl&&(this.hostname=""),m&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}const s=r.indexOf("#");s!==-1&&(this.hash=r.substr(s),r=r.slice(0,s));const c=r.indexOf("?");return c!==-1&&(this.search=r.substr(c),r=r.slice(0,c)),r&&(this.pathname=r),hi[n]&&this.hostname&&!this.pathname&&(this.pathname=""),this},Dr.prototype.parseHost=function(e){let t=pl.exec(e);t&&(t=t[0],t!==":"&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};const vl=Object.freeze(Object.defineProperty({__proto__:null,decode:an,encode:On,format:Su,parse:Fu},Symbol.toStringTag,{value:"Module"})),pi=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,mi=/[\0-\x1F\x7F-\x9F]/,Al=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,Du=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,gi=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/,bi=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,kl=Object.freeze(Object.defineProperty({__proto__:null,Any:pi,Cc:mi,Cf:Al,P:Du,S:gi,Z:bi},Symbol.toStringTag,{value:"Module"})),Cl=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),El=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var Tu;const _l=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]]),Sl=(Tu=String.fromCodePoint)!==null&&Tu!==void 0?Tu:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function Fl(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=_l.get(e))!==null&&t!==void 0?t:e}var _e;(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"})(_e||(_e={}));const Dl=32;var Lt;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Lt||(Lt={}));function Nu(e){return e>=_e.ZERO&&e<=_e.NINE}function Tl(e){return e>=_e.UPPER_A&&e<=_e.UPPER_F||e>=_e.LOWER_A&&e<=_e.LOWER_F}function Nl(e){return e>=_e.UPPER_A&&e<=_e.UPPER_Z||e>=_e.LOWER_A&&e<=_e.LOWER_Z||Nu(e)}function Ll(e){return e===_e.EQUALS||Nl(e)}var Se;(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"})(Se||(Se={}));var It;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(It||(It={}));class Il{constructor(t,n,u){this.decodeTree=t,this.emitCodePoint=n,this.errors=u,this.state=Se.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=It.Strict}startEntity(t){this.decodeMode=t,this.state=Se.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Se.EntityStart:return t.charCodeAt(n)===_e.NUM?(this.state=Se.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Se.NamedEntity,this.stateNamedEntity(t,n));case Se.NumericStart:return this.stateNumericStart(t,n);case Se.NumericDecimal:return this.stateNumericDecimal(t,n);case Se.NumericHex:return this.stateNumericHex(t,n);case Se.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|Dl)===_e.LOWER_X?(this.state=Se.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Se.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,u,o){if(n!==u){const r=u-n;this.result=this.result*Math.pow(o,r)+parseInt(t.substr(n,r),o),this.consumed+=r}}stateNumericHex(t,n){const u=n;for(;n<t.length;){const o=t.charCodeAt(n);if(Nu(o)||Tl(o))n+=1;else return this.addToNumericResult(t,u,n,16),this.emitNumericEntity(o,3)}return this.addToNumericResult(t,u,n,16),-1}stateNumericDecimal(t,n){const u=n;for(;n<t.length;){const o=t.charCodeAt(n);if(Nu(o))n+=1;else return this.addToNumericResult(t,u,n,10),this.emitNumericEntity(o,2)}return this.addToNumericResult(t,u,n,10),-1}emitNumericEntity(t,n){var u;if(this.consumed<=n)return(u=this.errors)===null||u===void 0||u.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===_e.SEMI)this.consumed+=1;else if(this.decodeMode===It.Strict)return 0;return this.emitCodePoint(Fl(this.result),this.consumed),this.errors&&(t!==_e.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:u}=this;let o=u[this.treeIndex],r=(o&Lt.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const a=t.charCodeAt(n);if(this.treeIndex=Ol(u,o,this.treeIndex+Math.max(1,r),a),this.treeIndex<0)return this.result===0||this.decodeMode===It.Attribute&&(r===0||Ll(a))?0:this.emitNotTerminatedNamedEntity();if(o=u[this.treeIndex],r=(o&Lt.VALUE_LENGTH)>>14,r!==0){if(a===_e.SEMI)return this.emitNamedEntityData(this.treeIndex,r,this.consumed+this.excess);this.decodeMode!==It.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:u}=this,o=(u[n]&Lt.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,o,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,u){const{decodeTree:o}=this;return this.emitCodePoint(n===1?o[t]&~Lt.VALUE_LENGTH:o[t+1],u),n===3&&this.emitCodePoint(o[t+2],u),u}end(){var t;switch(this.state){case Se.NamedEntity:return this.result!==0&&(this.decodeMode!==It.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Se.NumericDecimal:return this.emitNumericEntity(0,2);case Se.NumericHex:return this.emitNumericEntity(0,3);case Se.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Se.EntityStart:return 0}}}function yi(e){let t="";const n=new Il(e,u=>t+=Sl(u));return function(o,r){let a=0,s=0;for(;(s=o.indexOf("&",s))>=0;){t+=o.slice(a,s),n.startEntity(r);const d=n.write(o,s+1);if(d<0){a=s+n.end();break}a=s+d,s=d===0?a+1:a}const c=t+o.slice(a);return t="",c}}function Ol(e,t,n,u){const o=(t&Lt.BRANCH_LENGTH)>>7,r=t&Lt.JUMP_TABLE;if(o===0)return r!==0&&u===r?n:-1;if(r){const c=u-r;return c<0||c>=o?-1:e[n+c]-1}let a=n,s=a+o-1;for(;a<=s;){const c=a+s>>>1,d=e[c];if(d<u)a=c+1;else if(d>u)s=c-1;else return e[c+o]}return-1}const Pl=yi(Cl);yi(El);function xi(e,t=It.Legacy){return Pl(e,t)}function Rl(e){return Object.prototype.toString.call(e)}function Lu(e){return Rl(e)==="[object String]"}const Ml=Object.prototype.hasOwnProperty;function Vl(e,t){return Ml.call(e,t)}function Tr(e){return Array.prototype.slice.call(arguments,1).forEach(function(n){if(n){if(typeof n!="object")throw new TypeError(n+"must be object");Object.keys(n).forEach(function(u){e[u]=n[u]})}}),e}function wi(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))}function Iu(e){return!(e>=55296&&e<=57343||e>=64976&&e<=65007||(e&65535)===65535||(e&65535)===65534||e>=0&&e<=8||e===11||e>=14&&e<=31||e>=127&&e<=159||e>1114111)}function Nr(e){if(e>65535){e-=65536;const t=55296+(e>>10),n=56320+(e&1023);return String.fromCharCode(t,n)}return String.fromCharCode(e)}const vi=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,Bl=/&([a-z#][a-z0-9]{1,31});/gi,zl=new RegExp(vi.source+"|"+Bl.source,"gi"),jl=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function Hl(e,t){if(t.charCodeAt(0)===35&&jl.test(t)){const u=t[1].toLowerCase()==="x"?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return Iu(u)?Nr(u):e}const n=xi(e);return n!==e?n:e}function Ul(e){return e.indexOf("\\")<0?e:e.replace(vi,"$1")}function sn(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(zl,function(t,n,u){return n||Hl(t,u)})}const $l=/[&<>"]/,Wl=/[&<>"]/g,Gl={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;"};function ql(e){return Gl[e]}function Ot(e){return $l.test(e)?e.replace(Wl,ql):e}const Xl=/[.?*+^$[\]\\(){}|-]/g;function Zl(e){return e.replace(Xl,"\\$&")}function le(e){switch(e){case 9:case 32:return!0}return!1}function Pn(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function Rn(e){return Du.test(e)||gi.test(e)}function Mn(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function Lr(e){return e=e.trim().replace(/\s+/g," "),"ẞ".toLowerCase()==="Ṿ"&&(e=e.replace(/ẞ/g,"ß")),e.toLowerCase().toUpperCase()}const Yl=Object.freeze(Object.defineProperty({__proto__:null,arrayReplaceAt:wi,assign:Tr,escapeHtml:Ot,escapeRE:Zl,fromCodePoint:Nr,has:Vl,isMdAsciiPunct:Mn,isPunctChar:Rn,isSpace:le,isString:Lu,isValidEntityCode:Iu,isWhiteSpace:Pn,lib:{mdurl:vl,ucmicro:kl},normalizeReference:Lr,unescapeAll:sn,unescapeMd:Ul},Symbol.toStringTag,{value:"Module"}));function Kl(e,t,n){let u,o,r,a;const s=e.posMax,c=e.pos;for(e.pos=t+1,u=1;e.pos<s;){if(r=e.src.charCodeAt(e.pos),r===93&&(u--,u===0)){o=!0;break}if(a=e.pos,e.md.inline.skipToken(e),r===91){if(a===e.pos-1)u++;else if(n)return e.pos=c,-1}}let d=-1;return o&&(d=e.pos),e.pos=c,d}function Ql(e,t,n){let u,o=t;const r={ok:!1,pos:0,str:""};if(e.charCodeAt(o)===60){for(o++;o<n;){if(u=e.charCodeAt(o),u===10||u===60)return r;if(u===62)return r.pos=o+1,r.str=sn(e.slice(t+1,o)),r.ok=!0,r;if(u===92&&o+1<n){o+=2;continue}o++}return r}let a=0;for(;o<n&&(u=e.charCodeAt(o),!(u===32||u<32||u===127));){if(u===92&&o+1<n){if(e.charCodeAt(o+1)===32)break;o+=2;continue}if(u===40&&(a++,a>32))return r;if(u===41){if(a===0)break;a--}o++}return t===o||a!==0||(r.str=sn(e.slice(t,o)),r.pos=o,r.ok=!0),r}function Jl(e,t,n,u){let o,r=t;const a={ok:!1,can_continue:!1,pos:0,str:"",marker:0};if(u)a.str=u.str,a.marker=u.marker;else{if(r>=n)return a;let s=e.charCodeAt(r);if(s!==34&&s!==39&&s!==40)return a;t++,r++,s===40&&(s=41),a.marker=s}for(;r<n;){if(o=e.charCodeAt(r),o===a.marker)return a.pos=r+1,a.str+=sn(e.slice(t,r)),a.ok=!0,a;if(o===40&&a.marker===41)return a;o===92&&r+1<n&&r++,r++}return a.can_continue=!0,a.str+=sn(e.slice(t,r)),a}const e0=Object.freeze(Object.defineProperty({__proto__:null,parseLinkDestination:Ql,parseLinkLabel:Kl,parseLinkTitle:Jl},Symbol.toStringTag,{value:"Module"})),mt={};mt.code_inline=function(e,t,n,u,o){const r=e[t];return"<code"+o.renderAttrs(r)+">"+Ot(r.content)+"</code>"},mt.code_block=function(e,t,n,u,o){const r=e[t];return"<pre"+o.renderAttrs(r)+"><code>"+Ot(e[t].content)+`</code></pre>
3
+ `},mt.fence=function(e,t,n,u,o){const r=e[t],a=r.info?sn(r.info).trim():"";let s="",c="";if(a){const f=a.split(/(\s+)/g);s=f[0],c=f.slice(2).join("")}let d;if(n.highlight?d=n.highlight(r.content,s,c)||Ot(r.content):d=Ot(r.content),d.indexOf("<pre")===0)return d+`
4
4
  `;if(a){const f=r.attrIndex("class"),l=r.attrs?r.attrs.slice():[];f<0?l.push(["class",n.langPrefix+s]):(l[f]=l[f].slice(),l[f][1]+=" "+n.langPrefix+s);const p={attrs:l};return`<pre><code${o.renderAttrs(p)}>${d}</code></pre>
5
5
  `}return`<pre><code${o.renderAttrs(r)}>${d}</code></pre>
6
- `},pt.image=function(e,t,n,u,o){const r=e[t];return r.attrs[r.attrIndex("alt")][1]=o.renderInlineAsText(r.children,n,u),o.renderToken(e,t,n)},pt.hardbreak=function(e,t,n){return n.xhtmlOut?`<br />
6
+ `},mt.image=function(e,t,n,u,o){const r=e[t];return r.attrs[r.attrIndex("alt")][1]=o.renderInlineAsText(r.children,n,u),o.renderToken(e,t,n)},mt.hardbreak=function(e,t,n){return n.xhtmlOut?`<br />
7
7
  `:`<br>
8
- `},pt.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?`<br />
8
+ `},mt.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?`<br />
9
9
  `:`<br>
10
10
  `:`
11
- `},pt.text=function(e,t){return Ot(e[t].content)},pt.html_block=function(e,t){return e[t].content},pt.html_inline=function(e,t){return e[t].content};function ln(){this.rules=Tr({},pt)}ln.prototype.renderAttrs=function(t){let n,u,o;if(!t.attrs)return"";for(o="",n=0,u=t.attrs.length;n<u;n++)o+=" "+Ot(t.attrs[n][0])+'="'+Ot(t.attrs[n][1])+'"';return o},ln.prototype.renderToken=function(t,n,u){const o=t[n];let r="";if(o.hidden)return"";o.block&&o.nesting!==-1&&n&&t[n-1].hidden&&(r+=`
11
+ `},mt.text=function(e,t){return Ot(e[t].content)},mt.html_block=function(e,t){return e[t].content},mt.html_inline=function(e,t){return e[t].content};function cn(){this.rules=Tr({},mt)}cn.prototype.renderAttrs=function(t){let n,u,o;if(!t.attrs)return"";for(o="",n=0,u=t.attrs.length;n<u;n++)o+=" "+Ot(t.attrs[n][0])+'="'+Ot(t.attrs[n][1])+'"';return o},cn.prototype.renderToken=function(t,n,u){const o=t[n];let r="";if(o.hidden)return"";o.block&&o.nesting!==-1&&n&&t[n-1].hidden&&(r+=`
12
12
  `),r+=(o.nesting===-1?"</":"<")+o.tag,r+=this.renderAttrs(o),o.nesting===0&&u.xhtmlOut&&(r+=" /");let a=!1;if(o.block&&(a=!0,o.nesting===1&&n+1<t.length)){const s=t[n+1];(s.type==="inline"||s.hidden||s.nesting===-1&&s.tag===o.tag)&&(a=!1)}return r+=a?`>
13
- `:">",r},ln.prototype.renderInline=function(e,t,n){let u="";const o=this.rules;for(let r=0,a=e.length;r<a;r++){const s=e[r].type;typeof o[s]<"u"?u+=o[s](e,r,t,n,this):u+=this.renderToken(e,r,t)}return u},ln.prototype.renderInlineAsText=function(e,t,n){let u="";for(let o=0,r=e.length;o<r;o++)switch(e[o].type){case"text":u+=e[o].content;break;case"image":u+=this.renderInlineAsText(e[o].children,t,n);break;case"html_inline":case"html_block":u+=e[o].content;break;case"softbreak":case"hardbreak":u+=`
14
- `;break}return u},ln.prototype.render=function(e,t,n){let u="";const o=this.rules;for(let r=0,a=e.length;r<a;r++){const s=e[r].type;s==="inline"?u+=this.renderInline(e[r].children,t,n):typeof o[s]<"u"?u+=o[s](e,r,t,n,this):u+=this.renderToken(e,r,t,n)}return u};function He(){this.__rules__=[],this.__cache__=null}He.prototype.__find__=function(e){for(let t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return-1},He.prototype.__compile__=function(){const e=this,t=[""];e.__rules__.forEach(function(n){n.enabled&&n.alt.forEach(function(u){t.indexOf(u)<0&&t.push(u)})}),e.__cache__={},t.forEach(function(n){e.__cache__[n]=[],e.__rules__.forEach(function(u){u.enabled&&(n&&u.alt.indexOf(n)<0||e.__cache__[n].push(u.fn))})})},He.prototype.at=function(e,t,n){const u=this.__find__(e),o=n||{};if(u===-1)throw new Error("Parser rule not found: "+e);this.__rules__[u].fn=t,this.__rules__[u].alt=o.alt||[],this.__cache__=null},He.prototype.before=function(e,t,n,u){const o=this.__find__(e),r=u||{};if(o===-1)throw new Error("Parser rule not found: "+e);this.__rules__.splice(o,0,{name:t,enabled:!0,fn:n,alt:r.alt||[]}),this.__cache__=null},He.prototype.after=function(e,t,n,u){const o=this.__find__(e),r=u||{};if(o===-1)throw new Error("Parser rule not found: "+e);this.__rules__.splice(o+1,0,{name:t,enabled:!0,fn:n,alt:r.alt||[]}),this.__cache__=null},He.prototype.push=function(e,t,n){const u=n||{};this.__rules__.push({name:e,enabled:!0,fn:t,alt:u.alt||[]}),this.__cache__=null},He.prototype.enable=function(e,t){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(function(u){const o=this.__find__(u);if(o<0){if(t)return;throw new Error("Rules manager: invalid rule name "+u)}this.__rules__[o].enabled=!0,n.push(u)},this),this.__cache__=null,n},He.prototype.enableOnly=function(e,t){Array.isArray(e)||(e=[e]),this.__rules__.forEach(function(n){n.enabled=!1}),this.enable(e,t)},He.prototype.disable=function(e,t){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(function(u){const o=this.__find__(u);if(o<0){if(t)return;throw new Error("Rules manager: invalid rule name "+u)}this.__rules__[o].enabled=!1,n.push(u)},this),this.__cache__=null,n},He.prototype.getRules=function(e){return this.__cache__===null&&this.__compile__(),this.__cache__[e]||[]};function rt(e,t,n){this.type=e,this.tag=t,this.attrs=null,this.map=null,this.nesting=n,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}rt.prototype.attrIndex=function(t){if(!this.attrs)return-1;const n=this.attrs;for(let u=0,o=n.length;u<o;u++)if(n[u][0]===t)return u;return-1},rt.prototype.attrPush=function(t){this.attrs?this.attrs.push(t):this.attrs=[t]},rt.prototype.attrSet=function(t,n){const u=this.attrIndex(t),o=[t,n];u<0?this.attrPush(o):this.attrs[u]=o},rt.prototype.attrGet=function(t){const n=this.attrIndex(t);let u=null;return n>=0&&(u=this.attrs[n][1]),u},rt.prototype.attrJoin=function(t,n){const u=this.attrIndex(t);u<0?this.attrPush([t,n]):this.attrs[u][1]=this.attrs[u][1]+" "+n};function Ei(e,t,n){this.src=e,this.env=n,this.tokens=[],this.inlineMode=!1,this.md=t}Ei.prototype.Token=rt;const Xl=/\r\n?|\n/g,Zl=/\0/g;function Yl(e){let t;t=e.src.replace(Xl,`
15
- `),t=t.replace(Zl,"�"),e.src=t}function Kl(e){let t;e.inlineMode?(t=new e.Token("inline","",0),t.content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}function Ql(e){const t=e.tokens;for(let n=0,u=t.length;n<u;n++){const o=t[n];o.type==="inline"&&e.md.inline.parse(o.content,e.md,e.env,o.children)}}function Jl(e){return/^<a[>\s]/i.test(e)}function e0(e){return/^<\/a\s*>/i.test(e)}function t0(e){const t=e.tokens;if(e.md.options.linkify)for(let n=0,u=t.length;n<u;n++){if(t[n].type!=="inline"||!e.md.linkify.pretest(t[n].content))continue;let o=t[n].children,r=0;for(let a=o.length-1;a>=0;a--){const s=o[a];if(s.type==="link_close"){for(a--;o[a].level!==s.level&&o[a].type!=="link_open";)a--;continue}if(s.type==="html_inline"&&(Jl(s.content)&&r>0&&r--,e0(s.content)&&r++),!(r>0)&&s.type==="text"&&e.md.linkify.test(s.content)){const c=s.content;let d=e.md.linkify.match(c);const f=[];let l=s.level,p=0;d.length>0&&d[0].index===0&&a>0&&o[a-1].type==="text_special"&&(d=d.slice(1));for(let m=0;m<d.length;m++){const h=d[m].url,y=e.md.normalizeLink(h);if(!e.md.validateLink(y))continue;let x=d[m].text;d[m].schema?d[m].schema==="mailto:"&&!/^mailto:/i.test(x)?x=e.md.normalizeLinkText("mailto:"+x).replace(/^mailto:/,""):x=e.md.normalizeLinkText(x):x=e.md.normalizeLinkText("http://"+x).replace(/^http:\/\//,"");const v=d[m].index;if(v>p){const k=new e.Token("text","",0);k.content=c.slice(p,v),k.level=l,f.push(k)}const g=new e.Token("link_open","a",1);g.attrs=[["href",y]],g.level=l++,g.markup="linkify",g.info="auto",f.push(g);const b=new e.Token("text","",0);b.content=x,b.level=l,f.push(b);const w=new e.Token("link_close","a",-1);w.level=--l,w.markup="linkify",w.info="auto",f.push(w),p=d[m].lastIndex}if(p<c.length){const m=new e.Token("text","",0);m.content=c.slice(p),m.level=l,f.push(m)}t[n].children=o=ki(o,a,f)}}}}const _i=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,n0=/\((c|tm|r)\)/i,r0=/\((c|tm|r)\)/ig,u0={c:"©",r:"®",tm:"™"};function o0(e,t){return u0[t.toLowerCase()]}function i0(e){let t=0;for(let n=e.length-1;n>=0;n--){const u=e[n];u.type==="text"&&!t&&(u.content=u.content.replace(r0,o0)),u.type==="link_open"&&u.info==="auto"&&t--,u.type==="link_close"&&u.info==="auto"&&t++}}function a0(e){let t=0;for(let n=e.length-1;n>=0;n--){const u=e[n];u.type==="text"&&!t&&_i.test(u.content)&&(u.content=u.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/mg,"$1—").replace(/(^|\s)--(?=\s|$)/mg,"$1–").replace(/(^|[^-\s])--(?=[^-\s]|$)/mg,"$1–")),u.type==="link_open"&&u.info==="auto"&&t--,u.type==="link_close"&&u.info==="auto"&&t++}}function s0(e){let t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)e.tokens[t].type==="inline"&&(n0.test(e.tokens[t].content)&&i0(e.tokens[t].children),_i.test(e.tokens[t].content)&&a0(e.tokens[t].children))}const c0=/['"]/,Si=/['"]/g,Fi="’";function Or(e,t,n){return e.slice(0,t)+n+e.slice(t+1)}function l0(e,t){let n;const u=[];for(let o=0;o<e.length;o++){const r=e[o],a=e[o].level;for(n=u.length-1;n>=0&&!(u[n].level<=a);n--);if(u.length=n+1,r.type!=="text")continue;let s=r.content,c=0,d=s.length;e:for(;c<d;){Si.lastIndex=c;const f=Si.exec(s);if(!f)break;let l=!0,p=!0;c=f.index+1;const m=f[0]==="'";let h=32;if(f.index-1>=0)h=s.charCodeAt(f.index-1);else for(n=o-1;n>=0&&!(e[n].type==="softbreak"||e[n].type==="hardbreak");n--)if(e[n].content){h=e[n].content.charCodeAt(e[n].content.length-1);break}let y=32;if(c<d)y=s.charCodeAt(c);else for(n=o+1;n<e.length&&!(e[n].type==="softbreak"||e[n].type==="hardbreak");n++)if(e[n].content){y=e[n].content.charCodeAt(0);break}const x=Mn(h)||Vn(String.fromCharCode(h)),v=Mn(y)||Vn(String.fromCharCode(y)),g=Rn(h),b=Rn(y);if(b?l=!1:v&&(g||x||(l=!1)),g?p=!1:x&&(b||v||(p=!1)),y===34&&f[0]==='"'&&h>=48&&h<=57&&(p=l=!1),l&&p&&(l=x,p=v),!l&&!p){m&&(r.content=Or(r.content,f.index,Fi));continue}if(p)for(n=u.length-1;n>=0;n--){let w=u[n];if(u[n].level<a)break;if(w.single===m&&u[n].level===a){w=u[n];let k,S;m?(k=t.md.options.quotes[2],S=t.md.options.quotes[3]):(k=t.md.options.quotes[0],S=t.md.options.quotes[1]),r.content=Or(r.content,f.index,S),e[w.token].content=Or(e[w.token].content,w.pos,k),c+=S.length-1,w.token===o&&(c+=k.length-1),s=r.content,d=s.length,u.length=n;continue e}}l?u.push({token:o,pos:f.index,single:m,level:a}):p&&m&&(r.content=Or(r.content,f.index,Fi))}}}function d0(e){if(e.md.options.typographer)for(let t=e.tokens.length-1;t>=0;t--)e.tokens[t].type!=="inline"||!c0.test(e.tokens[t].content)||l0(e.tokens[t].children,e)}function f0(e){let t,n;const u=e.tokens,o=u.length;for(let r=0;r<o;r++){if(u[r].type!=="inline")continue;const a=u[r].children,s=a.length;for(t=0;t<s;t++)a[t].type==="text_special"&&(a[t].type="text");for(t=n=0;t<s;t++)a[t].type==="text"&&t+1<s&&a[t+1].type==="text"?a[t+1].content=a[t].content+a[t+1].content:(t!==n&&(a[n]=a[t]),n++);t!==n&&(a.length=n)}}const Ru=[["normalize",Yl],["block",Kl],["inline",Ql],["linkify",t0],["replacements",s0],["smartquotes",d0],["text_join",f0]];function Vu(){this.ruler=new He;for(let e=0;e<Ru.length;e++)this.ruler.push(Ru[e][0],Ru[e][1])}Vu.prototype.process=function(e){const t=this.ruler.getRules("");for(let n=0,u=t.length;n<u;n++)t[n](e)},Vu.prototype.State=Ei;function mt(e,t,n,u){this.src=e,this.md=t,this.env=n,this.tokens=u,this.bMarks=[],this.eMarks=[],this.tShift=[],this.sCount=[],this.bsCount=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.ddIndent=-1,this.listIndent=-1,this.parentType="root",this.level=0;const o=this.src;for(let r=0,a=0,s=0,c=0,d=o.length,f=!1;a<d;a++){const l=o.charCodeAt(a);if(!f)if(le(l)){s++,l===9?c+=4-c%4:c++;continue}else f=!0;(l===10||a===d-1)&&(l!==10&&a++,this.bMarks.push(r),this.eMarks.push(a),this.tShift.push(s),this.sCount.push(c),this.bsCount.push(0),f=!1,s=0,c=0,r=a+1)}this.bMarks.push(o.length),this.eMarks.push(o.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}mt.prototype.push=function(e,t,n){const u=new rt(e,t,n);return u.block=!0,n<0&&this.level--,u.level=this.level,n>0&&this.level++,this.tokens.push(u),u},mt.prototype.isEmpty=function(t){return this.bMarks[t]+this.tShift[t]>=this.eMarks[t]},mt.prototype.skipEmptyLines=function(t){for(let n=this.lineMax;t<n&&!(this.bMarks[t]+this.tShift[t]<this.eMarks[t]);t++);return t},mt.prototype.skipSpaces=function(t){for(let n=this.src.length;t<n;t++){const u=this.src.charCodeAt(t);if(!le(u))break}return t},mt.prototype.skipSpacesBack=function(t,n){if(t<=n)return t;for(;t>n;)if(!le(this.src.charCodeAt(--t)))return t+1;return t},mt.prototype.skipChars=function(t,n){for(let u=this.src.length;t<u&&this.src.charCodeAt(t)===n;t++);return t},mt.prototype.skipCharsBack=function(t,n,u){if(t<=u)return t;for(;t>u;)if(n!==this.src.charCodeAt(--t))return t+1;return t},mt.prototype.getLines=function(t,n,u,o){if(t>=n)return"";const r=new Array(n-t);for(let a=0,s=t;s<n;s++,a++){let c=0;const d=this.bMarks[s];let f=d,l;for(s+1<n||o?l=this.eMarks[s]+1:l=this.eMarks[s];f<l&&c<u;){const p=this.src.charCodeAt(f);if(le(p))p===9?c+=4-(c+this.bsCount[s])%4:c++;else if(f-d<this.tShift[s])c++;else break;f++}c>u?r[a]=new Array(c-u+1).join(" ")+this.src.slice(f,l):r[a]=this.src.slice(f,l)}return r.join("")},mt.prototype.Token=rt;const h0=65536;function Mu(e,t){const n=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];return e.src.slice(n,u)}function Di(e){const t=[],n=e.length;let u=0,o=e.charCodeAt(u),r=!1,a=0,s="";for(;u<n;)o===124&&(r?(s+=e.substring(a,u-1),a=u):(t.push(s+e.substring(a,u)),s="",a=u+1)),r=o===92,u++,o=e.charCodeAt(u);return t.push(s+e.substring(a)),t}function p0(e,t,n,u){if(t+2>n)return!1;let o=t+1;if(e.sCount[o]<e.blkIndent||e.sCount[o]-e.blkIndent>=4)return!1;let r=e.bMarks[o]+e.tShift[o];if(r>=e.eMarks[o])return!1;const a=e.src.charCodeAt(r++);if(a!==124&&a!==45&&a!==58||r>=e.eMarks[o])return!1;const s=e.src.charCodeAt(r++);if(s!==124&&s!==45&&s!==58&&!le(s)||a===45&&le(s))return!1;for(;r<e.eMarks[o];){const w=e.src.charCodeAt(r);if(w!==124&&w!==45&&w!==58&&!le(w))return!1;r++}let c=Mu(e,t+1),d=c.split("|");const f=[];for(let w=0;w<d.length;w++){const k=d[w].trim();if(!k){if(w===0||w===d.length-1)continue;return!1}if(!/^:?-+:?$/.test(k))return!1;k.charCodeAt(k.length-1)===58?f.push(k.charCodeAt(0)===58?"center":"right"):k.charCodeAt(0)===58?f.push("left"):f.push("")}if(c=Mu(e,t).trim(),c.indexOf("|")===-1||e.sCount[t]-e.blkIndent>=4)return!1;d=Di(c),d.length&&d[0]===""&&d.shift(),d.length&&d[d.length-1]===""&&d.pop();const l=d.length;if(l===0||l!==f.length)return!1;if(u)return!0;const p=e.parentType;e.parentType="table";const m=e.md.block.ruler.getRules("blockquote"),h=e.push("table_open","table",1),y=[t,0];h.map=y;const x=e.push("thead_open","thead",1);x.map=[t,t+1];const v=e.push("tr_open","tr",1);v.map=[t,t+1];for(let w=0;w<d.length;w++){const k=e.push("th_open","th",1);f[w]&&(k.attrs=[["style","text-align:"+f[w]]]);const S=e.push("inline","",0);S.content=d[w].trim(),S.children=[],e.push("th_close","th",-1)}e.push("tr_close","tr",-1),e.push("thead_close","thead",-1);let g,b=0;for(o=t+2;o<n&&!(e.sCount[o]<e.blkIndent);o++){let w=!1;for(let S=0,_=m.length;S<_;S++)if(m[S](e,o,n,!0)){w=!0;break}if(w||(c=Mu(e,o).trim(),!c)||e.sCount[o]-e.blkIndent>=4||(d=Di(c),d.length&&d[0]===""&&d.shift(),d.length&&d[d.length-1]===""&&d.pop(),b+=l-d.length,b>h0))break;if(o===t+2){const S=e.push("tbody_open","tbody",1);S.map=g=[t+2,0]}const k=e.push("tr_open","tr",1);k.map=[o,o+1];for(let S=0;S<l;S++){const _=e.push("td_open","td",1);f[S]&&(_.attrs=[["style","text-align:"+f[S]]]);const E=e.push("inline","",0);E.content=d[S]?d[S].trim():"",E.children=[],e.push("td_close","td",-1)}e.push("tr_close","tr",-1)}return g&&(e.push("tbody_close","tbody",-1),g[1]=o),e.push("table_close","table",-1),y[1]=o,e.parentType=p,e.line=o,!0}function m0(e,t,n){if(e.sCount[t]-e.blkIndent<4)return!1;let u=t+1,o=u;for(;u<n;){if(e.isEmpty(u)){u++;continue}if(e.sCount[u]-e.blkIndent>=4){u++,o=u;continue}break}e.line=o;const r=e.push("code_block","code",0);return r.content=e.getLines(t,o,4+e.blkIndent,!1)+`
16
- `,r.map=[t,e.line],!0}function g0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||o+3>r)return!1;const a=e.src.charCodeAt(o);if(a!==126&&a!==96)return!1;let s=o;o=e.skipChars(o,a);let c=o-s;if(c<3)return!1;const d=e.src.slice(s,o),f=e.src.slice(o,r);if(a===96&&f.indexOf(String.fromCharCode(a))>=0)return!1;if(u)return!0;let l=t,p=!1;for(;l++,!(l>=n||(o=s=e.bMarks[l]+e.tShift[l],r=e.eMarks[l],o<r&&e.sCount[l]<e.blkIndent));)if(e.src.charCodeAt(o)===a&&!(e.sCount[l]-e.blkIndent>=4)&&(o=e.skipChars(o,a),!(o-s<c)&&(o=e.skipSpaces(o),!(o<r)))){p=!0;break}c=e.sCount[t],e.line=l+(p?1:0);const m=e.push("fence","code",0);return m.info=f,m.content=e.getLines(t+1,l,c,!0),m.markup=d,m.map=[t,e.line],!0}function b0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];const a=e.lineMax;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(o)!==62)return!1;if(u)return!0;const s=[],c=[],d=[],f=[],l=e.md.block.ruler.getRules("blockquote"),p=e.parentType;e.parentType="blockquote";let m=!1,h;for(h=t;h<n;h++){const b=e.sCount[h]<e.blkIndent;if(o=e.bMarks[h]+e.tShift[h],r=e.eMarks[h],o>=r)break;if(e.src.charCodeAt(o++)===62&&!b){let k=e.sCount[h]+1,S,_;e.src.charCodeAt(o)===32?(o++,k++,_=!1,S=!0):e.src.charCodeAt(o)===9?(S=!0,(e.bsCount[h]+k)%4===3?(o++,k++,_=!1):_=!0):S=!1;let E=k;for(s.push(e.bMarks[h]),e.bMarks[h]=o;o<r;){const W=e.src.charCodeAt(o);if(le(W))W===9?E+=4-(E+e.bsCount[h]+(_?1:0))%4:E++;else break;o++}m=o>=r,c.push(e.bsCount[h]),e.bsCount[h]=e.sCount[h]+1+(S?1:0),d.push(e.sCount[h]),e.sCount[h]=E-k,f.push(e.tShift[h]),e.tShift[h]=o-e.bMarks[h];continue}if(m)break;let w=!1;for(let k=0,S=l.length;k<S;k++)if(l[k](e,h,n,!0)){w=!0;break}if(w){e.lineMax=h,e.blkIndent!==0&&(s.push(e.bMarks[h]),c.push(e.bsCount[h]),f.push(e.tShift[h]),d.push(e.sCount[h]),e.sCount[h]-=e.blkIndent);break}s.push(e.bMarks[h]),c.push(e.bsCount[h]),f.push(e.tShift[h]),d.push(e.sCount[h]),e.sCount[h]=-1}const y=e.blkIndent;e.blkIndent=0;const x=e.push("blockquote_open","blockquote",1);x.markup=">";const v=[t,0];x.map=v,e.md.block.tokenize(e,t,h);const g=e.push("blockquote_close","blockquote",-1);g.markup=">",e.lineMax=a,e.parentType=p,v[1]=e.line;for(let b=0;b<f.length;b++)e.bMarks[b+t]=s[b],e.tShift[b+t]=f[b],e.sCount[b+t]=d[b],e.bsCount[b+t]=c[b];return e.blkIndent=y,!0}function y0(e,t,n,u){const o=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let r=e.bMarks[t]+e.tShift[t];const a=e.src.charCodeAt(r++);if(a!==42&&a!==45&&a!==95)return!1;let s=1;for(;r<o;){const d=e.src.charCodeAt(r++);if(d!==a&&!le(d))return!1;d===a&&s++}if(s<3)return!1;if(u)return!0;e.line=t+1;const c=e.push("hr","hr",0);return c.map=[t,e.line],c.markup=Array(s+1).join(String.fromCharCode(a)),!0}function Ti(e,t){const n=e.eMarks[t];let u=e.bMarks[t]+e.tShift[t];const o=e.src.charCodeAt(u++);if(o!==42&&o!==45&&o!==43)return-1;if(u<n){const r=e.src.charCodeAt(u);if(!le(r))return-1}return u}function Ni(e,t){const n=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];let o=n;if(o+1>=u)return-1;let r=e.src.charCodeAt(o++);if(r<48||r>57)return-1;for(;;){if(o>=u)return-1;if(r=e.src.charCodeAt(o++),r>=48&&r<=57){if(o-n>=10)return-1;continue}if(r===41||r===46)break;return-1}return o<u&&(r=e.src.charCodeAt(o),!le(r))?-1:o}function x0(e,t){const n=e.level+2;for(let u=t+2,o=e.tokens.length-2;u<o;u++)e.tokens[u].level===n&&e.tokens[u].type==="paragraph_open"&&(e.tokens[u+2].hidden=!0,e.tokens[u].hidden=!0,u+=2)}function w0(e,t,n,u){let o,r,a,s,c=t,d=!0;if(e.sCount[c]-e.blkIndent>=4||e.listIndent>=0&&e.sCount[c]-e.listIndent>=4&&e.sCount[c]<e.blkIndent)return!1;let f=!1;u&&e.parentType==="paragraph"&&e.sCount[c]>=e.blkIndent&&(f=!0);let l,p,m;if((m=Ni(e,c))>=0){if(l=!0,a=e.bMarks[c]+e.tShift[c],p=Number(e.src.slice(a,m-1)),f&&p!==1)return!1}else if((m=Ti(e,c))>=0)l=!1;else return!1;if(f&&e.skipSpaces(m)>=e.eMarks[c])return!1;if(u)return!0;const h=e.src.charCodeAt(m-1),y=e.tokens.length;l?(s=e.push("ordered_list_open","ol",1),p!==1&&(s.attrs=[["start",p]])):s=e.push("bullet_list_open","ul",1);const x=[c,0];s.map=x,s.markup=String.fromCharCode(h);let v=!1;const g=e.md.block.ruler.getRules("list"),b=e.parentType;for(e.parentType="list";c<n;){r=m,o=e.eMarks[c];const w=e.sCount[c]+m-(e.bMarks[c]+e.tShift[c]);let k=w;for(;r<o;){const H=e.src.charCodeAt(r);if(H===9)k+=4-(k+e.bsCount[c])%4;else if(H===32)k++;else break;r++}const S=r;let _;S>=o?_=1:_=k-w,_>4&&(_=1);const E=w+_;s=e.push("list_item_open","li",1),s.markup=String.fromCharCode(h);const W=[c,0];s.map=W,l&&(s.info=e.src.slice(a,m-1));const B=e.tight,I=e.tShift[c],M=e.sCount[c],D=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=E,e.tight=!0,e.tShift[c]=S-e.bMarks[c],e.sCount[c]=k,S>=o&&e.isEmpty(c+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,c,n,!0),(!e.tight||v)&&(d=!1),v=e.line-c>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=D,e.tShift[c]=I,e.sCount[c]=M,e.tight=B,s=e.push("list_item_close","li",-1),s.markup=String.fromCharCode(h),c=e.line,W[1]=c,c>=n||e.sCount[c]<e.blkIndent||e.sCount[c]-e.blkIndent>=4)break;let j=!1;for(let H=0,F=g.length;H<F;H++)if(g[H](e,c,n,!0)){j=!0;break}if(j)break;if(l){if(m=Ni(e,c),m<0)break;a=e.bMarks[c]+e.tShift[c]}else if(m=Ti(e,c),m<0)break;if(h!==e.src.charCodeAt(m-1))break}return l?s=e.push("ordered_list_close","ol",-1):s=e.push("bullet_list_close","ul",-1),s.markup=String.fromCharCode(h),x[1]=c,e.line=c,e.parentType=b,d&&x0(e,y),!0}function v0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t],a=t+1;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(o)!==91)return!1;function s(g){const b=e.lineMax;if(g>=b||e.isEmpty(g))return null;let w=!1;if(e.sCount[g]-e.blkIndent>3&&(w=!0),e.sCount[g]<0&&(w=!0),!w){const _=e.md.block.ruler.getRules("reference"),E=e.parentType;e.parentType="reference";let W=!1;for(let B=0,I=_.length;B<I;B++)if(_[B](e,g,b,!0)){W=!0;break}if(e.parentType=E,W)return null}const k=e.bMarks[g]+e.tShift[g],S=e.eMarks[g];return e.src.slice(k,S+1)}let c=e.src.slice(o,r+1);r=c.length;let d=-1;for(o=1;o<r;o++){const g=c.charCodeAt(o);if(g===91)return!1;if(g===93){d=o;break}else if(g===10){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}else if(g===92&&(o++,o<r&&c.charCodeAt(o)===10)){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}}if(d<0||c.charCodeAt(d+1)!==58)return!1;for(o=d+2;o<r;o++){const g=c.charCodeAt(o);if(g===10){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}else if(!le(g))break}const f=e.md.helpers.parseLinkDestination(c,o,r);if(!f.ok)return!1;const l=e.md.normalizeLink(f.str);if(!e.md.validateLink(l))return!1;o=f.pos;const p=o,m=a,h=o;for(;o<r;o++){const g=c.charCodeAt(o);if(g===10){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}else if(!le(g))break}let y=e.md.helpers.parseLinkTitle(c,o,r);for(;y.can_continue;){const g=s(a);if(g===null)break;c+=g,o=r,r=c.length,a++,y=e.md.helpers.parseLinkTitle(c,o,r,y)}let x;for(o<r&&h!==o&&y.ok?(x=y.str,o=y.pos):(x="",o=p,a=m);o<r;){const g=c.charCodeAt(o);if(!le(g))break;o++}if(o<r&&c.charCodeAt(o)!==10&&x)for(x="",o=p,a=m;o<r;){const g=c.charCodeAt(o);if(!le(g))break;o++}if(o<r&&c.charCodeAt(o)!==10)return!1;const v=Lr(c.slice(1,d));return v?(u||(typeof e.env.references>"u"&&(e.env.references={}),typeof e.env.references[v]>"u"&&(e.env.references[v]={title:x,href:l}),e.line=a),!0):!1}const A0=["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"],k0="[a-zA-Z_:][a-zA-Z0-9:._-]*",C0="(?:"+"[^\"'=<>`\\x00-\\x20]+"+"|"+"'[^']*'"+"|"+'"[^"]*"'+")",Li="<[A-Za-z][A-Za-z0-9\\-]*"+("(?:\\s+"+k0+"(?:\\s*=\\s*"+C0+")?)")+"*\\s*\\/?>",Oi="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",E0="<!---?>|<!--(?:[^-]|-[^-]|--[^>])*-->",_0="<[?][\\s\\S]*?[?]>",S0="<![A-Za-z][^>]*>",F0="<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",D0=new RegExp("^(?:"+Li+"|"+Oi+"|"+E0+"|"+_0+"|"+S0+"|"+F0+")"),T0=new RegExp("^(?:"+Li+"|"+Oi+")"),dn=[[/^<(script|pre|style|textarea)(?=(\s|>|$))/i,/<\/(script|pre|style|textarea)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[new RegExp("^</?("+A0.join("|")+")(?=(\\s|/?>|$))","i"),/^$/,!0],[new RegExp(T0.source+"\\s*$"),/^$/,!1]];function N0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||!e.md.options.html||e.src.charCodeAt(o)!==60)return!1;let a=e.src.slice(o,r),s=0;for(;s<dn.length&&!dn[s][0].test(a);s++);if(s===dn.length)return!1;if(u)return dn[s][2];let c=t+1;if(!dn[s][1].test(a)){for(;c<n&&!(e.sCount[c]<e.blkIndent);c++)if(o=e.bMarks[c]+e.tShift[c],r=e.eMarks[c],a=e.src.slice(o,r),dn[s][1].test(a)){a.length!==0&&c++;break}}e.line=c;const d=e.push("html_block","",0);return d.map=[t,c],d.content=e.getLines(t,c,e.blkIndent,!0),!0}function L0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let a=e.src.charCodeAt(o);if(a!==35||o>=r)return!1;let s=1;for(a=e.src.charCodeAt(++o);a===35&&o<r&&s<=6;)s++,a=e.src.charCodeAt(++o);if(s>6||o<r&&!le(a))return!1;if(u)return!0;r=e.skipSpacesBack(r,o);const c=e.skipCharsBack(r,35,o);c>o&&le(e.src.charCodeAt(c-1))&&(r=c),e.line=t+1;const d=e.push("heading_open","h"+String(s),1);d.markup="########".slice(0,s),d.map=[t,e.line];const f=e.push("inline","",0);f.content=e.src.slice(o,r).trim(),f.map=[t,e.line],f.children=[];const l=e.push("heading_close","h"+String(s),-1);return l.markup="########".slice(0,s),!0}function O0(e,t,n){const u=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;const o=e.parentType;e.parentType="paragraph";let r=0,a,s=t+1;for(;s<n&&!e.isEmpty(s);s++){if(e.sCount[s]-e.blkIndent>3)continue;if(e.sCount[s]>=e.blkIndent){let m=e.bMarks[s]+e.tShift[s];const h=e.eMarks[s];if(m<h&&(a=e.src.charCodeAt(m),(a===45||a===61)&&(m=e.skipChars(m,a),m=e.skipSpaces(m),m>=h))){r=a===61?1:2;break}}if(e.sCount[s]<0)continue;let p=!1;for(let m=0,h=u.length;m<h;m++)if(u[m](e,s,n,!0)){p=!0;break}if(p)break}if(!r)return!1;const c=e.getLines(t,s,e.blkIndent,!1).trim();e.line=s+1;const d=e.push("heading_open","h"+String(r),1);d.markup=String.fromCharCode(a),d.map=[t,e.line];const f=e.push("inline","",0);f.content=c,f.map=[t,e.line-1],f.children=[];const l=e.push("heading_close","h"+String(r),-1);return l.markup=String.fromCharCode(a),e.parentType=o,!0}function I0(e,t,n){const u=e.md.block.ruler.getRules("paragraph"),o=e.parentType;let r=t+1;for(e.parentType="paragraph";r<n&&!e.isEmpty(r);r++){if(e.sCount[r]-e.blkIndent>3||e.sCount[r]<0)continue;let d=!1;for(let f=0,l=u.length;f<l;f++)if(u[f](e,r,n,!0)){d=!0;break}if(d)break}const a=e.getLines(t,r,e.blkIndent,!1).trim();e.line=r;const s=e.push("paragraph_open","p",1);s.map=[t,e.line];const c=e.push("inline","",0);return c.content=a,c.map=[t,e.line],c.children=[],e.push("paragraph_close","p",-1),e.parentType=o,!0}const Ir=[["table",p0,["paragraph","reference"]],["code",m0],["fence",g0,["paragraph","reference","blockquote","list"]],["blockquote",b0,["paragraph","reference","blockquote","list"]],["hr",y0,["paragraph","reference","blockquote","list"]],["list",w0,["paragraph","reference","blockquote"]],["reference",v0],["html_block",N0,["paragraph","reference","blockquote"]],["heading",L0,["paragraph","reference","blockquote"]],["lheading",O0],["paragraph",I0]];function Pr(){this.ruler=new He;for(let e=0;e<Ir.length;e++)this.ruler.push(Ir[e][0],Ir[e][1],{alt:(Ir[e][2]||[]).slice()})}Pr.prototype.tokenize=function(e,t,n){const u=this.ruler.getRules(""),o=u.length,r=e.md.options.maxNesting;let a=t,s=!1;for(;a<n&&(e.line=a=e.skipEmptyLines(a),!(a>=n||e.sCount[a]<e.blkIndent));){if(e.level>=r){e.line=n;break}const c=e.line;let d=!1;for(let f=0;f<o;f++)if(d=u[f](e,a,n,!1),d){if(c>=e.line)throw new Error("block rule didn't increment state.line");break}if(!d)throw new Error("none of the block rules matched");e.tight=!s,e.isEmpty(e.line-1)&&(s=!0),a=e.line,a<n&&e.isEmpty(a)&&(s=!0,a++,e.line=a)}},Pr.prototype.parse=function(e,t,n,u){if(!e)return;const o=new this.State(e,t,n,u);this.tokenize(o,o.line,o.lineMax)},Pr.prototype.State=mt;function Bn(e,t,n,u){this.src=e,this.env=n,this.md=t,this.tokens=u,this.tokens_meta=Array(u.length),this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache={},this.delimiters=[],this._prev_delimiters=[],this.backticks={},this.backticksScanned=!1,this.linkLevel=0}Bn.prototype.pushPending=function(){const e=new rt("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e},Bn.prototype.push=function(e,t,n){this.pending&&this.pushPending();const u=new rt(e,t,n);let o=null;return n<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),u.level=this.level,n>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],o={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(u),this.tokens_meta.push(o),u},Bn.prototype.scanDelims=function(e,t){const n=this.posMax,u=this.src.charCodeAt(e),o=e>0?this.src.charCodeAt(e-1):32;let r=e;for(;r<n&&this.src.charCodeAt(r)===u;)r++;const a=r-e,s=r<n?this.src.charCodeAt(r):32,c=Mn(o)||Vn(String.fromCharCode(o)),d=Mn(s)||Vn(String.fromCharCode(s)),f=Rn(o),l=Rn(s),p=!l&&(!d||f||c),m=!f&&(!c||l||d);return{can_open:p&&(t||!m||c),can_close:m&&(t||!p||d),length:a}},Bn.prototype.Token=rt;function P0(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}function R0(e,t){let n=e.pos;for(;n<e.posMax&&!P0(e.src.charCodeAt(n));)n++;return n===e.pos?!1:(t||(e.pending+=e.src.slice(e.pos,n)),e.pos=n,!0)}const V0=/(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;function M0(e,t){if(!e.md.options.linkify||e.linkLevel>0)return!1;const n=e.pos,u=e.posMax;if(n+3>u||e.src.charCodeAt(n)!==58||e.src.charCodeAt(n+1)!==47||e.src.charCodeAt(n+2)!==47)return!1;const o=e.pending.match(V0);if(!o)return!1;const r=o[1],a=e.md.linkify.matchAtStart(e.src.slice(n-r.length));if(!a)return!1;let s=a.url;if(s.length<=r.length)return!1;let c=s.length;for(;c>0&&s.charCodeAt(c-1)===42;)c--;c!==s.length&&(s=s.slice(0,c));const d=e.md.normalizeLink(s);if(!e.md.validateLink(d))return!1;if(!t){e.pending=e.pending.slice(0,-r.length);const f=e.push("link_open","a",1);f.attrs=[["href",d]],f.markup="linkify",f.info="auto";const l=e.push("text","",0);l.content=e.md.normalizeLinkText(s);const p=e.push("link_close","a",-1);p.markup="linkify",p.info="auto"}return e.pos+=s.length-r.length,!0}function B0(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==10)return!1;const u=e.pending.length-1,o=e.posMax;if(!t)if(u>=0&&e.pending.charCodeAt(u)===32)if(u>=1&&e.pending.charCodeAt(u-1)===32){let r=u-1;for(;r>=1&&e.pending.charCodeAt(r-1)===32;)r--;e.pending=e.pending.slice(0,r),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0);else e.push("softbreak","br",0);for(n++;n<o&&le(e.src.charCodeAt(n));)n++;return e.pos=n,!0}const Bu=[];for(let e=0;e<256;e++)Bu.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){Bu[e.charCodeAt(0)]=1});function z0(e,t){let n=e.pos;const u=e.posMax;if(e.src.charCodeAt(n)!==92||(n++,n>=u))return!1;let o=e.src.charCodeAt(n);if(o===10){for(t||e.push("hardbreak","br",0),n++;n<u&&(o=e.src.charCodeAt(n),!!le(o));)n++;return e.pos=n,!0}let r=e.src[n];if(o>=55296&&o<=56319&&n+1<u){const s=e.src.charCodeAt(n+1);s>=56320&&s<=57343&&(r+=e.src[n+1],n++)}const a="\\"+r;if(!t){const s=e.push("text_special","",0);o<256&&Bu[o]!==0?s.content=r:s.content=a,s.markup=a,s.info="escape"}return e.pos=n+1,!0}function j0(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==96)return!1;const o=n;n++;const r=e.posMax;for(;n<r&&e.src.charCodeAt(n)===96;)n++;const a=e.src.slice(o,n),s=a.length;if(e.backticksScanned&&(e.backticks[s]||0)<=o)return t||(e.pending+=a),e.pos+=s,!0;let c=n,d;for(;(d=e.src.indexOf("`",c))!==-1;){for(c=d+1;c<r&&e.src.charCodeAt(c)===96;)c++;const f=c-d;if(f===s){if(!t){const l=e.push("code_inline","code",0);l.markup=a,l.content=e.src.slice(n,d).replace(/\n/g," ").replace(/^ (.+) $/,"$1")}return e.pos=c,!0}e.backticks[f]=d}return e.backticksScanned=!0,t||(e.pending+=a),e.pos+=s,!0}function H0(e,t){const n=e.pos,u=e.src.charCodeAt(n);if(t||u!==126)return!1;const o=e.scanDelims(e.pos,!0);let r=o.length;const a=String.fromCharCode(u);if(r<2)return!1;let s;r%2&&(s=e.push("text","",0),s.content=a,r--);for(let c=0;c<r;c+=2)s=e.push("text","",0),s.content=a+a,e.delimiters.push({marker:u,length:0,token:e.tokens.length-1,end:-1,open:o.can_open,close:o.can_close});return e.pos+=o.length,!0}function Ii(e,t){let n;const u=[],o=t.length;for(let r=0;r<o;r++){const a=t[r];if(a.marker!==126||a.end===-1)continue;const s=t[a.end];n=e.tokens[a.token],n.type="s_open",n.tag="s",n.nesting=1,n.markup="~~",n.content="",n=e.tokens[s.token],n.type="s_close",n.tag="s",n.nesting=-1,n.markup="~~",n.content="",e.tokens[s.token-1].type==="text"&&e.tokens[s.token-1].content==="~"&&u.push(s.token-1)}for(;u.length;){const r=u.pop();let a=r+1;for(;a<e.tokens.length&&e.tokens[a].type==="s_close";)a++;a--,r!==a&&(n=e.tokens[a],e.tokens[a]=e.tokens[r],e.tokens[r]=n)}}function $0(e){const t=e.tokens_meta,n=e.tokens_meta.length;Ii(e,e.delimiters);for(let u=0;u<n;u++)t[u]&&t[u].delimiters&&Ii(e,t[u].delimiters)}const Pi={tokenize:H0,postProcess:$0};function U0(e,t){const n=e.pos,u=e.src.charCodeAt(n);if(t||u!==95&&u!==42)return!1;const o=e.scanDelims(e.pos,u===42);for(let r=0;r<o.length;r++){const a=e.push("text","",0);a.content=String.fromCharCode(u),e.delimiters.push({marker:u,length:o.length,token:e.tokens.length-1,end:-1,open:o.can_open,close:o.can_close})}return e.pos+=o.length,!0}function Ri(e,t){const n=t.length;for(let u=n-1;u>=0;u--){const o=t[u];if(o.marker!==95&&o.marker!==42||o.end===-1)continue;const r=t[o.end],a=u>0&&t[u-1].end===o.end+1&&t[u-1].marker===o.marker&&t[u-1].token===o.token-1&&t[o.end+1].token===r.token+1,s=String.fromCharCode(o.marker),c=e.tokens[o.token];c.type=a?"strong_open":"em_open",c.tag=a?"strong":"em",c.nesting=1,c.markup=a?s+s:s,c.content="";const d=e.tokens[r.token];d.type=a?"strong_close":"em_close",d.tag=a?"strong":"em",d.nesting=-1,d.markup=a?s+s:s,d.content="",a&&(e.tokens[t[u-1].token].content="",e.tokens[t[o.end+1].token].content="",u--)}}function W0(e){const t=e.tokens_meta,n=e.tokens_meta.length;Ri(e,e.delimiters);for(let u=0;u<n;u++)t[u]&&t[u].delimiters&&Ri(e,t[u].delimiters)}const Vi={tokenize:U0,postProcess:W0};function G0(e,t){let n,u,o,r,a="",s="",c=e.pos,d=!0;if(e.src.charCodeAt(e.pos)!==91)return!1;const f=e.pos,l=e.posMax,p=e.pos+1,m=e.md.helpers.parseLinkLabel(e,e.pos,!0);if(m<0)return!1;let h=m+1;if(h<l&&e.src.charCodeAt(h)===40){for(d=!1,h++;h<l&&(n=e.src.charCodeAt(h),!(!le(n)&&n!==10));h++);if(h>=l)return!1;if(c=h,o=e.md.helpers.parseLinkDestination(e.src,h,e.posMax),o.ok){for(a=e.md.normalizeLink(o.str),e.md.validateLink(a)?h=o.pos:a="",c=h;h<l&&(n=e.src.charCodeAt(h),!(!le(n)&&n!==10));h++);if(o=e.md.helpers.parseLinkTitle(e.src,h,e.posMax),h<l&&c!==h&&o.ok)for(s=o.str,h=o.pos;h<l&&(n=e.src.charCodeAt(h),!(!le(n)&&n!==10));h++);}(h>=l||e.src.charCodeAt(h)!==41)&&(d=!0),h++}if(d){if(typeof e.env.references>"u")return!1;if(h<l&&e.src.charCodeAt(h)===91?(c=h+1,h=e.md.helpers.parseLinkLabel(e,h),h>=0?u=e.src.slice(c,h++):h=m+1):h=m+1,u||(u=e.src.slice(p,m)),r=e.env.references[Lr(u)],!r)return e.pos=f,!1;a=r.href,s=r.title}if(!t){e.pos=p,e.posMax=m;const y=e.push("link_open","a",1),x=[["href",a]];y.attrs=x,s&&x.push(["title",s]),e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=h,e.posMax=l,!0}function q0(e,t){let n,u,o,r,a,s,c,d,f="";const l=e.pos,p=e.posMax;if(e.src.charCodeAt(e.pos)!==33||e.src.charCodeAt(e.pos+1)!==91)return!1;const m=e.pos+2,h=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(h<0)return!1;if(r=h+1,r<p&&e.src.charCodeAt(r)===40){for(r++;r<p&&(n=e.src.charCodeAt(r),!(!le(n)&&n!==10));r++);if(r>=p)return!1;for(d=r,s=e.md.helpers.parseLinkDestination(e.src,r,e.posMax),s.ok&&(f=e.md.normalizeLink(s.str),e.md.validateLink(f)?r=s.pos:f=""),d=r;r<p&&(n=e.src.charCodeAt(r),!(!le(n)&&n!==10));r++);if(s=e.md.helpers.parseLinkTitle(e.src,r,e.posMax),r<p&&d!==r&&s.ok)for(c=s.str,r=s.pos;r<p&&(n=e.src.charCodeAt(r),!(!le(n)&&n!==10));r++);else c="";if(r>=p||e.src.charCodeAt(r)!==41)return e.pos=l,!1;r++}else{if(typeof e.env.references>"u")return!1;if(r<p&&e.src.charCodeAt(r)===91?(d=r+1,r=e.md.helpers.parseLinkLabel(e,r),r>=0?o=e.src.slice(d,r++):r=h+1):r=h+1,o||(o=e.src.slice(m,h)),a=e.env.references[Lr(o)],!a)return e.pos=l,!1;f=a.href,c=a.title}if(!t){u=e.src.slice(m,h);const y=[];e.md.inline.parse(u,e.md,e.env,y);const x=e.push("image","img",0),v=[["src",f],["alt",""]];x.attrs=v,x.children=y,x.content=u,c&&v.push(["title",c])}return e.pos=r,e.posMax=p,!0}const X0=/^([a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/,Z0=/^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/;function Y0(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==60)return!1;const u=e.pos,o=e.posMax;for(;;){if(++n>=o)return!1;const a=e.src.charCodeAt(n);if(a===60)return!1;if(a===62)break}const r=e.src.slice(u+1,n);if(Z0.test(r)){const a=e.md.normalizeLink(r);if(!e.md.validateLink(a))return!1;if(!t){const s=e.push("link_open","a",1);s.attrs=[["href",a]],s.markup="autolink",s.info="auto";const c=e.push("text","",0);c.content=e.md.normalizeLinkText(r);const d=e.push("link_close","a",-1);d.markup="autolink",d.info="auto"}return e.pos+=r.length+2,!0}if(X0.test(r)){const a=e.md.normalizeLink("mailto:"+r);if(!e.md.validateLink(a))return!1;if(!t){const s=e.push("link_open","a",1);s.attrs=[["href",a]],s.markup="autolink",s.info="auto";const c=e.push("text","",0);c.content=e.md.normalizeLinkText(r);const d=e.push("link_close","a",-1);d.markup="autolink",d.info="auto"}return e.pos+=r.length+2,!0}return!1}function K0(e){return/^<a[>\s]/i.test(e)}function Q0(e){return/^<\/a\s*>/i.test(e)}function J0(e){const t=e|32;return t>=97&&t<=122}function ed(e,t){if(!e.md.options.html)return!1;const n=e.posMax,u=e.pos;if(e.src.charCodeAt(u)!==60||u+2>=n)return!1;const o=e.src.charCodeAt(u+1);if(o!==33&&o!==63&&o!==47&&!J0(o))return!1;const r=e.src.slice(u).match(D0);if(!r)return!1;if(!t){const a=e.push("html_inline","",0);a.content=r[0],K0(a.content)&&e.linkLevel++,Q0(a.content)&&e.linkLevel--}return e.pos+=r[0].length,!0}const td=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,nd=/^&([a-z][a-z0-9]{1,31});/i;function rd(e,t){const n=e.pos,u=e.posMax;if(e.src.charCodeAt(n)!==38||n+1>=u)return!1;if(e.src.charCodeAt(n+1)===35){const r=e.src.slice(n).match(td);if(r){if(!t){const a=r[1][0].toLowerCase()==="x"?parseInt(r[1].slice(1),16):parseInt(r[1],10),s=e.push("text_special","",0);s.content=Pu(a)?Nr(a):Nr(65533),s.markup=r[0],s.info="entity"}return e.pos+=r[0].length,!0}}else{const r=e.src.slice(n).match(nd);if(r){const a=Ai(r[0]);if(a!==r[0]){if(!t){const s=e.push("text_special","",0);s.content=a,s.markup=r[0],s.info="entity"}return e.pos+=r[0].length,!0}}}return!1}function Mi(e){const t={},n=e.length;if(!n)return;let u=0,o=-2;const r=[];for(let a=0;a<n;a++){const s=e[a];if(r.push(0),(e[u].marker!==s.marker||o!==s.token-1)&&(u=a),o=s.token,s.length=s.length||0,!s.close)continue;t.hasOwnProperty(s.marker)||(t[s.marker]=[-1,-1,-1,-1,-1,-1]);const c=t[s.marker][(s.open?3:0)+s.length%3];let d=u-r[u]-1,f=d;for(;d>c;d-=r[d]+1){const l=e[d];if(l.marker===s.marker&&l.open&&l.end<0){let p=!1;if((l.close||s.open)&&(l.length+s.length)%3===0&&(l.length%3!==0||s.length%3!==0)&&(p=!0),!p){const m=d>0&&!e[d-1].open?r[d-1]+1:0;r[a]=a-d+m,r[d]=m,s.open=!1,l.end=a,l.close=!1,f=-1,o=-2;break}}}f!==-1&&(t[s.marker][(s.open?3:0)+(s.length||0)%3]=f)}}function ud(e){const t=e.tokens_meta,n=e.tokens_meta.length;Mi(e.delimiters);for(let u=0;u<n;u++)t[u]&&t[u].delimiters&&Mi(t[u].delimiters)}function od(e){let t,n,u=0;const o=e.tokens,r=e.tokens.length;for(t=n=0;t<r;t++)o[t].nesting<0&&u--,o[t].level=u,o[t].nesting>0&&u++,o[t].type==="text"&&t+1<r&&o[t+1].type==="text"?o[t+1].content=o[t].content+o[t+1].content:(t!==n&&(o[n]=o[t]),n++);t!==n&&(o.length=n)}const zu=[["text",R0],["linkify",M0],["newline",B0],["escape",z0],["backticks",j0],["strikethrough",Pi.tokenize],["emphasis",Vi.tokenize],["link",G0],["image",q0],["autolink",Y0],["html_inline",ed],["entity",rd]],ju=[["balance_pairs",ud],["strikethrough",Pi.postProcess],["emphasis",Vi.postProcess],["fragments_join",od]];function zn(){this.ruler=new He;for(let e=0;e<zu.length;e++)this.ruler.push(zu[e][0],zu[e][1]);this.ruler2=new He;for(let e=0;e<ju.length;e++)this.ruler2.push(ju[e][0],ju[e][1])}zn.prototype.skipToken=function(e){const t=e.pos,n=this.ruler.getRules(""),u=n.length,o=e.md.options.maxNesting,r=e.cache;if(typeof r[t]<"u"){e.pos=r[t];return}let a=!1;if(e.level<o){for(let s=0;s<u;s++)if(e.level++,a=n[s](e,!0),e.level--,a){if(t>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;a||e.pos++,r[t]=e.pos},zn.prototype.tokenize=function(e){const t=this.ruler.getRules(""),n=t.length,u=e.posMax,o=e.md.options.maxNesting;for(;e.pos<u;){const r=e.pos;let a=!1;if(e.level<o){for(let s=0;s<n;s++)if(a=t[s](e,!1),a){if(r>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}if(a){if(e.pos>=u)break;continue}e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},zn.prototype.parse=function(e,t,n,u){const o=new this.State(e,t,n,u);this.tokenize(o);const r=this.ruler2.getRules(""),a=r.length;for(let s=0;s<a;s++)r[s](o)},zn.prototype.State=Bn;function id(e){const t={};e=e||{},t.src_Any=bi.source,t.src_Cc=yi.source,t.src_Z=wi.source,t.src_P=Nu.source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");const n="[><|]";return t.src_pseudo_letter="(?:(?!"+n+"|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|"+n+"|"+t.src_ZPCc+")(?!"+(e["---"]?"-(?!--)|":"-|")+"_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|"+n+`|[()[\\]{}.,"'?!\\-;]).|\\[(?:(?!`+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+`|["]).)+\\"|\\'(?:(?!`+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]|$)|"+(e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+",(?!"+t.src_ZCc+"|$)|;(?!"+t.src_ZCc+"|$)|\\!+(?!"+t.src_ZCc+"|[!]|$)|\\?(?!"+t.src_ZCc+"|[?]|$))+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy="(^|"+n+'|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}function Hu(e){return Array.prototype.slice.call(arguments,1).forEach(function(n){n&&Object.keys(n).forEach(function(u){e[u]=n[u]})}),e}function Rr(e){return Object.prototype.toString.call(e)}function ad(e){return Rr(e)==="[object String]"}function sd(e){return Rr(e)==="[object Object]"}function cd(e){return Rr(e)==="[object RegExp]"}function Bi(e){return Rr(e)==="[object Function]"}function ld(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}const zi={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};function dd(e){return Object.keys(e||{}).reduce(function(t,n){return t||zi.hasOwnProperty(n)},!1)}const fd={"http:":{validate:function(e,t,n){const u=e.slice(t);return n.re.http||(n.re.http=new RegExp("^\\/\\/"+n.re.src_auth+n.re.src_host_port_strict+n.re.src_path,"i")),n.re.http.test(u)?u.match(n.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,n){const u=e.slice(t);return n.re.no_http||(n.re.no_http=new RegExp("^"+n.re.src_auth+"(?:localhost|(?:(?:"+n.re.src_domain+")\\.)+"+n.re.src_domain_root+")"+n.re.src_port+n.re.src_host_terminator+n.re.src_path,"i")),n.re.no_http.test(u)?t>=3&&e[t-3]===":"||t>=3&&e[t-3]==="/"?0:u.match(n.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,n){const u=e.slice(t);return n.re.mailto||(n.re.mailto=new RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(u)?u.match(n.re.mailto)[0].length:0}}},hd="a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]",pd="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");function md(e){e.__index__=-1,e.__text_cache__=""}function gd(e){return function(t,n){const u=t.slice(n);return e.test(u)?u.match(e)[0].length:0}}function ji(){return function(e,t){t.normalize(e)}}function Vr(e){const t=e.re=id(e.__opts__),n=e.__tlds__.slice();e.onCompile(),e.__tlds_replaced__||n.push(hd),n.push(t.src_xn),t.src_tlds=n.join("|");function u(s){return s.replace("%TLDS%",t.src_tlds)}t.email_fuzzy=RegExp(u(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(u(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(u(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(u(t.tpl_host_fuzzy_test),"i");const o=[];e.__compiled__={};function r(s,c){throw new Error('(LinkifyIt) Invalid schema "'+s+'": '+c)}Object.keys(e.__schemas__).forEach(function(s){const c=e.__schemas__[s];if(c===null)return;const d={validate:null,link:null};if(e.__compiled__[s]=d,sd(c)){cd(c.validate)?d.validate=gd(c.validate):Bi(c.validate)?d.validate=c.validate:r(s,c),Bi(c.normalize)?d.normalize=c.normalize:c.normalize?r(s,c):d.normalize=ji();return}if(ad(c)){o.push(s);return}r(s,c)}),o.forEach(function(s){e.__compiled__[e.__schemas__[s]]&&(e.__compiled__[s].validate=e.__compiled__[e.__schemas__[s]].validate,e.__compiled__[s].normalize=e.__compiled__[e.__schemas__[s]].normalize)}),e.__compiled__[""]={validate:null,normalize:ji()};const a=Object.keys(e.__compiled__).filter(function(s){return s.length>0&&e.__compiled__[s]}).map(ld).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+a+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+a+")","ig"),e.re.schema_at_start=RegExp("^"+e.re.schema_search.source,"i"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),md(e)}function bd(e,t){const n=e.__index__,u=e.__last_index__,o=e.__text_cache__.slice(n,u);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=u+t,this.raw=o,this.text=o,this.url=o}function $u(e,t){const n=new bd(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function We(e,t){if(!(this instanceof We))return new We(e,t);t||dd(e)&&(t=e,e={}),this.__opts__=Hu({},zi,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=Hu({},fd,e),this.__compiled__={},this.__tlds__=pd,this.__tlds_replaced__=!1,this.re={},Vr(this)}We.prototype.add=function(t,n){return this.__schemas__[t]=n,Vr(this),this},We.prototype.set=function(t){return this.__opts__=Hu(this.__opts__,t),this},We.prototype.test=function(t){if(this.__text_cache__=t,this.__index__=-1,!t.length)return!1;let n,u,o,r,a,s,c,d,f;if(this.re.schema_test.test(t)){for(c=this.re.schema_search,c.lastIndex=0;(n=c.exec(t))!==null;)if(r=this.testSchemaAt(t,n[2],c.lastIndex),r){this.__schema__=n[2],this.__index__=n.index+n[1].length,this.__last_index__=n.index+n[0].length+r;break}}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(d=t.search(this.re.host_fuzzy_test),d>=0&&(this.__index__<0||d<this.__index__)&&(u=t.match(this.__opts__.fuzzyIP?this.re.link_fuzzy:this.re.link_no_ip_fuzzy))!==null&&(a=u.index+u[1].length,(this.__index__<0||a<this.__index__)&&(this.__schema__="",this.__index__=a,this.__last_index__=u.index+u[0].length))),this.__opts__.fuzzyEmail&&this.__compiled__["mailto:"]&&(f=t.indexOf("@"),f>=0&&(o=t.match(this.re.email_fuzzy))!==null&&(a=o.index+o[1].length,s=o.index+o[0].length,(this.__index__<0||a<this.__index__||a===this.__index__&&s>this.__last_index__)&&(this.__schema__="mailto:",this.__index__=a,this.__last_index__=s))),this.__index__>=0},We.prototype.pretest=function(t){return this.re.pretest.test(t)},We.prototype.testSchemaAt=function(t,n,u){return this.__compiled__[n.toLowerCase()]?this.__compiled__[n.toLowerCase()].validate(t,u,this):0},We.prototype.match=function(t){const n=[];let u=0;this.__index__>=0&&this.__text_cache__===t&&(n.push($u(this,u)),u=this.__last_index__);let o=u?t.slice(u):t;for(;this.test(o);)n.push($u(this,u)),o=o.slice(this.__last_index__),u+=this.__last_index__;return n.length?n:null},We.prototype.matchAtStart=function(t){if(this.__text_cache__=t,this.__index__=-1,!t.length)return null;const n=this.re.schema_at_start.exec(t);if(!n)return null;const u=this.testSchemaAt(t,n[2],n[0].length);return u?(this.__schema__=n[2],this.__index__=n.index+n[1].length,this.__last_index__=n.index+n[0].length+u,$u(this,0)):null},We.prototype.tlds=function(t,n){return t=Array.isArray(t)?t:[t],n?(this.__tlds__=this.__tlds__.concat(t).sort().filter(function(u,o,r){return u!==r[o-1]}).reverse(),Vr(this),this):(this.__tlds__=t.slice(),this.__tlds_replaced__=!0,Vr(this),this)},We.prototype.normalize=function(t){t.schema||(t.url="http://"+t.url),t.schema==="mailto:"&&!/^mailto:/i.test(t.url)&&(t.url="mailto:"+t.url)},We.prototype.onCompile=function(){};const fn=2147483647,gt=36,Uu=1,jn=26,yd=38,xd=700,Hi=72,$i=128,Ui="-",wd=/^xn--/,vd=/[^\0-\x7F]/,Ad=/[\x2E\u3002\uFF0E\uFF61]/g,kd={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},Wu=gt-Uu,bt=Math.floor,Gu=String.fromCharCode;function It(e){throw new RangeError(kd[e])}function Cd(e,t){const n=[];let u=e.length;for(;u--;)n[u]=t(e[u]);return n}function Wi(e,t){const n=e.split("@");let u="";n.length>1&&(u=n[0]+"@",e=n[1]),e=e.replace(Ad,".");const o=e.split("."),r=Cd(o,t).join(".");return u+r}function Gi(e){const t=[];let n=0;const u=e.length;for(;n<u;){const o=e.charCodeAt(n++);if(o>=55296&&o<=56319&&n<u){const r=e.charCodeAt(n++);(r&64512)==56320?t.push(((o&1023)<<10)+(r&1023)+65536):(t.push(o),n--)}else t.push(o)}return t}const Ed=e=>String.fromCodePoint(...e),_d=function(e){return e>=48&&e<58?26+(e-48):e>=65&&e<91?e-65:e>=97&&e<123?e-97:gt},qi=function(e,t){return e+22+75*(e<26)-((t!=0)<<5)},Xi=function(e,t,n){let u=0;for(e=n?bt(e/xd):e>>1,e+=bt(e/t);e>Wu*jn>>1;u+=gt)e=bt(e/Wu);return bt(u+(Wu+1)*e/(e+yd))},Zi=function(e){const t=[],n=e.length;let u=0,o=$i,r=Hi,a=e.lastIndexOf(Ui);a<0&&(a=0);for(let s=0;s<a;++s)e.charCodeAt(s)>=128&&It("not-basic"),t.push(e.charCodeAt(s));for(let s=a>0?a+1:0;s<n;){const c=u;for(let f=1,l=gt;;l+=gt){s>=n&&It("invalid-input");const p=_d(e.charCodeAt(s++));p>=gt&&It("invalid-input"),p>bt((fn-u)/f)&&It("overflow"),u+=p*f;const m=l<=r?Uu:l>=r+jn?jn:l-r;if(p<m)break;const h=gt-m;f>bt(fn/h)&&It("overflow"),f*=h}const d=t.length+1;r=Xi(u-c,d,c==0),bt(u/d)>fn-o&&It("overflow"),o+=bt(u/d),u%=d,t.splice(u++,0,o)}return String.fromCodePoint(...t)},Yi=function(e){const t=[];e=Gi(e);const n=e.length;let u=$i,o=0,r=Hi;for(const c of e)c<128&&t.push(Gu(c));const a=t.length;let s=a;for(a&&t.push(Ui);s<n;){let c=fn;for(const f of e)f>=u&&f<c&&(c=f);const d=s+1;c-u>bt((fn-o)/d)&&It("overflow"),o+=(c-u)*d,u=c;for(const f of e)if(f<u&&++o>fn&&It("overflow"),f===u){let l=o;for(let p=gt;;p+=gt){const m=p<=r?Uu:p>=r+jn?jn:p-r;if(l<m)break;const h=l-m,y=gt-m;t.push(Gu(qi(m+h%y,0))),l=bt(h/y)}t.push(Gu(qi(l,0))),r=Xi(o,d,s===a),o=0,++s}++o,++u}return t.join("")},Ki={version:"2.3.1",ucs2:{decode:Gi,encode:Ed},decode:Zi,encode:Yi,toASCII:function(e){return Wi(e,function(t){return vd.test(t)?"xn--"+Yi(t):t})},toUnicode:function(e){return Wi(e,function(t){return wd.test(t)?Zi(t.slice(4).toLowerCase()):t})}},Sd={default:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}},zero:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","fragments_join"]}}},commonmark:{options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","fragments_join"]}}}},Fd=/^(vbscript|javascript|file|data):/,Dd=/^data:image\/(gif|png|jpeg|webp);/;function Td(e){const t=e.trim().toLowerCase();return Fd.test(t)?Dd.test(t):!0}const Qi=["http:","https:","mailto:"];function Nd(e){const t=Tu(e,!0);if(t.hostname&&(!t.protocol||Qi.indexOf(t.protocol)>=0))try{t.hostname=Ki.toASCII(t.hostname)}catch{}return Pn(Du(t))}function Ld(e){const t=Tu(e,!0);if(t.hostname&&(!t.protocol||Qi.indexOf(t.protocol)>=0))try{t.hostname=Ki.toUnicode(t.hostname)}catch{}return sn(Du(t),sn.defaultChars+"%")}function Ge(e,t){if(!(this instanceof Ge))return new Ge(e,t);t||Iu(e)||(t=e||{},e="default"),this.inline=new zn,this.block=new Pr,this.core=new Vu,this.renderer=new ln,this.linkify=new We,this.validateLink=Td,this.normalizeLink=Nd,this.normalizeLinkText=Ld,this.utils=$l,this.helpers=Tr({},ql),this.options={},this.configure(e),t&&this.set(t)}Ge.prototype.set=function(e){return Tr(this.options,e),this},Ge.prototype.configure=function(e){const t=this;if(Iu(e)){const n=e;if(e=Sd[n],!e)throw new Error('Wrong `markdown-it` preset "'+n+'", check name')}if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach(function(n){e.components[n].rules&&t[n].ruler.enableOnly(e.components[n].rules),e.components[n].rules2&&t[n].ruler2.enableOnly(e.components[n].rules2)}),this},Ge.prototype.enable=function(e,t){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(o){n=n.concat(this[o].ruler.enable(e,!0))},this),n=n.concat(this.inline.ruler2.enable(e,!0));const u=e.filter(function(o){return n.indexOf(o)<0});if(u.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+u);return this},Ge.prototype.disable=function(e,t){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(o){n=n.concat(this[o].ruler.disable(e,!0))},this),n=n.concat(this.inline.ruler2.disable(e,!0));const u=e.filter(function(o){return n.indexOf(o)<0});if(u.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+u);return this},Ge.prototype.use=function(e){const t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},Ge.prototype.parse=function(e,t){if(typeof e!="string")throw new Error("Input data should be a String");const n=new this.core.State(e,this,t);return this.core.process(n),n.tokens},Ge.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},Ge.prototype.parseInline=function(e,t){const n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens},Ge.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)};/*! @license DOMPurify 3.3.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.3/LICENSE */const{entries:Ji,setPrototypeOf:ea,isFrozen:Od,getPrototypeOf:Id,getOwnPropertyDescriptor:Pd}=Object;let{freeze:Ve,seal:et,create:Mr}=Object,{apply:qu,construct:Xu}=typeof Reflect<"u"&&Reflect;Ve||(Ve=function(t){return t}),et||(et=function(t){return t}),qu||(qu=function(t,n){for(var u=arguments.length,o=new Array(u>2?u-2:0),r=2;r<u;r++)o[r-2]=arguments[r];return t.apply(n,o)}),Xu||(Xu=function(t){for(var n=arguments.length,u=new Array(n>1?n-1:0),o=1;o<n;o++)u[o-1]=arguments[o];return new t(...u)});const Br=Be(Array.prototype.forEach),Rd=Be(Array.prototype.lastIndexOf),ta=Be(Array.prototype.pop),Hn=Be(Array.prototype.push),Vd=Be(Array.prototype.splice),zr=Be(String.prototype.toLowerCase),Zu=Be(String.prototype.toString),Yu=Be(String.prototype.match),$n=Be(String.prototype.replace),Md=Be(String.prototype.indexOf),Bd=Be(String.prototype.trim),qe=Be(Object.prototype.hasOwnProperty),Me=Be(RegExp.prototype.test),Un=zd(TypeError);function Be(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,u=new Array(n>1?n-1:0),o=1;o<n;o++)u[o-1]=arguments[o];return qu(e,t,u)}}function zd(e){return function(){for(var t=arguments.length,n=new Array(t),u=0;u<t;u++)n[u]=arguments[u];return Xu(e,n)}}function oe(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:zr;ea&&ea(e,null);let u=t.length;for(;u--;){let o=t[u];if(typeof o=="string"){const r=n(o);r!==o&&(Od(t)||(t[u]=r),o=r)}e[o]=!0}return e}function jd(e){for(let t=0;t<e.length;t++)qe(e,t)||(e[t]=null);return e}function yt(e){const t=Mr(null);for(const[n,u]of Ji(e))qe(e,n)&&(Array.isArray(u)?t[n]=jd(u):u&&typeof u=="object"&&u.constructor===Object?t[n]=yt(u):t[n]=u);return t}function Wn(e,t){for(;e!==null;){const u=Pd(e,t);if(u){if(u.get)return Be(u.get);if(typeof u.value=="function")return Be(u.value)}e=Id(e)}function n(){return null}return n}const na=Ve(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Ku=Ve(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Qu=Ve(["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"]),Hd=Ve(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Ju=Ve(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),$d=Ve(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ra=Ve(["#text"]),ua=Ve(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),eo=Ve(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),oa=Ve(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),jr=Ve(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Ud=et(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Wd=et(/<%[\w\W]*|[\w\W]*%>/gm),Gd=et(/\$\{[\w\W]*/gm),qd=et(/^data-[\-\w.\u00B7-\uFFFF]+$/),Xd=et(/^aria-[\-\w]+$/),ia=et(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Zd=et(/^(?:\w+script|data):/i),Yd=et(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),aa=et(/^html$/i),Kd=et(/^[a-z][.\w]*(-[.\w]+)+$/i);var sa=Object.freeze({__proto__:null,ARIA_ATTR:Xd,ATTR_WHITESPACE:Yd,CUSTOM_ELEMENT:Kd,DATA_ATTR:qd,DOCTYPE_NAME:aa,ERB_EXPR:Wd,IS_ALLOWED_URI:ia,IS_SCRIPT_OR_DATA:Zd,MUSTACHE_EXPR:Ud,TMPLIT_EXPR:Gd});const Gn={element:1,text:3,progressingInstruction:7,comment:8,document:9},Qd=function(){return typeof window>"u"?null:window},Jd=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let u=null;const o="data-tt-policy-suffix";n&&n.hasAttribute(o)&&(u=n.getAttribute(o));const r="dompurify"+(u?"#"+u:"");try{return t.createPolicy(r,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+r+" could not be created."),null}},ca=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function la(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Qd();const t=J=>la(J);if(t.version="3.3.3",t.removed=[],!e||!e.document||e.document.nodeType!==Gn.document||!e.Element)return t.isSupported=!1,t;let{document:n}=e;const u=n,o=u.currentScript,{DocumentFragment:r,HTMLTemplateElement:a,Node:s,Element:c,NodeFilter:d,NamedNodeMap:f=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:l,DOMParser:p,trustedTypes:m}=e,h=c.prototype,y=Wn(h,"cloneNode"),x=Wn(h,"remove"),v=Wn(h,"nextSibling"),g=Wn(h,"childNodes"),b=Wn(h,"parentNode");if(typeof a=="function"){const J=n.createElement("template");J.content&&J.content.ownerDocument&&(n=J.content.ownerDocument)}let w,k="";const{implementation:S,createNodeIterator:_,createDocumentFragment:E,getElementsByTagName:W}=n,{importNode:B}=u;let I=ca();t.isSupported=typeof Ji=="function"&&typeof b=="function"&&S&&S.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:M,ERB_EXPR:D,TMPLIT_EXPR:j,DATA_ATTR:H,ARIA_ATTR:F,IS_SCRIPT_OR_DATA:V,ATTR_WHITESPACE:O,CUSTOM_ELEMENT:$}=sa;let{IS_ALLOWED_URI:re}=sa,te=null;const P=oe({},[...na,...Ku,...Qu,...Ju,...ra]);let R=null;const N=oe({},[...ua,...eo,...oa,...jr]);let L=Object.seal(Mr(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),U=null,K=null;const Z=Object.seal(Mr(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Y=!0,ue=!0,ce=!1,De=!0,Te=!1,ht=!0,Pe=!1,Dn=!1,Ht=!1,St=!1,gu=!1,bu=!1,Ac=!0,kc=!1;const xp="user-content-";let Uo=!0,Ar=!1,Tn={},Ct=null;const Wo=oe({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Cc=null;const Ec=oe({},["audio","video","img","source","image","track"]);let Go=null;const _c=oe({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),yu="http://www.w3.org/1998/Math/MathML",xu="http://www.w3.org/2000/svg",Ft="http://www.w3.org/1999/xhtml";let Nn=Ft,qo=!1,Xo=null;const wp=oe({},[yu,xu,Ft],Zu);let wu=oe({},["mi","mo","mn","ms","mtext"]),vu=oe({},["annotation-xml"]);const vp=oe({},["title","style","font","a","script"]);let kr=null;const Ap=["application/xhtml+xml","text/html"],kp="text/html";let Ce=null,Ln=null;const Cp=n.createElement("form"),Sc=function(C){return C instanceof RegExp||C instanceof Function},Zo=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Ln&&Ln===C)){if((!C||typeof C!="object")&&(C={}),C=yt(C),kr=Ap.indexOf(C.PARSER_MEDIA_TYPE)===-1?kp:C.PARSER_MEDIA_TYPE,Ce=kr==="application/xhtml+xml"?Zu:zr,te=qe(C,"ALLOWED_TAGS")?oe({},C.ALLOWED_TAGS,Ce):P,R=qe(C,"ALLOWED_ATTR")?oe({},C.ALLOWED_ATTR,Ce):N,Xo=qe(C,"ALLOWED_NAMESPACES")?oe({},C.ALLOWED_NAMESPACES,Zu):wp,Go=qe(C,"ADD_URI_SAFE_ATTR")?oe(yt(_c),C.ADD_URI_SAFE_ATTR,Ce):_c,Cc=qe(C,"ADD_DATA_URI_TAGS")?oe(yt(Ec),C.ADD_DATA_URI_TAGS,Ce):Ec,Ct=qe(C,"FORBID_CONTENTS")?oe({},C.FORBID_CONTENTS,Ce):Wo,U=qe(C,"FORBID_TAGS")?oe({},C.FORBID_TAGS,Ce):yt({}),K=qe(C,"FORBID_ATTR")?oe({},C.FORBID_ATTR,Ce):yt({}),Tn=qe(C,"USE_PROFILES")?C.USE_PROFILES:!1,Y=C.ALLOW_ARIA_ATTR!==!1,ue=C.ALLOW_DATA_ATTR!==!1,ce=C.ALLOW_UNKNOWN_PROTOCOLS||!1,De=C.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Te=C.SAFE_FOR_TEMPLATES||!1,ht=C.SAFE_FOR_XML!==!1,Pe=C.WHOLE_DOCUMENT||!1,St=C.RETURN_DOM||!1,gu=C.RETURN_DOM_FRAGMENT||!1,bu=C.RETURN_TRUSTED_TYPE||!1,Ht=C.FORCE_BODY||!1,Ac=C.SANITIZE_DOM!==!1,kc=C.SANITIZE_NAMED_PROPS||!1,Uo=C.KEEP_CONTENT!==!1,Ar=C.IN_PLACE||!1,re=C.ALLOWED_URI_REGEXP||ia,Nn=C.NAMESPACE||Ft,wu=C.MATHML_TEXT_INTEGRATION_POINTS||wu,vu=C.HTML_INTEGRATION_POINTS||vu,L=C.CUSTOM_ELEMENT_HANDLING||{},C.CUSTOM_ELEMENT_HANDLING&&Sc(C.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(L.tagNameCheck=C.CUSTOM_ELEMENT_HANDLING.tagNameCheck),C.CUSTOM_ELEMENT_HANDLING&&Sc(C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(L.attributeNameCheck=C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),C.CUSTOM_ELEMENT_HANDLING&&typeof C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(L.allowCustomizedBuiltInElements=C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Te&&(ue=!1),gu&&(St=!0),Tn&&(te=oe({},ra),R=Mr(null),Tn.html===!0&&(oe(te,na),oe(R,ua)),Tn.svg===!0&&(oe(te,Ku),oe(R,eo),oe(R,jr)),Tn.svgFilters===!0&&(oe(te,Qu),oe(R,eo),oe(R,jr)),Tn.mathMl===!0&&(oe(te,Ju),oe(R,oa),oe(R,jr))),qe(C,"ADD_TAGS")||(Z.tagCheck=null),qe(C,"ADD_ATTR")||(Z.attributeCheck=null),C.ADD_TAGS&&(typeof C.ADD_TAGS=="function"?Z.tagCheck=C.ADD_TAGS:(te===P&&(te=yt(te)),oe(te,C.ADD_TAGS,Ce))),C.ADD_ATTR&&(typeof C.ADD_ATTR=="function"?Z.attributeCheck=C.ADD_ATTR:(R===N&&(R=yt(R)),oe(R,C.ADD_ATTR,Ce))),C.ADD_URI_SAFE_ATTR&&oe(Go,C.ADD_URI_SAFE_ATTR,Ce),C.FORBID_CONTENTS&&(Ct===Wo&&(Ct=yt(Ct)),oe(Ct,C.FORBID_CONTENTS,Ce)),C.ADD_FORBID_CONTENTS&&(Ct===Wo&&(Ct=yt(Ct)),oe(Ct,C.ADD_FORBID_CONTENTS,Ce)),Uo&&(te["#text"]=!0),Pe&&oe(te,["html","head","body"]),te.table&&(oe(te,["tbody"]),delete U.tbody),C.TRUSTED_TYPES_POLICY){if(typeof C.TRUSTED_TYPES_POLICY.createHTML!="function")throw Un('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof C.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Un('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');w=C.TRUSTED_TYPES_POLICY,k=w.createHTML("")}else w===void 0&&(w=Jd(m,o)),w!==null&&typeof k=="string"&&(k=w.createHTML(""));Ve&&Ve(C),Ln=C}},Fc=oe({},[...Ku,...Qu,...Hd]),Dc=oe({},[...Ju,...$d]),Ep=function(C){let z=b(C);(!z||!z.tagName)&&(z={namespaceURI:Nn,tagName:"template"});const Q=zr(C.tagName),ge=zr(z.tagName);return Xo[C.namespaceURI]?C.namespaceURI===xu?z.namespaceURI===Ft?Q==="svg":z.namespaceURI===yu?Q==="svg"&&(ge==="annotation-xml"||wu[ge]):!!Fc[Q]:C.namespaceURI===yu?z.namespaceURI===Ft?Q==="math":z.namespaceURI===xu?Q==="math"&&vu[ge]:!!Dc[Q]:C.namespaceURI===Ft?z.namespaceURI===xu&&!vu[ge]||z.namespaceURI===yu&&!wu[ge]?!1:!Dc[Q]&&(vp[Q]||!Fc[Q]):!!(kr==="application/xhtml+xml"&&Xo[C.namespaceURI]):!1},Et=function(C){Hn(t.removed,{element:C});try{b(C).removeChild(C)}catch{x(C)}},rn=function(C,z){try{Hn(t.removed,{attribute:z.getAttributeNode(C),from:z})}catch{Hn(t.removed,{attribute:null,from:z})}if(z.removeAttribute(C),C==="is")if(St||gu)try{Et(z)}catch{}else try{z.setAttribute(C,"")}catch{}},Tc=function(C){let z=null,Q=null;if(Ht)C="<remove></remove>"+C;else{const ve=Yu(C,/^[\r\n\t ]+/);Q=ve&&ve[0]}kr==="application/xhtml+xml"&&Nn===Ft&&(C='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+C+"</body></html>");const ge=w?w.createHTML(C):C;if(Nn===Ft)try{z=new p().parseFromString(ge,kr)}catch{}if(!z||!z.documentElement){z=S.createDocument(Nn,"template",null);try{z.documentElement.innerHTML=qo?k:ge}catch{}}const Re=z.body||z.documentElement;return C&&Q&&Re.insertBefore(n.createTextNode(Q),Re.childNodes[0]||null),Nn===Ft?W.call(z,Pe?"html":"body")[0]:Pe?z.documentElement:Re},Nc=function(C){return _.call(C.ownerDocument||C,C,d.SHOW_ELEMENT|d.SHOW_COMMENT|d.SHOW_TEXT|d.SHOW_PROCESSING_INSTRUCTION|d.SHOW_CDATA_SECTION,null)},Yo=function(C){return C instanceof l&&(typeof C.nodeName!="string"||typeof C.textContent!="string"||typeof C.removeChild!="function"||!(C.attributes instanceof f)||typeof C.removeAttribute!="function"||typeof C.setAttribute!="function"||typeof C.namespaceURI!="string"||typeof C.insertBefore!="function"||typeof C.hasChildNodes!="function")},Lc=function(C){return typeof s=="function"&&C instanceof s};function Dt(J,C,z){Br(J,Q=>{Q.call(t,C,z,Ln)})}const Oc=function(C){let z=null;if(Dt(I.beforeSanitizeElements,C,null),Yo(C))return Et(C),!0;const Q=Ce(C.nodeName);if(Dt(I.uponSanitizeElement,C,{tagName:Q,allowedTags:te}),ht&&C.hasChildNodes()&&!Lc(C.firstElementChild)&&Me(/<[/\w!]/g,C.innerHTML)&&Me(/<[/\w!]/g,C.textContent)||C.nodeType===Gn.progressingInstruction||ht&&C.nodeType===Gn.comment&&Me(/<[/\w]/g,C.data))return Et(C),!0;if(!(Z.tagCheck instanceof Function&&Z.tagCheck(Q))&&(!te[Q]||U[Q])){if(!U[Q]&&Pc(Q)&&(L.tagNameCheck instanceof RegExp&&Me(L.tagNameCheck,Q)||L.tagNameCheck instanceof Function&&L.tagNameCheck(Q)))return!1;if(Uo&&!Ct[Q]){const ge=b(C)||C.parentNode,Re=g(C)||C.childNodes;if(Re&&ge){const ve=Re.length;for(let Ue=ve-1;Ue>=0;--Ue){const Tt=y(Re[Ue],!0);Tt.__removalCount=(C.__removalCount||0)+1,ge.insertBefore(Tt,v(C))}}}return Et(C),!0}return C instanceof c&&!Ep(C)||(Q==="noscript"||Q==="noembed"||Q==="noframes")&&Me(/<\/no(script|embed|frames)/i,C.innerHTML)?(Et(C),!0):(Te&&C.nodeType===Gn.text&&(z=C.textContent,Br([M,D,j],ge=>{z=$n(z,ge," ")}),C.textContent!==z&&(Hn(t.removed,{element:C.cloneNode()}),C.textContent=z)),Dt(I.afterSanitizeElements,C,null),!1)},Ic=function(C,z,Q){if(K[z]||Ac&&(z==="id"||z==="name")&&(Q in n||Q in Cp))return!1;if(!(ue&&!K[z]&&Me(H,z))){if(!(Y&&Me(F,z))){if(!(Z.attributeCheck instanceof Function&&Z.attributeCheck(z,C))){if(!R[z]||K[z]){if(!(Pc(C)&&(L.tagNameCheck instanceof RegExp&&Me(L.tagNameCheck,C)||L.tagNameCheck instanceof Function&&L.tagNameCheck(C))&&(L.attributeNameCheck instanceof RegExp&&Me(L.attributeNameCheck,z)||L.attributeNameCheck instanceof Function&&L.attributeNameCheck(z,C))||z==="is"&&L.allowCustomizedBuiltInElements&&(L.tagNameCheck instanceof RegExp&&Me(L.tagNameCheck,Q)||L.tagNameCheck instanceof Function&&L.tagNameCheck(Q))))return!1}else if(!Go[z]){if(!Me(re,$n(Q,O,""))){if(!((z==="src"||z==="xlink:href"||z==="href")&&C!=="script"&&Md(Q,"data:")===0&&Cc[C])){if(!(ce&&!Me(V,$n(Q,O,"")))){if(Q)return!1}}}}}}}return!0},Pc=function(C){return C!=="annotation-xml"&&Yu(C,$)},Rc=function(C){Dt(I.beforeSanitizeAttributes,C,null);const{attributes:z}=C;if(!z||Yo(C))return;const Q={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:R,forceKeepAttr:void 0};let ge=z.length;for(;ge--;){const Re=z[ge],{name:ve,namespaceURI:Ue,value:Tt}=Re,On=Ce(ve),Ko=Tt;let Le=ve==="value"?Ko:Bd(Ko);if(Q.attrName=On,Q.attrValue=Le,Q.keepAttr=!0,Q.forceKeepAttr=void 0,Dt(I.uponSanitizeAttribute,C,Q),Le=Q.attrValue,kc&&(On==="id"||On==="name")&&(rn(ve,C),Le=xp+Le),ht&&Me(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,Le)){rn(ve,C);continue}if(On==="attributename"&&Yu(Le,"href")){rn(ve,C);continue}if(Q.forceKeepAttr)continue;if(!Q.keepAttr){rn(ve,C);continue}if(!De&&Me(/\/>/i,Le)){rn(ve,C);continue}Te&&Br([M,D,j],Mc=>{Le=$n(Le,Mc," ")});const Vc=Ce(C.nodeName);if(!Ic(Vc,On,Le)){rn(ve,C);continue}if(w&&typeof m=="object"&&typeof m.getAttributeType=="function"&&!Ue)switch(m.getAttributeType(Vc,On)){case"TrustedHTML":{Le=w.createHTML(Le);break}case"TrustedScriptURL":{Le=w.createScriptURL(Le);break}}if(Le!==Ko)try{Ue?C.setAttributeNS(Ue,ve,Le):C.setAttribute(ve,Le),Yo(C)?Et(C):ta(t.removed)}catch{rn(ve,C)}}Dt(I.afterSanitizeAttributes,C,null)},_p=function J(C){let z=null;const Q=Nc(C);for(Dt(I.beforeSanitizeShadowDOM,C,null);z=Q.nextNode();)Dt(I.uponSanitizeShadowNode,z,null),Oc(z),Rc(z),z.content instanceof r&&J(z.content);Dt(I.afterSanitizeShadowDOM,C,null)};return t.sanitize=function(J){let C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},z=null,Q=null,ge=null,Re=null;if(qo=!J,qo&&(J="<!-->"),typeof J!="string"&&!Lc(J))if(typeof J.toString=="function"){if(J=J.toString(),typeof J!="string")throw Un("dirty is not a string, aborting")}else throw Un("toString is not a function");if(!t.isSupported)return J;if(Dn||Zo(C),t.removed=[],typeof J=="string"&&(Ar=!1),Ar){if(J.nodeName){const Tt=Ce(J.nodeName);if(!te[Tt]||U[Tt])throw Un("root node is forbidden and cannot be sanitized in-place")}}else if(J instanceof s)z=Tc("<!---->"),Q=z.ownerDocument.importNode(J,!0),Q.nodeType===Gn.element&&Q.nodeName==="BODY"||Q.nodeName==="HTML"?z=Q:z.appendChild(Q);else{if(!St&&!Te&&!Pe&&J.indexOf("<")===-1)return w&&bu?w.createHTML(J):J;if(z=Tc(J),!z)return St?null:bu?k:""}z&&Ht&&Et(z.firstChild);const ve=Nc(Ar?J:z);for(;ge=ve.nextNode();)Oc(ge),Rc(ge),ge.content instanceof r&&_p(ge.content);if(Ar)return J;if(St){if(gu)for(Re=E.call(z.ownerDocument);z.firstChild;)Re.appendChild(z.firstChild);else Re=z;return(R.shadowroot||R.shadowrootmode)&&(Re=B.call(u,Re,!0)),Re}let Ue=Pe?z.outerHTML:z.innerHTML;return Pe&&te["!doctype"]&&z.ownerDocument&&z.ownerDocument.doctype&&z.ownerDocument.doctype.name&&Me(aa,z.ownerDocument.doctype.name)&&(Ue="<!DOCTYPE "+z.ownerDocument.doctype.name+`>
17
- `+Ue),Te&&Br([M,D,j],Tt=>{Ue=$n(Ue,Tt," ")}),w&&bu?w.createHTML(Ue):Ue},t.setConfig=function(){let J=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Zo(J),Dn=!0},t.clearConfig=function(){Ln=null,Dn=!1},t.isValidAttribute=function(J,C,z){Ln||Zo({});const Q=Ce(J),ge=Ce(C);return Ic(Q,ge,z)},t.addHook=function(J,C){typeof C=="function"&&Hn(I[J],C)},t.removeHook=function(J,C){if(C!==void 0){const z=Rd(I[J],C);return z===-1?void 0:Vd(I[J],z,1)[0]}return ta(I[J])},t.removeHooks=function(J){I[J]=[]},t.removeAllHooks=function(){I=ca()},t}var ef=la();const da={content:{type:Object,required:!0}},tf=new Ge({html:!0,linkify:!0});function nf(e){const t=e.split(`
13
+ `:">",r},cn.prototype.renderInline=function(e,t,n){let u="";const o=this.rules;for(let r=0,a=e.length;r<a;r++){const s=e[r].type;typeof o[s]<"u"?u+=o[s](e,r,t,n,this):u+=this.renderToken(e,r,t)}return u},cn.prototype.renderInlineAsText=function(e,t,n){let u="";for(let o=0,r=e.length;o<r;o++)switch(e[o].type){case"text":u+=e[o].content;break;case"image":u+=this.renderInlineAsText(e[o].children,t,n);break;case"html_inline":case"html_block":u+=e[o].content;break;case"softbreak":case"hardbreak":u+=`
14
+ `;break}return u},cn.prototype.render=function(e,t,n){let u="";const o=this.rules;for(let r=0,a=e.length;r<a;r++){const s=e[r].type;s==="inline"?u+=this.renderInline(e[r].children,t,n):typeof o[s]<"u"?u+=o[s](e,r,t,n,this):u+=this.renderToken(e,r,t,n)}return u};function Ue(){this.__rules__=[],this.__cache__=null}Ue.prototype.__find__=function(e){for(let t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return-1},Ue.prototype.__compile__=function(){const e=this,t=[""];e.__rules__.forEach(function(n){n.enabled&&n.alt.forEach(function(u){t.indexOf(u)<0&&t.push(u)})}),e.__cache__={},t.forEach(function(n){e.__cache__[n]=[],e.__rules__.forEach(function(u){u.enabled&&(n&&u.alt.indexOf(n)<0||e.__cache__[n].push(u.fn))})})},Ue.prototype.at=function(e,t,n){const u=this.__find__(e),o=n||{};if(u===-1)throw new Error("Parser rule not found: "+e);this.__rules__[u].fn=t,this.__rules__[u].alt=o.alt||[],this.__cache__=null},Ue.prototype.before=function(e,t,n,u){const o=this.__find__(e),r=u||{};if(o===-1)throw new Error("Parser rule not found: "+e);this.__rules__.splice(o,0,{name:t,enabled:!0,fn:n,alt:r.alt||[]}),this.__cache__=null},Ue.prototype.after=function(e,t,n,u){const o=this.__find__(e),r=u||{};if(o===-1)throw new Error("Parser rule not found: "+e);this.__rules__.splice(o+1,0,{name:t,enabled:!0,fn:n,alt:r.alt||[]}),this.__cache__=null},Ue.prototype.push=function(e,t,n){const u=n||{};this.__rules__.push({name:e,enabled:!0,fn:t,alt:u.alt||[]}),this.__cache__=null},Ue.prototype.enable=function(e,t){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(function(u){const o=this.__find__(u);if(o<0){if(t)return;throw new Error("Rules manager: invalid rule name "+u)}this.__rules__[o].enabled=!0,n.push(u)},this),this.__cache__=null,n},Ue.prototype.enableOnly=function(e,t){Array.isArray(e)||(e=[e]),this.__rules__.forEach(function(n){n.enabled=!1}),this.enable(e,t)},Ue.prototype.disable=function(e,t){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(function(u){const o=this.__find__(u);if(o<0){if(t)return;throw new Error("Rules manager: invalid rule name "+u)}this.__rules__[o].enabled=!1,n.push(u)},this),this.__cache__=null,n},Ue.prototype.getRules=function(e){return this.__cache__===null&&this.__compile__(),this.__cache__[e]||[]};function ut(e,t,n){this.type=e,this.tag=t,this.attrs=null,this.map=null,this.nesting=n,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}ut.prototype.attrIndex=function(t){if(!this.attrs)return-1;const n=this.attrs;for(let u=0,o=n.length;u<o;u++)if(n[u][0]===t)return u;return-1},ut.prototype.attrPush=function(t){this.attrs?this.attrs.push(t):this.attrs=[t]},ut.prototype.attrSet=function(t,n){const u=this.attrIndex(t),o=[t,n];u<0?this.attrPush(o):this.attrs[u]=o},ut.prototype.attrGet=function(t){const n=this.attrIndex(t);let u=null;return n>=0&&(u=this.attrs[n][1]),u},ut.prototype.attrJoin=function(t,n){const u=this.attrIndex(t);u<0?this.attrPush([t,n]):this.attrs[u][1]=this.attrs[u][1]+" "+n};function Ai(e,t,n){this.src=e,this.env=n,this.tokens=[],this.inlineMode=!1,this.md=t}Ai.prototype.Token=ut;const t0=/\r\n?|\n/g,n0=/\0/g;function r0(e){let t;t=e.src.replace(t0,`
15
+ `),t=t.replace(n0,"�"),e.src=t}function u0(e){let t;e.inlineMode?(t=new e.Token("inline","",0),t.content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}function o0(e){const t=e.tokens;for(let n=0,u=t.length;n<u;n++){const o=t[n];o.type==="inline"&&e.md.inline.parse(o.content,e.md,e.env,o.children)}}function i0(e){return/^<a[>\s]/i.test(e)}function a0(e){return/^<\/a\s*>/i.test(e)}function s0(e){const t=e.tokens;if(e.md.options.linkify)for(let n=0,u=t.length;n<u;n++){if(t[n].type!=="inline"||!e.md.linkify.pretest(t[n].content))continue;let o=t[n].children,r=0;for(let a=o.length-1;a>=0;a--){const s=o[a];if(s.type==="link_close"){for(a--;o[a].level!==s.level&&o[a].type!=="link_open";)a--;continue}if(s.type==="html_inline"&&(i0(s.content)&&r>0&&r--,a0(s.content)&&r++),!(r>0)&&s.type==="text"&&e.md.linkify.test(s.content)){const c=s.content;let d=e.md.linkify.match(c);const f=[];let l=s.level,p=0;d.length>0&&d[0].index===0&&a>0&&o[a-1].type==="text_special"&&(d=d.slice(1));for(let m=0;m<d.length;m++){const h=d[m].url,x=e.md.normalizeLink(h);if(!e.md.validateLink(x))continue;let y=d[m].text;d[m].schema?d[m].schema==="mailto:"&&!/^mailto:/i.test(y)?y=e.md.normalizeLinkText("mailto:"+y).replace(/^mailto:/,""):y=e.md.normalizeLinkText(y):y=e.md.normalizeLinkText("http://"+y).replace(/^http:\/\//,"");const v=d[m].index;if(v>p){const k=new e.Token("text","",0);k.content=c.slice(p,v),k.level=l,f.push(k)}const g=new e.Token("link_open","a",1);g.attrs=[["href",x]],g.level=l++,g.markup="linkify",g.info="auto",f.push(g);const b=new e.Token("text","",0);b.content=y,b.level=l,f.push(b);const w=new e.Token("link_close","a",-1);w.level=--l,w.markup="linkify",w.info="auto",f.push(w),p=d[m].lastIndex}if(p<c.length){const m=new e.Token("text","",0);m.content=c.slice(p),m.level=l,f.push(m)}t[n].children=o=wi(o,a,f)}}}}const ki=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,c0=/\((c|tm|r)\)/i,l0=/\((c|tm|r)\)/ig,d0={c:"©",r:"®",tm:"™"};function f0(e,t){return d0[t.toLowerCase()]}function h0(e){let t=0;for(let n=e.length-1;n>=0;n--){const u=e[n];u.type==="text"&&!t&&(u.content=u.content.replace(l0,f0)),u.type==="link_open"&&u.info==="auto"&&t--,u.type==="link_close"&&u.info==="auto"&&t++}}function p0(e){let t=0;for(let n=e.length-1;n>=0;n--){const u=e[n];u.type==="text"&&!t&&ki.test(u.content)&&(u.content=u.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/mg,"$1—").replace(/(^|\s)--(?=\s|$)/mg,"$1–").replace(/(^|[^-\s])--(?=[^-\s]|$)/mg,"$1–")),u.type==="link_open"&&u.info==="auto"&&t--,u.type==="link_close"&&u.info==="auto"&&t++}}function m0(e){let t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)e.tokens[t].type==="inline"&&(c0.test(e.tokens[t].content)&&h0(e.tokens[t].children),ki.test(e.tokens[t].content)&&p0(e.tokens[t].children))}const g0=/['"]/,Ci=/['"]/g,Ei="’";function Ir(e,t,n){return e.slice(0,t)+n+e.slice(t+1)}function b0(e,t){let n;const u=[];for(let o=0;o<e.length;o++){const r=e[o],a=e[o].level;for(n=u.length-1;n>=0&&!(u[n].level<=a);n--);if(u.length=n+1,r.type!=="text")continue;let s=r.content,c=0,d=s.length;e:for(;c<d;){Ci.lastIndex=c;const f=Ci.exec(s);if(!f)break;let l=!0,p=!0;c=f.index+1;const m=f[0]==="'";let h=32;if(f.index-1>=0)h=s.charCodeAt(f.index-1);else for(n=o-1;n>=0&&!(e[n].type==="softbreak"||e[n].type==="hardbreak");n--)if(e[n].content){h=e[n].content.charCodeAt(e[n].content.length-1);break}let x=32;if(c<d)x=s.charCodeAt(c);else for(n=o+1;n<e.length&&!(e[n].type==="softbreak"||e[n].type==="hardbreak");n++)if(e[n].content){x=e[n].content.charCodeAt(0);break}const y=Mn(h)||Rn(String.fromCharCode(h)),v=Mn(x)||Rn(String.fromCharCode(x)),g=Pn(h),b=Pn(x);if(b?l=!1:v&&(g||y||(l=!1)),g?p=!1:y&&(b||v||(p=!1)),x===34&&f[0]==='"'&&h>=48&&h<=57&&(p=l=!1),l&&p&&(l=y,p=v),!l&&!p){m&&(r.content=Ir(r.content,f.index,Ei));continue}if(p)for(n=u.length-1;n>=0;n--){let w=u[n];if(u[n].level<a)break;if(w.single===m&&u[n].level===a){w=u[n];let k,S;m?(k=t.md.options.quotes[2],S=t.md.options.quotes[3]):(k=t.md.options.quotes[0],S=t.md.options.quotes[1]),r.content=Ir(r.content,f.index,S),e[w.token].content=Ir(e[w.token].content,w.pos,k),c+=S.length-1,w.token===o&&(c+=k.length-1),s=r.content,d=s.length,u.length=n;continue e}}l?u.push({token:o,pos:f.index,single:m,level:a}):p&&m&&(r.content=Ir(r.content,f.index,Ei))}}}function y0(e){if(e.md.options.typographer)for(let t=e.tokens.length-1;t>=0;t--)e.tokens[t].type!=="inline"||!g0.test(e.tokens[t].content)||b0(e.tokens[t].children,e)}function x0(e){let t,n;const u=e.tokens,o=u.length;for(let r=0;r<o;r++){if(u[r].type!=="inline")continue;const a=u[r].children,s=a.length;for(t=0;t<s;t++)a[t].type==="text_special"&&(a[t].type="text");for(t=n=0;t<s;t++)a[t].type==="text"&&t+1<s&&a[t+1].type==="text"?a[t+1].content=a[t].content+a[t+1].content:(t!==n&&(a[n]=a[t]),n++);t!==n&&(a.length=n)}}const Ou=[["normalize",r0],["block",u0],["inline",o0],["linkify",s0],["replacements",m0],["smartquotes",y0],["text_join",x0]];function Pu(){this.ruler=new Ue;for(let e=0;e<Ou.length;e++)this.ruler.push(Ou[e][0],Ou[e][1])}Pu.prototype.process=function(e){const t=this.ruler.getRules("");for(let n=0,u=t.length;n<u;n++)t[n](e)},Pu.prototype.State=Ai;function gt(e,t,n,u){this.src=e,this.md=t,this.env=n,this.tokens=u,this.bMarks=[],this.eMarks=[],this.tShift=[],this.sCount=[],this.bsCount=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.ddIndent=-1,this.listIndent=-1,this.parentType="root",this.level=0;const o=this.src;for(let r=0,a=0,s=0,c=0,d=o.length,f=!1;a<d;a++){const l=o.charCodeAt(a);if(!f)if(le(l)){s++,l===9?c+=4-c%4:c++;continue}else f=!0;(l===10||a===d-1)&&(l!==10&&a++,this.bMarks.push(r),this.eMarks.push(a),this.tShift.push(s),this.sCount.push(c),this.bsCount.push(0),f=!1,s=0,c=0,r=a+1)}this.bMarks.push(o.length),this.eMarks.push(o.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}gt.prototype.push=function(e,t,n){const u=new ut(e,t,n);return u.block=!0,n<0&&this.level--,u.level=this.level,n>0&&this.level++,this.tokens.push(u),u},gt.prototype.isEmpty=function(t){return this.bMarks[t]+this.tShift[t]>=this.eMarks[t]},gt.prototype.skipEmptyLines=function(t){for(let n=this.lineMax;t<n&&!(this.bMarks[t]+this.tShift[t]<this.eMarks[t]);t++);return t},gt.prototype.skipSpaces=function(t){for(let n=this.src.length;t<n;t++){const u=this.src.charCodeAt(t);if(!le(u))break}return t},gt.prototype.skipSpacesBack=function(t,n){if(t<=n)return t;for(;t>n;)if(!le(this.src.charCodeAt(--t)))return t+1;return t},gt.prototype.skipChars=function(t,n){for(let u=this.src.length;t<u&&this.src.charCodeAt(t)===n;t++);return t},gt.prototype.skipCharsBack=function(t,n,u){if(t<=u)return t;for(;t>u;)if(n!==this.src.charCodeAt(--t))return t+1;return t},gt.prototype.getLines=function(t,n,u,o){if(t>=n)return"";const r=new Array(n-t);for(let a=0,s=t;s<n;s++,a++){let c=0;const d=this.bMarks[s];let f=d,l;for(s+1<n||o?l=this.eMarks[s]+1:l=this.eMarks[s];f<l&&c<u;){const p=this.src.charCodeAt(f);if(le(p))p===9?c+=4-(c+this.bsCount[s])%4:c++;else if(f-d<this.tShift[s])c++;else break;f++}c>u?r[a]=new Array(c-u+1).join(" ")+this.src.slice(f,l):r[a]=this.src.slice(f,l)}return r.join("")},gt.prototype.Token=ut;const w0=65536;function Ru(e,t){const n=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];return e.src.slice(n,u)}function _i(e){const t=[],n=e.length;let u=0,o=e.charCodeAt(u),r=!1,a=0,s="";for(;u<n;)o===124&&(r?(s+=e.substring(a,u-1),a=u):(t.push(s+e.substring(a,u)),s="",a=u+1)),r=o===92,u++,o=e.charCodeAt(u);return t.push(s+e.substring(a)),t}function v0(e,t,n,u){if(t+2>n)return!1;let o=t+1;if(e.sCount[o]<e.blkIndent||e.sCount[o]-e.blkIndent>=4)return!1;let r=e.bMarks[o]+e.tShift[o];if(r>=e.eMarks[o])return!1;const a=e.src.charCodeAt(r++);if(a!==124&&a!==45&&a!==58||r>=e.eMarks[o])return!1;const s=e.src.charCodeAt(r++);if(s!==124&&s!==45&&s!==58&&!le(s)||a===45&&le(s))return!1;for(;r<e.eMarks[o];){const w=e.src.charCodeAt(r);if(w!==124&&w!==45&&w!==58&&!le(w))return!1;r++}let c=Ru(e,t+1),d=c.split("|");const f=[];for(let w=0;w<d.length;w++){const k=d[w].trim();if(!k){if(w===0||w===d.length-1)continue;return!1}if(!/^:?-+:?$/.test(k))return!1;k.charCodeAt(k.length-1)===58?f.push(k.charCodeAt(0)===58?"center":"right"):k.charCodeAt(0)===58?f.push("left"):f.push("")}if(c=Ru(e,t).trim(),c.indexOf("|")===-1||e.sCount[t]-e.blkIndent>=4)return!1;d=_i(c),d.length&&d[0]===""&&d.shift(),d.length&&d[d.length-1]===""&&d.pop();const l=d.length;if(l===0||l!==f.length)return!1;if(u)return!0;const p=e.parentType;e.parentType="table";const m=e.md.block.ruler.getRules("blockquote"),h=e.push("table_open","table",1),x=[t,0];h.map=x;const y=e.push("thead_open","thead",1);y.map=[t,t+1];const v=e.push("tr_open","tr",1);v.map=[t,t+1];for(let w=0;w<d.length;w++){const k=e.push("th_open","th",1);f[w]&&(k.attrs=[["style","text-align:"+f[w]]]);const S=e.push("inline","",0);S.content=d[w].trim(),S.children=[],e.push("th_close","th",-1)}e.push("tr_close","tr",-1),e.push("thead_close","thead",-1);let g,b=0;for(o=t+2;o<n&&!(e.sCount[o]<e.blkIndent);o++){let w=!1;for(let S=0,_=m.length;S<_;S++)if(m[S](e,o,n,!0)){w=!0;break}if(w||(c=Ru(e,o).trim(),!c)||e.sCount[o]-e.blkIndent>=4||(d=_i(c),d.length&&d[0]===""&&d.shift(),d.length&&d[d.length-1]===""&&d.pop(),b+=l-d.length,b>w0))break;if(o===t+2){const S=e.push("tbody_open","tbody",1);S.map=g=[t+2,0]}const k=e.push("tr_open","tr",1);k.map=[o,o+1];for(let S=0;S<l;S++){const _=e.push("td_open","td",1);f[S]&&(_.attrs=[["style","text-align:"+f[S]]]);const E=e.push("inline","",0);E.content=d[S]?d[S].trim():"",E.children=[],e.push("td_close","td",-1)}e.push("tr_close","tr",-1)}return g&&(e.push("tbody_close","tbody",-1),g[1]=o),e.push("table_close","table",-1),x[1]=o,e.parentType=p,e.line=o,!0}function A0(e,t,n){if(e.sCount[t]-e.blkIndent<4)return!1;let u=t+1,o=u;for(;u<n;){if(e.isEmpty(u)){u++;continue}if(e.sCount[u]-e.blkIndent>=4){u++,o=u;continue}break}e.line=o;const r=e.push("code_block","code",0);return r.content=e.getLines(t,o,4+e.blkIndent,!1)+`
16
+ `,r.map=[t,e.line],!0}function k0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||o+3>r)return!1;const a=e.src.charCodeAt(o);if(a!==126&&a!==96)return!1;let s=o;o=e.skipChars(o,a);let c=o-s;if(c<3)return!1;const d=e.src.slice(s,o),f=e.src.slice(o,r);if(a===96&&f.indexOf(String.fromCharCode(a))>=0)return!1;if(u)return!0;let l=t,p=!1;for(;l++,!(l>=n||(o=s=e.bMarks[l]+e.tShift[l],r=e.eMarks[l],o<r&&e.sCount[l]<e.blkIndent));)if(e.src.charCodeAt(o)===a&&!(e.sCount[l]-e.blkIndent>=4)&&(o=e.skipChars(o,a),!(o-s<c)&&(o=e.skipSpaces(o),!(o<r)))){p=!0;break}c=e.sCount[t],e.line=l+(p?1:0);const m=e.push("fence","code",0);return m.info=f,m.content=e.getLines(t+1,l,c,!0),m.markup=d,m.map=[t,e.line],!0}function C0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];const a=e.lineMax;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(o)!==62)return!1;if(u)return!0;const s=[],c=[],d=[],f=[],l=e.md.block.ruler.getRules("blockquote"),p=e.parentType;e.parentType="blockquote";let m=!1,h;for(h=t;h<n;h++){const b=e.sCount[h]<e.blkIndent;if(o=e.bMarks[h]+e.tShift[h],r=e.eMarks[h],o>=r)break;if(e.src.charCodeAt(o++)===62&&!b){let k=e.sCount[h]+1,S,_;e.src.charCodeAt(o)===32?(o++,k++,_=!1,S=!0):e.src.charCodeAt(o)===9?(S=!0,(e.bsCount[h]+k)%4===3?(o++,k++,_=!1):_=!0):S=!1;let E=k;for(s.push(e.bMarks[h]),e.bMarks[h]=o;o<r;){const W=e.src.charCodeAt(o);if(le(W))W===9?E+=4-(E+e.bsCount[h]+(_?1:0))%4:E++;else break;o++}m=o>=r,c.push(e.bsCount[h]),e.bsCount[h]=e.sCount[h]+1+(S?1:0),d.push(e.sCount[h]),e.sCount[h]=E-k,f.push(e.tShift[h]),e.tShift[h]=o-e.bMarks[h];continue}if(m)break;let w=!1;for(let k=0,S=l.length;k<S;k++)if(l[k](e,h,n,!0)){w=!0;break}if(w){e.lineMax=h,e.blkIndent!==0&&(s.push(e.bMarks[h]),c.push(e.bsCount[h]),f.push(e.tShift[h]),d.push(e.sCount[h]),e.sCount[h]-=e.blkIndent);break}s.push(e.bMarks[h]),c.push(e.bsCount[h]),f.push(e.tShift[h]),d.push(e.sCount[h]),e.sCount[h]=-1}const x=e.blkIndent;e.blkIndent=0;const y=e.push("blockquote_open","blockquote",1);y.markup=">";const v=[t,0];y.map=v,e.md.block.tokenize(e,t,h);const g=e.push("blockquote_close","blockquote",-1);g.markup=">",e.lineMax=a,e.parentType=p,v[1]=e.line;for(let b=0;b<f.length;b++)e.bMarks[b+t]=s[b],e.tShift[b+t]=f[b],e.sCount[b+t]=d[b],e.bsCount[b+t]=c[b];return e.blkIndent=x,!0}function E0(e,t,n,u){const o=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let r=e.bMarks[t]+e.tShift[t];const a=e.src.charCodeAt(r++);if(a!==42&&a!==45&&a!==95)return!1;let s=1;for(;r<o;){const d=e.src.charCodeAt(r++);if(d!==a&&!le(d))return!1;d===a&&s++}if(s<3)return!1;if(u)return!0;e.line=t+1;const c=e.push("hr","hr",0);return c.map=[t,e.line],c.markup=Array(s+1).join(String.fromCharCode(a)),!0}function Si(e,t){const n=e.eMarks[t];let u=e.bMarks[t]+e.tShift[t];const o=e.src.charCodeAt(u++);if(o!==42&&o!==45&&o!==43)return-1;if(u<n){const r=e.src.charCodeAt(u);if(!le(r))return-1}return u}function Fi(e,t){const n=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];let o=n;if(o+1>=u)return-1;let r=e.src.charCodeAt(o++);if(r<48||r>57)return-1;for(;;){if(o>=u)return-1;if(r=e.src.charCodeAt(o++),r>=48&&r<=57){if(o-n>=10)return-1;continue}if(r===41||r===46)break;return-1}return o<u&&(r=e.src.charCodeAt(o),!le(r))?-1:o}function _0(e,t){const n=e.level+2;for(let u=t+2,o=e.tokens.length-2;u<o;u++)e.tokens[u].level===n&&e.tokens[u].type==="paragraph_open"&&(e.tokens[u+2].hidden=!0,e.tokens[u].hidden=!0,u+=2)}function S0(e,t,n,u){let o,r,a,s,c=t,d=!0;if(e.sCount[c]-e.blkIndent>=4||e.listIndent>=0&&e.sCount[c]-e.listIndent>=4&&e.sCount[c]<e.blkIndent)return!1;let f=!1;u&&e.parentType==="paragraph"&&e.sCount[c]>=e.blkIndent&&(f=!0);let l,p,m;if((m=Fi(e,c))>=0){if(l=!0,a=e.bMarks[c]+e.tShift[c],p=Number(e.src.slice(a,m-1)),f&&p!==1)return!1}else if((m=Si(e,c))>=0)l=!1;else return!1;if(f&&e.skipSpaces(m)>=e.eMarks[c])return!1;if(u)return!0;const h=e.src.charCodeAt(m-1),x=e.tokens.length;l?(s=e.push("ordered_list_open","ol",1),p!==1&&(s.attrs=[["start",p]])):s=e.push("bullet_list_open","ul",1);const y=[c,0];s.map=y,s.markup=String.fromCharCode(h);let v=!1;const g=e.md.block.ruler.getRules("list"),b=e.parentType;for(e.parentType="list";c<n;){r=m,o=e.eMarks[c];const w=e.sCount[c]+m-(e.bMarks[c]+e.tShift[c]);let k=w;for(;r<o;){const H=e.src.charCodeAt(r);if(H===9)k+=4-(k+e.bsCount[c])%4;else if(H===32)k++;else break;r++}const S=r;let _;S>=o?_=1:_=k-w,_>4&&(_=1);const E=w+_;s=e.push("list_item_open","li",1),s.markup=String.fromCharCode(h);const W=[c,0];s.map=W,l&&(s.info=e.src.slice(a,m-1));const V=e.tight,O=e.tShift[c],B=e.sCount[c],D=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=E,e.tight=!0,e.tShift[c]=S-e.bMarks[c],e.sCount[c]=k,S>=o&&e.isEmpty(c+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,c,n,!0),(!e.tight||v)&&(d=!1),v=e.line-c>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=D,e.tShift[c]=O,e.sCount[c]=B,e.tight=V,s=e.push("list_item_close","li",-1),s.markup=String.fromCharCode(h),c=e.line,W[1]=c,c>=n||e.sCount[c]<e.blkIndent||e.sCount[c]-e.blkIndent>=4)break;let j=!1;for(let H=0,F=g.length;H<F;H++)if(g[H](e,c,n,!0)){j=!0;break}if(j)break;if(l){if(m=Fi(e,c),m<0)break;a=e.bMarks[c]+e.tShift[c]}else if(m=Si(e,c),m<0)break;if(h!==e.src.charCodeAt(m-1))break}return l?s=e.push("ordered_list_close","ol",-1):s=e.push("bullet_list_close","ul",-1),s.markup=String.fromCharCode(h),y[1]=c,e.line=c,e.parentType=b,d&&_0(e,x),!0}function F0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t],a=t+1;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(o)!==91)return!1;function s(g){const b=e.lineMax;if(g>=b||e.isEmpty(g))return null;let w=!1;if(e.sCount[g]-e.blkIndent>3&&(w=!0),e.sCount[g]<0&&(w=!0),!w){const _=e.md.block.ruler.getRules("reference"),E=e.parentType;e.parentType="reference";let W=!1;for(let V=0,O=_.length;V<O;V++)if(_[V](e,g,b,!0)){W=!0;break}if(e.parentType=E,W)return null}const k=e.bMarks[g]+e.tShift[g],S=e.eMarks[g];return e.src.slice(k,S+1)}let c=e.src.slice(o,r+1);r=c.length;let d=-1;for(o=1;o<r;o++){const g=c.charCodeAt(o);if(g===91)return!1;if(g===93){d=o;break}else if(g===10){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}else if(g===92&&(o++,o<r&&c.charCodeAt(o)===10)){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}}if(d<0||c.charCodeAt(d+1)!==58)return!1;for(o=d+2;o<r;o++){const g=c.charCodeAt(o);if(g===10){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}else if(!le(g))break}const f=e.md.helpers.parseLinkDestination(c,o,r);if(!f.ok)return!1;const l=e.md.normalizeLink(f.str);if(!e.md.validateLink(l))return!1;o=f.pos;const p=o,m=a,h=o;for(;o<r;o++){const g=c.charCodeAt(o);if(g===10){const b=s(a);b!==null&&(c+=b,r=c.length,a++)}else if(!le(g))break}let x=e.md.helpers.parseLinkTitle(c,o,r);for(;x.can_continue;){const g=s(a);if(g===null)break;c+=g,o=r,r=c.length,a++,x=e.md.helpers.parseLinkTitle(c,o,r,x)}let y;for(o<r&&h!==o&&x.ok?(y=x.str,o=x.pos):(y="",o=p,a=m);o<r;){const g=c.charCodeAt(o);if(!le(g))break;o++}if(o<r&&c.charCodeAt(o)!==10&&y)for(y="",o=p,a=m;o<r;){const g=c.charCodeAt(o);if(!le(g))break;o++}if(o<r&&c.charCodeAt(o)!==10)return!1;const v=Lr(c.slice(1,d));return v?(u||(typeof e.env.references>"u"&&(e.env.references={}),typeof e.env.references[v]>"u"&&(e.env.references[v]={title:y,href:l}),e.line=a),!0):!1}const D0=["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"],T0="[a-zA-Z_:][a-zA-Z0-9:._-]*",N0="(?:"+"[^\"'=<>`\\x00-\\x20]+"+"|"+"'[^']*'"+"|"+'"[^"]*"'+")",Di="<[A-Za-z][A-Za-z0-9\\-]*"+("(?:\\s+"+T0+"(?:\\s*=\\s*"+N0+")?)")+"*\\s*\\/?>",Ti="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",L0="<!---?>|<!--(?:[^-]|-[^-]|--[^>])*-->",I0="<[?][\\s\\S]*?[?]>",O0="<![A-Za-z][^>]*>",P0="<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",R0=new RegExp("^(?:"+Di+"|"+Ti+"|"+L0+"|"+I0+"|"+O0+"|"+P0+")"),M0=new RegExp("^(?:"+Di+"|"+Ti+")"),ln=[[/^<(script|pre|style|textarea)(?=(\s|>|$))/i,/<\/(script|pre|style|textarea)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[new RegExp("^</?("+D0.join("|")+")(?=(\\s|/?>|$))","i"),/^$/,!0],[new RegExp(M0.source+"\\s*$"),/^$/,!1]];function V0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||!e.md.options.html||e.src.charCodeAt(o)!==60)return!1;let a=e.src.slice(o,r),s=0;for(;s<ln.length&&!ln[s][0].test(a);s++);if(s===ln.length)return!1;if(u)return ln[s][2];let c=t+1;if(!ln[s][1].test(a)){for(;c<n&&!(e.sCount[c]<e.blkIndent);c++)if(o=e.bMarks[c]+e.tShift[c],r=e.eMarks[c],a=e.src.slice(o,r),ln[s][1].test(a)){a.length!==0&&c++;break}}e.line=c;const d=e.push("html_block","",0);return d.map=[t,c],d.content=e.getLines(t,c,e.blkIndent,!0),!0}function B0(e,t,n,u){let o=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let a=e.src.charCodeAt(o);if(a!==35||o>=r)return!1;let s=1;for(a=e.src.charCodeAt(++o);a===35&&o<r&&s<=6;)s++,a=e.src.charCodeAt(++o);if(s>6||o<r&&!le(a))return!1;if(u)return!0;r=e.skipSpacesBack(r,o);const c=e.skipCharsBack(r,35,o);c>o&&le(e.src.charCodeAt(c-1))&&(r=c),e.line=t+1;const d=e.push("heading_open","h"+String(s),1);d.markup="########".slice(0,s),d.map=[t,e.line];const f=e.push("inline","",0);f.content=e.src.slice(o,r).trim(),f.map=[t,e.line],f.children=[];const l=e.push("heading_close","h"+String(s),-1);return l.markup="########".slice(0,s),!0}function z0(e,t,n){const u=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;const o=e.parentType;e.parentType="paragraph";let r=0,a,s=t+1;for(;s<n&&!e.isEmpty(s);s++){if(e.sCount[s]-e.blkIndent>3)continue;if(e.sCount[s]>=e.blkIndent){let m=e.bMarks[s]+e.tShift[s];const h=e.eMarks[s];if(m<h&&(a=e.src.charCodeAt(m),(a===45||a===61)&&(m=e.skipChars(m,a),m=e.skipSpaces(m),m>=h))){r=a===61?1:2;break}}if(e.sCount[s]<0)continue;let p=!1;for(let m=0,h=u.length;m<h;m++)if(u[m](e,s,n,!0)){p=!0;break}if(p)break}if(!r)return!1;const c=e.getLines(t,s,e.blkIndent,!1).trim();e.line=s+1;const d=e.push("heading_open","h"+String(r),1);d.markup=String.fromCharCode(a),d.map=[t,e.line];const f=e.push("inline","",0);f.content=c,f.map=[t,e.line-1],f.children=[];const l=e.push("heading_close","h"+String(r),-1);return l.markup=String.fromCharCode(a),e.parentType=o,!0}function j0(e,t,n){const u=e.md.block.ruler.getRules("paragraph"),o=e.parentType;let r=t+1;for(e.parentType="paragraph";r<n&&!e.isEmpty(r);r++){if(e.sCount[r]-e.blkIndent>3||e.sCount[r]<0)continue;let d=!1;for(let f=0,l=u.length;f<l;f++)if(u[f](e,r,n,!0)){d=!0;break}if(d)break}const a=e.getLines(t,r,e.blkIndent,!1).trim();e.line=r;const s=e.push("paragraph_open","p",1);s.map=[t,e.line];const c=e.push("inline","",0);return c.content=a,c.map=[t,e.line],c.children=[],e.push("paragraph_close","p",-1),e.parentType=o,!0}const Or=[["table",v0,["paragraph","reference"]],["code",A0],["fence",k0,["paragraph","reference","blockquote","list"]],["blockquote",C0,["paragraph","reference","blockquote","list"]],["hr",E0,["paragraph","reference","blockquote","list"]],["list",S0,["paragraph","reference","blockquote"]],["reference",F0],["html_block",V0,["paragraph","reference","blockquote"]],["heading",B0,["paragraph","reference","blockquote"]],["lheading",z0],["paragraph",j0]];function Pr(){this.ruler=new Ue;for(let e=0;e<Or.length;e++)this.ruler.push(Or[e][0],Or[e][1],{alt:(Or[e][2]||[]).slice()})}Pr.prototype.tokenize=function(e,t,n){const u=this.ruler.getRules(""),o=u.length,r=e.md.options.maxNesting;let a=t,s=!1;for(;a<n&&(e.line=a=e.skipEmptyLines(a),!(a>=n||e.sCount[a]<e.blkIndent));){if(e.level>=r){e.line=n;break}const c=e.line;let d=!1;for(let f=0;f<o;f++)if(d=u[f](e,a,n,!1),d){if(c>=e.line)throw new Error("block rule didn't increment state.line");break}if(!d)throw new Error("none of the block rules matched");e.tight=!s,e.isEmpty(e.line-1)&&(s=!0),a=e.line,a<n&&e.isEmpty(a)&&(s=!0,a++,e.line=a)}},Pr.prototype.parse=function(e,t,n,u){if(!e)return;const o=new this.State(e,t,n,u);this.tokenize(o,o.line,o.lineMax)},Pr.prototype.State=gt;function Vn(e,t,n,u){this.src=e,this.env=n,this.md=t,this.tokens=u,this.tokens_meta=Array(u.length),this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache={},this.delimiters=[],this._prev_delimiters=[],this.backticks={},this.backticksScanned=!1,this.linkLevel=0}Vn.prototype.pushPending=function(){const e=new ut("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e},Vn.prototype.push=function(e,t,n){this.pending&&this.pushPending();const u=new ut(e,t,n);let o=null;return n<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),u.level=this.level,n>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],o={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(u),this.tokens_meta.push(o),u},Vn.prototype.scanDelims=function(e,t){const n=this.posMax,u=this.src.charCodeAt(e),o=e>0?this.src.charCodeAt(e-1):32;let r=e;for(;r<n&&this.src.charCodeAt(r)===u;)r++;const a=r-e,s=r<n?this.src.charCodeAt(r):32,c=Mn(o)||Rn(String.fromCharCode(o)),d=Mn(s)||Rn(String.fromCharCode(s)),f=Pn(o),l=Pn(s),p=!l&&(!d||f||c),m=!f&&(!c||l||d);return{can_open:p&&(t||!m||c),can_close:m&&(t||!p||d),length:a}},Vn.prototype.Token=ut;function H0(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}function U0(e,t){let n=e.pos;for(;n<e.posMax&&!H0(e.src.charCodeAt(n));)n++;return n===e.pos?!1:(t||(e.pending+=e.src.slice(e.pos,n)),e.pos=n,!0)}const $0=/(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;function W0(e,t){if(!e.md.options.linkify||e.linkLevel>0)return!1;const n=e.pos,u=e.posMax;if(n+3>u||e.src.charCodeAt(n)!==58||e.src.charCodeAt(n+1)!==47||e.src.charCodeAt(n+2)!==47)return!1;const o=e.pending.match($0);if(!o)return!1;const r=o[1],a=e.md.linkify.matchAtStart(e.src.slice(n-r.length));if(!a)return!1;let s=a.url;if(s.length<=r.length)return!1;let c=s.length;for(;c>0&&s.charCodeAt(c-1)===42;)c--;c!==s.length&&(s=s.slice(0,c));const d=e.md.normalizeLink(s);if(!e.md.validateLink(d))return!1;if(!t){e.pending=e.pending.slice(0,-r.length);const f=e.push("link_open","a",1);f.attrs=[["href",d]],f.markup="linkify",f.info="auto";const l=e.push("text","",0);l.content=e.md.normalizeLinkText(s);const p=e.push("link_close","a",-1);p.markup="linkify",p.info="auto"}return e.pos+=s.length-r.length,!0}function G0(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==10)return!1;const u=e.pending.length-1,o=e.posMax;if(!t)if(u>=0&&e.pending.charCodeAt(u)===32)if(u>=1&&e.pending.charCodeAt(u-1)===32){let r=u-1;for(;r>=1&&e.pending.charCodeAt(r-1)===32;)r--;e.pending=e.pending.slice(0,r),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0);else e.push("softbreak","br",0);for(n++;n<o&&le(e.src.charCodeAt(n));)n++;return e.pos=n,!0}const Mu=[];for(let e=0;e<256;e++)Mu.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){Mu[e.charCodeAt(0)]=1});function q0(e,t){let n=e.pos;const u=e.posMax;if(e.src.charCodeAt(n)!==92||(n++,n>=u))return!1;let o=e.src.charCodeAt(n);if(o===10){for(t||e.push("hardbreak","br",0),n++;n<u&&(o=e.src.charCodeAt(n),!!le(o));)n++;return e.pos=n,!0}let r=e.src[n];if(o>=55296&&o<=56319&&n+1<u){const s=e.src.charCodeAt(n+1);s>=56320&&s<=57343&&(r+=e.src[n+1],n++)}const a="\\"+r;if(!t){const s=e.push("text_special","",0);o<256&&Mu[o]!==0?s.content=r:s.content=a,s.markup=a,s.info="escape"}return e.pos=n+1,!0}function X0(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==96)return!1;const o=n;n++;const r=e.posMax;for(;n<r&&e.src.charCodeAt(n)===96;)n++;const a=e.src.slice(o,n),s=a.length;if(e.backticksScanned&&(e.backticks[s]||0)<=o)return t||(e.pending+=a),e.pos+=s,!0;let c=n,d;for(;(d=e.src.indexOf("`",c))!==-1;){for(c=d+1;c<r&&e.src.charCodeAt(c)===96;)c++;const f=c-d;if(f===s){if(!t){const l=e.push("code_inline","code",0);l.markup=a,l.content=e.src.slice(n,d).replace(/\n/g," ").replace(/^ (.+) $/,"$1")}return e.pos=c,!0}e.backticks[f]=d}return e.backticksScanned=!0,t||(e.pending+=a),e.pos+=s,!0}function Z0(e,t){const n=e.pos,u=e.src.charCodeAt(n);if(t||u!==126)return!1;const o=e.scanDelims(e.pos,!0);let r=o.length;const a=String.fromCharCode(u);if(r<2)return!1;let s;r%2&&(s=e.push("text","",0),s.content=a,r--);for(let c=0;c<r;c+=2)s=e.push("text","",0),s.content=a+a,e.delimiters.push({marker:u,length:0,token:e.tokens.length-1,end:-1,open:o.can_open,close:o.can_close});return e.pos+=o.length,!0}function Ni(e,t){let n;const u=[],o=t.length;for(let r=0;r<o;r++){const a=t[r];if(a.marker!==126||a.end===-1)continue;const s=t[a.end];n=e.tokens[a.token],n.type="s_open",n.tag="s",n.nesting=1,n.markup="~~",n.content="",n=e.tokens[s.token],n.type="s_close",n.tag="s",n.nesting=-1,n.markup="~~",n.content="",e.tokens[s.token-1].type==="text"&&e.tokens[s.token-1].content==="~"&&u.push(s.token-1)}for(;u.length;){const r=u.pop();let a=r+1;for(;a<e.tokens.length&&e.tokens[a].type==="s_close";)a++;a--,r!==a&&(n=e.tokens[a],e.tokens[a]=e.tokens[r],e.tokens[r]=n)}}function Y0(e){const t=e.tokens_meta,n=e.tokens_meta.length;Ni(e,e.delimiters);for(let u=0;u<n;u++)t[u]&&t[u].delimiters&&Ni(e,t[u].delimiters)}const Li={tokenize:Z0,postProcess:Y0};function K0(e,t){const n=e.pos,u=e.src.charCodeAt(n);if(t||u!==95&&u!==42)return!1;const o=e.scanDelims(e.pos,u===42);for(let r=0;r<o.length;r++){const a=e.push("text","",0);a.content=String.fromCharCode(u),e.delimiters.push({marker:u,length:o.length,token:e.tokens.length-1,end:-1,open:o.can_open,close:o.can_close})}return e.pos+=o.length,!0}function Ii(e,t){const n=t.length;for(let u=n-1;u>=0;u--){const o=t[u];if(o.marker!==95&&o.marker!==42||o.end===-1)continue;const r=t[o.end],a=u>0&&t[u-1].end===o.end+1&&t[u-1].marker===o.marker&&t[u-1].token===o.token-1&&t[o.end+1].token===r.token+1,s=String.fromCharCode(o.marker),c=e.tokens[o.token];c.type=a?"strong_open":"em_open",c.tag=a?"strong":"em",c.nesting=1,c.markup=a?s+s:s,c.content="";const d=e.tokens[r.token];d.type=a?"strong_close":"em_close",d.tag=a?"strong":"em",d.nesting=-1,d.markup=a?s+s:s,d.content="",a&&(e.tokens[t[u-1].token].content="",e.tokens[t[o.end+1].token].content="",u--)}}function Q0(e){const t=e.tokens_meta,n=e.tokens_meta.length;Ii(e,e.delimiters);for(let u=0;u<n;u++)t[u]&&t[u].delimiters&&Ii(e,t[u].delimiters)}const Oi={tokenize:K0,postProcess:Q0};function J0(e,t){let n,u,o,r,a="",s="",c=e.pos,d=!0;if(e.src.charCodeAt(e.pos)!==91)return!1;const f=e.pos,l=e.posMax,p=e.pos+1,m=e.md.helpers.parseLinkLabel(e,e.pos,!0);if(m<0)return!1;let h=m+1;if(h<l&&e.src.charCodeAt(h)===40){for(d=!1,h++;h<l&&(n=e.src.charCodeAt(h),!(!le(n)&&n!==10));h++);if(h>=l)return!1;if(c=h,o=e.md.helpers.parseLinkDestination(e.src,h,e.posMax),o.ok){for(a=e.md.normalizeLink(o.str),e.md.validateLink(a)?h=o.pos:a="",c=h;h<l&&(n=e.src.charCodeAt(h),!(!le(n)&&n!==10));h++);if(o=e.md.helpers.parseLinkTitle(e.src,h,e.posMax),h<l&&c!==h&&o.ok)for(s=o.str,h=o.pos;h<l&&(n=e.src.charCodeAt(h),!(!le(n)&&n!==10));h++);}(h>=l||e.src.charCodeAt(h)!==41)&&(d=!0),h++}if(d){if(typeof e.env.references>"u")return!1;if(h<l&&e.src.charCodeAt(h)===91?(c=h+1,h=e.md.helpers.parseLinkLabel(e,h),h>=0?u=e.src.slice(c,h++):h=m+1):h=m+1,u||(u=e.src.slice(p,m)),r=e.env.references[Lr(u)],!r)return e.pos=f,!1;a=r.href,s=r.title}if(!t){e.pos=p,e.posMax=m;const x=e.push("link_open","a",1),y=[["href",a]];x.attrs=y,s&&y.push(["title",s]),e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=h,e.posMax=l,!0}function ed(e,t){let n,u,o,r,a,s,c,d,f="";const l=e.pos,p=e.posMax;if(e.src.charCodeAt(e.pos)!==33||e.src.charCodeAt(e.pos+1)!==91)return!1;const m=e.pos+2,h=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(h<0)return!1;if(r=h+1,r<p&&e.src.charCodeAt(r)===40){for(r++;r<p&&(n=e.src.charCodeAt(r),!(!le(n)&&n!==10));r++);if(r>=p)return!1;for(d=r,s=e.md.helpers.parseLinkDestination(e.src,r,e.posMax),s.ok&&(f=e.md.normalizeLink(s.str),e.md.validateLink(f)?r=s.pos:f=""),d=r;r<p&&(n=e.src.charCodeAt(r),!(!le(n)&&n!==10));r++);if(s=e.md.helpers.parseLinkTitle(e.src,r,e.posMax),r<p&&d!==r&&s.ok)for(c=s.str,r=s.pos;r<p&&(n=e.src.charCodeAt(r),!(!le(n)&&n!==10));r++);else c="";if(r>=p||e.src.charCodeAt(r)!==41)return e.pos=l,!1;r++}else{if(typeof e.env.references>"u")return!1;if(r<p&&e.src.charCodeAt(r)===91?(d=r+1,r=e.md.helpers.parseLinkLabel(e,r),r>=0?o=e.src.slice(d,r++):r=h+1):r=h+1,o||(o=e.src.slice(m,h)),a=e.env.references[Lr(o)],!a)return e.pos=l,!1;f=a.href,c=a.title}if(!t){u=e.src.slice(m,h);const x=[];e.md.inline.parse(u,e.md,e.env,x);const y=e.push("image","img",0),v=[["src",f],["alt",""]];y.attrs=v,y.children=x,y.content=u,c&&v.push(["title",c])}return e.pos=r,e.posMax=p,!0}const td=/^([a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/,nd=/^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/;function rd(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==60)return!1;const u=e.pos,o=e.posMax;for(;;){if(++n>=o)return!1;const a=e.src.charCodeAt(n);if(a===60)return!1;if(a===62)break}const r=e.src.slice(u+1,n);if(nd.test(r)){const a=e.md.normalizeLink(r);if(!e.md.validateLink(a))return!1;if(!t){const s=e.push("link_open","a",1);s.attrs=[["href",a]],s.markup="autolink",s.info="auto";const c=e.push("text","",0);c.content=e.md.normalizeLinkText(r);const d=e.push("link_close","a",-1);d.markup="autolink",d.info="auto"}return e.pos+=r.length+2,!0}if(td.test(r)){const a=e.md.normalizeLink("mailto:"+r);if(!e.md.validateLink(a))return!1;if(!t){const s=e.push("link_open","a",1);s.attrs=[["href",a]],s.markup="autolink",s.info="auto";const c=e.push("text","",0);c.content=e.md.normalizeLinkText(r);const d=e.push("link_close","a",-1);d.markup="autolink",d.info="auto"}return e.pos+=r.length+2,!0}return!1}function ud(e){return/^<a[>\s]/i.test(e)}function od(e){return/^<\/a\s*>/i.test(e)}function id(e){const t=e|32;return t>=97&&t<=122}function ad(e,t){if(!e.md.options.html)return!1;const n=e.posMax,u=e.pos;if(e.src.charCodeAt(u)!==60||u+2>=n)return!1;const o=e.src.charCodeAt(u+1);if(o!==33&&o!==63&&o!==47&&!id(o))return!1;const r=e.src.slice(u).match(R0);if(!r)return!1;if(!t){const a=e.push("html_inline","",0);a.content=r[0],ud(a.content)&&e.linkLevel++,od(a.content)&&e.linkLevel--}return e.pos+=r[0].length,!0}const sd=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,cd=/^&([a-z][a-z0-9]{1,31});/i;function ld(e,t){const n=e.pos,u=e.posMax;if(e.src.charCodeAt(n)!==38||n+1>=u)return!1;if(e.src.charCodeAt(n+1)===35){const r=e.src.slice(n).match(sd);if(r){if(!t){const a=r[1][0].toLowerCase()==="x"?parseInt(r[1].slice(1),16):parseInt(r[1],10),s=e.push("text_special","",0);s.content=Iu(a)?Nr(a):Nr(65533),s.markup=r[0],s.info="entity"}return e.pos+=r[0].length,!0}}else{const r=e.src.slice(n).match(cd);if(r){const a=xi(r[0]);if(a!==r[0]){if(!t){const s=e.push("text_special","",0);s.content=a,s.markup=r[0],s.info="entity"}return e.pos+=r[0].length,!0}}}return!1}function Pi(e){const t={},n=e.length;if(!n)return;let u=0,o=-2;const r=[];for(let a=0;a<n;a++){const s=e[a];if(r.push(0),(e[u].marker!==s.marker||o!==s.token-1)&&(u=a),o=s.token,s.length=s.length||0,!s.close)continue;t.hasOwnProperty(s.marker)||(t[s.marker]=[-1,-1,-1,-1,-1,-1]);const c=t[s.marker][(s.open?3:0)+s.length%3];let d=u-r[u]-1,f=d;for(;d>c;d-=r[d]+1){const l=e[d];if(l.marker===s.marker&&l.open&&l.end<0){let p=!1;if((l.close||s.open)&&(l.length+s.length)%3===0&&(l.length%3!==0||s.length%3!==0)&&(p=!0),!p){const m=d>0&&!e[d-1].open?r[d-1]+1:0;r[a]=a-d+m,r[d]=m,s.open=!1,l.end=a,l.close=!1,f=-1,o=-2;break}}}f!==-1&&(t[s.marker][(s.open?3:0)+(s.length||0)%3]=f)}}function dd(e){const t=e.tokens_meta,n=e.tokens_meta.length;Pi(e.delimiters);for(let u=0;u<n;u++)t[u]&&t[u].delimiters&&Pi(t[u].delimiters)}function fd(e){let t,n,u=0;const o=e.tokens,r=e.tokens.length;for(t=n=0;t<r;t++)o[t].nesting<0&&u--,o[t].level=u,o[t].nesting>0&&u++,o[t].type==="text"&&t+1<r&&o[t+1].type==="text"?o[t+1].content=o[t].content+o[t+1].content:(t!==n&&(o[n]=o[t]),n++);t!==n&&(o.length=n)}const Vu=[["text",U0],["linkify",W0],["newline",G0],["escape",q0],["backticks",X0],["strikethrough",Li.tokenize],["emphasis",Oi.tokenize],["link",J0],["image",ed],["autolink",rd],["html_inline",ad],["entity",ld]],Bu=[["balance_pairs",dd],["strikethrough",Li.postProcess],["emphasis",Oi.postProcess],["fragments_join",fd]];function Bn(){this.ruler=new Ue;for(let e=0;e<Vu.length;e++)this.ruler.push(Vu[e][0],Vu[e][1]);this.ruler2=new Ue;for(let e=0;e<Bu.length;e++)this.ruler2.push(Bu[e][0],Bu[e][1])}Bn.prototype.skipToken=function(e){const t=e.pos,n=this.ruler.getRules(""),u=n.length,o=e.md.options.maxNesting,r=e.cache;if(typeof r[t]<"u"){e.pos=r[t];return}let a=!1;if(e.level<o){for(let s=0;s<u;s++)if(e.level++,a=n[s](e,!0),e.level--,a){if(t>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;a||e.pos++,r[t]=e.pos},Bn.prototype.tokenize=function(e){const t=this.ruler.getRules(""),n=t.length,u=e.posMax,o=e.md.options.maxNesting;for(;e.pos<u;){const r=e.pos;let a=!1;if(e.level<o){for(let s=0;s<n;s++)if(a=t[s](e,!1),a){if(r>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}if(a){if(e.pos>=u)break;continue}e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},Bn.prototype.parse=function(e,t,n,u){const o=new this.State(e,t,n,u);this.tokenize(o);const r=this.ruler2.getRules(""),a=r.length;for(let s=0;s<a;s++)r[s](o)},Bn.prototype.State=Vn;function hd(e){const t={};e=e||{},t.src_Any=pi.source,t.src_Cc=mi.source,t.src_Z=bi.source,t.src_P=Du.source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");const n="[><|]";return t.src_pseudo_letter="(?:(?!"+n+"|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|"+n+"|"+t.src_ZPCc+")(?!"+(e["---"]?"-(?!--)|":"-|")+"_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|"+n+`|[()[\\]{}.,"'?!\\-;]).|\\[(?:(?!`+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+`|["]).)+\\"|\\'(?:(?!`+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]|$)|"+(e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+",(?!"+t.src_ZCc+"|$)|;(?!"+t.src_ZCc+"|$)|\\!+(?!"+t.src_ZCc+"|[!]|$)|\\?(?!"+t.src_ZCc+"|[?]|$))+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy="(^|"+n+'|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}function zu(e){return Array.prototype.slice.call(arguments,1).forEach(function(n){n&&Object.keys(n).forEach(function(u){e[u]=n[u]})}),e}function Rr(e){return Object.prototype.toString.call(e)}function pd(e){return Rr(e)==="[object String]"}function md(e){return Rr(e)==="[object Object]"}function gd(e){return Rr(e)==="[object RegExp]"}function Ri(e){return Rr(e)==="[object Function]"}function bd(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}const Mi={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};function yd(e){return Object.keys(e||{}).reduce(function(t,n){return t||Mi.hasOwnProperty(n)},!1)}const xd={"http:":{validate:function(e,t,n){const u=e.slice(t);return n.re.http||(n.re.http=new RegExp("^\\/\\/"+n.re.src_auth+n.re.src_host_port_strict+n.re.src_path,"i")),n.re.http.test(u)?u.match(n.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,n){const u=e.slice(t);return n.re.no_http||(n.re.no_http=new RegExp("^"+n.re.src_auth+"(?:localhost|(?:(?:"+n.re.src_domain+")\\.)+"+n.re.src_domain_root+")"+n.re.src_port+n.re.src_host_terminator+n.re.src_path,"i")),n.re.no_http.test(u)?t>=3&&e[t-3]===":"||t>=3&&e[t-3]==="/"?0:u.match(n.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,n){const u=e.slice(t);return n.re.mailto||(n.re.mailto=new RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(u)?u.match(n.re.mailto)[0].length:0}}},wd="a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]",vd="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");function Ad(e){e.__index__=-1,e.__text_cache__=""}function kd(e){return function(t,n){const u=t.slice(n);return e.test(u)?u.match(e)[0].length:0}}function Vi(){return function(e,t){t.normalize(e)}}function Mr(e){const t=e.re=hd(e.__opts__),n=e.__tlds__.slice();e.onCompile(),e.__tlds_replaced__||n.push(wd),n.push(t.src_xn),t.src_tlds=n.join("|");function u(s){return s.replace("%TLDS%",t.src_tlds)}t.email_fuzzy=RegExp(u(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(u(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(u(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(u(t.tpl_host_fuzzy_test),"i");const o=[];e.__compiled__={};function r(s,c){throw new Error('(LinkifyIt) Invalid schema "'+s+'": '+c)}Object.keys(e.__schemas__).forEach(function(s){const c=e.__schemas__[s];if(c===null)return;const d={validate:null,link:null};if(e.__compiled__[s]=d,md(c)){gd(c.validate)?d.validate=kd(c.validate):Ri(c.validate)?d.validate=c.validate:r(s,c),Ri(c.normalize)?d.normalize=c.normalize:c.normalize?r(s,c):d.normalize=Vi();return}if(pd(c)){o.push(s);return}r(s,c)}),o.forEach(function(s){e.__compiled__[e.__schemas__[s]]&&(e.__compiled__[s].validate=e.__compiled__[e.__schemas__[s]].validate,e.__compiled__[s].normalize=e.__compiled__[e.__schemas__[s]].normalize)}),e.__compiled__[""]={validate:null,normalize:Vi()};const a=Object.keys(e.__compiled__).filter(function(s){return s.length>0&&e.__compiled__[s]}).map(bd).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+a+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+a+")","ig"),e.re.schema_at_start=RegExp("^"+e.re.schema_search.source,"i"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),Ad(e)}function Cd(e,t){const n=e.__index__,u=e.__last_index__,o=e.__text_cache__.slice(n,u);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=u+t,this.raw=o,this.text=o,this.url=o}function ju(e,t){const n=new Cd(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function Ge(e,t){if(!(this instanceof Ge))return new Ge(e,t);t||yd(e)&&(t=e,e={}),this.__opts__=zu({},Mi,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=zu({},xd,e),this.__compiled__={},this.__tlds__=vd,this.__tlds_replaced__=!1,this.re={},Mr(this)}Ge.prototype.add=function(t,n){return this.__schemas__[t]=n,Mr(this),this},Ge.prototype.set=function(t){return this.__opts__=zu(this.__opts__,t),this},Ge.prototype.test=function(t){if(this.__text_cache__=t,this.__index__=-1,!t.length)return!1;let n,u,o,r,a,s,c,d,f;if(this.re.schema_test.test(t)){for(c=this.re.schema_search,c.lastIndex=0;(n=c.exec(t))!==null;)if(r=this.testSchemaAt(t,n[2],c.lastIndex),r){this.__schema__=n[2],this.__index__=n.index+n[1].length,this.__last_index__=n.index+n[0].length+r;break}}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(d=t.search(this.re.host_fuzzy_test),d>=0&&(this.__index__<0||d<this.__index__)&&(u=t.match(this.__opts__.fuzzyIP?this.re.link_fuzzy:this.re.link_no_ip_fuzzy))!==null&&(a=u.index+u[1].length,(this.__index__<0||a<this.__index__)&&(this.__schema__="",this.__index__=a,this.__last_index__=u.index+u[0].length))),this.__opts__.fuzzyEmail&&this.__compiled__["mailto:"]&&(f=t.indexOf("@"),f>=0&&(o=t.match(this.re.email_fuzzy))!==null&&(a=o.index+o[1].length,s=o.index+o[0].length,(this.__index__<0||a<this.__index__||a===this.__index__&&s>this.__last_index__)&&(this.__schema__="mailto:",this.__index__=a,this.__last_index__=s))),this.__index__>=0},Ge.prototype.pretest=function(t){return this.re.pretest.test(t)},Ge.prototype.testSchemaAt=function(t,n,u){return this.__compiled__[n.toLowerCase()]?this.__compiled__[n.toLowerCase()].validate(t,u,this):0},Ge.prototype.match=function(t){const n=[];let u=0;this.__index__>=0&&this.__text_cache__===t&&(n.push(ju(this,u)),u=this.__last_index__);let o=u?t.slice(u):t;for(;this.test(o);)n.push(ju(this,u)),o=o.slice(this.__last_index__),u+=this.__last_index__;return n.length?n:null},Ge.prototype.matchAtStart=function(t){if(this.__text_cache__=t,this.__index__=-1,!t.length)return null;const n=this.re.schema_at_start.exec(t);if(!n)return null;const u=this.testSchemaAt(t,n[2],n[0].length);return u?(this.__schema__=n[2],this.__index__=n.index+n[1].length,this.__last_index__=n.index+n[0].length+u,ju(this,0)):null},Ge.prototype.tlds=function(t,n){return t=Array.isArray(t)?t:[t],n?(this.__tlds__=this.__tlds__.concat(t).sort().filter(function(u,o,r){return u!==r[o-1]}).reverse(),Mr(this),this):(this.__tlds__=t.slice(),this.__tlds_replaced__=!0,Mr(this),this)},Ge.prototype.normalize=function(t){t.schema||(t.url="http://"+t.url),t.schema==="mailto:"&&!/^mailto:/i.test(t.url)&&(t.url="mailto:"+t.url)},Ge.prototype.onCompile=function(){};const dn=2147483647,bt=36,Hu=1,zn=26,Ed=38,_d=700,Bi=72,zi=128,ji="-",Sd=/^xn--/,Fd=/[^\0-\x7F]/,Dd=/[\x2E\u3002\uFF0E\uFF61]/g,Td={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},Uu=bt-Hu,yt=Math.floor,$u=String.fromCharCode;function Pt(e){throw new RangeError(Td[e])}function Nd(e,t){const n=[];let u=e.length;for(;u--;)n[u]=t(e[u]);return n}function Hi(e,t){const n=e.split("@");let u="";n.length>1&&(u=n[0]+"@",e=n[1]),e=e.replace(Dd,".");const o=e.split("."),r=Nd(o,t).join(".");return u+r}function Ui(e){const t=[];let n=0;const u=e.length;for(;n<u;){const o=e.charCodeAt(n++);if(o>=55296&&o<=56319&&n<u){const r=e.charCodeAt(n++);(r&64512)==56320?t.push(((o&1023)<<10)+(r&1023)+65536):(t.push(o),n--)}else t.push(o)}return t}const Ld=e=>String.fromCodePoint(...e),Id=function(e){return e>=48&&e<58?26+(e-48):e>=65&&e<91?e-65:e>=97&&e<123?e-97:bt},$i=function(e,t){return e+22+75*(e<26)-((t!=0)<<5)},Wi=function(e,t,n){let u=0;for(e=n?yt(e/_d):e>>1,e+=yt(e/t);e>Uu*zn>>1;u+=bt)e=yt(e/Uu);return yt(u+(Uu+1)*e/(e+Ed))},Gi=function(e){const t=[],n=e.length;let u=0,o=zi,r=Bi,a=e.lastIndexOf(ji);a<0&&(a=0);for(let s=0;s<a;++s)e.charCodeAt(s)>=128&&Pt("not-basic"),t.push(e.charCodeAt(s));for(let s=a>0?a+1:0;s<n;){const c=u;for(let f=1,l=bt;;l+=bt){s>=n&&Pt("invalid-input");const p=Id(e.charCodeAt(s++));p>=bt&&Pt("invalid-input"),p>yt((dn-u)/f)&&Pt("overflow"),u+=p*f;const m=l<=r?Hu:l>=r+zn?zn:l-r;if(p<m)break;const h=bt-m;f>yt(dn/h)&&Pt("overflow"),f*=h}const d=t.length+1;r=Wi(u-c,d,c==0),yt(u/d)>dn-o&&Pt("overflow"),o+=yt(u/d),u%=d,t.splice(u++,0,o)}return String.fromCodePoint(...t)},qi=function(e){const t=[];e=Ui(e);const n=e.length;let u=zi,o=0,r=Bi;for(const c of e)c<128&&t.push($u(c));const a=t.length;let s=a;for(a&&t.push(ji);s<n;){let c=dn;for(const f of e)f>=u&&f<c&&(c=f);const d=s+1;c-u>yt((dn-o)/d)&&Pt("overflow"),o+=(c-u)*d,u=c;for(const f of e)if(f<u&&++o>dn&&Pt("overflow"),f===u){let l=o;for(let p=bt;;p+=bt){const m=p<=r?Hu:p>=r+zn?zn:p-r;if(l<m)break;const h=l-m,x=bt-m;t.push($u($i(m+h%x,0))),l=yt(h/x)}t.push($u($i(l,0))),r=Wi(o,d,s===a),o=0,++s}++o,++u}return t.join("")},Xi={version:"2.3.1",ucs2:{decode:Ui,encode:Ld},decode:Gi,encode:qi,toASCII:function(e){return Hi(e,function(t){return Fd.test(t)?"xn--"+qi(t):t})},toUnicode:function(e){return Hi(e,function(t){return Sd.test(t)?Gi(t.slice(4).toLowerCase()):t})}},Od={default:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}},zero:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","fragments_join"]}}},commonmark:{options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","fragments_join"]}}}},Pd=/^(vbscript|javascript|file|data):/,Rd=/^data:image\/(gif|png|jpeg|webp);/;function Md(e){const t=e.trim().toLowerCase();return Pd.test(t)?Rd.test(t):!0}const Zi=["http:","https:","mailto:"];function Vd(e){const t=Fu(e,!0);if(t.hostname&&(!t.protocol||Zi.indexOf(t.protocol)>=0))try{t.hostname=Xi.toASCII(t.hostname)}catch{}return On(Su(t))}function Bd(e){const t=Fu(e,!0);if(t.hostname&&(!t.protocol||Zi.indexOf(t.protocol)>=0))try{t.hostname=Xi.toUnicode(t.hostname)}catch{}return an(Su(t),an.defaultChars+"%")}function qe(e,t){if(!(this instanceof qe))return new qe(e,t);t||Lu(e)||(t=e||{},e="default"),this.inline=new Bn,this.block=new Pr,this.core=new Pu,this.renderer=new cn,this.linkify=new Ge,this.validateLink=Md,this.normalizeLink=Vd,this.normalizeLinkText=Bd,this.utils=Yl,this.helpers=Tr({},e0),this.options={},this.configure(e),t&&this.set(t)}qe.prototype.set=function(e){return Tr(this.options,e),this},qe.prototype.configure=function(e){const t=this;if(Lu(e)){const n=e;if(e=Od[n],!e)throw new Error('Wrong `markdown-it` preset "'+n+'", check name')}if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach(function(n){e.components[n].rules&&t[n].ruler.enableOnly(e.components[n].rules),e.components[n].rules2&&t[n].ruler2.enableOnly(e.components[n].rules2)}),this},qe.prototype.enable=function(e,t){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(o){n=n.concat(this[o].ruler.enable(e,!0))},this),n=n.concat(this.inline.ruler2.enable(e,!0));const u=e.filter(function(o){return n.indexOf(o)<0});if(u.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+u);return this},qe.prototype.disable=function(e,t){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(o){n=n.concat(this[o].ruler.disable(e,!0))},this),n=n.concat(this.inline.ruler2.disable(e,!0));const u=e.filter(function(o){return n.indexOf(o)<0});if(u.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+u);return this},qe.prototype.use=function(e){const t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},qe.prototype.parse=function(e,t){if(typeof e!="string")throw new Error("Input data should be a String");const n=new this.core.State(e,this,t);return this.core.process(n),n.tokens},qe.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},qe.prototype.parseInline=function(e,t){const n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens},qe.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)};/*! @license DOMPurify 3.3.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.3/LICENSE */const{entries:Yi,setPrototypeOf:Ki,isFrozen:zd,getPrototypeOf:jd,getOwnPropertyDescriptor:Hd}=Object;let{freeze:Ve,seal:tt,create:Vr}=Object,{apply:Wu,construct:Gu}=typeof Reflect<"u"&&Reflect;Ve||(Ve=function(t){return t}),tt||(tt=function(t){return t}),Wu||(Wu=function(t,n){for(var u=arguments.length,o=new Array(u>2?u-2:0),r=2;r<u;r++)o[r-2]=arguments[r];return t.apply(n,o)}),Gu||(Gu=function(t){for(var n=arguments.length,u=new Array(n>1?n-1:0),o=1;o<n;o++)u[o-1]=arguments[o];return new t(...u)});const Br=ze(Array.prototype.forEach),Ud=ze(Array.prototype.lastIndexOf),Qi=ze(Array.prototype.pop),jn=ze(Array.prototype.push),$d=ze(Array.prototype.splice),zr=ze(String.prototype.toLowerCase),qu=ze(String.prototype.toString),Xu=ze(String.prototype.match),Hn=ze(String.prototype.replace),Wd=ze(String.prototype.indexOf),Gd=ze(String.prototype.trim),Xe=ze(Object.prototype.hasOwnProperty),Be=ze(RegExp.prototype.test),Un=qd(TypeError);function ze(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,u=new Array(n>1?n-1:0),o=1;o<n;o++)u[o-1]=arguments[o];return Wu(e,t,u)}}function qd(e){return function(){for(var t=arguments.length,n=new Array(t),u=0;u<t;u++)n[u]=arguments[u];return Gu(e,n)}}function oe(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:zr;Ki&&Ki(e,null);let u=t.length;for(;u--;){let o=t[u];if(typeof o=="string"){const r=n(o);r!==o&&(zd(t)||(t[u]=r),o=r)}e[o]=!0}return e}function Xd(e){for(let t=0;t<e.length;t++)Xe(e,t)||(e[t]=null);return e}function xt(e){const t=Vr(null);for(const[n,u]of Yi(e))Xe(e,n)&&(Array.isArray(u)?t[n]=Xd(u):u&&typeof u=="object"&&u.constructor===Object?t[n]=xt(u):t[n]=u);return t}function $n(e,t){for(;e!==null;){const u=Hd(e,t);if(u){if(u.get)return ze(u.get);if(typeof u.value=="function")return ze(u.value)}e=jd(e)}function n(){return null}return n}const Ji=Ve(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Zu=Ve(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Yu=Ve(["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"]),Zd=Ve(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Ku=Ve(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Yd=Ve(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ea=Ve(["#text"]),ta=Ve(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),Qu=Ve(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),na=Ve(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),jr=Ve(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Kd=tt(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Qd=tt(/<%[\w\W]*|[\w\W]*%>/gm),Jd=tt(/\$\{[\w\W]*/gm),ef=tt(/^data-[\-\w.\u00B7-\uFFFF]+$/),tf=tt(/^aria-[\-\w]+$/),ra=tt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),nf=tt(/^(?:\w+script|data):/i),rf=tt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ua=tt(/^html$/i),uf=tt(/^[a-z][.\w]*(-[.\w]+)+$/i);var oa=Object.freeze({__proto__:null,ARIA_ATTR:tf,ATTR_WHITESPACE:rf,CUSTOM_ELEMENT:uf,DATA_ATTR:ef,DOCTYPE_NAME:ua,ERB_EXPR:Qd,IS_ALLOWED_URI:ra,IS_SCRIPT_OR_DATA:nf,MUSTACHE_EXPR:Kd,TMPLIT_EXPR:Jd});const Wn={element:1,text:3,progressingInstruction:7,comment:8,document:9},of=function(){return typeof window>"u"?null:window},af=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let u=null;const o="data-tt-policy-suffix";n&&n.hasAttribute(o)&&(u=n.getAttribute(o));const r="dompurify"+(u?"#"+u:"");try{return t.createPolicy(r,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+r+" could not be created."),null}},ia=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function aa(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:of();const t=J=>aa(J);if(t.version="3.3.3",t.removed=[],!e||!e.document||e.document.nodeType!==Wn.document||!e.Element)return t.isSupported=!1,t;let{document:n}=e;const u=n,o=u.currentScript,{DocumentFragment:r,HTMLTemplateElement:a,Node:s,Element:c,NodeFilter:d,NamedNodeMap:f=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:l,DOMParser:p,trustedTypes:m}=e,h=c.prototype,x=$n(h,"cloneNode"),y=$n(h,"remove"),v=$n(h,"nextSibling"),g=$n(h,"childNodes"),b=$n(h,"parentNode");if(typeof a=="function"){const J=n.createElement("template");J.content&&J.content.ownerDocument&&(n=J.content.ownerDocument)}let w,k="";const{implementation:S,createNodeIterator:_,createDocumentFragment:E,getElementsByTagName:W}=n,{importNode:V}=u;let O=ia();t.isSupported=typeof Yi=="function"&&typeof b=="function"&&S&&S.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:B,ERB_EXPR:D,TMPLIT_EXPR:j,DATA_ATTR:H,ARIA_ATTR:F,IS_SCRIPT_OR_DATA:R,ATTR_WHITESPACE:I,CUSTOM_ELEMENT:U}=oa;let{IS_ALLOWED_URI:re}=oa,te=null;const P=oe({},[...Ji,...Zu,...Yu,...Ku,...ea]);let M=null;const T=oe({},[...ta,...Qu,...na,...jr]);let L=Object.seal(Vr(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),$=null,K=null;const Z=Object.seal(Vr(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Y=!0,ue=!0,ce=!1,Te=!0,Ne=!1,pt=!0,Re=!1,Fn=!1,Ut=!1,Ft=!1,mu=!1,gu=!1,wc=!0,vc=!1;const Ap="user-content-";let jo=!0,Ar=!1,Dn={},Et=null;const Ho=oe({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Ac=null;const kc=oe({},["audio","video","img","source","image","track"]);let Uo=null;const Cc=oe({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),bu="http://www.w3.org/1998/Math/MathML",yu="http://www.w3.org/2000/svg",Dt="http://www.w3.org/1999/xhtml";let Tn=Dt,$o=!1,Wo=null;const kp=oe({},[bu,yu,Dt],qu);let xu=oe({},["mi","mo","mn","ms","mtext"]),wu=oe({},["annotation-xml"]);const Cp=oe({},["title","style","font","a","script"]);let kr=null;const Ep=["application/xhtml+xml","text/html"],_p="text/html";let Ee=null,Nn=null;const Sp=n.createElement("form"),Ec=function(C){return C instanceof RegExp||C instanceof Function},Go=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Nn&&Nn===C)){if((!C||typeof C!="object")&&(C={}),C=xt(C),kr=Ep.indexOf(C.PARSER_MEDIA_TYPE)===-1?_p:C.PARSER_MEDIA_TYPE,Ee=kr==="application/xhtml+xml"?qu:zr,te=Xe(C,"ALLOWED_TAGS")?oe({},C.ALLOWED_TAGS,Ee):P,M=Xe(C,"ALLOWED_ATTR")?oe({},C.ALLOWED_ATTR,Ee):T,Wo=Xe(C,"ALLOWED_NAMESPACES")?oe({},C.ALLOWED_NAMESPACES,qu):kp,Uo=Xe(C,"ADD_URI_SAFE_ATTR")?oe(xt(Cc),C.ADD_URI_SAFE_ATTR,Ee):Cc,Ac=Xe(C,"ADD_DATA_URI_TAGS")?oe(xt(kc),C.ADD_DATA_URI_TAGS,Ee):kc,Et=Xe(C,"FORBID_CONTENTS")?oe({},C.FORBID_CONTENTS,Ee):Ho,$=Xe(C,"FORBID_TAGS")?oe({},C.FORBID_TAGS,Ee):xt({}),K=Xe(C,"FORBID_ATTR")?oe({},C.FORBID_ATTR,Ee):xt({}),Dn=Xe(C,"USE_PROFILES")?C.USE_PROFILES:!1,Y=C.ALLOW_ARIA_ATTR!==!1,ue=C.ALLOW_DATA_ATTR!==!1,ce=C.ALLOW_UNKNOWN_PROTOCOLS||!1,Te=C.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Ne=C.SAFE_FOR_TEMPLATES||!1,pt=C.SAFE_FOR_XML!==!1,Re=C.WHOLE_DOCUMENT||!1,Ft=C.RETURN_DOM||!1,mu=C.RETURN_DOM_FRAGMENT||!1,gu=C.RETURN_TRUSTED_TYPE||!1,Ut=C.FORCE_BODY||!1,wc=C.SANITIZE_DOM!==!1,vc=C.SANITIZE_NAMED_PROPS||!1,jo=C.KEEP_CONTENT!==!1,Ar=C.IN_PLACE||!1,re=C.ALLOWED_URI_REGEXP||ra,Tn=C.NAMESPACE||Dt,xu=C.MATHML_TEXT_INTEGRATION_POINTS||xu,wu=C.HTML_INTEGRATION_POINTS||wu,L=C.CUSTOM_ELEMENT_HANDLING||{},C.CUSTOM_ELEMENT_HANDLING&&Ec(C.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(L.tagNameCheck=C.CUSTOM_ELEMENT_HANDLING.tagNameCheck),C.CUSTOM_ELEMENT_HANDLING&&Ec(C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(L.attributeNameCheck=C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),C.CUSTOM_ELEMENT_HANDLING&&typeof C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(L.allowCustomizedBuiltInElements=C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Ne&&(ue=!1),mu&&(Ft=!0),Dn&&(te=oe({},ea),M=Vr(null),Dn.html===!0&&(oe(te,Ji),oe(M,ta)),Dn.svg===!0&&(oe(te,Zu),oe(M,Qu),oe(M,jr)),Dn.svgFilters===!0&&(oe(te,Yu),oe(M,Qu),oe(M,jr)),Dn.mathMl===!0&&(oe(te,Ku),oe(M,na),oe(M,jr))),Xe(C,"ADD_TAGS")||(Z.tagCheck=null),Xe(C,"ADD_ATTR")||(Z.attributeCheck=null),C.ADD_TAGS&&(typeof C.ADD_TAGS=="function"?Z.tagCheck=C.ADD_TAGS:(te===P&&(te=xt(te)),oe(te,C.ADD_TAGS,Ee))),C.ADD_ATTR&&(typeof C.ADD_ATTR=="function"?Z.attributeCheck=C.ADD_ATTR:(M===T&&(M=xt(M)),oe(M,C.ADD_ATTR,Ee))),C.ADD_URI_SAFE_ATTR&&oe(Uo,C.ADD_URI_SAFE_ATTR,Ee),C.FORBID_CONTENTS&&(Et===Ho&&(Et=xt(Et)),oe(Et,C.FORBID_CONTENTS,Ee)),C.ADD_FORBID_CONTENTS&&(Et===Ho&&(Et=xt(Et)),oe(Et,C.ADD_FORBID_CONTENTS,Ee)),jo&&(te["#text"]=!0),Re&&oe(te,["html","head","body"]),te.table&&(oe(te,["tbody"]),delete $.tbody),C.TRUSTED_TYPES_POLICY){if(typeof C.TRUSTED_TYPES_POLICY.createHTML!="function")throw Un('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof C.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Un('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');w=C.TRUSTED_TYPES_POLICY,k=w.createHTML("")}else w===void 0&&(w=af(m,o)),w!==null&&typeof k=="string"&&(k=w.createHTML(""));Ve&&Ve(C),Nn=C}},_c=oe({},[...Zu,...Yu,...Zd]),Sc=oe({},[...Ku,...Yd]),Fp=function(C){let z=b(C);(!z||!z.tagName)&&(z={namespaceURI:Tn,tagName:"template"});const Q=zr(C.tagName),ge=zr(z.tagName);return Wo[C.namespaceURI]?C.namespaceURI===yu?z.namespaceURI===Dt?Q==="svg":z.namespaceURI===bu?Q==="svg"&&(ge==="annotation-xml"||xu[ge]):!!_c[Q]:C.namespaceURI===bu?z.namespaceURI===Dt?Q==="math":z.namespaceURI===yu?Q==="math"&&wu[ge]:!!Sc[Q]:C.namespaceURI===Dt?z.namespaceURI===yu&&!wu[ge]||z.namespaceURI===bu&&!xu[ge]?!1:!Sc[Q]&&(Cp[Q]||!_c[Q]):!!(kr==="application/xhtml+xml"&&Wo[C.namespaceURI]):!1},_t=function(C){jn(t.removed,{element:C});try{b(C).removeChild(C)}catch{y(C)}},nn=function(C,z){try{jn(t.removed,{attribute:z.getAttributeNode(C),from:z})}catch{jn(t.removed,{attribute:null,from:z})}if(z.removeAttribute(C),C==="is")if(Ft||mu)try{_t(z)}catch{}else try{z.setAttribute(C,"")}catch{}},Fc=function(C){let z=null,Q=null;if(Ut)C="<remove></remove>"+C;else{const ve=Xu(C,/^[\r\n\t ]+/);Q=ve&&ve[0]}kr==="application/xhtml+xml"&&Tn===Dt&&(C='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+C+"</body></html>");const ge=w?w.createHTML(C):C;if(Tn===Dt)try{z=new p().parseFromString(ge,kr)}catch{}if(!z||!z.documentElement){z=S.createDocument(Tn,"template",null);try{z.documentElement.innerHTML=$o?k:ge}catch{}}const Me=z.body||z.documentElement;return C&&Q&&Me.insertBefore(n.createTextNode(Q),Me.childNodes[0]||null),Tn===Dt?W.call(z,Re?"html":"body")[0]:Re?z.documentElement:Me},Dc=function(C){return _.call(C.ownerDocument||C,C,d.SHOW_ELEMENT|d.SHOW_COMMENT|d.SHOW_TEXT|d.SHOW_PROCESSING_INSTRUCTION|d.SHOW_CDATA_SECTION,null)},qo=function(C){return C instanceof l&&(typeof C.nodeName!="string"||typeof C.textContent!="string"||typeof C.removeChild!="function"||!(C.attributes instanceof f)||typeof C.removeAttribute!="function"||typeof C.setAttribute!="function"||typeof C.namespaceURI!="string"||typeof C.insertBefore!="function"||typeof C.hasChildNodes!="function")},Tc=function(C){return typeof s=="function"&&C instanceof s};function Tt(J,C,z){Br(J,Q=>{Q.call(t,C,z,Nn)})}const Nc=function(C){let z=null;if(Tt(O.beforeSanitizeElements,C,null),qo(C))return _t(C),!0;const Q=Ee(C.nodeName);if(Tt(O.uponSanitizeElement,C,{tagName:Q,allowedTags:te}),pt&&C.hasChildNodes()&&!Tc(C.firstElementChild)&&Be(/<[/\w!]/g,C.innerHTML)&&Be(/<[/\w!]/g,C.textContent)||C.nodeType===Wn.progressingInstruction||pt&&C.nodeType===Wn.comment&&Be(/<[/\w]/g,C.data))return _t(C),!0;if(!(Z.tagCheck instanceof Function&&Z.tagCheck(Q))&&(!te[Q]||$[Q])){if(!$[Q]&&Ic(Q)&&(L.tagNameCheck instanceof RegExp&&Be(L.tagNameCheck,Q)||L.tagNameCheck instanceof Function&&L.tagNameCheck(Q)))return!1;if(jo&&!Et[Q]){const ge=b(C)||C.parentNode,Me=g(C)||C.childNodes;if(Me&&ge){const ve=Me.length;for(let We=ve-1;We>=0;--We){const Nt=x(Me[We],!0);Nt.__removalCount=(C.__removalCount||0)+1,ge.insertBefore(Nt,v(C))}}}return _t(C),!0}return C instanceof c&&!Fp(C)||(Q==="noscript"||Q==="noembed"||Q==="noframes")&&Be(/<\/no(script|embed|frames)/i,C.innerHTML)?(_t(C),!0):(Ne&&C.nodeType===Wn.text&&(z=C.textContent,Br([B,D,j],ge=>{z=Hn(z,ge," ")}),C.textContent!==z&&(jn(t.removed,{element:C.cloneNode()}),C.textContent=z)),Tt(O.afterSanitizeElements,C,null),!1)},Lc=function(C,z,Q){if(K[z]||wc&&(z==="id"||z==="name")&&(Q in n||Q in Sp))return!1;if(!(ue&&!K[z]&&Be(H,z))){if(!(Y&&Be(F,z))){if(!(Z.attributeCheck instanceof Function&&Z.attributeCheck(z,C))){if(!M[z]||K[z]){if(!(Ic(C)&&(L.tagNameCheck instanceof RegExp&&Be(L.tagNameCheck,C)||L.tagNameCheck instanceof Function&&L.tagNameCheck(C))&&(L.attributeNameCheck instanceof RegExp&&Be(L.attributeNameCheck,z)||L.attributeNameCheck instanceof Function&&L.attributeNameCheck(z,C))||z==="is"&&L.allowCustomizedBuiltInElements&&(L.tagNameCheck instanceof RegExp&&Be(L.tagNameCheck,Q)||L.tagNameCheck instanceof Function&&L.tagNameCheck(Q))))return!1}else if(!Uo[z]){if(!Be(re,Hn(Q,I,""))){if(!((z==="src"||z==="xlink:href"||z==="href")&&C!=="script"&&Wd(Q,"data:")===0&&Ac[C])){if(!(ce&&!Be(R,Hn(Q,I,"")))){if(Q)return!1}}}}}}}return!0},Ic=function(C){return C!=="annotation-xml"&&Xu(C,U)},Oc=function(C){Tt(O.beforeSanitizeAttributes,C,null);const{attributes:z}=C;if(!z||qo(C))return;const Q={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:M,forceKeepAttr:void 0};let ge=z.length;for(;ge--;){const Me=z[ge],{name:ve,namespaceURI:We,value:Nt}=Me,Ln=Ee(ve),Xo=Nt;let Ie=ve==="value"?Xo:Gd(Xo);if(Q.attrName=Ln,Q.attrValue=Ie,Q.keepAttr=!0,Q.forceKeepAttr=void 0,Tt(O.uponSanitizeAttribute,C,Q),Ie=Q.attrValue,vc&&(Ln==="id"||Ln==="name")&&(nn(ve,C),Ie=Ap+Ie),pt&&Be(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,Ie)){nn(ve,C);continue}if(Ln==="attributename"&&Xu(Ie,"href")){nn(ve,C);continue}if(Q.forceKeepAttr)continue;if(!Q.keepAttr){nn(ve,C);continue}if(!Te&&Be(/\/>/i,Ie)){nn(ve,C);continue}Ne&&Br([B,D,j],Rc=>{Ie=Hn(Ie,Rc," ")});const Pc=Ee(C.nodeName);if(!Lc(Pc,Ln,Ie)){nn(ve,C);continue}if(w&&typeof m=="object"&&typeof m.getAttributeType=="function"&&!We)switch(m.getAttributeType(Pc,Ln)){case"TrustedHTML":{Ie=w.createHTML(Ie);break}case"TrustedScriptURL":{Ie=w.createScriptURL(Ie);break}}if(Ie!==Xo)try{We?C.setAttributeNS(We,ve,Ie):C.setAttribute(ve,Ie),qo(C)?_t(C):Qi(t.removed)}catch{nn(ve,C)}}Tt(O.afterSanitizeAttributes,C,null)},Dp=function J(C){let z=null;const Q=Dc(C);for(Tt(O.beforeSanitizeShadowDOM,C,null);z=Q.nextNode();)Tt(O.uponSanitizeShadowNode,z,null),Nc(z),Oc(z),z.content instanceof r&&J(z.content);Tt(O.afterSanitizeShadowDOM,C,null)};return t.sanitize=function(J){let C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},z=null,Q=null,ge=null,Me=null;if($o=!J,$o&&(J="<!-->"),typeof J!="string"&&!Tc(J))if(typeof J.toString=="function"){if(J=J.toString(),typeof J!="string")throw Un("dirty is not a string, aborting")}else throw Un("toString is not a function");if(!t.isSupported)return J;if(Fn||Go(C),t.removed=[],typeof J=="string"&&(Ar=!1),Ar){if(J.nodeName){const Nt=Ee(J.nodeName);if(!te[Nt]||$[Nt])throw Un("root node is forbidden and cannot be sanitized in-place")}}else if(J instanceof s)z=Fc("<!---->"),Q=z.ownerDocument.importNode(J,!0),Q.nodeType===Wn.element&&Q.nodeName==="BODY"||Q.nodeName==="HTML"?z=Q:z.appendChild(Q);else{if(!Ft&&!Ne&&!Re&&J.indexOf("<")===-1)return w&&gu?w.createHTML(J):J;if(z=Fc(J),!z)return Ft?null:gu?k:""}z&&Ut&&_t(z.firstChild);const ve=Dc(Ar?J:z);for(;ge=ve.nextNode();)Nc(ge),Oc(ge),ge.content instanceof r&&Dp(ge.content);if(Ar)return J;if(Ft){if(mu)for(Me=E.call(z.ownerDocument);z.firstChild;)Me.appendChild(z.firstChild);else Me=z;return(M.shadowroot||M.shadowrootmode)&&(Me=V.call(u,Me,!0)),Me}let We=Re?z.outerHTML:z.innerHTML;return Re&&te["!doctype"]&&z.ownerDocument&&z.ownerDocument.doctype&&z.ownerDocument.doctype.name&&Be(ua,z.ownerDocument.doctype.name)&&(We="<!DOCTYPE "+z.ownerDocument.doctype.name+`>
17
+ `+We),Ne&&Br([B,D,j],Nt=>{We=Hn(We,Nt," ")}),w&&gu?w.createHTML(We):We},t.setConfig=function(){let J=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Go(J),Fn=!0},t.clearConfig=function(){Nn=null,Fn=!1},t.isValidAttribute=function(J,C,z){Nn||Go({});const Q=Ee(J),ge=Ee(C);return Lc(Q,ge,z)},t.addHook=function(J,C){typeof C=="function"&&jn(O[J],C)},t.removeHook=function(J,C){if(C!==void 0){const z=Ud(O[J],C);return z===-1?void 0:$d(O[J],z,1)[0]}return Qi(O[J])},t.removeHooks=function(J){O[J]=[]},t.removeAllHooks=function(){O=ia()},t}var sf=aa();const sa={content:{type:Object,required:!0}},cf=new qe({html:!0,linkify:!0});function lf(e){const t=e.split(`
18
18
  `),n=t.filter(o=>o.trim().length>0);if(n.length===0)return e.trim();const u=Math.min(...n.map(o=>{var r;return(((r=o.match(/^\s*/))==null?void 0:r[0])??"").length}));return t.map(o=>o.slice(u)).join(`
19
- `).trim()}const hn=i.defineComponent({name:"FXMarkdownMessage",props:da,setup(e){const t=i.computed(()=>{var r;const n=(((r=e.content)==null?void 0:r.content)??"").replace(/\\n/g,`
20
- `),u=nf(n);if(!u)return"";const o=tf.render(u);return ef.sanitize(o,{ADD_TAGS:["style"],ADD_ATTR:["style","align","valign","colspan","rowspan","scope","title"]})});return()=>{var u;const n=(u=e.content)==null?void 0:u.message;return i.createVNode("div",{class:"f-chat-message-markdown"},[n&&i.createVNode("div",{class:"f-chat-markdown-message"},[n]),i.createVNode("div",{class:"f-chat-markdown-content",innerHTML:t.value},null)])}}});hn.install=e=>{e.component(hn.name,hn)};function rf(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function uf(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var of=function(){function e(n){var u=this;this._insertTag=function(o){var r;u.tags.length===0?u.insertionPoint?r=u.insertionPoint.nextSibling:u.prepend?r=u.container.firstChild:r=u.before:r=u.tags[u.tags.length-1].nextSibling,u.container.insertBefore(o,r),u.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(u){u.forEach(this._insertTag)},t.insert=function(u){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(uf(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var r=rf(o);try{r.insertRule(u,r.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(u));this.ctr++},t.flush=function(){this.tags.forEach(function(u){var o;return(o=u.parentNode)==null?void 0:o.removeChild(u)}),this.tags=[],this.ctr=0},e}(),Oe="-ms-",Hr="-moz-",ae="-webkit-",fa="comm",to="rule",no="decl",af="@import",ha="@keyframes",sf="@layer",cf=Math.abs,$r=String.fromCharCode,lf=Object.assign;function df(e,t){return Ne(e,0)^45?(((t<<2^Ne(e,0))<<2^Ne(e,1))<<2^Ne(e,2))<<2^Ne(e,3):0}function pa(e){return e.trim()}function ff(e,t){return(e=t.exec(e))?e[0]:e}function se(e,t,n){return e.replace(t,n)}function ro(e,t){return e.indexOf(t)}function Ne(e,t){return e.charCodeAt(t)|0}function qn(e,t,n){return e.slice(t,n)}function xt(e){return e.length}function uo(e){return e.length}function Ur(e,t){return t.push(e),e}function hf(e,t){return e.map(t).join("")}var Wr=1,pn=1,ma=0,$e=0,xe=0,mn="";function Gr(e,t,n,u,o,r,a){return{value:e,root:t,parent:n,type:u,props:o,children:r,line:Wr,column:pn,length:a,return:""}}function Xn(e,t){return lf(Gr("",null,null,"",null,null,0),e,{length:-e.length},t)}function pf(){return xe}function mf(){return xe=$e>0?Ne(mn,--$e):0,pn--,xe===10&&(pn=1,Wr--),xe}function Xe(){return xe=$e<ma?Ne(mn,$e++):0,pn++,xe===10&&(pn=1,Wr++),xe}function wt(){return Ne(mn,$e)}function qr(){return $e}function Zn(e,t){return qn(mn,e,t)}function Yn(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ga(e){return Wr=pn=1,ma=xt(mn=e),$e=0,[]}function ba(e){return mn="",e}function Xr(e){return pa(Zn($e-1,oo(e===91?e+2:e===40?e+1:e)))}function gf(e){for(;(xe=wt())&&xe<33;)Xe();return Yn(e)>2||Yn(xe)>3?"":" "}function bf(e,t){for(;--t&&Xe()&&!(xe<48||xe>102||xe>57&&xe<65||xe>70&&xe<97););return Zn(e,qr()+(t<6&&wt()==32&&Xe()==32))}function oo(e){for(;Xe();)switch(xe){case e:return $e;case 34:case 39:e!==34&&e!==39&&oo(xe);break;case 40:e===41&&oo(e);break;case 92:Xe();break}return $e}function yf(e,t){for(;Xe()&&e+xe!==57;)if(e+xe===84&&wt()===47)break;return"/*"+Zn(t,$e-1)+"*"+$r(e===47?e:Xe())}function xf(e){for(;!Yn(wt());)Xe();return Zn(e,$e)}function wf(e){return ba(Zr("",null,null,null,[""],e=ga(e),0,[0],e))}function Zr(e,t,n,u,o,r,a,s,c){for(var d=0,f=0,l=a,p=0,m=0,h=0,y=1,x=1,v=1,g=0,b="",w=o,k=r,S=u,_=b;x;)switch(h=g,g=Xe()){case 40:if(h!=108&&Ne(_,l-1)==58){ro(_+=se(Xr(g),"&","&\f"),"&\f")!=-1&&(v=-1);break}case 34:case 39:case 91:_+=Xr(g);break;case 9:case 10:case 13:case 32:_+=gf(h);break;case 92:_+=bf(qr()-1,7);continue;case 47:switch(wt()){case 42:case 47:Ur(vf(yf(Xe(),qr()),t,n),c);break;default:_+="/"}break;case 123*y:s[d++]=xt(_)*v;case 125*y:case 59:case 0:switch(g){case 0:case 125:x=0;case 59+f:v==-1&&(_=se(_,/\f/g,"")),m>0&&xt(_)-l&&Ur(m>32?xa(_+";",u,n,l-1):xa(se(_," ","")+";",u,n,l-2),c);break;case 59:_+=";";default:if(Ur(S=ya(_,t,n,d,f,o,s,b,w=[],k=[],l),r),g===123)if(f===0)Zr(_,t,S,S,w,r,l,s,k);else switch(p===99&&Ne(_,3)===110?100:p){case 100:case 108:case 109:case 115:Zr(e,S,S,u&&Ur(ya(e,S,S,0,0,o,s,b,o,w=[],l),k),o,k,l,s,u?w:k);break;default:Zr(_,S,S,S,[""],k,0,s,k)}}d=f=m=0,y=v=1,b=_="",l=a;break;case 58:l=1+xt(_),m=h;default:if(y<1){if(g==123)--y;else if(g==125&&y++==0&&mf()==125)continue}switch(_+=$r(g),g*y){case 38:v=f>0?1:(_+="\f",-1);break;case 44:s[d++]=(xt(_)-1)*v,v=1;break;case 64:wt()===45&&(_+=Xr(Xe())),p=wt(),f=l=xt(b=_+=xf(qr())),g++;break;case 45:h===45&&xt(_)==2&&(y=0)}}return r}function ya(e,t,n,u,o,r,a,s,c,d,f){for(var l=o-1,p=o===0?r:[""],m=uo(p),h=0,y=0,x=0;h<u;++h)for(var v=0,g=qn(e,l+1,l=cf(y=a[h])),b=e;v<m;++v)(b=pa(y>0?p[v]+" "+g:se(g,/&\f/g,p[v])))&&(c[x++]=b);return Gr(e,t,n,o===0?to:s,c,d,f)}function vf(e,t,n){return Gr(e,t,n,fa,$r(pf()),qn(e,2,-2),0)}function xa(e,t,n,u){return Gr(e,t,n,no,qn(e,0,u),qn(e,u+1,-1),u)}function gn(e,t){for(var n="",u=uo(e),o=0;o<u;o++)n+=t(e[o],o,e,t)||"";return n}function Af(e,t,n,u){switch(e.type){case sf:if(e.children.length)break;case af:case no:return e.return=e.return||e.value;case fa:return"";case ha:return e.return=e.value+"{"+gn(e.children,u)+"}";case to:e.value=e.props.join(",")}return xt(n=gn(e.children,u))?e.return=e.value+"{"+n+"}":""}function kf(e){var t=uo(e);return function(n,u,o,r){for(var a="",s=0;s<t;s++)a+=e[s](n,u,o,r)||"";return a}}function Cf(e){return function(t){t.root||(t=t.return)&&e(t)}}function Ef(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var _f=function(t,n,u){for(var o=0,r=0;o=r,r=wt(),o===38&&r===12&&(n[u]=1),!Yn(r);)Xe();return Zn(t,$e)},Sf=function(t,n){var u=-1,o=44;do switch(Yn(o)){case 0:o===38&&wt()===12&&(n[u]=1),t[u]+=_f($e-1,n,u);break;case 2:t[u]+=Xr(o);break;case 4:if(o===44){t[++u]=wt()===58?"&\f":"",n[u]=t[u].length;break}default:t[u]+=$r(o)}while(o=Xe());return t},Ff=function(t,n){return ba(Sf(ga(t),n))},wa=new WeakMap,Df=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,u=t.parent,o=t.column===u.column&&t.line===u.line;u.type!=="rule";)if(u=u.parent,!u)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!wa.get(u))&&!o){wa.set(t,!0);for(var r=[],a=Ff(n,r),s=u.props,c=0,d=0;c<a.length;c++)for(var f=0;f<s.length;f++,d++)t.props[d]=r[c]?a[c].replace(/&\f/g,s[f]):s[f]+" "+a[c]}}},Tf=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function va(e,t){switch(df(e,t)){case 5103:return ae+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return ae+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return ae+e+Hr+e+Oe+e+e;case 6828:case 4268:return ae+e+Oe+e+e;case 6165:return ae+e+Oe+"flex-"+e+e;case 5187:return ae+e+se(e,/(\w+).+(:[^]+)/,ae+"box-$1$2"+Oe+"flex-$1$2")+e;case 5443:return ae+e+Oe+"flex-item-"+se(e,/flex-|-self/,"")+e;case 4675:return ae+e+Oe+"flex-line-pack"+se(e,/align-content|flex-|-self/,"")+e;case 5548:return ae+e+Oe+se(e,"shrink","negative")+e;case 5292:return ae+e+Oe+se(e,"basis","preferred-size")+e;case 6060:return ae+"box-"+se(e,"-grow","")+ae+e+Oe+se(e,"grow","positive")+e;case 4554:return ae+se(e,/([^-])(transform)/g,"$1"+ae+"$2")+e;case 6187:return se(se(se(e,/(zoom-|grab)/,ae+"$1"),/(image-set)/,ae+"$1"),e,"")+e;case 5495:case 3959:return se(e,/(image-set\([^]*)/,ae+"$1$`$1");case 4968:return se(se(e,/(.+:)(flex-)?(.*)/,ae+"box-pack:$3"+Oe+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+ae+e+e;case 4095:case 3583:case 4068:case 2532:return se(e,/(.+)-inline(.+)/,ae+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(xt(e)-1-t>6)switch(Ne(e,t+1)){case 109:if(Ne(e,t+4)!==45)break;case 102:return se(e,/(.+:)(.+)-([^]+)/,"$1"+ae+"$2-$3$1"+Hr+(Ne(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~ro(e,"stretch")?va(se(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Ne(e,t+1)!==115)break;case 6444:switch(Ne(e,xt(e)-3-(~ro(e,"!important")&&10))){case 107:return se(e,":",":"+ae)+e;case 101:return se(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ae+(Ne(e,14)===45?"inline-":"")+"box$3$1"+ae+"$2$3$1"+Oe+"$2box$3")+e}break;case 5936:switch(Ne(e,t+11)){case 114:return ae+e+Oe+se(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ae+e+Oe+se(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ae+e+Oe+se(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ae+e+Oe+e+e}return e}var Nf=function(t,n,u,o){if(t.length>-1&&!t.return)switch(t.type){case no:t.return=va(t.value,t.length);break;case ha:return gn([Xn(t,{value:se(t.value,"@","@"+ae)})],o);case to:if(t.length)return hf(t.props,function(r){switch(ff(r,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return gn([Xn(t,{props:[se(r,/:(read-\w+)/,":"+Hr+"$1")]})],o);case"::placeholder":return gn([Xn(t,{props:[se(r,/:(plac\w+)/,":"+ae+"input-$1")]}),Xn(t,{props:[se(r,/:(plac\w+)/,":"+Hr+"$1")]}),Xn(t,{props:[se(r,/:(plac\w+)/,Oe+"input-$1")]})],o)}return""})}},Lf=[Nf],Of=function(t){var n=t.key;if(n==="css"){var u=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(u,function(y){var x=y.getAttribute("data-emotion");x.indexOf(" ")!==-1&&(document.head.appendChild(y),y.setAttribute("data-s",""))})}var o=t.stylisPlugins||Lf,r={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(y){for(var x=y.getAttribute("data-emotion").split(" "),v=1;v<x.length;v++)r[x[v]]=!0;s.push(y)});var c,d=[Df,Tf];{var f,l=[Af,Cf(function(y){f.insert(y)})],p=kf(d.concat(o,l)),m=function(x){return gn(wf(x),p)};c=function(x,v,g,b){f=g,m(x?x+"{"+v.styles+"}":v.styles),b&&(h.inserted[v.name]=!0)}}var h={key:n,sheet:new of({key:n,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:r,registered:{},insert:c};return h.sheet.hydrate(s),h};function If(e){for(var t=0,n,u=0,o=e.length;o>=4;++u,o-=4)n=e.charCodeAt(u)&255|(e.charCodeAt(++u)&255)<<8|(e.charCodeAt(++u)&255)<<16|(e.charCodeAt(++u)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(u+2)&255)<<16;case 2:t^=(e.charCodeAt(u+1)&255)<<8;case 1:t^=e.charCodeAt(u)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Pf={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Rf=/[A-Z]|^ms/g,Vf=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Aa=function(t){return t.charCodeAt(1)===45},ka=function(t){return t!=null&&typeof t!="boolean"},io=Ef(function(e){return Aa(e)?e:e.replace(Rf,"-$&").toLowerCase()}),Ca=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Vf,function(u,o,r){return Pt={name:o,styles:r,next:Pt},o})}return Pf[t]!==1&&!Aa(t)&&typeof n=="number"&&n!==0?n+"px":n};function Yr(e,t,n){if(n==null)return"";var u=n;if(u.__emotion_styles!==void 0)return u;switch(typeof n){case"boolean":return"";case"object":{var o=n;if(o.anim===1)return Pt={name:o.name,styles:o.styles,next:Pt},o.name;var r=n;if(r.styles!==void 0){var a=r.next;if(a!==void 0)for(;a!==void 0;)Pt={name:a.name,styles:a.styles,next:Pt},a=a.next;var s=r.styles+";";return s}return Mf(e,t,n)}}var c=n;if(t==null)return c;var d=t[c];return d!==void 0?d:c}function Mf(e,t,n){var u="";if(Array.isArray(n))for(var o=0;o<n.length;o++)u+=Yr(e,t,n[o])+";";else for(var r in n){var a=n[r];if(typeof a!="object"){var s=a;t!=null&&t[s]!==void 0?u+=r+"{"+t[s]+"}":ka(s)&&(u+=io(r)+":"+Ca(r,s)+";")}else if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var c=0;c<a.length;c++)ka(a[c])&&(u+=io(r)+":"+Ca(r,a[c])+";");else{var d=Yr(e,t,a);switch(r){case"animation":case"animationName":{u+=io(r)+":"+d+";";break}default:u+=r+"{"+d+"}"}}}return u}var Ea=/label:\s*([^\s;{]+)\s*(;|$)/g,Pt;function ao(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var u=!0,o="";Pt=void 0;var r=e[0];if(r==null||r.raw===void 0)u=!1,o+=Yr(n,t,r);else{var a=r;o+=a[0]}for(var s=1;s<e.length;s++)if(o+=Yr(n,t,e[s]),u){var c=r;o+=c[s]}Ea.lastIndex=0;for(var d="",f;(f=Ea.exec(o))!==null;)d+="-"+f[1];var l=If(o)+d;return{name:l,styles:o,next:Pt}}function _a(e,t,n){var u="";return n.split(" ").forEach(function(o){e[o]!==void 0?t.push(e[o]+";"):o&&(u+=o+" ")}),u}var Bf=function(t,n,u){var o=t.key+"-"+n.name;t.registered[o]===void 0&&(t.registered[o]=n.styles)},zf=function(t,n,u){Bf(t,n);var o=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var r=n;do t.insert(n===r?"."+o:"",r,t.sheet,!0),r=r.next;while(r!==void 0)}};function Sa(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function Fa(e,t,n){var u=[],o=_a(e,u,n);return u.length<2?n:o+t(u)}var jf=function(t){var n=Of(t);n.sheet.speedy=function(s){this.isSpeedy=s},n.compat=!0;var u=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];var l=ao(d,n.registered,void 0);return zf(n,l),n.key+"-"+l.name},o=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];var l=ao(d,n.registered),p="animation-"+l.name;return Sa(n,{name:l.name,styles:"@keyframes "+p+"{"+l.styles+"}"}),p},r=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];var l=ao(d,n.registered);Sa(n,l)},a=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];return Fa(n.registered,u,Hf(d))};return{css:u,cx:a,injectGlobal:r,keyframes:o,hydrate:function(c){c.forEach(function(d){n.inserted[d]=!0})},flush:function(){n.registered={},n.inserted={},n.sheet.flush()},sheet:n.sheet,cache:n,getRegisteredStyles:_a.bind(null,n.registered),merge:Fa.bind(null,n.registered,u)}},Hf=function e(t){for(var n="",u=0;u<t.length;u++){var o=t[u];if(o!=null){var r=void 0;switch(typeof o){case"boolean":break;case"object":{if(Array.isArray(o))r=e(o);else{r="";for(var a in o)o[a]&&a&&(r&&(r+=" "),r+=a)}break}default:r=o}r&&(n&&(n+=" "),n+=r)}}return n},$f=jf({key:"css"}),so=$f.css,Uf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Wf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Da={exports:{}};/*!
19
+ `).trim()}const fn=i.defineComponent({name:"FXMarkdownMessage",props:sa,setup(e){const t=i.computed(()=>{var r;const n=(((r=e.content)==null?void 0:r.content)??"").replace(/\\n/g,`
20
+ `),u=lf(n);if(!u)return"";const o=cf.render(u);return sf.sanitize(o,{ADD_TAGS:["style"],ADD_ATTR:["style","align","valign","colspan","rowspan","scope","title"]})});return()=>{var u;const n=(u=e.content)==null?void 0:u.message;return i.createVNode("div",{class:"f-chat-message-markdown"},[n&&i.createVNode("div",{class:"f-chat-markdown-message"},[n]),i.createVNode("div",{class:"f-chat-markdown-content",innerHTML:t.value},null)])}}});fn.install=e=>{e.component(fn.name,fn)};const df=(e,t,n)=>{var o;if(e.type!==ke.Text)return null;const u=e;return(o=u.raw)!=null&&o.trim()?n.shouldShowMarkdown.value?i.createVNode(fn,{style:{border:"0px none rgb(51, 51, 51)",borderRadius:0,boxShadow:"none",padding:0},content:{type:"markdown",message:"",content:u.raw}},null):i.createVNode("div",{class:"f-chat-bubble-content-text",key:`bubble-text-${t}`},[u.raw]):null};function ff(e){return e?e.toLowerCase().replace(/[^a-z0-9\u4e00-\u9fff]+/g,"_").replace(/^_+|_+$/g,""):"surface"}function hf(e){const t=e.components.find(n=>n.id==="root");return t&&t.component==="Card",e.components}function pf(e){const t=ff(e.name),n="basic",u=[];u.push({version:"v0.9",createSurface:{surfaceId:t,catalogId:n,sendDataModel:!0}});const o=hf(e);return u.push({version:"v0.9",updateComponents:{surfaceId:t,components:o}}),e.data&&Object.keys(e.data).length>0&&u.push({version:"v0.9",updateDataModel:{surfaceId:t,path:"/",value:e.data}}),u}const mf=(e,t)=>{if(e.type!==ke.A2UIComplete)return null;const n=e,u=pf(n.a2uiData),o=new rn.MessageProcessor([ye.basicCatalog]);o.processMessages(u);const r=u[0].createSurface.surfaceId,a=o.model.getSurface(r);return i.createVNode(i.Fragment,null,[i.createVNode("div",{style:"width: 400px;"},[i.createVNode(ye.Surface,{surface:a},null)]),i.createVNode("details",null,[i.createVNode("summary",{style:{cursor:"pointer",fontSize:"12px",color:"#666"}},[i.createTextVNode("A2UI Debug Data")]),i.createVNode("pre",{style:{fontSize:"10px",maxHeight:"300px",overflow:"auto",background:"#f5f5f5",padding:"8px"}},[JSON.stringify(n.a2uiData,null,2)])])])};function gf(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function bf(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var yf=function(){function e(n){var u=this;this._insertTag=function(o){var r;u.tags.length===0?u.insertionPoint?r=u.insertionPoint.nextSibling:u.prepend?r=u.container.firstChild:r=u.before:r=u.tags[u.tags.length-1].nextSibling,u.container.insertBefore(o,r),u.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(u){u.forEach(this._insertTag)},t.insert=function(u){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(bf(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var r=gf(o);try{r.insertRule(u,r.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(u));this.ctr++},t.flush=function(){this.tags.forEach(function(u){var o;return(o=u.parentNode)==null?void 0:o.removeChild(u)}),this.tags=[],this.ctr=0},e}(),Oe="-ms-",Hr="-moz-",ae="-webkit-",ca="comm",Ju="rule",eo="decl",xf="@import",la="@keyframes",wf="@layer",vf=Math.abs,Ur=String.fromCharCode,Af=Object.assign;function kf(e,t){return Le(e,0)^45?(((t<<2^Le(e,0))<<2^Le(e,1))<<2^Le(e,2))<<2^Le(e,3):0}function da(e){return e.trim()}function Cf(e,t){return(e=t.exec(e))?e[0]:e}function se(e,t,n){return e.replace(t,n)}function to(e,t){return e.indexOf(t)}function Le(e,t){return e.charCodeAt(t)|0}function Gn(e,t,n){return e.slice(t,n)}function wt(e){return e.length}function no(e){return e.length}function $r(e,t){return t.push(e),e}function Ef(e,t){return e.map(t).join("")}var Wr=1,hn=1,fa=0,$e=0,xe=0,pn="";function Gr(e,t,n,u,o,r,a){return{value:e,root:t,parent:n,type:u,props:o,children:r,line:Wr,column:hn,length:a,return:""}}function qn(e,t){return Af(Gr("",null,null,"",null,null,0),e,{length:-e.length},t)}function _f(){return xe}function Sf(){return xe=$e>0?Le(pn,--$e):0,hn--,xe===10&&(hn=1,Wr--),xe}function Ze(){return xe=$e<fa?Le(pn,$e++):0,hn++,xe===10&&(hn=1,Wr++),xe}function vt(){return Le(pn,$e)}function qr(){return $e}function Xn(e,t){return Gn(pn,e,t)}function Zn(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ha(e){return Wr=hn=1,fa=wt(pn=e),$e=0,[]}function pa(e){return pn="",e}function Xr(e){return da(Xn($e-1,ro(e===91?e+2:e===40?e+1:e)))}function Ff(e){for(;(xe=vt())&&xe<33;)Ze();return Zn(e)>2||Zn(xe)>3?"":" "}function Df(e,t){for(;--t&&Ze()&&!(xe<48||xe>102||xe>57&&xe<65||xe>70&&xe<97););return Xn(e,qr()+(t<6&&vt()==32&&Ze()==32))}function ro(e){for(;Ze();)switch(xe){case e:return $e;case 34:case 39:e!==34&&e!==39&&ro(xe);break;case 40:e===41&&ro(e);break;case 92:Ze();break}return $e}function Tf(e,t){for(;Ze()&&e+xe!==57;)if(e+xe===84&&vt()===47)break;return"/*"+Xn(t,$e-1)+"*"+Ur(e===47?e:Ze())}function Nf(e){for(;!Zn(vt());)Ze();return Xn(e,$e)}function Lf(e){return pa(Zr("",null,null,null,[""],e=ha(e),0,[0],e))}function Zr(e,t,n,u,o,r,a,s,c){for(var d=0,f=0,l=a,p=0,m=0,h=0,x=1,y=1,v=1,g=0,b="",w=o,k=r,S=u,_=b;y;)switch(h=g,g=Ze()){case 40:if(h!=108&&Le(_,l-1)==58){to(_+=se(Xr(g),"&","&\f"),"&\f")!=-1&&(v=-1);break}case 34:case 39:case 91:_+=Xr(g);break;case 9:case 10:case 13:case 32:_+=Ff(h);break;case 92:_+=Df(qr()-1,7);continue;case 47:switch(vt()){case 42:case 47:$r(If(Tf(Ze(),qr()),t,n),c);break;default:_+="/"}break;case 123*x:s[d++]=wt(_)*v;case 125*x:case 59:case 0:switch(g){case 0:case 125:y=0;case 59+f:v==-1&&(_=se(_,/\f/g,"")),m>0&&wt(_)-l&&$r(m>32?ga(_+";",u,n,l-1):ga(se(_," ","")+";",u,n,l-2),c);break;case 59:_+=";";default:if($r(S=ma(_,t,n,d,f,o,s,b,w=[],k=[],l),r),g===123)if(f===0)Zr(_,t,S,S,w,r,l,s,k);else switch(p===99&&Le(_,3)===110?100:p){case 100:case 108:case 109:case 115:Zr(e,S,S,u&&$r(ma(e,S,S,0,0,o,s,b,o,w=[],l),k),o,k,l,s,u?w:k);break;default:Zr(_,S,S,S,[""],k,0,s,k)}}d=f=m=0,x=v=1,b=_="",l=a;break;case 58:l=1+wt(_),m=h;default:if(x<1){if(g==123)--x;else if(g==125&&x++==0&&Sf()==125)continue}switch(_+=Ur(g),g*x){case 38:v=f>0?1:(_+="\f",-1);break;case 44:s[d++]=(wt(_)-1)*v,v=1;break;case 64:vt()===45&&(_+=Xr(Ze())),p=vt(),f=l=wt(b=_+=Nf(qr())),g++;break;case 45:h===45&&wt(_)==2&&(x=0)}}return r}function ma(e,t,n,u,o,r,a,s,c,d,f){for(var l=o-1,p=o===0?r:[""],m=no(p),h=0,x=0,y=0;h<u;++h)for(var v=0,g=Gn(e,l+1,l=vf(x=a[h])),b=e;v<m;++v)(b=da(x>0?p[v]+" "+g:se(g,/&\f/g,p[v])))&&(c[y++]=b);return Gr(e,t,n,o===0?Ju:s,c,d,f)}function If(e,t,n){return Gr(e,t,n,ca,Ur(_f()),Gn(e,2,-2),0)}function ga(e,t,n,u){return Gr(e,t,n,eo,Gn(e,0,u),Gn(e,u+1,-1),u)}function mn(e,t){for(var n="",u=no(e),o=0;o<u;o++)n+=t(e[o],o,e,t)||"";return n}function Of(e,t,n,u){switch(e.type){case wf:if(e.children.length)break;case xf:case eo:return e.return=e.return||e.value;case ca:return"";case la:return e.return=e.value+"{"+mn(e.children,u)+"}";case Ju:e.value=e.props.join(",")}return wt(n=mn(e.children,u))?e.return=e.value+"{"+n+"}":""}function Pf(e){var t=no(e);return function(n,u,o,r){for(var a="",s=0;s<t;s++)a+=e[s](n,u,o,r)||"";return a}}function Rf(e){return function(t){t.root||(t=t.return)&&e(t)}}function Mf(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var Vf=function(t,n,u){for(var o=0,r=0;o=r,r=vt(),o===38&&r===12&&(n[u]=1),!Zn(r);)Ze();return Xn(t,$e)},Bf=function(t,n){var u=-1,o=44;do switch(Zn(o)){case 0:o===38&&vt()===12&&(n[u]=1),t[u]+=Vf($e-1,n,u);break;case 2:t[u]+=Xr(o);break;case 4:if(o===44){t[++u]=vt()===58?"&\f":"",n[u]=t[u].length;break}default:t[u]+=Ur(o)}while(o=Ze());return t},zf=function(t,n){return pa(Bf(ha(t),n))},ba=new WeakMap,jf=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,u=t.parent,o=t.column===u.column&&t.line===u.line;u.type!=="rule";)if(u=u.parent,!u)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!ba.get(u))&&!o){ba.set(t,!0);for(var r=[],a=zf(n,r),s=u.props,c=0,d=0;c<a.length;c++)for(var f=0;f<s.length;f++,d++)t.props[d]=r[c]?a[c].replace(/&\f/g,s[f]):s[f]+" "+a[c]}}},Hf=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function ya(e,t){switch(kf(e,t)){case 5103:return ae+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return ae+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return ae+e+Hr+e+Oe+e+e;case 6828:case 4268:return ae+e+Oe+e+e;case 6165:return ae+e+Oe+"flex-"+e+e;case 5187:return ae+e+se(e,/(\w+).+(:[^]+)/,ae+"box-$1$2"+Oe+"flex-$1$2")+e;case 5443:return ae+e+Oe+"flex-item-"+se(e,/flex-|-self/,"")+e;case 4675:return ae+e+Oe+"flex-line-pack"+se(e,/align-content|flex-|-self/,"")+e;case 5548:return ae+e+Oe+se(e,"shrink","negative")+e;case 5292:return ae+e+Oe+se(e,"basis","preferred-size")+e;case 6060:return ae+"box-"+se(e,"-grow","")+ae+e+Oe+se(e,"grow","positive")+e;case 4554:return ae+se(e,/([^-])(transform)/g,"$1"+ae+"$2")+e;case 6187:return se(se(se(e,/(zoom-|grab)/,ae+"$1"),/(image-set)/,ae+"$1"),e,"")+e;case 5495:case 3959:return se(e,/(image-set\([^]*)/,ae+"$1$`$1");case 4968:return se(se(e,/(.+:)(flex-)?(.*)/,ae+"box-pack:$3"+Oe+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+ae+e+e;case 4095:case 3583:case 4068:case 2532:return se(e,/(.+)-inline(.+)/,ae+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(wt(e)-1-t>6)switch(Le(e,t+1)){case 109:if(Le(e,t+4)!==45)break;case 102:return se(e,/(.+:)(.+)-([^]+)/,"$1"+ae+"$2-$3$1"+Hr+(Le(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~to(e,"stretch")?ya(se(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Le(e,t+1)!==115)break;case 6444:switch(Le(e,wt(e)-3-(~to(e,"!important")&&10))){case 107:return se(e,":",":"+ae)+e;case 101:return se(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ae+(Le(e,14)===45?"inline-":"")+"box$3$1"+ae+"$2$3$1"+Oe+"$2box$3")+e}break;case 5936:switch(Le(e,t+11)){case 114:return ae+e+Oe+se(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ae+e+Oe+se(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ae+e+Oe+se(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ae+e+Oe+e+e}return e}var Uf=function(t,n,u,o){if(t.length>-1&&!t.return)switch(t.type){case eo:t.return=ya(t.value,t.length);break;case la:return mn([qn(t,{value:se(t.value,"@","@"+ae)})],o);case Ju:if(t.length)return Ef(t.props,function(r){switch(Cf(r,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return mn([qn(t,{props:[se(r,/:(read-\w+)/,":"+Hr+"$1")]})],o);case"::placeholder":return mn([qn(t,{props:[se(r,/:(plac\w+)/,":"+ae+"input-$1")]}),qn(t,{props:[se(r,/:(plac\w+)/,":"+Hr+"$1")]}),qn(t,{props:[se(r,/:(plac\w+)/,Oe+"input-$1")]})],o)}return""})}},$f=[Uf],Wf=function(t){var n=t.key;if(n==="css"){var u=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(u,function(x){var y=x.getAttribute("data-emotion");y.indexOf(" ")!==-1&&(document.head.appendChild(x),x.setAttribute("data-s",""))})}var o=t.stylisPlugins||$f,r={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(x){for(var y=x.getAttribute("data-emotion").split(" "),v=1;v<y.length;v++)r[y[v]]=!0;s.push(x)});var c,d=[jf,Hf];{var f,l=[Of,Rf(function(x){f.insert(x)})],p=Pf(d.concat(o,l)),m=function(y){return mn(Lf(y),p)};c=function(y,v,g,b){f=g,m(y?y+"{"+v.styles+"}":v.styles),b&&(h.inserted[v.name]=!0)}}var h={key:n,sheet:new yf({key:n,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:r,registered:{},insert:c};return h.sheet.hydrate(s),h};function Gf(e){for(var t=0,n,u=0,o=e.length;o>=4;++u,o-=4)n=e.charCodeAt(u)&255|(e.charCodeAt(++u)&255)<<8|(e.charCodeAt(++u)&255)<<16|(e.charCodeAt(++u)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(u+2)&255)<<16;case 2:t^=(e.charCodeAt(u+1)&255)<<8;case 1:t^=e.charCodeAt(u)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var qf={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Xf=/[A-Z]|^ms/g,Zf=/_EMO_([^_]+?)_([^]*?)_EMO_/g,xa=function(t){return t.charCodeAt(1)===45},wa=function(t){return t!=null&&typeof t!="boolean"},uo=Mf(function(e){return xa(e)?e:e.replace(Xf,"-$&").toLowerCase()}),va=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Zf,function(u,o,r){return Rt={name:o,styles:r,next:Rt},o})}return qf[t]!==1&&!xa(t)&&typeof n=="number"&&n!==0?n+"px":n};function Yr(e,t,n){if(n==null)return"";var u=n;if(u.__emotion_styles!==void 0)return u;switch(typeof n){case"boolean":return"";case"object":{var o=n;if(o.anim===1)return Rt={name:o.name,styles:o.styles,next:Rt},o.name;var r=n;if(r.styles!==void 0){var a=r.next;if(a!==void 0)for(;a!==void 0;)Rt={name:a.name,styles:a.styles,next:Rt},a=a.next;var s=r.styles+";";return s}return Yf(e,t,n)}}var c=n;if(t==null)return c;var d=t[c];return d!==void 0?d:c}function Yf(e,t,n){var u="";if(Array.isArray(n))for(var o=0;o<n.length;o++)u+=Yr(e,t,n[o])+";";else for(var r in n){var a=n[r];if(typeof a!="object"){var s=a;t!=null&&t[s]!==void 0?u+=r+"{"+t[s]+"}":wa(s)&&(u+=uo(r)+":"+va(r,s)+";")}else if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var c=0;c<a.length;c++)wa(a[c])&&(u+=uo(r)+":"+va(r,a[c])+";");else{var d=Yr(e,t,a);switch(r){case"animation":case"animationName":{u+=uo(r)+":"+d+";";break}default:u+=r+"{"+d+"}"}}}return u}var Aa=/label:\s*([^\s;{]+)\s*(;|$)/g,Rt;function oo(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var u=!0,o="";Rt=void 0;var r=e[0];if(r==null||r.raw===void 0)u=!1,o+=Yr(n,t,r);else{var a=r;o+=a[0]}for(var s=1;s<e.length;s++)if(o+=Yr(n,t,e[s]),u){var c=r;o+=c[s]}Aa.lastIndex=0;for(var d="",f;(f=Aa.exec(o))!==null;)d+="-"+f[1];var l=Gf(o)+d;return{name:l,styles:o,next:Rt}}function ka(e,t,n){var u="";return n.split(" ").forEach(function(o){e[o]!==void 0?t.push(e[o]+";"):o&&(u+=o+" ")}),u}var Kf=function(t,n,u){var o=t.key+"-"+n.name;t.registered[o]===void 0&&(t.registered[o]=n.styles)},Qf=function(t,n,u){Kf(t,n);var o=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var r=n;do t.insert(n===r?"."+o:"",r,t.sheet,!0),r=r.next;while(r!==void 0)}};function Ca(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function Ea(e,t,n){var u=[],o=ka(e,u,n);return u.length<2?n:o+t(u)}var Jf=function(t){var n=Wf(t);n.sheet.speedy=function(s){this.isSpeedy=s},n.compat=!0;var u=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];var l=oo(d,n.registered,void 0);return Qf(n,l),n.key+"-"+l.name},o=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];var l=oo(d,n.registered),p="animation-"+l.name;return Ca(n,{name:l.name,styles:"@keyframes "+p+"{"+l.styles+"}"}),p},r=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];var l=oo(d,n.registered);Ca(n,l)},a=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];return Ea(n.registered,u,eh(d))};return{css:u,cx:a,injectGlobal:r,keyframes:o,hydrate:function(c){c.forEach(function(d){n.inserted[d]=!0})},flush:function(){n.registered={},n.inserted={},n.sheet.flush()},sheet:n.sheet,cache:n,getRegisteredStyles:ka.bind(null,n.registered),merge:Ea.bind(null,n.registered,u)}},eh=function e(t){for(var n="",u=0;u<t.length;u++){var o=t[u];if(o!=null){var r=void 0;switch(typeof o){case"boolean":break;case"object":{if(Array.isArray(o))r=e(o);else{r="";for(var a in o)o[a]&&a&&(r&&(r+=" "),r+=a)}break}default:r=o}r&&(n&&(n+=" "),n+=r)}}return n},th=Jf({key:"css"}),io=th.css,nh=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function rh(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var _a={exports:{}};/*!
21
21
  Copyright (c) 2018 Jed Watson.
22
22
  Licensed under the MIT License (MIT), see
23
23
  http://jedwatson.github.io/classnames
24
- */(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(r=o(r,u(s)))}return r}function u(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var s in r)t.call(r,s)&&r[s]&&(a=o(a,s));return a}function o(r,a){return a?r?r+" "+a:r+a:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(Da);var Gf=Da.exports;const co=Wf(Gf),Ta={className:{type:String,default:""},viewStatus:{type:String,default:"full"},widgetAPIURL:{type:String,default:""},widgetOptions:{type:Object,default:()=>({mode:"embedded",implOptions:{}})},widgetData:{type:Object,default:()=>({})}};class qf{constructor(t){fe(this,"root");if(!t)throw new Error("parentElement is required");this.root=document.createElement("div"),this.root.className="fx-card-container-stage__root",t.appendChild(this.root)}dispose(){this.root.remove()}getElement(){return this.root}}function Xf(){function e(t,n){if(t===n)return!0;if(typeof t!="object"||t===null||typeof n!="object"||n===null||Array.isArray(t)!==Array.isArray(n))return!1;const u=Object.keys(t),o=Object.keys(n);if(u.length!==o.length)return!1;for(const r of u)if(!o.includes(r)||!e(t[r],n[r]))return!1;return!0}return{deepEqual:e}}var lo={exports:{}};(function(e,t){(function(n,u){u(t)})(Uf,function(n){var u=Object.defineProperty,o=Object.defineProperties,r=Object.getOwnPropertyDescriptors,a=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,d=(P,R,N)=>R in P?u(P,R,{enumerable:!0,configurable:!0,writable:!0,value:N}):P[R]=N,f=(P,R)=>{for(var N in R||(R={}))s.call(R,N)&&d(P,N,R[N]);if(a)for(var N of a(R))c.call(R,N)&&d(P,N,R[N]);return P},l=(P,R)=>o(P,r(R)),p=(P,R,N)=>new Promise((L,U)=>{var K=ue=>{try{Y(N.next(ue))}catch(ce){U(ce)}},Z=ue=>{try{Y(N.throw(ue))}catch(ce){U(ce)}},Y=ue=>ue.done?L(ue.value):Promise.resolve(ue.value).then(K,Z);Y((N=N.apply(P,R)).next())}),m=(P=>(P[P.NONE=0]="NONE",P[P.LOADING=1]="LOADING",P[P.LOADED=2]="LOADED",P[P.ERROR=3]="ERROR",P))(m||{});class h{constructor(R){this.items={},this.factory=R}getOrCreateItemByURL(R){let N=this.items[R];return N||(N=this.items[R]=this.factory(R)),N}tryGetItemByURL(R){var N;return(N=this.items[R])!=null?N:null}removeItemByURL(R){const N=this.items[R];return N&&(this.items[R]=null,N)}}const y="__RUNTIME_IMPORT__";function x(P,R){var N,L;const U=globalThis,K=(N=U[y])!=null?N:U[y]={};return(L=K[P])!=null?L:K[P]=R()}const v=x("cssCache",()=>new h(P=>({url:P,status:m.NONE,el:null,error:null,reject:null})));function g(P,R,N){const L={handleLoad(){P.removeEventListener("load",L.handleLoad),P.removeEventListener("error",L.handleError),R()},handleError(U){P.removeEventListener("load",L.handleLoad),P.removeEventListener("error",L.handleError),N(U)}};P.addEventListener("load",L.handleLoad),P.addEventListener("error",L.handleError)}function b(P){const R=v.getOrCreateItemByURL(P),{status:N,error:L}=R;return N===m.LOADED?Promise.resolve():N===m.ERROR?Promise.reject(L):N===m.LOADING?new Promise((U,K)=>{const{el:Z}=R;g(Z,()=>U(),Y=>K(Y.error))}):(R.status=m.LOADING,new Promise((U,K)=>{const Z=document.createElement("link");Z.rel="stylesheet",Z.href=P,g(Z,()=>{R.status=m.LOADED,U()},Y=>{const ue=Y.error||new Error(`Load css failed. href=${P}`);R.status=m.ERROR,R.error=ue,K(ue)}),R.el=Z,Z.setAttribute("data-runtime-import-type","css"),document.head.appendChild(Z)}))}function w(P){return Promise.all(P.map(R=>b(R))).then(()=>Promise.resolve()).catch(R=>Promise.reject(R))}const k=x("jsCache",()=>new h(P=>({url:P,status:m.NONE,el:null,error:null,reject:null,exportThing:void 0}))),S=globalThis,{define:_}=S,{keys:E}=Object;let W=!1;typeof _<"u"&&!_.runtime_import&&(console.warn("runtime-import should NOT coexist with requiesjs or seajs or any other AMD/CMD loader."),W=!0);const B=x("pendingItemMap",()=>({})),I=function(...P){const R=P.pop(),{currentScript:N}=document;if(!N)throw new Error("currentScript is null.");const{src:L}=N,U=B[L];if(!U)throw new Error(`Can NOT find item, src=${L}`);B[L]=null;try{let K=P[0]||[],Z=null;typeof K=="string"&&(Z=K,K=P[1]||[]);const Y=U.exportThing=(()=>{let ue=!1;const ce={};let De=R(...K.map(Te=>Te==="exports"?(ue=!0,ce):S[Te]));return!De&&ue&&(De=ce),De})();Z&&(S[Z]=Y),Y&&E(Y).length===1&&Y.default&&(U.exportThing=Y.default,U.exportThing.default=Y.default)}catch(K){U.status=m.ERROR,K instanceof Error&&(U.error=K),U.reject(K)}},M=()=>{const{currentScript:P}=document;if(P){const{src:R}=P;if(B[R])return!0}return!1};["amd","cmd"].forEach(P=>{Object.defineProperty(I,P,{get:M})}),I.runtime_import=!0;function D(P,R){if(W)throw new Error("runtime-import UMD mode uses window.define, you should NOT have your own window.define.");S.define||(S.define=I),B[P]=R}function j(P){const R=/legao-comp\/(.*)\/[\d.]+\/web.js$/.exec(P),N=window;if(R&&R.length>0){const L=R[1];N.g_config=N.g_config||{},N.g_config.appKey=L}}function H(P,R,N){P.status=m.LOADING,j(R);const{umd:L,crossOrigin:U}=N;return new Promise((K,Z)=>{const Y=document.createElement("script");if(Y.src=R,Y.async=!1,Y.crossOrigin=U,L){Y.setAttribute("data-runtime-import-type","javascript-umd"),P.reject=Z;const ue=Y.src;D(ue,P)}else Y.setAttribute("data-runtime-import-type","javascript");g(Y,()=>{P.status=m.LOADED,P.el=null,K(P.exportThing)},ue=>{const ce=ue.error||new Error(`Load javascript failed. src=${R}`);P.status=m.ERROR,P.error=ce,P.el=null,Z(ce)}),P.el=Y,document.body.appendChild(Y)})}function F(P,R){const N=k.getOrCreateItemByURL(P),{status:L,exportThing:U,error:K}=N;if(L===m.LOADED)return Promise.resolve(U);if(L===m.ERROR)return Promise.reject(K);if(L===m.LOADING){const{el:Z}=N;return new Promise((Y,ue)=>{g(Z,()=>Y(N.exportThing),ce=>ue(ce.error))})}return H(N,P,R)}function V(P,R){let N=Promise.resolve();const L=P.length-1,{umd:U}=R;return P.forEach((K,Z)=>{const Y=U&&Z===L;N=N.then(()=>F(K,l(f({},R),{umd:Y})))}),N}function O(P){return p(this,null,function*(){const{scripts:R,styles:N}=P;if(N){const{urls:Y}=N;yield w(Y)}const{dependencies:L=[],entry:U,umd:K=!0,crossOrigin:Z="anonymous"}=R;if((U?L.concat([U]):L).length)return yield V(L.concat([U]),{umd:K,crossOrigin:Z})})}function $(P,R){return p(this,null,function*(){const N=R??{};return yield O({scripts:{dependencies:[],entry:P,umd:N.umd,crossOrigin:N.crossOrigin}})})}function re(P){return p(this,null,function*(){return yield O({scripts:{dependencies:[],entry:""},styles:{urls:[P]}})})}const te=O;n.importComponent=O,n.importModule=te,n.importScript=$,n.importStyle=re,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})})})(lo,lo.exports);var Zf=lo.exports;function Yf(){async function e(t){return await Zf.importScript(t)}return{loadWidgetAPI:e}}const bn=i.defineComponent({name:"FXWidgetContainer",props:Ta,setup(e,t){const{loadWidgetAPI:n}=Yf(),{deepEqual:u}=Xf(),o=i.ref(null),r=i.ref(null),a=i.ref(null),s=i.ref(null),c=i.ref(null),d=i.computed(()=>{const g=so`width:100%!important`;return co("caf-assistant-widget-container__root",g,e.className)}),f=so`
24
+ */(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(r=o(r,u(s)))}return r}function u(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var s in r)t.call(r,s)&&r[s]&&(a=o(a,s));return a}function o(r,a){return a?r?r+" "+a:r+a:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(_a);var uh=_a.exports;const ao=rh(uh),Sa={className:{type:String,default:""},viewStatus:{type:String,default:"full"},widgetAPIURL:{type:String,default:""},widgetOptions:{type:Object,default:()=>({mode:"embedded",implOptions:{}})},widgetData:{type:Object,default:()=>({})}};class oh{constructor(t){fe(this,"root");if(!t)throw new Error("parentElement is required");this.root=document.createElement("div"),this.root.className="fx-card-container-stage__root",t.appendChild(this.root)}dispose(){this.root.remove()}getElement(){return this.root}}function ih(){function e(t,n){if(t===n)return!0;if(typeof t!="object"||t===null||typeof n!="object"||n===null||Array.isArray(t)!==Array.isArray(n))return!1;const u=Object.keys(t),o=Object.keys(n);if(u.length!==o.length)return!1;for(const r of u)if(!o.includes(r)||!e(t[r],n[r]))return!1;return!0}return{deepEqual:e}}var so={exports:{}};(function(e,t){(function(n,u){u(t)})(nh,function(n){var u=Object.defineProperty,o=Object.defineProperties,r=Object.getOwnPropertyDescriptors,a=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,d=(P,M,T)=>M in P?u(P,M,{enumerable:!0,configurable:!0,writable:!0,value:T}):P[M]=T,f=(P,M)=>{for(var T in M||(M={}))s.call(M,T)&&d(P,T,M[T]);if(a)for(var T of a(M))c.call(M,T)&&d(P,T,M[T]);return P},l=(P,M)=>o(P,r(M)),p=(P,M,T)=>new Promise((L,$)=>{var K=ue=>{try{Y(T.next(ue))}catch(ce){$(ce)}},Z=ue=>{try{Y(T.throw(ue))}catch(ce){$(ce)}},Y=ue=>ue.done?L(ue.value):Promise.resolve(ue.value).then(K,Z);Y((T=T.apply(P,M)).next())}),m=(P=>(P[P.NONE=0]="NONE",P[P.LOADING=1]="LOADING",P[P.LOADED=2]="LOADED",P[P.ERROR=3]="ERROR",P))(m||{});class h{constructor(M){this.items={},this.factory=M}getOrCreateItemByURL(M){let T=this.items[M];return T||(T=this.items[M]=this.factory(M)),T}tryGetItemByURL(M){var T;return(T=this.items[M])!=null?T:null}removeItemByURL(M){const T=this.items[M];return T&&(this.items[M]=null,T)}}const x="__RUNTIME_IMPORT__";function y(P,M){var T,L;const $=globalThis,K=(T=$[x])!=null?T:$[x]={};return(L=K[P])!=null?L:K[P]=M()}const v=y("cssCache",()=>new h(P=>({url:P,status:m.NONE,el:null,error:null,reject:null})));function g(P,M,T){const L={handleLoad(){P.removeEventListener("load",L.handleLoad),P.removeEventListener("error",L.handleError),M()},handleError($){P.removeEventListener("load",L.handleLoad),P.removeEventListener("error",L.handleError),T($)}};P.addEventListener("load",L.handleLoad),P.addEventListener("error",L.handleError)}function b(P){const M=v.getOrCreateItemByURL(P),{status:T,error:L}=M;return T===m.LOADED?Promise.resolve():T===m.ERROR?Promise.reject(L):T===m.LOADING?new Promise(($,K)=>{const{el:Z}=M;g(Z,()=>$(),Y=>K(Y.error))}):(M.status=m.LOADING,new Promise(($,K)=>{const Z=document.createElement("link");Z.rel="stylesheet",Z.href=P,g(Z,()=>{M.status=m.LOADED,$()},Y=>{const ue=Y.error||new Error(`Load css failed. href=${P}`);M.status=m.ERROR,M.error=ue,K(ue)}),M.el=Z,Z.setAttribute("data-runtime-import-type","css"),document.head.appendChild(Z)}))}function w(P){return Promise.all(P.map(M=>b(M))).then(()=>Promise.resolve()).catch(M=>Promise.reject(M))}const k=y("jsCache",()=>new h(P=>({url:P,status:m.NONE,el:null,error:null,reject:null,exportThing:void 0}))),S=globalThis,{define:_}=S,{keys:E}=Object;let W=!1;typeof _<"u"&&!_.runtime_import&&(console.warn("runtime-import should NOT coexist with requiesjs or seajs or any other AMD/CMD loader."),W=!0);const V=y("pendingItemMap",()=>({})),O=function(...P){const M=P.pop(),{currentScript:T}=document;if(!T)throw new Error("currentScript is null.");const{src:L}=T,$=V[L];if(!$)throw new Error(`Can NOT find item, src=${L}`);V[L]=null;try{let K=P[0]||[],Z=null;typeof K=="string"&&(Z=K,K=P[1]||[]);const Y=$.exportThing=(()=>{let ue=!1;const ce={};let Te=M(...K.map(Ne=>Ne==="exports"?(ue=!0,ce):S[Ne]));return!Te&&ue&&(Te=ce),Te})();Z&&(S[Z]=Y),Y&&E(Y).length===1&&Y.default&&($.exportThing=Y.default,$.exportThing.default=Y.default)}catch(K){$.status=m.ERROR,K instanceof Error&&($.error=K),$.reject(K)}},B=()=>{const{currentScript:P}=document;if(P){const{src:M}=P;if(V[M])return!0}return!1};["amd","cmd"].forEach(P=>{Object.defineProperty(O,P,{get:B})}),O.runtime_import=!0;function D(P,M){if(W)throw new Error("runtime-import UMD mode uses window.define, you should NOT have your own window.define.");S.define||(S.define=O),V[P]=M}function j(P){const M=/legao-comp\/(.*)\/[\d.]+\/web.js$/.exec(P),T=window;if(M&&M.length>0){const L=M[1];T.g_config=T.g_config||{},T.g_config.appKey=L}}function H(P,M,T){P.status=m.LOADING,j(M);const{umd:L,crossOrigin:$}=T;return new Promise((K,Z)=>{const Y=document.createElement("script");if(Y.src=M,Y.async=!1,Y.crossOrigin=$,L){Y.setAttribute("data-runtime-import-type","javascript-umd"),P.reject=Z;const ue=Y.src;D(ue,P)}else Y.setAttribute("data-runtime-import-type","javascript");g(Y,()=>{P.status=m.LOADED,P.el=null,K(P.exportThing)},ue=>{const ce=ue.error||new Error(`Load javascript failed. src=${M}`);P.status=m.ERROR,P.error=ce,P.el=null,Z(ce)}),P.el=Y,document.body.appendChild(Y)})}function F(P,M){const T=k.getOrCreateItemByURL(P),{status:L,exportThing:$,error:K}=T;if(L===m.LOADED)return Promise.resolve($);if(L===m.ERROR)return Promise.reject(K);if(L===m.LOADING){const{el:Z}=T;return new Promise((Y,ue)=>{g(Z,()=>Y(T.exportThing),ce=>ue(ce.error))})}return H(T,P,M)}function R(P,M){let T=Promise.resolve();const L=P.length-1,{umd:$}=M;return P.forEach((K,Z)=>{const Y=$&&Z===L;T=T.then(()=>F(K,l(f({},M),{umd:Y})))}),T}function I(P){return p(this,null,function*(){const{scripts:M,styles:T}=P;if(T){const{urls:Y}=T;yield w(Y)}const{dependencies:L=[],entry:$,umd:K=!0,crossOrigin:Z="anonymous"}=M;if(($?L.concat([$]):L).length)return yield R(L.concat([$]),{umd:K,crossOrigin:Z})})}function U(P,M){return p(this,null,function*(){const T=M??{};return yield I({scripts:{dependencies:[],entry:P,umd:T.umd,crossOrigin:T.crossOrigin}})})}function re(P){return p(this,null,function*(){return yield I({scripts:{dependencies:[],entry:""},styles:{urls:[P]}})})}const te=I;n.importComponent=I,n.importModule=te,n.importScript=U,n.importStyle=re,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})})})(so,so.exports);var ah=so.exports;function sh(){async function e(t){return await ah.importScript(t)}return{loadWidgetAPI:e}}const gn=i.defineComponent({name:"FXWidgetContainer",props:Sa,setup(e,t){const{loadWidgetAPI:n}=sh(),{deepEqual:u}=ih(),o=i.ref(null),r=i.ref(null),a=i.ref(null),s=i.ref(null),c=i.ref(null),d=i.computed(()=>{const g=io`width:100%!important`;return ao("caf-assistant-widget-container__root",g,e.className)}),f=io`
25
25
  overflow: hidden;
26
- `,l=co("caf-assistant-widget-container__inner",f),p=i.computed(()=>{const g=so`
26
+ `,l=ao("caf-assistant-widget-container__inner",f),p=i.computed(()=>{const g=io`
27
27
  display: ${c.value?"block":"none"};
28
- `;return co("caf-assistant-widget-container__error",g)}),m=()=>{const g=a.value;g&&(s.value=new qf(g))},h=()=>{const g=s.value;g&&(g.dispose(),s.value=null)},y=()=>{const g=r.value,b=o.value;g&&(g.unmount(),g.dispose()),b&&b.cleanup(),r.value=null,o.value=null},x=async()=>{const g=await n(e.widgetAPIURL);if(!g)throw new Error("Failed to load widget API");await g.initialize();const b=g.createWidget();o.value=g,r.value=b},v=g=>{console.error(g),c.value=g};return i.watch(()=>e.widgetAPIURL,async()=>{if(a.value)try{y(),await x();const g=a.value,b=r.value;b==null||b.updateOptions(e.widgetOptions),b==null||b.updateData(e.widgetData),g&&b&&await b.mount(g)}catch(g){v(g)}}),i.watch(()=>e.widgetOptions,(g,b)=>{try{const w=r.value;w&&(!b||!u(b,g))&&w.updateOptions(g)}catch(w){v(w)}}),i.watch(()=>e.widgetData,(g,b)=>{try{const w=r.value;w&&(!b||!u(b,g))&&w.updateData(g)}catch(w){v(w)}}),i.onMounted(async()=>{try{const g=a.value;if(g){m();const b=s.value;if(b){await x();const w=r.value;w&&(w.updateOptions(e.widgetOptions),w.updateData(e.widgetData),w.mount(b.getElement()),i.nextTick(()=>{g.parentElement&&(g.style.width="100%")}))}}}catch(g){v(g)}}),i.onBeforeUnmount(async()=>{try{y(),h()}catch(g){console.error(g)}}),()=>i.createVNode("div",{class:d.value},[i.createVNode("div",{ref:a,class:l},null),i.createVNode("div",{class:p.value},null)])}}),Kf=/^```\s*dynamic-component[\s\S]*?```$/,Qf=/^```\s*dynamic-component/;function Jf(e){return e.replace(/```\s*\n*\s*dynamic-component/g,"``` dynamic-component")}function Na(e){return e?Kf.test(e)||Qf.test(e):!1}function eh(e){const t=e.replace(/```\s*dynamic-component\s*\n?/,"").replace(/\n?\s*```/,"").trim();if(!t)return null;let n;try{n=JSON.parse(t)}catch{return null}if(!n||typeof n!="object"||Array.isArray(n))return null;const u=n;return typeof u.instanceId!="string"?null:{instanceId:u.instanceId,name:typeof u.name=="string"?u.name:void 0,componentId:typeof u.componentId=="string"?u.componentId:void 0,jsUrl:typeof u.jsUrl=="string"?u.jsUrl:"",url:typeof u.url=="string"?u.url:"",title:typeof u.title=="string"?u.title:"预览",position:u.position==="inline"?"inline":"right",width:typeof u.width=="string"?u.width:void 0,isFullscreen:typeof u.isFullscreen=="boolean"?u.isFullscreen:!1,autoOpen:typeof u.autoOpen=="boolean"?u.autoOpen:!1,fileRe:typeof u.fileRe=="string"?u.fileRe:void 0}}function th(e){const t=e.replace(/```\s*dynamic-component\s*\n?/,"").replace(/\n?\s*```/,"").trim();if(!t)return null;const n=t.match(/"position"\s*:\s*"(inline|right)"/);return n?{position:n[1]}:null}function nh(e){if(!e)return[];const t="``` dynamic-component",n="```",u=[];let o=0;for(;o<e.length;){const r=e.indexOf(t,o);if(r===-1){const m=e.slice(o);m&&u.push(m);break}let a=r+t.length;const s=e.lastIndexOf("```",r),c=s>=0&&s<r+3?s:r,d=e.slice(o,c);d&&u.push(d);const f=e.indexOf(n,a);if(f===-1){u.push(e.slice(c));break}const l=f+n.length,p=e.slice(c,l);u.push(Jf(p)),o=l}return u.filter(r=>r.length>0)}const rh=3e4,vt=new Map,Kr=new Map;function uh(e){const t=`fluens-dynamic-component-${e.instanceId}`;let n=document.getElementById(t);return n||(n=document.createElement("div"),n.id=t,n.style.width="100%",n.style.height="100%"),n}function La(e){const t=Kr.get(e.instanceId);if(t)return Promise.resolve(t.api);const n=vt.get(e.instanceId);if(n)return new Promise((o,r)=>{const a=n.resolve,s=n.reject;n.resolve=c=>{a(c),o(c)},n.reject=c=>{s(c),r(c)}});if((e.name||e.componentId)&&!e.jsUrl)return Promise.reject(new Error(`Dynamic component resource is empty: ${e.name||e.componentId}`));const u=uh(e);return new Promise((o,r)=>{const a=setTimeout(()=>{vt.delete(e.instanceId),r(new Error(`Dynamic component script load timeout: ${e.name||e.componentId}`))},rh),s={config:e,container:u,resolve:o,reject:r,timeoutId:a};vt.set(e.instanceId,s);const c=document.createElement("script");c.src=(e==null?void 0:e.jsUrl)??"",c.dataset.dynamicComponentId=e.instanceId,c.onload=()=>{setTimeout(()=>{vt.has(e.instanceId)&&(clearTimeout(a),vt.delete(e.instanceId),r(new Error(`Dynamic component did not call __fluens_dynamic_component_register: ${e.name||e.componentId}`)))},200)},c.onerror=()=>{clearTimeout(a),vt.delete(e.instanceId),r(new Error(`Failed to load dynamic component: ${e.name||e.componentId}`))},document.head.appendChild(c)})}function Oa(e){var o;const t=Kr.get(e);if(t){try{t.api.unmount()}catch{}(o=t.scriptElement)==null||o.remove(),Kr.delete(e)}const n=vt.get(e);n&&(clearTimeout(n.timeoutId),vt.delete(e));const u=document.getElementById(`fluens-dynamic-component-${e}`);u&&u.remove()}window.__fluens_dynamic_component_register=function(e,t){const n=vt.get(e);if(!n){console.warn(`Failed to read data in pending dynamic component: ${e}`);return}clearTimeout(n.timeoutId),vt.delete(e);const u={config:n.config,container:n.container,api:t,scriptElement:document.currentScript};Kr.set(e,u),u.container.parentElement;try{t.mount(n.container,n.config)}catch(o){console.error(`Failed to mount dynamic component: ${e}`,o)}n.resolve(t)};const yn=i.defineComponent({name:"FXDynamicComponent",props:{config:{type:Object,required:!0}},setup(e){const t=i.ref("loading"),n=i.ref(""),u=i.computed(()=>`fluens-dynamic-component-${e.config.instanceId}`),o=i.computed(()=>e.config.position==="inline"),r=i.computed(()=>t.value==="loading"||t.value==="error"?{width:"fit-content",maxWidth:"100%",height:"auto"}:o.value?{width:"fit-content",maxWidth:"100%",height:"auto"}:{width:e.config.width||"100%",height:"auto"});return i.onMounted(()=>{t.value="loading",n.value="",La(e.config).then(()=>{t.value="ready"}).catch(a=>{t.value="error",n.value=a.message||"Unknown error"})}),i.onUnmounted(()=>{Oa(e.config.instanceId)}),()=>i.createVNode("div",{class:"f-chat-dynamic-component-body",style:r.value},[i.createVNode("div",{id:u.value,style:{width:"100%",height:"100%",display:t.value==="ready"?"":"none"}},null),t.value==="loading"&&i.createVNode("div",{class:"f-chat-dynamic-component-loading"},[i.createVNode("span",{class:"f-chat-dynamic-component-loading-spinner"},null),i.createVNode("span",null,[i.createTextVNode("加载中......")])]),t.value==="error"&&i.createVNode("div",{class:"f-chat-dynamic-component-error"},[i.createVNode("span",{class:"f-chat-dynamic-component-error-icon"},[i.createTextVNode("!")]),i.createVNode("span",null,[n.value])])])}});function oh(e){return e?e.toLowerCase().replace(/[^a-z0-9\u4e00-\u9fff]+/g,"_").replace(/^_+|_+$/g,""):"surface"}function ih(e){const t=e.components.find(n=>n.id==="root");return t&&t.component==="Card",e.components}function ah(e){const t=oh(e.name),n="basic",u=[];u.push({version:"v0.9",createSurface:{surfaceId:t,catalogId:n,sendDataModel:!0}});const o=ih(e);return u.push({version:"v0.9",updateComponents:{surfaceId:t,components:o}}),e.data&&Object.keys(e.data).length>0&&u.push({version:"v0.9",updateDataModel:{surfaceId:t,path:"/",value:e.data}}),u}const sh=i.defineComponent({name:"FXBubbleTextContent",props:Jc,emits:["dynamicComponentsDetected","showDynamicComponent"],setup(e,t){const{renderFileEmbeddedContent:n}=si(),{propertyStates:u,registerProperty:o,updatePropertyValue:r,startStreaming:a}=Fr();o("title",e.title??""),o("subtitle",e.subtitle??""),o("text",e.text??""),i.watch([()=>e.title,()=>e.subtitle,()=>e.text],([p,m,h])=>{r("title",p??""),r("subtitle",m??""),r("text",h??"")});const s=i.computed(()=>e.textFormat==="markdown"),c=i.ref(!1),d=i.computed(()=>{var p,m,h;return c.value?{title:((p=u.title)==null?void 0:p.displayedValue)??"",subtitle:((m=u.subtitle)==null?void 0:m.displayedValue)??"",text:((h=u.text)==null?void 0:h.displayedValue)??""}:{title:e.title,subtitle:e.subtitle,text:e.text}}),f=i.computed(()=>{const p=tl(d.value.text),m=[];for(const h of p)Fu(h)?m.push(h):m.push(...nh(h));return m}),l=()=>f.value.length===0?null:i.createVNode("div",{class:"f-chat-bubble-text-collection"},[f.value.map((p,m)=>{var h;if(Fu(p)&&p.endsWith("```")){if(p.startsWith("```A2UI")){const v=nl(p),g=ah(v),b=new un.MessageProcessor([ye.basicCatalog]);b.processMessages(g);const w=g[0].createSurface.surfaceId,k=b.model.getSurface(w);return i.createVNode(i.Fragment,null,[i.createVNode("div",{style:"width: 400px;"},[i.createVNode(ye.Surface,{surface:k},null)]),i.createVNode("details",null,[i.createVNode("summary",{style:{cursor:"pointer",fontSize:"12px",color:"#666"}},[i.createTextVNode("A2UI Debug Data")]),i.createVNode("pre",{style:{fontSize:"10px",maxHeight:"300px",overflow:"auto",background:"#f5f5f5",padding:"8px"}},[JSON.stringify(v,null,2)])])])}const y=ci(p),x=(h=y==null?void 0:y.renderer)==null?void 0:h.url;return x?i.createVNode(bn,{key:`widget-${m}`,widgetAPIURL:x,widgetOptions:{mode:"embedded",implOptions:rl(p)},widgetData:y.data||{}},null):null}else{if(Fu(p))return i.createVNode("div",{class:"f-chat-bubble-widget-pending",key:`widget-loading-${m}`},[i.createVNode("span",{class:"f-chat-todo-status-icon f-chat-todo-status-working"},null),i.createVNode("span",{class:"f-chat-bubble-widget-pending-text"},[i.createTextVNode("数据生成中......")])]);if(Na(p)&&p.endsWith("```")){const y=eh(p);if(!y)return null;if(y.position==="inline")return i.createVNode(yn,{key:`dc-new-${m}`,config:y},null);{const x={type:"file",fileContent:{type:"md",name:y.title}},v={onPreviewFile:g=>{t.emit("showDynamicComponent",y)}};return i.nextTick(()=>t.emit("dynamicComponentsDetected",[y])),n(x,v)}}else if(Na(p)){const y=th(p);return(y==null?void 0:y.position)==="right"?null:i.createVNode("div",{class:"f-chat-bubble-widget-pending",key:`dynamic-component-new-loading-${m}`},[i.createVNode("span",{class:"f-chat-todo-status-icon f-chat-todo-status-working"},null),i.createVNode("span",{class:"f-chat-bubble-widget-pending-text"},[i.createTextVNode("组件加载中......")])])}else if(p!=null&&p.trim())return s.value?i.createVNode(hn,{style:{border:"0px none rgb(51, 51, 51)",borderRadius:0,boxShadow:"none",padding:0},content:{type:"markdown",message:"",content:p}},null):i.createVNode("div",{class:"f-chat-bubble-content-text",key:`bubble-text-${m}`},[p])}return null})]);return i.onMounted(()=>{c.value&&a()}),()=>i.createVNode(i.Fragment,null,[d.value.title&&i.createVNode("div",{class:"f-chat-bubble-content-title"},[d.value.title]),d.value.subtitle&&i.createVNode("div",{class:"f-chat-bubble-content-subtitle"},[d.value.subtitle]),l()])}}),ch={content:{type:Object},outputMode:{type:String,default:"full"}};function Qr({status:e}){const t=`f-chat-todo-status-icon f-chat-todo-status-${e.toLowerCase()}`;return i.createVNode("span",{class:t,"aria-hidden":!0},null)}const Ia=100,lh=i.defineComponent({name:"FXBubbleThink",props:ch,setup(e,t){var W;const{propertyStates:n,registerProperty:u,updatePropertyValue:o,isAllDone:r}=Fr(),{elapsedSeconds:a,hasEverStarted:s,start:c,stop:d,reset:f}=Su(),l=i.ref(((W=e.content)==null?void 0:W.completed)!==!0),p=i.ref(null),m=i.ref(null),h=i.ref(!1),y=i.ref(!1),x=i.computed(()=>e.outputMode==="streaming"),v=i.computed(()=>{var B;return(B=e.content)==null?void 0:B.completed}),g=i.computed(()=>{var j,H,F;const B=(j=b.value)==null?void 0:j.trim(),I=B?B.slice(0,8):"",M=I?`<span class="f-chat-bubble-thinking-preview">${I}</span>`:"";if(v.value){const V=s.value?`(用时${a.value}秒)`:"";return(((H=e.content)==null?void 0:H.title)??"思考完成"+V)+M}return(((F=e.content)==null?void 0:F.title)??"正在思考......")+M}),b=i.computed(()=>{var B,I;return x.value?((B=n.content)==null?void 0:B.displayedValue)??"":((I=e.content)==null?void 0:I.content)??""}),w=i.computed(()=>({"f-chat-bubble-thinking":!0,"is-pending":!v.value,"is-completed":v.value})),k=()=>{const B=p.value;if(!B||!h.value){y.value=!1;return}y.value=B.scrollTop>0};i.watch(()=>v.value,B=>{B?d():c()},{immediate:!0}),i.watch(()=>v.value,B=>{B&&(l.value=!1)}),i.watch(()=>e.content,B=>{B&&(n.content?o("content",B.content??""):u("content",B.content??""))},{immediate:!0}),i.watch(b,async()=>{if(l.value){await i.nextTick();const B=m.value;if(!B)return;await i.nextTick(),h.value=B.scrollHeight>Ia;const I=p.value;I&&h.value&&(I.scrollTop=I.scrollHeight,y.value=!0)}},{immediate:!0}),i.watch(l,async B=>{if(B){await i.nextTick();const I=m.value;if(!I)return;await i.nextTick(),h.value=I.scrollHeight>Ia;const M=p.value;M&&h.value&&(M.scrollTop=M.scrollHeight,y.value=!0)}}),i.onUnmounted(()=>{f()}),t.expose({instance:{get loadDone(){return e.content?(x.value?r.value:!0)&&v.value:!0}}});const S=()=>{l.value=!l.value},_=()=>v.value?null:i.createVNode(Qr,{status:"Working"},null),E=()=>!b.value||!l.value?null:i.createVNode("div",{class:"f-chat-bubble-thinking-content"},[i.createVNode("div",{class:"f-chat-bubble-thinking-scroll-container",ref:p,onScroll:k},[h.value&&y.value&&i.createVNode("div",{class:"f-chat-bubble-thinking-fade-mask"},null),i.createVNode("div",{class:"f-chat-bubble-thinking-text-wrapper"},[i.createVNode("div",{ref:m,class:"f-chat-bubble-thinking-content-text",innerHTML:b.value},null)])])]);return()=>i.createVNode("div",{class:w.value},[i.createVNode("div",{class:"f-chat-bubble-thinking-header",onClick:S},[_(),i.createVNode("span",{class:"f-chat-bubble-thinking-title",innerHTML:g.value},null),b.value&&i.createVNode("i",{class:"f-icon f-icon-arrow-chevron-right",style:{transform:l.value?"rotate(90deg)":"rotate(0deg)",transition:"all 0.3s ease-in-out"}},null)]),E()])}}),dh={content:{type:Object}},Pa={id:{type:String},arrowOffsetX:{type:Number,default:0},class:{type:String,default:""},customStyles:{type:Object,default:null},isSimpleTips:{type:Boolean,default:!1},fitContent:{type:Boolean,default:!1},host:{type:Object},leftBoundary:{type:Object},keepWidthWithReference:{type:Boolean,default:!1},minWidth:{type:Number,default:-1},offsetX:{type:Object,default:i.ref(0)},offsetY:{type:Object,default:i.ref(0)},placement:{type:String,default:"bottom"},reference:{type:Object},rightBoundary:{type:Object},showArrow:{type:Boolean,default:!1},title:{type:String},visible:{type:Boolean,default:!1},zIndex:{type:Number,default:-1},limitContentBySpace:{type:Boolean,default:!1},beforeClose:{type:Function}};function fh(e){const t=e.host?e.host:"body",n=i.computed(()=>t==="body"?0:t?t.getBoundingClientRect().top:0),u=i.computed(()=>t==="body"?window.innerHeight:t?t.getBoundingClientRect().bottom:window.innerHeight),o=i.computed(()=>t==="body"?0:t?t.getBoundingClientRect().left:0),r=i.computed(()=>t==="body"?document.body.getBoundingClientRect().width:t?t.getBoundingClientRect().width-(e.rightBoundary?e.rightBoundary.getBoundingClientRect().width:0):document.body.getBoundingClientRect().width),a=i.computed(()=>t==="body"?window.innerHeight:t?t.getBoundingClientRect().height:window.innerHeight);return{host:t,hostLeft:o,hostTop:n,hostWidth:r,hostHeight:a,hostBottom:u}}function hh(e,t,n,u){const o=i.ref(e.offsetX||0),r=i.ref(e.offsetY||0),a=i.ref(-1),s=i.ref(-1),c=i.ref(-1),d=i.ref(-1),f=i.ref(e.placement),l=i.ref(0),p=i.ref(0),m=i.ref(0),h=i.computed(()=>document.documentElement.scrollLeft),y=i.computed(()=>document.documentElement.scrollTop),{hostLeft:x,hostTop:v,hostWidth:g,hostHeight:b,hostBottom:w}=u;i.watch(()=>e.offsetX,N=>{o.value=N});const k=i.computed(()=>{const N={left:`${p.value}px`,top:`${m.value}px`,transform:`translate(${o.value}px, ${r.value}px)`};return e.zIndex!==-1&&(N["z-index"]=e.zIndex),e.fitContent?e.keepWidthWithReference&&n.value&&a.value>=n.value.getBoundingClientRect().width&&(N.width=`${a.value}px`):a.value!==-1&&(N.width=`${a.value}px`),e.minWidth!==-1&&(N.minWidth=`${e.minWidth}px`),e.customStyles&&Object.assign(N,e.customStyles),s.value>0&&(N.maxHeight=s.value+"px"),N}),S=i.computed(()=>({left:`${l.value}px`,transform:`translateX(${e.arrowOffsetX}px)`}));function _(N){if(N&&e.keepWidthWithReference){const L=N.getBoundingClientRect();a.value=Math.max(e.minWidth,L.width)}}function E(N,L){const U=g.value-N.width-4;return U>0?U:L}function W(N,L){const U=b.value-N.height-12;return U>0?U:L}function B(N,L,U){const K=l.value,Z=L.left-x.value+L.width/2+h.value,Y=L.top-v.value-(N.height+U.height)+y.value;return{popoverLeft:Z,popoverTop:Y,arrowLeft:K}}function I(N,L,U){const K=L.top-v.value+(L.height+U.height)+y.value,Z=W(N,K);return Math.min(K,Z)}function M(N,L){const U=E(L,N),K=N<=U?l.value:N-U;return{popoverLeft:Math.min(N,U),arrowLeft:K,maxHeight:0}}function D(N,L){const U=E(L,N),K=N<=U?l.value:N-U;return{popoverLeft:N,arrowLeft:K,maxHeight:0}}function j(N,L,U){const K=L.left-x.value+h.value,{arrowLeft:Z,popoverLeft:Y}=D(K,N),{popoverTop:ue}=B(N,L,U);return{popoverLeft:Y,popoverTop:ue,arrowLeft:Z,maxHeight:0}}function H(N,L,U){const K=L.left-x.value+L.width/2-(U.width/2-(N.left-x.value))+h.value,{arrowLeft:Z,popoverLeft:Y}=M(K,N),ue=I(N,L,U);return{popoverLeft:Y,popoverTop:ue,arrowLeft:Z,maxHeight:0}}function F(N,L,U){const K=L.left-x.value+h.value,{arrowLeft:Z,popoverLeft:Y}=M(K,N),ue=I(N,L,U);return{popoverLeft:Y,popoverTop:ue,arrowLeft:Z,maxHeight:0}}function V(N,L,U){const K=L.left-x.value;let Z=0,Y=0,ue=0,ce=0,De="bottom-left";window.innerWidth-K>N.width?Z=K+h.value:(Z=L.right-N.width+h.value,ue=N.width-U.width-20);let Te=0;if(e.limitContentBySpace){const Ht={topHeight:L.top-v.value-U.height-8,bottomHeight:w.value-L.bottom-U.height-8};Te=Math.max(Ht.topHeight,Ht.bottomHeight),N.height>Te&&(ce=Te,n.value.classList.add("popover-limitmax"))}const ht=ce?Math.floor(ce):N.height,Pe=L.top-v.value+(L.height+U.height);return w.value-Pe>ht?Y=Pe+y.value:(Y=L.top-ht-U.height+y.value,w.value-Pe>L.top?(Y=Pe+y.value,ht>L.top&&(Y=w.value-ht)):(Y=Y<0?0:Y,De="top")),n.value.classList.add("popover-"+De,"bs-popover-"+De),{popoverLeft:Z<0?5:Z,popoverTop:Y,arrowLeft:ue,maxHeight:ce}}function O(N,L,U){const K=L.left+L.width,Z=Math.max(L.top-(N.height/2-L.height/2),v.value);let Y=v.value+b.value-N.height;Y<0&&(Y=Z);const ue=Math.min(Z,Y);return{popoverLeft:K,popoverTop:ue,arrowLeft:0,maxHeight:0}}function $(N,L,U){const K=L.left+L.width,Z=Math.max(L.top-L.height,v.value);let Y=v.value+b.value-N.height;Y<0&&(Y=Z);const ue=Math.min(Z,Y);return{popoverLeft:K,popoverTop:ue,arrowLeft:0,maxHeight:0}}const re=new Map([["top",B],["top-left",j],["bottom",H],["bottom-left",F],["right",O],["right-top",$],["auto",V]]);function te(N){var Y;e.keepWidthWithReference&&_(N);const L=N.getBoundingClientRect();c.value=L.top,d.value=L.left;const U=t.value?t.value.getBoundingClientRect():{height:4,width:4},K=(Y=n.value)==null?void 0:Y.getBoundingClientRect();a.value=K.width;const Z=re.get(f.value);if(Z){const{arrowLeft:ue,popoverLeft:ce,popoverTop:De,maxHeight:Te}=Z(K,L,U);l.value=ue,p.value=ce,m.value=De,s.value=Te||-1}}function P(N){if(N){const L=N.getBoundingClientRect();(L.left!==d.value||L.top!==c.value)&&te(N)}}function R(){f.value=e.placement,l.value=0,p.value=0,m.value=0,a.value=-1}return{arrowStyle:S,popoverStyle:k,position:f,popoverWidth:a,fitToReference:_,followToReferencePosition:P,locateToReference:te,resetPosition:R}}function ph(e,t,n,u,o,r,a){const s=i.ref(e.visible),c=i.computed(()=>s.value),{fitToReference:d,locateToReference:f,resetPosition:l}=a;let p;async function m(){s.value&&(e.beforeClose&&typeof e.beforeClose=="function"&&!await e.beforeClose()||(s.value=!1,document.body.removeEventListener("click",p),document.body.removeEventListener("mousedown",p),document.body.removeEventListener("wheel",p,!0),document.removeEventListener("scroll",p),l(),t.emit("hidden")))}p=y=>{var g;if(!o.value)return;const x=o.value.contains(y.target);if(y.type==="scroll"||y.type==="wheel"&&x){m();return}if(y.target.closest(".time-picker-panel"))return;const v=(g=y.target)==null?void 0:g.closest(".popover");if(v&&u.value&&v===u.value){y.type!=="scroll"&&y.type!=="wheel"&&y.stopPropagation();return}if(!x&&s.value){const b=o.value.closest(".popover");b&&b.removeEventListener("click",p),m()}};async function h(y){if(u.value&&(e.showArrow===!1||e.showArrow&&n.value)&&y){s.value=!0,o.value=y,r.value&&d(y),await i.nextTick(),f(y),document.body.addEventListener("click",p),document.body.addEventListener("mousedown",p),document.body.addEventListener("wheel",p,!0),document.addEventListener("scroll",p),(top==null?void 0:top.document)!==document&&(top==null||top.document.addEventListener("mousedown",p));const x=y.closest(".popover");x&&x.addEventListener("click",p),t.emit("shown")}}return t.expose({hide:m,popoverRef:u,show:h,shown:c,isShow:s}),{showPopover:s,hidePopverOnClickBodyHandler:p}}function mh(e,t,n,u,o,r){const{popoverWidth:a,fitToReference:s,followToReferencePosition:c}=o;function d(){var f;if(r.value&&((f=r.value.style)==null?void 0:f.display)!=="none"&&n.value){c(n.value);const l=n.value.getBoundingClientRect();u.value&&l.width!==a.value&&s(n.value)}}return{onResize:d}}function gh(e,t=500){const n=i.ref(e.value);let u;const o=i.watch(e,a=>{clearTimeout(u),u=setTimeout(()=>{n.value=a},t)}),r=()=>{clearTimeout(u),o()};return i.onUnmounted(r),{delayedValue:n,cleanup:r}}const Gt=i.defineComponent({name:"FXPopover",props:Pa,emits:["shown","hidden"],setup(e,t){const n=i.ref(),u=i.ref(),o=i.ref(e.reference),r=i.ref(e.keepWidthWithReference),a=i.computed(()=>!!e.title),s=fh(e),{host:c}=s,d=hh(e,n,u,s),{position:f,arrowStyle:l,popoverStyle:p,fitToReference:m,locateToReference:h}=d,{showPopover:y,hidePopverOnClickBodyHandler:x}=ph(e,t,n,u,o,r,d),{onResize:v}=mh(e,t,o,r,d,u),g=i.computed(()=>{let _=f.value;_==="top-left"&&(_="top");const E=`popover in popover-${_}`,W=`bs-popover-${_}`,B={"popover-fitcontent":e.fitContent,fade:!0};B[E]=!0,B[W]=!0;const I=(e.class||"").split(" ");return e.isSimpleTips&&I.unshift("popover-tips"),I.reduce((M,D)=>(M[D]=!0,M),B),B}),b=i.computed(()=>({"popover-content":!0,"popover-body":!0})),w=i.computed(()=>{const _={};return _.opacity=y.value?1:0,_.visibility=y.value?"visible":"hidden",_.zIndex=1060,_}),k=i.computed(()=>e.isSimpleTips?!0:e.showArrow),{delayedValue:S}=gh(w,50);return i.onMounted(()=>{var _;r.value&&m(o.value),e.reference&&h(o.value),window.addEventListener("resize",v),(_=u.value)==null||_.focus()}),i.onUnmounted(()=>{document.body.removeEventListener("click",x),window.removeEventListener("resize",v),y.value=!1}),()=>i.createVNode(i.Teleport,{to:c},{default:()=>{var _;return[i.withDirectives(i.createVNode("div",{tabindex:"-1",ref:u,class:g.value,style:{...p.value,...S.value},onMousedown:E=>{E.stopPropagation()},onClick:E=>{E.stopPropagation()}},[k.value&&i.createVNode("div",{ref:n,class:"popover-arrow arrow",style:l.value},null),a.value&&i.createVNode("h3",{class:"popover-title popover-header"},[e.title]),i.createVNode("div",{class:b.value},[t.slots.default&&((_=t.slots)==null?void 0:_.default())])]),[[i.vShow,y.value]])]}})}}),Jr="FarrisX_PopoverInstancesKey";window[Jr]=window[Jr]||new WeakMap;function fo(e,t,n){e.stopPropagation();const u=t.value;u&&u.value&&!u.value.isShow&&(u.value.show(n),window[Jr].set(n,u.value))}function Ra(e,t,n){e.stopPropagation(),t.value.value.hide(),window[Jr].delete(n)}function bh(e,t,n){e.stopPropagation();const u=t.value;u&&u.value&&(u.value.isShow?Ra(e,t,n):fo(e,t,n))}function Va(e,t,n){t.arg&&t.arg==="toggle"?bh(e,t,n):fo(e,t,n)}const Ma={mounted:(e,t,n)=>{t.modifiers.hover?(e.addEventListener("mouseenter",u=>fo(u,t,e)),e.addEventListener("mouseleave",u=>Ra(u,t,e))):t.modifiers.click?e.addEventListener("click",u=>Va(u,t,e)):e.addEventListener("click",u=>Va(u,t,e)),e.classList.add("v-popover")},unMounted:(e,t,n)=>{}};Gt.install=e=>{e.component(Gt.name,Gt),e.directive("fxpopover",Ma)};const Ba={type:{type:String,default:"StartedToDo"},status:{type:String,default:"NotStart"},message:{type:String,default:""},taskDetail:{type:String,default:""},todoList:{type:Array,default:[]},detailViewMode:{type:String,default:"hover"},initExpanded:{type:Boolean,default:!1},showLoading:{type:Boolean,default:!0},showLabel:{type:Boolean,default:!0},loading:Object,shimmer:{type:Boolean,default:!0},outputMode:{type:String,default:"streaming"}},za={items:{type:Array,default:()=>[]}},ja={id:{type:Number||String,default:0},status:{type:String},task:{type:String,default:""},todoList:{type:Array,default:[]},detailViewMode:{type:String,default:"expand"},initExpanded:{type:Boolean,default:!0},showLoading:{type:Boolean,default:!0},showLabel:{type:Boolean,default:!1},shimmer:{type:Boolean,default:!0},title:{type:String,default:""},message:{type:String,default:""},outputMode:{type:String,default:"full"}},eu=i.defineComponent({name:"FXTodoListItemView",props:ja,emits:["click"],setup(e,{emit:t}){const{propertyStates:n,registerProperty:u,updatePropertyValue:o,startStreaming:r}=Fr();u("title",e.title??""),u("task",e.task??""),i.watch([()=>e.title,()=>e.task],([p,m])=>{o("title",p??""),o("task",m??"")});const a=i.computed(()=>["f-chat-todo-item",{"is-done":e.status==="Done","is-working":e.status==="Working","is-not-start":e.status==="NotStart","no-shimmer":!e.shimmer}]),s=i.computed(()=>["f-chat-todo-task",{"is-done":e.status==="Done"}]);function c(){t("click",e,e.id)}const d=i.computed(()=>e.outputMode==="streaming"),f=i.computed(()=>{var p;return d.value?((p=n.title)==null?void 0:p.displayedValue)??"":e.title??""}),l=i.computed(()=>{var p;return d.value?((p=n.task)==null?void 0:p.displayedValue)??"":e.task??""});return i.computed(()=>{var p;return d.value?((p=n.detail)==null?void 0:p.displayedValue)??"":e.message??""}),i.onMounted(()=>{d.value&&r()}),()=>i.createVNode("li",{key:e.id,class:a.value,onClick:c},[e.todoList&&e.todoList.length>0&&i.createVNode(qt,{todoList:e.todoList,status:e.status,message:e.task,taskDetail:e.message,detailViewMode:e.detailViewMode,initExpanded:e.initExpanded,showLoading:e.showLoading,showLabel:e.showLabel,outputMode:e.outputMode},null),!e.todoList||e.todoList.length===0&&i.createVNode(i.Fragment,null,[e.showLoading&&i.createVNode(Qr,{status:e.status??"Done"},null),f.value?i.createVNode("div",{class:"f-chat-todo-task-wrapper"},[i.createVNode("span",{class:s.value},[f.value]),i.createVNode("div",{class:"f-chat-todo-task-description"},[l.value])]):i.createVNode("div",{class:s.value},[l.value])])])}}),Kn=i.defineComponent({name:"FXTodoListView",props:za,setup(e){return()=>{var t;return(t=e.items)!=null&&t.length?i.createVNode("ul",{class:"f-chat-todo-items"},[e.items.map((n,u)=>i.createVNode(eu,i.mergeProps({key:u},n),null))]):null}}}),yh="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='18px'%20height='18px'%20viewBox='0%200%2018%2018'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3ctitle%3e编组%207%3c/title%3e%3cdefs%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-1'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%231EBBC6'%20offset='58.0673923%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cpath%20d='M7.55915932,0%20L13.7556941,3.41136535%20L13.7556941,11.284674%20L13.3483936,11.690778%20L7.386,8.406%20L7.38699821,14.9818613%20L6.43606745,14.9818613%20L0.817648054,11.8789694%20L0,10.332184%20L0,3.84230019%20L1.11160458,3.1505903%20L6.167,6.164%20L6.16702601,0.0484363034%20L7.55915932,0%20Z%20M6.22734637,8.44496623%20L1.7439756,11.0288454%20L6.22734637,13.5008368%20L6.22734637,8.44496623%20Z%20M12.540835,4.77769015%20L8.0314841,7.40118228%20L12.540835,9.89639007%20L12.540835,4.77769015%20Z%20M1.21847977,4.6422718%20L1.21847977,9.89639007%20L5.74466316,7.33704011%20L1.21847977,4.6422718%20Z%20M7.38699821,1.29872452%20L7.38699821,6.38587585%20L11.9618229,3.74647178%20L7.38699821,1.29872452%20Z'%20id='path-2'%3e%3c/path%3e%3clinearGradient%20x1='81.0966666%25'%20y1='38.5584607%25'%20x2='28.8545509%25'%20y2='61.9626707%25'%20id='linearGradient-4'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-5'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='44.8152906%25'%20y1='77.6521765%25'%20x2='44.8152906%25'%20y2='3.26462903%25'%20id='linearGradient-6'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-7'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='3.93796935%25'%20y1='32.607826%25'%20x2='78.9687461%25'%20y2='60.0462823%25'%20id='linearGradient-8'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-9'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='56.0769337%25'%20y1='45.0797149%25'%20x2='24.9463054%25'%20y2='71.1433818%25'%20id='linearGradient-10'%3e%3cstop%20stop-color='%23159BD7'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='10.434388%25'%20y1='68.063656%25'%20x2='86.6988821%25'%20y2='30.8651063%25'%20id='linearGradient-11'%3e%3cstop%20stop-color='%2321C6C1'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-12'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3c/defs%3e%3cg%20id='页面-1'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='输入框'%20transform='translate(-383,%20-2915)'%3e%3cg%20id='编组-3'%20transform='translate(353,%202900)'%3e%3cg%20id='编组-12'%20transform='translate(16,%200)'%3e%3cg%20id='编组-7'%20transform='translate(14,%2015)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='18'%20height='18'%3e%3c/rect%3e%3cg%20id='编组-35'%20transform='translate(0.2571,%200.2571)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='17.4857143'%20height='17.4857143'%3e%3c/rect%3e%3cg%20id='编组-19备份-17'%20transform='translate(1.0286,%200.5143)'%3e%3cpath%20d='M8.37444647,0.834547606%20L14.5709813,4.24591296%20L14.5709813,12.1192216%20L14.1636807,12.5253256%20L8.20128715,9.24054761%20L8.20228536,15.8164089%20L7.25135461,15.8164089%20L1.63293521,12.713517%20L0.815287151,11.1667316%20L0.815287151,4.67684779%20L1.92689173,3.98513791%20L6.98228715,6.99854761%20L6.98231316,0.882983909%20L8.37444647,0.834547606%20Z%20M7.04263352,9.27951383%20L2.55926275,11.8633931%20L7.04263352,14.3353844%20L7.04263352,9.27951383%20Z%20M13.3561221,5.61223775%20L8.84677126,8.23572989%20L13.3561221,10.7309377%20L13.3561221,5.61223775%20Z%20M2.03376692,5.47681941%20L2.03376692,10.7309377%20L6.55995031,8.17158771%20L2.03376692,5.47681941%20Z%20M8.20228536,2.13327213%20L8.20228536,7.22042346%20L12.77711,4.58101939%20L8.20228536,2.13327213%20Z'%20id='形状结合'%20fill='url(%23linearGradient-1)'%3e%3c/path%3e%3cg%20id='路径-2-+-路径-3-+-路径-4蒙版'%20transform='translate(0.8153,%200.8345)'%3e%3cmask%20id='mask-3'%20fill='white'%3e%3cuse%20xlink:href='%23path-2'%3e%3c/use%3e%3c/mask%3e%3cuse%20id='蒙版'%20fill='url(%23linearGradient-1)'%20xlink:href='%23path-2'%3e%3c/use%3e%3cpolygon%20id='路径-2'%20fill='url(%23linearGradient-4)'%20filter='url(%23filter-5)'%20mask='url(%23mask-3)'%20points='4.25315881%206.97898081%206.77390576%206.97898081%207.02656062%208.27871177%202.85827337%2011.0934106%201.11764364%208.72438079'%3e%3c/polygon%3e%3cpolygon%20id='路径-3'%20fill='url(%23linearGradient-6)'%20filter='url(%23filter-7)'%20mask='url(%23mask-3)'%20points='7.02656062%206.72375166%208.13485635%204.53274022%208.34127598%201.90699543%205.4451985%201.76583085%205.65253089%205.06118714%206.77390576%206.72375166'%3e%3c/polygon%3e%3cpolygon%20id='路径-4'%20fill='url(%23linearGradient-8)'%20filter='url(%23filter-9)'%20mask='url(%23mask-3)'%20points='10.0650382%207.40118228%207.32091739%207.49951705%207.32091739%208.25868082%208.54200343%2010.0061721%2010.9306691%2010.9000701%2012.5091187%208.51626021'%3e%3c/polygon%3e%3c/g%3e%3cpath%20d='M8.37444647,0.834547606%20L14.5709813,4.24591296%20L14.5709813,12.1192216%20L14.1636807,12.5253256%20L6.98231316,8.56885311%20L6.98231316,0.882983909%20L8.37444647,0.834547606%20Z%20M8.20228536,2.13327213%20L8.20228536,7.22042346%20L8.49131316,7.05254761%20L8.49185956,7.71336245%20L9.03131316,8.12754761%20L8.84677126,8.23572989%20L13.3561221,10.7309377%20L13.3553132,5.61654761%20L13.6305018,5.15381301%20L12.77711,4.58101939%20L8.20228536,2.13327213%20Z'%20id='形状结合'%20fill='url(%23linearGradient-10)'%20fill-rule='nonzero'%3e%3c/path%3e%3cpolygon%20id='路径'%20fill='url(%23linearGradient-11)'%20fill-rule='nonzero'%20points='6.7778308%208.05322127%207.08945008%209.24101764%202.55926275%2011.8633931%202.19155022%2010.6380421'%3e%3c/polygon%3e%3cg%20id='编组-21'%20fill='url(%23linearGradient-12)'%3e%3cpath%20d='M7.62936495,9.94195975%20C8.65711289,9.94195975%209.49026721,9.10880543%209.49026721,8.08105749%20C9.49026721,7.05330955%208.65711289,6.22015523%207.62936495,6.22015523%20C6.60161701,6.22015523%205.7684627,7.05330955%205.7684627,8.08105749%20C5.7684627,9.10880543%206.60161701,9.94195975%207.62936495,9.94195975%20Z%20M13.9785177,6.03107309%20C14.7793603,6.03107309%2015.4285714,5.38186193%2015.4285714,4.58101939%20C15.4285714,3.78017684%2014.7793603,3.13096568%2013.9785177,3.13096568%20C13.1776752,3.13096568%2012.528464,3.78017684%2012.528464,4.58101939%20C12.528464,5.38186193%2013.1776752,6.03107309%2013.9785177,6.03107309%20Z%20M7.62936495,16.4714598%20C8.4302075,16.4714598%209.07941866,15.8222486%209.07941866,15.0214061%20C9.07941866,14.2205635%208.4302075,13.5713524%207.62936495,13.5713524%20C6.8285224,13.5713524%206.17931125,14.2205635%206.17931125,15.0214061%20C6.17931125,15.8222486%206.8285224,16.4714598%207.62936495,16.4714598%20Z%20M1.45005371,13.0387617%20C2.25089625,13.0387617%202.90010741,12.3895505%202.90010741,11.588708%20C2.90010741,10.7878654%202.25089625,10.1386543%201.45005371,10.1386543%20C0.649211158,10.1386543%200,10.7878654%200,11.588708%20C0,12.3895505%200.649211158,13.0387617%201.45005371,13.0387617%20Z%20M7.62936495,2.51342642%20C8.32342849,2.51342642%208.88607816,1.95077675%208.88607816,1.25671321%20C8.88607816,0.56264967%208.32342849,0%207.62936495,0%20C6.93530141,0%206.37265174,0.56264967%206.37265174,1.25671321%20C6.37265174,1.95077675%206.93530141,2.51342642%207.62936495,2.51342642%20Z%20M13.9785177,12.9913309%20C14.6725813,12.9913309%2015.2352309,12.4286812%2015.2352309,11.7346177%20C15.2352309,11.0405541%2014.6725813,10.4779045%2013.9785177,10.4779045%20C13.2844542,10.4779045%2012.7218045,11.0405541%2012.7218045,11.7346177%20C12.7218045,12.4286812%2013.2844542,12.9913309%2013.9785177,12.9913309%20Z%20M1.45005371,5.50262617%20C2.14411725,5.50262617%202.70676692,4.9399765%202.70676692,4.24591296%20C2.70676692,3.55184942%202.14411725,2.98919975%201.45005371,2.98919975%20C0.755990164,2.98919975%200.193340494,3.55184942%200.193340494,4.24591296%20C0.193340494,4.9399765%200.755990164,5.50262617%201.45005371,5.50262617%20Z'%20id='形状结合'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",xh=300,wh={Working:"正在执行任务",Done:"已完成任务",NotStart:"待执行任务"},qt=i.defineComponent({name:"FXStartedTodo",props:Ba,setup(e){const t=i.ref(null),n=i.ref(null),u=i.ref(null),o=i.ref(null),r=i.computed(()=>e.outputMode==="streaming"),{displayContent:a}=ii(()=>({detail:e.taskDetail??""}),()=>!0,r,{charInterval:30}),s=i.ref(e.initExpanded),c=i.computed(()=>({"f-chat-message-started-todo--content":!0,"d-none":!s.value}));function d(){e.detailViewMode!=="expand"&&(o.value!=null&&(window.clearTimeout(o.value),o.value=null),u.value=window.setTimeout(()=>{t.value&&n.value&&n.value.show(t.value),u.value=null},xh))}function f(){e.detailViewMode!=="expand"&&(u.value!=null&&(window.clearTimeout(u.value),u.value=null),o.value=window.setTimeout(()=>{var x,v;(v=(x=n.value)==null?void 0:x.hide)==null||v.call(x),o.value=null},150))}function l(){if(e.detailViewMode==="none")return null;const x=a.value.detail??"";return i.createVNode(i.Fragment,null,[x?i.createVNode("div",{class:"f-chat-started-todo-task-detail"},[x]):null,i.createVNode(Kn,{items:e.todoList},null)])}function p(){e.detailViewMode==="expand"&&(s.value=!s.value)}function m(){return e.detailViewMode==="expand"?i.createVNode("i",{class:"f-icon f-icon-arrow-chevron-right",style:{transform:s.value?"rotate(90deg)":"rotate(0deg)",transition:"all 0.3s ease-in-out"}},null):null}function h(){return e.detailViewMode==="hover"&&i.createVNode(Gt,{ref:n,class:"f-chat-started-todo-popover"},{default:()=>[i.createVNode("div",{class:"f-chat-started-todo-popover-content",onMouseenter:()=>{o.value!=null&&(window.clearTimeout(o.value),o.value=null)},onMouseleave:f},[l()])]})}function y(){return e.showLoading?e.loading?e.loading:e.status==="Done"?i.createVNode("img",{src:yh},null):i.createVNode(Qr,{status:e.status},null):null}return()=>i.createVNode("div",{ref:t,class:["f-chat-message-started-todo",{"is-working":e.status==="Working"}],onMouseenter:d,onMouseleave:f},[i.createVNode("div",{class:"f-chat-message-started-todo--header",onClick:p},[e.showLabel&&i.createVNode("span",{class:"f-chat-started-todo-label"},[wh[e.status]]),y(),i.createVNode("span",{class:"f-chat-started-todo-message",innerHTML:e.message},null),m()]),e.detailViewMode==="expand"&&i.createVNode("div",{class:c.value},[l()]),h()])}});qt.install=e=>{e.component(qt.name,qt)};const vh=i.defineComponent({name:"FXBubbleThoughtChain",props:dh,setup(e,t){const{elapsedSeconds:n,hasEverStarted:u,start:o,stop:r,reset:a}=Su(),s=i.computed(()=>{var l;return((l=e.content)==null?void 0:l.status)==="Done"}),c=i.computed(()=>{var l;return((l=e.content)==null?void 0:l.message)??"正在思考......"}),d=i.computed(()=>{var m,h;const l=((m=e.content)==null?void 0:m.doneMessage)??((h=e.content)==null?void 0:h.message)??"思考完成",p=u.value?`(用时${n.value}秒)`:"";return""+l+p}),f=i.computed(()=>s.value?d.value:c.value);return i.watch(()=>{var l;return(l=e.content)==null?void 0:l.status},l=>{l==="Working"?o():l==="Done"?r():a()},{immediate:!0}),i.onUnmounted(()=>{a()}),t.expose({instance:{get loadDone(){return e.content?s.value:!0}}}),()=>{var l,p,m;return e.content?i.createVNode(qt,{status:((l=e.content)==null?void 0:l.status)??"Working",message:f.value,todoList:(p=e.content)==null?void 0:p.todoList,detailViewMode:((m=e.content)==null?void 0:m.detailViewMode)??"expand",showLabel:!1,showLoading:!0,initExpanded:!0},null):null}}}),ho=i.defineComponent({name:"UserAuthMessage",props:{content:{type:Object,required:!0},onConfirm:{type:Function,default:void 0}},setup(e){return()=>i.createVNode("div",{class:"f-ec-auth"},[i.createVNode("div",{class:"f-ec-auth-desc"},[e.content.description]),i.createVNode("div",{class:"f-ec-auth-actions"},[e.content.options.map(t=>i.createVNode("button",{key:t.optionId,type:"button",class:"f-ec-auth-btn",onClick:()=>{var n;(n=e.onConfirm)==null||n.call(e,t.optionId,t.name,t.message??t.name),console.info("[UserAuth]",t.optionId,t.name)}},[t.name]))])])}}),Ah=300,Xt=i.defineComponent({name:"FXToolUseMessage",props:{content:{type:Object,required:!0}},setup(e){const t=i.computed(()=>e.content.toolResultApplied===!0||String(e.content.result??"").trim().length>0),n=i.ref(!1);let u=setTimeout(()=>{n.value=!0},Ah);i.onBeforeUnmount(()=>{u&&clearTimeout(u)});const o=i.computed(()=>t.value),r=i.computed(()=>n.value&&!t.value),a=i.computed(()=>o.value?"执行成功":"调用中"),s=i.ref(!1),c=i.computed(()=>({"f-chat-tool-use":!0,"is-done":o.value})),d=i.computed(()=>({"f-chat-tool-use-status":!0,"is-done":o.value,"is-run":r.value}));i.watch(()=>[e.content.result,e.content.toolResultApplied],()=>{t.value&&(s.value=!1)},{flush:"post"});const f=()=>t.value?i.createVNode("div",{class:"f-chat-tool-use-result"},[e.content.result??""]):null;return()=>i.createVNode("div",{class:c.value},[i.createVNode("div",{class:"f-chat-tool-use-header",onClick:()=>{s.value=!s.value}},[i.createVNode("i",{class:"tool-icon"},null),i.createVNode("span",{class:"f-chat-tool-use-name"},[e.content.toolDescription??"tool"]),i.createVNode("div",{class:d.value},[i.createVNode(Qr,{status:o.value?"Done":r.value?"Working":"NotStart"},null),i.createVNode("span",{class:"f-chat-tool-use-status-text"},[a.value])]),i.createVNode("i",{class:"f-icon f-icon-arrow-chevron-right",style:{transform:s.value?"rotate(90deg)":"rotate(0deg)",transition:"transform 0.2s ease"}},null)]),s.value&&i.createVNode("div",{class:"f-chat-tool-use-content"},[f()])])}});Xt.install=e=>{e.component(Xt.name,Xt)};const Qn=i.defineComponent({name:"FXBubble",components:{"fx-user-auth-inline":ho,"fx-app-preview-inline":on,FXToolUse:Xt},props:ri,setup(e,t){const n=i.shallowRef(),u=i.ref(),o=i.ref(),r=i.computed(()=>!!e.showAvatar),a=i.computed(()=>r.value===!0||e.header==="ContentHeader"),s=i.computed(()=>t.slots.leftFooter||t.slots.rightFooter),c=i.computed(()=>{var D;return Ae({},(D=e.styles)==null?void 0:D.footer)}),d=D=>{if(e.onPreview){if(D.type==="md"&&D.content){e.onPreview({content:D.content,contentType:"markdown"});return}if(D!=null&&D.url){const j=D!=null&&D.fullScreenPreview?"fullScreen":"splitScreen";e.onPreview({url:D.url,previewMode:j,title:D.name})}}},f=D=>{if(!e.onPreview)return;const j=D==null?void 0:D.filter(F=>F.type==="md"&&F.content);if(j.length===0)return;const H=Object.fromEntries(j.map(F=>[F.name,F.content??""]));e.onPreview({contentMap:H,contentType:"markdown"})},{renderFileEmbeddedContent:l,renderPageEmbeddedContent:p}=si(),m=i.ref(""),h=i.computed(()=>{var j,H;if((j=e.content)!=null&&j.footerContent)return e.content.footerContent;const D=(H=e.content)==null?void 0:H.structuredContent;return D&&(D.footerTemplate||D.footerUrl||D.footerFile)?{type:D.footerUrl?"page":D.footerFile?"file":"template",pageUrl:D.footerUrl,fileContent:D.footerFile,template:D.footerTemplate,width:D.footerWidth,height:D.footerHeight}:null});i.watch(()=>{var D;return(D=h.value)==null?void 0:D.width},D=>{if(!D){m.value="";return}if(D.endsWith("%")){const j=parseFloat(D);isNaN(j)||i.nextTick(()=>{var F,V;const H=(V=(F=n.value)==null?void 0:F.parentElement)==null?void 0:V.clientWidth;H&&(m.value=`${H*j/100}px`)})}else m.value=D},{immediate:!0});const y=D=>{if(!D||D.length===0)return"我";const j=D.charAt(0);return/[\u4e00-\u9fa5]/.test(j)?j:j.toUpperCase()};function x(){return e.header==="ContentHeader"?Wc:Gc}const v=x(),{renderHeader:g}=v(e,t),b=()=>{var H,F,V;const D=((H=e.content)==null?void 0:H.sender)??"发送人",j=y(((F=e.content)==null?void 0:F.sender)??"");return i.createVNode("div",{class:"f-chat-bubble-avatar"},[(V=e.content)!=null&&V.avatar?i.createVNode("img",{src:e.content.avatar,alt:D},null):i.createVNode("div",{class:"f-chat-bubble-avatar-initial"},[j])])},w=()=>{var j;const D=(j=e.content)==null?void 0:j.toolUseAboveText;return D!=null&&D.length?i.createVNode("div",{class:"f-chat-bubble-tool-use-group"},[D.map((H,F)=>i.createVNode(Xt,{key:H.toolUseId??`tu-${F}`,content:H},null))]):null},k=()=>{var D;return(D=e.content)!=null&&D.thinkingContent?i.createVNode(lh,{ref:u,content:e.content.thinkingContent,outputMode:e.outputMode},null):null},S=()=>{var D;return(D=e.content)!=null&&D.startedTodo?i.createVNode(vh,{ref:o,content:e.content.startedTodo},null):null},_=D=>{if(!(D!=null&&D.type))return null;const{type:j}=D;return j==="page"&&D.pageUrl?p(D,{onNavigate:H=>{var F;(F=e.onPreview)==null||F.call(e,{url:H})}}):j==="file"&&D.fileContent?l(D,{onPreviewFile:d,onBatchPreviewFile:f}):j==="template"&&D.template?D.template():null},E=()=>{var F,V,O;if(!((O=(V=(F=e.content)==null?void 0:F.structuredContent)==null?void 0:V.sections)!=null&&O.length))return null;const{sections:D,showDivider:j}=e.content.structuredContent,H=$=>{const{content:re,label:te}=$;return te||re&&typeof re=="string"?i.createVNode(i.Fragment,null,[i.createVNode("span",{class:"f-chat-bubble-structured-section-item-dot"},null),$.label&&i.createVNode("span",{class:"f-chat-bubble-structured-section-item-label"},[$.label]),i.createVNode("span",{class:"f-chat-bubble-structured-section-item-content"},[$.content])]):_($.content)};return i.createVNode("div",{class:["f-chat-bubble-structured",{"structure-content-divider":j}]},[D.map(($,re)=>i.createVNode("div",{key:re,class:["f-chat-bubble-structured-section",{"section-divider":$.showDivider}]},[i.createVNode("div",{class:"f-chat-bubble-structured-section-header"},[$.icon&&($.icon.startsWith("http")||$.icon.startsWith("//")||$.icon.startsWith("../")||/\.(png|jpg|jpeg|gif|svg|webp|bmp)$/i.test($.icon)?i.createVNode("img",{alt:$.title,src:$.icon,class:"f-chat-bubble-structured-section-icon"},null):i.createVNode("i",{class:`f-icon ${$.icon}`,style:$.iconStyle},null)),i.createVNode("span",{class:"f-chat-bubble-structured-section-title"},[$.title])]),$.items&&$.items.length>0&&i.createVNode("div",{class:"f-chat-bubble-structured-section-items"},[$.items.map((te,P)=>i.createVNode("div",{key:P,class:"f-chat-bubble-structured-section-item"},[H(te)]))])]))])},W=()=>{const D=h.value;if(!D)return null;const j={};return m.value&&(j.width=m.value),D.height&&(j.height=`${D.height}px`),i.createVNode("div",{class:"f-chat-bubble-content-footer",style:j},[_(D)])},B=()=>i.createVNode(ai,{attachments:e.attachments??[],enableFixedWidth:e.placement==="end",onPreview:d,onBatchPreview:f},null),I=()=>{var j;const D=(j=e.content)==null?void 0:j.compositeInlineBlocks;return D!=null&&D.length?D.map((H,F)=>H.kind==="userAuth"?i.createVNode(i.resolveComponent("fx-user-auth-inline"),{key:`inline-auth-${F}`,content:H.content,onConfirm:e.onUserAuthConfirm},null):i.createVNode(i.resolveComponent("fx-app-preview-inline"),{key:`inline-preview-${F}`,content:H.content,onOpen:e.onPreview},null)):null},M=()=>{var D,j,H,F,V,O;return i.createVNode("div",{class:`f-chat-bubble-content ${e.placement}`},[a.value&&g(),i.createVNode("div",{class:`f-chat-bubble-content-text-wrapper ${e.placement}`},[(D=e.content)!=null&&D.compositeOrderedBeforeMarkdownRender?e.content.compositeOrderedBeforeMarkdownRender():i.createVNode(i.Fragment,null,[k(),w()]),S(),E(),i.createVNode(sh,{title:((j=e.content)==null?void 0:j.title)??"",subtitle:((H=e.content)==null?void 0:H.subtitle)??"",text:((F=e.content)==null?void 0:F.text)??"",textFormat:((V=e.content)==null?void 0:V.textFormat)??"plain",placement:e.placement,onDynamicComponentsDetected:e==null?void 0:e.onDynamicComponentsDetected,onShowDynamicComponent:e==null?void 0:e.onShowDynamicComponent},null),W(),(O=e.compositeTailRender)==null?void 0:O.call(e),I()]),s.value&&i.createVNode("div",{class:"f-chat-bubble-footer",style:c.value},[t.slots.leftFooter&&i.createVNode("div",{class:"f-chat-bubble-footer-left"},[t.slots.leftFooter()]),t.slots.rightFooter&&i.createVNode("div",{class:"f-chat-bubble-footer-right"},[t.slots.rightFooter()])]),B()])};return()=>i.createVNode("div",{class:"f-chat-bubble-container",ref:n},[i.createVNode("div",{class:`f-chat-bubble-wrapper ${e.placement}`},[e.placement==="start"?i.createVNode(i.Fragment,null,[r.value&&b(),M()]):i.createVNode(i.Fragment,null,[M(),r.value&&b()])])])}}),Ha={customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""}},po=i.defineComponent({name:"FXBubbleAction",props:Ha,setup(e,t){const n=i.computed(()=>Ae({},e.customStyle));return()=>t.slots.default&&i.createVNode("span",{class:"f-chat-bubble-footer-action",style:n.value},[t.slots.default()])}});Qn.install=e=>{e.component(Qn.name,Qn),e.component(po.name,po)};const $a={items:{type:Array,default:()=>[]},modelValue:{type:Number,default:0},direction:{type:String,default:"horizontal"},autoplay:{type:Boolean,default:!1},interval:{type:Number,default:3e3},loop:{type:Boolean,default:!0},trigger:{type:String,default:"click"},indicatorPosition:{type:String,default:"inside"},arrowVisibility:{type:String,default:"hover"},showIndicator:{type:Boolean,default:!0},showArrow:{type:Boolean,default:!0},showInfo:{type:Boolean,default:!0},height:{type:[String,Number],default:"400px"},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})},customClass:{type:[String,Array,Object],default:""},customStyle:{type:[Object,String],default:""},buttonPosition:{type:String,default:"inner"}},Ua={item:{type:Object,default:()=>({})},index:{type:Number,default:0},active:{type:Boolean,default:!1},showInfo:{type:Boolean,default:!0},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})}},tu=i.defineComponent({name:"FXCarouselItem",props:Ua,emits:["click"],setup(e,{slots:t,emit:n}){const u=i.computed(()=>{var l;const f={"fx-carousel--item":!0,"fx-carousel--item-active":e.active};return be(f,(l=e.classNames)==null?void 0:l.item)}),o=i.computed(()=>{var l,p;const f=Ae({},(l=e.styles)==null?void 0:l.item);return Ae(f,(p=e.styles)==null?void 0:p.item)}),r=()=>{var f,l,p;return e.item.image?i.createVNode("img",{class:["fx-carousel--item-image",(f=e.classNames)==null?void 0:f.image],style:(l=e.styles)==null?void 0:l.image,src:e.item.image,alt:(p=e.item.title)==null?void 0:p.toString()},null):null},a=()=>{var f,l,p,m;return e.item.content?i.createVNode("div",{class:["fx-carousel--item-content",(f=e.classNames)==null?void 0:f.content],style:(l=e.styles)==null?void 0:l.content},[e.item.content]):t.default?i.createVNode("div",{class:["fx-carousel--item-content",(p=e.classNames)==null?void 0:p.content],style:(m=e.styles)==null?void 0:m.content},[t.default()]):null},s=()=>{var f,l;return e.item.title?i.createVNode("h3",{class:["fx-carousel--item-title",(f=e.classNames)==null?void 0:f.title],style:(l=e.styles)==null?void 0:l.title},[e.item.title]):null},c=()=>{var f,l;return e.item.description?i.createVNode("p",{class:["fx-carousel--item-description",(f=e.classNames)==null?void 0:f.description],style:(l=e.styles)==null?void 0:l.description},[e.item.description]):null},d=f=>{e.item.disabled||n("click",f,e.item,e.index)};return()=>i.createVNode("div",{class:u.value,style:o.value,onClick:d},[r(),a(),e.showInfo&&i.createVNode("div",{class:"fx-carousel--item-info"},[s(),c()])])}});function kh(e){const{items:t,autoplay:n=!1,interval:u=3e3,loop:o=!0,direction:r="horizontal"}=e,a=i.ref(0),s=i.ref(!1),c=i.ref(null),d=i.computed(()=>t.length),f=i.computed(()=>d.value<=1);i.computed(()=>a.value===0?o?d.value-1:0:a.value-1),i.computed(()=>a.value===d.value-1?o?0:a.value:a.value+1);const l=i.computed(()=>{const b=-a.value*100;return{transform:r==="horizontal"?`translateX(${b}%)`:`translateY(${b}%)`,transition:"transform 0.5s ease"}}),p=b=>{b<0||b>=d.value||(a.value,a.value=b)},m=()=>{f.value||(a.value===d.value-1?p(o?0:a.value):p(a.value+1))},h=()=>{f.value||(a.value===0?p(o?d.value-1:0):p(a.value-1))},y=()=>{!n||f.value||(x(),c.value=window.setInterval(()=>{s.value||m()},u))},x=()=>{c.value&&(clearInterval(c.value),c.value=null)},v=()=>{s.value=!0,n&&x()},g=()=>{s.value=!1,n&&y()};return i.onMounted(()=>{y()}),i.onUnmounted(()=>{x()}),{currentIndex:a,totalItems:d,isSingleItem:f,trackStyle:l,goTo:p,next:m,prev:h,handleMouseEnter:v,handleMouseLeave:g}}const Jn=i.defineComponent({name:"FXCarousel",props:$a,emits:["update:modelValue","change","item-click"],setup(e,{slots:t,emit:n}){const{currentIndex:u,isSingleItem:o,trackStyle:r,goTo:a,next:s,prev:c,handleMouseEnter:d,handleMouseLeave:f}=kh({items:e.items,autoplay:e.autoplay,interval:e.interval,loop:e.loop,direction:e.direction}),l=k=>{n("update:modelValue",k),n("change",k,u.value)},p=i.computed(()=>{var S;const k={"fx-carousel":!0,"fx-carousel--vertical":e.direction==="vertical","fx-carousel--single":o.value,"fx-carousel--button-outer":e.buttonPosition==="outer","fx-carousel--button-inner":e.buttonPosition==="inner"};return be(k,(S=e.classNames)==null?void 0:S.root)}),m=i.computed(()=>{var _;const k={height:typeof e.height=="number"?`${e.height}px`:e.height},S=Ae(k,e.customStyle);return Ae(S,(_=e.styles)==null?void 0:_.root)}),h=i.computed(()=>{var S;const k={"fx-carousel--container":!0,"fx-carousel--container-hover":e.arrowVisibility==="hover"};return be(k,(S=e.classNames)==null?void 0:S.container)}),y=i.computed(()=>{var S;return be({"fx-carousel--track":!0},(S=e.classNames)==null?void 0:S.track)}),x=i.computed(()=>{var S;const k={"fx-carousel--indicator":!0,"fx-carousel--indicator-outside":e.indicatorPosition==="outside","fx-carousel--indicator-none":e.indicatorPosition==="none"||!e.showIndicator};return be(k,(S=e.classNames)==null?void 0:S.indicator)}),v=k=>{var _,E;const S={"fx-carousel--arrow":!0,"fx-carousel--arrow-left":k==="left","fx-carousel--arrow-right":k==="right","fx-carousel--arrow-never":e.arrowVisibility==="never"||!e.showArrow};return S[`fx-carousel--arrow-${e.buttonPosition}`]=!0,be(S,k==="left"?(_=e.classNames)==null?void 0:_.arrowLeft:(E=e.classNames)==null?void 0:E.arrowRight)},g=k=>{var E,W;if(o.value)return null;const S=k==="left"?c:s,_=t[k==="left"?"prevArrow":"nextArrow"];return i.createVNode("button",{class:v(k),style:k==="left"?(E=e.styles)==null?void 0:E.arrowLeft:(W=e.styles)==null?void 0:W.arrowRight,onClick:S,"aria-label":`${k} arrow`},[_?_():i.createVNode("i",{style:"font-size: 60px;",class:`f-icon f-icon-arrow-chevron-${k==="left"?"left":"right"}`},null)])},b=()=>{var k;return o.value||!e.showIndicator?null:i.createVNode("div",{class:x.value,style:(k=e.styles)==null?void 0:k.indicator},[e.items.map((S,_)=>{var E,W;return i.createVNode("button",{"aria-label":`indicator ${_}`,key:_,class:["fx-carousel--indicator-item",{"fx-carousel--indicator-item-active":_===u.value}],style:_===u.value?(E=e.styles)==null?void 0:E.indicatorItemActive:(W=e.styles)==null?void 0:W.indicatorItem,onClick:()=>{a(_),l(_)}},null)})])},w=()=>i.createVNode("div",{class:y.value,style:r.value},[e.items.map((k,S)=>i.createVNode(tu,{key:k.id||`item_${S}`,item:k,showInfo:e.showInfo,index:S,active:S===u.value,styles:e.styles,classNames:e.classNames,onClick:(_,E,W)=>{n("item-click",_,E,W)}},{default:()=>{var _,E;return[(_=t.item)==null?void 0:_.call(t,{item:k,index:S,active:S===u.value}),(E=t[`item${S}`])==null?void 0:E.call(t,{item:k,index:S,active:S===u.value})]}}))]);return()=>{var k;return i.createVNode("div",{class:p.value,style:m.value,onMouseenter:d,onMouseleave:f},[e.buttonPosition==="outer"&&g("left"),i.createVNode("div",{class:h.value,style:(k=e.styles)==null?void 0:k.container},[e.buttonPosition==="inner"&&g("left"),w(),e.buttonPosition==="inner"&&g("right")]),e.buttonPosition==="outer"&&g("right"),b()])}}});Jn.install=e=>{e.component(Jn.name,Jn),e.component(tu.name,tu)};const Wa={customStyle:{type:String,default:""},customClass:{type:String,default:""},direction:{Type:String,default:"row"}};function Ch(e){const t=i.ref(-1),n=i.ref(-1),u=i.ref(0),o=i.ref(0),r=i.ref(!1),a=i.ref(!1),s=i.computed(()=>({display:r.value?"block":"none",left:`${u.value}px`,cursor:"e-resize"})),c=i.computed(()=>({display:a.value?"block":"none",top:`${o.value}px`,cursor:"n-resize"})),d=i.computed(()=>{const x={display:a.value||r.value?"block":"none"};return o.value>0&&(x.cursor="n-resize"),x});function f(x,v,g,b){const w=e.value;if(w){const{left:k,right:S,width:_}=w.getBoundingClientRect();let E=x.clientX-k;b==="right"&&(E=S-x.clientX),E>v&&(E=v),E<g&&(E=g),b==="right"&&(E=_-E),u.value=E}}function l(x,v,g,b){const w=e.value;if(w){const{top:k,bottom:S,height:_}=w.getBoundingClientRect();let E=x.clientY-k;b==="bottom"&&(E=S-x.clientY),E>v&&(E=v),E<g&&(E=g),b==="bottom"&&(E=_-E),o.value=E}}function p(){const x=e.value;if(x){const{width:v,height:g}=x.getBoundingClientRect();return{width:v,height:g}}return null}function m(){const x=e.value;return x?Array.from(x.querySelectorAll("[data-position]")).reduce((v,g)=>{const b=g.getAttribute("data-position");return v=Object.assign(v,{[b]:g}),v},{}):null}function h(x,v){const g=p(),b=m();if(g&&b){const w=b==null?void 0:b.right,k=b==null?void 0:b.left;if(x==="left"&&k)return w?g.width-w.clientWidth-v:g.width-v;if(x==="right"&&w)return k?g.width-k.clientWidth-v:g.width-v}}function y(x,v){const g=p(),b=m();if(g&&b){const w=b==null?void 0:b.bottom,k=b==null?void 0:b.top;if(x==="top"&&k)return w?g.height-w.clientHeight-v:g.height-v;if(x==="bottom"&&w)return k?g.height-k.clientHeight-v:g.height-v}}return{horizontalResizeHandleStyle:s,verticalResizeHandleStyle:c,resizeOverlayStyle:d,showHorizontalResizeHandle:r,showVerticalResizeHandle:a,horizontalResizeBarPosition:t,verticalResizeBarPosition:n,verticalResizeHandleOffset:o,horizontalResizeHandleOffset:u,draggingHorizontalResizeHandle:f,draggingVerticalResizeHandle:l,getPanelMaxWidth:h,getPanelMaxHeight:y}}const xn=i.defineComponent({name:"FXSplitter",props:Wa,emits:[],setup(e,t){const n=i.ref(),u=Ch(n),{horizontalResizeHandleStyle:o,verticalResizeHandleStyle:r,resizeOverlayStyle:a}=u;i.provide("splitter",{useResizeHandleComposition:u});const s=i.computed(()=>be({"f-splitter":!0},e==null?void 0:e.customClass)),c=i.computed(()=>{const d={"flex-direction":e.direction==="row"?"row":"column"};return Ae(d,e==null?void 0:e.customStyle)});return()=>i.createVNode("div",{class:s.value,ref:n,style:c.value},[t.slots.default&&t.slots.default(),i.createVNode("div",{class:"f-splitter-resize-overlay",style:a.value},null),i.createVNode("div",{class:"f-splitter-horizontal-resize-proxy",style:o.value},null),i.createVNode("div",{class:"f-splitter-vertical-resize-proxy",style:r.value},null)])}}),Eh={customClass:{type:String,defaut:""},customStyle:{type:String,default:""},width:{type:Number},height:{type:Number},position:{type:String,default:"left"},visible:{type:Boolean,default:!0},resizable:{type:Boolean,default:!0},resizeHandle:{type:String,default:""},collapsable:{type:Boolean,default:!1},minWidth:{type:Number,default:100},minHeight:{type:Number,default:100},maxWidth:{type:Number,default:0},maxHeight:{type:Number,default:0}};function _h(e,t){const n=i.ref(e.width),u=i.ref(e.height),{horizontalResizeBarPosition:o,horizontalResizeHandleOffset:r,showHorizontalResizeHandle:a,showVerticalResizeHandle:s,verticalResizeBarPosition:c,verticalResizeHandleOffset:d,draggingHorizontalResizeHandle:f,draggingVerticalResizeHandle:l,getPanelMaxWidth:p,getPanelMaxHeight:m}=t;let h="",y,x,v;const g=()=>e.maxWidth?e.maxWidth:p(h,e.minWidth)||0,b=()=>e.maxHeight?e.maxHeight:m(h,e.minHeight)||0;function w(_){if((h==="left"||h==="right")&&x){const{left:E}=x.getBoundingClientRect(),{width:W}=y.getBoundingClientRect(),B=_.clientX-E;let I=h==="left"?(W||0)+(B-o.value):(W||0)-(B-o.value);I=e.minWidth>0?Math.max(e.minWidth,I):I;const M=g();M!=null&&M>0&&(I=M>I?I:M),n.value=I}if((h==="top"||h==="bottom")&&x){const{top:E}=x.getBoundingClientRect(),{height:W}=y.getBoundingClientRect(),B=_.clientY-E;let I=h==="top"?(W||0)+(B-c.value):(W||0)-(B-c.value);I=e.minHeight>0?Math.max(e.minHeight,I):I;const M=b();M!=null&&M>0&&(I=M>I?I:M),u.value=I}r.value=0,d.value=0,o.value=-1,c.value=-1,a.value=!1,s.value=!1,document.removeEventListener("mousemove",v),document.removeEventListener("mouseup",w),document.body.style.userSelect="",h="",y=null,x=null}function k(_,E,W){if(h=E,y=W,a.value=!0,x=_.composedPath().find(I=>I.className.split(" ")[0]==="f-splitter"),x){const{left:I}=x.getBoundingClientRect();r.value=_.clientX-I,o.value=_.clientX-I;const M=g();v=D=>f(D,M,e.minWidth,h),document.addEventListener("mousemove",v),document.addEventListener("mouseup",w),document.body.style.userSelect="none"}}function S(_,E,W){if(h=E,y=W,s.value=!0,x=_.composedPath().find(I=>I.className.split(" ")[0]==="f-splitter"),x){const{top:I}=x.getBoundingClientRect();d.value=_.clientY-I,c.value=_.clientY-I;const M=b();v=D=>l(D,M,e.minHeight,h),document.addEventListener("mousemove",v),document.addEventListener("mouseup",w),document.body.style.userSelect="none"}}return{actualWidth:n,actualHeight:u,onClickSplitterHorizontalResizeBar:k,onClickSplitterVerticalResizeBar:S}}const er=i.defineComponent({name:"FSplitterPane",props:Eh,emits:[],setup(e,t){const n=i.ref(),u=i.inject("splitter"),{useResizeHandleComposition:o}=u,r=_h(e,o),{actualHeight:a,actualWidth:s,onClickSplitterHorizontalResizeBar:c,onClickSplitterVerticalResizeBar:d}=r,f=i.ref(e.position),l=i.computed(()=>{const b={"f-splitter-pane":!0,"f-splitter-pane-main":f.value==="center","has-resize-bar":e.resizable};return b["f-splitter-pane-"+f.value]=!0,be(b,e==null?void 0:e.customClass)}),p=i.computed(()=>e.resizeHandle?e.resizeHandle.split(",").filter(b=>["e","n","s","w"].find(w=>w===b)):[]),m=i.computed(()=>{const b={};return(s.value||s.value===0)&&(f.value==="left"||f.value==="right"||p.value.find(w=>w==="e")||p.value.find(w=>w==="w"))&&(b.width=`${s.value}px`),(a.value||a.value===0)&&(f.value==="bottom"||f.value==="top"||p.value.find(w=>w==="s")||p.value.find(w=>w==="n"))&&(b.height=`${a.value}px`),e.visible||(b.display="none"),Ae(b,e==null?void 0:e.customStyle)}),h=i.computed(()=>({"f-splitter-resize-bar":!0,"f-splitter-resize-bar-e":f.value==="left","f-splitter-resize-bar-n":f.value==="bottom","f-splitter-resize-bar-s":f.value==="top","f-splitter-resize-bar-w":f.value==="right"}));function y(b){return{e:"left",w:"right",s:"top",n:"bottom"}[b]||b}function x(b,w){w=y(w),["left","right"].find(k=>k===w)&&c(b,w,n.value),["top","bottom"].find(k=>k===w)&&d(b,w,n.value)}function v(){return p.value.length>0?p.value.map(b=>i.createVNode("span",{class:"f-splitter-resize-bar f-splitter-resize-bar-"+b,onMousedown:w=>x(w,b)},null)):i.createVNode("span",{class:h.value,onMousedown:b=>x(b,f.value)},null)}function g(){s.value=e.width,a.value=e.height,m.value}return t.expose({reset:g}),()=>i.createVNode("div",{ref:n,class:l.value,style:m.value,"data-position":f.value},[t.slots.default&&t.slots.default(),e.resizable&&v()])}});xn.install=e=>{e.component(xn.name,xn),e.component(er.name,er)};const Ga={previewConfig:{type:Object,default:()=>({})},onClose:{type:Function,default:()=>{}},onIframeLoad:{type:Function,default:()=>{}}},qa={content:{type:String,default:null}},Sh=e=>{const t=typeof e;return t!=="function"&&t!=="object"||e===null},Fh=e=>{const t=e.flags===""?void 0:e.flags;return new RegExp(e.source,t)},tr=(e,t=new WeakMap)=>{if(e===null||Sh(e))return e;if(t.has(e))return t.get(e);if(e instanceof RegExp)return Fh(e);if(e instanceof Date)return new Date(e.getTime());if(e instanceof Function)return e;if(e instanceof Map){const u=new Map;return t.set(e,u),e.forEach((o,r)=>{u.set(r,tr(o,t))}),u}if(e instanceof Set){const u=new Set;t.set(e,u);for(const o of e)u.add(tr(o,t));return u}if(Array.isArray(e)){const u=[];return t.set(e,u),e.forEach(o=>{u.push(tr(o,t))}),u}const n={};t.set(e,n);for(const u in e)Object.prototype.hasOwnProperty.call(e,u)&&(n[u]=tr(e[u],t));return n},Dh=(e,t=200)=>{let n=0;return(...u)=>new Promise(o=>{n&&(clearTimeout(n),o("cancel")),n=window.setTimeout(()=>{e.apply(void 0,u),n=0,o("done")},t)})},mo=()=>`${Date.now().toString(36)}${Math.random().toString(36).substring(2)}`,nu=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),Th=new Set(["__proto__","constructor","prototype"]),Nh=e=>!Th.has(e),go=(e,t,n={})=>{if(Array.isArray(e)&&Array.isArray(t))return bo(e,t,n);const{excludeKeys:u}=n,o=e,r=t;for(const a of Object.keys(r)){if(!Nh(a))continue;const s=r[a],c=o[a];u&&u(a)?o[a]=s:Array.isArray(s)&&Array.isArray(c)?o[a]=bo(c,s,n):nu(s)&&nu(c)?o[a]=go(c,s,n):o[a]=s}return e},bo=(e,t,n)=>{const u=e.slice();return t.forEach((o,r)=>{const a=u[r];Array.isArray(o)&&Array.isArray(a)?u[r]=bo(a,o,n):nu(o)&&nu(a)?u[r]=go(a,o,n):u[r]=o}),u},q="md-editor",de="https://unpkg.com",Lh=`${de}/@highlightjs/cdn-assets@11.11.1/highlight.min.js`,Xa={main:`${de}/prettier@3.8.1/standalone.js`,markdown:`${de}/prettier@3.8.1/plugins/markdown.js`},Oh={css:`${de}/cropperjs@1.6.2/dist/cropper.min.css`,js:`${de}/cropperjs@1.6.2/dist/cropper.min.js`},Ih=`${de}/screenfull@5.2.0/dist/screenfull.js`,Ph=`${de}/mermaid@11.12.3/dist/mermaid.min.js`,Rh={js:`${de}/katex@0.16.33/dist/katex.min.js`,css:`${de}/katex@0.16.33/dist/katex.min.css`},yo={a11y:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/a11y-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/a11y-dark.min.css`},atom:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/atom-one-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/atom-one-dark.min.css`},github:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/github.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/github-dark.min.css`},gradient:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/gradient-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/gradient-dark.min.css`},kimbie:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/kimbie-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/kimbie-dark.min.css`},paraiso:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/paraiso-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/paraiso-dark.min.css`},qtcreator:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/qtcreator-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/qtcreator-dark.min.css`},stackoverflow:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/stackoverflow-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/stackoverflow-dark.min.css`}},Vh=`${de}/echarts@6.0.0/dist/echarts.min.js`,Za={"zh-CN":{toolbarTips:{bold:"加粗",underline:"下划线",italic:"斜体",strikeThrough:"删除线",title:"标题",sub:"下标",sup:"上标",quote:"引用",unorderedList:"无序列表",orderedList:"有序列表",task:"任务列表",codeRow:"行内代码",code:"块级代码",link:"链接",image:"图片",table:"表格",mermaid:"mermaid图",katex:"katex公式",revoke:"后退",next:"前进",save:"保存",prettier:"美化",pageFullscreen:"浏览器全屏",fullscreen:"屏幕全屏",preview:"预览",previewOnly:"仅预览",htmlPreview:"html代码预览",catalog:"目录",github:"源码地址"},titleItem:{h1:"一级标题",h2:"二级标题",h3:"三级标题",h4:"四级标题",h5:"五级标题",h6:"六级标题"},imgTitleItem:{link:"添加链接",upload:"上传图片",clip2upload:"裁剪上传"},linkModalTips:{linkTitle:"添加链接",imageTitle:"添加图片",descLabel:"链接描述:",descLabelPlaceHolder:"请输入描述...",urlLabel:"链接地址:",urlLabelPlaceHolder:"请输入链接...",buttonOK:"确定"},clipModalTips:{title:"裁剪图片上传",buttonUpload:"上传"},copyCode:{text:"复制代码",successTips:"已复制!",failTips:"复制失败!"},mermaid:{flow:"流程图",sequence:"时序图",gantt:"甘特图",class:"类图",state:"状态图",pie:"饼图",relationship:"关系图",journey:"旅程图"},katex:{inline:"行内公式",block:"块级公式"},footer:{markdownTotal:"字数",scrollAuto:"同步滚动"}},"en-US":{toolbarTips:{bold:"bold",underline:"underline",italic:"italic",strikeThrough:"strikeThrough",title:"title",sub:"subscript",sup:"superscript",quote:"quote",unorderedList:"unordered list",orderedList:"ordered list",task:"task list",codeRow:"inline code",code:"block-level code",link:"link",image:"image",table:"table",mermaid:"mermaid",katex:"formula",revoke:"revoke",next:"undo revoke",save:"save",prettier:"prettier",pageFullscreen:"fullscreen in page",fullscreen:"fullscreen",preview:"preview",previewOnly:"preview only",htmlPreview:"html preview",catalog:"catalog",github:"source code"},titleItem:{h1:"Lv1 Heading",h2:"Lv2 Heading",h3:"Lv3 Heading",h4:"Lv4 Heading",h5:"Lv5 Heading",h6:"Lv6 Heading"},imgTitleItem:{link:"Add Image Link",upload:"Upload Images",clip2upload:"Crop And Upload"},linkModalTips:{linkTitle:"Add Link",imageTitle:"Add Image",descLabel:"Desc:",descLabelPlaceHolder:"Enter a description...",urlLabel:"Link:",urlLabelPlaceHolder:"Enter a link...",buttonOK:"OK"},clipModalTips:{title:"Crop Image",buttonUpload:"Upload"},copyCode:{text:"Copy",successTips:"Copied!",failTips:"Copy failed!"},mermaid:{flow:"flow",sequence:"sequence",gantt:"gantt",class:"class",state:"state",pie:"pie",relationship:"relationship",journey:"journey"},katex:{inline:"inline",block:"block"},footer:{markdownTotal:"Character Count",scrollAuto:"Scroll Auto"}}},ut={editorExtensions:{highlight:{js:Lh,css:yo},prettier:{standaloneJs:Xa.main,parserMarkdownJs:Xa.markdown},cropper:{...Oh},screenfull:{js:Ih},mermaid:{js:Ph,enableZoom:!0},katex:{...Rh},echarts:{js:Vh}},editorExtensionsAttrs:{},editorConfig:{languageUserDefined:{},mermaidTemplate:{},renderDelay:500,zIndex:2e4},codeMirrorExtensions:e=>e,markdownItConfig:()=>{},markdownItPlugins:e=>e,mermaidConfig:e=>e,katexConfig:e=>e,echartsConfig:e=>e},Mh=({instance:e,ctx:t,props:n={}},u="default")=>{const o=(e==null?void 0:e.$slots[u])||(t==null?void 0:t.slots[u]);return(o?o(e):"")||n[u]},Bh="buildFinished",xo="errorCatcher",wo="catalogChanged",zh="pushCatalog",Ya="rerender",jh="taskStateChanged";class Hh{constructor(){fe(this,"pools",{})}remove(t,n,u){const o=this.pools[t]&&this.pools[t][n];o&&(this.pools[t][n]=o.filter(r=>r!==u))}clear(t){this.pools[t]={}}on(t,n){return this.pools[t]||(this.pools[t]={}),this.pools[t][n.name]||(this.pools[t][n.name]=[]),this.pools[t][n.name].push(n.callback),this.pools[t][n.name].includes(n.callback)}emit(t,n,...u){this.pools[t]||(this.pools[t]={});const o=this.pools[t][n];o&&o.forEach(r=>{try{r(...u)}catch(a){console.error(`${n} monitor event exception!`,a)}})}}const tt=new Hh,$h=(e,t)=>{if(!e)return e;const n=t.split(`
29
- `),u=['<span rn-wrapper aria-hidden="true">'];return n.forEach(()=>{u.push("<span></span>")}),u.push("</span>"),`<span class="${q}-code-block">${e}</span>${u.join("")}`};async function Ka(e){if(typeof e=="string"){if(window.isSecureContext&&navigator.clipboard)return await navigator.clipboard.writeText(e);{const t=document.createElement("textarea");let n=!1;if(t.value=e,t.style.position="fixed",t.style.opacity=0,t.style.zIndex="-10000",t.style.top="-10000",document.body.appendChild(t),t.select(),n=document.execCommand("copy"),document.body.removeChild(t),n)return;throw new Error('Failed to copy content via "execCommand"!')}}}const Uh={copy:`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-copy ${q}-icon"><rect width="14" height="14" x="8" y="8" rx="2" ry="2"/><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"/></svg>`,"collapse-tips":`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-circle-chevron-left ${q}-icon"><circle cx="12" cy="12" r="10"/><path d="m14 16-4-4 4-4"/></svg>`,pin:`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-pin ${q}-icon"><path d="M12 17v5"/><path d="M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z"/></svg>`,"pin-off":`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-pin-off ${q}-icon"><path d="M12 17v5"/><path d="M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89"/><path d="m2 2 20 20"/><path d="M9 9v1.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h11"/></svg>`,check:`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-check ${q}-icon"><path d="M20 6 9 17l-5-5"/></svg>`},At=(e,t)=>typeof t[e]=="string"?t[e]:Uh[e],Rt=(e,t,n="")=>{var o;const u=document.getElementById(t.id);if(u)n!==""&&(Reflect.get(window,n)?(o=t.onload)==null||o.call(u,new Event("load")):t.onload&&u.addEventListener("load",t.onload));else{const r={...t};r.onload=null;const a=Gh(e,r);t.onload&&a.addEventListener("load",t.onload),document.head.appendChild(a)}},Wh=(e,t)=>{var n;(n=document.getElementById(t.id))==null||n.remove(),Rt(e,t)},Gh=(e,t)=>{const n=document.createElement(e);return Object.keys(t).forEach(u=>{t[u]!==void 0&&(n[u]=t[u])}),n},qh=(e,t)=>{const n=new Map;return e==null||e.forEach(u=>{let o=u.querySelector(`.${q}-mermaid-action`);o?o.querySelector(`.${q}-mermaid-copy`)||o.insertAdjacentHTML("beforeend",`<span class="${q}-mermaid-copy">${At("copy",t.customIcon)}</span>`):(u.insertAdjacentHTML("beforeend",`<div class="${q}-mermaid-action"><span class="${q}-mermaid-copy">${At("copy",t.customIcon)}</span></div>`),o=u.querySelector(`.${q}-mermaid-action`));const r=o.querySelector(`.${q}-mermaid-copy`);let a=-1;const s=()=>{clearTimeout(a),Ka(u.dataset.content||"").then(()=>{r.innerHTML=At("check",t.customIcon)}).catch(()=>{r.innerHTML=At("copy",t.customIcon)}).finally(()=>{a=window.setTimeout(()=>{r.innerHTML=At("copy",t.customIcon)},1500)})};r.addEventListener("click",s),n.set(u,{removeClick:()=>{r.removeEventListener("click",s)}})}),()=>{n.forEach(({removeClick:u})=>{u==null||u()}),n.clear()}},Xh=(()=>{const e=t=>{if(!t)return()=>{};const n=t.firstChild;let u=1,o=0,r=0,a=!1,s,c,d,f=1;const l=()=>{n.style.transform=`translate(${o}px, ${r}px) scale(${u})`},p=w=>{w.touches.length===1?(a=!0,s=w.touches[0].clientX-o,c=w.touches[0].clientY-r):w.touches.length===2&&(d=Math.hypot(w.touches[0].clientX-w.touches[1].clientX,w.touches[0].clientY-w.touches[1].clientY),f=u)},m=w=>{if(w.preventDefault(),a&&w.touches.length===1)o=w.touches[0].clientX-s,r=w.touches[0].clientY-c,l();else if(w.touches.length===2){const k=Math.hypot(w.touches[0].clientX-w.touches[1].clientX,w.touches[0].clientY-w.touches[1].clientY)/d,S=u;u=f*(1+(k-1));const _=(w.touches[0].clientX+w.touches[1].clientX)/2,E=(w.touches[0].clientY+w.touches[1].clientY)/2,W=n.getBoundingClientRect(),B=(_-W.left)/S,I=(E-W.top)/S;o-=B*(u-S),r-=I*(u-S),l()}},h=()=>{a=!1},y=w=>{w.preventDefault();const k=.02,S=u;w.deltaY<0?u+=k:u=Math.max(.1,u-k);const _=n.getBoundingClientRect(),E=w.clientX-_.left,W=w.clientY-_.top;o-=E/S*(u-S),r-=W/S*(u-S),l()},x=w=>{a=!0,s=w.clientX-o,c=w.clientY-r},v=w=>{a&&(o=w.clientX-s,r=w.clientY-c,l())},g=()=>{a=!1},b=()=>{a=!1};return t.addEventListener("touchstart",p,{passive:!1}),t.addEventListener("touchmove",m,{passive:!1}),t.addEventListener("touchend",h),t.addEventListener("wheel",y,{passive:!1}),t.addEventListener("mousedown",x),t.addEventListener("mousemove",v),t.addEventListener("mouseup",g),t.addEventListener("mouseleave",b),()=>{t.removeEventListener("touchstart",p),t.removeEventListener("touchmove",m),t.removeEventListener("touchend",h),t.removeEventListener("wheel",y),t.removeEventListener("mousedown",x),t.removeEventListener("mousemove",v),t.removeEventListener("mouseup",g),t.removeEventListener("mouseleave",b)}};return(t,n)=>{const u=new Map;return t==null||t.forEach(o=>{let r=o.querySelector(`.${q}-mermaid-action`);r?r.querySelector(`.${q}-mermaid-zoom`)||r.insertAdjacentHTML("beforeend",`<span class="${q}-mermaid-zoom">${At("pin-off",n.customIcon)}</span>`):(o.insertAdjacentHTML("beforeend",`<div class="${q}-mermaid-action"><span class="${q}-mermaid-zoom">${At("pin-off",n.customIcon)}</span></div>`),r=o.querySelector(`.${q}-mermaid-action`));const a=r.querySelector(`.${q}-mermaid-zoom`),s=()=>{const c=u.get(o);if(c!=null&&c.removeEvent)c.removeEvent(),o.removeAttribute("data-grab"),u.set(o,{removeClick:c.removeClick}),a.innerHTML=At("pin-off",n.customIcon);else{const d=e(o);o.setAttribute("data-grab",""),u.set(o,{removeEvent:d,removeClick:c==null?void 0:c.removeClick}),a.innerHTML=At("pin",n.customIcon)}};a.addEventListener("click",s),u.set(o,{removeClick:()=>a.removeEventListener("click",s)})}),()=>{u.forEach(({removeEvent:o,removeClick:r})=>{o==null||o(),r==null||r()}),u.clear()}}})(),Qa=new Set([!0,!1,"alt","title"]);function Ja(e,t){return(Array.isArray(e)?e:[]).filter(([n])=>n!==t)}function es(e,t){e&&e.attrs&&(e.attrs=Ja(e.attrs,t))}function Zh(e,t){if(!Qa.has(e))throw new TypeError(`figcaption must be one of: ${[...Qa]}.`);if(e==="alt")return t.content;const n=t.attrs.find(([u])=>u==="title");return Array.isArray(n)&&n[1]?(es(t,"title"),n[1]):void 0}function Yh(e,t){t=t||{},e.core.ruler.before("linkify","image_figures",function(n){let u=1;for(let o=1,r=n.tokens.length;o<r-1;++o){const a=n.tokens[o];if(a.type!=="inline"||!a.children||a.children.length!==1&&a.children.length!==3||a.children.length===1&&a.children[0].type!=="image")continue;if(a.children.length===3){const[d,f,l]=a.children;if(d.type!=="link_open"||f.type!=="image"||l.type!=="link_close")continue}if(o!==0&&n.tokens[o-1].type!=="paragraph_open"||o!==r-1&&n.tokens[o+1].type!=="paragraph_close")continue;const s=n.tokens[o-1];let c;if(s.type="figure_open",s.tag="figure",n.tokens[o+1].type="figure_close",n.tokens[o+1].tag="figure",t.dataType&&n.tokens[o-1].attrPush(["data-type","image"]),t.link&&a.children.length===1){[c]=a.children;const d=new n.Token("link_open","a",1);d.attrPush(["href",c.attrGet("src")]),a.children.unshift(d),a.children.push(new n.Token("link_close","a",-1))}if(c=a.children.length===1?a.children[0]:a.children[1],t.figcaption){const d=Zh(t.figcaption,c);if(d){const[f]=e.parseInline(d,n.env);a.children.push(new n.Token("figcaption_open","figcaption",1)),a.children.push(...f.children),a.children.push(new n.Token("figcaption_close","figcaption",-1)),c.attrs&&(c.attrs=Ja(c.attrs,"title"))}}if(t.copyAttrs&&c.attrs){const d=t.copyAttrs===!0?"":t.copyAttrs;s.attrs=c.attrs.filter(([f])=>f.match(d)).map(f=>Array.from(f))}if(t.tabindex&&(n.tokens[o-1].attrPush(["tabindex",u]),u++),t.lazy&&(c.attrs.some(([d])=>d==="loading")||c.attrs.push(["loading","lazy"])),t.async&&(c.attrs.some(([d])=>d==="decoding")||c.attrs.push(["decoding","async"])),t.classes&&typeof t.classes=="string"){let d=!1;for(let f=0,l=c.attrs.length;f<l&&!d;f++){const p=c.attrs[f];p[0]==="class"&&(p[1]=`${p[1]} ${t.classes}`,d=!0)}d||c.attrs.push(["class",t.classes])}if(t.removeSrc){const d=c.attrs.find(([f])=>f==="src");c.attrs.push(["data-src",d[1]]),es(c,"src")}}})}const Kh=/\\([ \\!"#$%&'()*+,./:;<=>?@[\]^_`{|}~-])/g;function Qh(e,t){const n=e.posMax,u=e.pos;if(e.src.charCodeAt(u)!==126||t||u+2>=n)return!1;e.pos=u+1;let o=!1;for(;e.pos<n;){if(e.src.charCodeAt(e.pos)===126){o=!0;break}e.md.inline.skipToken(e)}if(!o||u+1===e.pos)return e.pos=u,!1;const r=e.src.slice(u+1,e.pos);if(r.match(/(^|[^\\])(\\\\)*\s/))return e.pos=u,!1;e.posMax=e.pos,e.pos=u+1;const a=e.push("sub_open","sub",1);a.markup="~";const s=e.push("text","",0);s.content=r.replace(Kh,"$1");const c=e.push("sub_close","sub",-1);return c.markup="~",e.pos=e.posMax+1,e.posMax=n,!0}function Jh(e){e.inline.ruler.after("emphasis","sub",Qh)}const e1=/\\([ \\!"#$%&'()*+,./:;<=>?@[\]^_`{|}~-])/g;function t1(e,t){const n=e.posMax,u=e.pos;if(e.src.charCodeAt(u)!==94||t||u+2>=n)return!1;e.pos=u+1;let o=!1;for(;e.pos<n;){if(e.src.charCodeAt(e.pos)===94){o=!0;break}e.md.inline.skipToken(e)}if(!o||u+1===e.pos)return e.pos=u,!1;const r=e.src.slice(u+1,e.pos);if(r.match(/(^|[^\\])(\\\\)*\s/))return e.pos=u,!1;e.posMax=e.pos,e.pos=u+1;const a=e.push("sup_open","sup",1);a.markup="^";const s=e.push("text","",0);s.content=r.replace(e1,"$1");const c=e.push("sup_close","sup",-1);return c.markup="^",e.pos=e.posMax+1,e.posMax=n,!0}function n1(e){e.inline.ruler.after("emphasis","sup",t1)}var r1=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,ts=new Set,vo=typeof process=="object"&&process?process:{},ns=(e,t,n,u)=>{typeof vo.emitWarning=="function"?vo.emitWarning(e,t,n,u):console.error(`[${n}] ${t}: ${e}`)},ru=globalThis.AbortController,rs=globalThis.AbortSignal;if(typeof ru>"u"){rs=class{constructor(){fe(this,"onabort");fe(this,"_onabort",[]);fe(this,"reason");fe(this,"aborted",!1)}addEventListener(n,u){this._onabort.push(u)}},ru=class{constructor(){fe(this,"signal",new rs);t()}abort(n){var u,o;if(!this.signal.aborted){this.signal.reason=n,this.signal.aborted=!0;for(let r of this.signal._onabort)r(n);(o=(u=this.signal).onabort)==null||o.call(u,n)}}};let e=((xc=vo.env)==null?void 0:xc.LRU_CACHE_IGNORE_AC_WARNING)!=="1",t=()=>{e&&(e=!1,ns("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",t))}}var u1=e=>!ts.has(e),Vt=e=>e&&e===Math.floor(e)&&e>0&&isFinite(e),us=e=>Vt(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?uu:null:null,uu=class extends Array{constructor(t){super(t),this.fill(0)}},o1=(kt=class{constructor(t,n){fe(this,"heap");fe(this,"length");if(!A(kt,kn))throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new n(t),this.length=0}static create(t){let n=us(t);if(!n)return[];ee(kt,kn,!0);let u=new kt(t,n);return ee(kt,kn,!1),u}push(t){this.heap[this.length++]=t}pop(){return this.heap[--this.length]}},kn=new WeakMap,ie(kt,kn,!1),kt),i1=(Fn=class{constructor(t){ie(this,G);ie(this,nt);ie(this,Ze);ie(this,ot);ie(this,en);ie(this,it);ie(this,Cn);ie(this,En);ie(this,at);fe(this,"ttl");fe(this,"ttlResolution");fe(this,"ttlAutopurge");fe(this,"updateAgeOnGet");fe(this,"updateAgeOnHas");fe(this,"allowStale");fe(this,"noDisposeOnSet");fe(this,"noUpdateTTL");fe(this,"maxEntrySize");fe(this,"sizeCalculation");fe(this,"noDeleteOnFetchRejection");fe(this,"noDeleteOnStaleGet");fe(this,"allowStaleOnFetchAbort");fe(this,"allowStaleOnFetchRejection");fe(this,"ignoreFetchAbort");ie(this,ke);ie(this,st);ie(this,we);ie(this,he);ie(this,ne);ie(this,ze);ie(this,Ye);ie(this,Ie);ie(this,Se);ie(this,ct);ie(this,Fe);ie(this,lt);ie(this,dt);ie(this,Ke);ie(this,Qe);ie(this,ft);ie(this,jt);ie(this,je);ie(this,_n);ie(this,tn,()=>{});ie(this,_t,()=>{});ie(this,wr,()=>{});ie(this,Je,()=>!1);ie(this,nn,t=>{});ie(this,Sn,(t,n,u)=>{});ie(this,vr,(t,n,u,o)=>{if(u||o)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0});fe(this,wc,"LRUCache");let{max:n=0,ttl:u,ttlResolution:o=1,ttlAutopurge:r,updateAgeOnGet:a,updateAgeOnHas:s,allowStale:c,dispose:d,onInsert:f,disposeAfter:l,noDisposeOnSet:p,noUpdateTTL:m,maxSize:h=0,maxEntrySize:y=0,sizeCalculation:x,fetchMethod:v,memoMethod:g,noDeleteOnFetchRejection:b,noDeleteOnStaleGet:w,allowStaleOnFetchRejection:k,allowStaleOnFetchAbort:S,ignoreFetchAbort:_,perf:E}=t;if(E!==void 0&&typeof(E==null?void 0:E.now)!="function")throw new TypeError("perf option must have a now() method if specified");if(ee(this,at,E??r1),n!==0&&!Vt(n))throw new TypeError("max option must be a nonnegative integer");let W=n?us(n):Array;if(!W)throw new Error("invalid max value: "+n);if(ee(this,nt,n),ee(this,Ze,h),this.maxEntrySize=y||A(this,Ze),this.sizeCalculation=x,this.sizeCalculation){if(!A(this,Ze)&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(g!==void 0&&typeof g!="function")throw new TypeError("memoMethod must be a function if defined");if(ee(this,En,g),v!==void 0&&typeof v!="function")throw new TypeError("fetchMethod must be a function if specified");if(ee(this,Cn,v),ee(this,jt,!!v),ee(this,we,new Map),ee(this,he,new Array(n).fill(void 0)),ee(this,ne,new Array(n).fill(void 0)),ee(this,ze,new W(n)),ee(this,Ye,new W(n)),ee(this,Ie,0),ee(this,Se,0),ee(this,ct,o1.create(n)),ee(this,ke,0),ee(this,st,0),typeof d=="function"&&ee(this,ot,d),typeof f=="function"&&ee(this,en,f),typeof l=="function"?(ee(this,it,l),ee(this,Fe,[])):(ee(this,it,void 0),ee(this,Fe,void 0)),ee(this,ft,!!A(this,ot)),ee(this,_n,!!A(this,en)),ee(this,je,!!A(this,it)),this.noDisposeOnSet=!!p,this.noUpdateTTL=!!m,this.noDeleteOnFetchRejection=!!b,this.allowStaleOnFetchRejection=!!k,this.allowStaleOnFetchAbort=!!S,this.ignoreFetchAbort=!!_,this.maxEntrySize!==0){if(A(this,Ze)!==0&&!Vt(A(this,Ze)))throw new TypeError("maxSize must be a positive integer if specified");if(!Vt(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");X(this,G,zc).call(this)}if(this.allowStale=!!c,this.noDeleteOnStaleGet=!!w,this.updateAgeOnGet=!!a,this.updateAgeOnHas=!!s,this.ttlResolution=Vt(o)||o===0?o:1,this.ttlAutopurge=!!r,this.ttl=u||0,this.ttl){if(!Vt(this.ttl))throw new TypeError("ttl must be a positive integer if specified");X(this,G,Jo).call(this)}if(A(this,nt)===0&&this.ttl===0&&A(this,Ze)===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!A(this,nt)&&!A(this,Ze)){let B="LRU_CACHE_UNBOUNDED";u1(B)&&(ts.add(B),ns("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",B,Fn))}}get perf(){return A(this,at)}static unsafeExposeInternals(t){return{starts:A(t,dt),ttls:A(t,Ke),autopurgeTimers:A(t,Qe),sizes:A(t,lt),keyMap:A(t,we),keyList:A(t,he),valList:A(t,ne),next:A(t,ze),prev:A(t,Ye),get head(){return A(t,Ie)},get tail(){return A(t,Se)},free:A(t,ct),isBackgroundFetch:n=>{var u;return X(u=t,G,pe).call(u,n)},backgroundFetch:(n,u,o,r)=>{var a;return X(a=t,G,Cu).call(a,n,u,o,r)},moveToTail:n=>{var u;return X(u=t,G,Cr).call(u,n)},indexes:n=>{var u;return X(u=t,G,$t).call(u,n)},rindexes:n=>{var u;return X(u=t,G,Ut).call(u,n)},isStale:n=>{var u;return A(u=t,Je).call(u,n)}}}get max(){return A(this,nt)}get maxSize(){return A(this,Ze)}get calculatedSize(){return A(this,st)}get size(){return A(this,ke)}get fetchMethod(){return A(this,Cn)}get memoMethod(){return A(this,En)}get dispose(){return A(this,ot)}get onInsert(){return A(this,en)}get disposeAfter(){return A(this,it)}getRemainingTTL(t){return A(this,we).has(t)?1/0:0}*entries(){for(let t of X(this,G,$t).call(this))A(this,ne)[t]!==void 0&&A(this,he)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield[A(this,he)[t],A(this,ne)[t]])}*rentries(){for(let t of X(this,G,Ut).call(this))A(this,ne)[t]!==void 0&&A(this,he)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield[A(this,he)[t],A(this,ne)[t]])}*keys(){for(let t of X(this,G,$t).call(this)){let n=A(this,he)[t];n!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield n)}}*rkeys(){for(let t of X(this,G,Ut).call(this)){let n=A(this,he)[t];n!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield n)}}*values(){for(let t of X(this,G,$t).call(this))A(this,ne)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield A(this,ne)[t])}*rvalues(){for(let t of X(this,G,Ut).call(this))A(this,ne)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield A(this,ne)[t])}[(vc=Symbol.iterator,wc=Symbol.toStringTag,vc)](){return this.entries()}find(t,n={}){for(let u of X(this,G,$t).call(this)){let o=A(this,ne)[u],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;if(r!==void 0&&t(r,A(this,he)[u],this))return this.get(A(this,he)[u],n)}}forEach(t,n=this){for(let u of X(this,G,$t).call(this)){let o=A(this,ne)[u],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;r!==void 0&&t.call(n,r,A(this,he)[u],this)}}rforEach(t,n=this){for(let u of X(this,G,Ut).call(this)){let o=A(this,ne)[u],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;r!==void 0&&t.call(n,r,A(this,he)[u],this)}}purgeStale(){let t=!1;for(let n of X(this,G,Ut).call(this,{allowStale:!0}))A(this,Je).call(this,n)&&(X(this,G,Wt).call(this,A(this,he)[n],"expire"),t=!0);return t}info(t){let n=A(this,we).get(t);if(n===void 0)return;let u=A(this,ne)[n],o=X(this,G,pe).call(this,u)?u.__staleWhileFetching:u;if(o===void 0)return;let r={value:o};if(A(this,Ke)&&A(this,dt)){let a=A(this,Ke)[n],s=A(this,dt)[n];if(a&&s){let c=a-(A(this,at).now()-s);r.ttl=c,r.start=Date.now()}}return A(this,lt)&&(r.size=A(this,lt)[n]),r}dump(){let t=[];for(let n of X(this,G,$t).call(this,{allowStale:!0})){let u=A(this,he)[n],o=A(this,ne)[n],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;if(r===void 0||u===void 0)continue;let a={value:r};if(A(this,Ke)&&A(this,dt)){a.ttl=A(this,Ke)[n];let s=A(this,at).now()-A(this,dt)[n];a.start=Math.floor(Date.now()-s)}A(this,lt)&&(a.size=A(this,lt)[n]),t.unshift([u,a])}return t}load(t){this.clear();for(let[n,u]of t){if(u.start){let o=Date.now()-u.start;u.start=A(this,at).now()-o}this.set(n,u.value,u)}}set(t,n,u={}){var p,m,h,y,x,v,g;if(n===void 0)return this.delete(t),this;let{ttl:o=this.ttl,start:r,noDisposeOnSet:a=this.noDisposeOnSet,sizeCalculation:s=this.sizeCalculation,status:c}=u,{noUpdateTTL:d=this.noUpdateTTL}=u,f=A(this,vr).call(this,t,n,u.size||0,s);if(this.maxEntrySize&&f>this.maxEntrySize)return c&&(c.set="miss",c.maxEntrySizeExceeded=!0),X(this,G,Wt).call(this,t,"set"),this;let l=A(this,ke)===0?void 0:A(this,we).get(t);if(l===void 0)l=A(this,ke)===0?A(this,Se):A(this,ct).length!==0?A(this,ct).pop():A(this,ke)===A(this,nt)?X(this,G,ku).call(this,!1):A(this,ke),A(this,he)[l]=t,A(this,ne)[l]=n,A(this,we).set(t,l),A(this,ze)[A(this,Se)]=l,A(this,Ye)[l]=A(this,Se),ee(this,Se,l),Au(this,ke)._++,A(this,Sn).call(this,l,f,c),c&&(c.set="add"),d=!1,A(this,_n)&&((p=A(this,en))==null||p.call(this,n,t,"add"));else{X(this,G,Cr).call(this,l);let b=A(this,ne)[l];if(n!==b){if(A(this,jt)&&X(this,G,pe).call(this,b)){b.__abortController.abort(new Error("replaced"));let{__staleWhileFetching:w}=b;w!==void 0&&!a&&(A(this,ft)&&((m=A(this,ot))==null||m.call(this,w,t,"set")),A(this,je)&&((h=A(this,Fe))==null||h.push([w,t,"set"])))}else a||(A(this,ft)&&((y=A(this,ot))==null||y.call(this,b,t,"set")),A(this,je)&&((x=A(this,Fe))==null||x.push([b,t,"set"])));if(A(this,nn).call(this,l),A(this,Sn).call(this,l,f,c),A(this,ne)[l]=n,c){c.set="replace";let w=b&&X(this,G,pe).call(this,b)?b.__staleWhileFetching:b;w!==void 0&&(c.oldValue=w)}}else c&&(c.set="update");A(this,_n)&&((v=this.onInsert)==null||v.call(this,n,t,n===b?"update":"replace"))}if(o!==0&&!A(this,Ke)&&X(this,G,Jo).call(this),A(this,Ke)&&(d||A(this,wr).call(this,l,o,r),c&&A(this,_t).call(this,c,l)),!a&&A(this,je)&&A(this,Fe)){let b=A(this,Fe),w;for(;w=b==null?void 0:b.shift();)(g=A(this,it))==null||g.call(this,...w)}return this}pop(){var t;try{for(;A(this,ke);){let n=A(this,ne)[A(this,Ie)];if(X(this,G,ku).call(this,!0),X(this,G,pe).call(this,n)){if(n.__staleWhileFetching)return n.__staleWhileFetching}else if(n!==void 0)return n}}finally{if(A(this,je)&&A(this,Fe)){let n=A(this,Fe),u;for(;u=n==null?void 0:n.shift();)(t=A(this,it))==null||t.call(this,...u)}}}has(t,n={}){let{updateAgeOnHas:u=this.updateAgeOnHas,status:o}=n,r=A(this,we).get(t);if(r!==void 0){let a=A(this,ne)[r];if(X(this,G,pe).call(this,a)&&a.__staleWhileFetching===void 0)return!1;if(A(this,Je).call(this,r))o&&(o.has="stale",A(this,_t).call(this,o,r));else return u&&A(this,tn).call(this,r),o&&(o.has="hit",A(this,_t).call(this,o,r)),!0}else o&&(o.has="miss");return!1}peek(t,n={}){let{allowStale:u=this.allowStale}=n,o=A(this,we).get(t);if(o===void 0||!u&&A(this,Je).call(this,o))return;let r=A(this,ne)[o];return X(this,G,pe).call(this,r)?r.__staleWhileFetching:r}async fetch(t,n={}){let{allowStale:u=this.allowStale,updateAgeOnGet:o=this.updateAgeOnGet,noDeleteOnStaleGet:r=this.noDeleteOnStaleGet,ttl:a=this.ttl,noDisposeOnSet:s=this.noDisposeOnSet,size:c=0,sizeCalculation:d=this.sizeCalculation,noUpdateTTL:f=this.noUpdateTTL,noDeleteOnFetchRejection:l=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:p=this.allowStaleOnFetchRejection,ignoreFetchAbort:m=this.ignoreFetchAbort,allowStaleOnFetchAbort:h=this.allowStaleOnFetchAbort,context:y,forceRefresh:x=!1,status:v,signal:g}=n;if(!A(this,jt))return v&&(v.fetch="get"),this.get(t,{allowStale:u,updateAgeOnGet:o,noDeleteOnStaleGet:r,status:v});let b={allowStale:u,updateAgeOnGet:o,noDeleteOnStaleGet:r,ttl:a,noDisposeOnSet:s,size:c,sizeCalculation:d,noUpdateTTL:f,noDeleteOnFetchRejection:l,allowStaleOnFetchRejection:p,allowStaleOnFetchAbort:h,ignoreFetchAbort:m,status:v,signal:g},w=A(this,we).get(t);if(w===void 0){v&&(v.fetch="miss");let k=X(this,G,Cu).call(this,t,w,b,y);return k.__returned=k}else{let k=A(this,ne)[w];if(X(this,G,pe).call(this,k)){let W=u&&k.__staleWhileFetching!==void 0;return v&&(v.fetch="inflight",W&&(v.returnedStale=!0)),W?k.__staleWhileFetching:k.__returned=k}let S=A(this,Je).call(this,w);if(!x&&!S)return v&&(v.fetch="hit"),X(this,G,Cr).call(this,w),o&&A(this,tn).call(this,w),v&&A(this,_t).call(this,v,w),k;let _=X(this,G,Cu).call(this,t,w,b,y),E=_.__staleWhileFetching!==void 0&&u;return v&&(v.fetch=S?"stale":"refresh",E&&S&&(v.returnedStale=!0)),E?_.__staleWhileFetching:_.__returned=_}}async forceFetch(t,n={}){let u=await this.fetch(t,n);if(u===void 0)throw new Error("fetch() returned undefined");return u}memo(t,n={}){let u=A(this,En);if(!u)throw new Error("no memoMethod provided to constructor");let{context:o,forceRefresh:r,...a}=n,s=this.get(t,a);if(!r&&s!==void 0)return s;let c=u(t,s,{options:a,context:o});return this.set(t,c,a),c}get(t,n={}){let{allowStale:u=this.allowStale,updateAgeOnGet:o=this.updateAgeOnGet,noDeleteOnStaleGet:r=this.noDeleteOnStaleGet,status:a}=n,s=A(this,we).get(t);if(s!==void 0){let c=A(this,ne)[s],d=X(this,G,pe).call(this,c);return a&&A(this,_t).call(this,a,s),A(this,Je).call(this,s)?(a&&(a.get="stale"),d?(a&&u&&c.__staleWhileFetching!==void 0&&(a.returnedStale=!0),u?c.__staleWhileFetching:void 0):(r||X(this,G,Wt).call(this,t,"expire"),a&&u&&(a.returnedStale=!0),u?c:void 0)):(a&&(a.get="hit"),d?c.__staleWhileFetching:(X(this,G,Cr).call(this,s),o&&A(this,tn).call(this,s),c))}else a&&(a.get="miss")}delete(t){return X(this,G,Wt).call(this,t,"delete")}clear(){return X(this,G,ni).call(this,"delete")}},nt=new WeakMap,Ze=new WeakMap,ot=new WeakMap,en=new WeakMap,it=new WeakMap,Cn=new WeakMap,En=new WeakMap,at=new WeakMap,ke=new WeakMap,st=new WeakMap,we=new WeakMap,he=new WeakMap,ne=new WeakMap,ze=new WeakMap,Ye=new WeakMap,Ie=new WeakMap,Se=new WeakMap,ct=new WeakMap,Fe=new WeakMap,lt=new WeakMap,dt=new WeakMap,Ke=new WeakMap,Qe=new WeakMap,ft=new WeakMap,jt=new WeakMap,je=new WeakMap,_n=new WeakMap,G=new WeakSet,Jo=function(){let t=new uu(A(this,nt)),n=new uu(A(this,nt));ee(this,Ke,t),ee(this,dt,n);let u=this.ttlAutopurge?new Array(A(this,nt)):void 0;ee(this,Qe,u),ee(this,wr,(s,c,d=A(this,at).now())=>{n[s]=c!==0?d:0,t[s]=c,o(s,c)}),ee(this,tn,s=>{n[s]=t[s]!==0?A(this,at).now():0,o(s,t[s])});let o=this.ttlAutopurge?(s,c)=>{if(u!=null&&u[s]&&(clearTimeout(u[s]),u[s]=void 0),c&&c!==0&&u){let d=setTimeout(()=>{A(this,Je).call(this,s)&&X(this,G,Wt).call(this,A(this,he)[s],"expire")},c+1);d.unref&&d.unref(),u[s]=d}}:()=>{};ee(this,_t,(s,c)=>{if(t[c]){let d=t[c],f=n[c];if(!d||!f)return;s.ttl=d,s.start=f,s.now=r||a();let l=s.now-f;s.remainingTTL=d-l}});let r=0,a=()=>{let s=A(this,at).now();if(this.ttlResolution>0){r=s;let c=setTimeout(()=>r=0,this.ttlResolution);c.unref&&c.unref()}return s};this.getRemainingTTL=s=>{let c=A(this,we).get(s);if(c===void 0)return 0;let d=t[c],f=n[c];if(!d||!f)return 1/0;let l=(r||a())-f;return d-l},ee(this,Je,s=>{let c=n[s],d=t[s];return!!d&&!!c&&(r||a())-c>d})},tn=new WeakMap,_t=new WeakMap,wr=new WeakMap,Je=new WeakMap,zc=function(){let t=new uu(A(this,nt));ee(this,st,0),ee(this,lt,t),ee(this,nn,n=>{ee(this,st,A(this,st)-t[n]),t[n]=0}),ee(this,vr,(n,u,o,r)=>{if(X(this,G,pe).call(this,u))return 0;if(!Vt(o))if(r){if(typeof r!="function")throw new TypeError("sizeCalculation must be a function");if(o=r(u,n),!Vt(o))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return o}),ee(this,Sn,(n,u,o)=>{if(t[n]=u,A(this,Ze)){let r=A(this,Ze)-t[n];for(;A(this,st)>r;)X(this,G,ku).call(this,!0)}ee(this,st,A(this,st)+t[n]),o&&(o.entrySize=u,o.totalCalculatedSize=A(this,st))})},nn=new WeakMap,Sn=new WeakMap,vr=new WeakMap,$t=function*({allowStale:t=this.allowStale}={}){if(A(this,ke))for(let n=A(this,Se);!(!X(this,G,ei).call(this,n)||((t||!A(this,Je).call(this,n))&&(yield n),n===A(this,Ie)));)n=A(this,Ye)[n]},Ut=function*({allowStale:t=this.allowStale}={}){if(A(this,ke))for(let n=A(this,Ie);!(!X(this,G,ei).call(this,n)||((t||!A(this,Je).call(this,n))&&(yield n),n===A(this,Se)));)n=A(this,ze)[n]},ei=function(t){return t!==void 0&&A(this,we).get(A(this,he)[t])===t},ku=function(t){var r,a,s;let n=A(this,Ie),u=A(this,he)[n],o=A(this,ne)[n];return A(this,jt)&&X(this,G,pe).call(this,o)?o.__abortController.abort(new Error("evicted")):(A(this,ft)||A(this,je))&&(A(this,ft)&&((r=A(this,ot))==null||r.call(this,o,u,"evict")),A(this,je)&&((a=A(this,Fe))==null||a.push([o,u,"evict"]))),A(this,nn).call(this,n),(s=A(this,Qe))!=null&&s[n]&&(clearTimeout(A(this,Qe)[n]),A(this,Qe)[n]=void 0),t&&(A(this,he)[n]=void 0,A(this,ne)[n]=void 0,A(this,ct).push(n)),A(this,ke)===1?(ee(this,Ie,ee(this,Se,0)),A(this,ct).length=0):ee(this,Ie,A(this,ze)[n]),A(this,we).delete(u),Au(this,ke)._--,n},Cu=function(t,n,u,o){let r=n===void 0?void 0:A(this,ne)[n];if(X(this,G,pe).call(this,r))return r;let a=new ru,{signal:s}=u;s==null||s.addEventListener("abort",()=>a.abort(s.reason),{signal:a.signal});let c={signal:a.signal,options:u,context:o},d=(y,x=!1)=>{let{aborted:v}=a.signal,g=u.ignoreFetchAbort&&y!==void 0,b=u.ignoreFetchAbort||!!(u.allowStaleOnFetchAbort&&y!==void 0);if(u.status&&(v&&!x?(u.status.fetchAborted=!0,u.status.fetchError=a.signal.reason,g&&(u.status.fetchAbortIgnored=!0)):u.status.fetchResolved=!0),v&&!g&&!x)return l(a.signal.reason,b);let w=m,k=A(this,ne)[n];return(k===m||g&&x&&k===void 0)&&(y===void 0?w.__staleWhileFetching!==void 0?A(this,ne)[n]=w.__staleWhileFetching:X(this,G,Wt).call(this,t,"fetch"):(u.status&&(u.status.fetchUpdated=!0),this.set(t,y,c.options))),y},f=y=>(u.status&&(u.status.fetchRejected=!0,u.status.fetchError=y),l(y,!1)),l=(y,x)=>{let{aborted:v}=a.signal,g=v&&u.allowStaleOnFetchAbort,b=g||u.allowStaleOnFetchRejection,w=b||u.noDeleteOnFetchRejection,k=m;if(A(this,ne)[n]===m&&(!w||!x&&k.__staleWhileFetching===void 0?X(this,G,Wt).call(this,t,"fetch"):g||(A(this,ne)[n]=k.__staleWhileFetching)),b)return u.status&&k.__staleWhileFetching!==void 0&&(u.status.returnedStale=!0),k.__staleWhileFetching;if(k.__returned===k)throw y},p=(y,x)=>{var g;let v=(g=A(this,Cn))==null?void 0:g.call(this,t,r,c);v&&v instanceof Promise&&v.then(b=>y(b===void 0?void 0:b),x),a.signal.addEventListener("abort",()=>{(!u.ignoreFetchAbort||u.allowStaleOnFetchAbort)&&(y(void 0),u.allowStaleOnFetchAbort&&(y=b=>d(b,!0)))})};u.status&&(u.status.fetchDispatched=!0);let m=new Promise(p).then(d,f),h=Object.assign(m,{__abortController:a,__staleWhileFetching:r,__returned:void 0});return n===void 0?(this.set(t,h,{...c.options,status:void 0}),n=A(this,we).get(t)):A(this,ne)[n]=h,h},pe=function(t){if(!A(this,jt))return!1;let n=t;return!!n&&n instanceof Promise&&n.hasOwnProperty("__staleWhileFetching")&&n.__abortController instanceof ru},ti=function(t,n){A(this,Ye)[n]=t,A(this,ze)[t]=n},Cr=function(t){t!==A(this,Se)&&(t===A(this,Ie)?ee(this,Ie,A(this,ze)[t]):X(this,G,ti).call(this,A(this,Ye)[t],A(this,ze)[t]),X(this,G,ti).call(this,A(this,Se),t),ee(this,Se,t))},Wt=function(t,n){var o,r,a,s,c,d;let u=!1;if(A(this,ke)!==0){let f=A(this,we).get(t);if(f!==void 0)if((o=A(this,Qe))!=null&&o[f]&&(clearTimeout((r=A(this,Qe))==null?void 0:r[f]),A(this,Qe)[f]=void 0),u=!0,A(this,ke)===1)X(this,G,ni).call(this,n);else{A(this,nn).call(this,f);let l=A(this,ne)[f];if(X(this,G,pe).call(this,l)?l.__abortController.abort(new Error("deleted")):(A(this,ft)||A(this,je))&&(A(this,ft)&&((a=A(this,ot))==null||a.call(this,l,t,n)),A(this,je)&&((s=A(this,Fe))==null||s.push([l,t,n]))),A(this,we).delete(t),A(this,he)[f]=void 0,A(this,ne)[f]=void 0,f===A(this,Se))ee(this,Se,A(this,Ye)[f]);else if(f===A(this,Ie))ee(this,Ie,A(this,ze)[f]);else{let p=A(this,Ye)[f];A(this,ze)[p]=A(this,ze)[f];let m=A(this,ze)[f];A(this,Ye)[m]=A(this,Ye)[f]}Au(this,ke)._--,A(this,ct).push(f)}}if(A(this,je)&&((c=A(this,Fe))!=null&&c.length)){let f=A(this,Fe),l;for(;l=f==null?void 0:f.shift();)(d=A(this,it))==null||d.call(this,...l)}return u},ni=function(t){var n,u,o,r;for(let a of X(this,G,Ut).call(this,{allowStale:!0})){let s=A(this,ne)[a];if(X(this,G,pe).call(this,s))s.__abortController.abort(new Error("deleted"));else{let c=A(this,he)[a];A(this,ft)&&((n=A(this,ot))==null||n.call(this,s,c,t)),A(this,je)&&((u=A(this,Fe))==null||u.push([s,c,t]))}}if(A(this,we).clear(),A(this,ne).fill(void 0),A(this,he).fill(void 0),A(this,Ke)&&A(this,dt)){A(this,Ke).fill(0),A(this,dt).fill(0);for(let a of A(this,Qe)??[])a!==void 0&&clearTimeout(a);(o=A(this,Qe))==null||o.fill(void 0)}if(A(this,lt)&&A(this,lt).fill(0),ee(this,Ie,0),ee(this,Se,0),A(this,ct).length=0,ee(this,st,0),ee(this,ke,0),A(this,je)&&A(this,Fe)){let a=A(this,Fe),s;for(;s=a==null?void 0:a.shift();)(r=A(this,it))==null||r.call(this,...s)}},Fn);/*! medium-zoom 1.1.0 | MIT License | https://github.com/francoischalifour/medium-zoom */var Zt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var u in n)Object.prototype.hasOwnProperty.call(n,u)&&(e[u]=n[u])}return e},ou=function(t){return t.tagName==="IMG"},a1=function(t){return NodeList.prototype.isPrototypeOf(t)},iu=function(t){return t&&t.nodeType===1},os=function(t){var n=t.currentSrc||t.src;return n.substr(-4).toLowerCase()===".svg"},is=function(t){try{return Array.isArray(t)?t.filter(ou):a1(t)?[].slice.call(t).filter(ou):iu(t)?[t].filter(ou):typeof t=="string"?[].slice.call(document.querySelectorAll(t)).filter(ou):[]}catch{throw new TypeError(`The provided selector is invalid.
28
+ `;return ao("caf-assistant-widget-container__error",g)}),m=()=>{const g=a.value;g&&(s.value=new oh(g))},h=()=>{const g=s.value;g&&(g.dispose(),s.value=null)},x=()=>{const g=r.value,b=o.value;g&&(g.unmount(),g.dispose()),b&&b.cleanup(),r.value=null,o.value=null},y=async()=>{const g=await n(e.widgetAPIURL);if(!g)throw new Error("Failed to load widget API");await g.initialize();const b=g.createWidget();o.value=g,r.value=b},v=g=>{console.error(g),c.value=g};return i.watch(()=>e.widgetAPIURL,async()=>{if(a.value)try{x(),await y();const g=a.value,b=r.value;b==null||b.updateOptions(e.widgetOptions),b==null||b.updateData(e.widgetData),g&&b&&await b.mount(g)}catch(g){v(g)}}),i.watch(()=>e.widgetOptions,(g,b)=>{try{const w=r.value;w&&(!b||!u(b,g))&&w.updateOptions(g)}catch(w){v(w)}}),i.watch(()=>e.widgetData,(g,b)=>{try{const w=r.value;w&&(!b||!u(b,g))&&w.updateData(g)}catch(w){v(w)}}),i.onMounted(async()=>{try{const g=a.value;if(g){m();const b=s.value;if(b){await y();const w=r.value;w&&(w.updateOptions(e.widgetOptions),w.updateData(e.widgetData),w.mount(b.getElement()),i.nextTick(()=>{g.parentElement&&(g.style.width="100%")}))}}}catch(g){v(g)}}),i.onBeforeUnmount(async()=>{try{x(),h()}catch(g){console.error(g)}}),()=>i.createVNode("div",{class:d.value},[i.createVNode("div",{ref:a,class:l},null),i.createVNode("div",{class:p.value},null)])}}),Fa=(e,t)=>{var n;if(e.type===ke.AssistantWidgetComplete){const u=e;return u.widgetUrl?i.createVNode(gn,{key:`widget-${t}`,widgetAPIURL:u.widgetUrl,widgetOptions:{mode:"embedded",implOptions:u.widgetImplOptions},widgetData:((n=u.widgetData)==null?void 0:n.data)||{}},null):null}return e.type===ke.AssistantWidgetPending?i.createVNode("div",{class:"f-chat-bubble-widget-pending",key:`widget-loading-${t}`},[i.createVNode("span",{class:"f-chat-todo-status-icon f-chat-todo-status-working"},null),i.createVNode("span",{class:"f-chat-bubble-widget-pending-text"},[i.createTextVNode("数据生成中......")])]):null},ch=3e4,At=new Map,Yn=new Map,Kn=new Map;function co(e){try{return JSON.parse(JSON.stringify(e))}catch{return{...e}}}function Da(e,t){if(typeof e.onAssistantMessage!="function")return!0;try{return e.onAssistantMessage(co(t)),!0}catch(n){return console.warn("[DynamicComponent] onAssistantMessage failed",n),!1}}function lh(e){const t=`fluens-dynamic-component-${e.instanceId}`;let n=document.getElementById(t);return n||(n=document.createElement("div"),n.id=t,n.style.width="100%",n.style.height="100%"),n}function Ta(e){const t=Yn.get(e.instanceId);if(t)return Promise.resolve(t.api);const n=At.get(e.instanceId);if(n)return new Promise((o,r)=>{const a=n.resolve,s=n.reject;n.resolve=c=>{a(c),o(c)},n.reject=c=>{s(c),r(c)}});if((e.name||e.componentId)&&!e.jsUrl)return Promise.reject(new Error(`Dynamic component resource is empty: ${e.name||e.componentId}`));const u=lh(e);return new Promise((o,r)=>{const a=setTimeout(()=>{At.delete(e.instanceId),r(new Error(`Dynamic component script load timeout: ${e.name||e.componentId}`))},ch),s={config:e,container:u,resolve:o,reject:r,timeoutId:a};At.set(e.instanceId,s);const c=document.createElement("script");c.src=(e==null?void 0:e.jsUrl)??"",c.dataset.dynamicComponentId=e.instanceId,c.onload=()=>{setTimeout(()=>{At.has(e.instanceId)&&(clearTimeout(a),At.delete(e.instanceId),r(new Error(`Dynamic component did not call __fluens_dynamic_component_register: ${e.name||e.componentId}`)))},200)},c.onerror=()=>{clearTimeout(a),At.delete(e.instanceId),r(new Error(`Failed to load dynamic component: ${e.name||e.componentId}`))},document.head.appendChild(c)})}function Na(e){var o;const t=Yn.get(e);if(t){try{t.api.unmount()}catch{}(o=t.scriptElement)==null||o.remove(),Yn.delete(e)}const n=At.get(e);n&&(clearTimeout(n.timeoutId),At.delete(e)),Kn.delete(e);const u=document.getElementById(`fluens-dynamic-component-${e}`);u&&u.remove()}function dh(e,t){const n=String(e??"").trim();if(!n)return!1;const u=Yn.get(n);if(u)return Da(u.api,t);const o=Kn.get(n)??[],r=o.findIndex(a=>a.messageId===t.messageId);return r>=0?o[r]=co(t):o.push(co(t)),Kn.set(n,o),!1}typeof window<"u"&&(window.__fluens_dynamic_component_register=function(e,t){const n=At.get(e);if(!n){console.warn(`Failed to read data in pending dynamic component: ${e}`);return}clearTimeout(n.timeoutId),At.delete(e);const u={config:n.config,container:n.container,api:t,scriptElement:document.currentScript};Yn.set(e,u),u.container.parentElement;try{t.mount(n.container,n.config)}catch(r){console.error(`Failed to mount dynamic component: ${e}`,r)}const o=Kn.get(e);o&&o.length>0&&(Kn.delete(e),o.forEach(r=>Da(t,r))),n.resolve(t)});const bn=i.defineComponent({name:"FXDynamicComponent",props:{config:{type:Object,required:!0}},setup(e){const t=i.ref("loading"),n=i.ref(""),u=i.computed(()=>`fluens-dynamic-component-${e.config.instanceId}`),o=i.computed(()=>e.config.position==="inline"),r=i.computed(()=>!e.config.jsUrl&&!!e.config.url),a=i.computed(()=>({width:"fit-content",maxWidth:"100%",height:"auto",...t.value==="ready"&&o.value?{padding:"16px 0"}:{},...t.value==="ready"&&!o.value?{height:"100%",overflow:"hidden"}:{}}));return i.onMounted(()=>{r.value||(t.value="loading",n.value="",Ta(e.config).then(()=>{t.value="ready"}).catch(s=>{t.value="error",n.value=s.message||"Unknown error"}))}),i.onUnmounted(()=>{r.value||Na(e.config.instanceId)}),()=>r.value?null:i.createVNode("div",{class:"f-chat-dynamic-component-body",style:a.value},[i.createVNode("div",{id:u.value,style:{width:"100%",height:"100%",display:t.value==="ready"?"":"none"}},null),t.value==="loading"&&i.createVNode("div",{class:"f-chat-dynamic-component-loading"},[i.createVNode("span",{class:"f-chat-dynamic-component-loading-spinner"},null),i.createVNode("span",null,[i.createTextVNode("加载中......")])]),t.value==="error"&&i.createVNode("div",{class:"f-chat-dynamic-component-error"},[i.createVNode("span",{class:"f-chat-dynamic-component-error-icon"},[i.createTextVNode("!")]),i.createVNode("span",null,[n.value])])])}}),La=(e,t,n)=>{if(e.type===ke.DynamicComponentComplete){const u=e;if(!u.config)return null;if(u.config.position==="inline")return i.createVNode(bn,{key:`dc-${t}`,config:u.config},null);const o={type:"file",fileContent:{type:"md",name:u.config.title}},r={onPreviewFile:a=>{n.emit("showDynamicComponent",u.config)}};return i.nextTick(()=>n.emit("dynamicComponentsDetected",[u.config])),i.createVNode("div",{style:{padding:"16px 0"}},[n.renderFileEmbeddedContent(o,r)])}return e.type===ke.DynamicComponentPending?i.createVNode("div",{class:"f-chat-bubble-widget-pending",key:`dc-loading-${t}`},[i.createVNode("span",{class:"f-chat-todo-status-icon f-chat-todo-status-working"},null),i.createVNode("span",{class:"f-chat-bubble-widget-pending-text"},[i.createTextVNode("组件加载中......")])]):null};function fh(){return{[ke.Text]:df,[ke.A2UIComplete]:mf,[ke.AssistantWidgetComplete]:Fa,[ke.AssistantWidgetPending]:Fa,[ke.DynamicComponentComplete]:La,[ke.DynamicComponentPending]:La}}const hh=i.defineComponent({name:"FXBubbleTextContent",props:Kc,emits:["dynamicComponentsDetected","showDynamicComponent"],setup(e,t){const{renderFileEmbeddedContent:n}=oi(),{propertyStates:u,registerProperty:o,updatePropertyValue:r,startStreaming:a}=Fr();o("title",e.title??""),o("subtitle",e.subtitle??""),o("text",e.text??""),i.watch([()=>e.title,()=>e.subtitle,()=>e.text],([h,x,y])=>{r("title",h??""),r("subtitle",x??""),r("text",y??"")});const s=i.computed(()=>e.textFormat==="markdown"),c=i.ref(!1),d=i.computed(()=>{var h,x,y;return c.value?{title:((h=u.title)==null?void 0:h.displayedValue)??"",subtitle:((x=u.subtitle)==null?void 0:x.displayedValue)??"",text:((y=u.text)==null?void 0:y.displayedValue)??""}:{title:e.title,subtitle:e.subtitle,text:e.text}}),f=i.computed(()=>ll(d.value.text)),l={shouldShowMarkdown:s,emit:t.emit,renderFileEmbeddedContent:n},p=fh(),m=()=>f.value.length===0?null:i.createVNode("div",{class:"f-chat-bubble-text-collection"},[f.value.map((h,x)=>p[h.type](h,x,l))]);return i.onMounted(()=>{c.value&&a()}),()=>i.createVNode(i.Fragment,null,[d.value.title&&i.createVNode("div",{class:"f-chat-bubble-content-title"},[d.value.title]),d.value.subtitle&&i.createVNode("div",{class:"f-chat-bubble-content-subtitle"},[d.value.subtitle]),m()])}}),ph={content:{type:Object},outputMode:{type:String,default:"full"}};function Kr({status:e}){const t=`f-chat-todo-status-icon f-chat-todo-status-${e.toLowerCase()}`;return i.createVNode("span",{class:t,"aria-hidden":!0},null)}const Ia=100,mh=i.defineComponent({name:"FXBubbleThink",props:ph,setup(e,t){var W;const{propertyStates:n,registerProperty:u,updatePropertyValue:o,isAllDone:r}=Fr(),{elapsedSeconds:a,hasEverStarted:s,start:c,stop:d,reset:f}=_u(),l=i.ref(((W=e.content)==null?void 0:W.completed)!==!0),p=i.ref(null),m=i.ref(null),h=i.ref(!1),x=i.ref(!1),y=i.computed(()=>e.outputMode==="streaming"),v=i.computed(()=>{var V;return(V=e.content)==null?void 0:V.completed}),g=i.computed(()=>{var H,F,R;const V=(H=b.value)==null?void 0:H.trim(),O=V?V.slice(0,8):"",B=V&&V.length>8?"…":"",D=O?`<span class="f-chat-bubble-thinking-preview">${O}${B}</span>`:"";if(v.value){const I=s.value?`(用时${a.value}秒)`:"";return(((F=e.content)==null?void 0:F.title)??"思考完成"+I)+D}return(((R=e.content)==null?void 0:R.title)??"正在思考......")+D}),b=i.computed(()=>{var V,O;return y.value?((V=n.content)==null?void 0:V.displayedValue)??"":((O=e.content)==null?void 0:O.content)??""}),w=i.computed(()=>({"f-chat-bubble-thinking":!0,"is-pending":!v.value,"is-completed":v.value})),k=()=>{const V=p.value;if(!V||!h.value){x.value=!1;return}x.value=V.scrollTop>0};i.watch(()=>v.value,V=>{V?d():c()},{immediate:!0}),i.watch(()=>v.value,V=>{V&&(l.value=!1)}),i.watch(()=>e.content,V=>{V&&(n.content?o("content",V.content??""):u("content",V.content??""))},{immediate:!0}),i.watch(b,async()=>{if(l.value){await i.nextTick();const V=m.value;if(!V)return;await i.nextTick(),h.value=V.scrollHeight>Ia;const O=p.value;O&&h.value&&(O.scrollTop=O.scrollHeight,x.value=!0)}},{immediate:!0}),i.watch(l,async V=>{if(V){await i.nextTick();const O=m.value;if(!O)return;await i.nextTick(),h.value=O.scrollHeight>Ia;const B=p.value;B&&h.value&&(B.scrollTop=B.scrollHeight,x.value=!0)}}),i.onUnmounted(()=>{f()}),t.expose({instance:{get loadDone(){return e.content?(y.value?r.value:!0)&&v.value:!0}}});const S=()=>{l.value=!l.value},_=()=>v.value?null:i.createVNode(Kr,{status:"Working"},null),E=()=>!b.value||!l.value?null:i.createVNode("div",{class:"f-chat-bubble-thinking-content"},[i.createVNode("div",{class:"f-chat-bubble-thinking-scroll-container",ref:p,onScroll:k},[h.value&&x.value&&i.createVNode("div",{class:"f-chat-bubble-thinking-fade-mask"},null),i.createVNode("div",{class:"f-chat-bubble-thinking-text-wrapper"},[i.createVNode("div",{ref:m,class:"f-chat-bubble-thinking-content-text",innerHTML:b.value},null)])])]);return()=>i.createVNode("div",{class:w.value},[i.createVNode("div",{class:"f-chat-bubble-thinking-header",onClick:S},[_(),i.createVNode("span",{class:"f-chat-bubble-thinking-title",innerHTML:g.value},null),b.value&&i.createVNode("i",{class:"fx-icon fx-icon-arrow-right",style:{transform:l.value?"rotate(90deg)":"rotate(0deg)",transition:"all 0.3s ease-in-out"}},null)]),E()])}}),gh={content:{type:Object}},Oa={id:{type:String},arrowOffsetX:{type:Number,default:0},class:{type:String,default:""},customStyles:{type:Object,default:null},isSimpleTips:{type:Boolean,default:!1},fitContent:{type:Boolean,default:!1},host:{type:Object},leftBoundary:{type:Object},keepWidthWithReference:{type:Boolean,default:!1},minWidth:{type:Number,default:-1},offsetX:{type:Object,default:i.ref(0)},offsetY:{type:Object,default:i.ref(0)},placement:{type:String,default:"bottom"},reference:{type:Object},rightBoundary:{type:Object},showArrow:{type:Boolean,default:!1},title:{type:String},visible:{type:Boolean,default:!1},zIndex:{type:Number,default:-1},limitContentBySpace:{type:Boolean,default:!1},beforeClose:{type:Function}};function bh(e){const t=e.host?e.host:"body",n=i.computed(()=>t==="body"?0:t?t.getBoundingClientRect().top:0),u=i.computed(()=>t==="body"?window.innerHeight:t?t.getBoundingClientRect().bottom:window.innerHeight),o=i.computed(()=>t==="body"?0:t?t.getBoundingClientRect().left:0),r=i.computed(()=>t==="body"?document.body.getBoundingClientRect().width:t?t.getBoundingClientRect().width-(e.rightBoundary?e.rightBoundary.getBoundingClientRect().width:0):document.body.getBoundingClientRect().width),a=i.computed(()=>t==="body"?window.innerHeight:t?t.getBoundingClientRect().height:window.innerHeight);return{host:t,hostLeft:o,hostTop:n,hostWidth:r,hostHeight:a,hostBottom:u}}function yh(e,t,n,u){const o=i.ref(e.offsetX||0),r=i.ref(e.offsetY||0),a=i.ref(-1),s=i.ref(-1),c=i.ref(-1),d=i.ref(-1),f=i.ref(e.placement),l=i.ref(0),p=i.ref(0),m=i.ref(0),h=i.computed(()=>document.documentElement.scrollLeft),x=i.computed(()=>document.documentElement.scrollTop),{hostLeft:y,hostTop:v,hostWidth:g,hostHeight:b,hostBottom:w}=u;i.watch(()=>e.offsetX,T=>{o.value=T});const k=i.computed(()=>{const T={left:`${p.value}px`,top:`${m.value}px`,transform:`translate(${o.value}px, ${r.value}px)`};return e.zIndex!==-1&&(T["z-index"]=e.zIndex),e.fitContent?e.keepWidthWithReference&&n.value&&a.value>=n.value.getBoundingClientRect().width&&(T.width=`${a.value}px`):a.value!==-1&&(T.width=`${a.value}px`),e.minWidth!==-1&&(T.minWidth=`${e.minWidth}px`),e.customStyles&&Object.assign(T,e.customStyles),s.value>0&&(T.maxHeight=s.value+"px"),T}),S=i.computed(()=>({left:`${l.value}px`,transform:`translateX(${e.arrowOffsetX}px)`}));function _(T){if(T&&e.keepWidthWithReference){const L=T.getBoundingClientRect();a.value=Math.max(e.minWidth,L.width)}}function E(T,L){const $=g.value-T.width-4;return $>0?$:L}function W(T,L){const $=b.value-T.height-12;return $>0?$:L}function V(T,L,$){const K=l.value,Z=L.left-y.value+L.width/2+h.value,Y=L.top-v.value-(T.height+$.height)+x.value;return{popoverLeft:Z,popoverTop:Y,arrowLeft:K}}function O(T,L,$){const K=L.top-v.value+(L.height+$.height)+x.value,Z=W(T,K);return Math.min(K,Z)}function B(T,L){const $=E(L,T),K=T<=$?l.value:T-$;return{popoverLeft:Math.min(T,$),arrowLeft:K,maxHeight:0}}function D(T,L){const $=E(L,T),K=T<=$?l.value:T-$;return{popoverLeft:T,arrowLeft:K,maxHeight:0}}function j(T,L,$){const K=L.left-y.value+h.value,{arrowLeft:Z,popoverLeft:Y}=D(K,T),{popoverTop:ue}=V(T,L,$);return{popoverLeft:Y,popoverTop:ue,arrowLeft:Z,maxHeight:0}}function H(T,L,$){const K=L.left-y.value+L.width/2-($.width/2-(T.left-y.value))+h.value,{arrowLeft:Z,popoverLeft:Y}=B(K,T),ue=O(T,L,$);return{popoverLeft:Y,popoverTop:ue,arrowLeft:Z,maxHeight:0}}function F(T,L,$){const K=L.left-y.value+h.value,{arrowLeft:Z,popoverLeft:Y}=B(K,T),ue=O(T,L,$);return{popoverLeft:Y,popoverTop:ue,arrowLeft:Z,maxHeight:0}}function R(T,L,$){const K=L.left-y.value;let Z=0,Y=0,ue=0,ce=0,Te="bottom-left";window.innerWidth-K>T.width?Z=K+h.value:(Z=L.right-T.width+h.value,ue=T.width-$.width-20);let Ne=0;if(e.limitContentBySpace){const Ut={topHeight:L.top-v.value-$.height-8,bottomHeight:w.value-L.bottom-$.height-8};Ne=Math.max(Ut.topHeight,Ut.bottomHeight),T.height>Ne&&(ce=Ne,n.value.classList.add("popover-limitmax"))}const pt=ce?Math.floor(ce):T.height,Re=L.top-v.value+(L.height+$.height);return w.value-Re>pt?Y=Re+x.value:(Y=L.top-pt-$.height+x.value,w.value-Re>L.top?(Y=Re+x.value,pt>L.top&&(Y=w.value-pt)):(Y=Y<0?0:Y,Te="top")),n.value.classList.add("popover-"+Te,"bs-popover-"+Te),{popoverLeft:Z<0?5:Z,popoverTop:Y,arrowLeft:ue,maxHeight:ce}}function I(T,L,$){const K=L.left+L.width,Z=Math.max(L.top-(T.height/2-L.height/2),v.value);let Y=v.value+b.value-T.height;Y<0&&(Y=Z);const ue=Math.min(Z,Y);return{popoverLeft:K,popoverTop:ue,arrowLeft:0,maxHeight:0}}function U(T,L,$){const K=L.left+L.width,Z=Math.max(L.top-L.height,v.value);let Y=v.value+b.value-T.height;Y<0&&(Y=Z);const ue=Math.min(Z,Y);return{popoverLeft:K,popoverTop:ue,arrowLeft:0,maxHeight:0}}const re=new Map([["top",V],["top-left",j],["bottom",H],["bottom-left",F],["right",I],["right-top",U],["auto",R]]);function te(T){var Y;e.keepWidthWithReference&&_(T);const L=T.getBoundingClientRect();c.value=L.top,d.value=L.left;const $=t.value?t.value.getBoundingClientRect():{height:4,width:4},K=(Y=n.value)==null?void 0:Y.getBoundingClientRect();a.value=K.width;const Z=re.get(f.value);if(Z){const{arrowLeft:ue,popoverLeft:ce,popoverTop:Te,maxHeight:Ne}=Z(K,L,$);l.value=ue,p.value=ce,m.value=Te,s.value=Ne||-1}}function P(T){if(T){const L=T.getBoundingClientRect();(L.left!==d.value||L.top!==c.value)&&te(T)}}function M(){f.value=e.placement,l.value=0,p.value=0,m.value=0,a.value=-1}return{arrowStyle:S,popoverStyle:k,position:f,popoverWidth:a,fitToReference:_,followToReferencePosition:P,locateToReference:te,resetPosition:M}}function xh(e,t,n,u,o,r,a){const s=i.ref(e.visible),c=i.computed(()=>s.value),{fitToReference:d,locateToReference:f,resetPosition:l}=a;let p;async function m(){s.value&&(e.beforeClose&&typeof e.beforeClose=="function"&&!await e.beforeClose()||(s.value=!1,document.body.removeEventListener("click",p),document.body.removeEventListener("mousedown",p),document.body.removeEventListener("wheel",p,!0),document.removeEventListener("scroll",p),l(),t.emit("hidden")))}p=x=>{var g;if(!o.value)return;const y=o.value.contains(x.target);if(x.type==="scroll"||x.type==="wheel"&&y){m();return}if(x.target.closest(".time-picker-panel"))return;const v=(g=x.target)==null?void 0:g.closest(".popover");if(v&&u.value&&v===u.value){x.type!=="scroll"&&x.type!=="wheel"&&x.stopPropagation();return}if(!y&&s.value){const b=o.value.closest(".popover");b&&b.removeEventListener("click",p),m()}};async function h(x){if(u.value&&(e.showArrow===!1||e.showArrow&&n.value)&&x){s.value=!0,o.value=x,r.value&&d(x),await i.nextTick(),f(x),document.body.addEventListener("click",p),document.body.addEventListener("mousedown",p),document.body.addEventListener("wheel",p,!0),document.addEventListener("scroll",p),(top==null?void 0:top.document)!==document&&(top==null||top.document.addEventListener("mousedown",p));const y=x.closest(".popover");y&&y.addEventListener("click",p),t.emit("shown")}}return t.expose({hide:m,popoverRef:u,show:h,shown:c,isShow:s}),{showPopover:s,hidePopverOnClickBodyHandler:p}}function wh(e,t,n,u,o,r){const{popoverWidth:a,fitToReference:s,followToReferencePosition:c}=o;function d(){var f;if(r.value&&((f=r.value.style)==null?void 0:f.display)!=="none"&&n.value){c(n.value);const l=n.value.getBoundingClientRect();u.value&&l.width!==a.value&&s(n.value)}}return{onResize:d}}function vh(e,t=500){const n=i.ref(e.value);let u;const o=i.watch(e,a=>{clearTimeout(u),u=setTimeout(()=>{n.value=a},t)}),r=()=>{clearTimeout(u),o()};return i.onUnmounted(r),{delayedValue:n,cleanup:r}}const qt=i.defineComponent({name:"FXPopover",props:Oa,emits:["shown","hidden"],setup(e,t){const n=i.ref(),u=i.ref(),o=i.ref(e.reference),r=i.ref(e.keepWidthWithReference),a=i.computed(()=>!!e.title),s=bh(e),{host:c}=s,d=yh(e,n,u,s),{position:f,arrowStyle:l,popoverStyle:p,fitToReference:m,locateToReference:h}=d,{showPopover:x,hidePopverOnClickBodyHandler:y}=xh(e,t,n,u,o,r,d),{onResize:v}=wh(e,t,o,r,d,u),g=i.computed(()=>{let _=f.value;_==="top-left"&&(_="top");const E=`popover in popover-${_}`,W=`bs-popover-${_}`,V={"popover-fitcontent":e.fitContent,fade:!0};V[E]=!0,V[W]=!0;const O=(e.class||"").split(" ");return e.isSimpleTips&&O.unshift("popover-tips"),O.reduce((B,D)=>(B[D]=!0,B),V),V}),b=i.computed(()=>({"popover-content":!0,"popover-body":!0})),w=i.computed(()=>{const _={};return _.opacity=x.value?1:0,_.visibility=x.value?"visible":"hidden",_.zIndex=1060,_}),k=i.computed(()=>e.isSimpleTips?!0:e.showArrow),{delayedValue:S}=vh(w,50);return i.onMounted(()=>{var _;r.value&&m(o.value),e.reference&&h(o.value),window.addEventListener("resize",v),(_=u.value)==null||_.focus()}),i.onUnmounted(()=>{document.body.removeEventListener("click",y),window.removeEventListener("resize",v),x.value=!1}),()=>i.createVNode(i.Teleport,{to:c},{default:()=>{var _;return[i.withDirectives(i.createVNode("div",{tabindex:"-1",ref:u,class:g.value,style:{...p.value,...S.value},onMousedown:E=>{E.stopPropagation()},onClick:E=>{E.stopPropagation()}},[k.value&&i.createVNode("div",{ref:n,class:"popover-arrow arrow",style:l.value},null),a.value&&i.createVNode("h3",{class:"popover-title popover-header"},[e.title]),i.createVNode("div",{class:b.value},[t.slots.default&&((_=t.slots)==null?void 0:_.default())])]),[[i.vShow,x.value]])]}})}}),Qr="FarrisX_PopoverInstancesKey";window[Qr]=window[Qr]||new WeakMap;function lo(e,t,n){e.stopPropagation();const u=t.value;u&&u.value&&!u.value.isShow&&(u.value.show(n),window[Qr].set(n,u.value))}function Pa(e,t,n){e.stopPropagation(),t.value.value.hide(),window[Qr].delete(n)}function Ah(e,t,n){e.stopPropagation();const u=t.value;u&&u.value&&(u.value.isShow?Pa(e,t,n):lo(e,t,n))}function Ra(e,t,n){t.arg&&t.arg==="toggle"?Ah(e,t,n):lo(e,t,n)}const Ma={mounted:(e,t,n)=>{t.modifiers.hover?(e.addEventListener("mouseenter",u=>lo(u,t,e)),e.addEventListener("mouseleave",u=>Pa(u,t,e))):t.modifiers.click?e.addEventListener("click",u=>Ra(u,t,e)):e.addEventListener("click",u=>Ra(u,t,e)),e.classList.add("v-popover")},unMounted:(e,t,n)=>{}};qt.install=e=>{e.component(qt.name,qt),e.directive("fxpopover",Ma)};const Va={type:{type:String,default:"StartedToDo"},status:{type:String,default:"NotStart"},message:{type:String,default:""},taskDetail:{type:String,default:""},todoList:{type:Array,default:[]},detailViewMode:{type:String,default:"hover"},initExpanded:{type:Boolean,default:!1},showLoading:{type:Boolean,default:!0},showLabel:{type:Boolean,default:!0},loading:Object,shimmer:{type:Boolean,default:!0},outputMode:{type:String,default:"streaming"}},Ba={items:{type:Array,default:()=>[]}},za={id:{type:Number||String,default:0},status:{type:String},task:{type:String,default:""},todoList:{type:Array,default:[]},detailViewMode:{type:String,default:"expand"},initExpanded:{type:Boolean,default:!0},showLoading:{type:Boolean,default:!0},showLabel:{type:Boolean,default:!1},shimmer:{type:Boolean,default:!0},title:{type:String,default:""},message:{type:String,default:""},outputMode:{type:String,default:"full"}},Jr=i.defineComponent({name:"FXTodoListItemView",props:za,emits:["click"],setup(e,{emit:t}){const{propertyStates:n,registerProperty:u,updatePropertyValue:o,startStreaming:r}=Fr();u("title",e.title??""),u("task",e.task??""),i.watch([()=>e.title,()=>e.task],([p,m])=>{o("title",p??""),o("task",m??"")});const a=i.computed(()=>["f-chat-todo-item",{"is-done":e.status==="Done","is-working":e.status==="Working","is-not-start":e.status==="NotStart","no-shimmer":!e.shimmer}]),s=i.computed(()=>["f-chat-todo-task",{"is-done":e.status==="Done"}]);function c(){t("click",e,e.id)}const d=i.computed(()=>e.outputMode==="streaming"),f=i.computed(()=>{var p;return d.value?((p=n.title)==null?void 0:p.displayedValue)??"":e.title??""}),l=i.computed(()=>{var p;return d.value?((p=n.task)==null?void 0:p.displayedValue)??"":e.task??""});return i.computed(()=>{var p;return d.value?((p=n.detail)==null?void 0:p.displayedValue)??"":e.message??""}),i.onMounted(()=>{d.value&&r()}),()=>i.createVNode("li",{key:e.id,class:a.value,onClick:c},[e.todoList&&e.todoList.length>0&&i.createVNode(Xt,{todoList:e.todoList,status:e.status,message:e.task,taskDetail:e.message,detailViewMode:e.detailViewMode,initExpanded:e.initExpanded,showLoading:e.showLoading,showLabel:e.showLabel,outputMode:e.outputMode},null),!e.todoList||e.todoList.length===0&&i.createVNode(i.Fragment,null,[e.showLoading&&i.createVNode(Kr,{status:e.status??"Done"},null),f.value?i.createVNode("div",{class:"f-chat-todo-task-wrapper"},[i.createVNode("span",{class:s.value},[f.value]),i.createVNode("div",{class:"f-chat-todo-task-description"},[l.value])]):i.createVNode("div",{class:s.value},[l.value])])])}}),Qn=i.defineComponent({name:"FXTodoListView",props:Ba,setup(e){return()=>{var t;return(t=e.items)!=null&&t.length?i.createVNode("ul",{class:"f-chat-todo-items"},[e.items.map((n,u)=>i.createVNode(Jr,i.mergeProps({key:u},n),null))]):null}}}),kh="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='18px'%20height='18px'%20viewBox='0%200%2018%2018'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3ctitle%3e编组%207%3c/title%3e%3cdefs%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-1'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%231EBBC6'%20offset='58.0673923%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cpath%20d='M7.55915932,0%20L13.7556941,3.41136535%20L13.7556941,11.284674%20L13.3483936,11.690778%20L7.386,8.406%20L7.38699821,14.9818613%20L6.43606745,14.9818613%20L0.817648054,11.8789694%20L0,10.332184%20L0,3.84230019%20L1.11160458,3.1505903%20L6.167,6.164%20L6.16702601,0.0484363034%20L7.55915932,0%20Z%20M6.22734637,8.44496623%20L1.7439756,11.0288454%20L6.22734637,13.5008368%20L6.22734637,8.44496623%20Z%20M12.540835,4.77769015%20L8.0314841,7.40118228%20L12.540835,9.89639007%20L12.540835,4.77769015%20Z%20M1.21847977,4.6422718%20L1.21847977,9.89639007%20L5.74466316,7.33704011%20L1.21847977,4.6422718%20Z%20M7.38699821,1.29872452%20L7.38699821,6.38587585%20L11.9618229,3.74647178%20L7.38699821,1.29872452%20Z'%20id='path-2'%3e%3c/path%3e%3clinearGradient%20x1='81.0966666%25'%20y1='38.5584607%25'%20x2='28.8545509%25'%20y2='61.9626707%25'%20id='linearGradient-4'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-5'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='44.8152906%25'%20y1='77.6521765%25'%20x2='44.8152906%25'%20y2='3.26462903%25'%20id='linearGradient-6'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-7'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='3.93796935%25'%20y1='32.607826%25'%20x2='78.9687461%25'%20y2='60.0462823%25'%20id='linearGradient-8'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-9'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='56.0769337%25'%20y1='45.0797149%25'%20x2='24.9463054%25'%20y2='71.1433818%25'%20id='linearGradient-10'%3e%3cstop%20stop-color='%23159BD7'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='10.434388%25'%20y1='68.063656%25'%20x2='86.6988821%25'%20y2='30.8651063%25'%20id='linearGradient-11'%3e%3cstop%20stop-color='%2321C6C1'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-12'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3c/defs%3e%3cg%20id='页面-1'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='输入框'%20transform='translate(-383,%20-2915)'%3e%3cg%20id='编组-3'%20transform='translate(353,%202900)'%3e%3cg%20id='编组-12'%20transform='translate(16,%200)'%3e%3cg%20id='编组-7'%20transform='translate(14,%2015)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='18'%20height='18'%3e%3c/rect%3e%3cg%20id='编组-35'%20transform='translate(0.2571,%200.2571)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='17.4857143'%20height='17.4857143'%3e%3c/rect%3e%3cg%20id='编组-19备份-17'%20transform='translate(1.0286,%200.5143)'%3e%3cpath%20d='M8.37444647,0.834547606%20L14.5709813,4.24591296%20L14.5709813,12.1192216%20L14.1636807,12.5253256%20L8.20128715,9.24054761%20L8.20228536,15.8164089%20L7.25135461,15.8164089%20L1.63293521,12.713517%20L0.815287151,11.1667316%20L0.815287151,4.67684779%20L1.92689173,3.98513791%20L6.98228715,6.99854761%20L6.98231316,0.882983909%20L8.37444647,0.834547606%20Z%20M7.04263352,9.27951383%20L2.55926275,11.8633931%20L7.04263352,14.3353844%20L7.04263352,9.27951383%20Z%20M13.3561221,5.61223775%20L8.84677126,8.23572989%20L13.3561221,10.7309377%20L13.3561221,5.61223775%20Z%20M2.03376692,5.47681941%20L2.03376692,10.7309377%20L6.55995031,8.17158771%20L2.03376692,5.47681941%20Z%20M8.20228536,2.13327213%20L8.20228536,7.22042346%20L12.77711,4.58101939%20L8.20228536,2.13327213%20Z'%20id='形状结合'%20fill='url(%23linearGradient-1)'%3e%3c/path%3e%3cg%20id='路径-2-+-路径-3-+-路径-4蒙版'%20transform='translate(0.8153,%200.8345)'%3e%3cmask%20id='mask-3'%20fill='white'%3e%3cuse%20xlink:href='%23path-2'%3e%3c/use%3e%3c/mask%3e%3cuse%20id='蒙版'%20fill='url(%23linearGradient-1)'%20xlink:href='%23path-2'%3e%3c/use%3e%3cpolygon%20id='路径-2'%20fill='url(%23linearGradient-4)'%20filter='url(%23filter-5)'%20mask='url(%23mask-3)'%20points='4.25315881%206.97898081%206.77390576%206.97898081%207.02656062%208.27871177%202.85827337%2011.0934106%201.11764364%208.72438079'%3e%3c/polygon%3e%3cpolygon%20id='路径-3'%20fill='url(%23linearGradient-6)'%20filter='url(%23filter-7)'%20mask='url(%23mask-3)'%20points='7.02656062%206.72375166%208.13485635%204.53274022%208.34127598%201.90699543%205.4451985%201.76583085%205.65253089%205.06118714%206.77390576%206.72375166'%3e%3c/polygon%3e%3cpolygon%20id='路径-4'%20fill='url(%23linearGradient-8)'%20filter='url(%23filter-9)'%20mask='url(%23mask-3)'%20points='10.0650382%207.40118228%207.32091739%207.49951705%207.32091739%208.25868082%208.54200343%2010.0061721%2010.9306691%2010.9000701%2012.5091187%208.51626021'%3e%3c/polygon%3e%3c/g%3e%3cpath%20d='M8.37444647,0.834547606%20L14.5709813,4.24591296%20L14.5709813,12.1192216%20L14.1636807,12.5253256%20L6.98231316,8.56885311%20L6.98231316,0.882983909%20L8.37444647,0.834547606%20Z%20M8.20228536,2.13327213%20L8.20228536,7.22042346%20L8.49131316,7.05254761%20L8.49185956,7.71336245%20L9.03131316,8.12754761%20L8.84677126,8.23572989%20L13.3561221,10.7309377%20L13.3553132,5.61654761%20L13.6305018,5.15381301%20L12.77711,4.58101939%20L8.20228536,2.13327213%20Z'%20id='形状结合'%20fill='url(%23linearGradient-10)'%20fill-rule='nonzero'%3e%3c/path%3e%3cpolygon%20id='路径'%20fill='url(%23linearGradient-11)'%20fill-rule='nonzero'%20points='6.7778308%208.05322127%207.08945008%209.24101764%202.55926275%2011.8633931%202.19155022%2010.6380421'%3e%3c/polygon%3e%3cg%20id='编组-21'%20fill='url(%23linearGradient-12)'%3e%3cpath%20d='M7.62936495,9.94195975%20C8.65711289,9.94195975%209.49026721,9.10880543%209.49026721,8.08105749%20C9.49026721,7.05330955%208.65711289,6.22015523%207.62936495,6.22015523%20C6.60161701,6.22015523%205.7684627,7.05330955%205.7684627,8.08105749%20C5.7684627,9.10880543%206.60161701,9.94195975%207.62936495,9.94195975%20Z%20M13.9785177,6.03107309%20C14.7793603,6.03107309%2015.4285714,5.38186193%2015.4285714,4.58101939%20C15.4285714,3.78017684%2014.7793603,3.13096568%2013.9785177,3.13096568%20C13.1776752,3.13096568%2012.528464,3.78017684%2012.528464,4.58101939%20C12.528464,5.38186193%2013.1776752,6.03107309%2013.9785177,6.03107309%20Z%20M7.62936495,16.4714598%20C8.4302075,16.4714598%209.07941866,15.8222486%209.07941866,15.0214061%20C9.07941866,14.2205635%208.4302075,13.5713524%207.62936495,13.5713524%20C6.8285224,13.5713524%206.17931125,14.2205635%206.17931125,15.0214061%20C6.17931125,15.8222486%206.8285224,16.4714598%207.62936495,16.4714598%20Z%20M1.45005371,13.0387617%20C2.25089625,13.0387617%202.90010741,12.3895505%202.90010741,11.588708%20C2.90010741,10.7878654%202.25089625,10.1386543%201.45005371,10.1386543%20C0.649211158,10.1386543%200,10.7878654%200,11.588708%20C0,12.3895505%200.649211158,13.0387617%201.45005371,13.0387617%20Z%20M7.62936495,2.51342642%20C8.32342849,2.51342642%208.88607816,1.95077675%208.88607816,1.25671321%20C8.88607816,0.56264967%208.32342849,0%207.62936495,0%20C6.93530141,0%206.37265174,0.56264967%206.37265174,1.25671321%20C6.37265174,1.95077675%206.93530141,2.51342642%207.62936495,2.51342642%20Z%20M13.9785177,12.9913309%20C14.6725813,12.9913309%2015.2352309,12.4286812%2015.2352309,11.7346177%20C15.2352309,11.0405541%2014.6725813,10.4779045%2013.9785177,10.4779045%20C13.2844542,10.4779045%2012.7218045,11.0405541%2012.7218045,11.7346177%20C12.7218045,12.4286812%2013.2844542,12.9913309%2013.9785177,12.9913309%20Z%20M1.45005371,5.50262617%20C2.14411725,5.50262617%202.70676692,4.9399765%202.70676692,4.24591296%20C2.70676692,3.55184942%202.14411725,2.98919975%201.45005371,2.98919975%20C0.755990164,2.98919975%200.193340494,3.55184942%200.193340494,4.24591296%20C0.193340494,4.9399765%200.755990164,5.50262617%201.45005371,5.50262617%20Z'%20id='形状结合'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Ch=300,Eh={Working:"正在执行任务",Done:"已完成任务",NotStart:"待执行任务"},Xt=i.defineComponent({name:"FXStartedTodo",props:Va,setup(e){const t=i.ref(null),n=i.ref(null),u=i.ref(null),o=i.ref(null),r=i.computed(()=>e.outputMode==="streaming"),{displayContent:a}=ri(()=>({detail:e.taskDetail??""}),()=>!0,r,{charInterval:30}),s=i.ref(e.initExpanded),c=i.computed(()=>({"f-chat-message-started-todo--content":!0,"d-none":!s.value}));function d(){e.detailViewMode!=="expand"&&(o.value!=null&&(window.clearTimeout(o.value),o.value=null),u.value=window.setTimeout(()=>{t.value&&n.value&&n.value.show(t.value),u.value=null},Ch))}function f(){e.detailViewMode!=="expand"&&(u.value!=null&&(window.clearTimeout(u.value),u.value=null),o.value=window.setTimeout(()=>{var y,v;(v=(y=n.value)==null?void 0:y.hide)==null||v.call(y),o.value=null},150))}function l(){if(e.detailViewMode==="none")return null;const y=a.value.detail??"";return i.createVNode(i.Fragment,null,[y?i.createVNode("div",{class:"f-chat-started-todo-task-detail"},[y]):null,i.createVNode(Qn,{items:e.todoList},null)])}function p(){e.detailViewMode==="expand"&&(s.value=!s.value)}function m(){return e.detailViewMode==="expand"?i.createVNode("i",{class:"fx-icon fx-icon-arrow-right",style:{transform:s.value?"rotate(90deg)":"rotate(0deg)",transition:"all 0.3s ease-in-out"}},null):null}function h(){return e.detailViewMode==="hover"&&i.createVNode(qt,{ref:n,class:"f-chat-started-todo-popover"},{default:()=>[i.createVNode("div",{class:"f-chat-started-todo-popover-content",onMouseenter:()=>{o.value!=null&&(window.clearTimeout(o.value),o.value=null)},onMouseleave:f},[l()])]})}function x(){return e.showLoading?e.loading?e.loading:e.status==="Done"?i.createVNode("img",{src:kh},null):i.createVNode(Kr,{status:e.status},null):null}return()=>i.createVNode("div",{ref:t,class:["f-chat-message-started-todo",{"is-working":e.status==="Working"}],onMouseenter:d,onMouseleave:f},[i.createVNode("div",{class:"f-chat-message-started-todo--header",onClick:p},[e.showLabel&&i.createVNode("span",{class:"f-chat-started-todo-label"},[Eh[e.status]]),x(),i.createVNode("span",{class:"f-chat-started-todo-message",innerHTML:e.message},null),m()]),e.detailViewMode==="expand"&&i.createVNode("div",{class:c.value},[l()]),h()])}});Xt.install=e=>{e.component(Xt.name,Xt)};const _h=i.defineComponent({name:"FXBubbleThoughtChain",props:gh,setup(e,t){const{elapsedSeconds:n,hasEverStarted:u,start:o,stop:r,reset:a}=_u(),s=i.computed(()=>{var l;return((l=e.content)==null?void 0:l.status)==="Done"}),c=i.computed(()=>{var l;return((l=e.content)==null?void 0:l.message)??"正在思考......"}),d=i.computed(()=>{var m,h;const l=((m=e.content)==null?void 0:m.doneMessage)??((h=e.content)==null?void 0:h.message)??"思考完成",p=u.value?`(用时${n.value}秒)`:"";return""+l+p}),f=i.computed(()=>s.value?d.value:c.value);return i.watch(()=>{var l;return(l=e.content)==null?void 0:l.status},l=>{l==="Working"?o():l==="Done"?r():a()},{immediate:!0}),i.onUnmounted(()=>{a()}),t.expose({instance:{get loadDone(){return e.content?s.value:!0}}}),()=>{var l,p,m;return e.content?i.createVNode(Xt,{status:((l=e.content)==null?void 0:l.status)??"Working",message:f.value,todoList:(p=e.content)==null?void 0:p.todoList,detailViewMode:((m=e.content)==null?void 0:m.detailViewMode)??"expand",showLabel:!1,showLoading:!0,initExpanded:!0},null):null}}}),fo=i.defineComponent({name:"UserAuthMessage",props:{content:{type:Object,required:!0},onConfirm:{type:Function,default:void 0}},setup(e){return()=>i.createVNode("div",{class:"f-ec-auth"},[i.createVNode("div",{class:"f-ec-auth-desc"},[e.content.description]),i.createVNode("div",{class:"f-ec-auth-actions"},[e.content.options.map(t=>i.createVNode("button",{key:t.optionId,type:"button",class:"f-ec-auth-btn",onClick:()=>{var n;(n=e.onConfirm)==null||n.call(e,t.optionId,t.name,t.message??t.name),console.info("[UserAuth]",t.optionId,t.name)}},[t.name]))])])}}),Sh=300,Zt=i.defineComponent({name:"FXToolUseMessage",props:{content:{type:Object,required:!0}},setup(e){const t=i.computed(()=>e.content.toolResultApplied===!0||String(e.content.result??"").trim().length>0),n=i.ref(!1);let u=setTimeout(()=>{n.value=!0},Sh);i.onBeforeUnmount(()=>{u&&clearTimeout(u)});const o=i.computed(()=>t.value),r=i.computed(()=>n.value&&!t.value),a=i.computed(()=>o.value?"执行完成":"调用中"),s=i.ref(!1),c=i.computed(()=>({"f-chat-tool-use":!0,"is-done":o.value})),d=i.computed(()=>({"f-chat-tool-use-status":!0,"is-done":o.value,"is-run":r.value}));i.watch(()=>[e.content.result,e.content.toolResultApplied],()=>{t.value&&(s.value=!1)},{flush:"post"});const f=()=>t.value?i.createVNode("div",{class:"f-chat-tool-use-result"},[e.content.result??""]):null;return()=>i.createVNode("div",{class:c.value},[i.createVNode("div",{class:"f-chat-tool-use-header",onClick:()=>{s.value=!s.value}},[i.createVNode("i",{class:"fx-icon fx-icon-thinking_tool tool-icon"},null),i.createVNode("span",{class:"f-chat-tool-use-name"},[e.content.toolDescription??"tool"]),i.createVNode("div",{class:d.value},[i.createVNode(Kr,{status:o.value?"Done":r.value?"Working":"NotStart"},null),i.createVNode("span",{class:"f-chat-tool-use-status-text"},[a.value])]),i.createVNode("i",{class:"fx-icon fx-icon-arrow-right",style:{transform:s.value?"rotate(90deg)":"rotate(0deg)",transition:"transform 0.2s ease"}},null)]),s.value&&i.createVNode("div",{class:"f-chat-tool-use-content"},[f()])])}});Zt.install=e=>{e.component(Zt.name,Zt)};const Jn=i.defineComponent({name:"FXBubble",components:{"fx-user-auth-inline":fo,"fx-app-preview-inline":un,FXToolUse:Zt},props:ei,setup(e,t){const n=i.shallowRef(),u=i.ref(),o=i.ref(),r=i.computed(()=>!!e.showAvatar),a=i.computed(()=>r.value===!0||e.header==="ContentHeader"),s=i.computed(()=>t.slots.leftFooter||t.slots.rightFooter),c=i.computed(()=>{var D;return Ae({},(D=e.styles)==null?void 0:D.footer)}),d=D=>{if(e.onPreview){if(D.type==="md"&&D.content){e.onPreview({content:D.content,contentType:"markdown"});return}if(D!=null&&D.url){const j=D!=null&&D.fullScreenPreview?"fullScreen":"splitScreen";e.onPreview({url:D.url,previewMode:j,title:D.name})}}},f=D=>{if(!e.onPreview)return;const j=D==null?void 0:D.filter(F=>F.type==="md"&&F.content);if(j.length===0)return;const H=Object.fromEntries(j.map(F=>[F.name,F.content??""]));e.onPreview({contentMap:H,contentType:"markdown"})},{renderFileEmbeddedContent:l,renderPageEmbeddedContent:p}=oi(),m=i.ref(""),h=i.computed(()=>{var j,H;if((j=e.content)!=null&&j.footerContent)return e.content.footerContent;const D=(H=e.content)==null?void 0:H.structuredContent;return D&&(D.footerTemplate||D.footerUrl||D.footerFile)?{type:D.footerUrl?"page":D.footerFile?"file":"template",pageUrl:D.footerUrl,fileContent:D.footerFile,template:D.footerTemplate,width:D.footerWidth,height:D.footerHeight}:null});i.watch(()=>{var D;return(D=h.value)==null?void 0:D.width},D=>{if(!D){m.value="";return}if(D.endsWith("%")){const j=parseFloat(D);isNaN(j)||i.nextTick(()=>{var F,R;const H=(R=(F=n.value)==null?void 0:F.parentElement)==null?void 0:R.clientWidth;H&&(m.value=`${H*j/100}px`)})}else m.value=D},{immediate:!0});const x=D=>{if(!D||D.length===0)return"我";const j=D.charAt(0);return/[\u4e00-\u9fa5]/.test(j)?j:j.toUpperCase()};function y(){return e.header==="ContentHeader"?Uc:$c}const v=y(),{renderHeader:g}=v(e,t),b=()=>{var H,F,R;const D=((H=e.content)==null?void 0:H.sender)??"发送人",j=x(((F=e.content)==null?void 0:F.sender)??"");return i.createVNode("div",{class:"f-chat-bubble-avatar"},[(R=e.content)!=null&&R.avatar?i.createVNode("img",{src:e.content.avatar,alt:D},null):i.createVNode("div",{class:"f-chat-bubble-avatar-initial"},[j])])},w=()=>{var j;const D=(j=e.content)==null?void 0:j.toolUseAboveText;return D!=null&&D.length?i.createVNode("div",{class:"f-chat-bubble-tool-use-group"},[D.map((H,F)=>i.createVNode(Zt,{key:H.toolUseId??`tu-${F}`,content:H},null))]):null},k=()=>{var D;return(D=e.content)!=null&&D.thinkingContent?i.createVNode(mh,{ref:u,content:e.content.thinkingContent,outputMode:e.outputMode},null):null},S=()=>{var D;return(D=e.content)!=null&&D.startedTodo?i.createVNode(_h,{ref:o,content:e.content.startedTodo},null):null},_=D=>{if(!(D!=null&&D.type))return null;const{type:j}=D;return j==="page"&&D.pageUrl?p(D,{onNavigate:H=>{var F;(F=e.onPreview)==null||F.call(e,{url:H})}}):j==="file"&&D.fileContent?l(D,{onPreviewFile:d,onBatchPreviewFile:f}):j==="template"&&D.template?D.template():null},E=()=>{var F,R,I;if(!((I=(R=(F=e.content)==null?void 0:F.structuredContent)==null?void 0:R.sections)!=null&&I.length))return null;const{sections:D,showDivider:j}=e.content.structuredContent,H=U=>{const{content:re,label:te}=U;return te||re&&typeof re=="string"?i.createVNode(i.Fragment,null,[i.createVNode("span",{class:"f-chat-bubble-structured-section-item-dot"},null),U.label&&i.createVNode("span",{class:"f-chat-bubble-structured-section-item-label"},[U.label]),i.createVNode("span",{class:"f-chat-bubble-structured-section-item-content"},[U.content])]):_(U.content)};return i.createVNode("div",{class:["f-chat-bubble-structured",{"structure-content-divider":j}]},[D.map((U,re)=>i.createVNode("div",{key:re,class:["f-chat-bubble-structured-section",{"section-divider":U.showDivider}]},[i.createVNode("div",{class:"f-chat-bubble-structured-section-header"},[U.icon&&(U.icon.startsWith("http")||U.icon.startsWith("//")||U.icon.startsWith("../")||/\.(png|jpg|jpeg|gif|svg|webp|bmp)$/i.test(U.icon)?i.createVNode("img",{alt:U.title,src:U.icon,class:"f-chat-bubble-structured-section-icon"},null):i.createVNode("i",{class:`fx-icon ${U.icon}`,style:U.iconStyle},null)),i.createVNode("span",{class:"f-chat-bubble-structured-section-title"},[U.title])]),U.items&&U.items.length>0&&i.createVNode("div",{class:"f-chat-bubble-structured-section-items"},[U.items.map((te,P)=>i.createVNode("div",{key:P,class:"f-chat-bubble-structured-section-item"},[H(te)]))])]))])},W=()=>{const D=h.value;if(!D)return null;const j={};return m.value&&(j.width=m.value),D.height&&(j.height=`${D.height}px`),i.createVNode("div",{class:"f-chat-bubble-content-footer",style:j},[_(D)])},V=()=>i.createVNode(ui,{attachments:e.attachments??[],enableFixedWidth:e.placement==="end",onPreview:d,onBatchPreview:f},null),O=()=>{var j;const D=(j=e.content)==null?void 0:j.compositeInlineBlocks;return D!=null&&D.length?D.map((H,F)=>H.kind==="userAuth"?i.createVNode(i.resolveComponent("fx-user-auth-inline"),{key:`inline-auth-${F}`,content:H.content,onConfirm:e.onUserAuthConfirm},null):i.createVNode(i.resolveComponent("fx-app-preview-inline"),{key:`inline-preview-${F}`,content:H.content,onOpen:e.onPreview},null)):null},B=()=>{var D,j,H,F,R,I;return i.createVNode("div",{class:`f-chat-bubble-content ${e.placement}`},[a.value&&g(),i.createVNode("div",{class:`f-chat-bubble-content-text-wrapper ${e.placement}`},[(D=e.content)!=null&&D.compositeOrderedBeforeMarkdownRender?e.content.compositeOrderedBeforeMarkdownRender():i.createVNode(i.Fragment,null,[k(),w()]),S(),E(),i.createVNode(hh,{title:((j=e.content)==null?void 0:j.title)??"",subtitle:((H=e.content)==null?void 0:H.subtitle)??"",text:((F=e.content)==null?void 0:F.text)??"",textFormat:((R=e.content)==null?void 0:R.textFormat)??"plain",placement:e.placement,onDynamicComponentsDetected:e==null?void 0:e.onDynamicComponentsDetected,onShowDynamicComponent:e==null?void 0:e.onShowDynamicComponent},null),W(),(I=e.compositeTailRender)==null?void 0:I.call(e),O()]),s.value&&i.createVNode("div",{class:"f-chat-bubble-footer",style:c.value},[t.slots.leftFooter&&i.createVNode("div",{class:"f-chat-bubble-footer-left"},[t.slots.leftFooter()]),t.slots.rightFooter&&i.createVNode("div",{class:"f-chat-bubble-footer-right"},[t.slots.rightFooter()])]),V()])};return()=>i.createVNode("div",{class:"f-chat-bubble-container",ref:n},[i.createVNode("div",{class:`f-chat-bubble-wrapper ${e.placement}`},[e.placement==="start"?i.createVNode(i.Fragment,null,[r.value&&b(),B()]):i.createVNode(i.Fragment,null,[B(),r.value&&b()])])])}}),ja={customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""}},ho=i.defineComponent({name:"FXBubbleAction",props:ja,setup(e,t){const n=i.computed(()=>Ae({},e.customStyle));return()=>t.slots.default&&i.createVNode("span",{class:"f-chat-bubble-footer-action",style:n.value},[t.slots.default()])}});Jn.install=e=>{e.component(Jn.name,Jn),e.component(ho.name,ho)};const Ha={items:{type:Array,default:()=>[]},modelValue:{type:Number,default:0},direction:{type:String,default:"horizontal"},autoplay:{type:Boolean,default:!1},interval:{type:Number,default:3e3},loop:{type:Boolean,default:!0},trigger:{type:String,default:"click"},indicatorPosition:{type:String,default:"inside"},arrowVisibility:{type:String,default:"hover"},showIndicator:{type:Boolean,default:!0},showArrow:{type:Boolean,default:!0},showInfo:{type:Boolean,default:!0},height:{type:[String,Number],default:"400px"},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})},customClass:{type:[String,Array,Object],default:""},customStyle:{type:[Object,String],default:""},buttonPosition:{type:String,default:"inner"}},Ua={item:{type:Object,default:()=>({})},index:{type:Number,default:0},active:{type:Boolean,default:!1},showInfo:{type:Boolean,default:!0},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})}},eu=i.defineComponent({name:"FXCarouselItem",props:Ua,emits:["click"],setup(e,{slots:t,emit:n}){const u=i.computed(()=>{var l;const f={"fx-carousel--item":!0,"fx-carousel--item-active":e.active};return be(f,(l=e.classNames)==null?void 0:l.item)}),o=i.computed(()=>{var l,p;const f=Ae({},(l=e.styles)==null?void 0:l.item);return Ae(f,(p=e.styles)==null?void 0:p.item)}),r=()=>{var f,l,p;return e.item.image?i.createVNode("img",{class:["fx-carousel--item-image",(f=e.classNames)==null?void 0:f.image],style:(l=e.styles)==null?void 0:l.image,src:e.item.image,alt:(p=e.item.title)==null?void 0:p.toString()},null):null},a=()=>{var f,l,p,m;return e.item.content?i.createVNode("div",{class:["fx-carousel--item-content",(f=e.classNames)==null?void 0:f.content],style:(l=e.styles)==null?void 0:l.content},[e.item.content]):t.default?i.createVNode("div",{class:["fx-carousel--item-content",(p=e.classNames)==null?void 0:p.content],style:(m=e.styles)==null?void 0:m.content},[t.default()]):null},s=()=>{var f,l;return e.item.title?i.createVNode("h3",{class:["fx-carousel--item-title",(f=e.classNames)==null?void 0:f.title],style:(l=e.styles)==null?void 0:l.title},[e.item.title]):null},c=()=>{var f,l;return e.item.description?i.createVNode("p",{class:["fx-carousel--item-description",(f=e.classNames)==null?void 0:f.description],style:(l=e.styles)==null?void 0:l.description},[e.item.description]):null},d=f=>{e.item.disabled||n("click",f,e.item,e.index)};return()=>i.createVNode("div",{class:u.value,style:o.value,onClick:d},[r(),a(),e.showInfo&&i.createVNode("div",{class:"fx-carousel--item-info"},[s(),c()])])}});function Fh(e){const{items:t,autoplay:n=!1,interval:u=3e3,loop:o=!0,direction:r="horizontal"}=e,a=i.ref(0),s=i.ref(!1),c=i.ref(null),d=i.computed(()=>t.length),f=i.computed(()=>d.value<=1);i.computed(()=>a.value===0?o?d.value-1:0:a.value-1),i.computed(()=>a.value===d.value-1?o?0:a.value:a.value+1);const l=i.computed(()=>{const b=-a.value*100;return{transform:r==="horizontal"?`translateX(${b}%)`:`translateY(${b}%)`,transition:"transform 0.5s ease"}}),p=b=>{b<0||b>=d.value||(a.value,a.value=b)},m=()=>{f.value||(a.value===d.value-1?p(o?0:a.value):p(a.value+1))},h=()=>{f.value||(a.value===0?p(o?d.value-1:0):p(a.value-1))},x=()=>{!n||f.value||(y(),c.value=window.setInterval(()=>{s.value||m()},u))},y=()=>{c.value&&(clearInterval(c.value),c.value=null)},v=()=>{s.value=!0,n&&y()},g=()=>{s.value=!1,n&&x()};return i.onMounted(()=>{x()}),i.onUnmounted(()=>{y()}),{currentIndex:a,totalItems:d,isSingleItem:f,trackStyle:l,goTo:p,next:m,prev:h,handleMouseEnter:v,handleMouseLeave:g}}const er=i.defineComponent({name:"FXCarousel",props:Ha,emits:["update:modelValue","change","item-click"],setup(e,{slots:t,emit:n}){const{currentIndex:u,isSingleItem:o,trackStyle:r,goTo:a,next:s,prev:c,handleMouseEnter:d,handleMouseLeave:f}=Fh({items:e.items,autoplay:e.autoplay,interval:e.interval,loop:e.loop,direction:e.direction}),l=k=>{n("update:modelValue",k),n("change",k,u.value)},p=i.computed(()=>{var S;const k={"fx-carousel":!0,"fx-carousel--vertical":e.direction==="vertical","fx-carousel--single":o.value,"fx-carousel--button-outer":e.buttonPosition==="outer","fx-carousel--button-inner":e.buttonPosition==="inner"};return be(k,(S=e.classNames)==null?void 0:S.root)}),m=i.computed(()=>{var _;const k={height:typeof e.height=="number"?`${e.height}px`:e.height},S=Ae(k,e.customStyle);return Ae(S,(_=e.styles)==null?void 0:_.root)}),h=i.computed(()=>{var S;const k={"fx-carousel--container":!0,"fx-carousel--container-hover":e.arrowVisibility==="hover"};return be(k,(S=e.classNames)==null?void 0:S.container)}),x=i.computed(()=>{var S;return be({"fx-carousel--track":!0},(S=e.classNames)==null?void 0:S.track)}),y=i.computed(()=>{var S;const k={"fx-carousel--indicator":!0,"fx-carousel--indicator-outside":e.indicatorPosition==="outside","fx-carousel--indicator-none":e.indicatorPosition==="none"||!e.showIndicator};return be(k,(S=e.classNames)==null?void 0:S.indicator)}),v=k=>{var _,E;const S={"fx-carousel--arrow":!0,"fx-carousel--arrow-left":k==="left","fx-carousel--arrow-right":k==="right","fx-carousel--arrow-never":e.arrowVisibility==="never"||!e.showArrow};return S[`fx-carousel--arrow-${e.buttonPosition}`]=!0,be(S,k==="left"?(_=e.classNames)==null?void 0:_.arrowLeft:(E=e.classNames)==null?void 0:E.arrowRight)},g=k=>{var E,W;if(o.value)return null;const S=k==="left"?c:s,_=t[k==="left"?"prevArrow":"nextArrow"];return i.createVNode("button",{class:v(k),style:k==="left"?(E=e.styles)==null?void 0:E.arrowLeft:(W=e.styles)==null?void 0:W.arrowRight,onClick:S,"aria-label":`${k} arrow`},[_?_():i.createVNode("i",{style:"font-size: 60px;",class:`fx-icon fx-icon-arrow-${k==="left"?"left":"right"}`},null)])},b=()=>{var k;return o.value||!e.showIndicator?null:i.createVNode("div",{class:y.value,style:(k=e.styles)==null?void 0:k.indicator},[e.items.map((S,_)=>{var E,W;return i.createVNode("button",{"aria-label":`indicator ${_}`,key:_,class:["fx-carousel--indicator-item",{"fx-carousel--indicator-item-active":_===u.value}],style:_===u.value?(E=e.styles)==null?void 0:E.indicatorItemActive:(W=e.styles)==null?void 0:W.indicatorItem,onClick:()=>{a(_),l(_)}},null)})])},w=()=>i.createVNode("div",{class:x.value,style:r.value},[e.items.map((k,S)=>i.createVNode(eu,{key:k.id||`item_${S}`,item:k,showInfo:e.showInfo,index:S,active:S===u.value,styles:e.styles,classNames:e.classNames,onClick:(_,E,W)=>{n("item-click",_,E,W)}},{default:()=>{var _,E;return[(_=t.item)==null?void 0:_.call(t,{item:k,index:S,active:S===u.value}),(E=t[`item${S}`])==null?void 0:E.call(t,{item:k,index:S,active:S===u.value})]}}))]);return()=>{var k;return i.createVNode("div",{class:p.value,style:m.value,onMouseenter:d,onMouseleave:f},[e.buttonPosition==="outer"&&g("left"),i.createVNode("div",{class:h.value,style:(k=e.styles)==null?void 0:k.container},[e.buttonPosition==="inner"&&g("left"),w(),e.buttonPosition==="inner"&&g("right")]),e.buttonPosition==="outer"&&g("right"),b()])}}});er.install=e=>{e.component(er.name,er),e.component(eu.name,eu)};const $a={customStyle:{type:String,default:""},customClass:{type:String,default:""},direction:{Type:String,default:"row"}};function Dh(e){const t=i.ref(-1),n=i.ref(-1),u=i.ref(0),o=i.ref(0),r=i.ref(!1),a=i.ref(!1),s=i.computed(()=>({display:r.value?"block":"none",left:`${u.value}px`,cursor:"e-resize"})),c=i.computed(()=>({display:a.value?"block":"none",top:`${o.value}px`,cursor:"n-resize"})),d=i.computed(()=>{const y={display:a.value||r.value?"block":"none"};return o.value>0&&(y.cursor="n-resize"),y});function f(y,v,g,b){const w=e.value;if(w){const{left:k,right:S,width:_}=w.getBoundingClientRect();let E=y.clientX-k;b==="right"&&(E=S-y.clientX),E>v&&(E=v),E<g&&(E=g),b==="right"&&(E=_-E),u.value=E}}function l(y,v,g,b){const w=e.value;if(w){const{top:k,bottom:S,height:_}=w.getBoundingClientRect();let E=y.clientY-k;b==="bottom"&&(E=S-y.clientY),E>v&&(E=v),E<g&&(E=g),b==="bottom"&&(E=_-E),o.value=E}}function p(){const y=e.value;if(y){const{width:v,height:g}=y.getBoundingClientRect();return{width:v,height:g}}return null}function m(){const y=e.value;return y?Array.from(y.querySelectorAll("[data-position]")).reduce((v,g)=>{const b=g.getAttribute("data-position");return v=Object.assign(v,{[b]:g}),v},{}):null}function h(y,v){const g=p(),b=m();if(g&&b){const w=b==null?void 0:b.right,k=b==null?void 0:b.left;if(y==="left"&&k)return w?g.width-w.clientWidth-v:g.width-v;if(y==="right"&&w)return k?g.width-k.clientWidth-v:g.width-v}}function x(y,v){const g=p(),b=m();if(g&&b){const w=b==null?void 0:b.bottom,k=b==null?void 0:b.top;if(y==="top"&&k)return w?g.height-w.clientHeight-v:g.height-v;if(y==="bottom"&&w)return k?g.height-k.clientHeight-v:g.height-v}}return{horizontalResizeHandleStyle:s,verticalResizeHandleStyle:c,resizeOverlayStyle:d,showHorizontalResizeHandle:r,showVerticalResizeHandle:a,horizontalResizeBarPosition:t,verticalResizeBarPosition:n,verticalResizeHandleOffset:o,horizontalResizeHandleOffset:u,draggingHorizontalResizeHandle:f,draggingVerticalResizeHandle:l,getPanelMaxWidth:h,getPanelMaxHeight:x}}const yn=i.defineComponent({name:"FXSplitter",props:$a,emits:[],setup(e,t){const n=i.ref(),u=Dh(n),{horizontalResizeHandleStyle:o,verticalResizeHandleStyle:r,resizeOverlayStyle:a}=u;i.provide("splitter",{useResizeHandleComposition:u});const s=i.computed(()=>be({"f-splitter":!0},e==null?void 0:e.customClass)),c=i.computed(()=>{const d={"flex-direction":e.direction==="row"?"row":"column"};return Ae(d,e==null?void 0:e.customStyle)});return()=>i.createVNode("div",{class:s.value,ref:n,style:c.value},[t.slots.default&&t.slots.default(),i.createVNode("div",{class:"f-splitter-resize-overlay",style:a.value},null),i.createVNode("div",{class:"f-splitter-horizontal-resize-proxy",style:o.value},null),i.createVNode("div",{class:"f-splitter-vertical-resize-proxy",style:r.value},null)])}}),Th={customClass:{type:String,defaut:""},customStyle:{type:String,default:""},width:{type:Number},height:{type:Number},position:{type:String,default:"left"},visible:{type:Boolean,default:!0},resizable:{type:Boolean,default:!0},resizeHandle:{type:String,default:""},collapsable:{type:Boolean,default:!1},minWidth:{type:Number,default:100},minHeight:{type:Number,default:100},maxWidth:{type:Number,default:0},maxHeight:{type:Number,default:0}};function Nh(e,t){const n=i.ref(e.width),u=i.ref(e.height),{horizontalResizeBarPosition:o,horizontalResizeHandleOffset:r,showHorizontalResizeHandle:a,showVerticalResizeHandle:s,verticalResizeBarPosition:c,verticalResizeHandleOffset:d,draggingHorizontalResizeHandle:f,draggingVerticalResizeHandle:l,getPanelMaxWidth:p,getPanelMaxHeight:m}=t;let h="",x,y,v;const g=()=>e.maxWidth?e.maxWidth:p(h,e.minWidth)||0,b=()=>e.maxHeight?e.maxHeight:m(h,e.minHeight)||0;function w(_){if((h==="left"||h==="right")&&y){const{left:E}=y.getBoundingClientRect(),{width:W}=x.getBoundingClientRect(),V=_.clientX-E;let O=h==="left"?(W||0)+(V-o.value):(W||0)-(V-o.value);O=e.minWidth>0?Math.max(e.minWidth,O):O;const B=g();B!=null&&B>0&&(O=B>O?O:B),n.value=O}if((h==="top"||h==="bottom")&&y){const{top:E}=y.getBoundingClientRect(),{height:W}=x.getBoundingClientRect(),V=_.clientY-E;let O=h==="top"?(W||0)+(V-c.value):(W||0)-(V-c.value);O=e.minHeight>0?Math.max(e.minHeight,O):O;const B=b();B!=null&&B>0&&(O=B>O?O:B),u.value=O}r.value=0,d.value=0,o.value=-1,c.value=-1,a.value=!1,s.value=!1,document.removeEventListener("mousemove",v),document.removeEventListener("mouseup",w),document.body.style.userSelect="",h="",x=null,y=null}function k(_,E,W){if(h=E,x=W,a.value=!0,y=_.composedPath().find(O=>O.className.split(" ")[0]==="f-splitter"),y){const{left:O}=y.getBoundingClientRect();r.value=_.clientX-O,o.value=_.clientX-O;const B=g();v=D=>f(D,B,e.minWidth,h),document.addEventListener("mousemove",v),document.addEventListener("mouseup",w),document.body.style.userSelect="none"}}function S(_,E,W){if(h=E,x=W,s.value=!0,y=_.composedPath().find(O=>O.className.split(" ")[0]==="f-splitter"),y){const{top:O}=y.getBoundingClientRect();d.value=_.clientY-O,c.value=_.clientY-O;const B=b();v=D=>l(D,B,e.minHeight,h),document.addEventListener("mousemove",v),document.addEventListener("mouseup",w),document.body.style.userSelect="none"}}return{actualWidth:n,actualHeight:u,onClickSplitterHorizontalResizeBar:k,onClickSplitterVerticalResizeBar:S}}const tr=i.defineComponent({name:"FSplitterPane",props:Th,emits:[],setup(e,t){const n=i.ref(),u=i.inject("splitter"),{useResizeHandleComposition:o}=u,r=Nh(e,o),{actualHeight:a,actualWidth:s,onClickSplitterHorizontalResizeBar:c,onClickSplitterVerticalResizeBar:d}=r,f=i.ref(e.position),l=i.computed(()=>{const b={"f-splitter-pane":!0,"f-splitter-pane-main":f.value==="center","has-resize-bar":e.resizable};return b["f-splitter-pane-"+f.value]=!0,be(b,e==null?void 0:e.customClass)}),p=i.computed(()=>e.resizeHandle?e.resizeHandle.split(",").filter(b=>["e","n","s","w"].find(w=>w===b)):[]),m=i.computed(()=>{const b={};return(s.value||s.value===0)&&(f.value==="left"||f.value==="right"||p.value.find(w=>w==="e")||p.value.find(w=>w==="w"))&&(b.width=`${s.value}px`),(a.value||a.value===0)&&(f.value==="bottom"||f.value==="top"||p.value.find(w=>w==="s")||p.value.find(w=>w==="n"))&&(b.height=`${a.value}px`),e.visible||(b.display="none"),Ae(b,e==null?void 0:e.customStyle)}),h=i.computed(()=>({"f-splitter-resize-bar":!0,"f-splitter-resize-bar-e":f.value==="left","f-splitter-resize-bar-n":f.value==="bottom","f-splitter-resize-bar-s":f.value==="top","f-splitter-resize-bar-w":f.value==="right"}));function x(b){return{e:"left",w:"right",s:"top",n:"bottom"}[b]||b}function y(b,w){w=x(w),["left","right"].find(k=>k===w)&&c(b,w,n.value),["top","bottom"].find(k=>k===w)&&d(b,w,n.value)}function v(){return p.value.length>0?p.value.map(b=>i.createVNode("span",{class:"f-splitter-resize-bar f-splitter-resize-bar-"+b,onMousedown:w=>y(w,b)},null)):i.createVNode("span",{class:h.value,onMousedown:b=>y(b,f.value)},null)}function g(){s.value=e.width,a.value=e.height,m.value}return t.expose({reset:g}),()=>i.createVNode("div",{ref:n,class:l.value,style:m.value,"data-position":f.value},[t.slots.default&&t.slots.default(),e.resizable&&v()])}});yn.install=e=>{e.component(yn.name,yn),e.component(tr.name,tr)};const Wa={previewConfig:{type:Object,default:()=>({})},onClose:{type:Function,default:()=>{}},onIframeLoad:{type:Function,default:()=>{}}},Ga={content:{type:String,default:null}},Lh=e=>{const t=typeof e;return t!=="function"&&t!=="object"||e===null},Ih=e=>{const t=e.flags===""?void 0:e.flags;return new RegExp(e.source,t)},nr=(e,t=new WeakMap)=>{if(e===null||Lh(e))return e;if(t.has(e))return t.get(e);if(e instanceof RegExp)return Ih(e);if(e instanceof Date)return new Date(e.getTime());if(e instanceof Function)return e;if(e instanceof Map){const u=new Map;return t.set(e,u),e.forEach((o,r)=>{u.set(r,nr(o,t))}),u}if(e instanceof Set){const u=new Set;t.set(e,u);for(const o of e)u.add(nr(o,t));return u}if(Array.isArray(e)){const u=[];return t.set(e,u),e.forEach(o=>{u.push(nr(o,t))}),u}const n={};t.set(e,n);for(const u in e)Object.prototype.hasOwnProperty.call(e,u)&&(n[u]=nr(e[u],t));return n},Oh=(e,t=200)=>{let n=0;return(...u)=>new Promise(o=>{n&&(clearTimeout(n),o("cancel")),n=window.setTimeout(()=>{e.apply(void 0,u),n=0,o("done")},t)})},po=()=>`${Date.now().toString(36)}${Math.random().toString(36).substring(2)}`,tu=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),Ph=new Set(["__proto__","constructor","prototype"]),Rh=e=>!Ph.has(e),mo=(e,t,n={})=>{if(Array.isArray(e)&&Array.isArray(t))return go(e,t,n);const{excludeKeys:u}=n,o=e,r=t;for(const a of Object.keys(r)){if(!Rh(a))continue;const s=r[a],c=o[a];u&&u(a)?o[a]=s:Array.isArray(s)&&Array.isArray(c)?o[a]=go(c,s,n):tu(s)&&tu(c)?o[a]=mo(c,s,n):o[a]=s}return e},go=(e,t,n)=>{const u=e.slice();return t.forEach((o,r)=>{const a=u[r];Array.isArray(o)&&Array.isArray(a)?u[r]=go(a,o,n):tu(o)&&tu(a)?u[r]=mo(a,o,n):u[r]=o}),u},q="md-editor",de="https://unpkg.com",Mh=`${de}/@highlightjs/cdn-assets@11.11.1/highlight.min.js`,qa={main:`${de}/prettier@3.8.1/standalone.js`,markdown:`${de}/prettier@3.8.1/plugins/markdown.js`},Vh={css:`${de}/cropperjs@1.6.2/dist/cropper.min.css`,js:`${de}/cropperjs@1.6.2/dist/cropper.min.js`},Bh=`${de}/screenfull@5.2.0/dist/screenfull.js`,zh=`${de}/mermaid@11.12.3/dist/mermaid.min.js`,jh={js:`${de}/katex@0.16.33/dist/katex.min.js`,css:`${de}/katex@0.16.33/dist/katex.min.css`},bo={a11y:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/a11y-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/a11y-dark.min.css`},atom:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/atom-one-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/atom-one-dark.min.css`},github:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/github.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/github-dark.min.css`},gradient:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/gradient-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/gradient-dark.min.css`},kimbie:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/kimbie-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/kimbie-dark.min.css`},paraiso:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/paraiso-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/paraiso-dark.min.css`},qtcreator:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/qtcreator-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/qtcreator-dark.min.css`},stackoverflow:{light:`${de}/@highlightjs/cdn-assets@11.11.1/styles/stackoverflow-light.min.css`,dark:`${de}/@highlightjs/cdn-assets@11.11.1/styles/stackoverflow-dark.min.css`}},Hh=`${de}/echarts@6.0.0/dist/echarts.min.js`,Xa={"zh-CN":{toolbarTips:{bold:"加粗",underline:"下划线",italic:"斜体",strikeThrough:"删除线",title:"标题",sub:"下标",sup:"上标",quote:"引用",unorderedList:"无序列表",orderedList:"有序列表",task:"任务列表",codeRow:"行内代码",code:"块级代码",link:"链接",image:"图片",table:"表格",mermaid:"mermaid图",katex:"katex公式",revoke:"后退",next:"前进",save:"保存",prettier:"美化",pageFullscreen:"浏览器全屏",fullscreen:"屏幕全屏",preview:"预览",previewOnly:"仅预览",htmlPreview:"html代码预览",catalog:"目录",github:"源码地址"},titleItem:{h1:"一级标题",h2:"二级标题",h3:"三级标题",h4:"四级标题",h5:"五级标题",h6:"六级标题"},imgTitleItem:{link:"添加链接",upload:"上传图片",clip2upload:"裁剪上传"},linkModalTips:{linkTitle:"添加链接",imageTitle:"添加图片",descLabel:"链接描述:",descLabelPlaceHolder:"请输入描述...",urlLabel:"链接地址:",urlLabelPlaceHolder:"请输入链接...",buttonOK:"确定"},clipModalTips:{title:"裁剪图片上传",buttonUpload:"上传"},copyCode:{text:"复制代码",successTips:"已复制!",failTips:"复制失败!"},mermaid:{flow:"流程图",sequence:"时序图",gantt:"甘特图",class:"类图",state:"状态图",pie:"饼图",relationship:"关系图",journey:"旅程图"},katex:{inline:"行内公式",block:"块级公式"},footer:{markdownTotal:"字数",scrollAuto:"同步滚动"}},"en-US":{toolbarTips:{bold:"bold",underline:"underline",italic:"italic",strikeThrough:"strikeThrough",title:"title",sub:"subscript",sup:"superscript",quote:"quote",unorderedList:"unordered list",orderedList:"ordered list",task:"task list",codeRow:"inline code",code:"block-level code",link:"link",image:"image",table:"table",mermaid:"mermaid",katex:"formula",revoke:"revoke",next:"undo revoke",save:"save",prettier:"prettier",pageFullscreen:"fullscreen in page",fullscreen:"fullscreen",preview:"preview",previewOnly:"preview only",htmlPreview:"html preview",catalog:"catalog",github:"source code"},titleItem:{h1:"Lv1 Heading",h2:"Lv2 Heading",h3:"Lv3 Heading",h4:"Lv4 Heading",h5:"Lv5 Heading",h6:"Lv6 Heading"},imgTitleItem:{link:"Add Image Link",upload:"Upload Images",clip2upload:"Crop And Upload"},linkModalTips:{linkTitle:"Add Link",imageTitle:"Add Image",descLabel:"Desc:",descLabelPlaceHolder:"Enter a description...",urlLabel:"Link:",urlLabelPlaceHolder:"Enter a link...",buttonOK:"OK"},clipModalTips:{title:"Crop Image",buttonUpload:"Upload"},copyCode:{text:"Copy",successTips:"Copied!",failTips:"Copy failed!"},mermaid:{flow:"flow",sequence:"sequence",gantt:"gantt",class:"class",state:"state",pie:"pie",relationship:"relationship",journey:"journey"},katex:{inline:"inline",block:"block"},footer:{markdownTotal:"Character Count",scrollAuto:"Scroll Auto"}}},ot={editorExtensions:{highlight:{js:Mh,css:bo},prettier:{standaloneJs:qa.main,parserMarkdownJs:qa.markdown},cropper:{...Vh},screenfull:{js:Bh},mermaid:{js:zh,enableZoom:!0},katex:{...jh},echarts:{js:Hh}},editorExtensionsAttrs:{},editorConfig:{languageUserDefined:{},mermaidTemplate:{},renderDelay:500,zIndex:2e4},codeMirrorExtensions:e=>e,markdownItConfig:()=>{},markdownItPlugins:e=>e,mermaidConfig:e=>e,katexConfig:e=>e,echartsConfig:e=>e},Uh=({instance:e,ctx:t,props:n={}},u="default")=>{const o=(e==null?void 0:e.$slots[u])||(t==null?void 0:t.slots[u]);return(o?o(e):"")||n[u]},$h="buildFinished",yo="errorCatcher",xo="catalogChanged",Wh="pushCatalog",Za="rerender",Gh="taskStateChanged";class qh{constructor(){fe(this,"pools",{})}remove(t,n,u){const o=this.pools[t]&&this.pools[t][n];o&&(this.pools[t][n]=o.filter(r=>r!==u))}clear(t){this.pools[t]={}}on(t,n){return this.pools[t]||(this.pools[t]={}),this.pools[t][n.name]||(this.pools[t][n.name]=[]),this.pools[t][n.name].push(n.callback),this.pools[t][n.name].includes(n.callback)}emit(t,n,...u){this.pools[t]||(this.pools[t]={});const o=this.pools[t][n];o&&o.forEach(r=>{try{r(...u)}catch(a){console.error(`${n} monitor event exception!`,a)}})}}const nt=new qh,Xh=(e,t)=>{if(!e)return e;const n=t.split(`
29
+ `),u=['<span rn-wrapper aria-hidden="true">'];return n.forEach(()=>{u.push("<span></span>")}),u.push("</span>"),`<span class="${q}-code-block">${e}</span>${u.join("")}`};async function Ya(e){if(typeof e=="string"){if(window.isSecureContext&&navigator.clipboard)return await navigator.clipboard.writeText(e);{const t=document.createElement("textarea");let n=!1;if(t.value=e,t.style.position="fixed",t.style.opacity=0,t.style.zIndex="-10000",t.style.top="-10000",document.body.appendChild(t),t.select(),n=document.execCommand("copy"),document.body.removeChild(t),n)return;throw new Error('Failed to copy content via "execCommand"!')}}}const Zh={copy:`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-copy ${q}-icon"><rect width="14" height="14" x="8" y="8" rx="2" ry="2"/><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"/></svg>`,"collapse-tips":`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-circle-chevron-left ${q}-icon"><circle cx="12" cy="12" r="10"/><path d="m14 16-4-4 4-4"/></svg>`,pin:`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-pin ${q}-icon"><path d="M12 17v5"/><path d="M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z"/></svg>`,"pin-off":`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-pin-off ${q}-icon"><path d="M12 17v5"/><path d="M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89"/><path d="m2 2 20 20"/><path d="M9 9v1.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h11"/></svg>`,check:`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-check ${q}-icon"><path d="M20 6 9 17l-5-5"/></svg>`},kt=(e,t)=>typeof t[e]=="string"?t[e]:Zh[e],Mt=(e,t,n="")=>{var o;const u=document.getElementById(t.id);if(u)n!==""&&(Reflect.get(window,n)?(o=t.onload)==null||o.call(u,new Event("load")):t.onload&&u.addEventListener("load",t.onload));else{const r={...t};r.onload=null;const a=Kh(e,r);t.onload&&a.addEventListener("load",t.onload),document.head.appendChild(a)}},Yh=(e,t)=>{var n;(n=document.getElementById(t.id))==null||n.remove(),Mt(e,t)},Kh=(e,t)=>{const n=document.createElement(e);return Object.keys(t).forEach(u=>{t[u]!==void 0&&(n[u]=t[u])}),n},Qh=(e,t)=>{const n=new Map;return e==null||e.forEach(u=>{let o=u.querySelector(`.${q}-mermaid-action`);o?o.querySelector(`.${q}-mermaid-copy`)||o.insertAdjacentHTML("beforeend",`<span class="${q}-mermaid-copy">${kt("copy",t.customIcon)}</span>`):(u.insertAdjacentHTML("beforeend",`<div class="${q}-mermaid-action"><span class="${q}-mermaid-copy">${kt("copy",t.customIcon)}</span></div>`),o=u.querySelector(`.${q}-mermaid-action`));const r=o.querySelector(`.${q}-mermaid-copy`);let a=-1;const s=()=>{clearTimeout(a),Ya(u.dataset.content||"").then(()=>{r.innerHTML=kt("check",t.customIcon)}).catch(()=>{r.innerHTML=kt("copy",t.customIcon)}).finally(()=>{a=window.setTimeout(()=>{r.innerHTML=kt("copy",t.customIcon)},1500)})};r.addEventListener("click",s),n.set(u,{removeClick:()=>{r.removeEventListener("click",s)}})}),()=>{n.forEach(({removeClick:u})=>{u==null||u()}),n.clear()}},Jh=(()=>{const e=t=>{if(!t)return()=>{};const n=t.firstChild;let u=1,o=0,r=0,a=!1,s,c,d,f=1;const l=()=>{n.style.transform=`translate(${o}px, ${r}px) scale(${u})`},p=w=>{w.touches.length===1?(a=!0,s=w.touches[0].clientX-o,c=w.touches[0].clientY-r):w.touches.length===2&&(d=Math.hypot(w.touches[0].clientX-w.touches[1].clientX,w.touches[0].clientY-w.touches[1].clientY),f=u)},m=w=>{if(w.preventDefault(),a&&w.touches.length===1)o=w.touches[0].clientX-s,r=w.touches[0].clientY-c,l();else if(w.touches.length===2){const k=Math.hypot(w.touches[0].clientX-w.touches[1].clientX,w.touches[0].clientY-w.touches[1].clientY)/d,S=u;u=f*(1+(k-1));const _=(w.touches[0].clientX+w.touches[1].clientX)/2,E=(w.touches[0].clientY+w.touches[1].clientY)/2,W=n.getBoundingClientRect(),V=(_-W.left)/S,O=(E-W.top)/S;o-=V*(u-S),r-=O*(u-S),l()}},h=()=>{a=!1},x=w=>{w.preventDefault();const k=.02,S=u;w.deltaY<0?u+=k:u=Math.max(.1,u-k);const _=n.getBoundingClientRect(),E=w.clientX-_.left,W=w.clientY-_.top;o-=E/S*(u-S),r-=W/S*(u-S),l()},y=w=>{a=!0,s=w.clientX-o,c=w.clientY-r},v=w=>{a&&(o=w.clientX-s,r=w.clientY-c,l())},g=()=>{a=!1},b=()=>{a=!1};return t.addEventListener("touchstart",p,{passive:!1}),t.addEventListener("touchmove",m,{passive:!1}),t.addEventListener("touchend",h),t.addEventListener("wheel",x,{passive:!1}),t.addEventListener("mousedown",y),t.addEventListener("mousemove",v),t.addEventListener("mouseup",g),t.addEventListener("mouseleave",b),()=>{t.removeEventListener("touchstart",p),t.removeEventListener("touchmove",m),t.removeEventListener("touchend",h),t.removeEventListener("wheel",x),t.removeEventListener("mousedown",y),t.removeEventListener("mousemove",v),t.removeEventListener("mouseup",g),t.removeEventListener("mouseleave",b)}};return(t,n)=>{const u=new Map;return t==null||t.forEach(o=>{let r=o.querySelector(`.${q}-mermaid-action`);r?r.querySelector(`.${q}-mermaid-zoom`)||r.insertAdjacentHTML("beforeend",`<span class="${q}-mermaid-zoom">${kt("pin-off",n.customIcon)}</span>`):(o.insertAdjacentHTML("beforeend",`<div class="${q}-mermaid-action"><span class="${q}-mermaid-zoom">${kt("pin-off",n.customIcon)}</span></div>`),r=o.querySelector(`.${q}-mermaid-action`));const a=r.querySelector(`.${q}-mermaid-zoom`),s=()=>{const c=u.get(o);if(c!=null&&c.removeEvent)c.removeEvent(),o.removeAttribute("data-grab"),u.set(o,{removeClick:c.removeClick}),a.innerHTML=kt("pin-off",n.customIcon);else{const d=e(o);o.setAttribute("data-grab",""),u.set(o,{removeEvent:d,removeClick:c==null?void 0:c.removeClick}),a.innerHTML=kt("pin",n.customIcon)}};a.addEventListener("click",s),u.set(o,{removeClick:()=>a.removeEventListener("click",s)})}),()=>{u.forEach(({removeEvent:o,removeClick:r})=>{o==null||o(),r==null||r()}),u.clear()}}})(),Ka=new Set([!0,!1,"alt","title"]);function Qa(e,t){return(Array.isArray(e)?e:[]).filter(([n])=>n!==t)}function Ja(e,t){e&&e.attrs&&(e.attrs=Qa(e.attrs,t))}function e1(e,t){if(!Ka.has(e))throw new TypeError(`figcaption must be one of: ${[...Ka]}.`);if(e==="alt")return t.content;const n=t.attrs.find(([u])=>u==="title");return Array.isArray(n)&&n[1]?(Ja(t,"title"),n[1]):void 0}function t1(e,t){t=t||{},e.core.ruler.before("linkify","image_figures",function(n){let u=1;for(let o=1,r=n.tokens.length;o<r-1;++o){const a=n.tokens[o];if(a.type!=="inline"||!a.children||a.children.length!==1&&a.children.length!==3||a.children.length===1&&a.children[0].type!=="image")continue;if(a.children.length===3){const[d,f,l]=a.children;if(d.type!=="link_open"||f.type!=="image"||l.type!=="link_close")continue}if(o!==0&&n.tokens[o-1].type!=="paragraph_open"||o!==r-1&&n.tokens[o+1].type!=="paragraph_close")continue;const s=n.tokens[o-1];let c;if(s.type="figure_open",s.tag="figure",n.tokens[o+1].type="figure_close",n.tokens[o+1].tag="figure",t.dataType&&n.tokens[o-1].attrPush(["data-type","image"]),t.link&&a.children.length===1){[c]=a.children;const d=new n.Token("link_open","a",1);d.attrPush(["href",c.attrGet("src")]),a.children.unshift(d),a.children.push(new n.Token("link_close","a",-1))}if(c=a.children.length===1?a.children[0]:a.children[1],t.figcaption){const d=e1(t.figcaption,c);if(d){const[f]=e.parseInline(d,n.env);a.children.push(new n.Token("figcaption_open","figcaption",1)),a.children.push(...f.children),a.children.push(new n.Token("figcaption_close","figcaption",-1)),c.attrs&&(c.attrs=Qa(c.attrs,"title"))}}if(t.copyAttrs&&c.attrs){const d=t.copyAttrs===!0?"":t.copyAttrs;s.attrs=c.attrs.filter(([f])=>f.match(d)).map(f=>Array.from(f))}if(t.tabindex&&(n.tokens[o-1].attrPush(["tabindex",u]),u++),t.lazy&&(c.attrs.some(([d])=>d==="loading")||c.attrs.push(["loading","lazy"])),t.async&&(c.attrs.some(([d])=>d==="decoding")||c.attrs.push(["decoding","async"])),t.classes&&typeof t.classes=="string"){let d=!1;for(let f=0,l=c.attrs.length;f<l&&!d;f++){const p=c.attrs[f];p[0]==="class"&&(p[1]=`${p[1]} ${t.classes}`,d=!0)}d||c.attrs.push(["class",t.classes])}if(t.removeSrc){const d=c.attrs.find(([f])=>f==="src");c.attrs.push(["data-src",d[1]]),Ja(c,"src")}}})}const n1=/\\([ \\!"#$%&'()*+,./:;<=>?@[\]^_`{|}~-])/g;function r1(e,t){const n=e.posMax,u=e.pos;if(e.src.charCodeAt(u)!==126||t||u+2>=n)return!1;e.pos=u+1;let o=!1;for(;e.pos<n;){if(e.src.charCodeAt(e.pos)===126){o=!0;break}e.md.inline.skipToken(e)}if(!o||u+1===e.pos)return e.pos=u,!1;const r=e.src.slice(u+1,e.pos);if(r.match(/(^|[^\\])(\\\\)*\s/))return e.pos=u,!1;e.posMax=e.pos,e.pos=u+1;const a=e.push("sub_open","sub",1);a.markup="~";const s=e.push("text","",0);s.content=r.replace(n1,"$1");const c=e.push("sub_close","sub",-1);return c.markup="~",e.pos=e.posMax+1,e.posMax=n,!0}function u1(e){e.inline.ruler.after("emphasis","sub",r1)}const o1=/\\([ \\!"#$%&'()*+,./:;<=>?@[\]^_`{|}~-])/g;function i1(e,t){const n=e.posMax,u=e.pos;if(e.src.charCodeAt(u)!==94||t||u+2>=n)return!1;e.pos=u+1;let o=!1;for(;e.pos<n;){if(e.src.charCodeAt(e.pos)===94){o=!0;break}e.md.inline.skipToken(e)}if(!o||u+1===e.pos)return e.pos=u,!1;const r=e.src.slice(u+1,e.pos);if(r.match(/(^|[^\\])(\\\\)*\s/))return e.pos=u,!1;e.posMax=e.pos,e.pos=u+1;const a=e.push("sup_open","sup",1);a.markup="^";const s=e.push("text","",0);s.content=r.replace(o1,"$1");const c=e.push("sup_close","sup",-1);return c.markup="^",e.pos=e.posMax+1,e.posMax=n,!0}function a1(e){e.inline.ruler.after("emphasis","sup",i1)}var s1=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,es=new Set,wo=typeof process=="object"&&process?process:{},ts=(e,t,n,u)=>{typeof wo.emitWarning=="function"?wo.emitWarning(e,t,n,u):console.error(`[${n}] ${t}: ${e}`)},nu=globalThis.AbortController,ns=globalThis.AbortSignal;if(typeof nu>"u"){ns=class{constructor(){fe(this,"onabort");fe(this,"_onabort",[]);fe(this,"reason");fe(this,"aborted",!1)}addEventListener(n,u){this._onabort.push(u)}},nu=class{constructor(){fe(this,"signal",new ns);t()}abort(n){var u,o;if(!this.signal.aborted){this.signal.reason=n,this.signal.aborted=!0;for(let r of this.signal._onabort)r(n);(o=(u=this.signal).onabort)==null||o.call(u,n)}}};let e=((bc=wo.env)==null?void 0:bc.LRU_CACHE_IGNORE_AC_WARNING)!=="1",t=()=>{e&&(e=!1,ts("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",t))}}var c1=e=>!es.has(e),Vt=e=>e&&e===Math.floor(e)&&e>0&&isFinite(e),rs=e=>Vt(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?ru:null:null,ru=class extends Array{constructor(t){super(t),this.fill(0)}},l1=(Ct=class{constructor(t,n){fe(this,"heap");fe(this,"length");if(!A(Ct,An))throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new n(t),this.length=0}static create(t){let n=rs(t);if(!n)return[];ee(Ct,An,!0);let u=new Ct(t,n);return ee(Ct,An,!1),u}push(t){this.heap[this.length++]=t}pop(){return this.heap[--this.length]}},An=new WeakMap,ie(Ct,An,!1),Ct),d1=(Sn=class{constructor(t){ie(this,G);ie(this,rt);ie(this,Ye);ie(this,it);ie(this,Jt);ie(this,at);ie(this,kn);ie(this,Cn);ie(this,st);fe(this,"ttl");fe(this,"ttlResolution");fe(this,"ttlAutopurge");fe(this,"updateAgeOnGet");fe(this,"updateAgeOnHas");fe(this,"allowStale");fe(this,"noDisposeOnSet");fe(this,"noUpdateTTL");fe(this,"maxEntrySize");fe(this,"sizeCalculation");fe(this,"noDeleteOnFetchRejection");fe(this,"noDeleteOnStaleGet");fe(this,"allowStaleOnFetchAbort");fe(this,"allowStaleOnFetchRejection");fe(this,"ignoreFetchAbort");ie(this,Ce);ie(this,ct);ie(this,we);ie(this,he);ie(this,ne);ie(this,je);ie(this,Ke);ie(this,Pe);ie(this,Fe);ie(this,lt);ie(this,De);ie(this,dt);ie(this,ft);ie(this,Qe);ie(this,Je);ie(this,ht);ie(this,Ht);ie(this,He);ie(this,En);ie(this,en,()=>{});ie(this,St,()=>{});ie(this,wr,()=>{});ie(this,et,()=>!1);ie(this,tn,t=>{});ie(this,_n,(t,n,u)=>{});ie(this,vr,(t,n,u,o)=>{if(u||o)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0});fe(this,yc,"LRUCache");let{max:n=0,ttl:u,ttlResolution:o=1,ttlAutopurge:r,updateAgeOnGet:a,updateAgeOnHas:s,allowStale:c,dispose:d,onInsert:f,disposeAfter:l,noDisposeOnSet:p,noUpdateTTL:m,maxSize:h=0,maxEntrySize:x=0,sizeCalculation:y,fetchMethod:v,memoMethod:g,noDeleteOnFetchRejection:b,noDeleteOnStaleGet:w,allowStaleOnFetchRejection:k,allowStaleOnFetchAbort:S,ignoreFetchAbort:_,perf:E}=t;if(E!==void 0&&typeof(E==null?void 0:E.now)!="function")throw new TypeError("perf option must have a now() method if specified");if(ee(this,st,E??s1),n!==0&&!Vt(n))throw new TypeError("max option must be a nonnegative integer");let W=n?rs(n):Array;if(!W)throw new Error("invalid max value: "+n);if(ee(this,rt,n),ee(this,Ye,h),this.maxEntrySize=x||A(this,Ye),this.sizeCalculation=y,this.sizeCalculation){if(!A(this,Ye)&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(g!==void 0&&typeof g!="function")throw new TypeError("memoMethod must be a function if defined");if(ee(this,Cn,g),v!==void 0&&typeof v!="function")throw new TypeError("fetchMethod must be a function if specified");if(ee(this,kn,v),ee(this,Ht,!!v),ee(this,we,new Map),ee(this,he,new Array(n).fill(void 0)),ee(this,ne,new Array(n).fill(void 0)),ee(this,je,new W(n)),ee(this,Ke,new W(n)),ee(this,Pe,0),ee(this,Fe,0),ee(this,lt,l1.create(n)),ee(this,Ce,0),ee(this,ct,0),typeof d=="function"&&ee(this,it,d),typeof f=="function"&&ee(this,Jt,f),typeof l=="function"?(ee(this,at,l),ee(this,De,[])):(ee(this,at,void 0),ee(this,De,void 0)),ee(this,ht,!!A(this,it)),ee(this,En,!!A(this,Jt)),ee(this,He,!!A(this,at)),this.noDisposeOnSet=!!p,this.noUpdateTTL=!!m,this.noDeleteOnFetchRejection=!!b,this.allowStaleOnFetchRejection=!!k,this.allowStaleOnFetchAbort=!!S,this.ignoreFetchAbort=!!_,this.maxEntrySize!==0){if(A(this,Ye)!==0&&!Vt(A(this,Ye)))throw new TypeError("maxSize must be a positive integer if specified");if(!Vt(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");X(this,G,Vc).call(this)}if(this.allowStale=!!c,this.noDeleteOnStaleGet=!!w,this.updateAgeOnGet=!!a,this.updateAgeOnHas=!!s,this.ttlResolution=Vt(o)||o===0?o:1,this.ttlAutopurge=!!r,this.ttl=u||0,this.ttl){if(!Vt(this.ttl))throw new TypeError("ttl must be a positive integer if specified");X(this,G,Yo).call(this)}if(A(this,rt)===0&&this.ttl===0&&A(this,Ye)===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!A(this,rt)&&!A(this,Ye)){let V="LRU_CACHE_UNBOUNDED";c1(V)&&(es.add(V),ts("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",V,Sn))}}get perf(){return A(this,st)}static unsafeExposeInternals(t){return{starts:A(t,ft),ttls:A(t,Qe),autopurgeTimers:A(t,Je),sizes:A(t,dt),keyMap:A(t,we),keyList:A(t,he),valList:A(t,ne),next:A(t,je),prev:A(t,Ke),get head(){return A(t,Pe)},get tail(){return A(t,Fe)},free:A(t,lt),isBackgroundFetch:n=>{var u;return X(u=t,G,pe).call(u,n)},backgroundFetch:(n,u,o,r)=>{var a;return X(a=t,G,ku).call(a,n,u,o,r)},moveToTail:n=>{var u;return X(u=t,G,Cr).call(u,n)},indexes:n=>{var u;return X(u=t,G,$t).call(u,n)},rindexes:n=>{var u;return X(u=t,G,Wt).call(u,n)},isStale:n=>{var u;return A(u=t,et).call(u,n)}}}get max(){return A(this,rt)}get maxSize(){return A(this,Ye)}get calculatedSize(){return A(this,ct)}get size(){return A(this,Ce)}get fetchMethod(){return A(this,kn)}get memoMethod(){return A(this,Cn)}get dispose(){return A(this,it)}get onInsert(){return A(this,Jt)}get disposeAfter(){return A(this,at)}getRemainingTTL(t){return A(this,we).has(t)?1/0:0}*entries(){for(let t of X(this,G,$t).call(this))A(this,ne)[t]!==void 0&&A(this,he)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield[A(this,he)[t],A(this,ne)[t]])}*rentries(){for(let t of X(this,G,Wt).call(this))A(this,ne)[t]!==void 0&&A(this,he)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield[A(this,he)[t],A(this,ne)[t]])}*keys(){for(let t of X(this,G,$t).call(this)){let n=A(this,he)[t];n!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield n)}}*rkeys(){for(let t of X(this,G,Wt).call(this)){let n=A(this,he)[t];n!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield n)}}*values(){for(let t of X(this,G,$t).call(this))A(this,ne)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield A(this,ne)[t])}*rvalues(){for(let t of X(this,G,Wt).call(this))A(this,ne)[t]!==void 0&&!X(this,G,pe).call(this,A(this,ne)[t])&&(yield A(this,ne)[t])}[(xc=Symbol.iterator,yc=Symbol.toStringTag,xc)](){return this.entries()}find(t,n={}){for(let u of X(this,G,$t).call(this)){let o=A(this,ne)[u],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;if(r!==void 0&&t(r,A(this,he)[u],this))return this.get(A(this,he)[u],n)}}forEach(t,n=this){for(let u of X(this,G,$t).call(this)){let o=A(this,ne)[u],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;r!==void 0&&t.call(n,r,A(this,he)[u],this)}}rforEach(t,n=this){for(let u of X(this,G,Wt).call(this)){let o=A(this,ne)[u],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;r!==void 0&&t.call(n,r,A(this,he)[u],this)}}purgeStale(){let t=!1;for(let n of X(this,G,Wt).call(this,{allowStale:!0}))A(this,et).call(this,n)&&(X(this,G,Gt).call(this,A(this,he)[n],"expire"),t=!0);return t}info(t){let n=A(this,we).get(t);if(n===void 0)return;let u=A(this,ne)[n],o=X(this,G,pe).call(this,u)?u.__staleWhileFetching:u;if(o===void 0)return;let r={value:o};if(A(this,Qe)&&A(this,ft)){let a=A(this,Qe)[n],s=A(this,ft)[n];if(a&&s){let c=a-(A(this,st).now()-s);r.ttl=c,r.start=Date.now()}}return A(this,dt)&&(r.size=A(this,dt)[n]),r}dump(){let t=[];for(let n of X(this,G,$t).call(this,{allowStale:!0})){let u=A(this,he)[n],o=A(this,ne)[n],r=X(this,G,pe).call(this,o)?o.__staleWhileFetching:o;if(r===void 0||u===void 0)continue;let a={value:r};if(A(this,Qe)&&A(this,ft)){a.ttl=A(this,Qe)[n];let s=A(this,st).now()-A(this,ft)[n];a.start=Math.floor(Date.now()-s)}A(this,dt)&&(a.size=A(this,dt)[n]),t.unshift([u,a])}return t}load(t){this.clear();for(let[n,u]of t){if(u.start){let o=Date.now()-u.start;u.start=A(this,st).now()-o}this.set(n,u.value,u)}}set(t,n,u={}){var p,m,h,x,y,v,g;if(n===void 0)return this.delete(t),this;let{ttl:o=this.ttl,start:r,noDisposeOnSet:a=this.noDisposeOnSet,sizeCalculation:s=this.sizeCalculation,status:c}=u,{noUpdateTTL:d=this.noUpdateTTL}=u,f=A(this,vr).call(this,t,n,u.size||0,s);if(this.maxEntrySize&&f>this.maxEntrySize)return c&&(c.set="miss",c.maxEntrySizeExceeded=!0),X(this,G,Gt).call(this,t,"set"),this;let l=A(this,Ce)===0?void 0:A(this,we).get(t);if(l===void 0)l=A(this,Ce)===0?A(this,Fe):A(this,lt).length!==0?A(this,lt).pop():A(this,Ce)===A(this,rt)?X(this,G,Au).call(this,!1):A(this,Ce),A(this,he)[l]=t,A(this,ne)[l]=n,A(this,we).set(t,l),A(this,je)[A(this,Fe)]=l,A(this,Ke)[l]=A(this,Fe),ee(this,Fe,l),vu(this,Ce)._++,A(this,_n).call(this,l,f,c),c&&(c.set="add"),d=!1,A(this,En)&&((p=A(this,Jt))==null||p.call(this,n,t,"add"));else{X(this,G,Cr).call(this,l);let b=A(this,ne)[l];if(n!==b){if(A(this,Ht)&&X(this,G,pe).call(this,b)){b.__abortController.abort(new Error("replaced"));let{__staleWhileFetching:w}=b;w!==void 0&&!a&&(A(this,ht)&&((m=A(this,it))==null||m.call(this,w,t,"set")),A(this,He)&&((h=A(this,De))==null||h.push([w,t,"set"])))}else a||(A(this,ht)&&((x=A(this,it))==null||x.call(this,b,t,"set")),A(this,He)&&((y=A(this,De))==null||y.push([b,t,"set"])));if(A(this,tn).call(this,l),A(this,_n).call(this,l,f,c),A(this,ne)[l]=n,c){c.set="replace";let w=b&&X(this,G,pe).call(this,b)?b.__staleWhileFetching:b;w!==void 0&&(c.oldValue=w)}}else c&&(c.set="update");A(this,En)&&((v=this.onInsert)==null||v.call(this,n,t,n===b?"update":"replace"))}if(o!==0&&!A(this,Qe)&&X(this,G,Yo).call(this),A(this,Qe)&&(d||A(this,wr).call(this,l,o,r),c&&A(this,St).call(this,c,l)),!a&&A(this,He)&&A(this,De)){let b=A(this,De),w;for(;w=b==null?void 0:b.shift();)(g=A(this,at))==null||g.call(this,...w)}return this}pop(){var t;try{for(;A(this,Ce);){let n=A(this,ne)[A(this,Pe)];if(X(this,G,Au).call(this,!0),X(this,G,pe).call(this,n)){if(n.__staleWhileFetching)return n.__staleWhileFetching}else if(n!==void 0)return n}}finally{if(A(this,He)&&A(this,De)){let n=A(this,De),u;for(;u=n==null?void 0:n.shift();)(t=A(this,at))==null||t.call(this,...u)}}}has(t,n={}){let{updateAgeOnHas:u=this.updateAgeOnHas,status:o}=n,r=A(this,we).get(t);if(r!==void 0){let a=A(this,ne)[r];if(X(this,G,pe).call(this,a)&&a.__staleWhileFetching===void 0)return!1;if(A(this,et).call(this,r))o&&(o.has="stale",A(this,St).call(this,o,r));else return u&&A(this,en).call(this,r),o&&(o.has="hit",A(this,St).call(this,o,r)),!0}else o&&(o.has="miss");return!1}peek(t,n={}){let{allowStale:u=this.allowStale}=n,o=A(this,we).get(t);if(o===void 0||!u&&A(this,et).call(this,o))return;let r=A(this,ne)[o];return X(this,G,pe).call(this,r)?r.__staleWhileFetching:r}async fetch(t,n={}){let{allowStale:u=this.allowStale,updateAgeOnGet:o=this.updateAgeOnGet,noDeleteOnStaleGet:r=this.noDeleteOnStaleGet,ttl:a=this.ttl,noDisposeOnSet:s=this.noDisposeOnSet,size:c=0,sizeCalculation:d=this.sizeCalculation,noUpdateTTL:f=this.noUpdateTTL,noDeleteOnFetchRejection:l=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:p=this.allowStaleOnFetchRejection,ignoreFetchAbort:m=this.ignoreFetchAbort,allowStaleOnFetchAbort:h=this.allowStaleOnFetchAbort,context:x,forceRefresh:y=!1,status:v,signal:g}=n;if(!A(this,Ht))return v&&(v.fetch="get"),this.get(t,{allowStale:u,updateAgeOnGet:o,noDeleteOnStaleGet:r,status:v});let b={allowStale:u,updateAgeOnGet:o,noDeleteOnStaleGet:r,ttl:a,noDisposeOnSet:s,size:c,sizeCalculation:d,noUpdateTTL:f,noDeleteOnFetchRejection:l,allowStaleOnFetchRejection:p,allowStaleOnFetchAbort:h,ignoreFetchAbort:m,status:v,signal:g},w=A(this,we).get(t);if(w===void 0){v&&(v.fetch="miss");let k=X(this,G,ku).call(this,t,w,b,x);return k.__returned=k}else{let k=A(this,ne)[w];if(X(this,G,pe).call(this,k)){let W=u&&k.__staleWhileFetching!==void 0;return v&&(v.fetch="inflight",W&&(v.returnedStale=!0)),W?k.__staleWhileFetching:k.__returned=k}let S=A(this,et).call(this,w);if(!y&&!S)return v&&(v.fetch="hit"),X(this,G,Cr).call(this,w),o&&A(this,en).call(this,w),v&&A(this,St).call(this,v,w),k;let _=X(this,G,ku).call(this,t,w,b,x),E=_.__staleWhileFetching!==void 0&&u;return v&&(v.fetch=S?"stale":"refresh",E&&S&&(v.returnedStale=!0)),E?_.__staleWhileFetching:_.__returned=_}}async forceFetch(t,n={}){let u=await this.fetch(t,n);if(u===void 0)throw new Error("fetch() returned undefined");return u}memo(t,n={}){let u=A(this,Cn);if(!u)throw new Error("no memoMethod provided to constructor");let{context:o,forceRefresh:r,...a}=n,s=this.get(t,a);if(!r&&s!==void 0)return s;let c=u(t,s,{options:a,context:o});return this.set(t,c,a),c}get(t,n={}){let{allowStale:u=this.allowStale,updateAgeOnGet:o=this.updateAgeOnGet,noDeleteOnStaleGet:r=this.noDeleteOnStaleGet,status:a}=n,s=A(this,we).get(t);if(s!==void 0){let c=A(this,ne)[s],d=X(this,G,pe).call(this,c);return a&&A(this,St).call(this,a,s),A(this,et).call(this,s)?(a&&(a.get="stale"),d?(a&&u&&c.__staleWhileFetching!==void 0&&(a.returnedStale=!0),u?c.__staleWhileFetching:void 0):(r||X(this,G,Gt).call(this,t,"expire"),a&&u&&(a.returnedStale=!0),u?c:void 0)):(a&&(a.get="hit"),d?c.__staleWhileFetching:(X(this,G,Cr).call(this,s),o&&A(this,en).call(this,s),c))}else a&&(a.get="miss")}delete(t){return X(this,G,Gt).call(this,t,"delete")}clear(){return X(this,G,Jo).call(this,"delete")}},rt=new WeakMap,Ye=new WeakMap,it=new WeakMap,Jt=new WeakMap,at=new WeakMap,kn=new WeakMap,Cn=new WeakMap,st=new WeakMap,Ce=new WeakMap,ct=new WeakMap,we=new WeakMap,he=new WeakMap,ne=new WeakMap,je=new WeakMap,Ke=new WeakMap,Pe=new WeakMap,Fe=new WeakMap,lt=new WeakMap,De=new WeakMap,dt=new WeakMap,ft=new WeakMap,Qe=new WeakMap,Je=new WeakMap,ht=new WeakMap,Ht=new WeakMap,He=new WeakMap,En=new WeakMap,G=new WeakSet,Yo=function(){let t=new ru(A(this,rt)),n=new ru(A(this,rt));ee(this,Qe,t),ee(this,ft,n);let u=this.ttlAutopurge?new Array(A(this,rt)):void 0;ee(this,Je,u),ee(this,wr,(s,c,d=A(this,st).now())=>{n[s]=c!==0?d:0,t[s]=c,o(s,c)}),ee(this,en,s=>{n[s]=t[s]!==0?A(this,st).now():0,o(s,t[s])});let o=this.ttlAutopurge?(s,c)=>{if(u!=null&&u[s]&&(clearTimeout(u[s]),u[s]=void 0),c&&c!==0&&u){let d=setTimeout(()=>{A(this,et).call(this,s)&&X(this,G,Gt).call(this,A(this,he)[s],"expire")},c+1);d.unref&&d.unref(),u[s]=d}}:()=>{};ee(this,St,(s,c)=>{if(t[c]){let d=t[c],f=n[c];if(!d||!f)return;s.ttl=d,s.start=f,s.now=r||a();let l=s.now-f;s.remainingTTL=d-l}});let r=0,a=()=>{let s=A(this,st).now();if(this.ttlResolution>0){r=s;let c=setTimeout(()=>r=0,this.ttlResolution);c.unref&&c.unref()}return s};this.getRemainingTTL=s=>{let c=A(this,we).get(s);if(c===void 0)return 0;let d=t[c],f=n[c];if(!d||!f)return 1/0;let l=(r||a())-f;return d-l},ee(this,et,s=>{let c=n[s],d=t[s];return!!d&&!!c&&(r||a())-c>d})},en=new WeakMap,St=new WeakMap,wr=new WeakMap,et=new WeakMap,Vc=function(){let t=new ru(A(this,rt));ee(this,ct,0),ee(this,dt,t),ee(this,tn,n=>{ee(this,ct,A(this,ct)-t[n]),t[n]=0}),ee(this,vr,(n,u,o,r)=>{if(X(this,G,pe).call(this,u))return 0;if(!Vt(o))if(r){if(typeof r!="function")throw new TypeError("sizeCalculation must be a function");if(o=r(u,n),!Vt(o))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return o}),ee(this,_n,(n,u,o)=>{if(t[n]=u,A(this,Ye)){let r=A(this,Ye)-t[n];for(;A(this,ct)>r;)X(this,G,Au).call(this,!0)}ee(this,ct,A(this,ct)+t[n]),o&&(o.entrySize=u,o.totalCalculatedSize=A(this,ct))})},tn=new WeakMap,_n=new WeakMap,vr=new WeakMap,$t=function*({allowStale:t=this.allowStale}={}){if(A(this,Ce))for(let n=A(this,Fe);!(!X(this,G,Ko).call(this,n)||((t||!A(this,et).call(this,n))&&(yield n),n===A(this,Pe)));)n=A(this,Ke)[n]},Wt=function*({allowStale:t=this.allowStale}={}){if(A(this,Ce))for(let n=A(this,Pe);!(!X(this,G,Ko).call(this,n)||((t||!A(this,et).call(this,n))&&(yield n),n===A(this,Fe)));)n=A(this,je)[n]},Ko=function(t){return t!==void 0&&A(this,we).get(A(this,he)[t])===t},Au=function(t){var r,a,s;let n=A(this,Pe),u=A(this,he)[n],o=A(this,ne)[n];return A(this,Ht)&&X(this,G,pe).call(this,o)?o.__abortController.abort(new Error("evicted")):(A(this,ht)||A(this,He))&&(A(this,ht)&&((r=A(this,it))==null||r.call(this,o,u,"evict")),A(this,He)&&((a=A(this,De))==null||a.push([o,u,"evict"]))),A(this,tn).call(this,n),(s=A(this,Je))!=null&&s[n]&&(clearTimeout(A(this,Je)[n]),A(this,Je)[n]=void 0),t&&(A(this,he)[n]=void 0,A(this,ne)[n]=void 0,A(this,lt).push(n)),A(this,Ce)===1?(ee(this,Pe,ee(this,Fe,0)),A(this,lt).length=0):ee(this,Pe,A(this,je)[n]),A(this,we).delete(u),vu(this,Ce)._--,n},ku=function(t,n,u,o){let r=n===void 0?void 0:A(this,ne)[n];if(X(this,G,pe).call(this,r))return r;let a=new nu,{signal:s}=u;s==null||s.addEventListener("abort",()=>a.abort(s.reason),{signal:a.signal});let c={signal:a.signal,options:u,context:o},d=(x,y=!1)=>{let{aborted:v}=a.signal,g=u.ignoreFetchAbort&&x!==void 0,b=u.ignoreFetchAbort||!!(u.allowStaleOnFetchAbort&&x!==void 0);if(u.status&&(v&&!y?(u.status.fetchAborted=!0,u.status.fetchError=a.signal.reason,g&&(u.status.fetchAbortIgnored=!0)):u.status.fetchResolved=!0),v&&!g&&!y)return l(a.signal.reason,b);let w=m,k=A(this,ne)[n];return(k===m||g&&y&&k===void 0)&&(x===void 0?w.__staleWhileFetching!==void 0?A(this,ne)[n]=w.__staleWhileFetching:X(this,G,Gt).call(this,t,"fetch"):(u.status&&(u.status.fetchUpdated=!0),this.set(t,x,c.options))),x},f=x=>(u.status&&(u.status.fetchRejected=!0,u.status.fetchError=x),l(x,!1)),l=(x,y)=>{let{aborted:v}=a.signal,g=v&&u.allowStaleOnFetchAbort,b=g||u.allowStaleOnFetchRejection,w=b||u.noDeleteOnFetchRejection,k=m;if(A(this,ne)[n]===m&&(!w||!y&&k.__staleWhileFetching===void 0?X(this,G,Gt).call(this,t,"fetch"):g||(A(this,ne)[n]=k.__staleWhileFetching)),b)return u.status&&k.__staleWhileFetching!==void 0&&(u.status.returnedStale=!0),k.__staleWhileFetching;if(k.__returned===k)throw x},p=(x,y)=>{var g;let v=(g=A(this,kn))==null?void 0:g.call(this,t,r,c);v&&v instanceof Promise&&v.then(b=>x(b===void 0?void 0:b),y),a.signal.addEventListener("abort",()=>{(!u.ignoreFetchAbort||u.allowStaleOnFetchAbort)&&(x(void 0),u.allowStaleOnFetchAbort&&(x=b=>d(b,!0)))})};u.status&&(u.status.fetchDispatched=!0);let m=new Promise(p).then(d,f),h=Object.assign(m,{__abortController:a,__staleWhileFetching:r,__returned:void 0});return n===void 0?(this.set(t,h,{...c.options,status:void 0}),n=A(this,we).get(t)):A(this,ne)[n]=h,h},pe=function(t){if(!A(this,Ht))return!1;let n=t;return!!n&&n instanceof Promise&&n.hasOwnProperty("__staleWhileFetching")&&n.__abortController instanceof nu},Qo=function(t,n){A(this,Ke)[n]=t,A(this,je)[t]=n},Cr=function(t){t!==A(this,Fe)&&(t===A(this,Pe)?ee(this,Pe,A(this,je)[t]):X(this,G,Qo).call(this,A(this,Ke)[t],A(this,je)[t]),X(this,G,Qo).call(this,A(this,Fe),t),ee(this,Fe,t))},Gt=function(t,n){var o,r,a,s,c,d;let u=!1;if(A(this,Ce)!==0){let f=A(this,we).get(t);if(f!==void 0)if((o=A(this,Je))!=null&&o[f]&&(clearTimeout((r=A(this,Je))==null?void 0:r[f]),A(this,Je)[f]=void 0),u=!0,A(this,Ce)===1)X(this,G,Jo).call(this,n);else{A(this,tn).call(this,f);let l=A(this,ne)[f];if(X(this,G,pe).call(this,l)?l.__abortController.abort(new Error("deleted")):(A(this,ht)||A(this,He))&&(A(this,ht)&&((a=A(this,it))==null||a.call(this,l,t,n)),A(this,He)&&((s=A(this,De))==null||s.push([l,t,n]))),A(this,we).delete(t),A(this,he)[f]=void 0,A(this,ne)[f]=void 0,f===A(this,Fe))ee(this,Fe,A(this,Ke)[f]);else if(f===A(this,Pe))ee(this,Pe,A(this,je)[f]);else{let p=A(this,Ke)[f];A(this,je)[p]=A(this,je)[f];let m=A(this,je)[f];A(this,Ke)[m]=A(this,Ke)[f]}vu(this,Ce)._--,A(this,lt).push(f)}}if(A(this,He)&&((c=A(this,De))!=null&&c.length)){let f=A(this,De),l;for(;l=f==null?void 0:f.shift();)(d=A(this,at))==null||d.call(this,...l)}return u},Jo=function(t){var n,u,o,r;for(let a of X(this,G,Wt).call(this,{allowStale:!0})){let s=A(this,ne)[a];if(X(this,G,pe).call(this,s))s.__abortController.abort(new Error("deleted"));else{let c=A(this,he)[a];A(this,ht)&&((n=A(this,it))==null||n.call(this,s,c,t)),A(this,He)&&((u=A(this,De))==null||u.push([s,c,t]))}}if(A(this,we).clear(),A(this,ne).fill(void 0),A(this,he).fill(void 0),A(this,Qe)&&A(this,ft)){A(this,Qe).fill(0),A(this,ft).fill(0);for(let a of A(this,Je)??[])a!==void 0&&clearTimeout(a);(o=A(this,Je))==null||o.fill(void 0)}if(A(this,dt)&&A(this,dt).fill(0),ee(this,Pe,0),ee(this,Fe,0),A(this,lt).length=0,ee(this,ct,0),ee(this,Ce,0),A(this,He)&&A(this,De)){let a=A(this,De),s;for(;s=a==null?void 0:a.shift();)(r=A(this,at))==null||r.call(this,...s)}},Sn);/*! medium-zoom 1.1.0 | MIT License | https://github.com/francoischalifour/medium-zoom */var Yt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var u in n)Object.prototype.hasOwnProperty.call(n,u)&&(e[u]=n[u])}return e},uu=function(t){return t.tagName==="IMG"},f1=function(t){return NodeList.prototype.isPrototypeOf(t)},ou=function(t){return t&&t.nodeType===1},us=function(t){var n=t.currentSrc||t.src;return n.substr(-4).toLowerCase()===".svg"},os=function(t){try{return Array.isArray(t)?t.filter(uu):f1(t)?[].slice.call(t).filter(uu):ou(t)?[t].filter(uu):typeof t=="string"?[].slice.call(document.querySelectorAll(t)).filter(uu):[]}catch{throw new TypeError(`The provided selector is invalid.
30
30
  Expects a CSS selector, a Node element, a NodeList or an array.
31
- See: https://github.com/francoischalifour/medium-zoom`)}},s1=function(t){var n=document.createElement("div");return n.classList.add("medium-zoom-overlay"),n.style.background=t,n},c1=function(t){var n=t.getBoundingClientRect(),u=n.top,o=n.left,r=n.width,a=n.height,s=t.cloneNode(),c=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0,d=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;return s.removeAttribute("id"),s.style.position="absolute",s.style.top=u+c+"px",s.style.left=o+d+"px",s.style.width=r+"px",s.style.height=a+"px",s.style.transform="",s},wn=function(t,n){var u=Zt({bubbles:!1,cancelable:!1,detail:void 0},n);if(typeof window.CustomEvent=="function")return new CustomEvent(t,u);var o=document.createEvent("CustomEvent");return o.initCustomEvent(t,u.bubbles,u.cancelable,u.detail),o},l1=function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=window.Promise||function(M){function D(){}M(D,D)},o=function(M){var D=M.target;if(D===W){h();return}b.indexOf(D)!==-1&&y({target:D})},r=function(){if(!(k||!E.original)){var M=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;Math.abs(S-M)>_.scrollOffset&&setTimeout(h,150)}},a=function(M){var D=M.key||M.keyCode;(D==="Escape"||D==="Esc"||D===27)&&h()},s=function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=M;if(M.background&&(W.style.background=M.background),M.container&&M.container instanceof Object&&(D.container=Zt({},_.container,M.container)),M.template){var j=iu(M.template)?M.template:document.querySelector(M.template);D.template=j}return _=Zt({},_,D),b.forEach(function(H){H.dispatchEvent(wn("medium-zoom:update",{detail:{zoom:B}}))}),B},c=function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return e(Zt({},_,M))},d=function(){for(var M=arguments.length,D=Array(M),j=0;j<M;j++)D[j]=arguments[j];var H=D.reduce(function(F,V){return[].concat(F,is(V))},[]);return H.filter(function(F){return b.indexOf(F)===-1}).forEach(function(F){b.push(F),F.classList.add("medium-zoom-image")}),w.forEach(function(F){var V=F.type,O=F.listener,$=F.options;H.forEach(function(re){re.addEventListener(V,O,$)})}),B},f=function(){for(var M=arguments.length,D=Array(M),j=0;j<M;j++)D[j]=arguments[j];E.zoomed&&h();var H=D.length>0?D.reduce(function(F,V){return[].concat(F,is(V))},[]):b;return H.forEach(function(F){F.classList.remove("medium-zoom-image"),F.dispatchEvent(wn("medium-zoom:detach",{detail:{zoom:B}}))}),b=b.filter(function(F){return H.indexOf(F)===-1}),B},l=function(M,D){var j=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return b.forEach(function(H){H.addEventListener("medium-zoom:"+M,D,j)}),w.push({type:"medium-zoom:"+M,listener:D,options:j}),B},p=function(M,D){var j=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return b.forEach(function(H){H.removeEventListener("medium-zoom:"+M,D,j)}),w=w.filter(function(H){return!(H.type==="medium-zoom:"+M&&H.listener.toString()===D.toString())}),B},m=function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=M.target,j=function(){var F={width:document.documentElement.clientWidth,height:document.documentElement.clientHeight,left:0,top:0,right:0,bottom:0},V=void 0,O=void 0;if(_.container)if(_.container instanceof Object)F=Zt({},F,_.container),V=F.width-F.left-F.right-_.margin*2,O=F.height-F.top-F.bottom-_.margin*2;else{var $=iu(_.container)?_.container:document.querySelector(_.container),re=$.getBoundingClientRect(),te=re.width,P=re.height,R=re.left,N=re.top;F=Zt({},F,{width:te,height:P,left:R,top:N})}V=V||F.width-_.margin*2,O=O||F.height-_.margin*2;var L=E.zoomedHd||E.original,U=os(L)?V:L.naturalWidth||V,K=os(L)?O:L.naturalHeight||O,Z=L.getBoundingClientRect(),Y=Z.top,ue=Z.left,ce=Z.width,De=Z.height,Te=Math.min(Math.max(ce,U),V)/ce,ht=Math.min(Math.max(De,K),O)/De,Pe=Math.min(Te,ht),Dn=(-ue+(V-ce)/2+_.margin+F.left)/Pe,Ht=(-Y+(O-De)/2+_.margin+F.top)/Pe,St="scale("+Pe+") translate3d("+Dn+"px, "+Ht+"px, 0)";E.zoomed.style.transform=St,E.zoomedHd&&(E.zoomedHd.style.transform=St)};return new u(function(H){if(D&&b.indexOf(D)===-1){H(B);return}var F=function te(){k=!1,E.zoomed.removeEventListener("transitionend",te),E.original.dispatchEvent(wn("medium-zoom:opened",{detail:{zoom:B}})),H(B)};if(E.zoomed){H(B);return}if(D)E.original=D;else if(b.length>0){var V=b;E.original=V[0]}else{H(B);return}if(E.original.dispatchEvent(wn("medium-zoom:open",{detail:{zoom:B}})),S=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0,k=!0,E.zoomed=c1(E.original),document.body.appendChild(W),_.template){var O=iu(_.template)?_.template:document.querySelector(_.template);E.template=document.createElement("div"),E.template.appendChild(O.content.cloneNode(!0)),document.body.appendChild(E.template)}if(E.original.parentElement&&E.original.parentElement.tagName==="PICTURE"&&E.original.currentSrc&&(E.zoomed.src=E.original.currentSrc),document.body.appendChild(E.zoomed),window.requestAnimationFrame(function(){document.body.classList.add("medium-zoom--opened")}),E.original.classList.add("medium-zoom-image--hidden"),E.zoomed.classList.add("medium-zoom-image--opened"),E.zoomed.addEventListener("click",h),E.zoomed.addEventListener("transitionend",F),E.original.getAttribute("data-zoom-src")){E.zoomedHd=E.zoomed.cloneNode(),E.zoomedHd.removeAttribute("srcset"),E.zoomedHd.removeAttribute("sizes"),E.zoomedHd.removeAttribute("loading"),E.zoomedHd.src=E.zoomed.getAttribute("data-zoom-src"),E.zoomedHd.onerror=function(){clearInterval($),console.warn("Unable to reach the zoom image target "+E.zoomedHd.src),E.zoomedHd=null,j()};var $=setInterval(function(){E.zoomedHd.complete&&(clearInterval($),E.zoomedHd.classList.add("medium-zoom-image--opened"),E.zoomedHd.addEventListener("click",h),document.body.appendChild(E.zoomedHd),j())},10)}else if(E.original.hasAttribute("srcset")){E.zoomedHd=E.zoomed.cloneNode(),E.zoomedHd.removeAttribute("sizes"),E.zoomedHd.removeAttribute("loading");var re=E.zoomedHd.addEventListener("load",function(){E.zoomedHd.removeEventListener("load",re),E.zoomedHd.classList.add("medium-zoom-image--opened"),E.zoomedHd.addEventListener("click",h),document.body.appendChild(E.zoomedHd),j()})}else j()})},h=function(){return new u(function(M){if(k||!E.original){M(B);return}var D=function j(){E.original.classList.remove("medium-zoom-image--hidden"),document.body.removeChild(E.zoomed),E.zoomedHd&&document.body.removeChild(E.zoomedHd),document.body.removeChild(W),E.zoomed.classList.remove("medium-zoom-image--opened"),E.template&&document.body.removeChild(E.template),k=!1,E.zoomed.removeEventListener("transitionend",j),E.original.dispatchEvent(wn("medium-zoom:closed",{detail:{zoom:B}})),E.original=null,E.zoomed=null,E.zoomedHd=null,E.template=null,M(B)};k=!0,document.body.classList.remove("medium-zoom--opened"),E.zoomed.style.transform="",E.zoomedHd&&(E.zoomedHd.style.transform=""),E.template&&(E.template.style.transition="opacity 150ms",E.template.style.opacity=0),E.original.dispatchEvent(wn("medium-zoom:close",{detail:{zoom:B}})),E.zoomed.addEventListener("transitionend",D)})},y=function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=M.target;return E.original?h():m({target:D})},x=function(){return _},v=function(){return b},g=function(){return E.original},b=[],w=[],k=!1,S=0,_=n,E={original:null,zoomed:null,zoomedHd:null,template:null};Object.prototype.toString.call(t)==="[object Object]"?_=t:(t||typeof t=="string")&&d(t),_=Zt({margin:0,background:"#fff",scrollOffset:40,container:null,template:null},_);var W=s1(_.background);document.addEventListener("click",o),document.addEventListener("keyup",a),document.addEventListener("scroll",r),window.addEventListener("resize",h);var B={open:m,close:h,toggle:y,update:s,clone:c,attach:d,detach:f,on:l,off:p,getOptions:x,getImages:v,getZoomedImage:g};return B};function d1(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var u=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",n==="top"&&u.firstChild?u.insertBefore(o,u.firstChild):u.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}var f1=".medium-zoom-overlay{position:fixed;top:0;right:0;bottom:0;left:0;opacity:0;transition:opacity .3s;will-change:opacity}.medium-zoom--opened .medium-zoom-overlay{cursor:pointer;cursor:zoom-out;opacity:1}.medium-zoom-image{cursor:pointer;cursor:zoom-in;transition:transform .3s cubic-bezier(.2,0,.2,1)!important}.medium-zoom-image--hidden{visibility:hidden}.medium-zoom-image--opened{position:relative;cursor:pointer;cursor:zoom-out;will-change:transform}";d1(f1);const Mt={hljs:`${q}-hljs`,hlcss:`${q}-hlCss`,mermaidM:`${q}-mermaid-m`,mermaid:`${q}-mermaid`,katexjs:`${q}-katex`,katexcss:`${q}-katexCss`,echarts:`${q}-echarts`},h1=(e,{editorId:t,rootRef:n,setting:u})=>{const o=ut.editorExtensions.highlight,r=ut.editorExtensionsAttrs.highlight;i.provide("editorId",t),i.provide("rootRef",n),i.provide("theme",i.computed(()=>e.theme)),i.provide("language",i.computed(()=>e.language)),i.provide("highlight",i.computed(()=>{const{js:s}=o,c={...yo,...o.css},{js:d,css:f={}}=r||{},l=e.codeStyleReverse&&e.codeStyleReverseList.includes(e.previewTheme)?"dark":e.theme,p=c[e.codeTheme]?c[e.codeTheme][l]:yo.atom[l],m=c[e.codeTheme]&&f[e.codeTheme]?f[e.codeTheme][l]:f.atom?f.atom[l]:{};return{js:{src:s,...d},css:{href:p,...m}}})),i.provide("showCodeRowNumber",e.showCodeRowNumber);const a=i.computed(()=>{const s={...Za,...ut.editorConfig.languageUserDefined};return go(tr(Za["en-US"]),s[e.language]||{})});return i.provide("usedLanguageText",a),i.provide("previewTheme",i.computed(()=>e.previewTheme)),i.provide("customIcon",i.computed(()=>e.customIcon)),i.provide("setting",i.computed(()=>u?{...u}:{preview:!0,htmlPreview:!1,previewOnly:!1,pageFullscreen:!1,fullscreen:!1})),{editorId:t}},p1=e=>{const t=i.useId();return e.id||e.editorId||`${q}-${t}`},m1=(e,t,n)=>{const u=i.inject("editorId"),o=i.inject("rootRef"),r=i.inject("usedLanguageText"),a=i.inject("setting"),s=()=>{o.value.querySelectorAll(`#${u} .${q}-preview .${q}-code`).forEach(f=>{let l=-1;const p=f.querySelector(`.${q}-copy-button:not([data-processed])`);p&&(p.onclick=m=>{m.preventDefault(),clearTimeout(l);const h=(f.querySelector("input:checked + pre code")||f.querySelector("pre code")).textContent,{text:y,successTips:x,failTips:v}=r.value.copyCode;let g=x;Ka(e.formatCopiedText(h||"")).catch(()=>{g=v}).finally(()=>{p.dataset.isIcon?p.dataset.tips=g:p.innerHTML=g,l=window.setTimeout(()=>{p.dataset.isIcon?p.dataset.tips=y:p.innerHTML=y},1500)})},p.setAttribute("data-processed","true"))})},c=()=>{i.nextTick(s)},d=f=>{f&&i.nextTick(s)};i.watch([t,n],c),i.watch(()=>a.value.preview,d),i.watch(()=>a.value.htmlPreview,d),i.onMounted(s)},g1=e=>{const t=i.inject("editorId"),n=i.inject("theme"),u=i.inject("rootRef"),{editorExtensions:o,editorExtensionsAttrs:r}=ut;let a=o.echarts.instance;const s=i.shallowRef(-1),c=()=>{!e.noEcharts&&a&&(s.value=s.value+1)};i.watch(()=>n.value,()=>{c()}),i.onMounted(()=>{var y;if(e.noEcharts||a)return;const h=o.echarts.js;Rt("script",{...(y=r.echarts)==null?void 0:y.js,src:h,id:Mt.echarts,onload(){a=window.echarts,c()}},"echarts")});let d=[],f=[],l=[];const p=(h=!1)=>{if(!d.length){h&&(f.forEach(g=>{var b;(b=g.dispose)==null||b.call(g)}),l.forEach(g=>{var b;(b=g.disconnect)==null||b.call(g)}),f=[],l=[]);return}const y=[],x=[],v=[];d.forEach((g,b)=>{var S,_;const w=f[b],k=l[b];if(h||!g||!g.isConnected||u!=null&&u.value&&!u.value.contains(g)){(S=w==null?void 0:w.dispose)==null||S.call(w),(_=k==null?void 0:k.disconnect)==null||_.call(k);return}y.push(g),w&&x.push(w),k&&v.push(k)}),d=y,f=x,l=v},m=()=>{p(),!e.noEcharts&&a&&Array.from(u.value.querySelectorAll(`#${t} div.${q}-echarts:not([data-processed])`)).forEach(h=>{if(h.dataset.closed==="false")return!1;try{const y=new Function(`return ${h.innerText}`)(),x=a.init(h,n.value);x.setOption(y),h.setAttribute("data-processed",""),d.push(h),f.push(x);const v=new ResizeObserver(()=>{x.resize()});v.observe(h),l.push(v)}catch(y){tt.emit(t,xo,{name:"echarts",message:y==null?void 0:y.message,error:y})}})};return i.onBeforeUnmount(()=>{p(!0)}),{reRenderEcharts:s,replaceEcharts:m}},b1=e=>{const t=i.inject("highlight"),n=i.shallowRef(ut.editorExtensions.highlight.instance);return i.onMounted(()=>{e.noHighlight||n.value||(Rt("link",{...t.value.css,rel:"stylesheet",id:Mt.hlcss}),Rt("script",{...t.value.js,id:Mt.hljs,onload(){n.value=window.hljs}},"hljs"))}),i.watch(()=>t.value.css,()=>{e.noHighlight||ut.editorExtensions.highlight.instance||Wh("link",{...t.value.css,rel:"stylesheet",id:Mt.hlcss})}),n},y1=e=>{const t=i.shallowRef(ut.editorExtensions.katex.instance);return i.onMounted(()=>{var o,r;if(e.noKatex||t.value)return;const{editorExtensions:n,editorExtensionsAttrs:u}=ut;Rt("script",{...(o=u.katex)==null?void 0:o.js,src:n.katex.js,id:Mt.katexjs,onload(){t.value=window.katex}},"katex"),Rt("link",{...(r=u.katex)==null?void 0:r.css,rel:"stylesheet",href:n.katex.css,id:Mt.katexcss})}),t},au=new i1({max:1e3,ttl:6e5}),x1=e=>{const t=i.inject("editorId"),n=i.inject("theme"),u=i.inject("rootRef"),{editorExtensions:o,editorExtensionsAttrs:r,mermaidConfig:a}=ut;let s=o.mermaid.instance;const c=i.shallowRef(-1),d=()=>{if(!e.noMermaid&&s){const f=n.value==="dark"?{startOnLoad:!1,theme:"dark"}:{startOnLoad:!1,theme:"base",themeVariables:{background:"#ffffff",primaryColor:"#ffffff",primaryTextColor:"#1f2329",primaryBorderColor:"#b7c0cc",secondaryColor:"#f7f8fa",tertiaryColor:"#f7f8fa",lineColor:"#596273",edgeLabelBackground:"#ffffff",clusterBkg:"#ffffff",clusterBorder:"#b7c0cc"}};s.initialize(a(f)),c.value=c.value+1}};return i.watch(()=>n.value,()=>{au.clear(),d()}),i.onMounted(()=>{var l,p;if(e.noMermaid||s)return;const f=o.mermaid.js;/\.mjs/.test(f)?(Rt("link",{...(l=r.mermaid)==null?void 0:l.js,rel:"modulepreload",href:f,id:Mt.mermaidM}),import(f).then(m=>{s=m.default,d()}).catch(m=>{tt.emit(t,xo,{name:"mermaid",message:`Failed to load mermaid module: ${m.message}`,error:m})})):Rt("script",{...(p=r.mermaid)==null?void 0:p.js,src:f,id:Mt.mermaid,onload(){s=window.mermaid,d()}},"mermaid")}),{reRenderRef:c,replaceMermaid:async()=>{if(!e.noMermaid&&s){const f=u.value.querySelectorAll(`div.${q}-mermaid`),l=document.createElement("div"),p=document.body.offsetWidth>1366?document.body.offsetWidth:1366,m=document.body.offsetHeight>768?document.body.offsetHeight:768;l.style.width=p+"px",l.style.height=m+"px",l.style.position="fixed",l.style.zIndex="-10000",l.style.top="-10000";let h=f.length;h>0&&document.body.appendChild(l),await Promise.allSettled(Array.from(f).map(y=>(async x=>{var b;if(x.dataset.closed==="false")return!1;const v=x.innerText;let g=au.get(v);if(!g){const w=mo();let k={svg:""};try{k=await s.render(w,v,l),g=await e.sanitizeMermaid(k.svg);const S=document.createElement("p");S.className=`${q}-mermaid`,S.setAttribute("data-processed",""),S.setAttribute("data-content",v),S.innerHTML=g,(b=S.children[0])==null||b.removeAttribute("height"),au.set(v,S.innerHTML),x.dataset.line!==void 0&&(S.dataset.line=x.dataset.line),x.replaceWith(S)}catch(S){tt.emit(t,xo,{name:"mermaid",message:S.message,error:S})}--h===0&&l.remove()}})(y)))}}}},w1=(e,t)=>{t=t||{};const n=3,u=t.marker||"!",o=u.charCodeAt(0),r=u.length;let a="",s="";const c=(f,l,p,m,h)=>{const y=f[l];return y.type==="admonition_open"?f[l].attrPush(["class",`${q}-admonition ${q}-admonition-${y.info}`]):y.type==="admonition_title_open"&&f[l].attrPush(["class",`${q}-admonition-title`]),h.renderToken(f,l,p)},d=f=>{const l=f.trim().split(" ",2);s="",a=l[0],l.length>1&&(s=f.substring(a.length+2))};e.block.ruler.before("code","admonition",(f,l,p,m)=>{let h,y,x,v=!1,g=f.bMarks[l]+f.tShift[l],b=f.eMarks[l];if(o!==f.src.charCodeAt(g))return!1;for(h=g+1;h<=b&&u[(h-g)%r]===f.src[h];h++);const w=Math.floor((h-g)/r);if(w!==n)return!1;h-=(h-g)%r;const k=f.src.slice(g,h),S=f.src.slice(h,b);if(d(S),m)return!0;for(y=l;y++,!(y>=p||(g=f.bMarks[y]+f.tShift[y],b=f.eMarks[y],g<b&&f.sCount[y]<f.blkIndent));)if(o===f.src.charCodeAt(g)&&!(f.sCount[y]-f.blkIndent>=4)){for(h=g+1;h<=b&&u[(h-g)%r]===f.src[h];h++);if(!(Math.floor((h-g)/r)<w)&&(h-=(h-g)%r,h=f.skipSpaces(h),!(h<b))){v=!0;break}}const _=f.parentType,E=f.lineMax;return f.parentType="root",f.lineMax=y,x=f.push("admonition_open","div",1),x.markup=k,x.block=!0,x.info=a,x.map=[l,y],s&&(x=f.push("admonition_title_open","p",1),x.markup=k+" "+a,x.map=[l,y],x=f.push("inline","",0),x.content=s,x.map=[l,f.line-1],x.children=[],x=f.push("admonition_title_close","p",-1),x.markup=k+" "+a),f.md.block.tokenize(f,l+1,y),x=f.push("admonition_close","div",-1),x.markup=f.src.slice(g,h),x.block=!0,f.parentType=_,f.lineMax=E,f.line=y+(v?1:0),!0},{alt:["paragraph","reference","blockquote","list"]}),e.renderer.rules.admonition_open=c,e.renderer.rules.admonition_title_open=c,e.renderer.rules.admonition_title_close=c,e.renderer.rules.admonition_close=c},Ao=(e,t)=>{const n=e.attrs?e.attrs.slice():[];return t.forEach(u=>{const o=e.attrIndex(u[0]);o<0?n.push(u):(n[o]=n[o].slice(),n[o][1]+=` ${u[1]}`)}),n},v1=(e,t)=>{const n=e.renderer.rules.fence,u=e.utils.unescapeAll,o=/\[(\w*)(?::([\w ]*))?\]/,r=/::(open|close)/,a=l=>l.info?u(l.info).trim():"",s=l=>{const p=a(l),[m=null,h=""]=(o.exec(p)||[]).slice(1);return[m,h]},c=l=>{const p=a(l);return p?p.split(/(\s+)/g)[0]:""},d=l=>{const p=l.info.match(r)||[],m=p[1]==="open"||p[1]!=="close"&&t.codeFoldable&&l.content.trim().split(`
32
- `).length<t.autoFoldThreshold,h=p[1]||t.codeFoldable?"details":"div",y=p[1]||t.codeFoldable?"summary":"div";return{open:m,tagContainer:h,tagHeader:y}},f=(l,p,m,h,y)=>{var V;if(l[p].hidden)return"";const x=(V=t.usedLanguageTextRef.value)==null?void 0:V.copyCode.text,v=t.customIconRef.value.copy||x,g=!!t.customIconRef.value.copy,b=`<span class="${q}-collapse-tips">${At("collapse-tips",t.customIconRef.value)}</span>`,[w]=s(l[p]);if(w===null){const{open:O,tagContainer:$,tagHeader:re}=d(l[p]),te=[["class",`${q}-code`]];O&&te.push(["open",""]);const P={attrs:Ao(l[p],te)};l[p].info=l[p].info.replace(r,"");const R=n(l,p,m,h,y);return`
33
- <${$} ${y.renderAttrs(P)}>
31
+ See: https://github.com/francoischalifour/medium-zoom`)}},h1=function(t){var n=document.createElement("div");return n.classList.add("medium-zoom-overlay"),n.style.background=t,n},p1=function(t){var n=t.getBoundingClientRect(),u=n.top,o=n.left,r=n.width,a=n.height,s=t.cloneNode(),c=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0,d=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;return s.removeAttribute("id"),s.style.position="absolute",s.style.top=u+c+"px",s.style.left=o+d+"px",s.style.width=r+"px",s.style.height=a+"px",s.style.transform="",s},xn=function(t,n){var u=Yt({bubbles:!1,cancelable:!1,detail:void 0},n);if(typeof window.CustomEvent=="function")return new CustomEvent(t,u);var o=document.createEvent("CustomEvent");return o.initCustomEvent(t,u.bubbles,u.cancelable,u.detail),o},m1=function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=window.Promise||function(B){function D(){}B(D,D)},o=function(B){var D=B.target;if(D===W){h();return}b.indexOf(D)!==-1&&x({target:D})},r=function(){if(!(k||!E.original)){var B=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;Math.abs(S-B)>_.scrollOffset&&setTimeout(h,150)}},a=function(B){var D=B.key||B.keyCode;(D==="Escape"||D==="Esc"||D===27)&&h()},s=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=B;if(B.background&&(W.style.background=B.background),B.container&&B.container instanceof Object&&(D.container=Yt({},_.container,B.container)),B.template){var j=ou(B.template)?B.template:document.querySelector(B.template);D.template=j}return _=Yt({},_,D),b.forEach(function(H){H.dispatchEvent(xn("medium-zoom:update",{detail:{zoom:V}}))}),V},c=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return e(Yt({},_,B))},d=function(){for(var B=arguments.length,D=Array(B),j=0;j<B;j++)D[j]=arguments[j];var H=D.reduce(function(F,R){return[].concat(F,os(R))},[]);return H.filter(function(F){return b.indexOf(F)===-1}).forEach(function(F){b.push(F),F.classList.add("medium-zoom-image")}),w.forEach(function(F){var R=F.type,I=F.listener,U=F.options;H.forEach(function(re){re.addEventListener(R,I,U)})}),V},f=function(){for(var B=arguments.length,D=Array(B),j=0;j<B;j++)D[j]=arguments[j];E.zoomed&&h();var H=D.length>0?D.reduce(function(F,R){return[].concat(F,os(R))},[]):b;return H.forEach(function(F){F.classList.remove("medium-zoom-image"),F.dispatchEvent(xn("medium-zoom:detach",{detail:{zoom:V}}))}),b=b.filter(function(F){return H.indexOf(F)===-1}),V},l=function(B,D){var j=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return b.forEach(function(H){H.addEventListener("medium-zoom:"+B,D,j)}),w.push({type:"medium-zoom:"+B,listener:D,options:j}),V},p=function(B,D){var j=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return b.forEach(function(H){H.removeEventListener("medium-zoom:"+B,D,j)}),w=w.filter(function(H){return!(H.type==="medium-zoom:"+B&&H.listener.toString()===D.toString())}),V},m=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=B.target,j=function(){var F={width:document.documentElement.clientWidth,height:document.documentElement.clientHeight,left:0,top:0,right:0,bottom:0},R=void 0,I=void 0;if(_.container)if(_.container instanceof Object)F=Yt({},F,_.container),R=F.width-F.left-F.right-_.margin*2,I=F.height-F.top-F.bottom-_.margin*2;else{var U=ou(_.container)?_.container:document.querySelector(_.container),re=U.getBoundingClientRect(),te=re.width,P=re.height,M=re.left,T=re.top;F=Yt({},F,{width:te,height:P,left:M,top:T})}R=R||F.width-_.margin*2,I=I||F.height-_.margin*2;var L=E.zoomedHd||E.original,$=us(L)?R:L.naturalWidth||R,K=us(L)?I:L.naturalHeight||I,Z=L.getBoundingClientRect(),Y=Z.top,ue=Z.left,ce=Z.width,Te=Z.height,Ne=Math.min(Math.max(ce,$),R)/ce,pt=Math.min(Math.max(Te,K),I)/Te,Re=Math.min(Ne,pt),Fn=(-ue+(R-ce)/2+_.margin+F.left)/Re,Ut=(-Y+(I-Te)/2+_.margin+F.top)/Re,Ft="scale("+Re+") translate3d("+Fn+"px, "+Ut+"px, 0)";E.zoomed.style.transform=Ft,E.zoomedHd&&(E.zoomedHd.style.transform=Ft)};return new u(function(H){if(D&&b.indexOf(D)===-1){H(V);return}var F=function te(){k=!1,E.zoomed.removeEventListener("transitionend",te),E.original.dispatchEvent(xn("medium-zoom:opened",{detail:{zoom:V}})),H(V)};if(E.zoomed){H(V);return}if(D)E.original=D;else if(b.length>0){var R=b;E.original=R[0]}else{H(V);return}if(E.original.dispatchEvent(xn("medium-zoom:open",{detail:{zoom:V}})),S=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0,k=!0,E.zoomed=p1(E.original),document.body.appendChild(W),_.template){var I=ou(_.template)?_.template:document.querySelector(_.template);E.template=document.createElement("div"),E.template.appendChild(I.content.cloneNode(!0)),document.body.appendChild(E.template)}if(E.original.parentElement&&E.original.parentElement.tagName==="PICTURE"&&E.original.currentSrc&&(E.zoomed.src=E.original.currentSrc),document.body.appendChild(E.zoomed),window.requestAnimationFrame(function(){document.body.classList.add("medium-zoom--opened")}),E.original.classList.add("medium-zoom-image--hidden"),E.zoomed.classList.add("medium-zoom-image--opened"),E.zoomed.addEventListener("click",h),E.zoomed.addEventListener("transitionend",F),E.original.getAttribute("data-zoom-src")){E.zoomedHd=E.zoomed.cloneNode(),E.zoomedHd.removeAttribute("srcset"),E.zoomedHd.removeAttribute("sizes"),E.zoomedHd.removeAttribute("loading"),E.zoomedHd.src=E.zoomed.getAttribute("data-zoom-src"),E.zoomedHd.onerror=function(){clearInterval(U),console.warn("Unable to reach the zoom image target "+E.zoomedHd.src),E.zoomedHd=null,j()};var U=setInterval(function(){E.zoomedHd.complete&&(clearInterval(U),E.zoomedHd.classList.add("medium-zoom-image--opened"),E.zoomedHd.addEventListener("click",h),document.body.appendChild(E.zoomedHd),j())},10)}else if(E.original.hasAttribute("srcset")){E.zoomedHd=E.zoomed.cloneNode(),E.zoomedHd.removeAttribute("sizes"),E.zoomedHd.removeAttribute("loading");var re=E.zoomedHd.addEventListener("load",function(){E.zoomedHd.removeEventListener("load",re),E.zoomedHd.classList.add("medium-zoom-image--opened"),E.zoomedHd.addEventListener("click",h),document.body.appendChild(E.zoomedHd),j()})}else j()})},h=function(){return new u(function(B){if(k||!E.original){B(V);return}var D=function j(){E.original.classList.remove("medium-zoom-image--hidden"),document.body.removeChild(E.zoomed),E.zoomedHd&&document.body.removeChild(E.zoomedHd),document.body.removeChild(W),E.zoomed.classList.remove("medium-zoom-image--opened"),E.template&&document.body.removeChild(E.template),k=!1,E.zoomed.removeEventListener("transitionend",j),E.original.dispatchEvent(xn("medium-zoom:closed",{detail:{zoom:V}})),E.original=null,E.zoomed=null,E.zoomedHd=null,E.template=null,B(V)};k=!0,document.body.classList.remove("medium-zoom--opened"),E.zoomed.style.transform="",E.zoomedHd&&(E.zoomedHd.style.transform=""),E.template&&(E.template.style.transition="opacity 150ms",E.template.style.opacity=0),E.original.dispatchEvent(xn("medium-zoom:close",{detail:{zoom:V}})),E.zoomed.addEventListener("transitionend",D)})},x=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=B.target;return E.original?h():m({target:D})},y=function(){return _},v=function(){return b},g=function(){return E.original},b=[],w=[],k=!1,S=0,_=n,E={original:null,zoomed:null,zoomedHd:null,template:null};Object.prototype.toString.call(t)==="[object Object]"?_=t:(t||typeof t=="string")&&d(t),_=Yt({margin:0,background:"#fff",scrollOffset:40,container:null,template:null},_);var W=h1(_.background);document.addEventListener("click",o),document.addEventListener("keyup",a),document.addEventListener("scroll",r),window.addEventListener("resize",h);var V={open:m,close:h,toggle:x,update:s,clone:c,attach:d,detach:f,on:l,off:p,getOptions:y,getImages:v,getZoomedImage:g};return V};function g1(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(typeof document>"u")){var u=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",n==="top"&&u.firstChild?u.insertBefore(o,u.firstChild):u.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}var b1=".medium-zoom-overlay{position:fixed;top:0;right:0;bottom:0;left:0;opacity:0;transition:opacity .3s;will-change:opacity}.medium-zoom--opened .medium-zoom-overlay{cursor:pointer;cursor:zoom-out;opacity:1}.medium-zoom-image{cursor:pointer;cursor:zoom-in;transition:transform .3s cubic-bezier(.2,0,.2,1)!important}.medium-zoom-image--hidden{visibility:hidden}.medium-zoom-image--opened{position:relative;cursor:pointer;cursor:zoom-out;will-change:transform}";g1(b1);const Bt={hljs:`${q}-hljs`,hlcss:`${q}-hlCss`,mermaidM:`${q}-mermaid-m`,mermaid:`${q}-mermaid`,katexjs:`${q}-katex`,katexcss:`${q}-katexCss`,echarts:`${q}-echarts`},y1=(e,{editorId:t,rootRef:n,setting:u})=>{const o=ot.editorExtensions.highlight,r=ot.editorExtensionsAttrs.highlight;i.provide("editorId",t),i.provide("rootRef",n),i.provide("theme",i.computed(()=>e.theme)),i.provide("language",i.computed(()=>e.language)),i.provide("highlight",i.computed(()=>{const{js:s}=o,c={...bo,...o.css},{js:d,css:f={}}=r||{},l=e.codeStyleReverse&&e.codeStyleReverseList.includes(e.previewTheme)?"dark":e.theme,p=c[e.codeTheme]?c[e.codeTheme][l]:bo.atom[l],m=c[e.codeTheme]&&f[e.codeTheme]?f[e.codeTheme][l]:f.atom?f.atom[l]:{};return{js:{src:s,...d},css:{href:p,...m}}})),i.provide("showCodeRowNumber",e.showCodeRowNumber);const a=i.computed(()=>{const s={...Xa,...ot.editorConfig.languageUserDefined};return mo(nr(Xa["en-US"]),s[e.language]||{})});return i.provide("usedLanguageText",a),i.provide("previewTheme",i.computed(()=>e.previewTheme)),i.provide("customIcon",i.computed(()=>e.customIcon)),i.provide("setting",i.computed(()=>u?{...u}:{preview:!0,htmlPreview:!1,previewOnly:!1,pageFullscreen:!1,fullscreen:!1})),{editorId:t}},x1=e=>{const t=i.useId();return e.id||e.editorId||`${q}-${t}`},w1=(e,t,n)=>{const u=i.inject("editorId"),o=i.inject("rootRef"),r=i.inject("usedLanguageText"),a=i.inject("setting"),s=()=>{o.value.querySelectorAll(`#${u} .${q}-preview .${q}-code`).forEach(f=>{let l=-1;const p=f.querySelector(`.${q}-copy-button:not([data-processed])`);p&&(p.onclick=m=>{m.preventDefault(),clearTimeout(l);const h=(f.querySelector("input:checked + pre code")||f.querySelector("pre code")).textContent,{text:x,successTips:y,failTips:v}=r.value.copyCode;let g=y;Ya(e.formatCopiedText(h||"")).catch(()=>{g=v}).finally(()=>{p.dataset.isIcon?p.dataset.tips=g:p.innerHTML=g,l=window.setTimeout(()=>{p.dataset.isIcon?p.dataset.tips=x:p.innerHTML=x},1500)})},p.setAttribute("data-processed","true"))})},c=()=>{i.nextTick(s)},d=f=>{f&&i.nextTick(s)};i.watch([t,n],c),i.watch(()=>a.value.preview,d),i.watch(()=>a.value.htmlPreview,d),i.onMounted(s)},v1=e=>{const t=i.inject("editorId"),n=i.inject("theme"),u=i.inject("rootRef"),{editorExtensions:o,editorExtensionsAttrs:r}=ot;let a=o.echarts.instance;const s=i.shallowRef(-1),c=()=>{!e.noEcharts&&a&&(s.value=s.value+1)};i.watch(()=>n.value,()=>{c()}),i.onMounted(()=>{var x;if(e.noEcharts||a)return;const h=o.echarts.js;Mt("script",{...(x=r.echarts)==null?void 0:x.js,src:h,id:Bt.echarts,onload(){a=window.echarts,c()}},"echarts")});let d=[],f=[],l=[];const p=(h=!1)=>{if(!d.length){h&&(f.forEach(g=>{var b;(b=g.dispose)==null||b.call(g)}),l.forEach(g=>{var b;(b=g.disconnect)==null||b.call(g)}),f=[],l=[]);return}const x=[],y=[],v=[];d.forEach((g,b)=>{var S,_;const w=f[b],k=l[b];if(h||!g||!g.isConnected||u!=null&&u.value&&!u.value.contains(g)){(S=w==null?void 0:w.dispose)==null||S.call(w),(_=k==null?void 0:k.disconnect)==null||_.call(k);return}x.push(g),w&&y.push(w),k&&v.push(k)}),d=x,f=y,l=v},m=()=>{p(),!e.noEcharts&&a&&Array.from(u.value.querySelectorAll(`#${t} div.${q}-echarts:not([data-processed])`)).forEach(h=>{if(h.dataset.closed==="false")return!1;try{const x=new Function(`return ${h.innerText}`)(),y=a.init(h,n.value);y.setOption(x),h.setAttribute("data-processed",""),d.push(h),f.push(y);const v=new ResizeObserver(()=>{y.resize()});v.observe(h),l.push(v)}catch(x){nt.emit(t,yo,{name:"echarts",message:x==null?void 0:x.message,error:x})}})};return i.onBeforeUnmount(()=>{p(!0)}),{reRenderEcharts:s,replaceEcharts:m}},A1=e=>{const t=i.inject("highlight"),n=i.shallowRef(ot.editorExtensions.highlight.instance);return i.onMounted(()=>{e.noHighlight||n.value||(Mt("link",{...t.value.css,rel:"stylesheet",id:Bt.hlcss}),Mt("script",{...t.value.js,id:Bt.hljs,onload(){n.value=window.hljs}},"hljs"))}),i.watch(()=>t.value.css,()=>{e.noHighlight||ot.editorExtensions.highlight.instance||Yh("link",{...t.value.css,rel:"stylesheet",id:Bt.hlcss})}),n},k1=e=>{const t=i.shallowRef(ot.editorExtensions.katex.instance);return i.onMounted(()=>{var o,r;if(e.noKatex||t.value)return;const{editorExtensions:n,editorExtensionsAttrs:u}=ot;Mt("script",{...(o=u.katex)==null?void 0:o.js,src:n.katex.js,id:Bt.katexjs,onload(){t.value=window.katex}},"katex"),Mt("link",{...(r=u.katex)==null?void 0:r.css,rel:"stylesheet",href:n.katex.css,id:Bt.katexcss})}),t},iu=new d1({max:1e3,ttl:6e5}),C1=e=>{const t=i.inject("editorId"),n=i.inject("theme"),u=i.inject("rootRef"),{editorExtensions:o,editorExtensionsAttrs:r,mermaidConfig:a}=ot;let s=o.mermaid.instance;const c=i.shallowRef(-1),d=()=>{if(!e.noMermaid&&s){const f=n.value==="dark"?{startOnLoad:!1,theme:"dark"}:{startOnLoad:!1,theme:"base",themeVariables:{background:"#ffffff",primaryColor:"#ffffff",primaryTextColor:"#1f2329",primaryBorderColor:"#b7c0cc",secondaryColor:"#f7f8fa",tertiaryColor:"#f7f8fa",lineColor:"#596273",edgeLabelBackground:"#ffffff",clusterBkg:"#ffffff",clusterBorder:"#b7c0cc"}};s.initialize(a(f)),c.value=c.value+1}};return i.watch(()=>n.value,()=>{iu.clear(),d()}),i.onMounted(()=>{var l,p;if(e.noMermaid||s)return;const f=o.mermaid.js;/\.mjs/.test(f)?(Mt("link",{...(l=r.mermaid)==null?void 0:l.js,rel:"modulepreload",href:f,id:Bt.mermaidM}),import(f).then(m=>{s=m.default,d()}).catch(m=>{nt.emit(t,yo,{name:"mermaid",message:`Failed to load mermaid module: ${m.message}`,error:m})})):Mt("script",{...(p=r.mermaid)==null?void 0:p.js,src:f,id:Bt.mermaid,onload(){s=window.mermaid,d()}},"mermaid")}),{reRenderRef:c,replaceMermaid:async()=>{if(!e.noMermaid&&s){const f=u.value.querySelectorAll(`div.${q}-mermaid`),l=document.createElement("div"),p=document.body.offsetWidth>1366?document.body.offsetWidth:1366,m=document.body.offsetHeight>768?document.body.offsetHeight:768;l.style.width=p+"px",l.style.height=m+"px",l.style.position="fixed",l.style.zIndex="-10000",l.style.top="-10000";let h=f.length;h>0&&document.body.appendChild(l),await Promise.allSettled(Array.from(f).map(x=>(async y=>{var b;if(y.dataset.closed==="false")return!1;const v=y.innerText;let g=iu.get(v);if(!g){const w=po();let k={svg:""};try{k=await s.render(w,v,l),g=await e.sanitizeMermaid(k.svg);const S=document.createElement("p");S.className=`${q}-mermaid`,S.setAttribute("data-processed",""),S.setAttribute("data-content",v),S.innerHTML=g,(b=S.children[0])==null||b.removeAttribute("height"),iu.set(v,S.innerHTML),y.dataset.line!==void 0&&(S.dataset.line=y.dataset.line),y.replaceWith(S)}catch(S){nt.emit(t,yo,{name:"mermaid",message:S.message,error:S})}--h===0&&l.remove()}})(x)))}}}},E1=(e,t)=>{t=t||{};const n=3,u=t.marker||"!",o=u.charCodeAt(0),r=u.length;let a="",s="";const c=(f,l,p,m,h)=>{const x=f[l];return x.type==="admonition_open"?f[l].attrPush(["class",`${q}-admonition ${q}-admonition-${x.info}`]):x.type==="admonition_title_open"&&f[l].attrPush(["class",`${q}-admonition-title`]),h.renderToken(f,l,p)},d=f=>{const l=f.trim().split(" ",2);s="",a=l[0],l.length>1&&(s=f.substring(a.length+2))};e.block.ruler.before("code","admonition",(f,l,p,m)=>{let h,x,y,v=!1,g=f.bMarks[l]+f.tShift[l],b=f.eMarks[l];if(o!==f.src.charCodeAt(g))return!1;for(h=g+1;h<=b&&u[(h-g)%r]===f.src[h];h++);const w=Math.floor((h-g)/r);if(w!==n)return!1;h-=(h-g)%r;const k=f.src.slice(g,h),S=f.src.slice(h,b);if(d(S),m)return!0;for(x=l;x++,!(x>=p||(g=f.bMarks[x]+f.tShift[x],b=f.eMarks[x],g<b&&f.sCount[x]<f.blkIndent));)if(o===f.src.charCodeAt(g)&&!(f.sCount[x]-f.blkIndent>=4)){for(h=g+1;h<=b&&u[(h-g)%r]===f.src[h];h++);if(!(Math.floor((h-g)/r)<w)&&(h-=(h-g)%r,h=f.skipSpaces(h),!(h<b))){v=!0;break}}const _=f.parentType,E=f.lineMax;return f.parentType="root",f.lineMax=x,y=f.push("admonition_open","div",1),y.markup=k,y.block=!0,y.info=a,y.map=[l,x],s&&(y=f.push("admonition_title_open","p",1),y.markup=k+" "+a,y.map=[l,x],y=f.push("inline","",0),y.content=s,y.map=[l,f.line-1],y.children=[],y=f.push("admonition_title_close","p",-1),y.markup=k+" "+a),f.md.block.tokenize(f,l+1,x),y=f.push("admonition_close","div",-1),y.markup=f.src.slice(g,h),y.block=!0,f.parentType=_,f.lineMax=E,f.line=x+(v?1:0),!0},{alt:["paragraph","reference","blockquote","list"]}),e.renderer.rules.admonition_open=c,e.renderer.rules.admonition_title_open=c,e.renderer.rules.admonition_title_close=c,e.renderer.rules.admonition_close=c},vo=(e,t)=>{const n=e.attrs?e.attrs.slice():[];return t.forEach(u=>{const o=e.attrIndex(u[0]);o<0?n.push(u):(n[o]=n[o].slice(),n[o][1]+=` ${u[1]}`)}),n},_1=(e,t)=>{const n=e.renderer.rules.fence,u=e.utils.unescapeAll,o=/\[(\w*)(?::([\w ]*))?\]/,r=/::(open|close)/,a=l=>l.info?u(l.info).trim():"",s=l=>{const p=a(l),[m=null,h=""]=(o.exec(p)||[]).slice(1);return[m,h]},c=l=>{const p=a(l);return p?p.split(/(\s+)/g)[0]:""},d=l=>{const p=l.info.match(r)||[],m=p[1]==="open"||p[1]!=="close"&&t.codeFoldable&&l.content.trim().split(`
32
+ `).length<t.autoFoldThreshold,h=p[1]||t.codeFoldable?"details":"div",x=p[1]||t.codeFoldable?"summary":"div";return{open:m,tagContainer:h,tagHeader:x}},f=(l,p,m,h,x)=>{var R;if(l[p].hidden)return"";const y=(R=t.usedLanguageTextRef.value)==null?void 0:R.copyCode.text,v=t.customIconRef.value.copy||y,g=!!t.customIconRef.value.copy,b=`<span class="${q}-collapse-tips">${kt("collapse-tips",t.customIconRef.value)}</span>`,[w]=s(l[p]);if(w===null){const{open:I,tagContainer:U,tagHeader:re}=d(l[p]),te=[["class",`${q}-code`]];I&&te.push(["open",""]);const P={attrs:vo(l[p],te)};l[p].info=l[p].info.replace(r,"");const M=n(l,p,m,h,x);return`
33
+ <${U} ${x.renderAttrs(P)}>
34
34
  <${re} class="${q}-code-head">
35
35
  <div class="${q}-code-flag"><span></span><span></span><span></span></div>
36
36
  <div class="${q}-code-action">
37
37
  <span class="${q}-code-lang">${e.utils.escapeHtml(l[p].info.trim())}</span>
38
- <span class="${q}-copy-button" data-tips="${x}"${g?" data-is-icon=true":""}>${v}</span>
38
+ <span class="${q}-copy-button" data-tips="${y}"${g?" data-is-icon=true":""}>${v}</span>
39
39
  ${t.extraTools instanceof Function?t.extraTools({lang:l[p].info.trim()}):t.extraTools||""}
40
- ${$==="details"?b:""}
40
+ ${U==="details"?b:""}
41
41
  </div>
42
42
  </${re}>
43
- ${R}
44
- </${$}>
45
- `}let k,S,_,E,W="",B="",I="";const{open:M,tagContainer:D,tagHeader:j}=d(l[p]),H=[["class",`${q}-code`]];M&&H.push(["open",""]);const F={attrs:Ao(l[p],H)};for(let O=p;O<l.length&&(k=l[O],[S,_]=s(k),S===w);O++){k.info=k.info.replace(o,"").replace(r,""),k.hidden=!0;const $=`${q}-codetab-${t.editorId}-${p}-${O-p}`;E=O-p>0?"":"checked",W+=`
43
+ ${M}
44
+ </${U}>
45
+ `}let k,S,_,E,W="",V="",O="";const{open:B,tagContainer:D,tagHeader:j}=d(l[p]),H=[["class",`${q}-code`]];B&&H.push(["open",""]);const F={attrs:vo(l[p],H)};for(let I=p;I<l.length&&(k=l[I],[S,_]=s(k),S===w);I++){k.info=k.info.replace(o,"").replace(r,""),k.hidden=!0;const U=`${q}-codetab-${t.editorId}-${p}-${I-p}`;E=I-p>0?"":"checked",W+=`
46
46
  <li>
47
47
  <input
48
48
  type="radio"
49
- id="label-${q}-codetab-label-1-${t.editorId}-${p}-${O-p}"
49
+ id="label-${q}-codetab-label-1-${t.editorId}-${p}-${I-p}"
50
50
  name="${q}-codetab-label-${t.editorId}-${p}"
51
- class="${$}"
51
+ class="${U}"
52
52
  ${E}
53
53
  >
54
54
  <label
55
- for="label-${q}-codetab-label-1-${t.editorId}-${p}-${O-p}"
56
- onclick="this.getRootNode().querySelectorAll('.${$}').forEach(e => e.click())"
55
+ for="label-${q}-codetab-label-1-${t.editorId}-${p}-${I-p}"
56
+ onclick="this.getRootNode().querySelectorAll('.${U}').forEach(e => e.click())"
57
57
  >
58
58
  ${e.utils.escapeHtml(_||c(k))}
59
59
  </label>
60
- </li>`,B+=`
60
+ </li>`,V+=`
61
61
  <div role="tabpanel">
62
62
  <input
63
63
  type="radio"
64
64
  name="${q}-codetab-pre-${t.editorId}-${p}"
65
- class="${$}"
65
+ class="${U}"
66
66
  ${E}
67
67
  role="presentation">
68
- ${n(l,O,m,h,y)}
69
- </div>`,I+=`
68
+ ${n(l,I,m,h,x)}
69
+ </div>`,O+=`
70
70
  <input
71
71
  type="radio"
72
72
  name="${q}-codetab-lang-${t.editorId}-${p}"
73
- class="${$}"
73
+ class="${U}"
74
74
  ${E}
75
75
  role="presentation">
76
76
  <span class=${q}-code-lang role="note">${e.utils.escapeHtml(c(k))}</span>`}return`
77
- <${D} ${y.renderAttrs(F)}>
77
+ <${D} ${x.renderAttrs(F)}>
78
78
  <${j} class="${q}-code-head">
79
79
  <div class="${q}-code-flag">
80
80
  <ul class="${q}-codetab-label" role="tablist">${W}</ul>
81
81
  </div>
82
82
  <div class="${q}-code-action">
83
- <span class="${q}-codetab-lang">${I}</span>
84
- <span class="${q}-copy-button" data-tips="${x}"${g?" data-is-icon=true":""}>${v}</span>
83
+ <span class="${q}-codetab-lang">${O}</span>
84
+ <span class="${q}-copy-button" data-tips="${y}"${g?" data-is-icon=true":""}>${v}</span>
85
85
  ${t.extraTools instanceof Function?t.extraTools({lang:l[p].info.trim()}):t.extraTools||""}
86
86
  ${D==="details"?b:""}
87
87
  </div>
88
88
  </${j}>
89
- ${B}
89
+ ${V}
90
90
  </${D}>
91
- `};e.renderer.rules.fence=f,e.renderer.rules.code_block=f},A1=(e,t)=>{const n=e.renderer.rules.fence.bind(e.renderer.rules);e.renderer.rules.fence=(u,o,r,a,s)=>{var f,l;const c=u[o],d=c.content.trim();if(c.info==="echarts"){if(c.attrSet("class",`${q}-echarts`),c.attrSet("data-echarts-theme",t.themeRef.value),c.map&&c.level===0){const p=c.map[1]-1,m=!!((l=(f=a.srcLines[p])==null?void 0:f.trim())!=null&&l.startsWith("```"));c.attrSet("data-closed",`${m}`),c.attrSet("data-line",String(c.map[0]))}return`<div ${s.renderAttrs(c)} style="width: 100%; aspect-ratio: 4 / 3;">${e.utils.escapeHtml(d)}</div>`}return n(u,o,r,a,s)}},k1=(e,t)=>{e.renderer.rules.heading_open=(n,u)=>{var s;const o=n[u],r=((s=n[u+1].children)==null?void 0:s.reduce((c,d)=>c+(["text","code_inline","math_inline"].includes(d.type)&&d.content||""),""))||"",a=o.markup.length;return t.headsRef.value.push({text:r,level:a,line:o.map[0],currentToken:o,nextToken:n[u+1]}),o.map&&o.level===0&&o.attrSet("id",t.mdHeadingId({text:r,level:a,index:t.headsRef.value.length,currentToken:o,nextToken:n[u+1]})),e.renderer.renderToken(n,u,t)},e.renderer.rules.heading_close=(n,u,o,r,a)=>a.renderToken(n,u,o)},as={block:[{open:"$$",close:"$$"},{open:"\\[",close:"\\]"}],inline:[{open:"$$",close:"$$"},{open:"$",close:"$"},{open:"\\[",close:"\\]"},{open:"\\(",close:"\\)"}]},C1=e=>(t,n)=>{const u=e.delimiters;for(const o of u){if(!t.src.startsWith(o.open,t.pos))continue;const r=t.pos+o.open.length;let a=r;for(;(a=t.src.indexOf(o.close,a))!==-1;){let s=0,c=a-1;for(;c>=0&&t.src[c]==="\\";)s++,c--;if(s%2===0)break;a+=o.close.length}if(a!==-1){if(a-r===0)return n||(t.pending+=o.open+o.close),t.pos=a+o.close.length,!0;if(!n){const s=t.push("math_inline","math",0);s.markup=o.open,s.content=t.src.slice(r,a)}return t.pos=a+o.close.length,!0}}return!1},E1=e=>(t,n,u,o)=>{const r=e.delimiters,a=t.bMarks[n]+t.tShift[n],s=t.eMarks[n],c=(d,f,l)=>{t.line=f;const p=t.push("math_block","math",0);return p.block=!0,p.content=d,p.map=[n,t.line],p.markup=l,!0};for(const d of r){const f=a;if(t.src.slice(f,f+d.open.length)!==d.open)continue;const l=f+d.open.length,p=t.src.slice(l,s).trim(),m=p==="",h=p===d.close,y=p.endsWith(d.close);if(!m&&!h&&!y)continue;if(o)return!0;if(h)return c("",n+1,d.open);if(!m&&y){const w=p.slice(0,-d.close.length);return c(w,n+1,d.open)}let x=n+1,v=!1,g="";for(;x<u;x++){const w=t.bMarks[x]+t.tShift[x],k=t.eMarks[x];if(w<k&&t.tShift[x]<t.blkIndent)break;if(t.src.slice(w,k).trim().endsWith(d.close)){const S=t.src.slice(0,k).lastIndexOf(d.close);g=t.src.slice(w,S),v=!0;break}}if(!v)continue;const b=t.getLines(n+1,x,t.tShift[n],!0)+(g.trim()?g:"");return c(b,x+1,d.open)}return!1},_1=(e,{katexRef:t,inlineDelimiters:n,blockDelimiters:u})=>{const o=(s,c,d,f,l=!1)=>{const p={attrs:Ao(s,[["class",c]])},m=f.renderAttrs(p);if(!t.value)return`<${d} ${m}>${s.content}</${d}>`;const h=t.value.renderToString(s.content,ut.katexConfig({throwOnError:!1,displayMode:l}));return`<${d} ${m} data-processed>${h}</${d}>`},r=(s,c,d,f,l)=>o(s[c],`${q}-katex-inline`,"span",l),a=(s,c,d,f,l)=>o(s[c],`${q}-katex-block`,"p",l,!0);e.inline.ruler.before("escape","math_inline",C1({delimiters:n||as.inline})),e.block.ruler.after("blockquote","math_block",E1({delimiters:u||as.block}),{alt:["paragraph","reference","blockquote","list"]}),e.renderer.rules.math_inline=r,e.renderer.rules.math_block=a},S1=(e,t)=>{const n=e.renderer.rules.fence.bind(e.renderer.rules);e.renderer.rules.fence=(u,o,r,a,s)=>{var f,l;const c=u[o],d=c.content.trim();if(c.info==="mermaid"){if(c.attrSet("class",`${q}-mermaid`),c.attrSet("data-mermaid-theme",t.themeRef.value),c.map&&c.level===0){const m=c.map[1]-1,h=!!((l=(f=a.srcLines[m])==null?void 0:f.trim())!=null&&l.startsWith("```"));c.attrSet("data-closed",`${h}`),c.attrSet("data-line",String(c.map[0]))}const p=au.get(d);return p?(c.attrSet("data-processed",""),c.attrSet("data-content",d),`<p ${s.renderAttrs(c)}>${p}</p>`):`<div ${s.renderAttrs(c)}>${e.utils.escapeHtml(d)}</div>`}return n(u,o,r,a,s)}},ss=(e,t,n)=>{const u=e.attrIndex(t),o=[t,n];u<0?e.attrPush(o):(e.attrs=e.attrs||[],e.attrs[u]=o)},F1=e=>e.type==="inline",D1=e=>e.type==="paragraph_open",T1=e=>e.type==="list_item_open",N1=e=>e.content.indexOf("[ ] ")===0||e.content.indexOf("[x] ")===0||e.content.indexOf("[X] ")===0,L1=(e,t)=>F1(e[t])&&D1(e[t-1])&&T1(e[t-2])&&N1(e[t]),O1=(e,t)=>{const n=e[t].level-1;for(let u=t-1;u>=0;u--)if(e[u].level===n)return u;return-1},I1=e=>{const t=new e("html_inline","",0);return t.content="<label>",t},P1=e=>{const t=new e("html_inline","",0);return t.content="</label>",t},R1=(e,t,n)=>{const u=new n("html_inline","",0);return u.content='<label class="task-list-item-label" for="'+t+'">'+e+"</label>",u.attrs=[["for",t]],u},V1=(e,t,n)=>{const u=new t("html_inline","",0),o=n.enabled?" ":' disabled="" ';return e.content.indexOf("[ ] ")===0?u.content='<input class="task-list-item-checkbox"'+o+'type="checkbox">':(e.content.indexOf("[x] ")===0||e.content.indexOf("[X] ")===0)&&(u.content='<input class="task-list-item-checkbox" checked=""'+o+'type="checkbox">'),u},M1=(e,t,n)=>{if(e.children=e.children||[],e.children.unshift(V1(e,t,n)),e.children[1].content=e.children[1].content.slice(3),e.content=e.content.slice(3),n.label)if(n.labelAfter){e.children.pop();const u="task-item-"+Math.ceil(Math.random()*(1e4*1e3)-1e3);e.children[0].content=e.children[0].content.slice(0,-1)+' id="'+u+'">',e.children.push(R1(e.content,u,t))}else e.children.unshift(I1(t)),e.children.push(P1(t))},B1=(e,t={})=>{e.core.ruler.after("inline","github-task-lists",n=>{const u=n.tokens;for(let o=2;o<u.length;o++)L1(u,o)&&(M1(u[o],n.Token,t),ss(u[o-2],"class","task-list-item"+(t.enabled?" enabled":" ")),ss(u[O1(u,o-2)],"class","contains-task-list"))})},z1=e=>{e.core.ruler.push("init-line-number",t=>(t.tokens.forEach(n=>{n.map&&(n.attrs||(n.attrs=[]),n.attrs.push(["data-line",n.map[0].toString()]))}),!0))},j1=(e,t)=>{const{editorConfig:n,markdownItPlugins:u}=ut,o=i.inject("editorId"),r=i.inject("language"),a=i.inject("usedLanguageText"),s=i.inject("showCodeRowNumber"),c=i.inject("theme"),d=i.inject("customIcon"),f=i.inject("rootRef"),l=i.inject("setting"),p=i.ref([]),m=b1(e),h=y1(e),{reRenderRef:y,replaceMermaid:x}=x1(e),{reRenderEcharts:v,replaceEcharts:g}=g1(e),b=Ge({html:!0,breaks:!0,linkify:!0}),w=[{type:"image",plugin:Yh,options:{figcaption:!0,classes:"md-zoom"}},{type:"admonition",plugin:w1,options:{}},{type:"taskList",plugin:B1,options:{}},{type:"heading",plugin:k1,options:{mdHeadingId:e.mdHeadingId,headsRef:p}},{type:"code",plugin:v1,options:{editorId:o,usedLanguageTextRef:a,codeFoldable:e.codeFoldable,autoFoldThreshold:e.autoFoldThreshold,customIconRef:d}},{type:"sub",plugin:Jh,options:{}},{type:"sup",plugin:n1,options:{}}];e.noKatex||w.push({type:"katex",plugin:_1,options:{katexRef:h}}),e.noMermaid||w.push({type:"mermaid",plugin:S1,options:{themeRef:c}}),e.noEcharts||w.push({type:"echarts",plugin:A1,options:{themeRef:c}}),u(w,{editorId:o}).forEach(H=>{b.use(H.plugin,H.options)});const k=b.options.highlight;b.set({highlight:(H,F,V)=>{if(k){const re=k(H,F,V);if(re)return re}let O;!e.noHighlight&&m.value?m.value.getLanguage(F)?O=m.value.highlight(H,{language:F,ignoreIllegals:!0}).value:O=m.value.highlightAuto(H).value:O=b.utils.escapeHtml(H);const $=s?$h(O.replace(/^\n+|\n+$/g,""),H.replace(/^\n+|\n+$/g,"")):`<span class="${q}-code-block">${O.replace(/^\n+|\n+$/g,"")}</span>`;return`<pre><code class="language-${F}" language=${F}>${$}</code></pre>`}}),z1(b);const S=i.ref(`_article-key_${mo()}`),_=i.ref(e.sanitize(b.render(e.modelValue,{srcLines:e.modelValue.split(`
92
- `)})));let E=()=>{},W=()=>{};const B=()=>{var F;const H=(F=f.value)==null?void 0:F.querySelectorAll(`#${o} p.${q}-mermaid:not([data-closed=false])`);W(),W=qh(H,{customIcon:d.value}),E(),E=Xh(H,{customIcon:d.value})},I=()=>{tt.emit(o,Bh,_.value),e.onHtmlChanged(_.value),e.onGetCatalog(p.value),tt.emit(o,wo,p.value),i.nextTick(()=>{x().then(B),g()})},M=()=>{p.value=[],_.value=e.sanitize(b.render(e.modelValue,{srcLines:e.modelValue.split(`
93
- `)}))},D=i.computed(()=>(e.noKatex||!!h.value)&&(e.noHighlight||!!m.value));let j=-1;return i.watch([i.toRef(e,"modelValue"),D,y,r],()=>{j=window.setTimeout(()=>{M()},t?0:n.renderDelay)}),i.watch(()=>l.value.preview,()=>{l.value.preview&&i.nextTick(()=>{x().then(B),g(),tt.emit(o,wo,p.value)})}),i.watch([_,v],()=>{I()}),i.onMounted(I),i.onMounted(()=>{tt.on(o,{name:zh,callback(){tt.emit(o,wo,p.value)}}),tt.on(o,{name:Ya,callback:()=>{S.value=`_article-key_${mo()}`,M()}})}),i.onBeforeUnmount(()=>{E(),W(),clearTimeout(j)}),{html:_,key:S}},H1=(e,t)=>{const n=i.inject("editorId"),u=i.inject("setting"),{noImgZoomIn:o}=e,r=Dh(()=>{const a=document.querySelectorAll(`#${n}-preview img:not(.not-zoom):not(.medium-zoom-image)`);a.length!==0&&l1(a,{background:"#00000073"})});i.onMounted(async()=>{!o&&u.value.preview&&await r()}),i.watch([t,()=>u.value.preview],async()=>{!o&&u.value.preview&&await r()})},cs={checked:{regexp:/- \[x\]/,value:"- [ ]"},unChecked:{regexp:/- \[\s\]/,value:"- [x]"}},$1=(e,t)=>{const n=i.inject("editorId"),u=i.inject("rootRef");let o=()=>{};const r=()=>{if(!u.value)return!1;const a=u.value.querySelectorAll(".task-list-item.enabled"),s=c=>{var h;c.preventDefault();const d=c.target.checked?"unChecked":"checked",f=(h=c.target.parentElement)==null?void 0:h.dataset.line;if(!f)return;const l=Number(f),p=e.modelValue.split(`
94
- `),m=p[Number(l)].replace(cs[d].regexp,cs[d].value);e.previewOnly?(p[Number(l)]=m,e.onChange(p.join(`
95
- `))):tt.emit(n,jh,l+1,m)};a.forEach(c=>{c.addEventListener("click",s)}),o=()=>{a.forEach(c=>{c.removeEventListener("click",s)})}};i.onBeforeUnmount(()=>{o()}),i.watch([t],()=>{o(),i.nextTick(r)},{immediate:!0})},U1=(e,t,n)=>{const u=i.inject("setting"),o=()=>{i.nextTick(()=>{var a;(a=e.onRemount)==null||a.call(e)})},r=a=>{a&&o()};i.watch([t,n],o),i.watch(()=>u.value.preview,r),i.watch(()=>u.value.htmlPreview,r),i.onMounted(o)},ls={modelValue:{type:String,default:""},onChange:{type:Function,default:()=>{}},onHtmlChanged:{type:Function,default:()=>{}},onGetCatalog:{type:Function,default:()=>{}},mdHeadingId:{type:Function,default:()=>""},noMermaid:{type:Boolean,default:!1},sanitize:{type:Function,default:e=>e},noKatex:{type:Boolean,default:!1},formatCopiedText:{type:Function,default:e=>e},noHighlight:{type:Boolean,default:!1},previewOnly:{type:Boolean,default:!1},noImgZoomIn:{type:Boolean},sanitizeMermaid:{type:Function},codeFoldable:{type:Boolean},autoFoldThreshold:{type:Number},onRemount:{type:Function},noEcharts:{type:Boolean},previewComponent:{type:[Object,Function],default:void 0}};({...ls});const ds=e=>{const t=new DOMParser().parseFromString(e,"text/html");return Array.from(t.body.childNodes)},W1=(e,t)=>e.nodeType!==t.nodeType?!1:e.nodeType===Node.TEXT_NODE||e.nodeType===Node.COMMENT_NODE?e.textContent===t.textContent:e.nodeType===Node.ELEMENT_NODE?e.outerHTML===t.outerHTML:e.isEqualNode?e.isEqualNode(t):!1,G1=i.defineComponent({name:"UpdateOnDemand",props:{id:{type:String,required:!0},class:{type:[String,Array,Object],required:!0},html:{type:String,required:!0}},setup(e){const t=i.ref(),n=e.html,u=(o,r)=>{if(!t.value)return;const a=t.value,s=Array.from(a.childNodes),c=Math.min(o.length,r.length);let d=-1;for(let l=0;l<c;l++)if(!W1(o[l],r[l])){d=l;break}if(d===-1)if(r.length>o.length)d=o.length;else if(o.length>r.length)d=r.length;else return;const f=Math.min(d,s.length);for(let l=s.length-1;l>=f;l--)s[l].remove();for(let l=d;l<o.length;l++)a.appendChild(o[l].cloneNode(!0))};return i.watch(()=>e.html,(o,r)=>{const a=ds(o),s=ds(r||"");u(a,s)}),()=>i.createVNode("div",{id:e.id,class:e.class,innerHTML:n,ref:t},null)}}),q1=i.defineComponent({name:"ContentPreview",props:ls,setup(e){const t=i.inject("editorId"),n=i.inject("setting"),u=i.inject("previewTheme"),o=i.inject("showCodeRowNumber"),{html:r,key:a}=j1(e,e.previewOnly);m1(e,r,a),H1(e,r),$1(e,r),U1(e,r,a);const s=i.computed(()=>[`${q}-preview`,`${u==null?void 0:u.value}-theme`,o&&`${q}-scrn`].filter(Boolean)),c=()=>{const d=`${t}-preview`;return e.previewComponent?i.h(e.previewComponent,{key:a.value,html:r.value,id:d,class:s.value}):i.createVNode(G1,{key:a.value,html:r.value,id:d,class:s.value},null)};return()=>i.createVNode(i.Fragment,null,[n.value.preview&&(e.previewOnly?c():i.createVNode("div",{id:`${t}-preview-wrapper`,class:`${q}-preview-wrapper`,key:"content-preview-wrapper"},[c()])),n.value.htmlPreview&&i.createVNode("div",{id:`${t}-html-wrapper`,class:`${q}-preview-wrapper`,key:"html-preview-wrapper"},[i.createVNode("div",{class:`${q}-html`},[r.value])])])}}),X1=({text:e})=>e,fs={modelValue:{type:String,default:""},onChange:{type:Function,default:void 0},theme:{type:String,default:"light"},class:{type:String,default:""},language:{type:String,default:"zh-CN"},onHtmlChanged:{type:Function,default:void 0},onGetCatalog:{type:Function,default:void 0},editorId:{type:String,default:void 0},id:{type:String,default:void 0},showCodeRowNumber:{type:Boolean,default:!0},previewTheme:{type:String,default:"default"},style:{type:Object,default:()=>({})},mdHeadingId:{type:Function,default:X1},sanitize:{type:Function,default:e=>e},noMermaid:{type:Boolean,default:!1},noKatex:{type:Boolean,default:!1},codeTheme:{type:String,default:"atom"},formatCopiedText:{type:Function,default:e=>e},codeStyleReverse:{type:Boolean,default:!0},codeStyleReverseList:{type:Array,default:["default","mk-cute"]},noHighlight:{type:Boolean,default:!1},noImgZoomIn:{type:Boolean,default:!1},customIcon:{type:Object,default:{}},sanitizeMermaid:{type:Function,default:e=>Promise.resolve(e)},codeFoldable:{type:Boolean,default:!0},autoFoldThreshold:{type:Number,default:30},onRemount:{type:Function,default:void 0},noEcharts:{type:Boolean,default:!1},previewComponent:{type:[Object,Function],default:void 0}};({...fs});const hs=["onHtmlChanged","onGetCatalog","onChange","onRemount","update:modelValue"];[...hs];const Z1=(e,t,n)=>{const{editorId:u}=n,o={rerender(){tt.emit(u,Ya)}};t.expose(o)},su=i.defineComponent({name:"MdPreview",props:fs,emits:hs,setup(e,t){const{noKatex:n,noMermaid:u,noHighlight:o}=e,r=i.ref(),a=p1(e);h1(e,{rootRef:r,editorId:a}),Z1(e,t,{editorId:a}),i.onBeforeUnmount(()=>{tt.clear(a)});const s=l=>{var p;(p=e.onChange)==null||p.call(e,l),t.emit("onChange",l),t.emit("update:modelValue",l)},c=l=>{var p;(p=e.onHtmlChanged)==null||p.call(e,l),t.emit("onHtmlChanged",l)},d=l=>{var p;(p=e.onGetCatalog)==null||p.call(e,l),t.emit("onGetCatalog",l)},f=()=>{var l;(l=e.onRemount)==null||l.call(e),t.emit("onRemount")};return()=>i.createVNode("div",{id:a,class:[q,e.class,e.theme==="dark"&&`${q}-dark`,`${q}-previewOnly`],style:e.style,ref:r},[i.createVNode(q1,{modelValue:e.modelValue,onChange:s,onHtmlChanged:c,onGetCatalog:d,mdHeadingId:e.mdHeadingId,noMermaid:u,sanitize:e.sanitize,noKatex:n,formatCopiedText:e.formatCopiedText,noHighlight:o,noImgZoomIn:e.noImgZoomIn,previewOnly:!0,sanitizeMermaid:e.sanitizeMermaid,codeFoldable:e.codeFoldable,autoFoldThreshold:e.autoFoldThreshold,onRemount:f,noEcharts:e.noEcharts,previewComponent:e.previewComponent},null)])}});su.install=e=>(e.component(su.name,su),e);const Y1={onClick:{type:Function,default:void 0},language:{type:String,default:void 0},theme:{type:String,default:void 0},disabled:{type:Boolean,default:void 0}},ko=i.defineComponent({name:"NormalFooterToolbar",props:Y1,emits:["onClick"],setup(e,t){return()=>{const n=Mh({props:e,ctx:t});return i.createVNode("div",{class:[`${q}-footer-item`,e.disabled&&`${q}-disabled`],onClick:u=>{var o;e.disabled||((o=e.onClick)==null||o.call(e,u),t.emit("onClick",u))}},[n])}}});ko.install=e=>(e.component(ko.name,ko),e);var Co={exports:{}},me={},Eo={exports:{}},Yt={},ps;function ms(){if(ps)return Yt;ps=1;function e(){var r={};return r["align-content"]=!1,r["align-items"]=!1,r["align-self"]=!1,r["alignment-adjust"]=!1,r["alignment-baseline"]=!1,r.all=!1,r["anchor-point"]=!1,r.animation=!1,r["animation-delay"]=!1,r["animation-direction"]=!1,r["animation-duration"]=!1,r["animation-fill-mode"]=!1,r["animation-iteration-count"]=!1,r["animation-name"]=!1,r["animation-play-state"]=!1,r["animation-timing-function"]=!1,r.azimuth=!1,r["backface-visibility"]=!1,r.background=!0,r["background-attachment"]=!0,r["background-clip"]=!0,r["background-color"]=!0,r["background-image"]=!0,r["background-origin"]=!0,r["background-position"]=!0,r["background-repeat"]=!0,r["background-size"]=!0,r["baseline-shift"]=!1,r.binding=!1,r.bleed=!1,r["bookmark-label"]=!1,r["bookmark-level"]=!1,r["bookmark-state"]=!1,r.border=!0,r["border-bottom"]=!0,r["border-bottom-color"]=!0,r["border-bottom-left-radius"]=!0,r["border-bottom-right-radius"]=!0,r["border-bottom-style"]=!0,r["border-bottom-width"]=!0,r["border-collapse"]=!0,r["border-color"]=!0,r["border-image"]=!0,r["border-image-outset"]=!0,r["border-image-repeat"]=!0,r["border-image-slice"]=!0,r["border-image-source"]=!0,r["border-image-width"]=!0,r["border-left"]=!0,r["border-left-color"]=!0,r["border-left-style"]=!0,r["border-left-width"]=!0,r["border-radius"]=!0,r["border-right"]=!0,r["border-right-color"]=!0,r["border-right-style"]=!0,r["border-right-width"]=!0,r["border-spacing"]=!0,r["border-style"]=!0,r["border-top"]=!0,r["border-top-color"]=!0,r["border-top-left-radius"]=!0,r["border-top-right-radius"]=!0,r["border-top-style"]=!0,r["border-top-width"]=!0,r["border-width"]=!0,r.bottom=!1,r["box-decoration-break"]=!0,r["box-shadow"]=!0,r["box-sizing"]=!0,r["box-snap"]=!0,r["box-suppress"]=!0,r["break-after"]=!0,r["break-before"]=!0,r["break-inside"]=!0,r["caption-side"]=!1,r.chains=!1,r.clear=!0,r.clip=!1,r["clip-path"]=!1,r["clip-rule"]=!1,r.color=!0,r["color-interpolation-filters"]=!0,r["column-count"]=!1,r["column-fill"]=!1,r["column-gap"]=!1,r["column-rule"]=!1,r["column-rule-color"]=!1,r["column-rule-style"]=!1,r["column-rule-width"]=!1,r["column-span"]=!1,r["column-width"]=!1,r.columns=!1,r.contain=!1,r.content=!1,r["counter-increment"]=!1,r["counter-reset"]=!1,r["counter-set"]=!1,r.crop=!1,r.cue=!1,r["cue-after"]=!1,r["cue-before"]=!1,r.cursor=!1,r.direction=!1,r.display=!0,r["display-inside"]=!0,r["display-list"]=!0,r["display-outside"]=!0,r["dominant-baseline"]=!1,r.elevation=!1,r["empty-cells"]=!1,r.filter=!1,r.flex=!1,r["flex-basis"]=!1,r["flex-direction"]=!1,r["flex-flow"]=!1,r["flex-grow"]=!1,r["flex-shrink"]=!1,r["flex-wrap"]=!1,r.float=!1,r["float-offset"]=!1,r["flood-color"]=!1,r["flood-opacity"]=!1,r["flow-from"]=!1,r["flow-into"]=!1,r.font=!0,r["font-family"]=!0,r["font-feature-settings"]=!0,r["font-kerning"]=!0,r["font-language-override"]=!0,r["font-size"]=!0,r["font-size-adjust"]=!0,r["font-stretch"]=!0,r["font-style"]=!0,r["font-synthesis"]=!0,r["font-variant"]=!0,r["font-variant-alternates"]=!0,r["font-variant-caps"]=!0,r["font-variant-east-asian"]=!0,r["font-variant-ligatures"]=!0,r["font-variant-numeric"]=!0,r["font-variant-position"]=!0,r["font-weight"]=!0,r.grid=!1,r["grid-area"]=!1,r["grid-auto-columns"]=!1,r["grid-auto-flow"]=!1,r["grid-auto-rows"]=!1,r["grid-column"]=!1,r["grid-column-end"]=!1,r["grid-column-start"]=!1,r["grid-row"]=!1,r["grid-row-end"]=!1,r["grid-row-start"]=!1,r["grid-template"]=!1,r["grid-template-areas"]=!1,r["grid-template-columns"]=!1,r["grid-template-rows"]=!1,r["hanging-punctuation"]=!1,r.height=!0,r.hyphens=!1,r.icon=!1,r["image-orientation"]=!1,r["image-resolution"]=!1,r["ime-mode"]=!1,r["initial-letters"]=!1,r["inline-box-align"]=!1,r["justify-content"]=!1,r["justify-items"]=!1,r["justify-self"]=!1,r.left=!1,r["letter-spacing"]=!0,r["lighting-color"]=!0,r["line-box-contain"]=!1,r["line-break"]=!1,r["line-grid"]=!1,r["line-height"]=!1,r["line-snap"]=!1,r["line-stacking"]=!1,r["line-stacking-ruby"]=!1,r["line-stacking-shift"]=!1,r["line-stacking-strategy"]=!1,r["list-style"]=!0,r["list-style-image"]=!0,r["list-style-position"]=!0,r["list-style-type"]=!0,r.margin=!0,r["margin-bottom"]=!0,r["margin-left"]=!0,r["margin-right"]=!0,r["margin-top"]=!0,r["marker-offset"]=!1,r["marker-side"]=!1,r.marks=!1,r.mask=!1,r["mask-box"]=!1,r["mask-box-outset"]=!1,r["mask-box-repeat"]=!1,r["mask-box-slice"]=!1,r["mask-box-source"]=!1,r["mask-box-width"]=!1,r["mask-clip"]=!1,r["mask-image"]=!1,r["mask-origin"]=!1,r["mask-position"]=!1,r["mask-repeat"]=!1,r["mask-size"]=!1,r["mask-source-type"]=!1,r["mask-type"]=!1,r["max-height"]=!0,r["max-lines"]=!1,r["max-width"]=!0,r["min-height"]=!0,r["min-width"]=!0,r["move-to"]=!1,r["nav-down"]=!1,r["nav-index"]=!1,r["nav-left"]=!1,r["nav-right"]=!1,r["nav-up"]=!1,r["object-fit"]=!1,r["object-position"]=!1,r.opacity=!1,r.order=!1,r.orphans=!1,r.outline=!1,r["outline-color"]=!1,r["outline-offset"]=!1,r["outline-style"]=!1,r["outline-width"]=!1,r.overflow=!1,r["overflow-wrap"]=!1,r["overflow-x"]=!1,r["overflow-y"]=!1,r.padding=!0,r["padding-bottom"]=!0,r["padding-left"]=!0,r["padding-right"]=!0,r["padding-top"]=!0,r.page=!1,r["page-break-after"]=!1,r["page-break-before"]=!1,r["page-break-inside"]=!1,r["page-policy"]=!1,r.pause=!1,r["pause-after"]=!1,r["pause-before"]=!1,r.perspective=!1,r["perspective-origin"]=!1,r.pitch=!1,r["pitch-range"]=!1,r["play-during"]=!1,r.position=!1,r["presentation-level"]=!1,r.quotes=!1,r["region-fragment"]=!1,r.resize=!1,r.rest=!1,r["rest-after"]=!1,r["rest-before"]=!1,r.richness=!1,r.right=!1,r.rotation=!1,r["rotation-point"]=!1,r["ruby-align"]=!1,r["ruby-merge"]=!1,r["ruby-position"]=!1,r["shape-image-threshold"]=!1,r["shape-outside"]=!1,r["shape-margin"]=!1,r.size=!1,r.speak=!1,r["speak-as"]=!1,r["speak-header"]=!1,r["speak-numeral"]=!1,r["speak-punctuation"]=!1,r["speech-rate"]=!1,r.stress=!1,r["string-set"]=!1,r["tab-size"]=!1,r["table-layout"]=!1,r["text-align"]=!0,r["text-align-last"]=!0,r["text-combine-upright"]=!0,r["text-decoration"]=!0,r["text-decoration-color"]=!0,r["text-decoration-line"]=!0,r["text-decoration-skip"]=!0,r["text-decoration-style"]=!0,r["text-emphasis"]=!0,r["text-emphasis-color"]=!0,r["text-emphasis-position"]=!0,r["text-emphasis-style"]=!0,r["text-height"]=!0,r["text-indent"]=!0,r["text-justify"]=!0,r["text-orientation"]=!0,r["text-overflow"]=!0,r["text-shadow"]=!0,r["text-space-collapse"]=!0,r["text-transform"]=!0,r["text-underline-position"]=!0,r["text-wrap"]=!0,r.top=!1,r.transform=!1,r["transform-origin"]=!1,r["transform-style"]=!1,r.transition=!1,r["transition-delay"]=!1,r["transition-duration"]=!1,r["transition-property"]=!1,r["transition-timing-function"]=!1,r["unicode-bidi"]=!1,r["vertical-align"]=!1,r.visibility=!1,r["voice-balance"]=!1,r["voice-duration"]=!1,r["voice-family"]=!1,r["voice-pitch"]=!1,r["voice-range"]=!1,r["voice-rate"]=!1,r["voice-stress"]=!1,r["voice-volume"]=!1,r.volume=!1,r["white-space"]=!1,r.widows=!1,r.width=!0,r["will-change"]=!1,r["word-break"]=!0,r["word-spacing"]=!0,r["word-wrap"]=!0,r["wrap-flow"]=!1,r["wrap-through"]=!1,r["writing-mode"]=!1,r["z-index"]=!1,r}function t(r,a,s){}function n(r,a,s){}var u=/javascript\s*\:/img;function o(r,a){return u.test(a)?"":a}return Yt.whiteList=e(),Yt.getDefaultWhiteList=e,Yt.onAttr=t,Yt.onIgnoreAttr=n,Yt.safeAttrValue=o,Yt}var gs,bs;function ys(){return bs||(bs=1,gs={indexOf:function(e,t){var n,u;if(Array.prototype.indexOf)return e.indexOf(t);for(n=0,u=e.length;n<u;n++)if(e[n]===t)return n;return-1},forEach:function(e,t,n){var u,o;if(Array.prototype.forEach)return e.forEach(t,n);for(u=0,o=e.length;u<o;u++)t.call(n,e[u],u,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},trimRight:function(e){return String.prototype.trimRight?e.trimRight():e.replace(/(\s*$)/g,"")}}),gs}var _o,xs;function K1(){if(xs)return _o;xs=1;var e=ys();function t(n,u){n=e.trimRight(n),n[n.length-1]!==";"&&(n+=";");var o=n.length,r=!1,a=0,s=0,c="";function d(){if(!r){var p=e.trim(n.slice(a,s)),m=p.indexOf(":");if(m!==-1){var h=e.trim(p.slice(0,m)),y=e.trim(p.slice(m+1));if(h){var x=u(a,c.length,h,y,p);x&&(c+=x+"; ")}}}a=s+1}for(;s<o;s++){var f=n[s];if(f==="/"&&n[s+1]==="*"){var l=n.indexOf("*/",s+2);if(l===-1)break;s=l+1,a=s+1,r=!1}else f==="("?r=!0:f===")"?r=!1:f===";"?r||d():f===`
96
- `&&d()}return e.trim(c)}return _o=t,_o}var So,ws;function Q1(){if(ws)return So;ws=1;var e=ms(),t=K1();ys();function n(r){return r==null}function u(r){var a={};for(var s in r)a[s]=r[s];return a}function o(r){r=u(r||{}),r.whiteList=r.whiteList||e.whiteList,r.onAttr=r.onAttr||e.onAttr,r.onIgnoreAttr=r.onIgnoreAttr||e.onIgnoreAttr,r.safeAttrValue=r.safeAttrValue||e.safeAttrValue,this.options=r}return o.prototype.process=function(r){if(r=r||"",r=r.toString(),!r)return"";var a=this,s=a.options,c=s.whiteList,d=s.onAttr,f=s.onIgnoreAttr,l=s.safeAttrValue,p=t(r,function(m,h,y,x,v){var g=c[y],b=!1;if(g===!0?b=g:typeof g=="function"?b=g(x):g instanceof RegExp&&(b=g.test(x)),b!==!0&&(b=!1),x=l(y,x),!!x){var w={position:h,sourcePosition:m,source:v,isWhite:b};if(b){var k=d(y,x,w);return n(k)?y+":"+x:k}else{var k=f(y,x,w);if(!n(k))return k}}});return p},So=o,So}var vs;function Fo(){return vs||(vs=1,function(e,t){var n=ms(),u=Q1();function o(a,s){var c=new u(s);return c.process(a)}t=e.exports=o,t.FilterCSS=u;for(var r in n)t[r]=n[r];typeof window<"u"&&(window.filterCSS=e.exports)}(Eo,Eo.exports)),Eo.exports}var As,ks;function Do(){return ks||(ks=1,As={indexOf:function(e,t){var n,u;if(Array.prototype.indexOf)return e.indexOf(t);for(n=0,u=e.length;n<u;n++)if(e[n]===t)return n;return-1},forEach:function(e,t,n){var u,o;if(Array.prototype.forEach)return e.forEach(t,n);for(u=0,o=e.length;u<o;u++)t.call(n,e[u],u,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},spaceIndex:function(e){var t=/\s|\n|\t/,n=t.exec(e);return n?n.index:-1}}),As}var Cs;function Es(){if(Cs)return me;Cs=1;var e=Fo().FilterCSS,t=Fo().getDefaultWhiteList,n=Do();function u(){return{a:["target","href","title"],abbr:["title"],address:[],area:["shape","coords","href","alt"],article:[],aside:[],audio:["autoplay","controls","crossorigin","loop","muted","preload","src"],b:[],bdi:["dir"],bdo:["dir"],big:[],blockquote:["cite"],br:[],caption:[],center:[],cite:[],code:[],col:["align","valign","span","width"],colgroup:["align","valign","span","width"],dd:[],del:["datetime"],details:["open"],div:[],dl:[],dt:[],em:[],figcaption:[],figure:[],font:["color","size","face"],footer:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],header:[],hr:[],i:[],img:["src","alt","title","width","height","loading"],ins:["datetime"],kbd:[],li:[],mark:[],nav:[],ol:[],p:[],pre:[],s:[],section:[],small:[],span:[],sub:[],summary:[],sup:[],strong:[],strike:[],table:["width","border","align","valign"],tbody:["align","valign"],td:["width","rowspan","colspan","align","valign"],tfoot:["align","valign"],th:["width","rowspan","colspan","align","valign"],thead:["align","valign"],tr:["rowspan","align","valign"],tt:[],u:[],ul:[],video:["autoplay","controls","crossorigin","loop","muted","playsinline","poster","preload","src","height","width"]}}var o=new e;function r(F,V,O){}function a(F,V,O){}function s(F,V,O){}function c(F,V,O){}function d(F){return F.replace(l,"&lt;").replace(p,"&gt;")}function f(F,V,O,$){if(O=B(O),V==="href"||V==="src"){if(O=n.trim(O),O==="#")return"#";if(!(O.substr(0,7)==="http://"||O.substr(0,8)==="https://"||O.substr(0,7)==="mailto:"||O.substr(0,4)==="tel:"||O.substr(0,11)==="data:image/"||O.substr(0,6)==="ftp://"||O.substr(0,2)==="./"||O.substr(0,3)==="../"||O[0]==="#"||O[0]==="/"))return""}else if(V==="background"){if(g.lastIndex=0,g.test(O))return""}else if(V==="style"){if(b.lastIndex=0,b.test(O)||(w.lastIndex=0,w.test(O)&&(g.lastIndex=0,g.test(O))))return"";$!==!1&&($=$||o,O=$.process(O))}return O=I(O),O}var l=/</g,p=/>/g,m=/"/g,h=/&quot;/g,y=/&#([a-zA-Z0-9]*);?/gim,x=/&colon;?/gim,v=/&newline;?/gim,g=/((j\s*a\s*v\s*a|v\s*b|l\s*i\s*v\s*e)\s*s\s*c\s*r\s*i\s*p\s*t\s*|m\s*o\s*c\s*h\s*a):/gi,b=/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n\s*\(.*/gi,w=/u\s*r\s*l\s*\(.*/gi;function k(F){return F.replace(m,"&quot;")}function S(F){return F.replace(h,'"')}function _(F){return F.replace(y,function(V,O){return O[0]==="x"||O[0]==="X"?String.fromCharCode(parseInt(O.substr(1),16)):String.fromCharCode(parseInt(O,10))})}function E(F){return F.replace(x,":").replace(v," ")}function W(F){for(var V="",O=0,$=F.length;O<$;O++)V+=F.charCodeAt(O)<32?" ":F.charAt(O);return n.trim(V)}function B(F){return F=S(F),F=_(F),F=E(F),F=W(F),F}function I(F){return F=k(F),F=d(F),F}function M(){return""}function D(F,V){typeof V!="function"&&(V=function(){});var O=!Array.isArray(F);function $(P){return O?!0:n.indexOf(F,P)!==-1}var re=[],te=!1;return{onIgnoreTag:function(P,R,N){if($(P))if(N.isClosing){var L="[/removed]",U=N.position+L.length;return re.push([te!==!1?te:N.position,U]),te=!1,L}else return te||(te=N.position),"[removed]";else return V(P,R,N)},remove:function(P){var R="",N=0;return n.forEach(re,function(L){R+=P.slice(N,L[0]),N=L[1]}),R+=P.slice(N),R}}}function j(F){for(var V="",O=0;O<F.length;){var $=F.indexOf("<!--",O);if($===-1){V+=F.slice(O);break}V+=F.slice(O,$);var re=F.indexOf("-->",$);if(re===-1)break;O=re+3}return V}function H(F){var V=F.split("");return V=V.filter(function(O){var $=O.charCodeAt(0);return $===127?!1:$<=31?$===10||$===13:!0}),V.join("")}return me.whiteList=u(),me.getDefaultWhiteList=u,me.onTag=r,me.onIgnoreTag=a,me.onTagAttr=s,me.onIgnoreTagAttr=c,me.safeAttrValue=f,me.escapeHtml=d,me.escapeQuote=k,me.unescapeQuote=S,me.escapeHtmlEntities=_,me.escapeDangerHtml5Entities=E,me.clearNonPrintableCharacter=W,me.friendlyAttrValue=B,me.escapeAttrValue=I,me.onIgnoreTagStripAll=M,me.StripTagBody=D,me.stripCommentTag=j,me.stripBlankChar=H,me.attributeWrapSign='"',me.cssFilter=o,me.getDefaultCSSWhiteList=t,me}var cu={},_s;function Ss(){if(_s)return cu;_s=1;var e=Do();function t(l){var p=e.spaceIndex(l),m;return p===-1?m=l.slice(1,-1):m=l.slice(1,p+1),m=e.trim(m).toLowerCase(),m.slice(0,1)==="/"&&(m=m.slice(1)),m.slice(-1)==="/"&&(m=m.slice(0,-1)),m}function n(l){return l.slice(0,2)==="</"}function u(l,p,m){var h="",y=0,x=!1,v=!1,g=0,b=l.length,w="",k="";e:for(g=0;g<b;g++){var S=l.charAt(g);if(x===!1){if(S==="<"){x=g;continue}}else if(v===!1){if(S==="<"){h+=m(l.slice(y,g)),x=g,y=g;continue}if(S===">"||g===b-1){h+=m(l.slice(y,x)),k=l.slice(x,g+1),w=t(k),h+=p(x,h.length,w,k,n(k)),y=g+1,x=!1;continue}if(S==='"'||S==="'")for(var _=1,E=l.charAt(g-_);E.trim()===""||E==="=";){if(E==="="){v=S;continue e}E=l.charAt(g-++_)}}else if(S===v){v=!1;continue}}return y<b&&(h+=m(l.substr(y))),h}var o=/[^a-zA-Z0-9\\_:.-]/gim;function r(l,p){var m=0,h=0,y=[],x=!1,v=l.length;function g(_,E){if(_=e.trim(_),_=_.replace(o,"").toLowerCase(),!(_.length<1)){var W=p(_,E||"");W&&y.push(W)}}for(var b=0;b<v;b++){var w=l.charAt(b),k,S;if(x===!1&&w==="="){x=l.slice(m,b),m=b+1,h=l.charAt(m)==='"'||l.charAt(m)==="'"?m:s(l,b+1);continue}if(x!==!1&&b===h){if(S=l.indexOf(w,b+1),S===-1)break;k=e.trim(l.slice(h+1,S)),g(x,k),x=!1,b=S,m=b+1;continue}if(/\s|\n|\t/.test(w))if(l=l.replace(/\s|\n|\t/g," "),x===!1)if(S=a(l,b),S===-1){k=e.trim(l.slice(m,b)),g(k),x=!1,m=b+1;continue}else{b=S-1;continue}else if(S=c(l,b-1),S===-1){k=e.trim(l.slice(m,b)),k=f(k),g(x,k),x=!1,m=b+1;continue}else continue}return m<l.length&&(x===!1?g(l.slice(m)):g(x,f(e.trim(l.slice(m))))),e.trim(y.join(" "))}function a(l,p){for(;p<l.length;p++){var m=l[p];if(m!==" ")return m==="="?p:-1}}function s(l,p){for(;p<l.length;p++){var m=l[p];if(m!==" ")return m==="'"||m==='"'?p:-1}}function c(l,p){for(;p>0;p--){var m=l[p];if(m!==" ")return m==="="?p:-1}}function d(l){return l[0]==='"'&&l[l.length-1]==='"'||l[0]==="'"&&l[l.length-1]==="'"}function f(l){return d(l)?l.substr(1,l.length-2):l}return cu.parseTag=u,cu.parseAttr=r,cu}var To,Fs;function J1(){if(Fs)return To;Fs=1;var e=Fo().FilterCSS,t=Es(),n=Ss(),u=n.parseTag,o=n.parseAttr,r=Do();function a(l){return l==null}function s(l){var p=r.spaceIndex(l);if(p===-1)return{html:"",closing:l[l.length-2]==="/"};l=r.trim(l.slice(p+1,-1));var m=l[l.length-1]==="/";return m&&(l=r.trim(l.slice(0,-1))),{html:l,closing:m}}function c(l){var p={};for(var m in l)p[m]=l[m];return p}function d(l){var p={};for(var m in l)Array.isArray(l[m])?p[m.toLowerCase()]=l[m].map(function(h){return h.toLowerCase()}):p[m.toLowerCase()]=l[m];return p}function f(l){l=c(l||{}),l.stripIgnoreTag&&(l.onIgnoreTag&&console.error('Notes: cannot use these two options "stripIgnoreTag" and "onIgnoreTag" at the same time'),l.onIgnoreTag=t.onIgnoreTagStripAll),l.whiteList||l.allowList?l.whiteList=d(l.whiteList||l.allowList):l.whiteList=t.whiteList,this.attributeWrapSign=l.singleQuotedAttributeValue===!0?"'":t.attributeWrapSign,l.onTag=l.onTag||t.onTag,l.onTagAttr=l.onTagAttr||t.onTagAttr,l.onIgnoreTag=l.onIgnoreTag||t.onIgnoreTag,l.onIgnoreTagAttr=l.onIgnoreTagAttr||t.onIgnoreTagAttr,l.safeAttrValue=l.safeAttrValue||t.safeAttrValue,l.escapeHtml=l.escapeHtml||t.escapeHtml,this.options=l,l.css===!1?this.cssFilter=!1:(l.css=l.css||{},this.cssFilter=new e(l.css))}return f.prototype.process=function(l){if(l=l||"",l=l.toString(),!l)return"";var p=this,m=p.options,h=m.whiteList,y=m.onTag,x=m.onIgnoreTag,v=m.onTagAttr,g=m.onIgnoreTagAttr,b=m.safeAttrValue,w=m.escapeHtml,k=p.attributeWrapSign,S=p.cssFilter;m.stripBlankChar&&(l=t.stripBlankChar(l)),m.allowCommentTag||(l=t.stripCommentTag(l));var _=!1;m.stripIgnoreTagBody&&(_=t.StripTagBody(m.stripIgnoreTagBody,x),x=_.onIgnoreTag);var E=u(l,function(W,B,I,M,D){var j={sourcePosition:W,position:B,isClosing:D,isWhite:Object.prototype.hasOwnProperty.call(h,I)},H=y(I,M,j);if(!a(H))return H;if(j.isWhite){if(j.isClosing)return"</"+I+">";var F=s(M),V=h[I],O=o(F.html,function($,re){var te=r.indexOf(V,$)!==-1,P=v(I,$,re,te);return a(P)?te?(re=b(I,$,re,S),re?$+"="+k+re+k:$):(P=g(I,$,re,te),a(P)?void 0:P):P});return M="<"+I,O&&(M+=" "+O),F.closing&&(M+=" /"),M+=">",M}else return H=x(I,M,j),a(H)?w(M):H},w);return _&&(E=_.remove(E)),E},To=f,To}var Ds;function e2(){return Ds||(Ds=1,function(e,t){var n=Es(),u=Ss(),o=J1();function r(s,c){var d=new o(c);return d.process(s)}t=e.exports=r,t.filterXSS=r,t.FilterXSS=o,function(){for(var s in n)t[s]=n[s];for(var c in u)t[c]=u[c]}(),typeof window<"u"&&(window.filterXSS=e.exports);function a(){return typeof self<"u"&&typeof DedicatedWorkerGlobalScope<"u"&&self instanceof DedicatedWorkerGlobalScope}a()&&(self.filterXSS=e.exports)}(Co,Co.exports)),Co.exports}e2();const Kt=i.defineComponent({name:"FMarkdownPreview",props:qa,setup(e){return()=>i.createVNode("div",{class:"f-markdown-preview-container"},[i.createVNode(su,{modelValue:e.content},null)])}});Kt.install=e=>{e.component(Kt.name,Kt)};const No="farris-x-preview-bridge",Lo=1,Oo="assistant.message";function Ts(e){try{return JSON.parse(JSON.stringify(e))}catch{return{...e,content:e.content}}}function Ns(e){return e!==null&&typeof e=="object"}function Ls(e){if(!Ns(e)||e.source!==No||e.v!==Lo||e.type!==Oo)return!1;const t=e.payload;return!(!Ns(t)||typeof t.messageId!="string"||t.messageId.length===0||t.role!=="user"&&t.role!=="assistant")}let t2=0;const nr=[];function Qt(){var e;return((e=nr[nr.length-1])==null?void 0:e.h)??{}}function n2(e){const t=++t2;return nr.push({id:t,h:e}),()=>{const n=nr.findIndex(u=>u.id===t);n>=0&&nr.splice(n,1)}}const Jt={showPreview(e){var t,n;(n=(t=Qt()).showPreview)==null||n.call(t,e)},replaceRightPreview(e){var t,n;(n=(t=Qt()).showPreview)==null||n.call(t,e)},closePreviewPane(){var e,t;(t=(e=Qt()).closePreviewPane)==null||t.call(e)},closeRightPreview(){var e,t;(t=(e=Qt()).closeRightPreview)==null||t.call(e)},showFullScreenPreview(e){var t,n;(n=(t=Qt()).showFullScreenPreview)==null||n.call(t,e)},closeFullScreenPreview(){var e,t;(t=(e=Qt()).closeFullScreenPreview)==null||t.call(e)},isPreviewLayoutActive(){return typeof Qt().showPreview=="function"}},Os={eventType:"invoke",method:"sendMessage"};function Is(e,t){const n=(t==null?void 0:t.target)??(typeof window<"u"?window.top??window:void 0);if(!n)return!1;try{return n.postMessage({eventType:Os.eventType,method:Os.method,params:[e]},(t==null?void 0:t.targetOrigin)??"*"),!0}catch{return!1}}function r2(e,t){return!!(e.source===window.parent||t&&e.source===window.top||e.source===window)}function Io(e,t,n){const u=Ts(n);try{return e.postMessage({source:No,v:Lo,type:Oo,payload:u},t),!0}catch{return!1}}function Ps(e){const t=e.allowTopAsSource!==!1,n=u=>{var o;r2(u,t)&&(e.allowedParentOrigins&&e.allowedParentOrigins.length>0&&!e.allowedParentOrigins.includes(u.origin)||Ls(u.data)&&((o=e.onAssistantMessage)==null||o.call(e,u.data.payload)))};return window.addEventListener("message",n),()=>window.removeEventListener("message",n)}const Po={subscribe:Ps,postAssistantMessage:Io,sendChatMessage:Is,showPreview:Jt.showPreview,replaceRightPreview:Jt.replaceRightPreview,closePreviewPane:Jt.closePreviewPane,closeRightPreview:Jt.closeRightPreview,showFullScreenPreview:Jt.showFullScreenPreview,closeFullScreenPreview:Jt.closeFullScreenPreview,isPreviewLayoutActive:Jt.isPreviewLayoutActive};function Ro(e,t){try{const n=Po[e];if(typeof n!="function"){console.warn("[AgentWorkbenchSDK] invoke: not a function:",e);return}return n(...t??[])}catch(n){console.warn("[AgentWorkbenchSDK] invoke error:",e,n);return}}const u2="/platform/common/web/renderer/index.html#/preview",o2="Cases/ApplicationTemplates/Contacts/bo-contacts-front/metadata/components/Contacts.frm",i2="Cases/ApplicationTemplates/Contacts/bo-contacts-front/metadata/components",a2="67441dbb-0219-46f2-b247-51555c317995";function Rs(e){if(e.url)return e.url;const t=e.baseUri??u2,n=e.metadataPath??o2,u=e.projectPath??i2,o=e.baseMetadataId??a2;return`${t}?metadataPath=${encodeURIComponent(n)}&projectPath=${encodeURIComponent(u)}&baseMetadataId=${encodeURIComponent(o)}`}function s2(e){if(typeof window>"u")return null;if(e.postMessageTargetOrigin)return e.postMessageTargetOrigin;try{const t=Rs(e),n=new URL(t,window.location.href).origin;return n==="null"||n===""?window.location.origin:n}catch{return null}}const rr=i.defineComponent({name:"ChatPreview",props:Ga,setup(e,{expose:t}){const n=i.ref(null),u=i.ref(null),o=i.ref(!1),r=i.ref(!1),a=i.computed(()=>Rs(e.previewConfig??{})),s=i.computed(()=>{var F;return((F=e.previewConfig)==null?void 0:F.contentType)==="markdown"}),c=i.computed(()=>{var F;return Object.keys(((F=e.previewConfig)==null?void 0:F.contentMap)??{})}),d=i.computed(()=>c.value.filter(F=>F).length>0),f=i.ref(),l=i.ref(),p=i.ref(!1);let m=null;i.onBeforeUnmount(()=>{m==null||m(),m=null,M()}),i.watch(()=>[a.value,n.value,s.value],()=>{if(m==null||m(),m=null,s.value)return;const F=n.value;if(!F)return;p.value=!1,o.value=!1,r.value=!1;const V=Date.now(),O=200,$=300,re=1e4;let te=!1,P=null,R=null;R=window.setTimeout(()=>{R=null,te||(r.value=!0)},O);const N=()=>{if(te)return;if(te=!0,P&&(window.clearTimeout(P),P=null),R&&(window.clearTimeout(R),R=null),p.value=!0,D(F),r.value){const K=Date.now()-V,Z=Math.max(0,$-K);setTimeout(()=>{o.value=!0},Z)}else o.value=!0;const U=()=>{var K;return(K=e.onIframeLoad)==null?void 0:K.call(e)};U(),window.setTimeout(U,0),window.setTimeout(U,120)},L=()=>{var U;te||(te=!0,R&&(window.clearTimeout(R),R=null),console.warn("ChatPreview: iframe load timeout"),p.value=!0,o.value=!0,(U=e.onIframeLoad)==null||U.call(e))};F.addEventListener("load",N,{once:!0}),P=window.setTimeout(L,re),m=()=>{F.removeEventListener("load",N),P&&(window.clearTimeout(P),P=null),R&&(window.clearTimeout(R),R=null)}},{flush:"post"}),i.watch([s,()=>{var F;return(F=e.previewConfig)==null?void 0:F.contentMap}],()=>{M(),s.value&&i.nextTick(()=>I())},{flush:"post"}),i.watch(()=>{var F;return(F=e.previewConfig)==null?void 0:F.contentMap},F=>{if(F){const V=Object.keys(F);f.value=V[0]??""}else f.value="";h()},{immediate:!0});function h(F){var V,O;F&&(f.value=F),d.value&&f.value?l.value=((O=(V=e.previewConfig)==null?void 0:V.contentMap)==null?void 0:O[f.value])||"":l.value=""}function y(F){var $;if(s.value||!p.value)return!1;const V=($=n.value)==null?void 0:$.contentWindow;if(!V)return!1;const O=s2(e.previewConfig??{});return O?Io(V,O,F):!1}t({postAssistantPayload:y});const x=i.ref(!1);let v=null;const g=800;function b(){x.value=!0,B(!0),v!=null&&(window.clearTimeout(v),v=null)}function w(){v!=null&&window.clearTimeout(v),v=window.setTimeout(()=>{x.value=!1,B(!1),v=null},g)}function k(){b(),w()}function S(){b()}function _(){w()}let E=[];function W(){const F=u.value;if(!F)return[];const V=[],O=F.querySelectorAll(".f-markdown-preview-container");return O.length>0&&O.forEach($=>V.push($)),V.length===0&&F.scrollHeight>F.clientHeight&&V.push(F),V}function B(F){const V=u.value;V&&V.querySelectorAll(".f-markdown-preview-container").forEach(O=>{O.classList.toggle("f-chat-preview-scrollbar-visible",F)})}function I(){const F=W();E=F,F.forEach(V=>{V.addEventListener("scroll",k,{passive:!0}),V.addEventListener("mouseenter",S),V.addEventListener("mouseleave",_)})}function M(){E.forEach(F=>{F.removeEventListener("scroll",k),F.removeEventListener("mouseenter",S),F.removeEventListener("mouseleave",_)}),E=[]}function D(F){try{const V=F.contentDocument;if(!V)return;const O="f-chat-preview-injected-scrollbar-style";if(V.getElementById(O))return;const $=V.createElement("style");$.id=O,$.textContent=`
91
+ `};e.renderer.rules.fence=f,e.renderer.rules.code_block=f},S1=(e,t)=>{const n=e.renderer.rules.fence.bind(e.renderer.rules);e.renderer.rules.fence=(u,o,r,a,s)=>{var f,l;const c=u[o],d=c.content.trim();if(c.info==="echarts"){if(c.attrSet("class",`${q}-echarts`),c.attrSet("data-echarts-theme",t.themeRef.value),c.map&&c.level===0){const p=c.map[1]-1,m=!!((l=(f=a.srcLines[p])==null?void 0:f.trim())!=null&&l.startsWith("```"));c.attrSet("data-closed",`${m}`),c.attrSet("data-line",String(c.map[0]))}return`<div ${s.renderAttrs(c)} style="width: 100%; aspect-ratio: 4 / 3;">${e.utils.escapeHtml(d)}</div>`}return n(u,o,r,a,s)}},F1=(e,t)=>{e.renderer.rules.heading_open=(n,u)=>{var s;const o=n[u],r=((s=n[u+1].children)==null?void 0:s.reduce((c,d)=>c+(["text","code_inline","math_inline"].includes(d.type)&&d.content||""),""))||"",a=o.markup.length;return t.headsRef.value.push({text:r,level:a,line:o.map[0],currentToken:o,nextToken:n[u+1]}),o.map&&o.level===0&&o.attrSet("id",t.mdHeadingId({text:r,level:a,index:t.headsRef.value.length,currentToken:o,nextToken:n[u+1]})),e.renderer.renderToken(n,u,t)},e.renderer.rules.heading_close=(n,u,o,r,a)=>a.renderToken(n,u,o)},is={block:[{open:"$$",close:"$$"},{open:"\\[",close:"\\]"}],inline:[{open:"$$",close:"$$"},{open:"$",close:"$"},{open:"\\[",close:"\\]"},{open:"\\(",close:"\\)"}]},D1=e=>(t,n)=>{const u=e.delimiters;for(const o of u){if(!t.src.startsWith(o.open,t.pos))continue;const r=t.pos+o.open.length;let a=r;for(;(a=t.src.indexOf(o.close,a))!==-1;){let s=0,c=a-1;for(;c>=0&&t.src[c]==="\\";)s++,c--;if(s%2===0)break;a+=o.close.length}if(a!==-1){if(a-r===0)return n||(t.pending+=o.open+o.close),t.pos=a+o.close.length,!0;if(!n){const s=t.push("math_inline","math",0);s.markup=o.open,s.content=t.src.slice(r,a)}return t.pos=a+o.close.length,!0}}return!1},T1=e=>(t,n,u,o)=>{const r=e.delimiters,a=t.bMarks[n]+t.tShift[n],s=t.eMarks[n],c=(d,f,l)=>{t.line=f;const p=t.push("math_block","math",0);return p.block=!0,p.content=d,p.map=[n,t.line],p.markup=l,!0};for(const d of r){const f=a;if(t.src.slice(f,f+d.open.length)!==d.open)continue;const l=f+d.open.length,p=t.src.slice(l,s).trim(),m=p==="",h=p===d.close,x=p.endsWith(d.close);if(!m&&!h&&!x)continue;if(o)return!0;if(h)return c("",n+1,d.open);if(!m&&x){const w=p.slice(0,-d.close.length);return c(w,n+1,d.open)}let y=n+1,v=!1,g="";for(;y<u;y++){const w=t.bMarks[y]+t.tShift[y],k=t.eMarks[y];if(w<k&&t.tShift[y]<t.blkIndent)break;if(t.src.slice(w,k).trim().endsWith(d.close)){const S=t.src.slice(0,k).lastIndexOf(d.close);g=t.src.slice(w,S),v=!0;break}}if(!v)continue;const b=t.getLines(n+1,y,t.tShift[n],!0)+(g.trim()?g:"");return c(b,y+1,d.open)}return!1},N1=(e,{katexRef:t,inlineDelimiters:n,blockDelimiters:u})=>{const o=(s,c,d,f,l=!1)=>{const p={attrs:vo(s,[["class",c]])},m=f.renderAttrs(p);if(!t.value)return`<${d} ${m}>${s.content}</${d}>`;const h=t.value.renderToString(s.content,ot.katexConfig({throwOnError:!1,displayMode:l}));return`<${d} ${m} data-processed>${h}</${d}>`},r=(s,c,d,f,l)=>o(s[c],`${q}-katex-inline`,"span",l),a=(s,c,d,f,l)=>o(s[c],`${q}-katex-block`,"p",l,!0);e.inline.ruler.before("escape","math_inline",D1({delimiters:n||is.inline})),e.block.ruler.after("blockquote","math_block",T1({delimiters:u||is.block}),{alt:["paragraph","reference","blockquote","list"]}),e.renderer.rules.math_inline=r,e.renderer.rules.math_block=a},L1=(e,t)=>{const n=e.renderer.rules.fence.bind(e.renderer.rules);e.renderer.rules.fence=(u,o,r,a,s)=>{var f,l;const c=u[o],d=c.content.trim();if(c.info==="mermaid"){if(c.attrSet("class",`${q}-mermaid`),c.attrSet("data-mermaid-theme",t.themeRef.value),c.map&&c.level===0){const m=c.map[1]-1,h=!!((l=(f=a.srcLines[m])==null?void 0:f.trim())!=null&&l.startsWith("```"));c.attrSet("data-closed",`${h}`),c.attrSet("data-line",String(c.map[0]))}const p=iu.get(d);return p?(c.attrSet("data-processed",""),c.attrSet("data-content",d),`<p ${s.renderAttrs(c)}>${p}</p>`):`<div ${s.renderAttrs(c)}>${e.utils.escapeHtml(d)}</div>`}return n(u,o,r,a,s)}},as=(e,t,n)=>{const u=e.attrIndex(t),o=[t,n];u<0?e.attrPush(o):(e.attrs=e.attrs||[],e.attrs[u]=o)},I1=e=>e.type==="inline",O1=e=>e.type==="paragraph_open",P1=e=>e.type==="list_item_open",R1=e=>e.content.indexOf("[ ] ")===0||e.content.indexOf("[x] ")===0||e.content.indexOf("[X] ")===0,M1=(e,t)=>I1(e[t])&&O1(e[t-1])&&P1(e[t-2])&&R1(e[t]),V1=(e,t)=>{const n=e[t].level-1;for(let u=t-1;u>=0;u--)if(e[u].level===n)return u;return-1},B1=e=>{const t=new e("html_inline","",0);return t.content="<label>",t},z1=e=>{const t=new e("html_inline","",0);return t.content="</label>",t},j1=(e,t,n)=>{const u=new n("html_inline","",0);return u.content='<label class="task-list-item-label" for="'+t+'">'+e+"</label>",u.attrs=[["for",t]],u},H1=(e,t,n)=>{const u=new t("html_inline","",0),o=n.enabled?" ":' disabled="" ';return e.content.indexOf("[ ] ")===0?u.content='<input class="task-list-item-checkbox"'+o+'type="checkbox">':(e.content.indexOf("[x] ")===0||e.content.indexOf("[X] ")===0)&&(u.content='<input class="task-list-item-checkbox" checked=""'+o+'type="checkbox">'),u},U1=(e,t,n)=>{if(e.children=e.children||[],e.children.unshift(H1(e,t,n)),e.children[1].content=e.children[1].content.slice(3),e.content=e.content.slice(3),n.label)if(n.labelAfter){e.children.pop();const u="task-item-"+Math.ceil(Math.random()*(1e4*1e3)-1e3);e.children[0].content=e.children[0].content.slice(0,-1)+' id="'+u+'">',e.children.push(j1(e.content,u,t))}else e.children.unshift(B1(t)),e.children.push(z1(t))},$1=(e,t={})=>{e.core.ruler.after("inline","github-task-lists",n=>{const u=n.tokens;for(let o=2;o<u.length;o++)M1(u,o)&&(U1(u[o],n.Token,t),as(u[o-2],"class","task-list-item"+(t.enabled?" enabled":" ")),as(u[V1(u,o-2)],"class","contains-task-list"))})},W1=e=>{e.core.ruler.push("init-line-number",t=>(t.tokens.forEach(n=>{n.map&&(n.attrs||(n.attrs=[]),n.attrs.push(["data-line",n.map[0].toString()]))}),!0))},G1=(e,t)=>{const{editorConfig:n,markdownItPlugins:u}=ot,o=i.inject("editorId"),r=i.inject("language"),a=i.inject("usedLanguageText"),s=i.inject("showCodeRowNumber"),c=i.inject("theme"),d=i.inject("customIcon"),f=i.inject("rootRef"),l=i.inject("setting"),p=i.ref([]),m=A1(e),h=k1(e),{reRenderRef:x,replaceMermaid:y}=C1(e),{reRenderEcharts:v,replaceEcharts:g}=v1(e),b=qe({html:!0,breaks:!0,linkify:!0}),w=[{type:"image",plugin:t1,options:{figcaption:!0,classes:"md-zoom"}},{type:"admonition",plugin:E1,options:{}},{type:"taskList",plugin:$1,options:{}},{type:"heading",plugin:F1,options:{mdHeadingId:e.mdHeadingId,headsRef:p}},{type:"code",plugin:_1,options:{editorId:o,usedLanguageTextRef:a,codeFoldable:e.codeFoldable,autoFoldThreshold:e.autoFoldThreshold,customIconRef:d}},{type:"sub",plugin:u1,options:{}},{type:"sup",plugin:a1,options:{}}];e.noKatex||w.push({type:"katex",plugin:N1,options:{katexRef:h}}),e.noMermaid||w.push({type:"mermaid",plugin:L1,options:{themeRef:c}}),e.noEcharts||w.push({type:"echarts",plugin:S1,options:{themeRef:c}}),u(w,{editorId:o}).forEach(H=>{b.use(H.plugin,H.options)});const k=b.options.highlight;b.set({highlight:(H,F,R)=>{if(k){const re=k(H,F,R);if(re)return re}let I;!e.noHighlight&&m.value?m.value.getLanguage(F)?I=m.value.highlight(H,{language:F,ignoreIllegals:!0}).value:I=m.value.highlightAuto(H).value:I=b.utils.escapeHtml(H);const U=s?Xh(I.replace(/^\n+|\n+$/g,""),H.replace(/^\n+|\n+$/g,"")):`<span class="${q}-code-block">${I.replace(/^\n+|\n+$/g,"")}</span>`;return`<pre><code class="language-${F}" language=${F}>${U}</code></pre>`}}),W1(b);const S=i.ref(`_article-key_${po()}`),_=i.ref(e.sanitize(b.render(e.modelValue,{srcLines:e.modelValue.split(`
92
+ `)})));let E=()=>{},W=()=>{};const V=()=>{var F;const H=(F=f.value)==null?void 0:F.querySelectorAll(`#${o} p.${q}-mermaid:not([data-closed=false])`);W(),W=Qh(H,{customIcon:d.value}),E(),E=Jh(H,{customIcon:d.value})},O=()=>{nt.emit(o,$h,_.value),e.onHtmlChanged(_.value),e.onGetCatalog(p.value),nt.emit(o,xo,p.value),i.nextTick(()=>{y().then(V),g()})},B=()=>{p.value=[],_.value=e.sanitize(b.render(e.modelValue,{srcLines:e.modelValue.split(`
93
+ `)}))},D=i.computed(()=>(e.noKatex||!!h.value)&&(e.noHighlight||!!m.value));let j=-1;return i.watch([i.toRef(e,"modelValue"),D,x,r],()=>{j=window.setTimeout(()=>{B()},t?0:n.renderDelay)}),i.watch(()=>l.value.preview,()=>{l.value.preview&&i.nextTick(()=>{y().then(V),g(),nt.emit(o,xo,p.value)})}),i.watch([_,v],()=>{O()}),i.onMounted(O),i.onMounted(()=>{nt.on(o,{name:Wh,callback(){nt.emit(o,xo,p.value)}}),nt.on(o,{name:Za,callback:()=>{S.value=`_article-key_${po()}`,B()}})}),i.onBeforeUnmount(()=>{E(),W(),clearTimeout(j)}),{html:_,key:S}},q1=(e,t)=>{const n=i.inject("editorId"),u=i.inject("setting"),{noImgZoomIn:o}=e,r=Oh(()=>{const a=document.querySelectorAll(`#${n}-preview img:not(.not-zoom):not(.medium-zoom-image)`);a.length!==0&&m1(a,{background:"#00000073"})});i.onMounted(async()=>{!o&&u.value.preview&&await r()}),i.watch([t,()=>u.value.preview],async()=>{!o&&u.value.preview&&await r()})},ss={checked:{regexp:/- \[x\]/,value:"- [ ]"},unChecked:{regexp:/- \[\s\]/,value:"- [x]"}},X1=(e,t)=>{const n=i.inject("editorId"),u=i.inject("rootRef");let o=()=>{};const r=()=>{if(!u.value)return!1;const a=u.value.querySelectorAll(".task-list-item.enabled"),s=c=>{var h;c.preventDefault();const d=c.target.checked?"unChecked":"checked",f=(h=c.target.parentElement)==null?void 0:h.dataset.line;if(!f)return;const l=Number(f),p=e.modelValue.split(`
94
+ `),m=p[Number(l)].replace(ss[d].regexp,ss[d].value);e.previewOnly?(p[Number(l)]=m,e.onChange(p.join(`
95
+ `))):nt.emit(n,Gh,l+1,m)};a.forEach(c=>{c.addEventListener("click",s)}),o=()=>{a.forEach(c=>{c.removeEventListener("click",s)})}};i.onBeforeUnmount(()=>{o()}),i.watch([t],()=>{o(),i.nextTick(r)},{immediate:!0})},Z1=(e,t,n)=>{const u=i.inject("setting"),o=()=>{i.nextTick(()=>{var a;(a=e.onRemount)==null||a.call(e)})},r=a=>{a&&o()};i.watch([t,n],o),i.watch(()=>u.value.preview,r),i.watch(()=>u.value.htmlPreview,r),i.onMounted(o)},cs={modelValue:{type:String,default:""},onChange:{type:Function,default:()=>{}},onHtmlChanged:{type:Function,default:()=>{}},onGetCatalog:{type:Function,default:()=>{}},mdHeadingId:{type:Function,default:()=>""},noMermaid:{type:Boolean,default:!1},sanitize:{type:Function,default:e=>e},noKatex:{type:Boolean,default:!1},formatCopiedText:{type:Function,default:e=>e},noHighlight:{type:Boolean,default:!1},previewOnly:{type:Boolean,default:!1},noImgZoomIn:{type:Boolean},sanitizeMermaid:{type:Function},codeFoldable:{type:Boolean},autoFoldThreshold:{type:Number},onRemount:{type:Function},noEcharts:{type:Boolean},previewComponent:{type:[Object,Function],default:void 0}};({...cs});const ls=e=>{const t=new DOMParser().parseFromString(e,"text/html");return Array.from(t.body.childNodes)},Y1=(e,t)=>e.nodeType!==t.nodeType?!1:e.nodeType===Node.TEXT_NODE||e.nodeType===Node.COMMENT_NODE?e.textContent===t.textContent:e.nodeType===Node.ELEMENT_NODE?e.outerHTML===t.outerHTML:e.isEqualNode?e.isEqualNode(t):!1,K1=i.defineComponent({name:"UpdateOnDemand",props:{id:{type:String,required:!0},class:{type:[String,Array,Object],required:!0},html:{type:String,required:!0}},setup(e){const t=i.ref(),n=e.html,u=(o,r)=>{if(!t.value)return;const a=t.value,s=Array.from(a.childNodes),c=Math.min(o.length,r.length);let d=-1;for(let l=0;l<c;l++)if(!Y1(o[l],r[l])){d=l;break}if(d===-1)if(r.length>o.length)d=o.length;else if(o.length>r.length)d=r.length;else return;const f=Math.min(d,s.length);for(let l=s.length-1;l>=f;l--)s[l].remove();for(let l=d;l<o.length;l++)a.appendChild(o[l].cloneNode(!0))};return i.watch(()=>e.html,(o,r)=>{const a=ls(o),s=ls(r||"");u(a,s)}),()=>i.createVNode("div",{id:e.id,class:e.class,innerHTML:n,ref:t},null)}}),Q1=i.defineComponent({name:"ContentPreview",props:cs,setup(e){const t=i.inject("editorId"),n=i.inject("setting"),u=i.inject("previewTheme"),o=i.inject("showCodeRowNumber"),{html:r,key:a}=G1(e,e.previewOnly);w1(e,r,a),q1(e,r),X1(e,r),Z1(e,r,a);const s=i.computed(()=>[`${q}-preview`,`${u==null?void 0:u.value}-theme`,o&&`${q}-scrn`].filter(Boolean)),c=()=>{const d=`${t}-preview`;return e.previewComponent?i.h(e.previewComponent,{key:a.value,html:r.value,id:d,class:s.value}):i.createVNode(K1,{key:a.value,html:r.value,id:d,class:s.value},null)};return()=>i.createVNode(i.Fragment,null,[n.value.preview&&(e.previewOnly?c():i.createVNode("div",{id:`${t}-preview-wrapper`,class:`${q}-preview-wrapper`,key:"content-preview-wrapper"},[c()])),n.value.htmlPreview&&i.createVNode("div",{id:`${t}-html-wrapper`,class:`${q}-preview-wrapper`,key:"html-preview-wrapper"},[i.createVNode("div",{class:`${q}-html`},[r.value])])])}}),J1=({text:e})=>e,ds={modelValue:{type:String,default:""},onChange:{type:Function,default:void 0},theme:{type:String,default:"light"},class:{type:String,default:""},language:{type:String,default:"zh-CN"},onHtmlChanged:{type:Function,default:void 0},onGetCatalog:{type:Function,default:void 0},editorId:{type:String,default:void 0},id:{type:String,default:void 0},showCodeRowNumber:{type:Boolean,default:!0},previewTheme:{type:String,default:"default"},style:{type:Object,default:()=>({})},mdHeadingId:{type:Function,default:J1},sanitize:{type:Function,default:e=>e},noMermaid:{type:Boolean,default:!1},noKatex:{type:Boolean,default:!1},codeTheme:{type:String,default:"atom"},formatCopiedText:{type:Function,default:e=>e},codeStyleReverse:{type:Boolean,default:!0},codeStyleReverseList:{type:Array,default:["default","mk-cute"]},noHighlight:{type:Boolean,default:!1},noImgZoomIn:{type:Boolean,default:!1},customIcon:{type:Object,default:{}},sanitizeMermaid:{type:Function,default:e=>Promise.resolve(e)},codeFoldable:{type:Boolean,default:!0},autoFoldThreshold:{type:Number,default:30},onRemount:{type:Function,default:void 0},noEcharts:{type:Boolean,default:!1},previewComponent:{type:[Object,Function],default:void 0}};({...ds});const fs=["onHtmlChanged","onGetCatalog","onChange","onRemount","update:modelValue"];[...fs];const e2=(e,t,n)=>{const{editorId:u}=n,o={rerender(){nt.emit(u,Za)}};t.expose(o)},au=i.defineComponent({name:"MdPreview",props:ds,emits:fs,setup(e,t){const{noKatex:n,noMermaid:u,noHighlight:o}=e,r=i.ref(),a=x1(e);y1(e,{rootRef:r,editorId:a}),e2(e,t,{editorId:a}),i.onBeforeUnmount(()=>{nt.clear(a)});const s=l=>{var p;(p=e.onChange)==null||p.call(e,l),t.emit("onChange",l),t.emit("update:modelValue",l)},c=l=>{var p;(p=e.onHtmlChanged)==null||p.call(e,l),t.emit("onHtmlChanged",l)},d=l=>{var p;(p=e.onGetCatalog)==null||p.call(e,l),t.emit("onGetCatalog",l)},f=()=>{var l;(l=e.onRemount)==null||l.call(e),t.emit("onRemount")};return()=>i.createVNode("div",{id:a,class:[q,e.class,e.theme==="dark"&&`${q}-dark`,`${q}-previewOnly`],style:e.style,ref:r},[i.createVNode(Q1,{modelValue:e.modelValue,onChange:s,onHtmlChanged:c,onGetCatalog:d,mdHeadingId:e.mdHeadingId,noMermaid:u,sanitize:e.sanitize,noKatex:n,formatCopiedText:e.formatCopiedText,noHighlight:o,noImgZoomIn:e.noImgZoomIn,previewOnly:!0,sanitizeMermaid:e.sanitizeMermaid,codeFoldable:e.codeFoldable,autoFoldThreshold:e.autoFoldThreshold,onRemount:f,noEcharts:e.noEcharts,previewComponent:e.previewComponent},null)])}});au.install=e=>(e.component(au.name,au),e);const t2={onClick:{type:Function,default:void 0},language:{type:String,default:void 0},theme:{type:String,default:void 0},disabled:{type:Boolean,default:void 0}},Ao=i.defineComponent({name:"NormalFooterToolbar",props:t2,emits:["onClick"],setup(e,t){return()=>{const n=Uh({props:e,ctx:t});return i.createVNode("div",{class:[`${q}-footer-item`,e.disabled&&`${q}-disabled`],onClick:u=>{var o;e.disabled||((o=e.onClick)==null||o.call(e,u),t.emit("onClick",u))}},[n])}}});Ao.install=e=>(e.component(Ao.name,Ao),e);var ko={exports:{}},me={},Co={exports:{}},Kt={},hs;function ps(){if(hs)return Kt;hs=1;function e(){var r={};return r["align-content"]=!1,r["align-items"]=!1,r["align-self"]=!1,r["alignment-adjust"]=!1,r["alignment-baseline"]=!1,r.all=!1,r["anchor-point"]=!1,r.animation=!1,r["animation-delay"]=!1,r["animation-direction"]=!1,r["animation-duration"]=!1,r["animation-fill-mode"]=!1,r["animation-iteration-count"]=!1,r["animation-name"]=!1,r["animation-play-state"]=!1,r["animation-timing-function"]=!1,r.azimuth=!1,r["backface-visibility"]=!1,r.background=!0,r["background-attachment"]=!0,r["background-clip"]=!0,r["background-color"]=!0,r["background-image"]=!0,r["background-origin"]=!0,r["background-position"]=!0,r["background-repeat"]=!0,r["background-size"]=!0,r["baseline-shift"]=!1,r.binding=!1,r.bleed=!1,r["bookmark-label"]=!1,r["bookmark-level"]=!1,r["bookmark-state"]=!1,r.border=!0,r["border-bottom"]=!0,r["border-bottom-color"]=!0,r["border-bottom-left-radius"]=!0,r["border-bottom-right-radius"]=!0,r["border-bottom-style"]=!0,r["border-bottom-width"]=!0,r["border-collapse"]=!0,r["border-color"]=!0,r["border-image"]=!0,r["border-image-outset"]=!0,r["border-image-repeat"]=!0,r["border-image-slice"]=!0,r["border-image-source"]=!0,r["border-image-width"]=!0,r["border-left"]=!0,r["border-left-color"]=!0,r["border-left-style"]=!0,r["border-left-width"]=!0,r["border-radius"]=!0,r["border-right"]=!0,r["border-right-color"]=!0,r["border-right-style"]=!0,r["border-right-width"]=!0,r["border-spacing"]=!0,r["border-style"]=!0,r["border-top"]=!0,r["border-top-color"]=!0,r["border-top-left-radius"]=!0,r["border-top-right-radius"]=!0,r["border-top-style"]=!0,r["border-top-width"]=!0,r["border-width"]=!0,r.bottom=!1,r["box-decoration-break"]=!0,r["box-shadow"]=!0,r["box-sizing"]=!0,r["box-snap"]=!0,r["box-suppress"]=!0,r["break-after"]=!0,r["break-before"]=!0,r["break-inside"]=!0,r["caption-side"]=!1,r.chains=!1,r.clear=!0,r.clip=!1,r["clip-path"]=!1,r["clip-rule"]=!1,r.color=!0,r["color-interpolation-filters"]=!0,r["column-count"]=!1,r["column-fill"]=!1,r["column-gap"]=!1,r["column-rule"]=!1,r["column-rule-color"]=!1,r["column-rule-style"]=!1,r["column-rule-width"]=!1,r["column-span"]=!1,r["column-width"]=!1,r.columns=!1,r.contain=!1,r.content=!1,r["counter-increment"]=!1,r["counter-reset"]=!1,r["counter-set"]=!1,r.crop=!1,r.cue=!1,r["cue-after"]=!1,r["cue-before"]=!1,r.cursor=!1,r.direction=!1,r.display=!0,r["display-inside"]=!0,r["display-list"]=!0,r["display-outside"]=!0,r["dominant-baseline"]=!1,r.elevation=!1,r["empty-cells"]=!1,r.filter=!1,r.flex=!1,r["flex-basis"]=!1,r["flex-direction"]=!1,r["flex-flow"]=!1,r["flex-grow"]=!1,r["flex-shrink"]=!1,r["flex-wrap"]=!1,r.float=!1,r["float-offset"]=!1,r["flood-color"]=!1,r["flood-opacity"]=!1,r["flow-from"]=!1,r["flow-into"]=!1,r.font=!0,r["font-family"]=!0,r["font-feature-settings"]=!0,r["font-kerning"]=!0,r["font-language-override"]=!0,r["font-size"]=!0,r["font-size-adjust"]=!0,r["font-stretch"]=!0,r["font-style"]=!0,r["font-synthesis"]=!0,r["font-variant"]=!0,r["font-variant-alternates"]=!0,r["font-variant-caps"]=!0,r["font-variant-east-asian"]=!0,r["font-variant-ligatures"]=!0,r["font-variant-numeric"]=!0,r["font-variant-position"]=!0,r["font-weight"]=!0,r.grid=!1,r["grid-area"]=!1,r["grid-auto-columns"]=!1,r["grid-auto-flow"]=!1,r["grid-auto-rows"]=!1,r["grid-column"]=!1,r["grid-column-end"]=!1,r["grid-column-start"]=!1,r["grid-row"]=!1,r["grid-row-end"]=!1,r["grid-row-start"]=!1,r["grid-template"]=!1,r["grid-template-areas"]=!1,r["grid-template-columns"]=!1,r["grid-template-rows"]=!1,r["hanging-punctuation"]=!1,r.height=!0,r.hyphens=!1,r.icon=!1,r["image-orientation"]=!1,r["image-resolution"]=!1,r["ime-mode"]=!1,r["initial-letters"]=!1,r["inline-box-align"]=!1,r["justify-content"]=!1,r["justify-items"]=!1,r["justify-self"]=!1,r.left=!1,r["letter-spacing"]=!0,r["lighting-color"]=!0,r["line-box-contain"]=!1,r["line-break"]=!1,r["line-grid"]=!1,r["line-height"]=!1,r["line-snap"]=!1,r["line-stacking"]=!1,r["line-stacking-ruby"]=!1,r["line-stacking-shift"]=!1,r["line-stacking-strategy"]=!1,r["list-style"]=!0,r["list-style-image"]=!0,r["list-style-position"]=!0,r["list-style-type"]=!0,r.margin=!0,r["margin-bottom"]=!0,r["margin-left"]=!0,r["margin-right"]=!0,r["margin-top"]=!0,r["marker-offset"]=!1,r["marker-side"]=!1,r.marks=!1,r.mask=!1,r["mask-box"]=!1,r["mask-box-outset"]=!1,r["mask-box-repeat"]=!1,r["mask-box-slice"]=!1,r["mask-box-source"]=!1,r["mask-box-width"]=!1,r["mask-clip"]=!1,r["mask-image"]=!1,r["mask-origin"]=!1,r["mask-position"]=!1,r["mask-repeat"]=!1,r["mask-size"]=!1,r["mask-source-type"]=!1,r["mask-type"]=!1,r["max-height"]=!0,r["max-lines"]=!1,r["max-width"]=!0,r["min-height"]=!0,r["min-width"]=!0,r["move-to"]=!1,r["nav-down"]=!1,r["nav-index"]=!1,r["nav-left"]=!1,r["nav-right"]=!1,r["nav-up"]=!1,r["object-fit"]=!1,r["object-position"]=!1,r.opacity=!1,r.order=!1,r.orphans=!1,r.outline=!1,r["outline-color"]=!1,r["outline-offset"]=!1,r["outline-style"]=!1,r["outline-width"]=!1,r.overflow=!1,r["overflow-wrap"]=!1,r["overflow-x"]=!1,r["overflow-y"]=!1,r.padding=!0,r["padding-bottom"]=!0,r["padding-left"]=!0,r["padding-right"]=!0,r["padding-top"]=!0,r.page=!1,r["page-break-after"]=!1,r["page-break-before"]=!1,r["page-break-inside"]=!1,r["page-policy"]=!1,r.pause=!1,r["pause-after"]=!1,r["pause-before"]=!1,r.perspective=!1,r["perspective-origin"]=!1,r.pitch=!1,r["pitch-range"]=!1,r["play-during"]=!1,r.position=!1,r["presentation-level"]=!1,r.quotes=!1,r["region-fragment"]=!1,r.resize=!1,r.rest=!1,r["rest-after"]=!1,r["rest-before"]=!1,r.richness=!1,r.right=!1,r.rotation=!1,r["rotation-point"]=!1,r["ruby-align"]=!1,r["ruby-merge"]=!1,r["ruby-position"]=!1,r["shape-image-threshold"]=!1,r["shape-outside"]=!1,r["shape-margin"]=!1,r.size=!1,r.speak=!1,r["speak-as"]=!1,r["speak-header"]=!1,r["speak-numeral"]=!1,r["speak-punctuation"]=!1,r["speech-rate"]=!1,r.stress=!1,r["string-set"]=!1,r["tab-size"]=!1,r["table-layout"]=!1,r["text-align"]=!0,r["text-align-last"]=!0,r["text-combine-upright"]=!0,r["text-decoration"]=!0,r["text-decoration-color"]=!0,r["text-decoration-line"]=!0,r["text-decoration-skip"]=!0,r["text-decoration-style"]=!0,r["text-emphasis"]=!0,r["text-emphasis-color"]=!0,r["text-emphasis-position"]=!0,r["text-emphasis-style"]=!0,r["text-height"]=!0,r["text-indent"]=!0,r["text-justify"]=!0,r["text-orientation"]=!0,r["text-overflow"]=!0,r["text-shadow"]=!0,r["text-space-collapse"]=!0,r["text-transform"]=!0,r["text-underline-position"]=!0,r["text-wrap"]=!0,r.top=!1,r.transform=!1,r["transform-origin"]=!1,r["transform-style"]=!1,r.transition=!1,r["transition-delay"]=!1,r["transition-duration"]=!1,r["transition-property"]=!1,r["transition-timing-function"]=!1,r["unicode-bidi"]=!1,r["vertical-align"]=!1,r.visibility=!1,r["voice-balance"]=!1,r["voice-duration"]=!1,r["voice-family"]=!1,r["voice-pitch"]=!1,r["voice-range"]=!1,r["voice-rate"]=!1,r["voice-stress"]=!1,r["voice-volume"]=!1,r.volume=!1,r["white-space"]=!1,r.widows=!1,r.width=!0,r["will-change"]=!1,r["word-break"]=!0,r["word-spacing"]=!0,r["word-wrap"]=!0,r["wrap-flow"]=!1,r["wrap-through"]=!1,r["writing-mode"]=!1,r["z-index"]=!1,r}function t(r,a,s){}function n(r,a,s){}var u=/javascript\s*\:/img;function o(r,a){return u.test(a)?"":a}return Kt.whiteList=e(),Kt.getDefaultWhiteList=e,Kt.onAttr=t,Kt.onIgnoreAttr=n,Kt.safeAttrValue=o,Kt}var ms,gs;function bs(){return gs||(gs=1,ms={indexOf:function(e,t){var n,u;if(Array.prototype.indexOf)return e.indexOf(t);for(n=0,u=e.length;n<u;n++)if(e[n]===t)return n;return-1},forEach:function(e,t,n){var u,o;if(Array.prototype.forEach)return e.forEach(t,n);for(u=0,o=e.length;u<o;u++)t.call(n,e[u],u,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},trimRight:function(e){return String.prototype.trimRight?e.trimRight():e.replace(/(\s*$)/g,"")}}),ms}var Eo,ys;function n2(){if(ys)return Eo;ys=1;var e=bs();function t(n,u){n=e.trimRight(n),n[n.length-1]!==";"&&(n+=";");var o=n.length,r=!1,a=0,s=0,c="";function d(){if(!r){var p=e.trim(n.slice(a,s)),m=p.indexOf(":");if(m!==-1){var h=e.trim(p.slice(0,m)),x=e.trim(p.slice(m+1));if(h){var y=u(a,c.length,h,x,p);y&&(c+=y+"; ")}}}a=s+1}for(;s<o;s++){var f=n[s];if(f==="/"&&n[s+1]==="*"){var l=n.indexOf("*/",s+2);if(l===-1)break;s=l+1,a=s+1,r=!1}else f==="("?r=!0:f===")"?r=!1:f===";"?r||d():f===`
96
+ `&&d()}return e.trim(c)}return Eo=t,Eo}var _o,xs;function r2(){if(xs)return _o;xs=1;var e=ps(),t=n2();bs();function n(r){return r==null}function u(r){var a={};for(var s in r)a[s]=r[s];return a}function o(r){r=u(r||{}),r.whiteList=r.whiteList||e.whiteList,r.onAttr=r.onAttr||e.onAttr,r.onIgnoreAttr=r.onIgnoreAttr||e.onIgnoreAttr,r.safeAttrValue=r.safeAttrValue||e.safeAttrValue,this.options=r}return o.prototype.process=function(r){if(r=r||"",r=r.toString(),!r)return"";var a=this,s=a.options,c=s.whiteList,d=s.onAttr,f=s.onIgnoreAttr,l=s.safeAttrValue,p=t(r,function(m,h,x,y,v){var g=c[x],b=!1;if(g===!0?b=g:typeof g=="function"?b=g(y):g instanceof RegExp&&(b=g.test(y)),b!==!0&&(b=!1),y=l(x,y),!!y){var w={position:h,sourcePosition:m,source:v,isWhite:b};if(b){var k=d(x,y,w);return n(k)?x+":"+y:k}else{var k=f(x,y,w);if(!n(k))return k}}});return p},_o=o,_o}var ws;function So(){return ws||(ws=1,function(e,t){var n=ps(),u=r2();function o(a,s){var c=new u(s);return c.process(a)}t=e.exports=o,t.FilterCSS=u;for(var r in n)t[r]=n[r];typeof window<"u"&&(window.filterCSS=e.exports)}(Co,Co.exports)),Co.exports}var vs,As;function Fo(){return As||(As=1,vs={indexOf:function(e,t){var n,u;if(Array.prototype.indexOf)return e.indexOf(t);for(n=0,u=e.length;n<u;n++)if(e[n]===t)return n;return-1},forEach:function(e,t,n){var u,o;if(Array.prototype.forEach)return e.forEach(t,n);for(u=0,o=e.length;u<o;u++)t.call(n,e[u],u,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},spaceIndex:function(e){var t=/\s|\n|\t/,n=t.exec(e);return n?n.index:-1}}),vs}var ks;function Cs(){if(ks)return me;ks=1;var e=So().FilterCSS,t=So().getDefaultWhiteList,n=Fo();function u(){return{a:["target","href","title"],abbr:["title"],address:[],area:["shape","coords","href","alt"],article:[],aside:[],audio:["autoplay","controls","crossorigin","loop","muted","preload","src"],b:[],bdi:["dir"],bdo:["dir"],big:[],blockquote:["cite"],br:[],caption:[],center:[],cite:[],code:[],col:["align","valign","span","width"],colgroup:["align","valign","span","width"],dd:[],del:["datetime"],details:["open"],div:[],dl:[],dt:[],em:[],figcaption:[],figure:[],font:["color","size","face"],footer:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],header:[],hr:[],i:[],img:["src","alt","title","width","height","loading"],ins:["datetime"],kbd:[],li:[],mark:[],nav:[],ol:[],p:[],pre:[],s:[],section:[],small:[],span:[],sub:[],summary:[],sup:[],strong:[],strike:[],table:["width","border","align","valign"],tbody:["align","valign"],td:["width","rowspan","colspan","align","valign"],tfoot:["align","valign"],th:["width","rowspan","colspan","align","valign"],thead:["align","valign"],tr:["rowspan","align","valign"],tt:[],u:[],ul:[],video:["autoplay","controls","crossorigin","loop","muted","playsinline","poster","preload","src","height","width"]}}var o=new e;function r(F,R,I){}function a(F,R,I){}function s(F,R,I){}function c(F,R,I){}function d(F){return F.replace(l,"&lt;").replace(p,"&gt;")}function f(F,R,I,U){if(I=V(I),R==="href"||R==="src"){if(I=n.trim(I),I==="#")return"#";if(!(I.substr(0,7)==="http://"||I.substr(0,8)==="https://"||I.substr(0,7)==="mailto:"||I.substr(0,4)==="tel:"||I.substr(0,11)==="data:image/"||I.substr(0,6)==="ftp://"||I.substr(0,2)==="./"||I.substr(0,3)==="../"||I[0]==="#"||I[0]==="/"))return""}else if(R==="background"){if(g.lastIndex=0,g.test(I))return""}else if(R==="style"){if(b.lastIndex=0,b.test(I)||(w.lastIndex=0,w.test(I)&&(g.lastIndex=0,g.test(I))))return"";U!==!1&&(U=U||o,I=U.process(I))}return I=O(I),I}var l=/</g,p=/>/g,m=/"/g,h=/&quot;/g,x=/&#([a-zA-Z0-9]*);?/gim,y=/&colon;?/gim,v=/&newline;?/gim,g=/((j\s*a\s*v\s*a|v\s*b|l\s*i\s*v\s*e)\s*s\s*c\s*r\s*i\s*p\s*t\s*|m\s*o\s*c\s*h\s*a):/gi,b=/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n\s*\(.*/gi,w=/u\s*r\s*l\s*\(.*/gi;function k(F){return F.replace(m,"&quot;")}function S(F){return F.replace(h,'"')}function _(F){return F.replace(x,function(R,I){return I[0]==="x"||I[0]==="X"?String.fromCharCode(parseInt(I.substr(1),16)):String.fromCharCode(parseInt(I,10))})}function E(F){return F.replace(y,":").replace(v," ")}function W(F){for(var R="",I=0,U=F.length;I<U;I++)R+=F.charCodeAt(I)<32?" ":F.charAt(I);return n.trim(R)}function V(F){return F=S(F),F=_(F),F=E(F),F=W(F),F}function O(F){return F=k(F),F=d(F),F}function B(){return""}function D(F,R){typeof R!="function"&&(R=function(){});var I=!Array.isArray(F);function U(P){return I?!0:n.indexOf(F,P)!==-1}var re=[],te=!1;return{onIgnoreTag:function(P,M,T){if(U(P))if(T.isClosing){var L="[/removed]",$=T.position+L.length;return re.push([te!==!1?te:T.position,$]),te=!1,L}else return te||(te=T.position),"[removed]";else return R(P,M,T)},remove:function(P){var M="",T=0;return n.forEach(re,function(L){M+=P.slice(T,L[0]),T=L[1]}),M+=P.slice(T),M}}}function j(F){for(var R="",I=0;I<F.length;){var U=F.indexOf("<!--",I);if(U===-1){R+=F.slice(I);break}R+=F.slice(I,U);var re=F.indexOf("-->",U);if(re===-1)break;I=re+3}return R}function H(F){var R=F.split("");return R=R.filter(function(I){var U=I.charCodeAt(0);return U===127?!1:U<=31?U===10||U===13:!0}),R.join("")}return me.whiteList=u(),me.getDefaultWhiteList=u,me.onTag=r,me.onIgnoreTag=a,me.onTagAttr=s,me.onIgnoreTagAttr=c,me.safeAttrValue=f,me.escapeHtml=d,me.escapeQuote=k,me.unescapeQuote=S,me.escapeHtmlEntities=_,me.escapeDangerHtml5Entities=E,me.clearNonPrintableCharacter=W,me.friendlyAttrValue=V,me.escapeAttrValue=O,me.onIgnoreTagStripAll=B,me.StripTagBody=D,me.stripCommentTag=j,me.stripBlankChar=H,me.attributeWrapSign='"',me.cssFilter=o,me.getDefaultCSSWhiteList=t,me}var su={},Es;function _s(){if(Es)return su;Es=1;var e=Fo();function t(l){var p=e.spaceIndex(l),m;return p===-1?m=l.slice(1,-1):m=l.slice(1,p+1),m=e.trim(m).toLowerCase(),m.slice(0,1)==="/"&&(m=m.slice(1)),m.slice(-1)==="/"&&(m=m.slice(0,-1)),m}function n(l){return l.slice(0,2)==="</"}function u(l,p,m){var h="",x=0,y=!1,v=!1,g=0,b=l.length,w="",k="";e:for(g=0;g<b;g++){var S=l.charAt(g);if(y===!1){if(S==="<"){y=g;continue}}else if(v===!1){if(S==="<"){h+=m(l.slice(x,g)),y=g,x=g;continue}if(S===">"||g===b-1){h+=m(l.slice(x,y)),k=l.slice(y,g+1),w=t(k),h+=p(y,h.length,w,k,n(k)),x=g+1,y=!1;continue}if(S==='"'||S==="'")for(var _=1,E=l.charAt(g-_);E.trim()===""||E==="=";){if(E==="="){v=S;continue e}E=l.charAt(g-++_)}}else if(S===v){v=!1;continue}}return x<b&&(h+=m(l.substr(x))),h}var o=/[^a-zA-Z0-9\\_:.-]/gim;function r(l,p){var m=0,h=0,x=[],y=!1,v=l.length;function g(_,E){if(_=e.trim(_),_=_.replace(o,"").toLowerCase(),!(_.length<1)){var W=p(_,E||"");W&&x.push(W)}}for(var b=0;b<v;b++){var w=l.charAt(b),k,S;if(y===!1&&w==="="){y=l.slice(m,b),m=b+1,h=l.charAt(m)==='"'||l.charAt(m)==="'"?m:s(l,b+1);continue}if(y!==!1&&b===h){if(S=l.indexOf(w,b+1),S===-1)break;k=e.trim(l.slice(h+1,S)),g(y,k),y=!1,b=S,m=b+1;continue}if(/\s|\n|\t/.test(w))if(l=l.replace(/\s|\n|\t/g," "),y===!1)if(S=a(l,b),S===-1){k=e.trim(l.slice(m,b)),g(k),y=!1,m=b+1;continue}else{b=S-1;continue}else if(S=c(l,b-1),S===-1){k=e.trim(l.slice(m,b)),k=f(k),g(y,k),y=!1,m=b+1;continue}else continue}return m<l.length&&(y===!1?g(l.slice(m)):g(y,f(e.trim(l.slice(m))))),e.trim(x.join(" "))}function a(l,p){for(;p<l.length;p++){var m=l[p];if(m!==" ")return m==="="?p:-1}}function s(l,p){for(;p<l.length;p++){var m=l[p];if(m!==" ")return m==="'"||m==='"'?p:-1}}function c(l,p){for(;p>0;p--){var m=l[p];if(m!==" ")return m==="="?p:-1}}function d(l){return l[0]==='"'&&l[l.length-1]==='"'||l[0]==="'"&&l[l.length-1]==="'"}function f(l){return d(l)?l.substr(1,l.length-2):l}return su.parseTag=u,su.parseAttr=r,su}var Do,Ss;function u2(){if(Ss)return Do;Ss=1;var e=So().FilterCSS,t=Cs(),n=_s(),u=n.parseTag,o=n.parseAttr,r=Fo();function a(l){return l==null}function s(l){var p=r.spaceIndex(l);if(p===-1)return{html:"",closing:l[l.length-2]==="/"};l=r.trim(l.slice(p+1,-1));var m=l[l.length-1]==="/";return m&&(l=r.trim(l.slice(0,-1))),{html:l,closing:m}}function c(l){var p={};for(var m in l)p[m]=l[m];return p}function d(l){var p={};for(var m in l)Array.isArray(l[m])?p[m.toLowerCase()]=l[m].map(function(h){return h.toLowerCase()}):p[m.toLowerCase()]=l[m];return p}function f(l){l=c(l||{}),l.stripIgnoreTag&&(l.onIgnoreTag&&console.error('Notes: cannot use these two options "stripIgnoreTag" and "onIgnoreTag" at the same time'),l.onIgnoreTag=t.onIgnoreTagStripAll),l.whiteList||l.allowList?l.whiteList=d(l.whiteList||l.allowList):l.whiteList=t.whiteList,this.attributeWrapSign=l.singleQuotedAttributeValue===!0?"'":t.attributeWrapSign,l.onTag=l.onTag||t.onTag,l.onTagAttr=l.onTagAttr||t.onTagAttr,l.onIgnoreTag=l.onIgnoreTag||t.onIgnoreTag,l.onIgnoreTagAttr=l.onIgnoreTagAttr||t.onIgnoreTagAttr,l.safeAttrValue=l.safeAttrValue||t.safeAttrValue,l.escapeHtml=l.escapeHtml||t.escapeHtml,this.options=l,l.css===!1?this.cssFilter=!1:(l.css=l.css||{},this.cssFilter=new e(l.css))}return f.prototype.process=function(l){if(l=l||"",l=l.toString(),!l)return"";var p=this,m=p.options,h=m.whiteList,x=m.onTag,y=m.onIgnoreTag,v=m.onTagAttr,g=m.onIgnoreTagAttr,b=m.safeAttrValue,w=m.escapeHtml,k=p.attributeWrapSign,S=p.cssFilter;m.stripBlankChar&&(l=t.stripBlankChar(l)),m.allowCommentTag||(l=t.stripCommentTag(l));var _=!1;m.stripIgnoreTagBody&&(_=t.StripTagBody(m.stripIgnoreTagBody,y),y=_.onIgnoreTag);var E=u(l,function(W,V,O,B,D){var j={sourcePosition:W,position:V,isClosing:D,isWhite:Object.prototype.hasOwnProperty.call(h,O)},H=x(O,B,j);if(!a(H))return H;if(j.isWhite){if(j.isClosing)return"</"+O+">";var F=s(B),R=h[O],I=o(F.html,function(U,re){var te=r.indexOf(R,U)!==-1,P=v(O,U,re,te);return a(P)?te?(re=b(O,U,re,S),re?U+"="+k+re+k:U):(P=g(O,U,re,te),a(P)?void 0:P):P});return B="<"+O,I&&(B+=" "+I),F.closing&&(B+=" /"),B+=">",B}else return H=y(O,B,j),a(H)?w(B):H},w);return _&&(E=_.remove(E)),E},Do=f,Do}var Fs;function o2(){return Fs||(Fs=1,function(e,t){var n=Cs(),u=_s(),o=u2();function r(s,c){var d=new o(c);return d.process(s)}t=e.exports=r,t.filterXSS=r,t.FilterXSS=o,function(){for(var s in n)t[s]=n[s];for(var c in u)t[c]=u[c]}(),typeof window<"u"&&(window.filterXSS=e.exports);function a(){return typeof self<"u"&&typeof DedicatedWorkerGlobalScope<"u"&&self instanceof DedicatedWorkerGlobalScope}a()&&(self.filterXSS=e.exports)}(ko,ko.exports)),ko.exports}o2();const Qt=i.defineComponent({name:"FMarkdownPreview",props:Ga,setup(e){return()=>i.createVNode("div",{class:"f-markdown-preview-container"},[i.createVNode(au,{modelValue:e.content},null)])}});Qt.install=e=>{e.component(Qt.name,Qt)};const To="farris-x-preview-bridge",No=1,Lo="assistant.message";function Ds(e){try{return JSON.parse(JSON.stringify(e))}catch{return{...e,content:e.content}}}function Ts(e){return e!==null&&typeof e=="object"}function Ns(e){if(!Ts(e)||e.source!==To||e.v!==No||e.type!==Lo)return!1;const t=e.payload;return!(!Ts(t)||typeof t.messageId!="string"||t.messageId.length===0||t.role!=="user"&&t.role!=="assistant")}function i2(e,t){return!!(e.source===window.parent||t&&e.source===window.top||e.source===window)}function Ls(e,t,n){const u=Ds(n);try{return e.postMessage({source:To,v:No,type:Lo,payload:u},t),!0}catch{return!1}}function Is(e){const t=e.allowTopAsSource!==!1,n=u=>{var o;i2(u,t)&&(e.allowedParentOrigins&&e.allowedParentOrigins.length>0&&!e.allowedParentOrigins.includes(u.origin)||Ns(u.data)&&((o=e.onAssistantMessage)==null||o.call(e,u.data.payload)))};return window.addEventListener("message",n),()=>window.removeEventListener("message",n)}const a2="/platform/common/web/renderer/index.html#/preview",s2="Cases/ApplicationTemplates/Contacts/bo-contacts-front/metadata/components/Contacts.frm",c2="Cases/ApplicationTemplates/Contacts/bo-contacts-front/metadata/components",l2="67441dbb-0219-46f2-b247-51555c317995";function Os(e){if(e.url)return e.url;const t=e.baseUri??a2,n=e.metadataPath??s2,u=e.projectPath??c2,o=e.baseMetadataId??l2;return`${t}?metadataPath=${encodeURIComponent(n)}&projectPath=${encodeURIComponent(u)}&baseMetadataId=${encodeURIComponent(o)}`}function d2(e){if(typeof window>"u")return null;if(e.postMessageTargetOrigin)return e.postMessageTargetOrigin;try{const t=Os(e),n=new URL(t,window.location.href).origin;return n==="null"||n===""?window.location.origin:n}catch{return null}}const rr=i.defineComponent({name:"ChatPreview",props:Wa,setup(e,{expose:t}){const n=i.ref(null),u=i.ref(null),o=i.ref(!1),r=i.ref(!1),a=i.computed(()=>Os(e.previewConfig??{})),s=i.computed(()=>{var F;return((F=e.previewConfig)==null?void 0:F.contentType)==="markdown"}),c=i.computed(()=>{var F;return Object.keys(((F=e.previewConfig)==null?void 0:F.contentMap)??{})}),d=i.computed(()=>c.value.filter(F=>F).length>0),f=i.ref(),l=i.ref(),p=i.ref(!1);let m=null;i.onBeforeUnmount(()=>{m==null||m(),m=null,B()}),i.watch(()=>[a.value,n.value,s.value],()=>{if(m==null||m(),m=null,s.value)return;const F=n.value;if(!F)return;p.value=!1,o.value=!1,r.value=!1;const R=Date.now(),I=200,U=300,re=1e4;let te=!1,P=null,M=null;M=window.setTimeout(()=>{M=null,te||(r.value=!0)},I);const T=()=>{if(te)return;if(te=!0,P&&(window.clearTimeout(P),P=null),M&&(window.clearTimeout(M),M=null),p.value=!0,D(F),r.value){const K=Date.now()-R,Z=Math.max(0,U-K);setTimeout(()=>{o.value=!0},Z)}else o.value=!0;const $=()=>{var K;return(K=e.onIframeLoad)==null?void 0:K.call(e)};$(),window.setTimeout($,0),window.setTimeout($,120)},L=()=>{var $;te||(te=!0,M&&(window.clearTimeout(M),M=null),console.warn("ChatPreview: iframe load timeout"),p.value=!0,o.value=!0,($=e.onIframeLoad)==null||$.call(e))};F.addEventListener("load",T,{once:!0}),P=window.setTimeout(L,re),m=()=>{F.removeEventListener("load",T),P&&(window.clearTimeout(P),P=null),M&&(window.clearTimeout(M),M=null)}},{flush:"post"}),i.watch([s,()=>{var F;return(F=e.previewConfig)==null?void 0:F.contentMap}],()=>{B(),s.value&&i.nextTick(()=>O())},{flush:"post"}),i.watch(()=>{var F;return(F=e.previewConfig)==null?void 0:F.contentMap},F=>{if(F){const R=Object.keys(F);f.value=R[0]??""}else f.value="";h()},{immediate:!0});function h(F){var R,I;F&&(f.value=F),d.value&&f.value?l.value=((I=(R=e.previewConfig)==null?void 0:R.contentMap)==null?void 0:I[f.value])||"":l.value=""}function x(F){var U;if(s.value||!p.value)return!1;const R=(U=n.value)==null?void 0:U.contentWindow;if(!R)return!1;const I=d2(e.previewConfig??{});return I?Ls(R,I,F):!1}t({postAssistantPayload:x});const y=i.ref(!1);let v=null;const g=800;function b(){y.value=!0,V(!0),v!=null&&(window.clearTimeout(v),v=null)}function w(){v!=null&&window.clearTimeout(v),v=window.setTimeout(()=>{y.value=!1,V(!1),v=null},g)}function k(){b(),w()}function S(){b()}function _(){w()}let E=[];function W(){const F=u.value;if(!F)return[];const R=[],I=F.querySelectorAll(".f-markdown-preview-container");return I.length>0&&I.forEach(U=>R.push(U)),R.length===0&&F.scrollHeight>F.clientHeight&&R.push(F),R}function V(F){const R=u.value;R&&R.querySelectorAll(".f-markdown-preview-container").forEach(I=>{I.classList.toggle("f-chat-preview-scrollbar-visible",F)})}function O(){const F=W();E=F,F.forEach(R=>{R.addEventListener("scroll",k,{passive:!0}),R.addEventListener("mouseenter",S),R.addEventListener("mouseleave",_)})}function B(){E.forEach(F=>{F.removeEventListener("scroll",k),F.removeEventListener("mouseenter",S),F.removeEventListener("mouseleave",_)}),E=[]}function D(F){try{const R=F.contentDocument;if(!R)return;const I="f-chat-preview-injected-scrollbar-style";if(R.getElementById(I))return;const U=R.createElement("style");U.id=I,U.textContent=`
97
97
  html, body {
98
98
  scrollbar-width: thin;
99
99
  scrollbar-color: transparent transparent;
@@ -119,7 +119,7 @@ See: https://github.com/francoischalifour/medium-zoom`)}},s1=function(t){var n=d
119
119
  body.iframe-scrollbar-visible::-webkit-scrollbar-thumb {
120
120
  background: rgba(0, 0, 0, 0.2);
121
121
  }
122
- `,(V.head||V.documentElement).appendChild($);const re="f-chat-preview-injected-scrollbar-script";if(V.getElementById(re))return;const te=V.createElement("script");te.id=re,te.textContent=`
122
+ `,(R.head||R.documentElement).appendChild(U);const re="f-chat-preview-injected-scrollbar-script";if(R.getElementById(re))return;const te=R.createElement("script");te.id=re,te.textContent=`
123
123
  (function() {
124
124
  var hideTimer = null;
125
125
  var HIDE_DELAY = 800;
@@ -140,8 +140,8 @@ See: https://github.com/francoischalifour/medium-zoom`)}},s1=function(t){var n=d
140
140
  document.addEventListener('mouseenter', show);
141
141
  document.addEventListener('mouseleave', scheduleHide);
142
142
  })();
143
- `,(V.head||V.documentElement).appendChild(te)}catch{}}const j=()=>{var F;return i.createVNode("div",{class:"f-chat-preview-header"},[i.createVNode("div",{class:"f-chat-preview-header-left"},[i.createVNode("button",{class:"f-chat-preview-preview-btn"},[i.createVNode("i",{class:"f-icon f-icon-file-txt"},null),i.createVNode("span",{class:"f-chat-preview-preview-text"},[((F=e.previewConfig)==null?void 0:F.title)||"预览"])])]),i.createVNode("div",{class:"f-chat-preview-header-right"},[i.createVNode("button",{class:"f-chat-preview-tool-btn",title:"关闭预览","aria-label":"关闭预览",onClick:()=>{var V;return(V=e.onClose)==null?void 0:V.call(e)}},[i.createVNode("i",{class:"f-icon f-icon-close"},null)])])])},H=()=>{var F;return d.value?l.value?i.createVNode("div",{class:"d-flex"},[i.createVNode(xn,{class:"f-chat-content-main-layout",direction:"row"},{default:()=>[i.createVNode(er,{position:"center",resizable:!1,minWidth:100,class:"f-chat-content-main-left"},{default:()=>[i.createVNode("div",{class:"f-chat-preview-content-nav"},[i.createVNode("div",{class:"f-chat-preview-content-nav-title"},[i.createTextVNode("全部文件")]),i.createVNode("div",{class:"f-chat-preview-content-nav-content"},[c.value.map((V,O)=>i.createVNode("div",{key:O,class:["f-chat-preview-content-nav-item",V===f.value?"active-nav-item":""],title:V,onClick:()=>h(V)},[V]))])])]}),i.createVNode(er,{position:"right",resizable:!0,width:600,class:"f-chat-preview-pane-right"},{default:()=>[i.createVNode(Kt,{content:l.value},null)]})]})]):null:i.createVNode(Kt,{content:((F=e.previewConfig)==null?void 0:F.content)??""},null)};return()=>i.createVNode("div",{class:"f-chat-preview"},[j(),i.createVNode("div",{ref:u,class:"f-chat-preview-content",style:{overflow:s.value?"auto":"hidden"}},[s.value?H():i.createVNode(i.Fragment,null,[i.withDirectives(i.createVNode("div",{class:["f-chat-preview-skeleton",{"f-chat-preview-skeleton--fade-out":o.value}]},[i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"60%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"80%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"45%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"70%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"55%"}},null)]),[[i.vShow,r.value]]),i.createVNode("iframe",{ref:n,name:"preview-iframe",title:"preview-iframe",src:a.value,class:["f-chat-preview-iframe",{"f-chat-preview-iframe--visible":o.value}]},null)])])])}});function c2(e){return Po.subscribe(e)}rr.install=e=>{e.component(rr.name,rr)};const Vs={modelValue:{type:Boolean,default:!1},title:{type:[String,Object],default:"标题"},description:{type:[String,Object],default:""},cancelText:{type:String,default:"取消"},confirmText:{type:String,default:"确认"},closeOnMask:{type:Boolean,default:!1},showDivider:{type:Boolean,default:!0}},ur=i.defineComponent({name:"FXConfirmDialog",props:Vs,emits:{"update:modelValue":e=>!0,cancel:()=>!0,confirm:()=>!0},setup(e,{emit:t,slots:n}){function u(){t("update:modelValue",!1)}function o(){t("cancel"),u()}function r(){t("confirm"),u()}function a(s){e.closeOnMask&&s.target===s.currentTarget&&o()}return()=>e.modelValue?i.createVNode(i.Teleport,{to:"body"},{default:()=>[i.createVNode("div",{class:"f-chat-confirm-dialog-mask",onClick:a},[i.createVNode("div",{class:"f-chat-confirm-dialog"},[i.createVNode("div",{class:"f-chat-confirm-dialog-title"},[n.title?n.title():e.title]),i.createVNode("div",{class:"f-chat-confirm-dialog-description"},[n.default?n.default():e.description]),i.createVNode("div",{class:["f-chat-confirm-dialog-actions",{"with-divider":e.showDivider}]},[i.createVNode("button",{type:"button",class:"f-chat-confirm-dialog-btn f-chat-confirm-dialog-btn-cancel",onClick:o},[e.cancelText]),i.createVNode("button",{type:"button",class:"f-chat-confirm-dialog-btn f-chat-confirm-dialog-btn-confirm",onClick:r},[e.confirmText])])])])]}):null}});ur.install=e=>{e.component(ur.name,ur)};function Ms(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,u=Array(t);n<t;n++)u[n]=e[n];return u}function l2(e){if(Array.isArray(e))return e}function d2(e,t,n){return(t=y2(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function f2(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var u,o,r,a,s=[],c=!0,d=!1;try{if(r=(n=n.call(e)).next,t!==0)for(;!(c=(u=r.call(n)).done)&&(s.push(u.value),s.length!==t);c=!0);}catch(f){d=!0,o=f}finally{try{if(!c&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(d)throw o}}return s}}function h2(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
144
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Bs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);t&&(u=u.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,u)}return n}function zs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Bs(Object(n),!0).forEach(function(u){d2(e,u,n[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bs(Object(n)).forEach(function(u){Object.defineProperty(e,u,Object.getOwnPropertyDescriptor(n,u))})}return e}function p2(e,t){if(e==null)return{};var n,u,o=m2(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(u=0;u<r.length;u++)n=r[u],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function m2(e,t){if(e==null)return{};var n={};for(var u in e)if({}.hasOwnProperty.call(e,u)){if(t.indexOf(u)!==-1)continue;n[u]=e[u]}return n}function g2(e,t){return l2(e)||f2(e,t)||x2(e,t)||h2()}function b2(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var u=n.call(e,t);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function y2(e){var t=b2(e,"string");return typeof t=="symbol"?t:t+""}function x2(e,t){if(e){if(typeof e=="string")return Ms(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ms(e,t):void 0}}function w2(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function js(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);t&&(u=u.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,u)}return n}function Hs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?js(Object(n),!0).forEach(function(u){w2(e,u,n[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):js(Object(n)).forEach(function(u){Object.defineProperty(e,u,Object.getOwnPropertyDescriptor(n,u))})}return e}function v2(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(u){return t.reduceRight(function(o,r){return r(o)},u)}}function or(e){return function t(){for(var n=this,u=arguments.length,o=new Array(u),r=0;r<u;r++)o[r]=arguments[r];return o.length>=e.length?e.apply(this,o):function(){for(var a=arguments.length,s=new Array(a),c=0;c<a;c++)s[c]=arguments[c];return t.apply(n,[].concat(o,s))}}}function lu(e){return{}.toString.call(e).includes("Object")}function A2(e){return!Object.keys(e).length}function ir(e){return typeof e=="function"}function k2(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function C2(e,t){return lu(t)||Bt("changeType"),Object.keys(t).some(function(n){return!k2(e,n)})&&Bt("changeField"),t}function E2(e){ir(e)||Bt("selectorType")}function _2(e){ir(e)||lu(e)||Bt("handlerType"),lu(e)&&Object.values(e).some(function(t){return!ir(t)})&&Bt("handlersType")}function S2(e){e||Bt("initialIsRequired"),lu(e)||Bt("initialType"),A2(e)&&Bt("initialContent")}function F2(e,t){throw new Error(e[t]||e.default)}var D2={initialIsRequired:"initial state is required",initialType:"initial state should be an object",initialContent:"initial state shouldn't be an empty object",handlerType:"handler should be an object or a function",handlersType:"all handlers should be a functions",selectorType:"selector should be a function",changeType:"provided value of changes should be an object",changeField:'it seams you want to change a field in the state which is not specified in the "initial" state',default:"an unknown error accured in `state-local` package"},Bt=or(F2)(D2),du={changes:C2,selector:E2,handler:_2,initial:S2};function T2(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};du.initial(e),du.handler(t);var n={current:e},u=or(O2)(n,t),o=or(L2)(n),r=or(du.changes)(e),a=or(N2)(n);function s(){var d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(f){return f};return du.selector(d),d(n.current)}function c(d){v2(u,o,r,a)(d)}return[s,c]}function N2(e,t){return ir(t)?t(e.current):t}function L2(e,t){return e.current=Hs(Hs({},e.current),t),t}function O2(e,t,n){return ir(t)?t(e.current):Object.keys(n).forEach(function(u){var o;return(o=t[u])===null||o===void 0?void 0:o.call(t,e.current[u])}),n}var I2={create:T2},P2={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.55.1/min/vs"}};function R2(e){return function t(){for(var n=this,u=arguments.length,o=new Array(u),r=0;r<u;r++)o[r]=arguments[r];return o.length>=e.length?e.apply(this,o):function(){for(var a=arguments.length,s=new Array(a),c=0;c<a;c++)s[c]=arguments[c];return t.apply(n,[].concat(o,s))}}}function V2(e){return{}.toString.call(e).includes("Object")}function M2(e){return e||Us("configIsRequired"),V2(e)||Us("configType"),e.urls?(B2(),{paths:{vs:e.urls.monacoBase}}):e}function B2(){console.warn($s.deprecation)}function z2(e,t){throw new Error(e[t]||e.default)}var $s={configIsRequired:"the configuration object is required",configType:"the configuration object should be an object",default:"an unknown error accured in `@monaco-editor/loader` package",deprecation:`Deprecation warning!
143
+ `,(R.head||R.documentElement).appendChild(te)}catch{}}const j=()=>{var F;return i.createVNode("div",{class:"f-chat-preview-header"},[i.createVNode("div",{class:"f-chat-preview-header-left"},[i.createVNode("button",{class:"f-chat-preview-preview-btn"},[i.createVNode("i",{class:"fx-icon fx-icon-card_info"},null),i.createVNode("span",{class:"f-chat-preview-preview-text"},[((F=e.previewConfig)==null?void 0:F.title)||"预览"])])]),i.createVNode("div",{class:"f-chat-preview-header-right"},[i.createVNode("button",{class:"f-chat-preview-tool-btn",title:"关闭预览","aria-label":"关闭预览",onClick:()=>{var R;return(R=e.onClose)==null?void 0:R.call(e)}},[i.createVNode("i",{class:"fx-icon fx-icon-sidewindow_close"},null)])])])},H=()=>{var F;return d.value?l.value?i.createVNode("div",{class:"d-flex"},[i.createVNode(yn,{class:"f-chat-content-main-layout",direction:"row"},{default:()=>[i.createVNode(tr,{position:"center",resizable:!1,minWidth:100,class:"f-chat-content-main-left"},{default:()=>[i.createVNode("div",{class:"f-chat-preview-content-nav"},[i.createVNode("div",{class:"f-chat-preview-content-nav-title"},[i.createTextVNode("全部文件")]),i.createVNode("div",{class:"f-chat-preview-content-nav-content"},[c.value.map((R,I)=>i.createVNode("div",{key:I,class:["f-chat-preview-content-nav-item",R===f.value?"active-nav-item":""],title:R,onClick:()=>h(R)},[R]))])])]}),i.createVNode(tr,{position:"right",resizable:!0,width:600,class:"f-chat-preview-pane-right"},{default:()=>[i.createVNode(Qt,{content:l.value},null)]})]})]):null:i.createVNode(Qt,{content:((F=e.previewConfig)==null?void 0:F.content)??""},null)};return()=>i.createVNode("div",{class:"f-chat-preview"},[j(),i.createVNode("div",{ref:u,class:"f-chat-preview-content",style:{overflow:s.value?"auto":"hidden"}},[s.value?H():i.createVNode(i.Fragment,null,[i.withDirectives(i.createVNode("div",{class:["f-chat-preview-skeleton",{"f-chat-preview-skeleton--fade-out":o.value}]},[i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"60%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"80%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"45%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"70%"}},null),i.createVNode("div",{class:"f-chat-preview-skeleton-line",style:{width:"55%"}},null)]),[[i.vShow,r.value]]),i.createVNode("iframe",{ref:n,name:"preview-iframe",title:"preview-iframe",src:a.value,class:["f-chat-preview-iframe",{"f-chat-preview-iframe--visible":o.value}]},null)])])])}});function Io(e,t){const n=typeof window<"u"?window.AgentWorkbenchSDK:void 0;if(!n){console.warn("[AgentWorkbenchSDK] invoke: window.AgentWorkbenchSDK is not available");return}try{const u=n[e];if(typeof u!="function"){console.warn("[AgentWorkbenchSDK] invoke: not a function:",e);return}return u(...t??[])}catch(u){console.warn("[AgentWorkbenchSDK] invoke error:",e,u);return}}function f2(e){return Is(e)}rr.install=e=>{e.component(rr.name,rr)};const Ps={modelValue:{type:Boolean,default:!1},title:{type:[String,Object],default:"标题"},description:{type:[String,Object],default:""},cancelText:{type:String,default:"取消"},confirmText:{type:String,default:"确认"},closeOnMask:{type:Boolean,default:!1},showDivider:{type:Boolean,default:!0}},ur=i.defineComponent({name:"FXConfirmDialog",props:Ps,emits:{"update:modelValue":e=>!0,cancel:()=>!0,confirm:()=>!0},setup(e,{emit:t,slots:n}){function u(){t("update:modelValue",!1)}function o(){t("cancel"),u()}function r(){t("confirm"),u()}function a(s){e.closeOnMask&&s.target===s.currentTarget&&o()}return()=>e.modelValue?i.createVNode(i.Teleport,{to:"body"},{default:()=>[i.createVNode("div",{class:"f-chat-confirm-dialog-mask",onClick:a},[i.createVNode("div",{class:"f-chat-confirm-dialog"},[i.createVNode("div",{class:"f-chat-confirm-dialog-title"},[n.title?n.title():e.title]),i.createVNode("div",{class:"f-chat-confirm-dialog-description"},[n.default?n.default():e.description]),i.createVNode("div",{class:["f-chat-confirm-dialog-actions",{"with-divider":e.showDivider}]},[i.createVNode("button",{type:"button",class:"f-chat-confirm-dialog-btn f-chat-confirm-dialog-btn-cancel",onClick:o},[e.cancelText]),i.createVNode("button",{type:"button",class:"f-chat-confirm-dialog-btn f-chat-confirm-dialog-btn-confirm",onClick:r},[e.confirmText])])])])]}):null}});ur.install=e=>{e.component(ur.name,ur)};function Rs(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,u=Array(t);n<t;n++)u[n]=e[n];return u}function h2(e){if(Array.isArray(e))return e}function p2(e,t,n){return(t=v2(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function m2(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var u,o,r,a,s=[],c=!0,d=!1;try{if(r=(n=n.call(e)).next,t!==0)for(;!(c=(u=r.call(n)).done)&&(s.push(u.value),s.length!==t);c=!0);}catch(f){d=!0,o=f}finally{try{if(!c&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(d)throw o}}return s}}function g2(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
144
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ms(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);t&&(u=u.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,u)}return n}function Vs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ms(Object(n),!0).forEach(function(u){p2(e,u,n[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ms(Object(n)).forEach(function(u){Object.defineProperty(e,u,Object.getOwnPropertyDescriptor(n,u))})}return e}function b2(e,t){if(e==null)return{};var n,u,o=y2(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(u=0;u<r.length;u++)n=r[u],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function y2(e,t){if(e==null)return{};var n={};for(var u in e)if({}.hasOwnProperty.call(e,u)){if(t.indexOf(u)!==-1)continue;n[u]=e[u]}return n}function x2(e,t){return h2(e)||m2(e,t)||A2(e,t)||g2()}function w2(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var u=n.call(e,t);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function v2(e){var t=w2(e,"string");return typeof t=="symbol"?t:t+""}function A2(e,t){if(e){if(typeof e=="string")return Rs(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Rs(e,t):void 0}}function k2(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Bs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(e);t&&(u=u.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,u)}return n}function zs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Bs(Object(n),!0).forEach(function(u){k2(e,u,n[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bs(Object(n)).forEach(function(u){Object.defineProperty(e,u,Object.getOwnPropertyDescriptor(n,u))})}return e}function C2(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(u){return t.reduceRight(function(o,r){return r(o)},u)}}function or(e){return function t(){for(var n=this,u=arguments.length,o=new Array(u),r=0;r<u;r++)o[r]=arguments[r];return o.length>=e.length?e.apply(this,o):function(){for(var a=arguments.length,s=new Array(a),c=0;c<a;c++)s[c]=arguments[c];return t.apply(n,[].concat(o,s))}}}function cu(e){return{}.toString.call(e).includes("Object")}function E2(e){return!Object.keys(e).length}function ir(e){return typeof e=="function"}function _2(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function S2(e,t){return cu(t)||zt("changeType"),Object.keys(t).some(function(n){return!_2(e,n)})&&zt("changeField"),t}function F2(e){ir(e)||zt("selectorType")}function D2(e){ir(e)||cu(e)||zt("handlerType"),cu(e)&&Object.values(e).some(function(t){return!ir(t)})&&zt("handlersType")}function T2(e){e||zt("initialIsRequired"),cu(e)||zt("initialType"),E2(e)&&zt("initialContent")}function N2(e,t){throw new Error(e[t]||e.default)}var L2={initialIsRequired:"initial state is required",initialType:"initial state should be an object",initialContent:"initial state shouldn't be an empty object",handlerType:"handler should be an object or a function",handlersType:"all handlers should be a functions",selectorType:"selector should be a function",changeType:"provided value of changes should be an object",changeField:'it seams you want to change a field in the state which is not specified in the "initial" state',default:"an unknown error accured in `state-local` package"},zt=or(N2)(L2),lu={changes:S2,selector:F2,handler:D2,initial:T2};function I2(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};lu.initial(e),lu.handler(t);var n={current:e},u=or(R2)(n,t),o=or(P2)(n),r=or(lu.changes)(e),a=or(O2)(n);function s(){var d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(f){return f};return lu.selector(d),d(n.current)}function c(d){C2(u,o,r,a)(d)}return[s,c]}function O2(e,t){return ir(t)?t(e.current):t}function P2(e,t){return e.current=zs(zs({},e.current),t),t}function R2(e,t,n){return ir(t)?t(e.current):Object.keys(n).forEach(function(u){var o;return(o=t[u])===null||o===void 0?void 0:o.call(t,e.current[u])}),n}var M2={create:I2},V2={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.55.1/min/vs"}};function B2(e){return function t(){for(var n=this,u=arguments.length,o=new Array(u),r=0;r<u;r++)o[r]=arguments[r];return o.length>=e.length?e.apply(this,o):function(){for(var a=arguments.length,s=new Array(a),c=0;c<a;c++)s[c]=arguments[c];return t.apply(n,[].concat(o,s))}}}function z2(e){return{}.toString.call(e).includes("Object")}function j2(e){return e||Hs("configIsRequired"),z2(e)||Hs("configType"),e.urls?(H2(),{paths:{vs:e.urls.monacoBase}}):e}function H2(){console.warn(js.deprecation)}function U2(e,t){throw new Error(e[t]||e.default)}var js={configIsRequired:"the configuration object is required",configType:"the configuration object should be an object",default:"an unknown error accured in `@monaco-editor/loader` package",deprecation:`Deprecation warning!
145
145
  You are using deprecated way of configuration.
146
146
 
147
147
  Instead of using
@@ -150,6 +150,6 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
150
150
  monaco.config({ paths: { vs: '...' } })
151
151
 
152
152
  For more please check the link https://github.com/suren-atoyan/monaco-loader#config
153
- `},Us=R2(z2)($s),j2={config:M2},H2=function(){for(var t=arguments.length,n=new Array(t),u=0;u<t;u++)n[u]=arguments[u];return function(o){return n.reduceRight(function(r,a){return a(r)},o)}};function Ws(e,t){return Object.keys(t).forEach(function(n){t[n]instanceof Object&&e[n]&&Object.assign(t[n],Ws(e[n],t[n]))}),zs(zs({},e),t)}var $2={type:"cancelation",msg:"operation is manually canceled"};function Vo(e){var t=!1,n=new Promise(function(u,o){e.then(function(r){return t?o($2):u(r)}),e.catch(o)});return n.cancel=function(){return t=!0},n}var U2=["monaco"],W2=I2.create({config:P2,isInitialized:!1,resolve:null,reject:null,monaco:null}),Gs=g2(W2,2),ar=Gs[0],fu=Gs[1];function G2(e){var t=j2.config(e),n=t.monaco,u=p2(t,U2);fu(function(o){return{config:Ws(o.config,u),monaco:n}})}function q2(){var e=ar(function(t){var n=t.monaco,u=t.isInitialized,o=t.resolve;return{monaco:n,isInitialized:u,resolve:o}});if(!e.isInitialized){if(fu({isInitialized:!0}),e.monaco)return e.resolve(e.monaco),Vo(Mo);if(window.monaco&&window.monaco.editor)return qs(window.monaco),e.resolve(window.monaco),Vo(Mo);H2(X2,Y2)(K2)}return Vo(Mo)}function X2(e){return document.body.appendChild(e)}function Z2(e){var t=document.createElement("script");return e&&(t.src=e),t}function Y2(e){var t=ar(function(u){var o=u.config,r=u.reject;return{config:o,reject:r}}),n=Z2("".concat(t.config.paths.vs,"/loader.js"));return n.onload=function(){return e()},n.onerror=t.reject,n}function K2(){var e=ar(function(n){var u=n.config,o=n.resolve,r=n.reject;return{config:u,resolve:o,reject:r}}),t=window.require;t.config(e.config),t(["vs/editor/editor.main"],function(n){var u=n.m||n;qs(u),e.resolve(u)},function(n){e.reject(n)})}function qs(e){ar().monaco||fu({monaco:e})}function Q2(){return ar(function(e){var t=e.monaco;return t})}var Mo=new Promise(function(e,t){return fu({resolve:e,reject:t})}),J2={config:G2,init:q2,__getMonacoInstance:Q2};const Xs={content:{type:Object,required:!0}},Zs=20,ep=16,vn=180;function tp(e){typeof requestIdleCallback<"u"?requestIdleCallback(e,{timeout:500}):setTimeout(e,0)}const sr=i.defineComponent({name:"FXCodingMessage",props:Xs,setup(e){const t=i.ref(!0),n=i.ref(!1),u=i.ref(null),o=i.ref(null),r=i.ref(vn),a=i.ref(!1);function s(){t.value=!t.value}function c(){var g,b,w,k;const h=(g=e.content)==null?void 0:g.code;if(!h)return vn;const x=o.value;let v;if(x!=null&&x.getOriginalEditor&&(x!=null&&x.getModifiedEditor)){const S=((b=x.getOriginalEditor().getModel())==null?void 0:b.getLineCount())??0,_=((w=x.getModifiedEditor().getModel())==null?void 0:w.getLineCount())??0;v=S+_}else if(x!=null&&x.getModel)v=((k=x.getModel())==null?void 0:k.getLineCount())??0;else{const{value:S,originalValue:_}=h,E=(S||"").split(`
153
+ `},Hs=B2(U2)(js),$2={config:j2},W2=function(){for(var t=arguments.length,n=new Array(t),u=0;u<t;u++)n[u]=arguments[u];return function(o){return n.reduceRight(function(r,a){return a(r)},o)}};function Us(e,t){return Object.keys(t).forEach(function(n){t[n]instanceof Object&&e[n]&&Object.assign(t[n],Us(e[n],t[n]))}),Vs(Vs({},e),t)}var G2={type:"cancelation",msg:"operation is manually canceled"};function Oo(e){var t=!1,n=new Promise(function(u,o){e.then(function(r){return t?o(G2):u(r)}),e.catch(o)});return n.cancel=function(){return t=!0},n}var q2=["monaco"],X2=M2.create({config:V2,isInitialized:!1,resolve:null,reject:null,monaco:null}),$s=x2(X2,2),ar=$s[0],du=$s[1];function Z2(e){var t=$2.config(e),n=t.monaco,u=b2(t,q2);du(function(o){return{config:Us(o.config,u),monaco:n}})}function Y2(){var e=ar(function(t){var n=t.monaco,u=t.isInitialized,o=t.resolve;return{monaco:n,isInitialized:u,resolve:o}});if(!e.isInitialized){if(du({isInitialized:!0}),e.monaco)return e.resolve(e.monaco),Oo(Po);if(window.monaco&&window.monaco.editor)return Ws(window.monaco),e.resolve(window.monaco),Oo(Po);W2(K2,J2)(ep)}return Oo(Po)}function K2(e){return document.body.appendChild(e)}function Q2(e){var t=document.createElement("script");return e&&(t.src=e),t}function J2(e){var t=ar(function(u){var o=u.config,r=u.reject;return{config:o,reject:r}}),n=Q2("".concat(t.config.paths.vs,"/loader.js"));return n.onload=function(){return e()},n.onerror=t.reject,n}function ep(){var e=ar(function(n){var u=n.config,o=n.resolve,r=n.reject;return{config:u,resolve:o,reject:r}}),t=window.require;t.config(e.config),t(["vs/editor/editor.main"],function(n){var u=n.m||n;Ws(u),e.resolve(u)},function(n){e.reject(n)})}function Ws(e){ar().monaco||du({monaco:e})}function tp(){return ar(function(e){var t=e.monaco;return t})}var Po=new Promise(function(e,t){return du({resolve:e,reject:t})}),np={config:Z2,init:Y2,__getMonacoInstance:tp};const Gs={content:{type:Object,required:!0}},qs=20,rp=16,wn=180;function up(e){typeof requestIdleCallback<"u"?requestIdleCallback(e,{timeout:500}):setTimeout(e,0)}const sr=i.defineComponent({name:"FXCodingMessage",props:Gs,setup(e){const t=i.ref(!0),n=i.ref(!1),u=i.ref(null),o=i.ref(null),r=i.ref(wn),a=i.ref(!1);function s(){t.value=!t.value}function c(){var g,b,w,k;const h=(g=e.content)==null?void 0:g.code;if(!h)return wn;const y=o.value;let v;if(y!=null&&y.getOriginalEditor&&(y!=null&&y.getModifiedEditor)){const S=((b=y.getOriginalEditor().getModel())==null?void 0:b.getLineCount())??0,_=((w=y.getModifiedEditor().getModel())==null?void 0:w.getLineCount())??0;v=S+_}else if(y!=null&&y.getModel)v=((k=y.getModel())==null?void 0:k.getLineCount())??0;else{const{value:S,originalValue:_}=h,E=(S||"").split(`
154
154
  `).length,W=_?_.split(`
155
- `).length:0;v=_?W+E:E}return ep+v*Zs}const d=i.computed(()=>(o.value,c()>vn));function f(){n.value=!n.value,r.value=n.value?c():vn,p()}function l(){if(!o.value)return;o.value=null;const y=()=>{};typeof requestIdleCallback<"u"?requestIdleCallback(y,{timeout:100}):setTimeout(y,0)}function p(){if(a.value)return;const h=u.value,y=o.value;if(!h||!(y!=null&&y.layout))return;const x=h.clientWidth||h.offsetWidth,v=r.value;requestAnimationFrame(()=>{var g,b;a.value||!o.value||(b=(g=o.value)==null?void 0:g.layout)==null||b.call(g,{width:x,height:v})})}function m(){var h;a.value||!u.value||!((h=e.content)!=null&&h.code)||J2.init().then(y=>{var w;if(a.value||!u.value||!((w=e.content)!=null&&w.code))return;const{value:x,originalValue:v,language:g="typescript"}=e.content.code,b={readOnly:!0,minimap:{enabled:!1},scrollBeyondLastLine:!1,lineNumbers:"off",glyphMargin:!1,lineDecorationsWidth:0,folding:!1,renderLineHighlight:"none",fontSize:12,lineHeight:Zs,padding:{top:8,bottom:8}};if(v){const k=y.editor.createDiffEditor(u.value,{...b,renderSideBySide:!1,renderOverviewRuler:!1});k.setModel({original:y.editor.createModel(v,g),modified:y.editor.createModel(x,g)}),k.getOriginalEditor().updateOptions({minimap:{enabled:!1}}),k.getModifiedEditor().updateOptions({minimap:{enabled:!1}}),i.nextTick(()=>{var _;if(a.value)return;const S=(_=k.getContainerDomNode)==null?void 0:_.call(k);if(S){const E=S.querySelector('.diff-editor-cell.original, [class*="original"]');E&&(E.style.display="none")}}),o.value=k}else{const k=y.editor.create(u.value,{value:x,language:g,...b});o.value=k}r.value=vn,i.nextTick(()=>p())})}return i.onMounted(()=>{tp(()=>{a.value||!u.value||m()})}),i.watch(t,h=>{h&&!a.value&&i.nextTick(()=>p())}),i.onBeforeUnmount(()=>{a.value=!0,l()}),i.watch(()=>{var h,y;return(y=(h=e.content)==null?void 0:h.code)==null?void 0:y.value},()=>{a.value||(n.value?r.value=c():r.value=vn,p())}),()=>{const h=e.content;if(!h)return null;const{message:y,fileIcon:x,fileName:v,code:g}=h;return i.createVNode("div",{class:"f-chat-message-coding"},[i.createVNode("div",{class:"f-chat-coding-message"},[y]),i.createVNode("div",{class:"f-chat-coding-card"},[i.createVNode("div",{class:"f-chat-coding-header",onClick:s,role:"button",tabindex:0,onKeydown:b=>b.key==="Enter"&&s()},[i.createVNode("span",{class:"f-chat-coding-header-icon-slot"},[i.createVNode("span",{class:"f-chat-coding-header-icon"},[i.createVNode("img",{src:x,alt:"",onError:b=>{var w;b.target.style.display="none",(w=b.target.parentElement)==null||w.classList.add("icon-error")}},null),i.createVNode("span",{class:"f-chat-coding-header-icon-fallback"},[i.createTextVNode("📄")])]),i.createVNode("span",{class:"f-chat-coding-header-expand"},[i.createVNode("i",{class:t.value?"f-icon f-icon-arrow-chevron-down":"f-icon f-icon-arrow-chevron-right"},null)])]),i.createVNode("span",{class:"f-chat-coding-header-filename"},[v]),i.createVNode("span",{class:"f-chat-coding-header-stats"},[i.createVNode("span",{class:"f-chat-coding-stat-add"},[i.createTextVNode("+"),g.addedLines]),i.createVNode("span",{class:"f-chat-coding-stat-del"},[i.createTextVNode("-"),g.deletedLines])])]),i.createVNode("div",{style:{display:t.value?"block":"none"}},[i.createVNode("div",{ref:u,class:"f-chat-coding-editor",style:{height:`${r.value}px`}},null),d.value&&i.createVNode("button",{type:"button",class:"f-chat-coding-expand-btn",onClick:f,"aria-label":n.value?"收起代码":"展开代码",title:n.value?"收起代码":"展开代码"},[i.createVNode("i",{class:["f-icon f-icon-arrow-chevron-down",n.value&&"f-chat-coding-expand-icon-up"]},null)])])])])}}});sr.install=e=>{e.component(sr.name,sr)};const Ys={content:{type:Object,required:!0}};function np(e){return"file"in e&&"path"in e}const cr=i.defineComponent({name:"FileOperationMessage",props:Ys,setup(e){const t=i.ref(!0),n=i.ref({}),u=i.computed(()=>{var c;return!!((c=e.content)!=null&&c.summary)}),o=i.computed(()=>{var d;const c=(d=e.content)==null?void 0:d.summary;return c?`浏览了 ${c.explored} 个文件并查询了 ${c.searched} 个文件`:""});function r(){t.value=!t.value}function a(c){n.value={...n.value,[c]:!n.value[c]}}function s(c){return n.value[c]??!1}return()=>{const c=e.content;if(!c)return null;const{summary:d,operations:f}=c,l=!u.value||t.value;return i.createVNode("div",{class:"f-chat-message-file-operation"},[d&&i.createVNode("div",{class:"f-chat-file-op-summary",onClick:r,role:"button",tabindex:0,onKeydown:p=>p.key==="Enter"&&r()},[i.createVNode("span",{class:"f-chat-file-op-summary-inner"},[i.createVNode("span",{class:"f-chat-file-op-summary-text"},[o.value]),i.createVNode("span",{class:["f-chat-file-op-expand-btn",{expanded:t.value}]},[i.createVNode("i",{class:t.value?"f-icon f-icon-arrow-chevron-down":"f-icon f-icon-arrow-chevron-right"},null)])])]),l&&i.createVNode("div",{class:"f-chat-file-op-operations"},[f.map((p,m)=>{var h,y,x,v;return i.createVNode("div",{key:m,class:"f-chat-file-op-operation"},[i.createVNode("div",i.mergeProps({class:["f-chat-file-op-operation-row",{"op-read":p.type==="Read","has-details":!!((h=p.details)!=null&&h.length)}],onClick:()=>{var g;return((g=p.details)==null?void 0:g.length)&&a(m)}},(y=p.details)!=null&&y.length?{role:"button",tabIndex:0}:{},{onKeydown:g=>{var b;return((b=p.details)==null?void 0:b.length)&&g.key==="Enter"&&a(m)}}),[i.createVNode("span",{class:"f-chat-file-op-type"},[p.type]),i.createVNode("span",{class:"f-chat-file-op-message-wrap"},[i.createVNode("span",{class:"f-chat-file-op-message"},[p.message]),(x=p.details)!=null&&x.length?i.createVNode("span",{class:["f-chat-file-op-expand-btn","sm",{expanded:s(m)}]},[i.createVNode("i",{class:s(m)?"f-icon f-icon-arrow-chevron-down":"f-icon f-icon-arrow-chevron-right"},null)]):null])]),((v=p.details)==null?void 0:v.length)&&s(m)&&i.createVNode("div",{class:"f-chat-file-op-details"},[p.details.map((g,b)=>np(g)?i.createVNode("div",{key:b,class:"f-chat-file-op-detail-file"},[i.createVNode("span",{class:"f-chat-file-op-file-icon"},[i.createVNode("img",{src:g.icon,alt:"",onError:w=>{const k=w.target;k.style.display="none";const S=k.parentElement;S&&S.classList.add("icon-error")}},null),i.createVNode("span",{class:"f-chat-file-op-file-icon-fallback"},[i.createTextVNode("📄")])]),i.createVNode("span",{class:"f-chat-file-op-file-name"},[g.file]),i.createVNode("span",{class:"f-chat-file-op-file-path",title:g.path},[g.path])]):i.createVNode("div",{key:b,class:"f-chat-file-op-detail-text"},[i.createVNode("div",{class:"f-chat-file-op-detail-title"},[g.title]),i.createVNode("div",{class:"f-chat-file-op-detail-content"},[g.text])]))])])})])])}}});cr.install=e=>{e.component(cr.name,cr)};const Ks={visible:{type:Boolean,default:!0},description:[String,Object],progress:{type:Number,default:0},showProgress:{type:Boolean,default:!0},icon:{type:[String,Object],default:""},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})}},rp="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='60px'%20height='60px'%20viewBox='0%200%2060%2060'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3ctitle%3e智能logo60px%3c/title%3e%3cdefs%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-1'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%231EBBC6'%20offset='58.0673923%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cpath%20d='M25.1971977,0%20L45.8523137,11.3712178%20L45.8523137,37.6155801%20L44.4946453,38.9692599%20L24.623,28.022%20L24.6233274,49.9395377%20L21.4535582,49.9395377%20L2.72549351,39.5965647%20L0,34.4406135%20L0,12.8076673%20L3.70534859,10.5019677%20L20.556,20.546%20L20.5567534,0.161454345%20L25.1971977,0%20Z%20M20.7578212,28.1498874%20L5.81325199,36.7628182%20L20.7578212,45.0027895%20L20.7578212,28.1498874%20Z%20M41.8027832,15.9256338%20L26.7716137,24.6706076%20L41.8027832,32.9879669%20L41.8027832,15.9256338%20Z%20M4.06159924,15.4742393%20L4.06159924,32.9879669%20L19.1488772,24.4568004%20L4.06159924,15.4742393%20Z%20M24.6233274,4.32908173%20L24.6233274,21.2862528%20L39.8727429,12.4882393%20L24.6233274,4.32908173%20Z'%20id='path-2'%3e%3c/path%3e%3clinearGradient%20x1='81.0966666%25'%20y1='38.5584607%25'%20x2='28.8545509%25'%20y2='61.9626707%25'%20id='linearGradient-4'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-5'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='44.8152906%25'%20y1='77.6521765%25'%20x2='44.8152906%25'%20y2='3.26462903%25'%20id='linearGradient-6'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-7'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='3.93796935%25'%20y1='32.607826%25'%20x2='78.9687461%25'%20y2='60.0462823%25'%20id='linearGradient-8'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-9'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='56.0769337%25'%20y1='45.0797149%25'%20x2='24.9463054%25'%20y2='71.1433818%25'%20id='linearGradient-10'%3e%3cstop%20stop-color='%23159BD7'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='10.434388%25'%20y1='68.063656%25'%20x2='86.6988821%25'%20y2='30.8651063%25'%20id='linearGradient-11'%3e%3cstop%20stop-color='%2321C6C1'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-12'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3c/defs%3e%3cg%20id='页面-1'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='生成过程'%20transform='translate(-766,%20-1268)'%3e%3cg%20id='编组-7'%20transform='translate(321,%20699)'%3e%3cg%20id='编组-5'%20transform='translate(247,%20488)'%3e%3cg%20id='智能logo60px'%20transform='translate(198,%2081)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='60'%20height='60'%3e%3c/rect%3e%3cg%20id='编组-35'%20transform='translate(0.8571,%200.8571)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='58.2857143'%20height='58.2857143'%3e%3c/rect%3e%3cg%20id='编组-19备份-17'%20transform='translate(3.4286,%201.7143)'%3e%3cpath%20d='M27.9148216,2.78182535%20L48.5699376,14.1530432%20L48.5699376,40.3974054%20L47.2122691,41.7510852%20L27.3406238,30.8038254%20L27.3409512,52.7213631%20L24.171182,52.7213631%20L5.44311735,42.3783901%20L2.71762384,37.2224388%20L2.71762384,15.5894926%20L6.42297243,13.283793%20L23.2736238,23.3278254%20L23.2743772,2.9432797%20L27.9148216,2.78182535%20Z%20M23.4754451,30.9317128%20L8.53087583,39.5446435%20L23.4754451,47.7846148%20L23.4754451,30.9317128%20Z%20M44.520407,18.7074592%20L29.4892375,27.452433%20L44.520407,35.7697922%20L44.520407,18.7074592%20Z%20M6.77922307,18.2560647%20L6.77922307,35.7697922%20L21.866501,27.2386257%20L6.77922307,18.2560647%20Z%20M27.3409512,7.11090709%20L27.3409512,24.0680782%20L42.5903667,15.2700646%20L27.3409512,7.11090709%20Z'%20id='形状结合'%20fill='url(%23linearGradient-1)'%3e%3c/path%3e%3cg%20id='路径-2-+-路径-3-+-路径-4蒙版'%20transform='translate(2.7176,%202.7818)'%3e%3cmask%20id='mask-3'%20fill='white'%3e%3cuse%20xlink:href='%23path-2'%3e%3c/use%3e%3c/mask%3e%3cuse%20id='蒙版'%20fill='url(%23linearGradient-1)'%20xlink:href='%23path-2'%3e%3c/use%3e%3cpolygon%20id='路径-2'%20fill='url(%23linearGradient-4)'%20filter='url(%23filter-5)'%20mask='url(%23mask-3)'%20points='14.177196%2023.2632694%2022.5796859%2023.2632694%2023.4218687%2027.5957059%209.52757789%2036.9780352%203.7254788%2029.0812693'%3e%3c/polygon%3e%3cpolygon%20id='路径-3'%20fill='url(%23linearGradient-6)'%20filter='url(%23filter-7)'%20mask='url(%23mask-3)'%20points='23.4218687%2022.4125055%2027.1161878%2015.1091341%2027.8042533%206.35665145%2018.1506617%205.88610282%2018.8417696%2016.8706238%2022.5796859%2022.4125055'%3e%3c/polygon%3e%3cpolygon%20id='路径-4'%20fill='url(%23linearGradient-8)'%20filter='url(%23filter-9)'%20mask='url(%23mask-3)'%20points='33.5501273%2024.6706076%2024.403058%2024.9983902%2024.403058%2027.5289361%2028.4733448%2033.3539069%2036.4355638%2036.3335669%2041.6970622%2028.387534'%3e%3c/polygon%3e%3c/g%3e%3cpath%20d='M27.9148216,2.78182535%20L48.5699376,14.1530432%20L48.5699376,40.3974054%20L47.2122691,41.7510852%20L23.2743772,28.5628437%20L23.2743772,2.9432797%20L27.9148216,2.78182535%20Z%20M27.3409512,7.11090709%20L27.3409512,24.0680782%20L28.3053772,23.5108254%20L28.3061985,25.7112082%20L30.1053772,27.0928254%20L29.4892375,27.452433%20L44.520407,35.7697922%20L44.5203772,18.7198254%20L45.4350062,17.1793767%20L42.5903667,15.2700646%20L27.3409512,7.11090709%20Z'%20id='形状结合'%20fill='url(%23linearGradient-10)'%20fill-rule='nonzero'%3e%3c/path%3e%3cpolygon%20id='路径'%20fill='url(%23linearGradient-11)'%20fill-rule='nonzero'%20points='22.5927693%2026.8440709%2023.6315003%2030.8033921%208.53087583%2039.5446435%207.30516741%2035.4601402'%3e%3c/polygon%3e%3cg%20id='编组-21'%20fill='url(%23linearGradient-12)'%3e%3cpath%20d='M25.4312165,33.1398658%20C28.857043,33.1398658%2031.634224,30.3626848%2031.634224,26.9368583%20C31.634224,23.5110318%2028.857043,20.7338508%2025.4312165,20.7338508%20C22.00539,20.7338508%2019.228209,23.5110318%2019.228209,26.9368583%20C19.228209,30.3626848%2022.00539,33.1398658%2025.4312165,33.1398658%20Z%20M46.5950591,20.103577%20C49.2645342,20.103577%2051.4285714,17.9395398%2051.4285714,15.2700646%20C51.4285714,12.6005895%2049.2645342,10.4365523%2046.5950591,10.4365523%20C43.9255839,10.4365523%2041.7615467,12.6005895%2041.7615467,15.2700646%20C41.7615467,17.9395398%2043.9255839,20.103577%2046.5950591,20.103577%20Z%20M25.4312165,54.9048659%20C28.1006917,54.9048659%2030.2647289,52.7408287%2030.2647289,50.0713536%20C30.2647289,47.4018784%2028.1006917,45.2378412%2025.4312165,45.2378412%20C22.7617413,45.2378412%2020.5977042,47.4018784%2020.5977042,50.0713536%20C20.5977042,52.7408287%2022.7617413,54.9048659%2025.4312165,54.9048659%20Z%20M4.83351235,43.462539%20C7.50298751,43.462539%209.6670247,41.2985018%209.6670247,38.6290267%20C9.6670247,35.9595515%207.50298751,33.7955143%204.83351235,33.7955143%20C2.16403719,33.7955143%200,35.9595515%200,38.6290267%20C0,41.2985018%202.16403719,43.462539%204.83351235,43.462539%20Z%20M25.4312165,8.37808808%20C27.7447616,8.37808808%2029.6202605,6.50258918%2029.6202605,4.18904404%20C29.6202605,1.8754989%2027.7447616,0%2025.4312165,0%20C23.1176714,0%2021.2421725,1.8754989%2021.2421725,4.18904404%20C21.2421725,6.50258918%2023.1176714,8.37808808%2025.4312165,8.37808808%20Z%20M46.5950591,43.3044363%20C48.9086042,43.3044363%2050.7841031,41.4289374%2050.7841031,39.1153922%20C50.7841031,36.8018471%2048.9086042,34.9263482%2046.5950591,34.9263482%20C44.2815139,34.9263482%2042.406015,36.8018471%2042.406015,39.1153922%20C42.406015,41.4289374%2044.2815139,43.3044363%2046.5950591,43.3044363%20Z%20M4.83351235,18.3420872%20C7.14705749,18.3420872%209.02255639,16.4665883%209.02255639,14.1530432%20C9.02255639,11.8394981%207.14705749,9.96399915%204.83351235,9.96399915%20C2.51996721,9.96399915%200.644468314,11.8394981%200.644468314,14.1530432%20C0.644468314,16.4665883%202.51996721,18.3420872%204.83351235,18.3420872%20Z'%20id='形状结合'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",lr=i.defineComponent({name:"FXGenerateProcess",props:Ks,emits:["closed"],setup(e,t){const n=i.computed(()=>{const d={"fx-generate-process":!0,"fx-generate-process--no-progress":!e.showProgress};return be(d,e.customClass)}),u=i.computed(()=>Ae({},e.customStyle));function o(){var d,f;return t.slots.icon?t.slots.icon():i.createVNode("div",{class:["fx-generate-process--icon",(d=e.classNames)==null?void 0:d.icon],style:(f=e.styles)==null?void 0:f.icon},[e.icon?Sr(e.icon):i.createVNode("img",{alt:"ai logo",class:"fx-generate-process--icon-default",src:rp},null)])}function r(){var d,f;return e.description&&i.createVNode("p",{class:["fx-generate-process--description",(d=e.classNames)==null?void 0:d.description],style:(f=e.styles)==null?void 0:f.description},[e.description])}function a(){var d,f;return e.progress>0&&i.createVNode("div",{class:["fx-generate-process--progress-text",(d=e.classNames)==null?void 0:d["progress-text"]],style:(f=e.styles)==null?void 0:f["progress-text"]},[e.progress,i.createTextVNode("%")])}function s(){return i.createVNode("div",{class:"fx-generate-process--mask",onClick:d=>{d.stopPropagation()}},null)}function c(d=()=>{}){t.emit("closed",{callback:d})}return i.watch(()=>e.visible,d=>{d||c()}),t.expose({close:c}),()=>{var d,f;return i.createVNode(i.Fragment,null,[e.visible&&s(),e.visible&&i.createVNode("div",{class:n.value,style:u.value},[o(),!e.showProgress&&r(),e.showProgress&&i.createVNode("div",{class:["fx-generate-process--progress-bar",(d=e.classNames)==null?void 0:d["progress-bar"]],style:(f=e.styles)==null?void 0:f["progress-bar"]},[i.createVNode("div",{class:"fx-generate-process--progress-fill",style:{width:`${e.progress}%`}},null),!e.description&&a()]),e.description&&e.progress>0&&i.createVNode("div",{class:"fx-generate-process--progress"},[r(),i.createTextVNode(" "),a()])])])}}});lr.install=e=>{e.component(lr.name,lr)};const Qs={title:{type:String,default:"历史对话"},items:{type:Array,default:()=>[]}},up=[{key:"today",label:"今天"},{key:"week",label:"近7天"},{key:"older",label:"更早"}],dr=i.defineComponent({name:"FXChatHistory",props:Qs,emits:["itemClick"],setup(e,{emit:t}){const n=a=>{const s=new Date(a),c=new Date;return s.getDate()===c.getDate()&&s.getMonth()===c.getMonth()&&s.getFullYear()===c.getFullYear()},u=a=>{const s=new Date(a),c=new Date;return c.setDate(c.getDate()-7),s>=c&&!n(a)},o=i.computed(()=>{var c;const a={today:[],week:[],older:[]};(c=e.items)==null||c.forEach(d=>{n(d.timestamp)?a.today.push(d):u(d.timestamp)?a.week.push(d):a.older.push(d)});const s=(d,f)=>f.timestamp-d.timestamp;return a.today.sort(s).length||a.week.sort(s).length||a.older.sort(s).length?{today:a.today.sort(s),week:a.week.sort(s),older:a.older.sort(s)}:null}),r=(a,s)=>s.length>0&&i.createVNode("div",{class:"f-chat-history-section"},[i.createVNode("span",{class:"f-chat-history-section-header"},[a]),i.createVNode("div",{class:"d-flex flex-column"},[s.map(c=>i.createVNode("div",{key:c.id,class:"f-chat-history-item",onClick:()=>t("itemClick",c)},[i.createVNode("span",{class:"f-chat-history-item-title"},[c.title])]))])]);return()=>i.createVNode("div",{class:"f-chat-history-manager"},[i.createVNode("div",{class:"f-chat-history-manager-scroll"},[o.value&&up.map(a=>r(a.label,o.value[a.key]))])])}});dr.install=e=>{e.component(dr.name,dr)};const Js={items:{type:Array,default:()=>[]},title:{type:[String,Object],default:""},vertical:{type:Boolean,default:!1},wrap:{type:Boolean,default:!1},gap:{type:[String,Number],default:12},fadeIn:{type:Boolean,default:!1},fadeInLeft:{type:Boolean,default:!1},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""}};var ec=(e=>(e.standardFeatureCard="standard-feature-card",e.primaryFeatureCard="primary-feature-card",e.compactFeatureCard="compact-feature-card",e.standardQuestionItem="standard-question-item",e.functionEntryItem="function-entry-item",e.defaultTextItem="default-text-item",e.hasNestEntryItem="has-nest-entry-item",e.likeButtonEntryItem="like-button-entry-item",e.none="",e))(ec||{});const tc={id:{type:[String,Number],default:""},icon:{type:[String,Object],default:""},label:{type:[String,Object],default:""},description:{type:[String,Object],default:""},badge:{type:[String,Object],default:""},disabled:{type:Boolean,default:!1},children:{type:Array,default:()=>[]},styles:{type:Object},classNames:{type:Object},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},showType:{type:String,default:ec.defaultTextItem},gap:{type:[String,Number]},onClick:{type:Function,required:!1}},hu=i.defineComponent({name:"FPrompt",props:tc,setup(e){const t=i.computed(()=>!e.id&&e.children&&e.children.length>0),n=i.computed(()=>{var p;let l={"fx-prompt--item-wrapper":!0,"fx-prompt--item-disabled":e.disabled,"fx-prompt--item-has-nest":e.id&&e.children&&e.children.length>0};return l=be(l,(p=e.classNames)==null?void 0:p.item),be(l,e.customClass)}),u=i.computed(()=>{let l={"fx-prompt--item":!0};return l[`fx-prompt--${e.showType||"none"}`]=!0,l}),o=i.computed(()=>{var p;const l=Ae({},(p=e.styles)==null?void 0:p.item);return Ae(l,e.customStyle)}),r=()=>{var l,p;return e.icon?i.createVNode("div",{class:["fx-prompt--item-icon",(l=e.classNames)==null?void 0:l.icon],style:(p=e.styles)==null?void 0:p.icon},[Sr(e.icon)]):null},a=()=>{var l,p;return e.label?i.createVNode("h6",{class:["fx-prompt--item-label",(l=e.classNames)==null?void 0:l.label],style:(p=e.styles)==null?void 0:p.label},[In(e.label)]):null};function s(){var p;const l={"fx-prompt--item-badge":!0};return typeof e.badge=="string"&&(l["badge-default"]=!0),be(l,(p=e.classNames)==null?void 0:p.badge)}const c=()=>{var l;return e.badge?i.createVNode("span",{class:s(),style:(l=e.styles)==null?void 0:l.badge},[In(e.badge)]):null},d=()=>{var l,p;return e.description?i.createVNode("p",{class:["fx-prompt--item-description",(l=e.classNames)==null?void 0:l.description],style:(p=e.styles)==null?void 0:p.description},[In(e.description)]):null},f=()=>{var l,p,m,h;return!e.children||e.children.length===0?null:i.createVNode(An,{class:{"fx-prompt--only-children":!e.id,"fx-prompt--item-nested":e.id},gap:e.gap,items:e.children,vertical:!0,customClass:(l=e.classNames)==null?void 0:l.subItems,customStyle:(p=e.styles)==null?void 0:p.subItems,styles:{item:((m=e.styles)==null?void 0:m.subItem)??{}},classNames:{item:((h=e.classNames)==null?void 0:h.subItem)??""}},null)};return()=>{var l,p;return i.createVNode("div",{class:n.value,style:o.value,onClick:e.onClick},[t.value?f():i.createVNode("div",{class:u.value},[r(),c(),i.createVNode("div",{class:["fx-prompt--item-content",(l=e.classNames)==null?void 0:l.itemContent],style:(p=e.styles)==null?void 0:p.itemContent},[a(),d(),f()])])])}}}),An=i.defineComponent({name:"FXPrompts",props:Js,emits:["item-click"],setup(e,t){const n=i.computed(()=>{var f;let d={"fx-prompts":!0,"fx-prompts--fade-in":e.fadeIn,"fx-prompts--fade-in-left":e.fadeInLeft};return d=be(d,e.customClass),d=be(d,(f=e.classNames)==null?void 0:f.root),d});function u(d=null){var l;let f={"fx-prompts--items":!0,"fx-prompt":!0,"fx-prompts--items-wrap":e.wrap,"fx-prompts--items-vertical":e.vertical};return f=be(f,(l=e.classNames)==null?void 0:l.items),f=be(f,d==null?void 0:d.customClass),f}function o(d=null){var l;let f={};return(e.gap||e.gap===0)&&(f.gap=typeof e.gap=="number"?`${e.gap}px`:e.gap),f=Ae(f,(l=e.styles)==null?void 0:l.items),f=Ae(f,d==null?void 0:d.customStyle),f}const r=(d,f)=>{f.disabled||f.children&&f.children.length>0||t.emit("item-click",d,f)},a=d=>{var f,l;return d!=null&&d.title?i.createVNode("h5",{class:["fx-prompts--title",(f=e.classNames)==null?void 0:f.title],style:(l=e.styles)==null?void 0:l.title},[In(d==null?void 0:d.title)]):null};function s(d){return!d.items||d.items.length===0?null:i.createVNode("div",{class:u(d),style:o(d)},[d.items.map((f,l)=>i.createVNode(hu,{key:f.id||`key_${l}`,id:f.id,icon:f.icon,label:f.label,description:f.description,disabled:f.disabled,children:f.children,styles:f.styles||e.styles,classNames:f.classNames||e.classNames,showType:f.showType,customClass:f.customClass,customStyle:f.customStyle,gap:f.gap,badge:f.badge,onClick:p=>r(p,f)},null))])}function c(){return t.slots.footer?t.slots.footer():null}return()=>{var d;return i.createVNode("div",{class:n.value,style:(d=e.styles)==null?void 0:d.root},[t.slots.title&&t.slots.title(),a(e),t.slots.default&&t.slots.default(),s(e),c()])}}});An.install=e=>{e.component(An.name,An),e.component(hu.name,hu)};const nc={items:{type:Array,default:()=>[]},height:{type:Number,default:200},title:{type:[String,Object],default:"推荐操作"},prompt:{type:[String,Object],default:"输入@获取推荐操作"},promptChar:{type:String,default:"@"},promptAgentName:{type:String,default:"AI助理"}},fr=i.defineComponent({name:"FXSuggestion",props:nc,setup(e,t){const n=i.ref(null),u=i.ref(!1),o=i.ref(!1),r=i.ref({top:0,left:0,height:0}),a=i.ref(-1),s=i.ref(""),c=i.computed(()=>typeof e.prompt=="string"?e.prompt:"输入“@”获取推荐操作"),d=i.computed(()=>{var v;return(((v=e.items)==null?void 0:v.length)??0)===0}),f=()=>{var W;if(!n.value||d.value)return;if((((W=n.value.textContent)==null?void 0:W.trim())||"")===""){n.value.textContent="",n.value.innerHTML="",y();return}const g=window.getSelection();if(!g||g.rangeCount===0)return;const b=g.getRangeAt(0),w=b.cloneRange();w.selectNodeContents(n.value),w.setEnd(b.endContainer,b.endOffset);const k=w.toString(),S=k.lastIndexOf(e.promptChar);if(s.value=n.value.textContent||"",S!==-1&&k.substring(S+1).trim()===""&&(n.value.textContent=k.replace(/@$/,`@${e.promptAgentName} `),s.value=n.value.textContent,u.value=!0,b.selectNodeContents(n.value),b.collapse(!1),g.removeAllRanges(),g.addRange(b)),u.value===!1){o.value=!1,a.value=-1;return}if((n.value.textContent||"").lastIndexOf(`@${e.promptAgentName} `)!==-1){const B=document.createRange();B.setStart(n.value,0),B.setEnd(b.endContainer,b.endOffset);const{top:I,right:M}=B.getBoundingClientRect(),D=l();r.value={top:I-D-5,left:M+5,height:D},a.value===-1&&(a.value=0),o.value=!0}else o.value=!1,a.value=-1},l=()=>{const g=e.items.length*38-6;return Math.min(g+28+20,e.height)},p=v=>{var k;if(!n.value)return;const g=window.getSelection();if(!g||g.rangeCount===0)return;const b=((k=n.value.textContent)==null?void 0:k.replace(/\s*$/,""))||"";n.value.textContent=`${b} ${v.label}`;const w=g.getRangeAt(0);w.selectNodeContents(n.value),w.collapse(!1),g.removeAllRanges(),g.addRange(w),y()},m=async v=>{if(!o.value||!e.items||e.items.length===0)return;switch(["ArrowUp","ArrowDown","Enter","Escape"].includes(v.key)&&v.preventDefault(),v.key){case"ArrowDown":a.value++,a.value>=e.items.length&&(a.value=0);break;case"ArrowUp":a.value--,a.value<0&&(a.value=e.items.length-1);break;case"Enter":a.value!==-1&&p(e.items[a.value]);break;case"Escape":y();break}await i.nextTick();const g=a.value>0?".f-chat-suggestion-panel-item--current":".f-chat-suggestion-panel-header",b=document.querySelector(g);b==null||b.scrollIntoView({block:"nearest",behavior:"smooth"})},h=v=>{n.value&&!n.value.contains(v.target)&&y()},y=()=>{u.value=!1,o.value=!1,a.value=-1};i.onMounted(()=>{document.addEventListener("click",h)}),i.onUnmounted(()=>{document.removeEventListener("click",h)});const x=v=>{const g=v.iconUrl||"",b=v.icon||"f-icon f-icon-task-record";return i.createVNode(i.Fragment,null,[g?i.createVNode("img",{alt:"suggestion item icon",src:g},null):i.createVNode("i",{class:b},null),i.createVNode("span",{class:"f-chat-suggestion-panel-item-label"},[v.label])])};return()=>{var v;return i.createVNode("div",{class:"f-chat-suggestion-container"},[i.createVNode("div",{ref:n,class:"f-chat-suggestion-input",contenteditable:"true",onInput:f,onKeyup:f,onKeydown:m,"data-placeholder":c.value},null),o.value&&i.createVNode("div",{class:"f-chat-suggestion-panel",style:{top:`${r.value.top}px`,left:`${r.value.left}px`,height:`${r.value.height}px`}},[i.createVNode("div",{class:"f-chat-suggestion-panel-header"},[e.title]),i.createVNode("div",{class:"f-chat-suggestion-panel-container"},[(v=e.items)==null?void 0:v.map((g,b)=>i.createVNode("div",{key:b,class:["f-chat-suggestion-panel-item",{"f-chat-suggestion-panel-item--current":b===a.value}],onClick:()=>p(g),onMouseenter:()=>a.value===b},[x(g)]))])])])}}});fr.install=e=>{e.component(fr.name,fr)};const rc={type:{type:String,default:"Todo"},message:{type:String,default:""},items:{type:Array,default:[]},customClass:{type:String,default:""}},hr=i.defineComponent({name:"Todo",props:rc,setup(e){const t=i.ref(!0),n=i.computed(()=>{var o;return(o=e.items)==null?void 0:o.length});function u(){t.value=!t.value}return()=>i.createVNode("div",{class:["f-chat-message-todo",e.customClass]},[i.createVNode("div",{class:"f-chat-todo-message"},[e.message]),i.createVNode("div",{class:"f-chat-todo-list"},[i.createVNode("div",{class:"f-chat-todo-header",onClick:u,role:"button",tabindex:0,onKeydown:o=>o.key==="Enter"&&u()},[i.createVNode("span",{class:"f-chat-todo-header-icon-slot"},[i.createVNode("span",{class:"f-chat-todo-header-icon"},[i.createVNode("i",{class:"f-icon f-icon-task-record"},null)]),i.createVNode("span",{class:"f-chat-todo-header-expand"},[i.createVNode("i",{class:t.value?"f-icon f-icon-arrow-chevron-down":"f-icon f-icon-arrow-chevron-right"},null)])]),i.createVNode("span",{class:"f-chat-todo-header-label"},[i.createTextVNode("待办任务")]),i.createVNode("span",{class:"f-chat-todo-header-count"},[n.value])]),t.value&&i.createVNode("div",{class:"f-chat-todo-content"},[i.createVNode(Kn,{items:e.items},null)])])])}});hr.install=e=>{e.component(hr.name,hr),e.component(Kn.name,Kn),e.component(eu.name,eu)};const uc={icon:[String,Object],title:[String,Object],description:[String,Object],customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})}},pr=i.defineComponent({name:"FXWelcome",props:uc,emits:[],setup(e,t){const n=i.computed(()=>{const a={"fx-welcome":!0};return!e.description&&(e.icon||t.slots.icon)&&(a["fx-welcome--no-description"]=!0),be(a,e.customClass)}),u=i.computed(()=>Ae({},e.customStyle));function o(){var a,s;return t.slots.icon?t.slots.icon():e.icon?i.createVNode("div",{class:["fx-welcome--icon",(a=e.classNames)==null?void 0:a.icon],style:(s=e.styles)==null?void 0:s.icon},[Sr(e.icon)]):null}function r(){var a,s,c,d,f,l;return t.slots.content?i.createVNode("div",{class:"fx-welcome--content"},[t.slots.content()]):(e.title||e.description)&&i.createVNode("div",{class:["fx-welcome--content",(a=e.classNames)==null?void 0:a.content],style:(s=e.styles)==null?void 0:s.content},[e.title&&i.createVNode("h4",{class:["fx-welcome--title",(c=e.classNames)==null?void 0:c.title],style:(d=e.styles)==null?void 0:d.title},[e.title]),e.description&&i.createVNode("p",{class:["fx-welcome--description",(f=e.classNames)==null?void 0:f.description],style:(l=e.styles)==null?void 0:l.description},[e.description])])}return()=>i.createVNode("div",{class:n.value,style:u.value},[o(),r()])}});pr.install=e=>{e.component(pr.name,pr)};const oc={content:{type:Object,required:!0},onOpen:{type:Function}},op="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAHHUlEQVRYCV2XSY8VVRTHT9UbgAbpZpSmaRNMxIiGqZVEE1csXBoNboyJ23ahfgI/gQuXdiRx6UY2utKNEUJjQLrBEEwUmQcBBZuphzdU+fufc+tVw61Xde894/+ce+6tepml9uKhpYMbVpWTuWUTpZUjQc7oSnvUMZvvVZJO8om4ZjzLUmK2bqVZO4g+r3hLfbMHi5plc1lZztBPnftkxeGkbfbCocUvW5lNrl+ZYQdLaurCv3UKs7mlNIHuo9RXsqJtHuKZwFRmxH+4ZLbYq3mS5Z76/dOVH2WKvCjLb1e3zHQPHEszIZDNfxY0AyAT9QNHSaoJaf0KV4qHApAcBu8+NisqwBUdO3mevZcT8aRE27mEaamLCdJShEaGknM4QkQLIJqbrWgsUwy2M3osnYtDS2qDQVlkkwDIJjKYrUbSSp0bDy96ugPJeYbUsyyRjbDXwpK31HkkjDusv5rsPa1PPUzkWBlpKX+VosKleS1Aq6IcOAgmWUkQkaFwo/jcRpUJJvy6/WR7kDU37/oEMNLUtC30lV64dilhKVg8sdo5DxeLQlX0mqs1PbQYV8Qq3Uu90Bc3xJQJKYZ+U327kdREdyDuWTpJSfzMmoDo9pNBtxFG2hSvU0WTjowUhXVZfzmVyQoGBe9zZU3UZo5RGXaypBEYbhf24SvaEj617/7s2/UH1AF8AnLi2zsatnNTwwvrxv3CfryoonAVr43NQ2bv7GxaL9XAVyd7NqedpKVzN3gEQ9NT63pQPd2lPUDwrecbNsK5oHZ3vrBvzvasJbTaT4D8eH/TxoeZ0249KuyH84vExCWriOwfy+yDPb7C9t98aZ//zGkmvtTpXZNxrvRHktTDJJBOr7AT1+ujb9dmEobjFtpav7E15cC5dLasyW3rMwGs7PdN9+4tAU786Su9VEsR0OA5AKB1KQO5ouuQ56MoVW3Xs9osIGNdm1lhb4zXxiuZfTgs4Eu/pN896pE5e/qibAUddjT5ZMRhVM1FEDdj7wLgcjcYPIdX5rZ9GK6ywAHw+rbaeCU0sbVBlqIOtpCh0bU1yGMXOp45mfcdIDcOREuBjjAEDp4g61I4tx4WduleqiD4SmlZ9NnvAHgu1vbOoz4vGQzQ9o5BA0Ch9C+L/o87Pfv3Md7k3CXlI40JKGAO0s82S4Ake/yqCieajGoZdmzMbf1QqJ240rHZ6yGzcXVu4yMqw9J2bw2A0jx2kUwqWhWnOr986I9YgbQeEuz1ZZwbUEcu1XWwZ1QRlvbqWJ3+GQCeWgZyAl7J8u1dDuACAOScZKrO/ABTLgSKGwC6YqIt5Gc3DI1PXusBSJK8atc0bHSN2Wvb4nwQ7QzRz16rs7RvrGV8U9j4ugC50C3tFDbcg0DoR68dJefymwsRP5+oDNmBPGGBdr6b2ZmbdRYmWOc9Kbq/H/TZ/yV1Utg9zgm1feMt27etTv+vV7opo7XNquZcAb9UVjhX3wWxg0lIxTl+uY7w/b1DNpROLqVeQHVVWRhZldu7u/ksSu0Y6dfBIzeKVnc0tETnTjUgchYFqFRVRQntiIoote0b6uh+IzNZpnrJbOZaLbNrrF2J2zS6pVLuzlSegktTlDQth2dASETUue08pPKcfU1/7nZh99NWc630OI1TmROIGVL9dLt5v28X7xbhEpnMqw2n4RtH/HwbOkHVqTddSpYy4Kigo3ziKQe3fP0jAmXgBi+qOw/rM0NgpnX4EF8u57KmMlnmXDTdsaHhqPgcFUjE0DJ4wlCavvRkhLMpeqm7AxRmrz4pc+yvqP5Iu1ty+/WRH/4Gi9qJ49oRxfkkRJHin8537aVN8yknZkdVXIqM24mA/v7skt3m9PQlRPMXP0NYRkWttcSWotWu8wD9yfjNrxcpfT67F7QFGegnJQlyFyoMjuC1rYLXcbWmGMvBrtczsnoH9Fk/vbZDGX6G80YTG7hLYONLCNtq0qPzLyJN9KXjRMlzDT65VMU40odIW2PdHgtPjDtYKN0Sh7p8UWWau3IufxLk58lQclPzJdCHI6aCJDlFL0nGWmMZ0orm+nil8T5yUHKifVzC71JleUObCl1fPRWfLtfwPsemA5ENLo35GsvmOl3+isk/tytorObRIshC9gs49J5SMIXhJEYX7xCVpYxINkkQQGw3mYc38KFKy+aajzvlDP/dDohRmYtsYACEypybwuC8/z2rnBMDNEXBHwzeU8qaeCkLFUTqSvpuQw4qP7KbZTPNhW42hZEDtQAcF4peS6qzQEgW2CmSEyjRfUDnDlLE4g3cMXaenjDE03yQhaycyuNfag6IYIivFoppDFMOdWvt3HmScbDUgLab7louOUOuXvfQh6RsTZ3+bMVhByTCy18sHWStJim6Cb7t+LSgCRRNY0c/mEfqB5HIeSWjkUcjAjetskX9zFFPM3nWxHnT/57/Dzj0fqfCZcLZAAAAAElFTkSuQmCC",ip="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAHeklEQVRYCV1XW2hcVRTd985MZjKxNaVa6cNqnwbaftSIiuiPilh8NC2tWh+lXyFFbMEKgvgABQUfIGoxWqGioFLjR0GQlqooGhptjNU+9EPaarT2IUySZt73Xtfa+5w7o3dyc885+5y91l57nzN3AnHXjoOPbJAgGEhEegNJugUNCURqzbrUk5ok6GcklK6OLrTRwc2PxPhLYkniCAswEqPtbXiWGxekEdUkxniQSCmReDSO4sGP+vYPERoQIjtGtr2JRQOB9tQ3Rh0DPMvNCnAi6cwUJROEBk4QvQluoCkBR6QR1UFgqkVYiWKufmRwT9+BrYFFLh/Dl7sSCAEN0PeEIgA044bkM3mNlkYFR9R8sq8qEIB9AMRRU6brUxiPNHol5whwfsK2yMYsZaeRYFzrwVM6GMuEoYRBBxxRZkgOQubEOeJCOFQHrl1uTEsEcKpDGwFjZ0sVC5KBLJb26kJkw0iADDPjCBHQR8n1BgRnKQknqToHIZCsRVWJoJgBeQJGUpXD3ITkEunN4n93GjXm+LaVAxGJadIyCq5ScOaRkVFIgpMQKoWSVxtlDBkZGHW+X6trdK6u6876PPsU0F+rzdwagDkkCPueEOGtr+BwPF2fNGKOnE8BSbZI2BrWTbaOSs2FHQwUFwzUni0YdRGj54dPFxX7nGVzGLXZKoi8qYWJPqNsA9X6cX3vm4Fka0ogp9ITnCBRxEi53smNZ7sz2ii1H0tirEHO682qI0pCppbVSosMx9vVRBHGUsE+78wWzaGqwJRiEe55nfPkmjnX6SICY5J8PX5AzpfPKohGipytWbROsmGWZp0zdnpEfj47iq4D5w6iAvyoShYUVgQ4YiLRVAQZBdK8AzyKIvlzelw2dW+WK2Yuome9rpy5WF75/llETZKR3L74bll/1f3eLGenT8ueI7uVIGX2kht4q88gQxYcG9VmGYBNnUyGXrqo2ZBdP+3E1qqlAMtm9cjNl6/Rw+ay4nxZu3xTaouw9tXh5+wQgl+Cp4cUI9fbpxYEfJW2y8IcKXMewHBwhhEdfz8FYWPd8vtkftdC6V+93aR31qFj78nRc2P/CcQK2MhYDaCt5BIJWZ0EzId5rWztY4ys/RaERvLlqX3y45lDKYlcJidP3Pi8LLy4lZpfzx+VDw7vgjIOQKNFmjTvLVAGS5/ECgkeJgG+6Zh/xxILtJpgCzDGYuS8d8bekMnaREqikC2kbW7Bl755CqSbEoSabdvRDIRE6Bt+VFn4sjawYZECvmQ8S/Y9EQPGInyPkvFktSS7Dr2WgrY33v1hp/w9OY61zjlJo4ipJH16EnySBGtMFcjzENIgwRIfLgiwgOAKrG0qgWrF3+Ez3+kWbAevN2sy9teIFN1W1mCcigyGvnxQJOjJkBh2bgagzAmJsvgYgZfMnvSFI0od9fVskkuKc9rxpSObl4FrH8O7QgZf2QyIcy16KzZ3BpCI+jaVVQGViOCMmEbIZiTIGo5oY8GgvWTWUlnbc6+O/f/f1fOvl1uX3ikdIMBvU42camqxEdj8+XEM6BwtQisIG9A0YDKJ8YiNQYj2HKLr730U7waZFPuXc0fSNhsPrt4qc7sW4FTt1DXMsx5Wqir90RdTwDYCxjiK0Bvw9G08qbgu0OgjuWfFFpk7Y0EKOD5xUp7et10OnvoqHctjVzx8w5OSxSefMRIE0mDgp1UHLEDe3IZkQpH5guBYKUP0yZ57evmsFXLLojtSIJ52r3/7Aux1eevgi7o7vHHJ7B5Zv2oLDqdc6/0R872SFqRhtilgcnh5aCAJFAW2aEGl54uKv/Ye+1B+++e4vjdM1Ery9sjL3qTPvpUPybLZK/UlNuGhxBTwo8q2lLYiZJQuN5zAYgO8Rs7FD6zql9nFS1OAP0onZM/h3Qoe4HzAmSPDJ76Q4ZOfp3NYJ9tuekby2JYF1gP9Akefrqb8jgv6P9tIRDUaAccwSvANWZOpyoQrSCuoAo7sPLYd1eFrCXeN5pkAmmcd1fcL3boYLVcnpR5XsYS+tbjUJzqsAZOG4HYrG2VcqV/AcvQ5B855LNci/EaIcdziYGKfKoAHLvpBm/N5saboE6CdObxrtOF4NWjHNvTA/mkHSLU5bUB0CBBGg7dzfdJG7fXEZBSwaTpABFMwh/WDC6A6B/bOnP2i8niMXmsAVEu6AxxbRtHAz7Ea3pL0Ql8dgoeXL4ICjUYFbkmOMXOOkSMRlR6RS2BBMWK+LeWwM/wpS3CsKVGBUVBRqQgQoF3B7zl1C1IwENkiJKDesf7mM5uzY1yjZ0qUNJ7wpWeAC66AoiRRrmNqiB1i+SCBLToUDPIeRw2VR5VROWF3zuAVTi2/F/DVzHGO8dYi1G1nwPY+YQQJyruYnQHfNoayHgx337V3CO4H6YhvtTW+2TICd3MRZfMONDrY2G9ilzSQKhajRqSOPSB9WFvzToLo82ceT0w4GBx+vDKkiqAnmz+5bcNUtTSQxM1enIDduih1QAUYNZWCU8SaAqJ3UcdMyI9KgTLMkNrcXKpC0owatVGCj1HUyeCn237Xn+f/Avavy/P8wtVMAAAAAElFTkSuQmCC",ap="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAGCklEQVRYCYVXPY8cRRCtnt29s/EhW0KAEAkxmXUBIkBkRERwdoqFHNiW/AMwPwCJECTYEDKEnYJk4+ASIwQ6WSIjwJKNQBjO8t6Xb3dvZ5r3XlXPjIzX7rub7qmuqvfqo3v3ksXIH53fsJQvmOV1y3aqyJ8055x74sZyAys8EqS+hX2pcC9b3t6xPD/i/gSPrWxpvPrNjWt0QhvLV85/CU2AP3sQXEDmwEIiXkuKLw4sb5DnBgz/nWju9NL42Lc3LyZFbs3VZ0O7RusATrnmj0ceURMMg3JfYEVC+4dme4ctUe5Xls4MlfbQdYvHnnQ4m4N9KKVkmYiDyqzCX+C6VYArG65PcI3jq5Z3D7QsQYDEhSE8rLvGkudRbfZwDzwZSZAo69WR2ck1EAlbYLU6EAmcMrIk8dHAjP60R3+2XmHvqQ1XlBuC8ifA4Q+ZObL8cBcLuGGz4afoQ63LGl+wn4aM131I0fIpSJ42oNws6KmtMyEEVRzNa8vTmVUrgyBHfwhbme+DwY6s3YF7gY+lBErtqM9RIpQ8hCUbNkePDFHjICp96DBJjNgnMKoSEiFmkvHxRAKljllHDdGfPWeDd8+0RssWeTbFmf/b6p82rdn8TuDMVhKZx7LBkoBhaR/5FDAYo10QMY5O3VgNxoXQMuAiT6vHrHr1NRu9f85GF68QGqWAPQJp2CN1NKCOqhP6XwZ0aZAAvCpbWLAB0b/taHYnciwBw1AoONUnnsdSibfB66dt8cbb1vx40xKzTjHLESWhLUsmAoxQ+2DmelQEa8gpqXjme2Pn40uWD3CrjnAMkV8RxX56bs1OfHDZVk6/Ke3hW+/Y9NYPOsIJfhrcJ06A0bvD1rNH3kPhkjwGoLQCoP7ApZJWcIeJrQensu3v2v7Xn7Wa1YuvWLPAKSEYH0cLTA7u5UYPtHWRGSJGOK5EdNaMNaSH/tA1ipgSSoM/MEEBRCjv7VhzsOfKo5Wwhd99NGiEzblk2nuATUFmBBJWmXHBoBFd1hEgGOOuAMwf/ja4L3hbVmtrVqEXOOr7f8q0gY90iM+CdngW6HjoeHp2QCwqu5YdHKxbWy38pCR8KPiJAYfB0KqXXrbjGx+2qvOtW/CJXto9tLRoeA20/tyvLiIHLxdPP1rGKVbBr3g++elXZbl0rrfv2+x7fOTvPrJqhtuU4KHdD2qo1DPKsqvLhykqvcAz1G4uBexvzH/9xfa++MTyPw+swtnnFayysczhqs1Ax4ZpB1TR6Hnswy/u/W6HiEwnAGWKFpBdgzov7t2x+u5ddPxR15xQA7TK1XMrG2SgE1GJgyTaDOAY0VkZ9YNtm25e14VT0XGDCNnEPG6oM4n51VuuWQBTCJ+8V9Q1ESTXOAVINSPhoMPY1CvXIoAalkGwR1O9hTvZUVChy0icgH5SQEbY1ORgy/pwHJ4C+HNWWGBQsdGxxCLI9DhRRTo8+z4IFsThvUp4Q0CciOZazChe9FUqdMN6qGMUtHQSxIMGodEu/J0OSdhnX+s6jjRTKzETEWubXVhQ1hGCInwPWRfX7ZWCXiR3Im5EIQbUieWXkIv4ZN0LZ+nrhZBcADxwhNeZoQek6OmXPIBdB67guf7rD5vf/lmixZ3fPAr2Db+UoocIXgaBCihTTncdtaIIDd+wNL981lUk6BQadXe2xXRuNb731XErVgBNAGfDMQuBIIziVJBsLrgrMp/df5FxH1dxVxdFQSLBjjPTqT+ACZDvWFOmjpfPSLFkFEiIp8/+HutuW/b0OSmMSsNo1tEEKCJlivmFpCIhrKt+zltQEnIQzvKh1y7dkjMzpObBTfBxl7dEVMa8fl2BEYo5P8kierJl1RU/HQDAQQsIEZ0ErQuQXIe4aIiMpS1WdOyKYYLInSkB4mZzNnINDkSNElBXOP7AmpEX+5IFN4GcWQ0dylLK42r4+dVriHBs0XSQx5CKrwXooCFwYL3AMeYCGiJXgwvulqwK3bWZxvELN25fI4rG7NJ7G/jywf+Q13Ou9d+SosHnQDPZb69rAtFIgHSmX1JwmfaYBRdQypX0sTfB2xayKHDK/wNolX2UI+Wo7QAAAABJRU5ErkJggg==",ic="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAGLUlEQVRYCW1XTY9UVRCt19M9MwyiAxojRI1REImJRAfQhcSVGmJINMG9G5LRH+DOxJ0JP0BnpYlbMCYqGBciJmqIZiAsSARUUDQoYGjmo2emP97znFNVr3vUm+n76ladqjpV9973oLAYcyf6hwZlOVtVNmNWTVcQDH9lPLnGcr1Oa9cTRoD8KEoerstS3m1g5pe71dw7h6eP0b3g9O7x7ntwnKUsR4AzoQIymGzUU/DAFDlS53Il0qlTnABSJpHOGnzKau7IG1teL7zywVE6OJjoQnIGB1gEmEk4JQ0yAqWvP9PPn8DV/obkpQ1K4pClarzaZNs9OuEcnlyVY1UBzDEk586upUF/9ZJCFkM5Wi9df1B58iRkg9kmwDNKFoFSromMZmBzMPRYR4w6D+BEA5d4PJHTVteEkr/jihkQKKcVFEwC7wePieg10pG0J5BrVsuhp+SR7ZO/GStfQXKC3IczcDjszdpZQQiihlgXSu5BqKXhxDWDSRHY/9Ex/1qvtH5fIT00fWpsZc0S7KTjlEMALGSIR9hFbAQ7gD8H9byyVVVgnyskxY+x0y+6kddaPpianS69PcmGcQ9UHzw3iQcdkhDFPFxsrcf2ZNhSkTEQ4chO1nLk8u0FgayITFOJ7amvTlbAUlLO5PLRNPLCUtqiPkfJ3rsjY52Hrs2sHuFlzRZxlQmFcXOty+SRX77ug7nGupBFEkQ5zJKbXGTlmXy8ZfbwVp3PCJbtrez6rYHduxm84fjz731bXoGAxe5HWtr728ulbb6jIUI5sWM9HMRzP63VuZI43wNiNMpy01RhLz09kf7rnp9+t2J7do7b1rvHbP5C1z76umP7do3by/un7OT8ij32YMtmdv7Xd7FT2rlLIMBo4kypwBmI0yklbdAvLFV2/PSq5AP7JmxsrLCvzq4Zg1y93reb7YG9dmCjPbmjZafPN+z5PZN2a3FgX55ZtW1bxuzCr13b8UDL9u6atD9u9O3UmRXr4lZkh1UscnGNLXAm2ps4uWs9s/NXBqL64l4QgHTxas/+XvDXX3uxtLOXevbUo+N2+OAmG28VdvTzRet2K7v8Z99+uVbZxHgBAmbtpdJ++JFfH4XD5KKvK2uocnSh0tF3q5PxL5c8wond4X4y1klUxXvO5Feu9ez85R46Bgv/COCPI3R8oaW/Y/xcNWpsbIWS00/ew0lBY8lte+i+pjWxNRzb7mnaXTg3HCLBp1Y+1cRCqyIC0BDBTB6OTKDfaBTaAKa+iQvywt4NuAGlXfitqy4cfHZK4enivu6stdjzGxHvi4hFIg2COTJ4rl0nkybZASV6/xOTdufGhrbh41PL2ord2yds+zZcz4g39GRsj18zDCNj6sIqOJR8cngy7pGvQ6n1lk0Ne+bxCfsL74MzF7t2Ewfzm3Orgrzy3EYrsBN52t1P80jMOEcKzWuIJEoUCrYlB/Wf4d4z6GIHOBhaOHSffNuxazd6/j2A8ovvO7pu9JvCK2CxY9iann14YsFuLQ08OWxej8fPPMVb7y9Iw9ZNTfo+8YPCl0SCRBLp64aIpH/3l/Bu4A0qS7+iDJbb4P6O80JhHLEzXvx7wFkNQXCKTnhyuqENwcAZx+cXFrWcJGjHj3aHZnL6pw7PkBm76Szp6AB3pByB5Ip1EsKTATTok2v5cwoTA6UOqnXdFMavLTrgrfWlV5nJGYryuqAef0hIoBoiaJJ1/3BAhxRXb1vkxJZx6/xjFExjG+EBMEP9K7nI0FZXTfL8ZXCW5qW4PgqAVqE4YYx2Qy8iad2mgOTGEXjpXB5JBMjwuolu+DipoT99kojLDnRdA1esTUZM6RX6s24jnWFXQ4gbxbJy+KkiCIpDaMh08k5QiT/4JibIt/EmtPkaSBKkpwkPRNJHRCpXpt3JMoHDk3ztzK2iDVONYWwO6fEoivkGPmhzDgybql3PXD5wykoVFEpWUXeHQairq/QYo8Xw4HGt6oEtkLtxZBb/SxWJCAaDQmmKKpJU2JTL80HjeOpEUBrows6Htg2C5HSwau6Dt+8/5kcWyjfn2oemWgP8D7kxMygH00QziLd25E3HKBiqHvIy3oTkJ10IddsVIBK73AZ0vrBCyenzD7OyHHaTkJSSAAAAAElFTkSuQmCC",sp="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAGkElEQVRYCZVXS2udRRh+Z+Y7zTFtk5iml7S1XpBW3HhJdVER0YUKikhtRNCFF5TYheLWjX/AlRuzcOnO/AXXIpiFG0URoUWq0KJpLb2eb8bned6ZcxLaCP1O5szMe33ey8z5Eqw+5czyKSt5Bdsli3vnRB6dB+k6lgV/2SVLsYJ1IE108pw23jf6plk6pWyEYOuhhNXwyPdrNBj4Vc689qXlQudm3QGoJS2t9GbX/8B6hOEgCpzROeexQ4EjHRTSsZ/IEXjjYV31ILuaHl3/MHjk/TdEaHEPxvTYkBzlq2Y3zrkzOWD0XNBJM+h7OmqOmyPOkmsgMvRDDaDYcoShFQqFMJRz2a4oIYbtFOgzQq40ykmLUNL0zoVkVJrmtM4OGNbgXCAzs0SdvBLxtUTDJd1dIyPD0+xC2HezKFa0QKXxqBmAtNEwsyFwVR9eW5kcOAWd53KSX4pANRfibjA7qgMEnXiEboB6oIYZ8R0A00iDeOi4OQM4lY00Aa3louaY5mup5zIXA1WQYndMJlHSMI1x8shCYhlEqWwH6ptJXb0Hqh6BKTuTyEGRXdqn7a6EnbCBVqiIZZBfAjJRFKw0a2V0ofJcxh1WueGDFhc/RtvcZ+HKT5bPfV5PEfjVXusDZQBgOjUYFkSmR7ItddUJJqWWWRj9gx2OpTLjdOmCF+//wkLnV4jNPm1xeK/1Py+jd27QEP5q9DLrPtBZ6MPKbChZ32JMPUd1rgzBCPulloV8zxzoO5+YOJcW9KaOmO1+EjtPdyvn5pm5B5+jatE4hqoNWpATp8EM+mWXDMpoPVa+ZpS3PgH3inULEJnUXmv6Aw3h07l2mDxiORKtRegArFu0MjyGXpweN1cDGP79zsqNP7cgKFd+Mbv2O474rLJD+5ujp++uaZChk1AJbhhQMq5jgCmocTr8KUpwl+WzV61c/FZZyrhUvD+GuNI/s7BwysKOQ1au/WblwtrYoXV7LfTXcLtfZujj0bErme7mvNWUWfBaUzxb3PeuhcT7ArIHTlu+hIjzZb+cEk4SLjLrL1r56ysWzUEBuHe727DBfrQNrvZ8E1Y8814CbPSppWjN5bTeytRRi7sel3N+xanDFuZfrWWAicE+2GuAGRBLWTPK7OkukCb6ASAkWwGo2SRMAUfejJUesUA5LbxB5pYnLryOfbIyWJA4v5Q90FgW+sjQLfhFVXZrf/HHjld76wdlwDveETnD1wSk6KePbnHOTZxaNNtzEg05lKPMIA68b/HY1xbnXxTNywobygiUiIo2cSpCGKg8AtDq3hQQNl4PMNCAac8r9HfbJy2chBxKhBH3v2Np/gVcKwNLix9Y2H3CecyCDhe/HEzARVMGe5WFSOfNMaPPPVFSFgqoV9z1mO9v852QmTL1gIWZpwD05S0S3eGPoI9jiw9tFf4EMxPVfEi4T9DUuoi8duRUMIicYOL880hV6+Mt9sebwf43bXDo9HjfFiENLR35pDomDHwULPGwN1CyHQhQkFgbDU5g6tNZmn2m2dt27maO43jyB+3WJ+18GC9ZL7kzOpSIl4L+GK5fxUI3YbCucebEtoZvdbU9pTv4tmVcYq2nVIoGBnHXDPAi4rHBrRdYJ9zRc89tb/UOOMxOd/A9aHhe+T6oNTMOmpqQDjWUCQji7k7TD92Bm/8XTeilsuMgfKC8uFvgRs656ASoOm73QRldsv7SDxaG90DQz8ikFblqg4aIna/tfJw+6dsql684T3XHEgBcBl0w+vUtvWixRkKI+rMU/egm5lE957xKUB798NChQnBL1OOzmcaoMhoM/nmKYoy4H/HyVyLWLi4A0MGbKH8YIKgLhYrsVl6faETPFZigwU+gRUWhN0kH4imEBYJinWkLkYHOtTsmSOjw5cfFuIU+3gnj9bMb6Po5Jlo/GrwsACJiUDoydtRtQIN0LjpYtERjmimLlcCTyHPODtcLBznIBkBRBU5rHORvENI6BciQIISYnqj3ZUaDCw1rvLspmoQoEgT4z1uCnA9Pd4IcR4QMdSjHwLCUHdpX6jETJIjrAFZWBZdMDAFhrZlGiFGZhqIG1jLMmUB0jjXzzabTnv9ZMnK3x5rTTguyZZq0kPNq5H+psA0QkgFCjwaT0FJwclVj0wSZ47bGTOBbmhNcOVYw7CsPSCo0A5/ds3+vSYb78uPxU31/cwUAlnLf490aDqqThppyPClthltlajyD54C9nNKvNggQvA3Q1lFOOD+/Rjv/AYfYvIrlGomFAAAAAElFTkSuQmCC",mr=i.defineComponent({name:"FChatAttachmentPreview",props:oc,emits:[],setup(e){function t(s){switch(s.toLowerCase()){case"doc":case"docx":return op;case"xlsx":case"xls":return ip;case"ppt":case"mobi":return ap;case"txt":return ic;case"png":case"jpg":case"jpeg":case"gif":return sp;default:return ic}}function n(s){return s.icon?s.icon:t(s.type||"")}function u(s){if(s===0)return"0 B";const c=1024,d=["B","KB","MB","GB"],f=Math.floor(Math.log(s)/Math.log(c));return parseFloat((s/Math.pow(c,f)).toFixed(2))+" "+d[f]}async function o(s){var c;(c=e.onOpen)==null||c.call(e,s)}async function r(s,c){s.stopPropagation(),s.preventDefault();const d=an(c);d&&await _r(d,c.name)}function a(s,c){const d=u(s.size||0),f=n(s),l=an(s);return i.createVNode("div",{key:c,class:"f-chat-attachment-preview-card"},[i.createVNode("div",{class:"f-chat-attachment-preview-card-inner"},[i.createVNode("div",{class:"f-chat-attachment-preview-main",role:"button",tabindex:0,onClick:()=>o(s),onKeydown:p=>p.key==="Enter"&&o(s)},[i.createVNode("div",{class:"f-chat-attachment-preview-icon-wrapper"},[i.createVNode("img",{src:f,alt:""},null)]),i.createVNode("div",{class:"f-chat-attachment-preview-info"},[i.createVNode("div",{class:"f-chat-attachment-preview-name",title:s.name},[s.name]),i.createVNode("div",{class:"f-chat-attachment-preview-meta"},[d&&i.createVNode("span",null,[d])])])]),l?i.createVNode("button",{type:"button",class:"f-chat-attachment-preview-download-btn","aria-label":"下载附件",title:"下载",onClick:p=>r(p,s)},[i.createVNode("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","aria-hidden":"true"},[i.createVNode("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("polyline",{points:"7 10 12 15 17 10","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("line",{x1:"12",y1:"15",x2:"12",y2:"3","stroke-linecap":"round","stroke-linejoin":"round"},null)])]):null])])}return()=>{const s=e.content;if(!s)return null;const{message:c,attachments:d}=s;return i.createVNode("div",{class:"f-chat-attachment-preview"},[c&&i.createVNode("div",{class:"f-chat-attachment-preview-message"},[c]),i.createVNode("div",{class:"f-chat-attachment-preview-list"},[d.map((f,l)=>a(f,l))])])}}});mr.install=e=>{e.component(mr.name,mr)},bn.install=e=>{e.component(bn.name,bn)},yn.install=e=>{e.component(yn.name,yn)};const ac={customClass:{type:String,default:""},enableFold:{type:Boolean,default:!0},expanded:{type:Boolean,default:!1},height:{type:Number,default:void 0},width:{type:Number,default:void 0}},gr=i.defineComponent({name:"FXAccordion",props:ac,emits:[],setup(e,t){const n=i.computed(()=>({height:e.height?`${e.height}px`:"",width:e.width?`${e.width}px`:""}));i.provide("accordionContext",{parentProps:e});const u=i.computed(()=>be({"farris-panel":!0,accordion:!0},e.customClass));return()=>{var o,r;return i.createVNode("div",{class:u.value,style:n.value},[(r=(o=t.slots).default)==null?void 0:r.call(o)])}}}),sc={active:{type:Boolean,default:!1},customClass:{type:String,default:""},disabled:{type:Boolean,default:!1},enableFold:{type:Boolean,default:!0},height:{type:Number,default:void 0},iconUri:{type:String,default:""},maxHeight:{type:Number,default:void 0},title:{type:String,default:""},width:{type:Number,default:void 0}},Bo=i.defineComponent({name:"FXAccordionItem",props:sc,emits:["clickHeader"],setup(e,t){const n=i.ref(),u=i.inject("accordionContext"),o=i.ref(e.title),r=i.ref(e.active),a=i.computed(()=>{var m;return!!((m=u==null?void 0:u.parentProps)!=null&&m.enableFold)&&e.enableFold});function s(){e.disabled||!a.value||(r.value=!r.value)}function c(m){t.emit("clickHeader"),s()}const d=i.computed(()=>{const m={card:!0,"farris-panel-item":!0,"f-state-disabled":e.disabled,"f-state-selected":r.value};return be(m,e.customClass)}),f=i.computed(()=>({"f-icon":!0,"f-accordion-collapse":!r.value,"f-accordion-expand":r.value}));function l(){return n.value?n.value.getBoundingClientRect().height:0}const p=i.computed(()=>{const m=e.maxHeight?{transition:"maxHeight 0.36s ease 0s","max-height":r.value?`${e.maxHeight}px`:0}:{transition:"height 0.36s ease 0s",height:r.value?`${l()}px`:0};return r.value||(m.overflow="hidden"),m});return i.onMounted(()=>{var m;(m=u==null?void 0:u.parentProps)!=null&&m.expanded&&(r.value=!0)}),()=>{var m,h,y,x,v,g;return i.createVNode("div",{class:d.value},[i.createVNode("div",{class:"card-header",onClick:c},[i.createVNode("div",{class:"panel-item-title"},[e.iconUri&&i.createVNode("img",{class:"panel-item-title-image",src:e.iconUri,title:"title-icon"},null),i.createVNode("span",null,[o.value]),(h=(m=t.slots).head)==null?void 0:h.call(m),a.value&&i.createVNode("i",{class:f.value},null)]),i.createVNode("div",{class:"panel-item-tool"},[(x=(y=t.slots).toolbar)==null?void 0:x.call(y)]),i.createVNode("div",{class:"panel-item-clear"},null)]),i.createVNode("div",{style:p.value},[i.createVNode("div",{class:"card-body",ref:n},[(g=(v=t.slots).default)==null?void 0:g.call(v)])])])}}});gr.install=e=>{e.component(gr.name,gr),e.component(Bo.name,Bo)};const cc={activeNavId:{type:String,default:""},displayField:{type:String,default:"text"},disableField:{type:String,default:"disable"},horizontal:{type:Boolean,default:!0},idField:{type:String,default:"id"},maxNum:{type:Number,default:99},navData:{type:Array,default:()=>[]},navPicking:{type:Function,default:null},valueField:{type:String,default:"num"},visible:{type:Boolean,default:!0},customClass:{type:String,default:""},customStyle:{type:String,default:""}},br=i.defineComponent({name:"FXNav",props:cc,emits:["nav","update:activeNavId"],setup(e,t){const n=i.ref(e.activeNavId),u=i.ref(e.navData);function o(f){if(u.value&&u.value.length){let l=u.value.find(p=>p[e.idField]===f&&p[e.disableField]!==!0);l||(l=u.value.find(p=>p[e.disableField]!==!0)),l&&n.value!==l.id&&(n.value=l.id,t.emit("nav",l))}}i.watch([()=>e.activeNavId,()=>e.navData],([f,l])=>{u.value=l,o(f)});const r=i.computed(()=>e.visible&&u.value.length>0);function a(f){f.disable||f.id===n.value||Promise.resolve().then(()=>{const l=e.navPicking;return l&&typeof l=="function"?l(f):!0}).then(l=>{let p=!0;typeof l=="object"?l.canContinue||(p=!1,l.message&&console.error({message:l.message,position:"top-center"})):p=l,p&&(n.value=f.id,t.emit("update:activeNavId",f.id),t.emit("nav",f))})}const s=i.computed(()=>{const f={"farris-nav":!0,"farris-nav-vertical":!e.horizontal};return be(f,e.customClass)}),c=i.computed(()=>Ae({},e.customStyle));function d(f){u.value=f,o(n.value)}return t.expose({updateNavData:d}),()=>{var f;return r.value&&i.createVNode("div",{class:s.value,style:c.value},[(f=u.value)==null?void 0:f.map(l=>i.createVNode("div",{class:["farris-nav-item",{active:l[e.idField]===n.value},{disabled:l[e.disableField]}],onClick:()=>a(l)},[i.createVNode("div",{class:"farris-nav-item-link pt-3"},[i.createVNode("span",{class:"farris-nav-item-link-text"},[typeof l[e.displayField]=="function"?l[e.displayField]():l[e.displayField],l[e.valueField]&&i.createVNode("div",{class:"farris-nav-item-tag"},[l[e.valueField]<=e.maxNum&&i.createVNode("span",{class:"tag-text"},[l[e.valueField]]),l[e.valueField]>e.maxNum&&i.createVNode("span",{class:"tag-text"},[e.maxNum,i.createTextVNode("+")])])]),i.createVNode("div",{class:"farris-nav-item-bottom-line"},null)])]))])}}});br.install=e=>{e.component(br.name,br)};const lc={buttonContent:{type:String,default:'<i class="f-icon f-icon-search"></i>'},customClass:{type:String,default:""},modelValue:{type:String,default:""},popupHost:{type:Object},data:{type:Array,default:()=>[]},placeholder:{type:String,default:"请输入关键词"},idField:{type:String,default:"id"},textField:{type:String,default:"name"},maxHeight:{type:Number,default:350},loading:{type:Boolean,default:!1},disable:{type:Boolean,default:!1},showDropdown:{type:Boolean,default:!0}},dc={data:{type:Array,default:()=>[]},onConfirmResult:{type:Function,default:void 0},onSearchedValue:{type:Function,default:void 0},idField:{type:String,default:"id"},textField:{type:String,default:"name"},maxHeight:{type:Number,default:350},loading:{type:Boolean,default:!1}},pu=i.defineComponent({name:"FXSearchBoxContainer",props:dc,emits:["confirmResult","searchedValue"],setup(e,t){const n=i.ref(e.data),u=i.ref(""),o=i.computed(()=>{if(!u.value)return n.value;const d=u.value.toLowerCase();return n.value.filter(f=>String(f[e.textField]??"").toLowerCase().includes(d))});function r(d){u.value=d}function a(d){t.emit("confirmResult",d[e.textField]),t.emit("searchedValue",[d])}function s(d){return t.slots.default?t.slots.default({item:d}):i.createVNode("span",null,[d[e.textField]])}const c=i.computed(()=>{const d={padding:"8px"};return e.maxHeight!==void 0&&e.maxHeight>0&&(d.maxHeight=`${e.maxHeight}px`),d});return i.watch(()=>e.data,d=>{d!==n.value&&(n.value=d)}),t.expose({search:r}),()=>i.createVNode("div",{class:"search-box-container f-utils-overflow-xhya position-relative",style:c.value},[e.loading&&i.createVNode("div",{class:"search-box-loading"},[i.createVNode("i",{class:"f-icon f-icon-clockwise f-icon-spin"},null)]),i.createVNode("ul",{class:"search-box-list"},[o.value.map(d=>i.createVNode("li",{class:"search-box-item dropdown-item",key:d[e.idField],onClick:()=>a(d)},[s(d)])),!e.loading&&o.value.length===0&&i.createVNode("li",{class:"search-box-empty"},[i.createTextVNode("无匹配结果")])])])}}),yr=i.defineComponent({name:"FXSearchBox",props:lc,emits:["update:modelValue","change","selectedValue","clickButton"],setup(e,t){const n=i.ref(),u=i.ref(),o=i.ref(),r=i.ref(e.modelValue),a=i.ref(!1),s='<i class="f-icon f-icon-clockwise f-icon-spin"></i>',c=i.computed(()=>e.loading?s:e.buttonContent);i.watch(r,w=>{var k;(k=o.value)==null||k.search(w),t.emit("update:modelValue",w)}),i.watch(()=>e.modelValue,w=>{r.value=w});function d(w){r.value=w,h()}function f(w){const k=r.value;t.emit("change",w,{oldValue:k,newValue:w})}function l(w){t.emit("selectedValue",w)}function p(){t.emit("clickButton",{})}async function m(){var w;a.value=!0,await i.nextTick(),(w=u.value)==null||w.show(n.value)}function h(){var w;(w=u.value)==null||w.hide(),a.value=!1}function y(){a.value?h():m()}function x(w){const k=w.target.value;r.value=k,f(k),e.showDropdown&&k&&m()}function v(){e.showDropdown&&r.value&&m()}function g(){r.value="",t.emit("update:modelValue",""),h()}t.expose({togglePopup:y,hidePopup:h,showPopup:m});const b=i.computed(()=>{const w=be({},e.customClass);return["f-search-box",{"f-search-box-disabled":e.disable},...typeof w=="string"?[w]:Array.isArray(w)?w:[]]});return()=>i.createVNode("div",{class:b.value},[i.createVNode("div",{class:"f-search-box-input-group",ref:n},[i.createVNode("input",{class:"f-search-box-input form-control",type:"text",placeholder:e.placeholder,value:r.value,disabled:e.disable,onInput:x,onFocus:v},null),r.value&&!e.disable&&i.createVNode("span",{class:"f-search-box-clear",onClick:g},[i.createVNode("i",{class:"f-icon f-icon-close"},null)]),i.createVNode("span",{class:"f-search-box-button",onClick:p},[i.createVNode("i",{class:"f-icon f-icon-search",innerHTML:c.value},null)])]),e.showDropdown&&i.createVNode(Gt,{ref:u,placement:"bottom-left",keepWidthWithReference:!0,showArrow:!1,fitContent:!0,limitContentBySpace:!0,host:e.popupHost},{default:()=>[i.createVNode(pu,{ref:o,data:e.data,idField:e.idField,textField:e.textField,onConfirmResult:d,onSearchedValue:w=>l(w),loading:e.loading,maxHeight:e.maxHeight},t.slots)]})])}});yr.install=e=>{e.component(yr.name,yr),e.component(pu.name,pu)};const zo={data:{type:Array,default:()=>[]},view:{type:String,default:"ContentView"},customClass:{type:String,default:""},itemClass:{type:[String,Function],default:""},idField:{type:String,default:"id"},textField:{type:String,default:"name"},titleField:{type:String,default:"name"},valueField:{type:String,default:"id"},group:{type:Object,default:void 0}};function cp(e){const t=i.ref([...e.data]),n=i.ref([]),u=i.ref(""),o=i.computed(()=>{var p;const l=e.group;return l!=null&&l.enable&&((p=l.groupFields)!=null&&p.length)?r(t.value,l):t.value.map((m,h)=>({type:0,data:m,originalIndex:h}))});function r(l,p){const m=[],h=p.groupFields[0],y=new Map;l.forEach(v=>{const g=String(v[h]??"");y.has(g)||y.set(g,[]),y.get(g).push(v)});let x=0;return y.forEach((v,g)=>{m.push({type:1,data:{[h]:g},groupField:h,groupValue:g,originalIndex:x++}),v.forEach(b=>{m.push({type:0,data:b,groupField:h,groupValue:g,originalIndex:x++})})}),m}function a(l){t.value=[...l],n.value=[],u.value=""}function s(l){u.value=l;const p=t.value.find(m=>m[e.idField]===l);p&&!n.value.includes(p)&&(n.value=[p])}function c(){n.value=[],u.value=""}function d(l){const p=n.value.indexOf(l);p>=0?n.value.splice(p,1):n.value=[l],u.value=l[e.idField]}function f(l){return n.value.includes(l)}return{data:t,visualData:o,selectedItems:n,activeItemId:u,updateDataSource:a,activeRowById:s,clearSelection:c,toggleSelection:d,isSelected:f}}const lp=i.defineComponent({name:"FXListViewItem",props:{...zo,item:{type:Object,default:()=>({})},index:{type:Number,default:0},isActive:{type:Boolean,default:!1},isSelected:{type:Boolean,default:!1}},emits:["clickItem"],setup(e,t){const n=i.computed(()=>({"f-list-view-item":!0,"f-list-view-item-active":e.isActive}));return()=>i.createVNode("li",{class:[n.value,typeof e.itemClass=="function"?e.itemClass(e.item,e.index):e.itemClass],onClick:()=>t.emit("clickItem",e.item,e.index)},[t.slots.default?t.slots.default({item:e.item,index:e.index,selectedItem:e.isSelected?e.item:null}):i.createVNode("span",null,[e.item[e.textField]])])}}),dp=i.defineComponent({name:"FXListGroupItem",props:{groupData:{type:Object,default:()=>({})},groupField:{type:String,default:""},groupValue:{type:String,default:""},index:{type:Number,default:0}},setup(e,t){return()=>i.createVNode("li",{class:"f-list-view-group-item"},[t.slots.default?t.slots.default({item:e.groupData,index:e.index}):i.createVNode("div",{class:"f-list-view-group-header"},[i.createVNode("i",{class:"f-icon f-accordion-expand"},null),i.createVNode("span",null,[e.groupValue])])])}}),xr=i.defineComponent({name:"FXListView",props:zo,emits:["clickItem"],setup(e,t){const{visualData:n,activeItemId:u,updateDataSource:o,activeRowById:r,clearSelection:a,toggleSelection:s,isSelected:c}=cp({data:e.data,idField:e.idField,group:e.group}),d=i.computed(()=>be({"f-list-view":!0},e.customClass));function f(l,p){s(l),t.emit("clickItem",l,p)}return t.expose({updateDataSource:o,activeRowById:r,clearSelection:a}),()=>i.createVNode("div",{class:d.value},[i.createVNode("div",{class:"f-list-view-content"},[i.createVNode("ul",{class:"f-list-view-items"},[n.value.map((l,p)=>l.type===1?i.createVNode(dp,{key:`group_${l.groupValue}_${p}`,groupData:l.data,groupField:l.groupField,groupValue:l.groupValue,index:p},{default:t.slots.group}):i.createVNode(lp,{key:`${l.data[e.idField]}_${p}`,item:l.data,index:l.originalIndex,isActive:l.data[e.idField]===u.value,isSelected:c(l.data),itemClass:e.itemClass,textField:e.textField,onClickItem:f},{default:t.slots.content}))])])])}});xr.install=e=>{e.component(xr.name,xr)};const jo=i.defineComponent({name:"FXAgentThinkingMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>{const t=e.content,n=t.streamStatus==="end"||t.streamStatus===void 0;return i.createVNode("details",{class:"f-ec-thinking",open:!0},[i.createVNode("summary",{class:"f-ec-thinking-summary"},[i.createTextVNode("思考过程"),n?null:i.createVNode("span",{class:"f-ec-thinking-badge"},[i.createTextVNode("进行中")])]),i.createVNode("div",{class:"f-ec-thinking-body"},[t.text]),t.sources&&t.sources.length>0?i.createVNode("ul",{class:"f-ec-thinking-sources"},[t.sources.map((u,o)=>i.createVNode("li",{key:o},[u]))]):null])}}});function fp(e){return e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:`${(e/(1024*1024)).toFixed(1)} MB`}function hp(e){const t=e.trim();return t.startsWith("http://")||t.startsWith("https://")?t:`#attachment:${encodeURIComponent(t)}`}function pp(e){const t=e.trim();return t.startsWith("http://")||t.startsWith("https://")?{url:t}:{fileId:t}}const fc=i.defineComponent({name:"FXAttachmentFileMessage",props:{content:{type:Object,required:!0}},setup(e){const t=i.computed(()=>hp(e.content.media)),n=i.computed(()=>an(pp(e.content.media)));async function u(o){o.preventDefault(),o.stopPropagation();const r=n.value;r&&await _r(r,e.content.name)}return()=>{const o=!!n.value;return i.createVNode("div",{class:"f-ec-attach-row"},[i.createVNode("a",{class:"f-ec-attach f-ec-attach--stretch",href:t.value,target:"_blank",rel:"noopener noreferrer"},[i.createVNode("span",{class:"f-ec-attach-icon","aria-hidden":!0},[i.createTextVNode("📎")]),i.createVNode("span",{class:"f-ec-attach-body"},[i.createVNode("span",{class:"f-ec-attach-name"},[e.content.name]),i.createVNode("span",{class:"f-ec-attach-meta"},[i.createVNode("span",{class:"f-ec-attach-cat"},[e.content.category]),i.createVNode("span",{class:"f-ec-attach-size"},[fp(e.content.size)])])])]),o?i.createVNode("button",{type:"button",class:"f-ec-attach-download-btn","aria-label":"下载附件",title:"下载",onClick:u},[i.createVNode("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","aria-hidden":"true"},[i.createVNode("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("polyline",{points:"7 10 12 15 17 10","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("line",{x1:"12",y1:"15",x2:"12",y2:"3","stroke-linecap":"round","stroke-linejoin":"round"},null)])]):null])}}}),mp={0:"高",1:"中",2:"低"},hc=i.defineComponent({name:"ErrorReminderMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>{const t=e.content.errorLevel;return i.createVNode("div",{class:["f-ec-error",`f-ec-error--lvl-${t}`]},[i.createVNode("div",{class:"f-ec-error-head"},[i.createVNode("span",{class:"f-ec-error-badge"},[mp[t]]),i.createVNode("span",{class:"f-ec-error-label"},[i.createTextVNode("错误提醒")])]),i.createVNode("div",{class:"f-ec-error-text"},[e.content.errorText]),e.content.errorLink?i.createVNode("a",{class:"f-ec-error-link",href:e.content.errorLink,target:"_blank",rel:"noopener noreferrer"},[i.createTextVNode("查看详情")]):null])}}}),Ho="{{suggestionText}}";function $o(e,t){if(typeof e=="string")return e===Ho?t:e.includes(Ho)?e.split(Ho).join(t):e;if(Array.isArray(e))return e.map(n=>$o(n,t));if(e!==null&&typeof e=="object"){const n={};for(const[u,o]of Object.entries(e))n[u]=$o(o,t);return n}return e}function gp(e,t){var u;const n=(u=e.pickActions)==null?void 0:u[t];return n||e.pickActionDefault}const pc=i.defineComponent({name:"InputRecommendMessage",props:{content:{type:Object,required:!0},onPick:{type:Function,default:void 0}},setup(e){const t=(n,u)=>{var r;const o=gp(e.content,u);if((o==null?void 0:o.sdk)==="AgentWorkbenchSDK"&&o.api){const a=$o(o.params??[],n);Ro(o.api,a)}else Ro("sendChatMessage",[n]);(r=e.onPick)==null||r.call(e,n)};return()=>i.createVNode("div",{class:"f-ec-recommend"},[e.content.title?i.createVNode("div",{class:"f-ec-recommend-title"},[e.content.title]):null,i.createVNode("div",{class:"f-ec-recommend-chips"},[e.content.suggestions.map((n,u)=>i.createVNode("button",{key:u,type:"button",class:"f-ec-recommend-chip",onClick:()=>t(n,u)},[n]))])])}}),mc=i.defineComponent({name:"LinkCardMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>{const t=e.content;return i.createVNode("div",{class:"f-ec-linkcard"},[t.poster?i.createVNode("div",{class:"f-ec-linkcard-poster"},[i.createVNode("img",{src:t.poster,alt:""},null)]):null,i.createVNode("div",{class:"f-ec-linkcard-body"},[i.createVNode("a",{class:"f-ec-linkcard-title",href:t.url,target:"_blank",rel:"noopener noreferrer"},[t.title]),t.subtitle?i.createVNode("div",{class:"f-ec-linkcard-sub"},[t.subtitle]):null,t.relatedLinks&&t.relatedLinks.length>0?i.createVNode("div",{class:"f-ec-linkcard-related"},[i.createVNode("div",{class:"f-ec-linkcard-related-label"},[i.createTextVNode("相关阅读")]),i.createVNode("ul",null,[t.relatedLinks.map((n,u)=>i.createVNode("li",{key:u},[i.createVNode("a",{href:n.url,target:"_blank",rel:"noopener noreferrer"},[n.title])]))])]):null])])}}}),gc=i.defineComponent({name:"ReferenceSourcesMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>i.createVNode("div",{class:"f-ec-sources"},[i.createVNode("div",{class:"f-ec-sources-title"},[i.createTextVNode("引用来源")]),i.createVNode("ul",{class:"f-ec-sources-list"},[e.content.items.map((t,n)=>i.createVNode("li",{key:n},[i.createVNode("a",{href:t.url,target:"_blank",rel:"noopener noreferrer"},[t.title])]))])])}}),zt="__hitl_other__";function mu(e){const t=e??"text";return t==="text"||t==="select"||t==="multi_select"||t==="confirm"||t==="form"||t==="date"||t==="number"?t:"text"}const bc=i.defineComponent({name:"FXHitlQuestion",props:{content:{type:Object,required:!0},disabled:{type:Boolean,default:!1},onSubmitAnswers:{type:Function,default:void 0}},setup(e){const t=i.ref(!1),n=i.ref({}),u=i.ref({});function o(h){const y={},x={};for(const v of h){const g=mu(v.ui_type);g==="confirm"?y[v.id]=v.default_value==="true"||v.default_value==="1":y[v.id]=v.default_value??"",x[v.id]={active:!1,text:""}}n.value=y,u.value=x}i.watch(()=>e.content.questions,h=>{Array.isArray(h)&&h.length&&o(h)},{immediate:!0});const r=i.computed(()=>{var h,y;if(t.value||e.disabled)return!1;for(const x of e.content.questions){const v=mu(x.ui_type),g=n.value[x.id];if(v==="text"&&(typeof g!="string"||g.trim()==="")||v==="select"&&(typeof g!="string"||g.trim()===""||g===zt&&(((y=(h=u.value[x.id])==null?void 0:h.text)==null?void 0:y.trim())??"")==="")||v==="confirm"&&typeof g!="boolean")return!1}return!0});function a(h,y){n.value={...n.value,[h]:y}}function s(h,y){var x;y===zt?(u.value={...u.value,[h.id]:{...u.value[h.id],active:!0,text:((x=u.value[h.id])==null?void 0:x.text)??""}},a(h.id,zt)):(u.value={...u.value,[h.id]:{active:!1,text:""}},a(h.id,y))}function c(){var y,x,v;if(!r.value)return;const h=[];for(const g of e.content.questions){const b=mu(g.ui_type);let w=n.value[g.id];b==="select"&&w===zt&&(w=((x=(y=u.value[g.id])==null?void 0:y.text)==null?void 0:x.trim())??""),h.push({id:g.id,answer:w})}t.value=!0,(v=e.onSubmitAnswers)==null||v.call(e,h)}function d(h){const y=n.value[h.id]??"";return i.createVNode("div",{class:"f-hitl-field",key:h.id},[h.header?i.createVNode("div",{class:"f-hitl-field__header"},[h.header]):null,i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("input",{class:"f-hitl-input",type:"text",value:y,placeholder:h.placeholder??"请输入",disabled:t.value||e.disabled,onInput:x=>a(h.id,x.target.value)},null)])}function f(h,y){const x=n.value[h.id]??"",v=u.value[h.id]??{active:!1,text:""};return i.createVNode("div",{class:"f-hitl-field",key:h.id},[h.header?i.createVNode("div",{class:"f-hitl-field__header"},[h.header]):null,i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("div",{class:"f-hitl-select-group"},[y.map(g=>i.createVNode("button",{key:g.label,type:"button",class:["f-hitl-opt",{"f-hitl-opt--active":x===g.label&&!v.active}],disabled:t.value||e.disabled,onClick:()=>s(h,g.label)},[i.createVNode("span",{class:"f-hitl-opt__label"},[g.label]),g.description?i.createVNode("span",{class:"f-hitl-opt__desc"},[g.description]):null])),h.allow_other?i.createVNode("button",{type:"button",class:["f-hitl-opt",{"f-hitl-opt--active":x===zt||v.active}],disabled:t.value||e.disabled,onClick:()=>s(h,zt)},[i.createTextVNode("其他")]):null]),h.allow_other&&(x===zt||v.active)?i.createVNode("input",{class:"f-hitl-input f-hitl-input--other",type:"text",value:v.text,placeholder:"请输入自定义内容",disabled:t.value||e.disabled,onInput:g=>{const b=g.target.value;u.value={...u.value,[h.id]:{active:!0,text:b}},a(h.id,zt)}},null):null])}function l(h){const y=n.value[h.id];return i.createVNode("div",{class:"f-hitl-field",key:h.id},[h.header?i.createVNode("div",{class:"f-hitl-field__header"},[h.header]):null,i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("div",{class:"f-hitl-confirm"},[i.createVNode("button",{type:"button",class:["f-hitl-cbtn",{"f-hitl-cbtn--primary":y===!0}],disabled:t.value||e.disabled,onClick:()=>a(h.id,!0)},[i.createTextVNode("是")]),i.createVNode("button",{type:"button",class:["f-hitl-cbtn",{"f-hitl-cbtn--primary":y===!1}],disabled:t.value||e.disabled,onClick:()=>a(h.id,!1)},[i.createTextVNode("否")])])])}function p(h){return i.createVNode("div",{class:"f-hitl-field f-hitl-field--unsupported",key:h.id},[i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("div",{class:"f-hitl-unsupported"},[i.createTextVNode("暂不支持 ui_type「"),String(h.ui_type),i.createTextVNode("」,请升级前端。")])])}function m(h){const y=mu(h.ui_type);if(y==="text")return d(h);if(y==="select"){const x=Array.isArray(h.options)?h.options:[];return x.length===0?p({...h,ui_type:"text"}):f(h,x)}return y==="confirm"?l(h):p(h)}return()=>i.createVNode("div",{class:"f-hitl-card"},[i.createVNode("div",{class:"f-hitl-card__meta"},[i.createVNode("span",{class:"f-hitl-chip"},[i.createTextVNode("人机协同")])]),i.createVNode("div",{class:"f-hitl-card__body"},[e.content.questions.map(h=>m(h))]),i.createVNode("div",{class:"f-hitl-card__footer"},[i.createVNode("button",{type:"button",class:"f-hitl-submit",disabled:!r.value,onClick:c},[t.value?"已提交":"提交回答"])])])}}),yc=i.defineComponent({name:"UnknownEnterpriseMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>i.createVNode("div",{class:"f-ec-unknown"},[i.createVNode("div",{class:"f-ec-unknown-title"},[i.createTextVNode("未知类型消息")]),e.content.wireType?i.createVNode("div",{class:"f-ec-unknown-wire"},[i.createTextVNode("wire type: "),e.content.wireType]):null,i.createVNode("div",{class:"f-ec-unknown-desc"},[e.content.hint??"客户端无法识别此消息类型,已按占位展示。"])])}}),bp=[jo,fc,hc,bc,pc,mc,gc,Xt,yc,ho];jo.install=e=>{for(const t of bp)e.component(t.name,t)};const yp={install(e){e.use(on).use(Qn).use(Jn).use(rr).use(ur).use(sr).use(cr).use(lr).use(dr).use(hn).use(Kt).use(An).use(qt).use(fr).use(hr).use(pr).use(mr).use(bn).use(yn).use(Gt).use(xn).use(gr).use(br).use(yr).use(xr)}};T.AgentWorkbenchSDK=Po,T.FXAccordion=gr,T.FXAccordionItem=Bo,T.FXAgentThinking=jo,T.FXAppPreview=on,T.FXAttachmentFile=fc,T.FXAttachmentPreview=mr,T.FXBubble=Qn,T.FXBubbleAction=po,T.FXCarousel=Jn,T.FXCarouselItem=tu,T.FXChatPreview=rr,T.FXCoding=sr,T.FXConfirmDialog=ur,T.FXDynamicComponent=yn,T.FXErrorReminder=hc,T.FXFileOperation=cr,T.FXGenerateProcess=lr,T.FXHistory=dr,T.FXHitlQuestion=bc,T.FXInputRecommend=pc,T.FXLinkCard=mc,T.FXListView=xr,T.FXMarkdown=hn,T.FXMarkdownPreview=Kt,T.FXNav=br,T.FXPopover=Gt,T.FXPopoverDirective=Ma,T.FXPrompt=hu,T.FXPrompts=An,T.FXReferenceSources=gc,T.FXSearchBox=yr,T.FXSearchBoxContainer=pu,T.FXSplitter=xn,T.FXSplitterPane=er,T.FXStartedTodo=qt,T.FXSuggestion=fr,T.FXTodo=hr,T.FXTodoListItemView=eu,T.FXTodoListView=Kn,T.FXToolUse=Xt,T.FXUnknownEnterprise=yc,T.FXUserAuth=ho,T.FXWelcome=pr,T.FXWidgetContainer=bn,T.PREVIEW_BRIDGE_MESSAGE_TYPE_ASSISTANT=Oo,T.PREVIEW_BRIDGE_SOURCE=No,T.PREVIEW_BRIDGE_VERSION=Lo,T.accordionItemProps=sc,T.accordionProps=ac,T.appPreviewMessageProps=Er,T.attachmentPreviewProps=oc,T.bubbleActionProps=Ha,T.bubbleProps=ri,T.carouselItemProps=Ua,T.carouselProps=$a,T.chatHistoryProps=Qs,T.chatPreviewProps=Ga,T.clonePreviewPayloadForPostMessage=Ts,T.codingMessageProps=Xs,T.confirmDialogProps=Vs,T.createPreviewIframeSdk=c2,T.default=yp,T.extractFileIdFromRuntimeDownloadUrl=ui,T.fileOperationMessageProps=Ys,T.generateProcessProps=Ks,T.getCustomClass=be,T.getCustomStyle=Ae,T.invokeAgentWorkbenchSdkApi=Ro,T.isImageUrl=oi,T.isPreviewBridgeAssistantMessage=Ls,T.listViewProps=zo,T.loadDynamicComponent=La,T.markdownMessageProps=da,T.markdownPreviewProps=qa,T.navProps=cc,T.popoverProps=Pa,T.postAssistantViaAgentWorkbenchSDK=Io,T.promptProps=tc,T.promptsProps=Js,T.registerPreviewChromeSdk=n2,T.renderIconNode=Sr,T.renderNode=In,T.resolveHrefForAttachmentDownload=an,T.resolveRuntimeAttachmentDownloadUrl=_u,T.searchBoxContainerProps=dc,T.searchBoxProps=lc,T.sendChatMessageViaAgentWorkbenchSDK=Is,T.splitterProps=Wa,T.startedTodoProps=Ba,T.subscribeAssistantViaAgentWorkbenchSDK=Ps,T.suggestionProps=nc,T.todoListItemProps=ja,T.todoListViewProps=za,T.todoProps=rc,T.triggerAttachmentDownload=_r,T.unloadDynamicComponent=Oa,T.useSequentialStreaming=Fr,T.useStreamingOutput=ii,T.useTimer=Su,T.welcomeProps=uc,T.widgetContainerProps=Ta,Object.defineProperties(T,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
155
+ `).length:0;v=_?W+E:E}return rp+v*qs}const d=i.computed(()=>(o.value,c()>wn));function f(){n.value=!n.value,r.value=n.value?c():wn,p()}function l(){if(!o.value)return;o.value=null;const x=()=>{};typeof requestIdleCallback<"u"?requestIdleCallback(x,{timeout:100}):setTimeout(x,0)}function p(){if(a.value)return;const h=u.value,x=o.value;if(!h||!(x!=null&&x.layout))return;const y=h.clientWidth||h.offsetWidth,v=r.value;requestAnimationFrame(()=>{var g,b;a.value||!o.value||(b=(g=o.value)==null?void 0:g.layout)==null||b.call(g,{width:y,height:v})})}function m(){var h;a.value||!u.value||!((h=e.content)!=null&&h.code)||np.init().then(x=>{var w;if(a.value||!u.value||!((w=e.content)!=null&&w.code))return;const{value:y,originalValue:v,language:g="typescript"}=e.content.code,b={readOnly:!0,minimap:{enabled:!1},scrollBeyondLastLine:!1,lineNumbers:"off",glyphMargin:!1,lineDecorationsWidth:0,folding:!1,renderLineHighlight:"none",fontSize:12,lineHeight:qs,padding:{top:8,bottom:8}};if(v){const k=x.editor.createDiffEditor(u.value,{...b,renderSideBySide:!1,renderOverviewRuler:!1});k.setModel({original:x.editor.createModel(v,g),modified:x.editor.createModel(y,g)}),k.getOriginalEditor().updateOptions({minimap:{enabled:!1}}),k.getModifiedEditor().updateOptions({minimap:{enabled:!1}}),i.nextTick(()=>{var _;if(a.value)return;const S=(_=k.getContainerDomNode)==null?void 0:_.call(k);if(S){const E=S.querySelector('.diff-editor-cell.original, [class*="original"]');E&&(E.style.display="none")}}),o.value=k}else{const k=x.editor.create(u.value,{value:y,language:g,...b});o.value=k}r.value=wn,i.nextTick(()=>p())})}return i.onMounted(()=>{up(()=>{a.value||!u.value||m()})}),i.watch(t,h=>{h&&!a.value&&i.nextTick(()=>p())}),i.onBeforeUnmount(()=>{a.value=!0,l()}),i.watch(()=>{var h,x;return(x=(h=e.content)==null?void 0:h.code)==null?void 0:x.value},()=>{a.value||(n.value?r.value=c():r.value=wn,p())}),()=>{const h=e.content;if(!h)return null;const{message:x,fileIcon:y,fileName:v,code:g}=h;return i.createVNode("div",{class:"f-chat-message-coding"},[i.createVNode("div",{class:"f-chat-coding-message"},[x]),i.createVNode("div",{class:"f-chat-coding-card"},[i.createVNode("div",{class:"f-chat-coding-header",onClick:s,role:"button",tabindex:0,onKeydown:b=>b.key==="Enter"&&s()},[i.createVNode("span",{class:"f-chat-coding-header-icon-slot"},[i.createVNode("span",{class:"f-chat-coding-header-icon"},[i.createVNode("img",{src:y,alt:"",onError:b=>{var w;b.target.style.display="none",(w=b.target.parentElement)==null||w.classList.add("icon-error")}},null),i.createVNode("span",{class:"f-chat-coding-header-icon-fallback"},[i.createTextVNode("📄")])]),i.createVNode("span",{class:"f-chat-coding-header-expand"},[i.createVNode("i",{class:t.value?"fx-icon fx-icon-expanddown":"fx-icon fx-icon-arrow-right"},null)])]),i.createVNode("span",{class:"f-chat-coding-header-filename"},[v]),i.createVNode("span",{class:"f-chat-coding-header-stats"},[i.createVNode("span",{class:"f-chat-coding-stat-add"},[i.createTextVNode("+"),g.addedLines]),i.createVNode("span",{class:"f-chat-coding-stat-del"},[i.createTextVNode("-"),g.deletedLines])])]),i.createVNode("div",{style:{display:t.value?"block":"none"}},[i.createVNode("div",{ref:u,class:"f-chat-coding-editor",style:{height:`${r.value}px`}},null),d.value&&i.createVNode("button",{type:"button",class:"f-chat-coding-expand-btn",onClick:f,"aria-label":n.value?"收起代码":"展开代码",title:n.value?"收起代码":"展开代码"},[i.createVNode("i",{class:["fx-icon fx-icon-expanddown",n.value&&"f-chat-coding-expand-icon-up"]},null)])])])])}}});sr.install=e=>{e.component(sr.name,sr)};const Xs={content:{type:Object,required:!0}};function op(e){return"file"in e&&"path"in e}const cr=i.defineComponent({name:"FileOperationMessage",props:Xs,setup(e){const t=i.ref(!0),n=i.ref({}),u=i.computed(()=>{var c;return!!((c=e.content)!=null&&c.summary)}),o=i.computed(()=>{var d;const c=(d=e.content)==null?void 0:d.summary;return c?`浏览了 ${c.explored} 个文件并查询了 ${c.searched} 个文件`:""});function r(){t.value=!t.value}function a(c){n.value={...n.value,[c]:!n.value[c]}}function s(c){return n.value[c]??!1}return()=>{const c=e.content;if(!c)return null;const{summary:d,operations:f}=c,l=!u.value||t.value;return i.createVNode("div",{class:"f-chat-message-file-operation"},[d&&i.createVNode("div",{class:"f-chat-file-op-summary",onClick:r,role:"button",tabindex:0,onKeydown:p=>p.key==="Enter"&&r()},[i.createVNode("span",{class:"f-chat-file-op-summary-inner"},[i.createVNode("span",{class:"f-chat-file-op-summary-text"},[o.value]),i.createVNode("span",{class:["f-chat-file-op-expand-btn",{expanded:t.value}]},[i.createVNode("i",{class:t.value?"fx-icon fx-icon-expanddown":"fx-icon fx-icon-arrow-right"},null)])])]),l&&i.createVNode("div",{class:"f-chat-file-op-operations"},[f.map((p,m)=>{var h,x,y,v;return i.createVNode("div",{key:m,class:"f-chat-file-op-operation"},[i.createVNode("div",i.mergeProps({class:["f-chat-file-op-operation-row",{"op-read":p.type==="Read","has-details":!!((h=p.details)!=null&&h.length)}],onClick:()=>{var g;return((g=p.details)==null?void 0:g.length)&&a(m)}},(x=p.details)!=null&&x.length?{role:"button",tabIndex:0}:{},{onKeydown:g=>{var b;return((b=p.details)==null?void 0:b.length)&&g.key==="Enter"&&a(m)}}),[i.createVNode("span",{class:"f-chat-file-op-type"},[p.type]),i.createVNode("span",{class:"f-chat-file-op-message-wrap"},[i.createVNode("span",{class:"f-chat-file-op-message"},[p.message]),(y=p.details)!=null&&y.length?i.createVNode("span",{class:["f-chat-file-op-expand-btn","sm",{expanded:s(m)}]},[i.createVNode("i",{class:s(m)?"fx-icon fx-icon-expanddown":"fx-icon fx-icon-arrow-right"},null)]):null])]),((v=p.details)==null?void 0:v.length)&&s(m)&&i.createVNode("div",{class:"f-chat-file-op-details"},[p.details.map((g,b)=>op(g)?i.createVNode("div",{key:b,class:"f-chat-file-op-detail-file"},[i.createVNode("span",{class:"f-chat-file-op-file-icon"},[i.createVNode("img",{src:g.icon,alt:"",onError:w=>{const k=w.target;k.style.display="none";const S=k.parentElement;S&&S.classList.add("icon-error")}},null),i.createVNode("span",{class:"f-chat-file-op-file-icon-fallback"},[i.createTextVNode("📄")])]),i.createVNode("span",{class:"f-chat-file-op-file-name"},[g.file]),i.createVNode("span",{class:"f-chat-file-op-file-path",title:g.path},[g.path])]):i.createVNode("div",{key:b,class:"f-chat-file-op-detail-text"},[i.createVNode("div",{class:"f-chat-file-op-detail-title"},[g.title]),i.createVNode("div",{class:"f-chat-file-op-detail-content"},[g.text])]))])])})])])}}});cr.install=e=>{e.component(cr.name,cr)};const Zs={visible:{type:Boolean,default:!0},description:[String,Object],progress:{type:Number,default:0},showProgress:{type:Boolean,default:!0},icon:{type:[String,Object],default:""},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})}},ip="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='60px'%20height='60px'%20viewBox='0%200%2060%2060'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3ctitle%3e智能logo60px%3c/title%3e%3cdefs%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-1'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%231EBBC6'%20offset='58.0673923%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cpath%20d='M25.1971977,0%20L45.8523137,11.3712178%20L45.8523137,37.6155801%20L44.4946453,38.9692599%20L24.623,28.022%20L24.6233274,49.9395377%20L21.4535582,49.9395377%20L2.72549351,39.5965647%20L0,34.4406135%20L0,12.8076673%20L3.70534859,10.5019677%20L20.556,20.546%20L20.5567534,0.161454345%20L25.1971977,0%20Z%20M20.7578212,28.1498874%20L5.81325199,36.7628182%20L20.7578212,45.0027895%20L20.7578212,28.1498874%20Z%20M41.8027832,15.9256338%20L26.7716137,24.6706076%20L41.8027832,32.9879669%20L41.8027832,15.9256338%20Z%20M4.06159924,15.4742393%20L4.06159924,32.9879669%20L19.1488772,24.4568004%20L4.06159924,15.4742393%20Z%20M24.6233274,4.32908173%20L24.6233274,21.2862528%20L39.8727429,12.4882393%20L24.6233274,4.32908173%20Z'%20id='path-2'%3e%3c/path%3e%3clinearGradient%20x1='81.0966666%25'%20y1='38.5584607%25'%20x2='28.8545509%25'%20y2='61.9626707%25'%20id='linearGradient-4'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-5'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='44.8152906%25'%20y1='77.6521765%25'%20x2='44.8152906%25'%20y2='3.26462903%25'%20id='linearGradient-6'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-7'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='3.93796935%25'%20y1='32.607826%25'%20x2='78.9687461%25'%20y2='60.0462823%25'%20id='linearGradient-8'%3e%3cstop%20stop-color='%23FFFFFF'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3cfilter%20x='0.0%25'%20y='0.0%25'%20width='100.0%25'%20height='100.0%25'%20filterUnits='objectBoundingBox'%20id='filter-9'%3e%3cfeGaussianBlur%20stdDeviation='0'%20in='SourceGraphic'%3e%3c/feGaussianBlur%3e%3c/filter%3e%3clinearGradient%20x1='56.0769337%25'%20y1='45.0797149%25'%20x2='24.9463054%25'%20y2='71.1433818%25'%20id='linearGradient-10'%3e%3cstop%20stop-color='%23159BD7'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='10.434388%25'%20y1='68.063656%25'%20x2='86.6988821%25'%20y2='30.8651063%25'%20id='linearGradient-11'%3e%3cstop%20stop-color='%2321C6C1'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%23FFFFFF'%20stop-opacity='0'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3clinearGradient%20x1='50%25'%20y1='0%25'%20x2='50%25'%20y2='100%25'%20id='linearGradient-12'%3e%3cstop%20stop-color='%230D7FE6'%20offset='0%25'%3e%3c/stop%3e%3cstop%20stop-color='%232AE7AF'%20offset='100%25'%3e%3c/stop%3e%3c/linearGradient%3e%3c/defs%3e%3cg%20id='页面-1'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='生成过程'%20transform='translate(-766,%20-1268)'%3e%3cg%20id='编组-7'%20transform='translate(321,%20699)'%3e%3cg%20id='编组-5'%20transform='translate(247,%20488)'%3e%3cg%20id='智能logo60px'%20transform='translate(198,%2081)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='60'%20height='60'%3e%3c/rect%3e%3cg%20id='编组-35'%20transform='translate(0.8571,%200.8571)'%3e%3crect%20id='矩形'%20x='0'%20y='0'%20width='58.2857143'%20height='58.2857143'%3e%3c/rect%3e%3cg%20id='编组-19备份-17'%20transform='translate(3.4286,%201.7143)'%3e%3cpath%20d='M27.9148216,2.78182535%20L48.5699376,14.1530432%20L48.5699376,40.3974054%20L47.2122691,41.7510852%20L27.3406238,30.8038254%20L27.3409512,52.7213631%20L24.171182,52.7213631%20L5.44311735,42.3783901%20L2.71762384,37.2224388%20L2.71762384,15.5894926%20L6.42297243,13.283793%20L23.2736238,23.3278254%20L23.2743772,2.9432797%20L27.9148216,2.78182535%20Z%20M23.4754451,30.9317128%20L8.53087583,39.5446435%20L23.4754451,47.7846148%20L23.4754451,30.9317128%20Z%20M44.520407,18.7074592%20L29.4892375,27.452433%20L44.520407,35.7697922%20L44.520407,18.7074592%20Z%20M6.77922307,18.2560647%20L6.77922307,35.7697922%20L21.866501,27.2386257%20L6.77922307,18.2560647%20Z%20M27.3409512,7.11090709%20L27.3409512,24.0680782%20L42.5903667,15.2700646%20L27.3409512,7.11090709%20Z'%20id='形状结合'%20fill='url(%23linearGradient-1)'%3e%3c/path%3e%3cg%20id='路径-2-+-路径-3-+-路径-4蒙版'%20transform='translate(2.7176,%202.7818)'%3e%3cmask%20id='mask-3'%20fill='white'%3e%3cuse%20xlink:href='%23path-2'%3e%3c/use%3e%3c/mask%3e%3cuse%20id='蒙版'%20fill='url(%23linearGradient-1)'%20xlink:href='%23path-2'%3e%3c/use%3e%3cpolygon%20id='路径-2'%20fill='url(%23linearGradient-4)'%20filter='url(%23filter-5)'%20mask='url(%23mask-3)'%20points='14.177196%2023.2632694%2022.5796859%2023.2632694%2023.4218687%2027.5957059%209.52757789%2036.9780352%203.7254788%2029.0812693'%3e%3c/polygon%3e%3cpolygon%20id='路径-3'%20fill='url(%23linearGradient-6)'%20filter='url(%23filter-7)'%20mask='url(%23mask-3)'%20points='23.4218687%2022.4125055%2027.1161878%2015.1091341%2027.8042533%206.35665145%2018.1506617%205.88610282%2018.8417696%2016.8706238%2022.5796859%2022.4125055'%3e%3c/polygon%3e%3cpolygon%20id='路径-4'%20fill='url(%23linearGradient-8)'%20filter='url(%23filter-9)'%20mask='url(%23mask-3)'%20points='33.5501273%2024.6706076%2024.403058%2024.9983902%2024.403058%2027.5289361%2028.4733448%2033.3539069%2036.4355638%2036.3335669%2041.6970622%2028.387534'%3e%3c/polygon%3e%3c/g%3e%3cpath%20d='M27.9148216,2.78182535%20L48.5699376,14.1530432%20L48.5699376,40.3974054%20L47.2122691,41.7510852%20L23.2743772,28.5628437%20L23.2743772,2.9432797%20L27.9148216,2.78182535%20Z%20M27.3409512,7.11090709%20L27.3409512,24.0680782%20L28.3053772,23.5108254%20L28.3061985,25.7112082%20L30.1053772,27.0928254%20L29.4892375,27.452433%20L44.520407,35.7697922%20L44.5203772,18.7198254%20L45.4350062,17.1793767%20L42.5903667,15.2700646%20L27.3409512,7.11090709%20Z'%20id='形状结合'%20fill='url(%23linearGradient-10)'%20fill-rule='nonzero'%3e%3c/path%3e%3cpolygon%20id='路径'%20fill='url(%23linearGradient-11)'%20fill-rule='nonzero'%20points='22.5927693%2026.8440709%2023.6315003%2030.8033921%208.53087583%2039.5446435%207.30516741%2035.4601402'%3e%3c/polygon%3e%3cg%20id='编组-21'%20fill='url(%23linearGradient-12)'%3e%3cpath%20d='M25.4312165,33.1398658%20C28.857043,33.1398658%2031.634224,30.3626848%2031.634224,26.9368583%20C31.634224,23.5110318%2028.857043,20.7338508%2025.4312165,20.7338508%20C22.00539,20.7338508%2019.228209,23.5110318%2019.228209,26.9368583%20C19.228209,30.3626848%2022.00539,33.1398658%2025.4312165,33.1398658%20Z%20M46.5950591,20.103577%20C49.2645342,20.103577%2051.4285714,17.9395398%2051.4285714,15.2700646%20C51.4285714,12.6005895%2049.2645342,10.4365523%2046.5950591,10.4365523%20C43.9255839,10.4365523%2041.7615467,12.6005895%2041.7615467,15.2700646%20C41.7615467,17.9395398%2043.9255839,20.103577%2046.5950591,20.103577%20Z%20M25.4312165,54.9048659%20C28.1006917,54.9048659%2030.2647289,52.7408287%2030.2647289,50.0713536%20C30.2647289,47.4018784%2028.1006917,45.2378412%2025.4312165,45.2378412%20C22.7617413,45.2378412%2020.5977042,47.4018784%2020.5977042,50.0713536%20C20.5977042,52.7408287%2022.7617413,54.9048659%2025.4312165,54.9048659%20Z%20M4.83351235,43.462539%20C7.50298751,43.462539%209.6670247,41.2985018%209.6670247,38.6290267%20C9.6670247,35.9595515%207.50298751,33.7955143%204.83351235,33.7955143%20C2.16403719,33.7955143%200,35.9595515%200,38.6290267%20C0,41.2985018%202.16403719,43.462539%204.83351235,43.462539%20Z%20M25.4312165,8.37808808%20C27.7447616,8.37808808%2029.6202605,6.50258918%2029.6202605,4.18904404%20C29.6202605,1.8754989%2027.7447616,0%2025.4312165,0%20C23.1176714,0%2021.2421725,1.8754989%2021.2421725,4.18904404%20C21.2421725,6.50258918%2023.1176714,8.37808808%2025.4312165,8.37808808%20Z%20M46.5950591,43.3044363%20C48.9086042,43.3044363%2050.7841031,41.4289374%2050.7841031,39.1153922%20C50.7841031,36.8018471%2048.9086042,34.9263482%2046.5950591,34.9263482%20C44.2815139,34.9263482%2042.406015,36.8018471%2042.406015,39.1153922%20C42.406015,41.4289374%2044.2815139,43.3044363%2046.5950591,43.3044363%20Z%20M4.83351235,18.3420872%20C7.14705749,18.3420872%209.02255639,16.4665883%209.02255639,14.1530432%20C9.02255639,11.8394981%207.14705749,9.96399915%204.83351235,9.96399915%20C2.51996721,9.96399915%200.644468314,11.8394981%200.644468314,14.1530432%20C0.644468314,16.4665883%202.51996721,18.3420872%204.83351235,18.3420872%20Z'%20id='形状结合'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",lr=i.defineComponent({name:"FXGenerateProcess",props:Zs,emits:["closed"],setup(e,t){const n=i.computed(()=>{const d={"fx-generate-process":!0,"fx-generate-process--no-progress":!e.showProgress};return be(d,e.customClass)}),u=i.computed(()=>Ae({},e.customStyle));function o(){var d,f;return t.slots.icon?t.slots.icon():i.createVNode("div",{class:["fx-generate-process--icon",(d=e.classNames)==null?void 0:d.icon],style:(f=e.styles)==null?void 0:f.icon},[e.icon?Sr(e.icon):i.createVNode("img",{alt:"ai logo",class:"fx-generate-process--icon-default",src:ip},null)])}function r(){var d,f;return e.description&&i.createVNode("p",{class:["fx-generate-process--description",(d=e.classNames)==null?void 0:d.description],style:(f=e.styles)==null?void 0:f.description},[e.description])}function a(){var d,f;return e.progress>0&&i.createVNode("div",{class:["fx-generate-process--progress-text",(d=e.classNames)==null?void 0:d["progress-text"]],style:(f=e.styles)==null?void 0:f["progress-text"]},[e.progress,i.createTextVNode("%")])}function s(){return i.createVNode("div",{class:"fx-generate-process--mask",onClick:d=>{d.stopPropagation()}},null)}function c(d=()=>{}){t.emit("closed",{callback:d})}return i.watch(()=>e.visible,d=>{d||c()}),t.expose({close:c}),()=>{var d,f;return i.createVNode(i.Fragment,null,[e.visible&&s(),e.visible&&i.createVNode("div",{class:n.value,style:u.value},[o(),!e.showProgress&&r(),e.showProgress&&i.createVNode("div",{class:["fx-generate-process--progress-bar",(d=e.classNames)==null?void 0:d["progress-bar"]],style:(f=e.styles)==null?void 0:f["progress-bar"]},[i.createVNode("div",{class:"fx-generate-process--progress-fill",style:{width:`${e.progress}%`}},null),!e.description&&a()]),e.description&&e.progress>0&&i.createVNode("div",{class:"fx-generate-process--progress"},[r(),i.createTextVNode(" "),a()])])])}}});lr.install=e=>{e.component(lr.name,lr)};const Ys={title:{type:String,default:"历史对话"},items:{type:Array,default:()=>[]}},ap=[{key:"today",label:"今天"},{key:"week",label:"近7天"},{key:"older",label:"更早"}],dr=i.defineComponent({name:"FXChatHistory",props:Ys,emits:["itemClick"],setup(e,{emit:t}){const n=a=>{const s=new Date(a),c=new Date;return s.getDate()===c.getDate()&&s.getMonth()===c.getMonth()&&s.getFullYear()===c.getFullYear()},u=a=>{const s=new Date(a),c=new Date;return c.setDate(c.getDate()-7),s>=c&&!n(a)},o=i.computed(()=>{var c;const a={today:[],week:[],older:[]};(c=e.items)==null||c.forEach(d=>{n(d.timestamp)?a.today.push(d):u(d.timestamp)?a.week.push(d):a.older.push(d)});const s=(d,f)=>f.timestamp-d.timestamp;return a.today.sort(s).length||a.week.sort(s).length||a.older.sort(s).length?{today:a.today.sort(s),week:a.week.sort(s),older:a.older.sort(s)}:null}),r=(a,s)=>s.length>0&&i.createVNode("div",{class:"f-chat-history-section"},[i.createVNode("span",{class:"f-chat-history-section-header"},[a]),i.createVNode("div",{class:"d-flex flex-column"},[s.map(c=>i.createVNode("div",{key:c.id,class:"f-chat-history-item",onClick:()=>t("itemClick",c)},[i.createVNode("span",{class:"f-chat-history-item-title"},[c.title])]))])]);return()=>i.createVNode("div",{class:"f-chat-history-manager"},[i.createVNode("div",{class:"f-chat-history-manager-scroll"},[o.value&&ap.map(a=>r(a.label,o.value[a.key]))])])}});dr.install=e=>{e.component(dr.name,dr)};const Ks={items:{type:Array,default:()=>[]},title:{type:[String,Object],default:""},vertical:{type:Boolean,default:!1},wrap:{type:Boolean,default:!1},gap:{type:[String,Number],default:12},fadeIn:{type:Boolean,default:!1},fadeInLeft:{type:Boolean,default:!1},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""}};var Qs=(e=>(e.standardFeatureCard="standard-feature-card",e.primaryFeatureCard="primary-feature-card",e.compactFeatureCard="compact-feature-card",e.standardQuestionItem="standard-question-item",e.functionEntryItem="function-entry-item",e.defaultTextItem="default-text-item",e.hasNestEntryItem="has-nest-entry-item",e.likeButtonEntryItem="like-button-entry-item",e.none="",e))(Qs||{});const Js={id:{type:[String,Number],default:""},icon:{type:[String,Object],default:""},label:{type:[String,Object],default:""},description:{type:[String,Object],default:""},badge:{type:[String,Object],default:""},disabled:{type:Boolean,default:!1},children:{type:Array,default:()=>[]},styles:{type:Object},classNames:{type:Object},customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},showType:{type:String,default:Qs.defaultTextItem},gap:{type:[String,Number]},onClick:{type:Function,required:!1}},fu=i.defineComponent({name:"FPrompt",props:Js,setup(e){const t=i.computed(()=>!e.id&&e.children&&e.children.length>0),n=i.computed(()=>{var p;let l={"fx-prompt--item-wrapper":!0,"fx-prompt--item-disabled":e.disabled,"fx-prompt--item-has-nest":e.id&&e.children&&e.children.length>0};return l=be(l,(p=e.classNames)==null?void 0:p.item),be(l,e.customClass)}),u=i.computed(()=>{let l={"fx-prompt--item":!0};return l[`fx-prompt--${e.showType||"none"}`]=!0,l}),o=i.computed(()=>{var p;const l=Ae({},(p=e.styles)==null?void 0:p.item);return Ae(l,e.customStyle)}),r=()=>{var l,p;return e.icon?i.createVNode("div",{class:["fx-prompt--item-icon",(l=e.classNames)==null?void 0:l.icon],style:(p=e.styles)==null?void 0:p.icon},[Sr(e.icon)]):null},a=()=>{var l,p;return e.label?i.createVNode("h6",{class:["fx-prompt--item-label",(l=e.classNames)==null?void 0:l.label],style:(p=e.styles)==null?void 0:p.label},[In(e.label)]):null};function s(){var p;const l={"fx-prompt--item-badge":!0};return typeof e.badge=="string"&&(l["badge-default"]=!0),be(l,(p=e.classNames)==null?void 0:p.badge)}const c=()=>{var l;return e.badge?i.createVNode("span",{class:s(),style:(l=e.styles)==null?void 0:l.badge},[In(e.badge)]):null},d=()=>{var l,p;return e.description?i.createVNode("p",{class:["fx-prompt--item-description",(l=e.classNames)==null?void 0:l.description],style:(p=e.styles)==null?void 0:p.description},[In(e.description)]):null},f=()=>{var l,p,m,h;return!e.children||e.children.length===0?null:i.createVNode(vn,{class:{"fx-prompt--only-children":!e.id,"fx-prompt--item-nested":e.id},gap:e.gap,items:e.children,vertical:!0,customClass:(l=e.classNames)==null?void 0:l.subItems,customStyle:(p=e.styles)==null?void 0:p.subItems,styles:{item:((m=e.styles)==null?void 0:m.subItem)??{}},classNames:{item:((h=e.classNames)==null?void 0:h.subItem)??""}},null)};return()=>{var l,p;return i.createVNode("div",{class:n.value,style:o.value,onClick:e.onClick},[t.value?f():i.createVNode("div",{class:u.value},[r(),c(),i.createVNode("div",{class:["fx-prompt--item-content",(l=e.classNames)==null?void 0:l.itemContent],style:(p=e.styles)==null?void 0:p.itemContent},[a(),d(),f()])])])}}}),vn=i.defineComponent({name:"FXPrompts",props:Ks,emits:["item-click"],setup(e,t){const n=i.computed(()=>{var f;let d={"fx-prompts":!0,"fx-prompts--fade-in":e.fadeIn,"fx-prompts--fade-in-left":e.fadeInLeft};return d=be(d,e.customClass),d=be(d,(f=e.classNames)==null?void 0:f.root),d});function u(d=null){var l;let f={"fx-prompts--items":!0,"fx-prompt":!0,"fx-prompts--items-wrap":e.wrap,"fx-prompts--items-vertical":e.vertical};return f=be(f,(l=e.classNames)==null?void 0:l.items),f=be(f,d==null?void 0:d.customClass),f}function o(d=null){var l;let f={};return(e.gap||e.gap===0)&&(f.gap=typeof e.gap=="number"?`${e.gap}px`:e.gap),f=Ae(f,(l=e.styles)==null?void 0:l.items),f=Ae(f,d==null?void 0:d.customStyle),f}const r=(d,f)=>{f.disabled||f.children&&f.children.length>0||t.emit("item-click",d,f)},a=d=>{var f,l;return d!=null&&d.title?i.createVNode("h5",{class:["fx-prompts--title",(f=e.classNames)==null?void 0:f.title],style:(l=e.styles)==null?void 0:l.title},[In(d==null?void 0:d.title)]):null};function s(d){return!d.items||d.items.length===0?null:i.createVNode("div",{class:u(d),style:o(d)},[d.items.map((f,l)=>i.createVNode(fu,{key:f.id||`key_${l}`,id:f.id,icon:f.icon,label:f.label,description:f.description,disabled:f.disabled,children:f.children,styles:f.styles||e.styles,classNames:f.classNames||e.classNames,showType:f.showType,customClass:f.customClass,customStyle:f.customStyle,gap:f.gap,badge:f.badge,onClick:p=>r(p,f)},null))])}function c(){return t.slots.footer?t.slots.footer():null}return()=>{var d;return i.createVNode("div",{class:n.value,style:(d=e.styles)==null?void 0:d.root},[t.slots.title&&t.slots.title(),a(e),t.slots.default&&t.slots.default(),s(e),c()])}}});vn.install=e=>{e.component(vn.name,vn),e.component(fu.name,fu)};const ec={items:{type:Array,default:()=>[]},height:{type:Number,default:200},title:{type:[String,Object],default:"推荐操作"},prompt:{type:[String,Object],default:"输入@获取推荐操作"},promptChar:{type:String,default:"@"},promptAgentName:{type:String,default:"AI助理"}},fr=i.defineComponent({name:"FXSuggestion",props:ec,setup(e,t){const n=i.ref(null),u=i.ref(!1),o=i.ref(!1),r=i.ref({top:0,left:0,height:0}),a=i.ref(-1),s=i.ref(""),c=i.computed(()=>typeof e.prompt=="string"?e.prompt:"输入“@”获取推荐操作"),d=i.computed(()=>{var v;return(((v=e.items)==null?void 0:v.length)??0)===0}),f=()=>{var W;if(!n.value||d.value)return;if((((W=n.value.textContent)==null?void 0:W.trim())||"")===""){n.value.textContent="",n.value.innerHTML="",x();return}const g=window.getSelection();if(!g||g.rangeCount===0)return;const b=g.getRangeAt(0),w=b.cloneRange();w.selectNodeContents(n.value),w.setEnd(b.endContainer,b.endOffset);const k=w.toString(),S=k.lastIndexOf(e.promptChar);if(s.value=n.value.textContent||"",S!==-1&&k.substring(S+1).trim()===""&&(n.value.textContent=k.replace(/@$/,`@${e.promptAgentName} `),s.value=n.value.textContent,u.value=!0,b.selectNodeContents(n.value),b.collapse(!1),g.removeAllRanges(),g.addRange(b)),u.value===!1){o.value=!1,a.value=-1;return}if((n.value.textContent||"").lastIndexOf(`@${e.promptAgentName} `)!==-1){const V=document.createRange();V.setStart(n.value,0),V.setEnd(b.endContainer,b.endOffset);const{top:O,right:B}=V.getBoundingClientRect(),D=l();r.value={top:O-D-5,left:B+5,height:D},a.value===-1&&(a.value=0),o.value=!0}else o.value=!1,a.value=-1},l=()=>{const g=e.items.length*38-6;return Math.min(g+28+20,e.height)},p=v=>{var k;if(!n.value)return;const g=window.getSelection();if(!g||g.rangeCount===0)return;const b=((k=n.value.textContent)==null?void 0:k.replace(/\s*$/,""))||"";n.value.textContent=`${b} ${v.label}`;const w=g.getRangeAt(0);w.selectNodeContents(n.value),w.collapse(!1),g.removeAllRanges(),g.addRange(w),x()},m=async v=>{if(!o.value||!e.items||e.items.length===0)return;switch(["ArrowUp","ArrowDown","Enter","Escape"].includes(v.key)&&v.preventDefault(),v.key){case"ArrowDown":a.value++,a.value>=e.items.length&&(a.value=0);break;case"ArrowUp":a.value--,a.value<0&&(a.value=e.items.length-1);break;case"Enter":a.value!==-1&&p(e.items[a.value]);break;case"Escape":x();break}await i.nextTick();const g=a.value>0?".f-chat-suggestion-panel-item--current":".f-chat-suggestion-panel-header",b=document.querySelector(g);b==null||b.scrollIntoView({block:"nearest",behavior:"smooth"})},h=v=>{n.value&&!n.value.contains(v.target)&&x()},x=()=>{u.value=!1,o.value=!1,a.value=-1};i.onMounted(()=>{document.addEventListener("click",h)}),i.onUnmounted(()=>{document.removeEventListener("click",h)});const y=v=>{const g=v.iconUrl||"",b=v.icon||"fx-icon fx-icon-sender_task";return i.createVNode(i.Fragment,null,[g?i.createVNode("img",{alt:"suggestion item icon",src:g},null):i.createVNode("i",{class:b},null),i.createVNode("span",{class:"f-chat-suggestion-panel-item-label"},[v.label])])};return()=>{var v;return i.createVNode("div",{class:"f-chat-suggestion-container"},[i.createVNode("div",{ref:n,class:"f-chat-suggestion-input",contenteditable:"true",onInput:f,onKeyup:f,onKeydown:m,"data-placeholder":c.value},null),o.value&&i.createVNode("div",{class:"f-chat-suggestion-panel",style:{top:`${r.value.top}px`,left:`${r.value.left}px`,height:`${r.value.height}px`}},[i.createVNode("div",{class:"f-chat-suggestion-panel-header"},[e.title]),i.createVNode("div",{class:"f-chat-suggestion-panel-container"},[(v=e.items)==null?void 0:v.map((g,b)=>i.createVNode("div",{key:b,class:["f-chat-suggestion-panel-item",{"f-chat-suggestion-panel-item--current":b===a.value}],onClick:()=>p(g),onMouseenter:()=>a.value===b},[y(g)]))])])])}}});fr.install=e=>{e.component(fr.name,fr)};const tc={type:{type:String,default:"Todo"},message:{type:String,default:""},items:{type:Array,default:[]},customClass:{type:String,default:""}},hr=i.defineComponent({name:"Todo",props:tc,setup(e){const t=i.ref(!0),n=i.computed(()=>{var o;return(o=e.items)==null?void 0:o.length});function u(){t.value=!t.value}return()=>i.createVNode("div",{class:["f-chat-message-todo",e.customClass]},[i.createVNode("div",{class:"f-chat-todo-message"},[e.message]),i.createVNode("div",{class:"f-chat-todo-list"},[i.createVNode("div",{class:"f-chat-todo-header",onClick:u,role:"button",tabindex:0,onKeydown:o=>o.key==="Enter"&&u()},[i.createVNode("span",{class:"f-chat-todo-header-icon-slot"},[i.createVNode("span",{class:"f-chat-todo-header-icon"},[i.createVNode("i",{class:"fx-icon fx-icon-task-record"},null)]),i.createVNode("span",{class:"f-chat-todo-header-expand"},[i.createVNode("i",{class:t.value?"fx-icon fx-icon-expanddown":"fx-icon fx-icon-arrow-right"},null)])]),i.createVNode("span",{class:"f-chat-todo-header-label"},[i.createTextVNode("待办任务")]),i.createVNode("span",{class:"f-chat-todo-header-count"},[n.value])]),t.value&&i.createVNode("div",{class:"f-chat-todo-content"},[i.createVNode(Qn,{items:e.items},null)])])])}});hr.install=e=>{e.component(hr.name,hr),e.component(Qn.name,Qn),e.component(Jr.name,Jr)};const nc={icon:[String,Object],title:[String,Object],description:[String,Object],customClass:{type:[Object,String,Array],default:""},customStyle:{type:[Object,String],default:""},styles:{type:Object,default:()=>({})},classNames:{type:Object,default:()=>({})}},pr=i.defineComponent({name:"FXWelcome",props:nc,emits:[],setup(e,t){const n=i.computed(()=>{const a={"fx-welcome":!0};return!e.description&&(e.icon||t.slots.icon)&&(a["fx-welcome--no-description"]=!0),be(a,e.customClass)}),u=i.computed(()=>Ae({},e.customStyle));function o(){var a,s;return t.slots.icon?t.slots.icon():e.icon?i.createVNode("div",{class:["fx-welcome--icon",(a=e.classNames)==null?void 0:a.icon],style:(s=e.styles)==null?void 0:s.icon},[Sr(e.icon)]):null}function r(){var a,s,c,d,f,l;return t.slots.content?i.createVNode("div",{class:"fx-welcome--content"},[t.slots.content()]):(e.title||e.description)&&i.createVNode("div",{class:["fx-welcome--content",(a=e.classNames)==null?void 0:a.content],style:(s=e.styles)==null?void 0:s.content},[e.title&&i.createVNode("h4",{class:["fx-welcome--title",(c=e.classNames)==null?void 0:c.title],style:(d=e.styles)==null?void 0:d.title},[e.title]),e.description&&i.createVNode("p",{class:["fx-welcome--description",(f=e.classNames)==null?void 0:f.description],style:(l=e.styles)==null?void 0:l.description},[e.description])])}return()=>i.createVNode("div",{class:n.value,style:u.value},[o(),r()])}});pr.install=e=>{e.component(pr.name,pr)};const rc={content:{type:Object,required:!0},onOpen:{type:Function}},sp="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAHHUlEQVRYCV2XSY8VVRTHT9UbgAbpZpSmaRNMxIiGqZVEE1csXBoNboyJ23ahfgI/gQuXdiRx6UY2utKNEUJjQLrBEEwUmQcBBZuphzdU+fufc+tVw61Xde894/+ce+6tepml9uKhpYMbVpWTuWUTpZUjQc7oSnvUMZvvVZJO8om4ZjzLUmK2bqVZO4g+r3hLfbMHi5plc1lZztBPnftkxeGkbfbCocUvW5lNrl+ZYQdLaurCv3UKs7mlNIHuo9RXsqJtHuKZwFRmxH+4ZLbYq3mS5Z76/dOVH2WKvCjLb1e3zHQPHEszIZDNfxY0AyAT9QNHSaoJaf0KV4qHApAcBu8+NisqwBUdO3mevZcT8aRE27mEaamLCdJShEaGknM4QkQLIJqbrWgsUwy2M3osnYtDS2qDQVlkkwDIJjKYrUbSSp0bDy96ugPJeYbUsyyRjbDXwpK31HkkjDusv5rsPa1PPUzkWBlpKX+VosKleS1Aq6IcOAgmWUkQkaFwo/jcRpUJJvy6/WR7kDU37/oEMNLUtC30lV64dilhKVg8sdo5DxeLQlX0mqs1PbQYV8Qq3Uu90Bc3xJQJKYZ+U327kdREdyDuWTpJSfzMmoDo9pNBtxFG2hSvU0WTjowUhXVZfzmVyQoGBe9zZU3UZo5RGXaypBEYbhf24SvaEj617/7s2/UH1AF8AnLi2zsatnNTwwvrxv3CfryoonAVr43NQ2bv7GxaL9XAVyd7NqedpKVzN3gEQ9NT63pQPd2lPUDwrecbNsK5oHZ3vrBvzvasJbTaT4D8eH/TxoeZ0249KuyH84vExCWriOwfy+yDPb7C9t98aZ//zGkmvtTpXZNxrvRHktTDJJBOr7AT1+ujb9dmEobjFtpav7E15cC5dLasyW3rMwGs7PdN9+4tAU786Su9VEsR0OA5AKB1KQO5ouuQ56MoVW3Xs9osIGNdm1lhb4zXxiuZfTgs4Eu/pN896pE5e/qibAUddjT5ZMRhVM1FEDdj7wLgcjcYPIdX5rZ9GK6ywAHw+rbaeCU0sbVBlqIOtpCh0bU1yGMXOp45mfcdIDcOREuBjjAEDp4g61I4tx4WduleqiD4SmlZ9NnvAHgu1vbOoz4vGQzQ9o5BA0Ch9C+L/o87Pfv3Md7k3CXlI40JKGAO0s82S4Ake/yqCieajGoZdmzMbf1QqJ240rHZ6yGzcXVu4yMqw9J2bw2A0jx2kUwqWhWnOr986I9YgbQeEuz1ZZwbUEcu1XWwZ1QRlvbqWJ3+GQCeWgZyAl7J8u1dDuACAOScZKrO/ABTLgSKGwC6YqIt5Gc3DI1PXusBSJK8atc0bHSN2Wvb4nwQ7QzRz16rs7RvrGV8U9j4ugC50C3tFDbcg0DoR68dJefymwsRP5+oDNmBPGGBdr6b2ZmbdRYmWOc9Kbq/H/TZ/yV1Utg9zgm1feMt27etTv+vV7opo7XNquZcAb9UVjhX3wWxg0lIxTl+uY7w/b1DNpROLqVeQHVVWRhZldu7u/ksSu0Y6dfBIzeKVnc0tETnTjUgchYFqFRVRQntiIoote0b6uh+IzNZpnrJbOZaLbNrrF2J2zS6pVLuzlSegktTlDQth2dASETUue08pPKcfU1/7nZh99NWc630OI1TmROIGVL9dLt5v28X7xbhEpnMqw2n4RtH/HwbOkHVqTddSpYy4Kigo3ziKQe3fP0jAmXgBi+qOw/rM0NgpnX4EF8u57KmMlnmXDTdsaHhqPgcFUjE0DJ4wlCavvRkhLMpeqm7AxRmrz4pc+yvqP5Iu1ty+/WRH/4Gi9qJ49oRxfkkRJHin8537aVN8yknZkdVXIqM24mA/v7skt3m9PQlRPMXP0NYRkWttcSWotWu8wD9yfjNrxcpfT67F7QFGegnJQlyFyoMjuC1rYLXcbWmGMvBrtczsnoH9Fk/vbZDGX6G80YTG7hLYONLCNtq0qPzLyJN9KXjRMlzDT65VMU40odIW2PdHgtPjDtYKN0Sh7p8UWWau3IufxLk58lQclPzJdCHI6aCJDlFL0nGWmMZ0orm+nil8T5yUHKifVzC71JleUObCl1fPRWfLtfwPsemA5ENLo35GsvmOl3+isk/tytorObRIshC9gs49J5SMIXhJEYX7xCVpYxINkkQQGw3mYc38KFKy+aajzvlDP/dDohRmYtsYACEypybwuC8/z2rnBMDNEXBHwzeU8qaeCkLFUTqSvpuQw4qP7KbZTPNhW42hZEDtQAcF4peS6qzQEgW2CmSEyjRfUDnDlLE4g3cMXaenjDE03yQhaycyuNfag6IYIivFoppDFMOdWvt3HmScbDUgLab7louOUOuXvfQh6RsTZ3+bMVhByTCy18sHWStJim6Cb7t+LSgCRRNY0c/mEfqB5HIeSWjkUcjAjetskX9zFFPM3nWxHnT/57/Dzj0fqfCZcLZAAAAAElFTkSuQmCC",cp="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAHeklEQVRYCV1XW2hcVRTd985MZjKxNaVa6cNqnwbaftSIiuiPilh8NC2tWh+lXyFFbMEKgvgABQUfIGoxWqGioFLjR0GQlqooGhptjNU+9EPaarT2IUySZt73Xtfa+5w7o3dyc885+5y91l57nzN3AnHXjoOPbJAgGEhEegNJugUNCURqzbrUk5ok6GcklK6OLrTRwc2PxPhLYkniCAswEqPtbXiWGxekEdUkxniQSCmReDSO4sGP+vYPERoQIjtGtr2JRQOB9tQ3Rh0DPMvNCnAi6cwUJROEBk4QvQluoCkBR6QR1UFgqkVYiWKufmRwT9+BrYFFLh/Dl7sSCAEN0PeEIgA044bkM3mNlkYFR9R8sq8qEIB9AMRRU6brUxiPNHol5whwfsK2yMYsZaeRYFzrwVM6GMuEoYRBBxxRZkgOQubEOeJCOFQHrl1uTEsEcKpDGwFjZ0sVC5KBLJb26kJkw0iADDPjCBHQR8n1BgRnKQknqToHIZCsRVWJoJgBeQJGUpXD3ITkEunN4n93GjXm+LaVAxGJadIyCq5ScOaRkVFIgpMQKoWSVxtlDBkZGHW+X6trdK6u6876PPsU0F+rzdwagDkkCPueEOGtr+BwPF2fNGKOnE8BSbZI2BrWTbaOSs2FHQwUFwzUni0YdRGj54dPFxX7nGVzGLXZKoi8qYWJPqNsA9X6cX3vm4Fka0ogp9ITnCBRxEi53smNZ7sz2ii1H0tirEHO682qI0pCppbVSosMx9vVRBHGUsE+78wWzaGqwJRiEe55nfPkmjnX6SICY5J8PX5AzpfPKohGipytWbROsmGWZp0zdnpEfj47iq4D5w6iAvyoShYUVgQ4YiLRVAQZBdK8AzyKIvlzelw2dW+WK2Yuome9rpy5WF75/llETZKR3L74bll/1f3eLGenT8ueI7uVIGX2kht4q88gQxYcG9VmGYBNnUyGXrqo2ZBdP+3E1qqlAMtm9cjNl6/Rw+ay4nxZu3xTaouw9tXh5+wQgl+Cp4cUI9fbpxYEfJW2y8IcKXMewHBwhhEdfz8FYWPd8vtkftdC6V+93aR31qFj78nRc2P/CcQK2MhYDaCt5BIJWZ0EzId5rWztY4ys/RaERvLlqX3y45lDKYlcJidP3Pi8LLy4lZpfzx+VDw7vgjIOQKNFmjTvLVAGS5/ECgkeJgG+6Zh/xxILtJpgCzDGYuS8d8bekMnaREqikC2kbW7Bl755CqSbEoSabdvRDIRE6Bt+VFn4sjawYZECvmQ8S/Y9EQPGInyPkvFktSS7Dr2WgrY33v1hp/w9OY61zjlJo4ipJH16EnySBGtMFcjzENIgwRIfLgiwgOAKrG0qgWrF3+Ez3+kWbAevN2sy9teIFN1W1mCcigyGvnxQJOjJkBh2bgagzAmJsvgYgZfMnvSFI0od9fVskkuKc9rxpSObl4FrH8O7QgZf2QyIcy16KzZ3BpCI+jaVVQGViOCMmEbIZiTIGo5oY8GgvWTWUlnbc6+O/f/f1fOvl1uX3ikdIMBvU42camqxEdj8+XEM6BwtQisIG9A0YDKJ8YiNQYj2HKLr730U7waZFPuXc0fSNhsPrt4qc7sW4FTt1DXMsx5Wqir90RdTwDYCxjiK0Bvw9G08qbgu0OgjuWfFFpk7Y0EKOD5xUp7et10OnvoqHctjVzx8w5OSxSefMRIE0mDgp1UHLEDe3IZkQpH5guBYKUP0yZ57evmsFXLLojtSIJ52r3/7Aux1eevgi7o7vHHJ7B5Zv2oLDqdc6/0R872SFqRhtilgcnh5aCAJFAW2aEGl54uKv/Ye+1B+++e4vjdM1Ery9sjL3qTPvpUPybLZK/UlNuGhxBTwo8q2lLYiZJQuN5zAYgO8Rs7FD6zql9nFS1OAP0onZM/h3Qoe4HzAmSPDJ76Q4ZOfp3NYJ9tuekby2JYF1gP9Akefrqb8jgv6P9tIRDUaAccwSvANWZOpyoQrSCuoAo7sPLYd1eFrCXeN5pkAmmcd1fcL3boYLVcnpR5XsYS+tbjUJzqsAZOG4HYrG2VcqV/AcvQ5B855LNci/EaIcdziYGKfKoAHLvpBm/N5saboE6CdObxrtOF4NWjHNvTA/mkHSLU5bUB0CBBGg7dzfdJG7fXEZBSwaTpABFMwh/WDC6A6B/bOnP2i8niMXmsAVEu6AxxbRtHAz7Ea3pL0Ql8dgoeXL4ICjUYFbkmOMXOOkSMRlR6RS2BBMWK+LeWwM/wpS3CsKVGBUVBRqQgQoF3B7zl1C1IwENkiJKDesf7mM5uzY1yjZ0qUNJ7wpWeAC66AoiRRrmNqiB1i+SCBLToUDPIeRw2VR5VROWF3zuAVTi2/F/DVzHGO8dYi1G1nwPY+YQQJyruYnQHfNoayHgx337V3CO4H6YhvtTW+2TICd3MRZfMONDrY2G9ilzSQKhajRqSOPSB9WFvzToLo82ceT0w4GBx+vDKkiqAnmz+5bcNUtTSQxM1enIDduih1QAUYNZWCU8SaAqJ3UcdMyI9KgTLMkNrcXKpC0owatVGCj1HUyeCn237Xn+f/Avavy/P8wtVMAAAAAElFTkSuQmCC",lp="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAGCklEQVRYCYVXPY8cRRCtnt29s/EhW0KAEAkxmXUBIkBkRERwdoqFHNiW/AMwPwCJECTYEDKEnYJk4+ASIwQ6WSIjwJKNQBjO8t6Xb3dvZ5r3XlXPjIzX7rub7qmuqvfqo3v3ksXIH53fsJQvmOV1y3aqyJ8055x74sZyAys8EqS+hX2pcC9b3t6xPD/i/gSPrWxpvPrNjWt0QhvLV85/CU2AP3sQXEDmwEIiXkuKLw4sb5DnBgz/nWju9NL42Lc3LyZFbs3VZ0O7RusATrnmj0ceURMMg3JfYEVC+4dme4ctUe5Xls4MlfbQdYvHnnQ4m4N9KKVkmYiDyqzCX+C6VYArG65PcI3jq5Z3D7QsQYDEhSE8rLvGkudRbfZwDzwZSZAo69WR2ck1EAlbYLU6EAmcMrIk8dHAjP60R3+2XmHvqQ1XlBuC8ifA4Q+ZObL8cBcLuGGz4afoQ63LGl+wn4aM131I0fIpSJ42oNws6KmtMyEEVRzNa8vTmVUrgyBHfwhbme+DwY6s3YF7gY+lBErtqM9RIpQ8hCUbNkePDFHjICp96DBJjNgnMKoSEiFmkvHxRAKljllHDdGfPWeDd8+0RssWeTbFmf/b6p82rdn8TuDMVhKZx7LBkoBhaR/5FDAYo10QMY5O3VgNxoXQMuAiT6vHrHr1NRu9f85GF68QGqWAPQJp2CN1NKCOqhP6XwZ0aZAAvCpbWLAB0b/taHYnciwBw1AoONUnnsdSibfB66dt8cbb1vx40xKzTjHLESWhLUsmAoxQ+2DmelQEa8gpqXjme2Pn40uWD3CrjnAMkV8RxX56bs1OfHDZVk6/Ke3hW+/Y9NYPOsIJfhrcJ06A0bvD1rNH3kPhkjwGoLQCoP7ApZJWcIeJrQensu3v2v7Xn7Wa1YuvWLPAKSEYH0cLTA7u5UYPtHWRGSJGOK5EdNaMNaSH/tA1ipgSSoM/MEEBRCjv7VhzsOfKo5Wwhd99NGiEzblk2nuATUFmBBJWmXHBoBFd1hEgGOOuAMwf/ja4L3hbVmtrVqEXOOr7f8q0gY90iM+CdngW6HjoeHp2QCwqu5YdHKxbWy38pCR8KPiJAYfB0KqXXrbjGx+2qvOtW/CJXto9tLRoeA20/tyvLiIHLxdPP1rGKVbBr3g++elXZbl0rrfv2+x7fOTvPrJqhtuU4KHdD2qo1DPKsqvLhykqvcAz1G4uBexvzH/9xfa++MTyPw+swtnnFayysczhqs1Ax4ZpB1TR6Hnswy/u/W6HiEwnAGWKFpBdgzov7t2x+u5ddPxR15xQA7TK1XMrG2SgE1GJgyTaDOAY0VkZ9YNtm25e14VT0XGDCNnEPG6oM4n51VuuWQBTCJ+8V9Q1ESTXOAVINSPhoMPY1CvXIoAalkGwR1O9hTvZUVChy0icgH5SQEbY1ORgy/pwHJ4C+HNWWGBQsdGxxCLI9DhRRTo8+z4IFsThvUp4Q0CciOZazChe9FUqdMN6qGMUtHQSxIMGodEu/J0OSdhnX+s6jjRTKzETEWubXVhQ1hGCInwPWRfX7ZWCXiR3Im5EIQbUieWXkIv4ZN0LZ+nrhZBcADxwhNeZoQek6OmXPIBdB67guf7rD5vf/lmixZ3fPAr2Db+UoocIXgaBCihTTncdtaIIDd+wNL981lUk6BQadXe2xXRuNb731XErVgBNAGfDMQuBIIziVJBsLrgrMp/df5FxH1dxVxdFQSLBjjPTqT+ACZDvWFOmjpfPSLFkFEiIp8/+HutuW/b0OSmMSsNo1tEEKCJlivmFpCIhrKt+zltQEnIQzvKh1y7dkjMzpObBTfBxl7dEVMa8fl2BEYo5P8kierJl1RU/HQDAQQsIEZ0ErQuQXIe4aIiMpS1WdOyKYYLInSkB4mZzNnINDkSNElBXOP7AmpEX+5IFN4GcWQ0dylLK42r4+dVriHBs0XSQx5CKrwXooCFwYL3AMeYCGiJXgwvulqwK3bWZxvELN25fI4rG7NJ7G/jywf+Q13Ou9d+SosHnQDPZb69rAtFIgHSmX1JwmfaYBRdQypX0sTfB2xayKHDK/wNolX2UI+Wo7QAAAABJRU5ErkJggg==",uc="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAGLUlEQVRYCW1XTY9UVRCt19M9MwyiAxojRI1REImJRAfQhcSVGmJINMG9G5LRH+DOxJ0JP0BnpYlbMCYqGBciJmqIZiAsSARUUDQoYGjmo2emP97znFNVr3vUm+n76ladqjpV9973oLAYcyf6hwZlOVtVNmNWTVcQDH9lPLnGcr1Oa9cTRoD8KEoerstS3m1g5pe71dw7h6eP0b3g9O7x7ntwnKUsR4AzoQIymGzUU/DAFDlS53Il0qlTnABSJpHOGnzKau7IG1teL7zywVE6OJjoQnIGB1gEmEk4JQ0yAqWvP9PPn8DV/obkpQ1K4pClarzaZNs9OuEcnlyVY1UBzDEk586upUF/9ZJCFkM5Wi9df1B58iRkg9kmwDNKFoFSromMZmBzMPRYR4w6D+BEA5d4PJHTVteEkr/jihkQKKcVFEwC7wePieg10pG0J5BrVsuhp+SR7ZO/GStfQXKC3IczcDjszdpZQQiihlgXSu5BqKXhxDWDSRHY/9Ex/1qvtH5fIT00fWpsZc0S7KTjlEMALGSIR9hFbAQ7gD8H9byyVVVgnyskxY+x0y+6kddaPpianS69PcmGcQ9UHzw3iQcdkhDFPFxsrcf2ZNhSkTEQ4chO1nLk8u0FgayITFOJ7amvTlbAUlLO5PLRNPLCUtqiPkfJ3rsjY52Hrs2sHuFlzRZxlQmFcXOty+SRX77ug7nGupBFEkQ5zJKbXGTlmXy8ZfbwVp3PCJbtrez6rYHduxm84fjz731bXoGAxe5HWtr728ulbb6jIUI5sWM9HMRzP63VuZI43wNiNMpy01RhLz09kf7rnp9+t2J7do7b1rvHbP5C1z76umP7do3by/un7OT8ij32YMtmdv7Xd7FT2rlLIMBo4kypwBmI0yklbdAvLFV2/PSq5AP7JmxsrLCvzq4Zg1y93reb7YG9dmCjPbmjZafPN+z5PZN2a3FgX55ZtW1bxuzCr13b8UDL9u6atD9u9O3UmRXr4lZkh1UscnGNLXAm2ps4uWs9s/NXBqL64l4QgHTxas/+XvDXX3uxtLOXevbUo+N2+OAmG28VdvTzRet2K7v8Z99+uVbZxHgBAmbtpdJ++JFfH4XD5KKvK2uocnSh0tF3q5PxL5c8wond4X4y1klUxXvO5Feu9ez85R46Bgv/COCPI3R8oaW/Y/xcNWpsbIWS00/ew0lBY8lte+i+pjWxNRzb7mnaXTg3HCLBp1Y+1cRCqyIC0BDBTB6OTKDfaBTaAKa+iQvywt4NuAGlXfitqy4cfHZK4enivu6stdjzGxHvi4hFIg2COTJ4rl0nkybZASV6/xOTdufGhrbh41PL2ord2yds+zZcz4g39GRsj18zDCNj6sIqOJR8cngy7pGvQ6n1lk0Ne+bxCfsL74MzF7t2Ewfzm3Orgrzy3EYrsBN52t1P80jMOEcKzWuIJEoUCrYlB/Wf4d4z6GIHOBhaOHSffNuxazd6/j2A8ovvO7pu9JvCK2CxY9iann14YsFuLQ08OWxej8fPPMVb7y9Iw9ZNTfo+8YPCl0SCRBLp64aIpH/3l/Bu4A0qS7+iDJbb4P6O80JhHLEzXvx7wFkNQXCKTnhyuqENwcAZx+cXFrWcJGjHj3aHZnL6pw7PkBm76Szp6AB3pByB5Ip1EsKTATTok2v5cwoTA6UOqnXdFMavLTrgrfWlV5nJGYryuqAef0hIoBoiaJJ1/3BAhxRXb1vkxJZx6/xjFExjG+EBMEP9K7nI0FZXTfL8ZXCW5qW4PgqAVqE4YYx2Qy8iad2mgOTGEXjpXB5JBMjwuolu+DipoT99kojLDnRdA1esTUZM6RX6s24jnWFXQ4gbxbJy+KkiCIpDaMh08k5QiT/4JibIt/EmtPkaSBKkpwkPRNJHRCpXpt3JMoHDk3ztzK2iDVONYWwO6fEoivkGPmhzDgybql3PXD5wykoVFEpWUXeHQairq/QYo8Xw4HGt6oEtkLtxZBb/SxWJCAaDQmmKKpJU2JTL80HjeOpEUBrows6Htg2C5HSwau6Dt+8/5kcWyjfn2oemWgP8D7kxMygH00QziLd25E3HKBiqHvIy3oTkJ10IddsVIBK73AZ0vrBCyenzD7OyHHaTkJSSAAAAAElFTkSuQmCC",dp="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAIKADAAQAAAABAAAAIAAAAACshmLzAAAGkElEQVRYCZVXS2udRRh+Z+Y7zTFtk5iml7S1XpBW3HhJdVER0YUKikhtRNCFF5TYheLWjX/AlRuzcOnO/AXXIpiFG0URoUWq0KJpLb2eb8bned6ZcxLaCP1O5szMe33ey8z5Eqw+5czyKSt5Bdsli3vnRB6dB+k6lgV/2SVLsYJ1IE108pw23jf6plk6pWyEYOuhhNXwyPdrNBj4Vc689qXlQudm3QGoJS2t9GbX/8B6hOEgCpzROeexQ4EjHRTSsZ/IEXjjYV31ILuaHl3/MHjk/TdEaHEPxvTYkBzlq2Y3zrkzOWD0XNBJM+h7OmqOmyPOkmsgMvRDDaDYcoShFQqFMJRz2a4oIYbtFOgzQq40ykmLUNL0zoVkVJrmtM4OGNbgXCAzs0SdvBLxtUTDJd1dIyPD0+xC2HezKFa0QKXxqBmAtNEwsyFwVR9eW5kcOAWd53KSX4pANRfibjA7qgMEnXiEboB6oIYZ8R0A00iDeOi4OQM4lY00Aa3louaY5mup5zIXA1WQYndMJlHSMI1x8shCYhlEqWwH6ptJXb0Hqh6BKTuTyEGRXdqn7a6EnbCBVqiIZZBfAjJRFKw0a2V0ofJcxh1WueGDFhc/RtvcZ+HKT5bPfV5PEfjVXusDZQBgOjUYFkSmR7ItddUJJqWWWRj9gx2OpTLjdOmCF+//wkLnV4jNPm1xeK/1Py+jd27QEP5q9DLrPtBZ6MPKbChZ32JMPUd1rgzBCPulloV8zxzoO5+YOJcW9KaOmO1+EjtPdyvn5pm5B5+jatE4hqoNWpATp8EM+mWXDMpoPVa+ZpS3PgH3inULEJnUXmv6Aw3h07l2mDxiORKtRegArFu0MjyGXpweN1cDGP79zsqNP7cgKFd+Mbv2O474rLJD+5ujp++uaZChk1AJbhhQMq5jgCmocTr8KUpwl+WzV61c/FZZyrhUvD+GuNI/s7BwysKOQ1au/WblwtrYoXV7LfTXcLtfZujj0bErme7mvNWUWfBaUzxb3PeuhcT7ArIHTlu+hIjzZb+cEk4SLjLrL1r56ysWzUEBuHe727DBfrQNrvZ8E1Y8814CbPSppWjN5bTeytRRi7sel3N+xanDFuZfrWWAicE+2GuAGRBLWTPK7OkukCb6ASAkWwGo2SRMAUfejJUesUA5LbxB5pYnLryOfbIyWJA4v5Q90FgW+sjQLfhFVXZrf/HHjld76wdlwDveETnD1wSk6KePbnHOTZxaNNtzEg05lKPMIA68b/HY1xbnXxTNywobygiUiIo2cSpCGKg8AtDq3hQQNl4PMNCAac8r9HfbJy2chBxKhBH3v2Np/gVcKwNLix9Y2H3CecyCDhe/HEzARVMGe5WFSOfNMaPPPVFSFgqoV9z1mO9v852QmTL1gIWZpwD05S0S3eGPoI9jiw9tFf4EMxPVfEi4T9DUuoi8duRUMIicYOL880hV6+Mt9sebwf43bXDo9HjfFiENLR35pDomDHwULPGwN1CyHQhQkFgbDU5g6tNZmn2m2dt27maO43jyB+3WJ+18GC9ZL7kzOpSIl4L+GK5fxUI3YbCucebEtoZvdbU9pTv4tmVcYq2nVIoGBnHXDPAi4rHBrRdYJ9zRc89tb/UOOMxOd/A9aHhe+T6oNTMOmpqQDjWUCQji7k7TD92Bm/8XTeilsuMgfKC8uFvgRs656ASoOm73QRldsv7SDxaG90DQz8ikFblqg4aIna/tfJw+6dsql684T3XHEgBcBl0w+vUtvWixRkKI+rMU/egm5lE957xKUB798NChQnBL1OOzmcaoMhoM/nmKYoy4H/HyVyLWLi4A0MGbKH8YIKgLhYrsVl6faETPFZigwU+gRUWhN0kH4imEBYJinWkLkYHOtTsmSOjw5cfFuIU+3gnj9bMb6Po5Jlo/GrwsACJiUDoydtRtQIN0LjpYtERjmimLlcCTyHPODtcLBznIBkBRBU5rHORvENI6BciQIISYnqj3ZUaDCw1rvLspmoQoEgT4z1uCnA9Pd4IcR4QMdSjHwLCUHdpX6jETJIjrAFZWBZdMDAFhrZlGiFGZhqIG1jLMmUB0jjXzzabTnv9ZMnK3x5rTTguyZZq0kPNq5H+psA0QkgFCjwaT0FJwclVj0wSZ47bGTOBbmhNcOVYw7CsPSCo0A5/ds3+vSYb78uPxU31/cwUAlnLf490aDqqThppyPClthltlajyD54C9nNKvNggQvA3Q1lFOOD+/Rjv/AYfYvIrlGomFAAAAAElFTkSuQmCC",mr=i.defineComponent({name:"FChatAttachmentPreview",props:rc,emits:[],setup(e){function t(s){switch(s.toLowerCase()){case"doc":case"docx":return sp;case"xlsx":case"xls":return cp;case"ppt":case"mobi":return lp;case"txt":return uc;case"png":case"jpg":case"jpeg":case"gif":return dp;default:return uc}}function n(s){return s.icon?s.icon:t(s.type||"")}function u(s){if(s===0)return"0 B";const c=1024,d=["B","KB","MB","GB"],f=Math.floor(Math.log(s)/Math.log(c));return parseFloat((s/Math.pow(c,f)).toFixed(2))+" "+d[f]}async function o(s){var c;(c=e.onOpen)==null||c.call(e,s)}async function r(s,c){s.stopPropagation(),s.preventDefault();const d=on(c);d&&await _r(d,c.name)}function a(s,c){const d=u(s.size||0),f=n(s),l=on(s);return i.createVNode("div",{key:c,class:"f-chat-attachment-preview-card"},[i.createVNode("div",{class:"f-chat-attachment-preview-card-inner"},[i.createVNode("div",{class:"f-chat-attachment-preview-main",role:"button",tabindex:0,onClick:()=>o(s),onKeydown:p=>p.key==="Enter"&&o(s)},[i.createVNode("div",{class:"f-chat-attachment-preview-icon-wrapper"},[i.createVNode("img",{src:f,alt:""},null)]),i.createVNode("div",{class:"f-chat-attachment-preview-info"},[i.createVNode("div",{class:"f-chat-attachment-preview-name",title:s.name},[s.name]),i.createVNode("div",{class:"f-chat-attachment-preview-meta"},[d&&i.createVNode("span",null,[d])])])]),l?i.createVNode("button",{type:"button",class:"f-chat-attachment-preview-download-btn","aria-label":"下载附件",title:"下载",onClick:p=>r(p,s)},[i.createVNode("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","aria-hidden":"true"},[i.createVNode("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("polyline",{points:"7 10 12 15 17 10","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("line",{x1:"12",y1:"15",x2:"12",y2:"3","stroke-linecap":"round","stroke-linejoin":"round"},null)])]):null])])}return()=>{const s=e.content;if(!s)return null;const{message:c,attachments:d}=s;return i.createVNode("div",{class:"f-chat-attachment-preview"},[c&&i.createVNode("div",{class:"f-chat-attachment-preview-message"},[c]),i.createVNode("div",{class:"f-chat-attachment-preview-list"},[d.map((f,l)=>a(f,l))])])}}});mr.install=e=>{e.component(mr.name,mr)},gn.install=e=>{e.component(gn.name,gn)},bn.install=e=>{e.component(bn.name,bn)};const oc={customClass:{type:String,default:""},enableFold:{type:Boolean,default:!0},expanded:{type:Boolean,default:!1},height:{type:Number,default:void 0},width:{type:Number,default:void 0}},gr=i.defineComponent({name:"FXAccordion",props:oc,emits:[],setup(e,t){const n=i.computed(()=>({height:e.height?`${e.height}px`:"",width:e.width?`${e.width}px`:""}));i.provide("accordionContext",{parentProps:e});const u=i.computed(()=>be({"farris-panel":!0,accordion:!0},e.customClass));return()=>{var o,r;return i.createVNode("div",{class:u.value,style:n.value},[(r=(o=t.slots).default)==null?void 0:r.call(o)])}}}),ic={active:{type:Boolean,default:!1},customClass:{type:String,default:""},disabled:{type:Boolean,default:!1},enableFold:{type:Boolean,default:!0},height:{type:Number,default:void 0},iconUri:{type:String,default:""},maxHeight:{type:Number,default:void 0},title:{type:String,default:""},width:{type:Number,default:void 0}},Ro=i.defineComponent({name:"FXAccordionItem",props:ic,emits:["clickHeader"],setup(e,t){const n=i.ref(),u=i.inject("accordionContext"),o=i.ref(e.title),r=i.ref(e.active),a=i.computed(()=>{var m;return!!((m=u==null?void 0:u.parentProps)!=null&&m.enableFold)&&e.enableFold});function s(){e.disabled||!a.value||(r.value=!r.value)}function c(m){t.emit("clickHeader"),s()}const d=i.computed(()=>{const m={card:!0,"farris-panel-item":!0,"f-state-disabled":e.disabled,"f-state-selected":r.value};return be(m,e.customClass)}),f=i.computed(()=>({"fx-icon":!0,"f-accordion-collapse":!r.value,"f-accordion-expand":r.value}));function l(){return n.value?n.value.getBoundingClientRect().height:0}const p=i.computed(()=>{const m=e.maxHeight?{transition:"maxHeight 0.36s ease 0s","max-height":r.value?`${e.maxHeight}px`:0}:{transition:"height 0.36s ease 0s",height:r.value?`${l()}px`:0};return r.value||(m.overflow="hidden"),m});return i.onMounted(()=>{var m;(m=u==null?void 0:u.parentProps)!=null&&m.expanded&&(r.value=!0)}),()=>{var m,h,x,y,v,g;return i.createVNode("div",{class:d.value},[i.createVNode("div",{class:"card-header",onClick:c},[i.createVNode("div",{class:"panel-item-title"},[e.iconUri&&i.createVNode("img",{class:"panel-item-title-image",src:e.iconUri,title:"title-icon"},null),i.createVNode("span",null,[o.value]),(h=(m=t.slots).head)==null?void 0:h.call(m),a.value&&i.createVNode("i",{class:f.value},null)]),i.createVNode("div",{class:"panel-item-tool"},[(y=(x=t.slots).toolbar)==null?void 0:y.call(x)]),i.createVNode("div",{class:"panel-item-clear"},null)]),i.createVNode("div",{style:p.value},[i.createVNode("div",{class:"card-body",ref:n},[(g=(v=t.slots).default)==null?void 0:g.call(v)])])])}}});gr.install=e=>{e.component(gr.name,gr),e.component(Ro.name,Ro)};const ac={activeNavId:{type:String,default:""},displayField:{type:String,default:"text"},disableField:{type:String,default:"disable"},horizontal:{type:Boolean,default:!0},idField:{type:String,default:"id"},maxNum:{type:Number,default:99},navData:{type:Array,default:()=>[]},navPicking:{type:Function,default:null},valueField:{type:String,default:"num"},visible:{type:Boolean,default:!0},customClass:{type:String,default:""},customStyle:{type:String,default:""}},br=i.defineComponent({name:"FXNav",props:ac,emits:["nav","update:activeNavId"],setup(e,t){const n=i.ref(e.activeNavId),u=i.ref(e.navData);function o(f){if(u.value&&u.value.length){let l=u.value.find(p=>p[e.idField]===f&&p[e.disableField]!==!0);l||(l=u.value.find(p=>p[e.disableField]!==!0)),l&&n.value!==l.id&&(n.value=l.id,t.emit("nav",l))}}i.watch([()=>e.activeNavId,()=>e.navData],([f,l])=>{u.value=l,o(f)});const r=i.computed(()=>e.visible&&u.value.length>0);function a(f){f.disable||f.id===n.value||Promise.resolve().then(()=>{const l=e.navPicking;return l&&typeof l=="function"?l(f):!0}).then(l=>{let p=!0;typeof l=="object"?l.canContinue||(p=!1,l.message&&console.error({message:l.message,position:"top-center"})):p=l,p&&(n.value=f.id,t.emit("update:activeNavId",f.id),t.emit("nav",f))})}const s=i.computed(()=>{const f={"farris-nav":!0,"farris-nav-vertical":!e.horizontal};return be(f,e.customClass)}),c=i.computed(()=>Ae({},e.customStyle));function d(f){u.value=f,o(n.value)}return t.expose({updateNavData:d}),()=>{var f;return r.value&&i.createVNode("div",{class:s.value,style:c.value},[(f=u.value)==null?void 0:f.map(l=>i.createVNode("div",{class:["farris-nav-item",{active:l[e.idField]===n.value},{disabled:l[e.disableField]}],onClick:()=>a(l)},[i.createVNode("div",{class:"farris-nav-item-link pt-3"},[i.createVNode("span",{class:"farris-nav-item-link-text"},[typeof l[e.displayField]=="function"?l[e.displayField]():l[e.displayField],l[e.valueField]&&i.createVNode("div",{class:"farris-nav-item-tag"},[l[e.valueField]<=e.maxNum&&i.createVNode("span",{class:"tag-text"},[l[e.valueField]]),l[e.valueField]>e.maxNum&&i.createVNode("span",{class:"tag-text"},[e.maxNum,i.createTextVNode("+")])])]),i.createVNode("div",{class:"farris-nav-item-bottom-line"},null)])]))])}}});br.install=e=>{e.component(br.name,br)};const sc={buttonContent:{type:String,default:'<i class="fx-icon fx-icon-search"></i>'},customClass:{type:String,default:""},modelValue:{type:String,default:""},popupHost:{type:Object},data:{type:Array,default:()=>[]},placeholder:{type:String,default:"请输入关键词"},idField:{type:String,default:"id"},textField:{type:String,default:"name"},maxHeight:{type:Number,default:350},loading:{type:Boolean,default:!1},disable:{type:Boolean,default:!1},showDropdown:{type:Boolean,default:!0}},cc={data:{type:Array,default:()=>[]},onConfirmResult:{type:Function,default:void 0},onSearchedValue:{type:Function,default:void 0},idField:{type:String,default:"id"},textField:{type:String,default:"name"},maxHeight:{type:Number,default:350},loading:{type:Boolean,default:!1}},hu=i.defineComponent({name:"FXSearchBoxContainer",props:cc,emits:["confirmResult","searchedValue"],setup(e,t){const n=i.ref(e.data),u=i.ref(""),o=i.computed(()=>{if(!u.value)return n.value;const d=u.value.toLowerCase();return n.value.filter(f=>String(f[e.textField]??"").toLowerCase().includes(d))});function r(d){u.value=d}function a(d){t.emit("confirmResult",d[e.textField]),t.emit("searchedValue",[d])}function s(d){return t.slots.default?t.slots.default({item:d}):i.createVNode("span",null,[d[e.textField]])}const c=i.computed(()=>{const d={padding:"8px"};return e.maxHeight!==void 0&&e.maxHeight>0&&(d.maxHeight=`${e.maxHeight}px`),d});return i.watch(()=>e.data,d=>{d!==n.value&&(n.value=d)}),t.expose({search:r}),()=>i.createVNode("div",{class:"search-box-container f-utils-overflow-xhya position-relative",style:c.value},[e.loading&&i.createVNode("div",{class:"search-box-loading"},[i.createVNode("i",{class:"fx-icon fx-icon-bubble_step_loading fx-icon-spin"},null)]),i.createVNode("ul",{class:"search-box-list"},[o.value.map(d=>i.createVNode("li",{class:"search-box-item dropdown-item",key:d[e.idField],onClick:()=>a(d)},[s(d)])),!e.loading&&o.value.length===0&&i.createVNode("li",{class:"search-box-empty"},[i.createTextVNode("无匹配结果")])])])}}),yr=i.defineComponent({name:"FXSearchBox",props:sc,emits:["update:modelValue","change","selectedValue","clickButton"],setup(e,t){const n=i.ref(),u=i.ref(),o=i.ref(),r=i.ref(e.modelValue),a=i.ref(!1),s='<i class="fx-icon fx-icon-clockwise fx-icon-spin"></i>',c=i.computed(()=>e.loading?s:e.buttonContent);i.watch(r,w=>{var k;(k=o.value)==null||k.search(w),t.emit("update:modelValue",w)}),i.watch(()=>e.modelValue,w=>{r.value=w});function d(w){r.value=w,h()}function f(w){const k=r.value;t.emit("change",w,{oldValue:k,newValue:w})}function l(w){t.emit("selectedValue",w)}function p(){t.emit("clickButton",{})}async function m(){var w;a.value=!0,await i.nextTick(),(w=u.value)==null||w.show(n.value)}function h(){var w;(w=u.value)==null||w.hide(),a.value=!1}function x(){a.value?h():m()}function y(w){const k=w.target.value;r.value=k,f(k),e.showDropdown&&k&&m()}function v(){e.showDropdown&&r.value&&m()}function g(){r.value="",t.emit("update:modelValue",""),h()}t.expose({togglePopup:x,hidePopup:h,showPopup:m});const b=i.computed(()=>{const w=be({},e.customClass);return["f-search-box",{"f-search-box-disabled":e.disable},...typeof w=="string"?[w]:Array.isArray(w)?w:[]]});return()=>i.createVNode("div",{class:b.value},[i.createVNode("div",{class:"f-search-box-input-group",ref:n},[i.createVNode("input",{class:"f-search-box-input form-control",type:"text",placeholder:e.placeholder,value:r.value,disabled:e.disable,onInput:y,onFocus:v},null),r.value&&!e.disable&&i.createVNode("span",{class:"f-search-box-clear",onClick:g},[i.createVNode("i",{class:"fx-icon fx-icon-close"},null)]),i.createVNode("span",{class:"f-search-box-button",onClick:p},[i.createVNode("i",{class:"fx-icon fx-icon-search",innerHTML:c.value},null)])]),e.showDropdown&&i.createVNode(qt,{ref:u,placement:"bottom-left",keepWidthWithReference:!0,showArrow:!1,fitContent:!0,limitContentBySpace:!0,host:e.popupHost},{default:()=>[i.createVNode(hu,{ref:o,data:e.data,idField:e.idField,textField:e.textField,onConfirmResult:d,onSearchedValue:w=>l(w),loading:e.loading,maxHeight:e.maxHeight},t.slots)]})])}});yr.install=e=>{e.component(yr.name,yr),e.component(hu.name,hu)};const Mo={data:{type:Array,default:()=>[]},view:{type:String,default:"ContentView"},customClass:{type:String,default:""},itemClass:{type:[String,Function],default:""},idField:{type:String,default:"id"},textField:{type:String,default:"name"},titleField:{type:String,default:"name"},valueField:{type:String,default:"id"},group:{type:Object,default:void 0}};function fp(e){const t=i.ref([...e.data]),n=i.ref([]),u=i.ref(""),o=i.computed(()=>{var p;const l=e.group;return l!=null&&l.enable&&((p=l.groupFields)!=null&&p.length)?r(t.value,l):t.value.map((m,h)=>({type:0,data:m,originalIndex:h}))});function r(l,p){const m=[],h=p.groupFields[0],x=new Map;l.forEach(v=>{const g=String(v[h]??"");x.has(g)||x.set(g,[]),x.get(g).push(v)});let y=0;return x.forEach((v,g)=>{m.push({type:1,data:{[h]:g},groupField:h,groupValue:g,originalIndex:y++}),v.forEach(b=>{m.push({type:0,data:b,groupField:h,groupValue:g,originalIndex:y++})})}),m}function a(l){t.value=[...l],n.value=[],u.value=""}function s(l){u.value=l;const p=t.value.find(m=>m[e.idField]===l);p&&!n.value.includes(p)&&(n.value=[p])}function c(){n.value=[],u.value=""}function d(l){const p=n.value.indexOf(l);p>=0?n.value.splice(p,1):n.value=[l],u.value=l[e.idField]}function f(l){return n.value.includes(l)}return{data:t,visualData:o,selectedItems:n,activeItemId:u,updateDataSource:a,activeRowById:s,clearSelection:c,toggleSelection:d,isSelected:f}}const hp=i.defineComponent({name:"FXListViewItem",props:{...Mo,item:{type:Object,default:()=>({})},index:{type:Number,default:0},isActive:{type:Boolean,default:!1},isSelected:{type:Boolean,default:!1}},emits:["clickItem"],setup(e,t){const n=i.computed(()=>({"f-list-view-item":!0,"f-list-view-item-active":e.isActive}));return()=>i.createVNode("li",{class:[n.value,typeof e.itemClass=="function"?e.itemClass(e.item,e.index):e.itemClass],onClick:()=>t.emit("clickItem",e.item,e.index)},[t.slots.default?t.slots.default({item:e.item,index:e.index,selectedItem:e.isSelected?e.item:null}):i.createVNode("span",null,[e.item[e.textField]])])}}),pp=i.defineComponent({name:"FXListGroupItem",props:{groupData:{type:Object,default:()=>({})},groupField:{type:String,default:""},groupValue:{type:String,default:""},index:{type:Number,default:0}},setup(e,t){return()=>i.createVNode("li",{class:"f-list-view-group-item"},[t.slots.default?t.slots.default({item:e.groupData,index:e.index}):i.createVNode("div",{class:"f-list-view-group-header"},[i.createVNode("i",{class:"fx-icon f-accordion-expand"},null),i.createVNode("span",null,[e.groupValue])])])}}),xr=i.defineComponent({name:"FXListView",props:Mo,emits:["clickItem"],setup(e,t){const{visualData:n,activeItemId:u,updateDataSource:o,activeRowById:r,clearSelection:a,toggleSelection:s,isSelected:c}=fp({data:e.data,idField:e.idField,group:e.group}),d=i.computed(()=>be({"f-list-view":!0},e.customClass));function f(l,p){s(l),t.emit("clickItem",l,p)}return t.expose({updateDataSource:o,activeRowById:r,clearSelection:a}),()=>i.createVNode("div",{class:d.value},[i.createVNode("div",{class:"f-list-view-content"},[i.createVNode("ul",{class:"f-list-view-items"},[n.value.map((l,p)=>l.type===1?i.createVNode(pp,{key:`group_${l.groupValue}_${p}`,groupData:l.data,groupField:l.groupField,groupValue:l.groupValue,index:p},{default:t.slots.group}):i.createVNode(hp,{key:`${l.data[e.idField]}_${p}`,item:l.data,index:l.originalIndex,isActive:l.data[e.idField]===u.value,isSelected:c(l.data),itemClass:e.itemClass,textField:e.textField,onClickItem:f},{default:t.slots.content}))])])])}});xr.install=e=>{e.component(xr.name,xr)};const Vo=i.defineComponent({name:"FXAgentThinkingMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>{const t=e.content,n=t.streamStatus==="end"||t.streamStatus===void 0;return i.createVNode("details",{class:"f-ec-thinking",open:!0},[i.createVNode("summary",{class:"f-ec-thinking-summary"},[i.createTextVNode("思考过程"),n?null:i.createVNode("span",{class:"f-ec-thinking-badge"},[i.createTextVNode("进行中")])]),i.createVNode("div",{class:"f-ec-thinking-body"},[t.text]),t.sources&&t.sources.length>0?i.createVNode("ul",{class:"f-ec-thinking-sources"},[t.sources.map((u,o)=>i.createVNode("li",{key:o},[u]))]):null])}}});function mp(e){return e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:`${(e/(1024*1024)).toFixed(1)} MB`}function gp(e){const t=e.trim();return t.startsWith("http://")||t.startsWith("https://")?t:`#attachment:${encodeURIComponent(t)}`}function bp(e){const t=e.trim();return t.startsWith("http://")||t.startsWith("https://")?{url:t}:{fileId:t}}const lc=i.defineComponent({name:"FXAttachmentFileMessage",props:{content:{type:Object,required:!0}},setup(e){const t=i.computed(()=>gp(e.content.media)),n=i.computed(()=>on(bp(e.content.media)));async function u(o){o.preventDefault(),o.stopPropagation();const r=n.value;r&&await _r(r,e.content.name)}return()=>{const o=!!n.value;return i.createVNode("div",{class:"f-ec-attach-row"},[i.createVNode("a",{class:"f-ec-attach f-ec-attach--stretch",href:t.value,target:"_blank",rel:"noopener noreferrer"},[i.createVNode("span",{class:"f-ec-attach-icon","aria-hidden":!0},[i.createTextVNode("📎")]),i.createVNode("span",{class:"f-ec-attach-body"},[i.createVNode("span",{class:"f-ec-attach-name"},[e.content.name]),i.createVNode("span",{class:"f-ec-attach-meta"},[i.createVNode("span",{class:"f-ec-attach-cat"},[e.content.category]),i.createVNode("span",{class:"f-ec-attach-size"},[mp(e.content.size)])])])]),o?i.createVNode("button",{type:"button",class:"f-ec-attach-download-btn","aria-label":"下载附件",title:"下载",onClick:u},[i.createVNode("svg",{width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","aria-hidden":"true"},[i.createVNode("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("polyline",{points:"7 10 12 15 17 10","stroke-linecap":"round","stroke-linejoin":"round"},null),i.createVNode("line",{x1:"12",y1:"15",x2:"12",y2:"3","stroke-linecap":"round","stroke-linejoin":"round"},null)])]):null])}}}),yp={0:"高",1:"中",2:"低"},dc=i.defineComponent({name:"ErrorReminderMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>{const t=e.content.errorLevel;return i.createVNode("div",{class:["f-ec-error",`f-ec-error--lvl-${t}`]},[i.createVNode("div",{class:"f-ec-error-head"},[i.createVNode("span",{class:"f-ec-error-badge"},[yp[t]]),i.createVNode("span",{class:"f-ec-error-label"},[i.createTextVNode("错误提醒")])]),i.createVNode("div",{class:"f-ec-error-text"},[e.content.errorText]),e.content.errorLink?i.createVNode("a",{class:"f-ec-error-link",href:e.content.errorLink,target:"_blank",rel:"noopener noreferrer"},[i.createTextVNode("查看详情")]):null])}}}),Bo="{{suggestionText}}";function zo(e,t){if(typeof e=="string")return e===Bo?t:e.includes(Bo)?e.split(Bo).join(t):e;if(Array.isArray(e))return e.map(n=>zo(n,t));if(e!==null&&typeof e=="object"){const n={};for(const[u,o]of Object.entries(e))n[u]=zo(o,t);return n}return e}function xp(e,t){var u;const n=(u=e.pickActions)==null?void 0:u[t];return n||e.pickActionDefault}const fc=i.defineComponent({name:"InputRecommendMessage",props:{content:{type:Object,required:!0},onPick:{type:Function,default:void 0}},setup(e){const t=(n,u)=>{var r;const o=xp(e.content,u);if((o==null?void 0:o.sdk)==="AgentWorkbenchSDK"&&o.api){const a=zo(o.params??[],n);Io(o.api,a)}else Io("sendChatMessage",[n]);(r=e.onPick)==null||r.call(e,n)};return()=>i.createVNode("div",{class:"f-ec-recommend"},[e.content.title?i.createVNode("div",{class:"f-ec-recommend-title"},[e.content.title]):null,i.createVNode("div",{class:"f-ec-recommend-chips"},[e.content.suggestions.map((n,u)=>i.createVNode("button",{key:u,type:"button",class:"f-ec-recommend-chip",onClick:()=>t(n,u)},[n]))])])}}),hc=i.defineComponent({name:"LinkCardMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>{const t=e.content;return i.createVNode("div",{class:"f-ec-linkcard"},[t.poster?i.createVNode("div",{class:"f-ec-linkcard-poster"},[i.createVNode("img",{src:t.poster,alt:""},null)]):null,i.createVNode("div",{class:"f-ec-linkcard-body"},[i.createVNode("a",{class:"f-ec-linkcard-title",href:t.url,target:"_blank",rel:"noopener noreferrer"},[t.title]),t.subtitle?i.createVNode("div",{class:"f-ec-linkcard-sub"},[t.subtitle]):null,t.relatedLinks&&t.relatedLinks.length>0?i.createVNode("div",{class:"f-ec-linkcard-related"},[i.createVNode("div",{class:"f-ec-linkcard-related-label"},[i.createTextVNode("相关阅读")]),i.createVNode("ul",null,[t.relatedLinks.map((n,u)=>i.createVNode("li",{key:u},[i.createVNode("a",{href:n.url,target:"_blank",rel:"noopener noreferrer"},[n.title])]))])]):null])])}}}),pc=i.defineComponent({name:"ReferenceSourcesMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>i.createVNode("div",{class:"f-ec-sources"},[i.createVNode("div",{class:"f-ec-sources-title"},[i.createTextVNode("引用来源")]),i.createVNode("ul",{class:"f-ec-sources-list"},[e.content.items.map((t,n)=>i.createVNode("li",{key:n},[i.createVNode("a",{href:t.url,target:"_blank",rel:"noopener noreferrer"},[t.title])]))])])}}),jt="__hitl_other__";function pu(e){const t=e??"text";return t==="text"||t==="select"||t==="multi_select"||t==="confirm"||t==="form"||t==="date"||t==="number"?t:"text"}const mc=i.defineComponent({name:"FXHitlQuestion",props:{content:{type:Object,required:!0},disabled:{type:Boolean,default:!1},onSubmitAnswers:{type:Function,default:void 0}},setup(e){const t=i.ref(!1),n=i.ref({}),u=i.ref({});function o(h){const x={},y={};for(const v of h){const g=pu(v.ui_type);g==="confirm"?x[v.id]=v.default_value==="true"||v.default_value==="1":x[v.id]=v.default_value??"",y[v.id]={active:!1,text:""}}n.value=x,u.value=y}i.watch(()=>e.content.questions,h=>{Array.isArray(h)&&h.length&&o(h)},{immediate:!0});const r=i.computed(()=>{var h,x;if(t.value||e.disabled)return!1;for(const y of e.content.questions){const v=pu(y.ui_type),g=n.value[y.id];if(v==="text"&&(typeof g!="string"||g.trim()==="")||v==="select"&&(typeof g!="string"||g.trim()===""||g===jt&&(((x=(h=u.value[y.id])==null?void 0:h.text)==null?void 0:x.trim())??"")==="")||v==="confirm"&&typeof g!="boolean")return!1}return!0});function a(h,x){n.value={...n.value,[h]:x}}function s(h,x){var y;x===jt?(u.value={...u.value,[h.id]:{...u.value[h.id],active:!0,text:((y=u.value[h.id])==null?void 0:y.text)??""}},a(h.id,jt)):(u.value={...u.value,[h.id]:{active:!1,text:""}},a(h.id,x))}function c(){var x,y,v;if(!r.value)return;const h=[];for(const g of e.content.questions){const b=pu(g.ui_type);let w=n.value[g.id];b==="select"&&w===jt&&(w=((y=(x=u.value[g.id])==null?void 0:x.text)==null?void 0:y.trim())??""),h.push({id:g.id,answer:w})}t.value=!0,(v=e.onSubmitAnswers)==null||v.call(e,h)}function d(h){const x=n.value[h.id]??"";return i.createVNode("div",{class:"f-hitl-field",key:h.id},[h.header?i.createVNode("div",{class:"f-hitl-field__header"},[h.header]):null,i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("input",{class:"f-hitl-input",type:"text",value:x,placeholder:h.placeholder??"请输入",disabled:t.value||e.disabled,onInput:y=>a(h.id,y.target.value)},null)])}function f(h,x){const y=n.value[h.id]??"",v=u.value[h.id]??{active:!1,text:""};return i.createVNode("div",{class:"f-hitl-field",key:h.id},[h.header?i.createVNode("div",{class:"f-hitl-field__header"},[h.header]):null,i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("div",{class:"f-hitl-select-group"},[x.map(g=>i.createVNode("button",{key:g.label,type:"button",class:["f-hitl-opt",{"f-hitl-opt--active":y===g.label&&!v.active}],disabled:t.value||e.disabled,onClick:()=>s(h,g.label)},[i.createVNode("span",{class:"f-hitl-opt__label"},[g.label]),g.description?i.createVNode("span",{class:"f-hitl-opt__desc"},[g.description]):null])),h.allow_other?i.createVNode("button",{type:"button",class:["f-hitl-opt",{"f-hitl-opt--active":y===jt||v.active}],disabled:t.value||e.disabled,onClick:()=>s(h,jt)},[i.createTextVNode("其他")]):null]),h.allow_other&&(y===jt||v.active)?i.createVNode("input",{class:"f-hitl-input f-hitl-input--other",type:"text",value:v.text,placeholder:"请输入自定义内容",disabled:t.value||e.disabled,onInput:g=>{const b=g.target.value;u.value={...u.value,[h.id]:{active:!0,text:b}},a(h.id,jt)}},null):null])}function l(h){const x=n.value[h.id];return i.createVNode("div",{class:"f-hitl-field",key:h.id},[h.header?i.createVNode("div",{class:"f-hitl-field__header"},[h.header]):null,i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("div",{class:"f-hitl-confirm"},[i.createVNode("button",{type:"button",class:["f-hitl-cbtn",{"f-hitl-cbtn--primary":x===!0}],disabled:t.value||e.disabled,onClick:()=>a(h.id,!0)},[i.createTextVNode("是")]),i.createVNode("button",{type:"button",class:["f-hitl-cbtn",{"f-hitl-cbtn--primary":x===!1}],disabled:t.value||e.disabled,onClick:()=>a(h.id,!1)},[i.createTextVNode("否")])])])}function p(h){return i.createVNode("div",{class:"f-hitl-field f-hitl-field--unsupported",key:h.id},[i.createVNode("div",{class:"f-hitl-field__label"},[h.question]),i.createVNode("div",{class:"f-hitl-unsupported"},[i.createTextVNode("暂不支持 ui_type「"),String(h.ui_type),i.createTextVNode("」,请升级前端。")])])}function m(h){const x=pu(h.ui_type);if(x==="text")return d(h);if(x==="select"){const y=Array.isArray(h.options)?h.options:[];return y.length===0?p({...h,ui_type:"text"}):f(h,y)}return x==="confirm"?l(h):p(h)}return()=>i.createVNode("div",{class:"f-hitl-card"},[i.createVNode("div",{class:"f-hitl-card__meta"},[i.createVNode("span",{class:"f-hitl-chip"},[i.createTextVNode("人机协同")])]),i.createVNode("div",{class:"f-hitl-card__body"},[e.content.questions.map(h=>m(h))]),i.createVNode("div",{class:"f-hitl-card__footer"},[i.createVNode("button",{type:"button",class:"f-hitl-submit",disabled:!r.value,onClick:c},[t.value?"已提交":"提交回答"])])])}}),gc=i.defineComponent({name:"UnknownEnterpriseMessage",props:{content:{type:Object,required:!0}},setup(e){return()=>i.createVNode("div",{class:"f-ec-unknown"},[i.createVNode("div",{class:"f-ec-unknown-title"},[i.createTextVNode("未知类型消息")]),e.content.wireType?i.createVNode("div",{class:"f-ec-unknown-wire"},[i.createTextVNode("wire type: "),e.content.wireType]):null,i.createVNode("div",{class:"f-ec-unknown-desc"},[e.content.hint??"客户端无法识别此消息类型,已按占位展示。"])])}}),wp=[Vo,lc,dc,mc,fc,hc,pc,Zt,gc,fo];Vo.install=e=>{for(const t of wp)e.component(t.name,t)};const vp={install(e){e.use(un).use(Jn).use(er).use(rr).use(ur).use(sr).use(cr).use(lr).use(dr).use(fn).use(Qt).use(vn).use(Xt).use(fr).use(hr).use(pr).use(mr).use(gn).use(bn).use(qt).use(yn).use(gr).use(br).use(yr).use(xr)}};N.FXAccordion=gr,N.FXAccordionItem=Ro,N.FXAgentThinking=Vo,N.FXAppPreview=un,N.FXAttachmentFile=lc,N.FXAttachmentPreview=mr,N.FXBubble=Jn,N.FXBubbleAction=ho,N.FXCarousel=er,N.FXCarouselItem=eu,N.FXChatPreview=rr,N.FXCoding=sr,N.FXConfirmDialog=ur,N.FXDynamicComponent=bn,N.FXErrorReminder=dc,N.FXFileOperation=cr,N.FXGenerateProcess=lr,N.FXHistory=dr,N.FXHitlQuestion=mc,N.FXInputRecommend=fc,N.FXLinkCard=hc,N.FXListView=xr,N.FXMarkdown=fn,N.FXMarkdownPreview=Qt,N.FXNav=br,N.FXPopover=qt,N.FXPopoverDirective=Ma,N.FXPrompt=fu,N.FXPrompts=vn,N.FXReferenceSources=pc,N.FXSearchBox=yr,N.FXSearchBoxContainer=hu,N.FXSplitter=yn,N.FXSplitterPane=tr,N.FXStartedTodo=Xt,N.FXSuggestion=fr,N.FXTodo=hr,N.FXTodoListItemView=Jr,N.FXTodoListView=Qn,N.FXToolUse=Zt,N.FXUnknownEnterprise=gc,N.FXUserAuth=fo,N.FXWelcome=pr,N.FXWidgetContainer=gn,N.PREVIEW_BRIDGE_MESSAGE_TYPE_ASSISTANT=Lo,N.PREVIEW_BRIDGE_SOURCE=To,N.PREVIEW_BRIDGE_VERSION=No,N.accordionItemProps=ic,N.accordionProps=oc,N.appPreviewMessageProps=Er,N.attachmentPreviewProps=rc,N.bubbleActionProps=ja,N.bubbleProps=ei,N.carouselItemProps=Ua,N.carouselProps=Ha,N.chatHistoryProps=Ys,N.chatPreviewProps=Wa,N.clonePreviewPayloadForPostMessage=Ds,N.codingMessageProps=Gs,N.confirmDialogProps=Ps,N.createPreviewIframeSdk=f2,N.default=vp,N.extractFileIdFromRuntimeDownloadUrl=ti,N.fileOperationMessageProps=Xs,N.generateProcessProps=Zs,N.getCustomClass=be,N.getCustomStyle=Ae,N.invokeAgentWorkbenchSdkApi=Io,N.isImageUrl=ni,N.isPreviewBridgeAssistantMessage=Ns,N.listViewProps=Mo,N.loadDynamicComponent=Ta,N.markdownMessageProps=sa,N.markdownPreviewProps=Ga,N.navProps=ac,N.popoverProps=Oa,N.postAssistantToPreviewIframe=Ls,N.postDynamicComponentAssistantMessage=dh,N.promptProps=Js,N.promptsProps=Ks,N.renderIconNode=Sr,N.renderNode=In,N.resolveHrefForAttachmentDownload=on,N.resolveRuntimeAttachmentDownloadUrl=Eu,N.searchBoxContainerProps=cc,N.searchBoxProps=sc,N.splitterProps=$a,N.startedTodoProps=Va,N.subscribeAssistantInPreviewIframe=Is,N.suggestionProps=ec,N.todoListItemProps=za,N.todoListViewProps=Ba,N.todoProps=tc,N.triggerAttachmentDownload=_r,N.unloadDynamicComponent=Na,N.useSequentialStreaming=Fr,N.useStreamingOutput=ri,N.useTimer=_u,N.welcomeProps=nc,N.widgetContainerProps=Sa,Object.defineProperties(N,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});